text: !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("lodash/assign"),require("lodash/cloneDeep"),require("lodash/compact"),require("lodash/difference"),require("lodash/functions"),require("lodash/identity"),require("lodash/includes"),require("lodash/isArray"),require("lodash/isElement"),require("lodash/isFunction"),require("lodash/isPlainObject"),require("lodash/isString"),require("lodash/merge"),require("lodash/trim")):"function"==typeof define&&define.amd?define(["lodash/assign","lodash/cloneDeep","lodash/compact","lodash/difference","lodash/functions","lodash/identity","lodash/includes","lodash/isArray","lodash/isElement","lodash/isFunction","lodash/isPlainObject","lodash/isString","lodash/merge","lodash/trim"],e):"object"==typeof exports?exports.cloudinary=e(require("lodash/assign"),require("lodash/cloneDeep"),require("lodash/compact"),require("lodash/difference"),require("lodash/functions"),require("lodash/identity"),require("lodash/includes"),require("lodash/isArray"),require("lodash/isElement"),require("lodash/isFunction"),require("lodash/isPlainObject"),require("lodash/isString"),require("lodash/merge"),require("lodash/trim")):t.cloudinary=e(t._.assign,t._.cloneDeep,t._.compact,t._.difference,t._.functions,t._.identity,t._.includes,t._.isArray,t._.isElement,t._.isFunction,t._.isPlainObject,t._.isString,t._.merge,t._.trim)}(this,function(t,e,n,r,o,i,u,a,s,c,l,f,h,p){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="./src/namespace/cloudinary-core.js")}({"./src/namespace/cloudinary-core.js":function(t,e,n){"use strict";n.r(e);var r={};n.r(r),n.d(r,"assign",function(){return s.a}),n.d(r,"cloneDeep",function(){return l.a}),n.d(r,"compact",function(){return h.a}),n.d(r,"difference",function(){return y.a}),n.d(r,"functions",function(){return v.a}),n.d(r,"identity",function(){return g.a}),n.d(r,"includes",function(){return _.a}),n.d(r,"isArray",function(){return k.a}),n.d(r,"isPlainObject",function(){return A.a}),n.d(r,"isString",function(){return E.a}),n.d(r,"merge",function(){return S.a}),n.d(r,"contains",function(){return _.a}),n.d(r,"isElement",function(){return B}),n.d(r,"isFunction",function(){return j}),n.d(r,"trim",function(){return F}),n.d(r,"getData",function(){return ot}),n.d(r,"setData",function(){return it}),n.d(r,"getAttribute",function(){return ut}),n.d(r,"setAttribute",function(){return at}),n.d(r,"removeAttribute",function(){return st}),n.d(r,"setAttributes",function(){return ct}),n.d(r,"hasClass",function(){return lt}),n.d(r,"addClass",function(){return ft}),n.d(r,"getStyles",function(){return ht}),n.d(r,"cssExpand",function(){return pt}),n.d(r,"domStyle",function(){return yt}),n.d(r,"curCSS",function(){return dt}),n.d(r,"cssValue",function(){return vt}),n.d(r,"augmentWidthOrHeight",function(){return mt}),n.d(r,"getWidthOrHeight",function(){return bt}),n.d(r,"width",function(){return _t}),n.d(r,"omit",function(){return x}),n.d(r,"allStrings",function(){return R}),n.d(r,"without",function(){return z}),n.d(r,"isNumberLike",function(){return I}),n.d(r,"smartEscape",function(){return V}),n.d(r,"defaults",function(){return N}),n.d(r,"objectProto",function(){return q}),n.d(r,"objToString",function(){return L}),n.d(r,"isObject",function(){return H}),n.d(r,"funcTag",function(){return M}),n.d(r,"reWords",function(){return W}),n.d(r,"camelCase",function(){return $}),n.d(r,"snakeCase",function(){return Q}),n.d(r,"convertKeys",function(){return Y}),n.d(r,"withCamelCaseKeys",function(){return Z}),n.d(r,"withSnakeCaseKeys",function(){return K}),n.d(r,"base64Encode",function(){return G}),n.d(r,"base64EncodeURL",function(){return X}),n.d(r,"extractUrlParams",function(){return tt}),n.d(r,"patchFetchFormat",function(){return et}),n.d(r,"optionConsume",function(){return nt}),n.d(r,"isEmpty",function(){return rt});var o={};n.r(o),n.d(o,"VERSION",function(){return xe}),n.d(o,"CF_SHARED_CDN",function(){return Te}),n.d(o,"OLD_AKAMAI_SHARED_CDN",function(){return Re}),n.d(o,"AKAMAI_SHARED_CDN",function(){return ze}),n.d(o,"SHARED_CDN",function(){return Ie}),n.d(o,"DEFAULT_POSTER_OPTIONS",function(){return Ve}),n.d(o,"DEFAULT_VIDEO_SOURCE_TYPES",function(){return Ne}),n.d(o,"SEO_TYPES",function(){return qe}),n.d(o,"DEFAULT_IMAGE_PARAMS",function(){return Le}),n.d(o,"DEFAULT_VIDEO_PARAMS",function(){return He}),n.d(o,"DEFAULT_VIDEO_SOURCES",function(){return Me});var i=function(t){var e,n,r,o,i,u,a,s;if(null==t)return"";for(s="",i=void 0,r=void 0,0,i=r=0,a=(u=t+"").length,o=0;o<a;)n=null,(e=u.charCodeAt(o))<128?r++:n=e>127&&e<2048?String.fromCharCode(e>>6|192,63&e|128):String.fromCharCode(e>>12|224,e>>6&63|128,63&e|128),null!==n&&(r>i&&(s+=u.slice(i,r)),s+=n,i=r=o+1),o++;return r>i&&(s+=u.slice(i,a)),s};var u=function(t){var e,n,r,o;for(e=0,o=0,e^=-1,n=0,r=(t=i(t)).length;n<r;)o=255&(e^t.charCodeAt(n)),e=e>>>8^"0x"+"00000000 77073096 EE0E612C 990951BA 076DC419 706AF48F E963A535 9E6495A3 0EDB8832 79DCB8A4 E0D5E91E 97D2D988 09B64C2B 7EB17CBD E7B82D07 90BF1D91 1DB71064 6AB020F2 F3B97148 84BE41DE 1ADAD47D 6DDDE4EB F4D4B551 83D385C7 136C9856 646BA8C0 FD62F97A 8A65C9EC 14015C4F 63066CD9 FA0F3D63 8D080DF5 3B6E20C8 4C69105E D56041E4 A2677172 3C03E4D1 4B04D447 D20D85FD A50AB56B 35B5A8FA 42B2986C DBBBC9D6 ACBCF940 32D86CE3 45DF5C75 DCD60DCF ABD13D59 26D930AC 51DE003A C8D75180 BFD06116 21B4F4B5 56B3C423 CFBA9599 B8BDA50F 2802B89E 5F058808 C60CD9B2 B10BE924 2F6F7C87 58684C11 C1611DAB B6662D3D 76DC4190 01DB7106 98D220BC EFD5102A 71B18589 06B6B51F 9FBFE4A5 E8B8D433 7807C9A2 0F00F934 9609A88E E10E9818 7F6A0DBB 086D3D2D 91646C97 E6635C01 6B6B51F4 1C6C6162 856530D8 F262004E 6C0695ED 1B01A57B 8208F4C1 F50FC457 65B0D9C6 12B7E950 8BBEB8EA FCB9887C 62DD1DDF 15DA2D49 8CD37CF3 FBD44C65 4DB26158 3AB551CE A3BC0074 D4BB30E2 4ADFA541 3DD895D7 A4D1C46D D3D6F4FB 4369E96A 346ED9FC AD678846 DA60B8D0 44042D73 33031DE5 AA0A4C5F DD0D7CC9 5005713C 270241AA BE0B1010 C90C2086 5768B525 206F85B3 B966D409 CE61E49F 5EDEF90E 29D9C998 B0D09822 C7D7A8B4 59B33D17 2EB40D81 B7BD5C3B C0BA6CAD EDB88320 9ABFB3B6 03B6E20C 74B1D29A EAD54739 9DD277AF 04DB2615 73DC1683 E3630B12 94643B84 0D6D6A3E 7A6A5AA8 E40ECF0B 9309FF9D 0A00AE27 7D079EB1 F00F9344 8708A3D2 1E01F268 6906C2FE F762575D 806567CB 196C3671 6E6B06E7 FED41B76 89D32BE0 10DA7A5A 67DD4ACC F9B9DF6F 8EBEEFF9 17B7BE43 60B08ED5 D6D6A3E8 A1D1937E 38D8C2C4 4FDFF252 D1BB67F1 A6BC5767 3FB506DD 48B2364B D80D2BDA AF0A1B4C 36034AF6 41047A60 DF60EFC3 A867DF55 316E8EEF 4669BE79 CB61B38C BC66831A 256FD2A0 5268E236 CC0C7795 BB0B4703 220216B9 5505262F C5BA3BBE B2BD0B28 2BB45A92 5CB36A04 C2D7FFA7 B5D0CF31 2CD99E8B 5BDEAE1D 9B64C2B0 EC63F226 756AA39C 026D930A 9C0906A9 EB0E363F 72076785 05005713 95BF4A82 E2B87A14 7BB12BAE 0CB61B38 92D28E9B E5D5BE0D 7CDCEFB7 0BDBDF21 86D3D2D4 F1D4E242 68DDB3F8 1FDA836E 81BE16CD F6B9265B 6FB077E1 18B74777 88085AE6 FF0F6A70 66063BCA 11010B5C 8F659EFF F862AE69 616BFFD3 166CCF45 A00AE278 D70DD2EE 4E048354 3903B3C2 A7672661 D06016F7 4969474D 3E6E77DB AED16A4A D9D65ADC 40DF0B66 37D83BF0 A9BCAE53 DEBB9EC5 47B2CF7F 30B5FFE9 BDBDF21C CABAC28A 53B39330 24B4A3A6 BAD03605 CDD70693 54DE5729 23D967BF B3667A2E C4614AB8 5D681B02 2A6F2B94 B40BBE37 C30C8EA1 5A05DF1B 2D02EF8D".substr(9*o,8),n++;return(e^=-1)<0&&(e+=4294967296),e},a=n("lodash/assign"),s=n.n(a),c=n("lodash/cloneDeep"),l=n.n(c),f=n("lodash/compact"),h=n.n(f),p=n("lodash/difference"),y=n.n(p),d=n("lodash/functions"),v=n.n(d),m=n("lodash/identity"),g=n.n(m),b=n("lodash/includes"),_=n.n(b),w=n("lodash/isArray"),k=n.n(w),O=n("lodash/isPlainObject"),A=n.n(O),D=n("lodash/isString"),E=n.n(D),C=n("lodash/merge"),S=n.n(C),B=n("lodash/isElement"),j=n("lodash/isFunction"),F=n("lodash/trim");function P(t){return(P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function x(t,e){t=t||{};var n=Object.keys(t).filter(function(t){return!_()(e,t)}),r={};return n.forEach(function(e){return r[e]=t[e]}),r}var T,R=function(t){return t.length&&t.every(E.a)},z=function(t,e){return t.filter(function(t){return t!==e})},I=function(t){return null!=t&&!isNaN(parseFloat(t))},V=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:/([^a-zA-Z0-9_.\-\/:]+)/g;return t.replace(e,function(t){return t.split("").map(function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()}).join("")})},N=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return n.reduce(function(t,e){var n,r;for(n in e)r=e[n],void 0===t[n]&&(t[n]=r);return t},t)},q=Object.prototype,L=q.toString,H=function(t){var e;return e=P(t),!!t&&("object"===e||"function"===e)},M="[object Function]",U=function(t){return H(t)&&L.call(t)===M},W=RegExp("[A-Z]+(?=[A-Z][a-z]+)|[A-Z]?[a-z]+|[A-Z]+|[0-9]+","g"),$=function(t){var e=t.match(W);return(e=e.map(function(t){return t.charAt(0).toLocaleUpperCase()+t.slice(1).toLocaleLowerCase()}))[0]=e[0].toLocaleLowerCase(),e.join("")},Q=function(t){var e=t.match(W);return(e=e.map(function(t){return t.toLocaleLowerCase()})).join("_")},Y=function(t,e){var n,r;for(var o in n={},t)r=t[o],e&&(o=e(o)),rt(o)||(n[o]=r);return n},Z=function(t){return Y(t,$)},K=function(t){return Y(t,Q)},G="undefined"!=typeof btoa&&U(btoa)?btoa:"undefined"!=typeof Buffer&&U(Buffer)?function(t){return t instanceof Buffer||(t=new Buffer.from(String(t),"binary")),t.toString("base64")}:function(t){throw new Error("No base64 encoding function found")},X=function(t){try{t=decodeURI(t)}finally{t=encodeURI(t)}return G(t)},J=["api_secret","auth_token","cdn_subdomain","cloud_name","cname","format","private_cdn","resource_type","secure","secure_cdn_subdomain","secure_distribution","shorten","sign_url","ssl_detected","type","url_suffix","use_root_path","version"];function tt(t){return J.reduce(function(e,n){return null!=t[n]&&(e[n]=t[n]),e},{})}function et(t){null==t&&(t={}),"fetch"===t.type&&null==t.fetch_format&&(t.fetch_format=nt(t,"format"))}function nt(t,e,n){var r=t[e];return delete t[e],null!=r?r:n}function rt(t){if(null==t)return!0;if("number"==typeof t.length)return 0===t.length;if("number"==typeof t.size)return 0===t.size;if("object"==P(t)){for(var e in t)if(t.hasOwnProperty(e))return!1;return!0}return!0}var ot=function(t,e){switch(!1){case!(null==t):return;case!j(t.getAttribute):return t.getAttribute("data-".concat(e));case!j(t.getAttr):return t.getAttr("data-".concat(e));case!j(t.data):return t.data(e);case!(j("undefined"!=typeof jQuery&&jQuery.fn&&jQuery.fn.data)&&B(t)):return jQuery(t).data(e)}},it=function(t,e,n){switch(!1){case!(null==t):return;case!j(t.setAttribute):return t.setAttribute("data-".concat(e),n);case!j(t.setAttr):return t.setAttr("data-".concat(e),n);case!j(t.data):return t.data(e,n);case!(j("undefined"!=typeof jQuery&&jQuery.fn&&jQuery.fn.data)&&B(t)):return jQuery(t).data(e,n)}},ut=function(t,e){switch(!1){case!(null==t):return;case!j(t.getAttribute):return t.getAttribute(e);case!j(t.attr):return t.attr(e);case!j(t.getAttr):return t.getAttr(e)}},at=function(t,e,n){switch(!1){case!(null==t):return;case!j(t.setAttribute):return t.setAttribute(e,n);case!j(t.attr):return t.attr(e,n);case!j(t.setAttr):return t.setAttr(e,n)}},st=function(t,e){switch(!1){case!(null==t):return;case!j(t.removeAttribute):return t.removeAttribute(e);default:return at(t,void 0)}},ct=function(t,e){var n,r,o;for(n in r=[],e)null!=(o=e[n])?r.push(at(t,n,o)):r.push(st(t,n));return r},lt=function(t,e){if(B(t))return t.className.match(new RegExp("\\b".concat(e,"\\b")))},ft=function(t,e){if(!t.className.match(new RegExp("\\b".concat(e,"\\b"))))return t.className=F("".concat(t.className," ").concat(e))},ht=function(t){return t.ownerDocument.defaultView.opener?t.ownerDocument.defaultView.getComputedStyle(t,null):window.getComputedStyle(t,null)},pt=["Top","Right","Bottom","Left"];T=function(t,e){var n,r;return n=9===t.nodeType?t.documentElement:t,t===(r=e&&e.parentNode)||!(!r||1!==r.nodeType||!n.contains(r))};var yt=function(t,e){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style)return t.style[e]},dt=function(t,e,n){var r,o,i,u,a,s;return u=/^margin/,s=void 0,o=void 0,r=void 0,i=void 0,a=t.style,(n=n||ht(t))&&(i=n.getPropertyValue(e)||n[e]),n&&(""!==i||T(t.ownerDocument,t)||(i=yt(t,e)),gt.test(i)&&u.test(e)&&(s=a.width,o=a.minWidth,r=a.maxWidth,a.minWidth=a.maxWidth=a.width=i,i=n.width,a.width=s,a.minWidth=o,a.maxWidth=r)),void 0!==i?i+"":i},vt=function(t,e,n,r){var o;return o=dt(t,e,r),n?parseFloat(o):o},mt=function(t,e,n,r,o){var i,u,a,s,c;if(n===(r?"border":"content"))return 0;for(c=0,i=0,u=(s="width"===e?["Right","Left"]:["Top","Bottom"]).length;i<u;i++)a=s[i],"margin"===n&&(c+=vt(t,n+a,!0,o)),r?("content"===n&&(c-=vt(t,"padding".concat(a),!0,o)),"margin"!==n&&(c-=vt(t,"border".concat(a,"Width"),!0,o))):(c+=vt(t,"padding".concat(a),!0,o),"padding"!==n&&(c+=vt(t,"border".concat(a,"Width"),!0,o)));return c},gt=new RegExp("^("+/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source+")(?!px)[a-z%]+$","i"),bt=function(t,e,n){var r,o,i,u;if(u=!0,i="width"===e?t.offsetWidth:t.offsetHeight,o=ht(t),r="border-box"===vt(t,"boxSizing",!1,o),i<=0||null==i){if(((i=dt(t,e,o))<0||null==i)&&(i=t.style[e]),gt.test(i))return i;u=r&&i===t.style[e],i=parseFloat(i)||0}return i+mt(t,e,n||(r?"border":"content"),u,o)},_t=function(t){return bt(t,"width","content")};function wt(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var kt=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.expressions=[],null!=e&&this.expressions.push(t.normalize(e))}var e,n,r;return e=t,r=[{key:"new",value:function(t){return new this(t)}},{key:"normalize",value:function(e){var n,r;return null==e?e:(e=String(e),"\\|\\||>=|<=|&&|!=|>|=|<|/|-|\\+|\\*",n="((\\|\\||>=|<=|&&|!=|>|=|<|/|-|\\+|\\*)(?=[ _])|"+Object.keys(t.PREDEFINED_VARS).join("|")+")",r=new RegExp(n,"g"),(e=e.replace(r,function(e){return t.OPERATORS[e]||t.PREDEFINED_VARS[e]})).replace(/[ _]+/g,"_"))}},{key:"variable",value:function(t,e){return new this(t).value(e)}},{key:"width",value:function(){return new this("width")}},{key:"height",value:function(){return new this("height")}},{key:"initialWidth",value:function(){return new this("initialWidth")}},{key:"initialHeight",value:function(){return new this("initialHeight")}},{key:"aspectRatio",value:function(){return new this("aspectRatio")}},{key:"initialAspectRatio",value:function(){return new this("initialAspectRatio")}},{key:"pageCount",value:function(){return new this("pageCount")}},{key:"faceCount",value:function(){return new this("faceCount")}},{key:"currentPage",value:function(){return new this("currentPage")}},{key:"tags",value:function(){return new this("tags")}},{key:"pageX",value:function(){return new this("pageX")}},{key:"pageY",value:function(){return new this("pageY")}}],(n=[{key:"serialize",value:function(){return t.normalize(this.expressions.join("_"))}},{key:"toString",value:function(){return this.serialize()}},{key:"getParent",value:function(){return this.parent}},{key:"setParent",value:function(t){return this.parent=t,this}},{key:"predicate",value:function(e,n,r){return null!=t.OPERATORS[n]&&(n=t.OPERATORS[n]),this.expressions.push("".concat(e,"_").concat(n,"_").concat(r)),this}},{key:"and",value:function(){return this.expressions.push("and"),this}},{key:"or",value:function(){return this.expressions.push("or"),this}},{key:"then",value:function(){return this.getParent().if(this.toString())}},{key:"height",value:function(t,e){return this.predicate("h",t,e)}},{key:"width",value:function(t,e){return this.predicate("w",t,e)}},{key:"aspectRatio",value:function(t,e){return this.predicate("ar",t,e)}},{key:"pageCount",value:function(t,e){return this.predicate("pc",t,e)}},{key:"faceCount",value:function(t,e){return this.predicate("fc",t,e)}},{key:"value",value:function(t){return this.expressions.push(t),this}}])&&wt(e.prototype,n),r&&wt(e,r),t}();kt.OPERATORS={"=":"eq","!=":"ne","<":"lt",">":"gt","<=":"lte",">=":"gte","&&":"and","||":"or","*":"mul","/":"div","+":"add","-":"sub"},kt.PREDEFINED_VARS={aspect_ratio:"ar",aspectRatio:"ar",current_page:"cp",currentPage:"cp",duration:"du",face_count:"fc",faceCount:"fc",height:"h",initial_aspect_ratio:"iar",initial_duration:"idu",initial_height:"ih",initial_width:"iw",initialAspectRatio:"iar",initialDuration:"idu",initialHeight:"ih",initialWidth:"iw",page_count:"pc",page_x:"px",page_y:"py",pageCount:"pc",pageX:"px",pageY:"py",tags:"tags",width:"w"},kt.BOUNDRY="[ _]+";var Ot=kt;function At(t){return(At="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function Dt(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function Et(t,e){return!e||"object"!==At(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Ct(t){return(Ct=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function St(t,e){return(St=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Bt=function(t){function Condition(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,Condition),Et(this,Ct(Condition).call(this,t))}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&St(t,e)}(Condition,Ot),e=Condition,(n=[{key:"height",value:function(t,e){return this.predicate("h",t,e)}},{key:"width",value:function(t,e){return this.predicate("w",t,e)}},{key:"aspectRatio",value:function(t,e){return this.predicate("ar",t,e)}},{key:"pageCount",value:function(t,e){return this.predicate("pc",t,e)}},{key:"faceCount",value:function(t,e){return this.predicate("fc",t,e)}},{key:"duration",value:function(t,e){return this.predicate("du",t,e)}},{key:"initialDuration",value:function(t,e){return this.predicate("idu",t,e)}}])&&Dt(e.prototype,n),r&&Dt(e,r),Condition}();function jt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var u,a=t[Symbol.iterator]();!(r=(u=a.next()).done)&&(n.push(u.value),!e||n.length!==e);r=!0);}catch(s){o=!0,i=s}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function Ft(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var Pt=function(){function Configuration(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,Configuration),this.configuration=null==t?{}:l()(t),N(this.configuration,xt)}var t,e,n;return t=Configuration,(e=[{key:"init",value:function(){return this.fromEnvironment(),this.fromDocument(),this}},{key:"set",value:function(t,e){return this.configuration[t]=e,this}},{key:"get",value:function(t){return this.configuration[t]}},{key:"merge",value:function(t){return s()(this.configuration,l()(t)),this}},{key:"fromDocument",value:function(){var t,e,n,r;if(r="undefined"!=typeof document&&null!==document?document.querySelectorAll('meta[name^="cloudinary_"]'):void 0)for(e=0,n=r.length;e<n;e++)t=r[e],this.configuration[t.getAttribute("name").replace("cloudinary_","")]=t.getAttribute("content");return this}},{key:"fromEnvironment",value:function(){var t,e,n,r=this;return"undefined"!=typeof process&&null!==process&&process.env&&process.env.CLOUDINARY_URL&&(t=process.env.CLOUDINARY_URL,(n=/cloudinary:\/\/(?:(\w+)(?:\:([\w-]+))?@)?([\w\.-]+)(?:\/([^?]*))?(?:\?(.+))?/.exec(t))&&(null!=n[3]&&(this.configuration.cloud_name=n[3]),null!=n[1]&&(this.configuration.api_key=n[1]),null!=n[2]&&(this.configuration.api_secret=n[2]),null!=n[4]&&(this.configuration.private_cdn=null!=n[4]),null!=n[4]&&(this.configuration.secure_distribution=n[4]),null!=(e=n[5])&&e.split("&").forEach(function(t){var e=jt(t.split("="),2),n=e[0],o=e[1];null==o&&(o=!0),r.configuration[n]=o}))),this}},{key:"config",value:function(t,e){switch(!1){case void 0===e:return this.set(t,e),this.configuration;case!E()(t):return this.get(t);case!A()(t):return this.merge(t),this.configuration;default:return this.configuration}}},{key:"toOptions",value:function(){return l()(this.configuration)}}])&&Ft(t.prototype,e),n&&Ft(t,n),Configuration}(),xt={responsive_class:"cld-responsive",responsive_use_breakpoints:!0,round_dpr:!0,secure:"https:"===("undefined"!=typeof window&&null!==window&&window.location?window.location.protocol:void 0)};Pt.CONFIG_PARAMS=["api_key","api_secret","callback","cdn_subdomain","cloud_name","cname","private_cdn","protocol","resource_type","responsive","responsive_class","responsive_use_breakpoints","responsive_width","round_dpr","secure","secure_cdn_subdomain","secure_distribution","shorten","type","upload_preset","url_suffix","use_root_path","version"];var Tt=Pt;function Rt(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var zt=function(){function Layer(t){var e=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,Layer),this.options={},null!=t&&["resourceType","type","publicId","format"].forEach(function(n){var r;return e.options[n]=null!=(r=t[n])?r:t[Q(n)]})}var t,e,n;return t=Layer,(e=[{key:"resourceType",value:function(t){return this.options.resourceType=t,this}},{key:"type",value:function(t){return this.options.type=t,this}},{key:"publicId",value:function(t){return this.options.publicId=t,this}},{key:"getPublicId",value:function(){var t;return null!=(t=this.options.publicId)?t.replace(/\//g,":"):void 0}},{key:"getFullPublicId",value:function(){return null!=this.options.format?this.getPublicId()+"."+this.options.format:this.getPublicId()}},{key:"format",value:function(t){return this.options.format=t,this}},{key:"toString",value:function(){var t;if(t=[],null==this.options.publicId)throw"Must supply publicId";return"image"!==this.options.resourceType&&t.push(this.options.resourceType),"upload"!==this.options.type&&t.push(this.options.type),t.push(this.getFullPublicId()),h()(t).join(":")}},{key:"clone",value:function(){return new this.constructor(this.options)}}])&&Rt(t.prototype,e),n&&Rt(t,n),Layer}();function It(t){return(It="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function Vt(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function Nt(t,e){return!e||"object"!==It(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function qt(t){return(qt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Lt(t,e){return(Lt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Ht=function(t){function TextLayer(t){var e;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,TextLayer),e=Nt(this,qt(TextLayer).call(this,t)),null!=t&&["resourceType","resourceType","fontFamily","fontSize","fontWeight","fontStyle","textDecoration","textAlign","stroke","letterSpacing","lineSpacing","fontHinting","fontAntialiasing","text"].forEach(function(n){var r;return e.options[n]=null!=(r=t[n])?r:t[Q(n)]}),e.options.resourceType="text",e}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Lt(t,e)}(TextLayer,zt),e=TextLayer,(n=[{key:"resourceType",value:function(t){throw"Cannot modify resourceType for text layers"}},{key:"type",value:function(t){throw"Cannot modify type for text layers"}},{key:"format",value:function(t){throw"Cannot modify format for text layers"}},{key:"fontFamily",value:function(t){return this.options.fontFamily=t,this}},{key:"fontSize",value:function(t){return this.options.fontSize=t,this}},{key:"fontWeight",value:function(t){return this.options.fontWeight=t,this}},{key:"fontStyle",value:function(t){return this.options.fontStyle=t,this}},{key:"textDecoration",value:function(t){return this.options.textDecoration=t,this}},{key:"textAlign",value:function(t){return this.options.textAlign=t,this}},{key:"stroke",value:function(t){return this.options.stroke=t,this}},{key:"letterSpacing",value:function(t){return this.options.letterSpacing=t,this}},{key:"lineSpacing",value:function(t){return this.options.lineSpacing=t,this}},{key:"fontHinting",value:function(t){return this.options.fontHinting=t,this}},{key:"fontAntialiasing",value:function(t){return this.options.fontAntialiasing=t,this}},{key:"text",value:function(t){return this.options.text=t,this}},{key:"toString",value:function(){var t,e,n,r,o,i,u,a,s,c;if(a=this.textStyleIdentifier(),null!=this.options.publicId&&(r=this.getFullPublicId()),null!=this.options.text){if(e=!rt(r),n=!rt(a),e&&n||!e&&!n)throw"Must supply either style parameters or a public_id when providing text parameter in a text overlay/underlay, but not both!";for(o=/\$\([a-zA-Z]\w*\)/g,u=0,c=V(this.options.text,/[,\/]/g),s="";i=o.exec(c);)s+=V(c.slice(u,i.index)),s+=i[0],u=i.index+i[0].length;s+=V(c.slice(u))}return t=[this.options.resourceType,a,r,s],h()(t).join(":")}},{key:"textStyleIdentifier",value:function(){var t;if(t=[],"normal"!==this.options.fontWeight&&t.push(this.options.fontWeight),"normal"!==this.options.fontStyle&&t.push(this.options.fontStyle),"none"!==this.options.textDecoration&&t.push(this.options.textDecoration),t.push(this.options.textAlign),"none"!==this.options.stroke&&t.push(this.options.stroke),rt(this.options.letterSpacing)&&!I(this.options.letterSpacing)||t.push("letter_spacing_"+this.options.letterSpacing),rt(this.options.lineSpacing)&&!I(this.options.lineSpacing)||t.push("line_spacing_"+this.options.lineSpacing),rt(this.options.fontAntialiasing)||t.push("antialias_"+this.options.fontAntialiasing),rt(this.options.fontHinting)||t.push("hinting_"+this.options.fontHinting),!rt(h()(t))){if(rt(this.options.fontFamily))throw"Must supply fontFamily. ".concat(t);if(rt(this.options.fontSize)&&!I(this.options.fontSize))throw"Must supply fontSize."}return t.unshift(this.options.fontFamily,this.options.fontSize),t=h()(t).join("_")}}])&&Vt(e.prototype,n),r&&Vt(e,r),TextLayer}();function Mt(t){return(Mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function Ut(t,e){return!e||"object"!==Mt(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Wt(t){return(Wt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function $t(t,e){return($t=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Qt=function(t){function SubtitlesLayer(t){var e;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,SubtitlesLayer),(e=Ut(this,Wt(SubtitlesLayer).call(this,t))).options.resourceType="subtitles",e}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&$t(t,e)}(SubtitlesLayer,Ht),SubtitlesLayer}();function Yt(t){return(Yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function Zt(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function Kt(t,e){return!e||"object"!==Yt(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Gt(t){return(Gt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Xt(t,e){return(Xt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Jt=function(t){function FetchLayer(t){var e;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,FetchLayer),e=Kt(this,Gt(FetchLayer).call(this,t)),E()(t)?e.options.url=t:(null!=t?t.url:void 0)&&(e.options.url=t.url),e}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Xt(t,e)}(FetchLayer,zt),e=FetchLayer,(n=[{key:"url",value:function(t){return this.options.url=t,this}},{key:"toString",value:function(){return"fetch:".concat(X(this.options.url))}}])&&Zt(e.prototype,n),r&&Zt(e,r),FetchLayer}();function te(t){return(te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function ee(t,e){return!e||"object"!==te(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function ne(t,e,n){return(ne="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=re(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}function re(t){return(re=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function oe(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ie(t,e)}function ie(t,e){return(ie=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function ue(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function ae(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function se(t,e,n){return e&&ae(t.prototype,e),n&&ae(t,n),t}var ce=function(){function t(e,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g.a;ue(this,t),this.name=e,this.shortName=n,this.process=r}return se(t,[{key:"set",value:function(t){return this.origValue=t,this}},{key:"serialize",value:function(){var t,e;return t=this.value(),e=k()(t)||A()(t)||E()(t)?!rt(t):null!=t,null!=this.shortName&&e?"".concat(this.shortName,"_").concat(t):""}},{key:"value",value:function(){return this.process(this.origValue)}},{key:"build_array",value:function(t){return null==t?[]:k()(t)?t:[t]}}],[{key:"norm_color",value:function(t){return null!=t?t.replace(/^#/,"rgb:"):void 0}},{key:"process_video_params",value:function(t){var e;switch(t.constructor){case Object:return e="","codec"in t&&(e=t.codec,"profile"in t&&(e+=":"+t.profile,"level"in t&&(e+=":"+t.level))),e;case String:return t;default:return null}}}]),t}(),le=function(t){function e(t,n){var r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".",i=arguments.length>3?arguments[3]:void 0;return ue(this,e),(r=ee(this,re(e).call(this,t,n,i))).sep=o,r}return oe(e,ce),se(e,[{key:"serialize",value:function(){if(null!=this.shortName){var t=this.value();if(rt(t))return"";if(E()(t))return"".concat(this.shortName,"_").concat(t);var e=t.map(function(t){return j(t.serialize)?t.serialize():t}).join(this.sep);return"".concat(this.shortName,"_").concat(e)}return""}},{key:"value",value:function(){var t=this;return k()(this.origValue)?this.origValue.map(function(e){return t.process(e)}):this.process(this.origValue)}},{key:"set",value:function(t){return null==t||k()(t)?ne(re(e.prototype),"set",this).call(this,t):ne(re(e.prototype),"set",this).call(this,[t])}}]),e}(),fe=function(t){function e(t){var n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"t",o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".",i=arguments.length>3?arguments[3]:void 0;return ue(this,e),(n=ee(this,re(e).call(this,t,r,i))).sep=o,n}return oe(e,ce),se(e,[{key:"serialize",value:function(){var t=this;if(rt(this.value()))return"";if(R(this.value())){var e=this.value().join(this.sep);return rt(e)?"":"".concat(this.shortName,"_").concat(e)}return this.value().map(function(e){return E()(e)&&!rt(e)?"".concat(t.shortName,"_").concat(e):j(e.serialize)?e.serialize():A()(e)&&!rt(e)?new Se(e).serialize():void 0}).filter(function(t){return t})}},{key:"set",value:function(t){return this.origValue=t,k()(this.origValue)?ne(re(e.prototype),"set",this).call(this,this.origValue):ne(re(e.prototype),"set",this).call(this,[this.origValue])}}]),e}(),he=function(t){function e(t,n,r){var o;return ue(this,e),(o=ee(this,re(e).call(this,t,n,r))).process||(o.process=o.norm_range_value),o}return oe(e,ce),se(e,null,[{key:"norm_range_value",value:function(t){var e,n;return(n=String(t).match(new RegExp("^"+offset_any_pattern+"$")))&&(e=null!=n[5]?"p":"",t=(n[1]||n[4])+e),t}}]),e}(),pe=function(t){function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g.a;return ue(this,e),ee(this,re(e).call(this,t,n,r))}return oe(e,ce),se(e,[{key:"serialize",value:function(){return this.value()}}]),e}(),ye=function(t){function e(){return ue(this,e),ee(this,re(e).apply(this,arguments))}return oe(e,ce),se(e,[{key:"value",value:function(){if(null==this.origValue)return"";var t;if(this.origValue instanceof zt)t=this.origValue;else if(A()(this.origValue)){var e=Z(this.origValue);t="text"===e.resourceType||null!=e.text?new Ht(e):"subtitles"===e.resourceType?new Qt(e):"fetch"===e.resourceType||null!=e.url?new Jt(e):new zt(e)}else t=E()(this.origValue)?/^fetch:.+/.test(this.origValue)?new Jt(this.origValue.substr(6)):this.origValue:"";return t.toString()}},{key:"textStyle",value:function(t){return new Ht(t).textStyleIdentifier()}}]),e}();function de(t){return(de="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function ve(t,e){return!e||"object"!==de(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function me(t){return(me=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ge(t,e){return(ge=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function be(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var u,a=t[Symbol.iterator]();!(r=(u=a.next()).done)&&(n.push(u.value),!e||n.length!==e);r=!0);}catch(s){o=!0,i=s}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function _e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function we(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function ke(t,e,n){return e&&we(t.prototype,e),n&&we(t,n),t}function Oe(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return n.forEach(function(e){Object.keys(e).forEach(function(n){null!=e[n]&&(t[n]=e[n])})}),t}var Ae=function(){function t(e){var n,r;_e(this,t),n=void 0,r={},this.toOptions=function(t){var e={};if(null==t&&(t=!0),Object.keys(r).forEach(function(t){return e[t]=r[t].origValue}),Oe(e,this.otherOptions),t&&!rt(this.chained)){var n=this.chained.map(function(t){return t.toOptions()});n.push(e),Oe(e={},this.otherOptions),e.transformation=n}return e},this.setParent=function(t){return n=t,null!=t&&this.fromOptions("function"==typeof t.toOptions?t.toOptions():void 0),this},this.getParent=function(){return n},this.param=function(t,e,n,o,i){return null==i&&(i=j(o)?o:g.a),r[e]=new ce(e,n,i).set(t),this},this.rawParam=function(t,e,n,o){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:g.a;return i=Ee(arguments),r[e]=new pe(e,n,i).set(t),this},this.rangeParam=function(t,e,n,o){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:g.a;return i=Ee(arguments),r[e]=new he(e,n,i).set(t),this},this.arrayParam=function(t,e,n){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:":",i=(arguments.length>4&&void 0!==arguments[4]&&arguments[4],arguments.length>5&&void 0!==arguments[5]?arguments[5]:g.a);return i=Ee(arguments),r[e]=new le(e,n,o,i).set(t),this},this.transformationParam=function(t,e,n){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",i=(arguments.length>4&&arguments[4],arguments.length>5&&void 0!==arguments[5]?arguments[5]:g.a);return i=Ee(arguments),r[e]=new fe(e,n,o,i).set(t),this},this.layerParam=function(t,e,n){return r[e]=new ye(e,n).set(t),this},this.getValue=function(t){var e=r[t]&&r[t].value();return null!=e?e:this.otherOptions[t]},this.get=function(t){return r[t]},this.remove=function(t){var e;switch(!1){case null==r[t]:return e=r[t],delete r[t],e.origValue;case null==this.otherOptions[t]:return e=this.otherOptions[t],delete this.otherOptions[t],e;default:return null}},this.keys=function(){var t;return function(){var e;for(t in e=[],r)null!=t&&e.push(t.match(De)?t:Q(t));return e}().sort()},this.toPlainObject=function(){var t,e,n;for(e in t={},r)t[e]=r[e].value(),A()(t[e])&&(t[e]=l()(t[e]));return rt(this.chained)||((n=this.chained.map(function(t){return t.toPlainObject()})).push(t),t={transformation:n}),t},this.chain=function(){var t;return 0!==Object.getOwnPropertyNames(r).length&&(t=new this.constructor(this.toOptions(!1)),this.resetTransformations(),this.chained.push(t)),this},this.resetTransformations=function(){return r={},this},this.otherOptions={},this.chained=[],this.fromOptions(e)}return ke(t,[{key:"fromOptions",value:function(e){if(e instanceof t)this.fromTransformation(e);else for(var n in e||(e={}),(E()(e)||k()(e))&&(e={transformation:e}),(e=l()(e,function(e){if(e instanceof t||e instanceof Layer)return new e.clone})).if&&(this.set("if",e.if),delete e.if),e){var r=e[n];null!=r&&(n.match(De)?"$attr"!==n&&this.set("variable",n,r):this.set(n,r))}return this}},{key:"fromTransformation",value:function(e){var n=this;return e instanceof t&&e.keys().forEach(function(t){return n.set(t,e.get(t).origValue)}),this}},{key:"set",value:function(t){var e;e=$(t);for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return _()(Ce.methods,e)?this[e].apply(this,r):this.otherOptions[t]=r[0],this}},{key:"hasLayer",value:function(){return this.getValue("overlay")||this.getValue("underlay")}},{key:"serialize",value:function(){var t,e,n,r,o,i,u,a,s,c,l,f,p,d,v,m,g;for(c=this.chained.map(function(t){return t.serialize()}),r=this.keys(),d=null!=(o=this.get("transformation"))?o.serialize():void 0,t=null!=(i=this.get("if"))?i.serialize():void 0,m=function(t){var e,n,r,o,i;if(k()(t)){for(o=[],e=0,n=t.length;e<n;e++){var u=be(t[e],2);r=u[0],i=u[1],o.push("".concat(r,"_").concat(Ot.normalize(i)))}return o}return t}(null!=(u=this.get("variables"))?u.value():void 0),r=y()(r,["transformation","if","variables"]),g=[],f=[],e=0,n=r.length;e<n;e++)(l=r[e]).match(De)?g.push(l+"_"+Ot.normalize(null!=(a=this.get(l))?a.value():void 0)):f.push(null!=(s=this.get(l))?s.serialize():void 0);switch(!1){case!E()(d):f.push(d);break;case!k()(d):c=c.concat(d)}return f=function(){var t,e,n;for(n=[],t=0,e=f.length;t<e;t++)v=f[t],(k()(v)&&!rt(v)||!k()(v)&&v)&&n.push(v);return n}(),f=g.sort().concat(m).concat(f.sort()),"if_end"===t?f.push(t):rt(t)||f.unshift(t),rt(p=h()(f).join(this.param_separator))||c.push(p),h()(c).join(this.trans_separator)}},{key:"listNames",value:function(){return Ce.methods}},{key:"toHtmlAttributes",value:function(){var t,e,n,r,o,i,u,a,s=this;for(n in r={},this.otherOptions)u=this.otherOptions[n],_()(Ce.PARAM_NAMES,Q(n))||(t=/^html_/.test(n)?n.slice(5):n,r[t]=u);return this.keys().forEach(function(t){/^html_/.test(t)&&(r[$(t.slice(5))]=s.getValue(t))}),this.hasLayer()||this.getValue("angle")||_()(["fit","limit","lfill"],this.getValue("crop"))||(a=null!=(o=this.get("width"))?o.origValue:void 0,e=null!=(i=this.get("height"))?i.origValue:void 0,parseFloat(a)>=1&&null==r.width&&(r.width=a),parseFloat(e)>=1&&null==r.height&&(r.height=e)),r}},{key:"isValidParamName",value:function(t){return Ce.methods.indexOf($(t))>=0}},{key:"toHtml",value:function(){var t;return null!=(t=this.getParent())&&"function"==typeof t.toHtml?t.toHtml():void 0}},{key:"toString",value:function(){return this.serialize()}},{key:"clone",value:function(){return new this.constructor(this.toOptions(!0))}}]),t}(),De=/^\$[a-zA-Z0-9]+$/;function Ee(t){var e;return e=null!=t?t[t.length-1]:void 0,j(e)?e:void 0}Ae.prototype.trans_separator="/",Ae.prototype.param_separator=",";var Ce=function(t){function Transformation(t){return _e(this,Transformation),ve(this,me(Transformation).call(this,t))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ge(t,e)}(Transformation,Ae),ke(Transformation,[{key:"angle",value:function(t){return this.arrayParam(t,"angle","a",".",Ot.normalize)}},{key:"audioCodec",value:function(t){return this.param(t,"audio_codec","ac")}},{key:"audioFrequency",value:function(t){return this.param(t,"audio_frequency","af")}},{key:"aspectRatio",value:function(t){return this.param(t,"aspect_ratio","ar",Ot.normalize)}},{key:"background",value:function(t){return this.param(t,"background","b",ce.norm_color)}},{key:"bitRate",value:function(t){return this.param(t,"bit_rate","br")}},{key:"border",value:function(t){return this.param(t,"border","bo",function(t){return A()(t)?(t=s()({},{color:"black",width:2},t),"".concat(t.width,"px_solid_").concat(ce.norm_color(t.color))):t})}},{key:"color",value:function(t){return this.param(t,"color","co",ce.norm_color)}},{key:"colorSpace",value:function(t){return this.param(t,"color_space","cs")}},{key:"crop",value:function(t){return this.param(t,"crop","c")}},{key:"defaultImage",value:function(t){return this.param(t,"default_image","d")}},{key:"delay",value:function(t){return this.param(t,"delay","dl")}},{key:"density",value:function(t){return this.param(t,"density","dn")}},{key:"duration",value:function(t){return this.rangeParam(t,"duration","du")}},{key:"dpr",value:function(t){return this.param(t,"dpr","dpr",function(t){return(null!=(t=t.toString())?t.match(/^\d+$/):void 0)?t+".0":Ot.normalize(t)})}},{key:"effect",value:function(t){return this.arrayParam(t,"effect","e",":",Ot.normalize)}},{key:"else",value:function(){return this.if("else")}},{key:"endIf",value:function(){return this.if("end")}},{key:"endOffset",value:function(t){return this.rangeParam(t,"end_offset","eo")}},{key:"fallbackContent",value:function(t){return this.param(t,"fallback_content")}},{key:"fetchFormat",value:function(t){return this.param(t,"fetch_format","f")}},{key:"format",value:function(t){return this.param(t,"format")}},{key:"flags",value:function(t){return this.arrayParam(t,"flags","fl",".")}},{key:"gravity",value:function(t){return this.param(t,"gravity","g")}},{key:"fps",value:function(t){return this.param(t,"fps","fps",function(t){return E()(t)?t:k()(t)?t.join("-"):t})}},{key:"height",value:function(t){var e=this;return this.param(t,"height","h",function(){return e.getValue("crop")||e.getValue("overlay")||e.getValue("underlay")?Ot.normalize(t):null})}},{key:"htmlHeight",value:function(t){return this.param(t,"html_height")}},{key:"htmlWidth",value:function(t){return this.param(t,"html_width")}},{key:"if",value:function(){var t,e,n,r,o,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";switch(i){case"else":return this.chain(),this.param(i,"if","if");case"end":for(this.chain(),t=n=this.chained.length-1;n>=0&&"end"!==(e=this.chained[t].getValue("if"))&&(null==e||(r=Transformation.new().if(e),this.chained[t].remove("if"),o=this.chained[t],this.chained[t]=Transformation.new().transformation([r,o]),"else"===e));t=n+=-1);return this.param(i,"if","if");case"":return Bt.new().setParent(this);default:return this.param(i,"if","if",function(t){return Bt.new(t).toString()})}}},{key:"keyframeInterval",value:function(t){return this.param(t,"keyframe_interval","ki")}},{key:"offset",value:function(t){var e,n,r=be(j(null!=t?t.split:void 0)?t.split(".."):k()(t)?t:[null,null],2);if(n=r[0],e=r[1],null!=n&&this.startOffset(n),null!=e)return this.endOffset(e)}},{key:"opacity",value:function(t){return this.param(t,"opacity","o",Ot.normalize)}},{key:"overlay",value:function(t){return this.layerParam(t,"overlay","l")}},{key:"page",value:function(t){return this.param(t,"page","pg")}},{key:"poster",value:function(t){return this.param(t,"poster")}},{key:"prefix",value:function(t){return this.param(t,"prefix","p")}},{key:"quality",value:function(t){return this.param(t,"quality","q",Ot.normalize)}},{key:"radius",value:function(t){return this.arrayParam(t,"radius","r",":",Ot.normalize)}},{key:"rawTransformation",value:function(t){return this.rawParam(t,"raw_transformation")}},{key:"size",value:function(t){var e,n;if(j(null!=t?t.split:void 0)){var r=be(t.split("x"),2);return n=r[0],e=r[1],this.width(n),this.height(e)}}},{key:"sourceTypes",value:function(t){return this.param(t,"source_types")}},{key:"sourceTransformation",value:function(t){return this.param(t,"source_transformation")}},{key:"startOffset",value:function(t){return this.rangeParam(t,"start_offset","so")}},{key:"streamingProfile",value:function(t){return this.param(t,"streaming_profile","sp")}},{key:"transformation",value:function(t){return this.transformationParam(t,"transformation","t")}},{key:"underlay",value:function(t){return this.layerParam(t,"underlay","u")}},{key:"variable",value:function(t,e){return this.param(e,t,t)}},{key:"variables",value:function(t){return this.arrayParam(t,"variables")}},{key:"videoCodec",value:function(t){return this.param(t,"video_codec","vc",ce.process_video_params)}},{key:"videoSampling",value:function(t){return this.param(t,"video_sampling","vs")}},{key:"width",value:function(t){var e=this;return this.param(t,"width","w",function(){return e.getValue("crop")||e.getValue("overlay")||e.getValue("underlay")?Ot.normalize(t):null})}},{key:"customFunction",value:function(t){return this.param(t,"custom_function","fn",function(){return"remote"===t.function_type?[t.function_type,btoa(t.source)].join(":"):"wasm"===t.function_type?[t.function_type,t.source].join(":"):void 0})}},{key:"x",value:function(t){return this.param(t,"x","x",Ot.normalize)}},{key:"y",value:function(t){return this.param(t,"y","y",Ot.normalize)}},{key:"zoom",value:function(t){return this.param(t,"zoom","z",Ot.normalize)}}],[{key:"new",value:function(t){return new Transformation(t)}}]),Transformation}();Ce.methods=["angle","audioCodec","audioFrequency","aspectRatio","background","bitRate","border","color","colorSpace","crop","customFunction","defaultImage","delay","density","duration","dpr","effect","else","endIf","endOffset","fallbackContent","fetchFormat","format","flags","gravity","fps","height","htmlHeight","htmlWidth","if","keyframeInterval","offset","opacity","overlay","page","poster","prefix","quality","radius","rawTransformation","size","sourceTypes","sourceTransformation","startOffset","streamingProfile","transformation","underlay","variable","variables","videoCodec","videoSampling","width","x","y","zoom"],Ce.PARAM_NAMES=Ce.methods.map(Q).concat(Tt.CONFIG_PARAMS);var Se=Ce;function Be(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function je(t,e){return e?!0===e?t:"".concat(t,'="').concat(e,'"'):void 0}function Fe(t){return E()(t)?t.replace('"',"&#34;").replace("'","&#39;"):t}var Pe=function(){function HtmlTag(t,e,n){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,HtmlTag),this.name=t,this.publicId=e,null==n&&(A()(e)?(n=e,this.publicId=void 0):n={}),(r=new Se(n)).setParent(this),this.transformation=function(){return r}}var t,e,n;return t=HtmlTag,n=[{key:"new",value:function(t,e,n){return new this(t,e,n)}},{key:"isResponsive",value:function(t,e){var n;return n=ot(t,"src-cache")||ot(t,"src"),lt(t,e)&&/\bw_auto\b/.exec(n)}}],(e=[{key:"htmlAttrs",value:function(t){var e,n;return function(){var r;for(e in r=[],t)(n=Fe(t[e]))&&r.push(je(e,n));return r}().sort().join(" ")}},{key:"getOptions",value:function(){return this.transformation().toOptions()}},{key:"getOption",value:function(t){return this.transformation().getValue(t)}},{key:"attributes",value:function(){var t=this.transformation().toHtmlAttributes();return Object.keys(t).forEach(function(e){A()(t[e])&&delete t[e]}),t.attributes&&(S()(t,t.attributes),delete t.attributes),t}},{key:"setAttr",value:function(t,e){return this.transformation().set("html_".concat(t),e),this}},{key:"getAttr",value:function(t){return this.attributes()["html_".concat(t)]||this.attributes()[t]}},{key:"removeAttr",value:function(t){var e;return null!=(e=this.transformation().remove("html_".concat(t)))?e:this.transformation().remove(t)}},{key:"content",value:function(){return""}},{key:"openTag",value:function(){var t="<"+this.name,e=this.htmlAttrs(this.attributes());return e&&e.length>0&&(t+=" "+e),t+">"}},{key:"closeTag",value:function(){return"</".concat(this.name,">")}},{key:"toHtml",value:function(){return this.openTag()+this.content()+this.closeTag()}},{key:"toDOM",value:function(){var t,e,n,r;if(!j("undefined"!=typeof document&&null!==document?document.createElement:void 0))throw"Can't create DOM if document is not present!";for(e in t=document.createElement(this.name),n=this.attributes())r=n[e],t.setAttribute(e,r);return t}}])&&Be(t.prototype,e),n&&Be(t,n),HtmlTag}(),xe="2.5.0",Te="d3jpl91pxevbkh.cloudfront.net",Re="cloudinary-a.akamaihd.net",ze="res.cloudinary.com",Ie=ze,Ve={format:"jpg",resource_type:"video"},Ne=["webm","mp4","ogv"],qe={"image/upload":"images","image/private":"private_images","image/authenticated":"authenticated_images","raw/upload":"files","video/upload":"videos"},Le={resource_type:"image",transformation:[],type:"upload"},He={fallback_content:"",resource_type:"video",source_transformation:{},source_types:Ne,transformation:[],type:"upload"},Me=[{type:"mp4",codecs:"hev1",transformations:{video_codec:"h265"}},{type:"webm",codecs:"vp9",transformations:{video_codec:"vp9"}},{type:"mp4",transformations:{video_codec:"auto"}},{type:"webm",transformations:{video_codec:"auto"}}];function Ue(t,e){if(e.cloud_name&&"/"===e.cloud_name[0])return"/res"+e.cloud_name;var n="http://",r="",o="res",i=".cloudinary.com",a="/"+e.cloud_name;return e.protocol&&(n=e.protocol+"//"),e.private_cdn&&(r=e.cloud_name+"-",a=""),e.cdn_subdomain&&(o="res-"+function(t){return u(t)%5+1}(t)),e.secure?(n="https://",!1===e.secure_cdn_subdomain&&(o="res"),null!=e.secure_distribution&&e.secure_distribution!==Re&&e.secure_distribution!==Ie&&(r="",o="",i=e.secure_distribution)):e.cname&&(n="http://",r="",o=e.cdn_subdomain?"a"+(u(t)%5+1)+".":"",i=e.cname),[n,r,o,i,a].join("")}function We(t){var e,n,r,o,i,u,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!t)return t;if(a instanceof Se&&(a=a.toOptions()),"fetch"===(a=N({},a,s,Le)).type&&(a.fetch_format=a.fetch_format||a.format,t=function(t){var e;return t.match(/^https?:\//)||(e=document.location.protocol+"//"+document.location.host,"?"===t[0]?e+=document.location.pathname:"/"!==t[0]&&(e+=document.location.pathname.replace(/\/[^\/]*$/,"/")),t=e+t),t}(t)),o=new Se(a).serialize(),!a.cloud_name)throw"Unknown cloud_name";if(!a.force_version&&void 0!==a.force_version||!(t.search("/")>=0)||t.match(/^v[0-9]+/)||t.match(/^https?:\//)||(null!=(n=a.version)?n.toString():void 0)||(a.version=1),t.match(/^https?:/))"upload"===a.type||"asset"===a.type?i=t:t=encodeURIComponent(t).replace(/%3A/g,":").replace(/%2F/g,"/");else{try{t=decodeURIComponent(t)}catch(c){c}if(t=encodeURIComponent(t).replace(/%3A/g,":").replace(/%2F/g,"/"),a.url_suffix){if(a.url_suffix.match(/[\.\/]/))throw"url_suffix should not include . or /";t=t+"/"+a.url_suffix}a.format&&(a.trust_public_id||(t=t.replace(/\.(jpg|png|gif|webp)$/,"")),t=t+"."+a.format)}return e=Ue(t,a),r=function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"image",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"upload",r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;if(e=null==e?"image":e,n=null==n?"upload":n,A()(e)&&(e=(t=e).resource_type,n=t.type,r=t.url_suffix,o=t.use_root_path,i=t.shorten),null==n&&(n="upload"),null!=r&&(e=qe["".concat(e,"/").concat(n)],n=null,null==e))throw new Error("URL Suffix only supported for ".concat(Object.keys(qe).join(", ")));if(o){if(("image"!==e||"upload"!==n)&&"images"!==e)throw new Error("Root path only supported for image/upload");e=null,n=null}return i&&"image"===e&&"upload"===n&&(e="iu",n=null),[e,n].join("/")}(a.resource_type,a.type,a.url_suffix,a.use_root_path,a.shorten),u=a.version?"v"+a.version:"",i||h()([e,r,o,u,t]).join("/").replace(/([^:])\/+/g,"$1/")}function $e(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var u,a=t[Symbol.iterator]();!(r=(u=a.next()).done)&&(n.push(u.value),!e||n.length!==e);r=!0);}catch(s){o=!0,i=s}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}var Qe=rt;function Ye(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=tt(r);return n=n||r,o.raw_transformation=new Se([S.a({},n),{crop:"scale",width:e}]).toString(),We(t,o)}function Ze(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(t){var e=t.breakpoints||[];if(e.length)return e;var n=$e([t.min_width,t.max_width,t.max_images].map(Number),3),r=n[0],o=n[1],i=n[2];if([r,o,i].some(isNaN))throw"Either (min_width, max_width, max_images) or breakpoints must be provided to the image srcset attribute";if(r>o)throw"min_width must be less than max_width";if(i<=0)throw"max_images must be a positive integer";1===i&&(r=o);for(var u=Math.ceil((o-r)/Math.max(i-1,1)),a=r;a<o;a+=u)e.push(a);return e.push(o),e}(e)}function Ke(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o={};if(Qe(n))return o;var i=!e.sizes&&!0===n.sizes,u=!e.srcset;if(u||i){var a=Ze(t,n,r);if(u){var s=function(t,e,n,r){return et(r=l.a(r)),e.map(function(e){return"".concat(Ye(t,e,n,r)," ").concat(e,"w")}).join(", ")}(t,a,n.transformation,r);Qe(s)||(o.srcset=s)}if(i){var c=function(t){return null==t?"":t.map(function(t){return"(max-width: ".concat(t,"px) ").concat(t,"px")}).join(", ")}(a);Qe(c)||(o.sizes=c)}}return o}function Ge(t){return(Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function Xe(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function Je(t,e){return!e||"object"!==Ge(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function tn(t,e,n){return(tn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=en(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}function en(t){return(en=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function nn(t,e){return(nn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var rn=function(t){function ImageTag(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,ImageTag),Je(this,en(ImageTag).call(this,"img",t,e))}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&nn(t,e)}(ImageTag,Pe),e=ImageTag,(n=[{key:"closeTag",value:function(){return""}},{key:"attributes",value:function(){var t,e,n;t=tn(en(ImageTag.prototype),"attributes",this).call(this)||{},e=this.getOptions();var r=this.getOption("srcset"),o=this.getOption("attributes")||{},i={};return E()(r)?i.srcset=r:i=Ke(this.publicId,o,r,e),rt(i)||(delete e.width,delete e.height),S()(t,i),null==t[n=e.responsive&&!e.client_hints?"data-src":"src"]&&(t[n]=We(this.publicId,this.getOptions())),t}}])&&Xe(e.prototype,n),r&&Xe(e,r),ImageTag}();function on(t){return(on="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function un(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function an(t,e){return!e||"object"!==on(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function sn(t,e,n){return(sn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=cn(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}function cn(t){return(cn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ln(t,e){return(ln=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var fn=function(t){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),an(this,cn(e).call(this,"source",t,n))}var n,r,o;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ln(t,e)}(e,Pe),n=e,(r=[{key:"closeTag",value:function(){return""}},{key:"attributes",value:function(){var t=this.getOption("srcset"),n=sn(cn(e.prototype),"attributes",this).call(this)||{},r=this.getOptions();return S()(n,Ke(this.publicId,n,t,r)),n.srcset||(n.srcset=We(this.publicId,r)),!n.media&&r.media&&(n.media=function(t){var e=[];return null!=t&&(null!=t.min_width&&e.push("(min-width: ".concat(t.min_width,"px)")),null!=t.max_width&&e.push("(max-width: ".concat(t.max_width,"px)"))),e.join(" and ")}(r.media)),n}}])&&un(n.prototype,r),o&&un(n,o),e}();function hn(t){return(hn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function pn(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function yn(t,e){return!e||"object"!==hn(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function dn(t,e,n){return(dn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=vn(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}function vn(t){return(vn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function mn(t,e){return(mn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var gn=function(t){function PictureTag(t){var e,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,PictureTag),(e=yn(this,vn(PictureTag).call(this,"picture",t,n))).widthList=r,e}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&mn(t,e)}(PictureTag,Pe),e=PictureTag,(n=[{key:"content",value:function(){var t=this;return this.widthList.map(function(e){var n=e.min_width,r=e.max_width,o=e.transformation,i=t.getOptions(),u=new Se(i);return u.chain().fromOptions("string"==typeof o?{raw_transformation:o}:o),(i=tt(i)).media={min_width:n,max_width:r},i.transformation=u,new fn(t.publicId,i).toHtml()}).join("")+new rn(this.publicId,this.getOptions()).toHtml()}},{key:"attributes",value:function(){var t=dn(vn(PictureTag.prototype),"attributes",this).call(this);return delete t.width,delete t.height,t}},{key:"closeTag",value:function(){return"</"+this.name+">"}}])&&pn(e.prototype,n),r&&pn(e,r),PictureTag}();function bn(t){return(bn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function _n(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function wn(t,e){return!e||"object"!==bn(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function kn(t,e,n){return(kn="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=On(t)););return t}(t,e);if(r){var o=Object.getOwnPropertyDescriptor(r,e);return o.get?o.get.call(n):o.value}})(t,e,n||t)}function On(t){return(On=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function An(t,e){return(An=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Dn=["source_types","source_transformation","fallback_content","poster","sources"],En=["webm","mp4","ogv"],Cn={format:"jpg",resource_type:"video"},Sn=function(t){function VideoTag(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,VideoTag),e=N({},e,He),wn(this,On(VideoTag).call(this,"video",t.replace(/\.(mp4|ogv|webm)$/,""),e))}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&An(t,e)}(VideoTag,Pe),e=VideoTag,(n=[{key:"setSourceTransformation",value:function(t){return this.transformation().sourceTransformation(t),this}},{key:"setSourceTypes",value:function(t){return this.transformation().sourceTypes(t),this}},{key:"setPoster",value:function(t){return this.transformation().poster(t),this}},{key:"setFallbackContent",value:function(t){return this.transformation().fallbackContent(t),this}},{key:"content",value:function(){var t=this,e=this.transformation().getValue("source_types"),n=this.transformation().getValue("source_transformation"),r=this.transformation().getValue("fallback_content"),o=this.getOption("sources"),i=[];return k()(o)&&!rt(o)?i=o.map(function(e){var n=We(t.publicId,N({},e.transformations||{},{resource_type:"video",format:e.type}),t.getOptions());return t.createSourceTag(n,e.type,e.codecs)}):(rt(e)&&(e=En),k()(e)&&(i=e.map(function(e){var r=We(t.publicId,N({},n[e]||{},{resource_type:"video",format:e}),t.getOptions());return t.createSourceTag(r,e)}))),i.join("")+r}},{key:"attributes",value:function(){var t=this.getOption("source_types"),e=this.getOption("poster");if(void 0===e&&(e={}),A()(e)){var n=null!=e.public_id?Le:Cn;e=We(e.public_id||this.publicId,N({},e,n,this.getOptions()))}var r=kn(On(VideoTag.prototype),"attributes",this).call(this)||{};return r=x(r,Dn),!rt(this.getOption("sources"))||rt(t)||k()(t)||(r.src=We(this.publicId,this.getOptions(),{resource_type:"video",format:t})),null!=e&&(r.poster=e),r}},{key:"createSourceTag",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=null;if(!rt(e)){var o="ogv"===e?"ogg":e;if(r="video/"+o,!rt(n)){var i=k()(n)?n.join(", "):n;r+="; codecs="+i}}return"<source "+this.htmlAttrs({src:t,type:r})+">"}}])&&_n(e.prototype,n),r&&_n(e,r),VideoTag}();function Bn(t){return(Bn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function jn(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function Fn(t,e){return!e||"object"!==Bn(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Pn(t){return(Pn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function xn(t,e){return(xn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Tn,Rn,zn,In,Vn,Nn,qn=function(t){function ClientHintsMetaTag(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,ClientHintsMetaTag),Fn(this,Pn(ClientHintsMetaTag).call(this,"meta",void 0,s()({"http-equiv":"Accept-CH",content:"DPR, Viewport-Width, Width"},t)))}var e,n,r;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&xn(t,e)}(ClientHintsMetaTag,Pe),e=ClientHintsMetaTag,(n=[{key:"closeTag",value:function(){return""}}])&&jn(e.prototype,n),r&&jn(e,r),ClientHintsMetaTag}();function Ln(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}zn=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100;return e*Math.ceil(t/e)},Rn=function(t,e){var n;for(n=t.length-2;n>=0&&t[n]>=e;)n--;return t[n+1]},Tn=function(t,e,n,r){var o,i,u,a;return!(a=null!=(o=null!=(i=null!=(u=r.responsive_use_breakpoints)?u:r.responsive_use_stoppoints)?i:this.config("responsive_use_breakpoints"))?o:this.config("responsive_use_stoppoints"))||"resize"===a&&!r.resizing?e:this.calc_breakpoint(t,e,n)},In=function(t){var e,n;for(e=0;(t=null!=t?t.parentNode:void 0)instanceof Element&&!e;)n=window.getComputedStyle(t),/^inline/.test(n.display)||(e=_t(t));return e},Nn=function(t,e){return t.replace(/\bdpr_(1\.0|auto)\b/g,"dpr_"+this.device_pixel_ratio(e))},Vn=function(t,e){var n;return t>(n=ot(e,"width")||0)&&(n=t,it(e,"width",t)),n};var Hn=function(){function Cloudinary(t){var e;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,Cloudinary),this.devicePixelRatioCache={},this.responsiveConfig={},this.responsiveResizeInitialized=!1,e=new Tt(t),this.config=function(t,n){return e.config(t,n)},this.fromDocument=function(){return e.fromDocument(),this},this.fromEnvironment=function(){return e.fromEnvironment(),this},this.init=function(){return e.init(),this}}var t,e,n;return t=Cloudinary,n=[{key:"new",value:function(t){return new this(t)}}],(e=[{key:"url",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return We(t,e,this.config())}},{key:"video_url",value:function(t,e){return e=s()({resource_type:"video"},e),this.url(t,e)}},{key:"video_thumbnail_url",value:function(t,e){return e=s()({},Ve,e),this.url(t,e)}},{key:"transformation_string",value:function(t){return new Se(t).serialize()}},{key:"image",value:function(t){var e,n,r,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return n=this.imageTag(t,o),e=null!=(r=null!=o.client_hints?o.client_hints:this.config("client_hints"))&&r,null!=o.src||e||n.setAttr("src",""),n=n.toDOM(),e||(it(n,"src-cache",this.url(t,o)),this.cloudinary_update(n,o)),n}},{key:"imageTag",value:function(t,e){var n;return(n=new rn(t,this.config())).transformation().fromOptions(e),n}},{key:"pictureTag",value:function(t,e){var n;return(n=new gn(t,this.config())).transformation().fromOptions(e),n}},{key:"sourceTag",value:function(t,e){var n;return(n=new fn(t,this.config())).transformation().fromOptions(e),n}},{key:"video_thumbnail",value:function(t,e){return this.image(t,S()({},Ve,e))}},{key:"facebook_profile_image",value:function(t,e){return this.image(t,s()({type:"facebook"},e))}},{key:"twitter_profile_image",value:function(t,e){return this.image(t,s()({type:"twitter"},e))}},{key:"twitter_name_profile_image",value:function(t,e){return this.image(t,s()({type:"twitter_name"},e))}},{key:"gravatar_image",value:function(t,e){return this.image(t,s()({type:"gravatar"},e))}},{key:"fetch_image",value:function(t,e){return this.image(t,s()({type:"fetch"},e))}},{key:"video",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.videoTag(t,e).toHtml()}},{key:"videoTag",value:function(t,e){return e=N({},e,this.config()),new Sn(t,e)}},{key:"sprite_css",value:function(t,e){return e=s()({type:"sprite"},e),t.match(/.css$/)||(e.format="css"),this.url(t,e)}},{key:"responsive",value:function(t){var e,n,r,o,i,u=this,a=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(this.responsiveConfig=S()(this.responsiveConfig||{},t),o=null!=(e=this.responsiveConfig.responsive_class)?e:this.config("responsive_class"),a&&this.cloudinary_update("img.".concat(o,", img.cld-hidpi"),this.responsiveConfig),(null==(n=null!=(r=this.responsiveConfig.responsive_resize)?r:this.config("responsive_resize"))||n)&&!this.responsiveResizeInitialized)return this.responsiveConfig.resizing=this.responsiveResizeInitialized=!0,i=null,window.addEventListener("resize",function(){var t,e,n,r,a,s;return t=null!=(e=null!=(n=u.responsiveConfig.responsive_debounce)?n:u.config("responsive_debounce"))?e:100,r=function(){if(i)return clearTimeout(i),i=null},a=function(){return u.cloudinary_update("img.".concat(o),u.responsiveConfig)},s=function(){return r(),a()},t?function(){return r(),i=setTimeout(s,t)}():a()})}},{key:"calc_breakpoint",value:function(t,e,n){var r=ot(t,"breakpoints")||ot(t,"stoppoints")||this.config("breakpoints")||this.config("stoppoints")||zn;return j(r)?r(e,n):(E()(r)&&(r=r.split(",").map(function(t){return parseInt(t)}).sort(function(t,e){return t-e})),Rn(r,e))}},{key:"calc_stoppoint",value:function(t,e,n){return this.calc_breakpoint(t,e,n)}},{key:"device_pixel_ratio",value:function(t){t=null==t||t;var e=("undefined"!=typeof window&&null!==window?window.devicePixelRatio:void 0)||1;t&&(e=Math.ceil(e)),(e<=0||NaN===e)&&(e=1);var n=e.toString();return n.match(/^\d+$/)&&(n+=".0"),n}},{key:"processImageTags",value:function(t,e){if(rt(t))return this;e=N({},e||{},this.config());var n=t.filter(function(t){return/^img$/i.test(t.tagName)}).map(function(t){var n=s()({width:t.getAttribute("width"),height:t.getAttribute("height"),src:t.getAttribute("src")},e),r=n.source||n.src;delete n.source,delete n.src;var o=new Se(n).toHtmlAttributes();return it(t,"src-cache",We(r,n)),t.setAttribute("width",o.width),t.setAttribute("height",o.height),t});return this.cloudinary_update(n,e),this}},{key:"cloudinary_update",value:function(t,e){var n,r,o,i,u=this;if(null===t)return this;null==e&&(e={});var a,s=null!=e.responsive?e.responsive:this.config("responsive");t=function(){switch(!1){case!k()(t):case"NodeList"!==t.constructor.name:return t;case!E()(t):return document.querySelectorAll(t);default:return[t]}}(),a=this.responsiveConfig&&null!=this.responsiveConfig.responsive_class?this.responsiveConfig.responsive_class:null!=e.responsive_class?e.responsive_class:this.config("responsive_class");var c=null!=e.round_dpr?e.round_dpr:this.config("round_dpr");return t.forEach(function(t){if(/img/i.test(t.tagName)){var l=!0;if(s&&ft(t,a),!rt(r=ot(t,"src-cache")||ot(t,"src"))){if(r=Nn.call(u,r,c),Pe.isResponsive(t,a))if(0!==(n=In(t))){switch(!1){case!/w_auto:breakpoints/.test(r):i=Vn(n,t),r=r.replace(/w_auto:breakpoints([_0-9]*)(:[0-9]+)?/,"w_auto:breakpoints$1:".concat(i));break;case!(o=/w_auto(:(\d+))?/.exec(r)):i=Tn.call(u,t,n,o[2],e),i=Vn(i,t),r=r.replace(/w_auto[^,\/]*/g,"w_".concat(i))}st(t,"width"),e.responsive_preserve_height||st(t,"height")}else l=!1;l&&at(t,"src",r)}}}),this}},{key:"transformation",value:function(t){return Se.new(this.config()).fromOptions(t).setParent(this)}}])&&Ln(t.prototype,e),n&&Ln(t,n),Cloudinary}();s()(Hn,o);var Mn=Hn;n.d(e,"ClientHintsMetaTag",function(){return qn}),n.d(e,"Cloudinary",function(){return Mn}),n.d(e,"Condition",function(){return Bt}),n.d(e,"Configuration",function(){return Tt}),n.d(e,"crc32",function(){return u}),n.d(e,"FetchLayer",function(){return Jt}),n.d(e,"HtmlTag",function(){return Pe}),n.d(e,"ImageTag",function(){return rn}),n.d(e,"Layer",function(){return zt}),n.d(e,"PictureTag",function(){return gn}),n.d(e,"SubtitlesLayer",function(){return Qt}),n.d(e,"TextLayer",function(){return Ht}),n.d(e,"Transformation",function(){return Se}),n.d(e,"utf8_encode",function(){return i}),n.d(e,"Util",function(){return r}),n.d(e,"VideoTag",function(){return Sn});e.default={ClientHintsMetaTag:qn,Cloudinary:Mn,Condition:Bt,Configuration:Tt,crc32:u,FetchLayer:Jt,HtmlTag:Pe,ImageTag:rn,Layer:zt,PictureTag:gn,SubtitlesLayer:Qt,TextLayer:Ht,Transformation:Se,utf8_encode:i,Util:r,VideoTag:Sn}},"lodash/assign":function(e,n){e.exports=t},"lodash/cloneDeep":function(t,n){t.exports=e},"lodash/compact":function(t,e){t.exports=n},"lodash/difference":function(t,e){t.exports=r},"lodash/functions":function(t,e){t.exports=o},"lodash/identity":function(t,e){t.exports=i},"lodash/includes":function(t,e){t.exports=u},"lodash/isArray":function(t,e){t.exports=a},"lodash/isElement":function(t,e){t.exports=s},"lodash/isFunction":function(t,e){t.exports=c},"lodash/isPlainObject":function(t,e){t.exports=l},"lodash/isString":function(t,e){t.exports=f},"lodash/merge":function(t,e){t.exports=h},"lodash/trim":function(t,e){t.exports=p}})});