1 2 if (!window._bubble_page_load_data) { 3 window._bubble_page_load_data = {} 4 } 5 if (!window._bubble_page_load_data.js_execution_timings) { 6 window._bubble_page_load_data.js_execution_timings = {} 7 } 8 window._bubble_page_load_data.js_execution_timings.static_js_start_execution = Date.now(); 9window.preloaded = window.preloaded || {}; 10window['bubble_run_derived'] = window['bubble_run_derived'] || {} 11window['bubble_run_derived']['{"function_name":"Responsive","args":["%p3.bTGba",true]}'] = {} 12window.preloaded['app/derived:{"function_name":"Responsive","args":["%p3.bTGba",true]}'] = true; 13/*! jQuery Migrate v3.4.1 | (c) OpenJS Foundation and other contributors | jquery.org/license */ 14// BUBBLE PATCH NOTES - offset() changed below, see comment 15"undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=true),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],function(e){return t(e,window)}):"object"==typeof module&&module.exports?module.exports=t(require("jquery"),window):t(jQuery,window)}(function(s,n){"use strict";function e(e){return 0<=function(e,t){for(var r=/^(\d+)\.(\d+)\.(\d+)/,n=r.exec(e)||[],o=r.exec(t)||[],a=1;a<=3;a++){if(+o[a]<+n[a])return 1;if(+n[a]<+o[a])return-1}return 0}(s.fn.jquery,e)}s.migrateVersion="3.4.1";var t=Object.create(null);s.migrateDisablePatches=function(){for(var e=0;e<arguments.length;e++)t[arguments[e]]=!0},s.migrateEnablePatches=function(){for(var e=0;e<arguments.length;e++)delete t[arguments[e]]},s.migrateIsPatchEnabled=function(e){return!t[e]},n.console&&n.console.log&&(s&&e("3.0.0")&&!e("5.0.0")||n.console.log("JQMIGRATE: jQuery 3.x-4.x REQUIRED"),s.migrateWarnings&&n.console.log("JQMIGRATE: Migrate plugin loaded multiple times"),n.console.log("JQMIGRATE: Migrate is installed"+(s.migrateMute?"":" with logging active")+", version "+s.migrateVersion));var o={};function u(e,t){var r=n.console;!s.migrateIsPatchEnabled(e)||s.migrateDeduplicateWarnings&&o[t]||(o[t]=!0,s.migrateWarnings.push(t+" ["+e+"]"),r&&r.warn&&!s.migrateMute&&(r.warn("JQMIGRATE: "+t),s.migrateTrace&&r.trace&&r.trace()))}function r(e,t,r,n,o){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return u(n,o),r},set:function(e){u(n,o),r=e}})}function a(e,t,r,n,o){var a=e[t];e[t]=function(){return o&&u(n,o),(s.migrateIsPatchEnabled(n)?r:a||s.noop).apply(this,arguments)}}function c(e,t,r,n,o){if(!o)throw new Error("No warning message provided");return a(e,t,r,n,o),0}function i(e,t,r,n){return a(e,t,r,n),0}s.migrateDeduplicateWarnings=!0,s.migrateWarnings=[],void 0===s.migrateTrace&&(s.migrateTrace=!0),s.migrateReset=function(){o={},s.migrateWarnings.length=0},"BackCompat"===n.document.compatMode&&u("quirks","jQuery is not compatible with Quirks Mode");var d,l,p,f={},m=s.fn.init,y=s.find,h=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/,g=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/g,v=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;for(d in i(s.fn,"init",function(e){var t=Array.prototype.slice.call(arguments);return s.migrateIsPatchEnabled("selector-empty-id")&&"string"==typeof e&&"#"===e&&(u("selector-empty-id","jQuery( '#' ) is not a valid selector"),t[0]=[]),m.apply(this,t)},"selector-empty-id"),s.fn.init.prototype=s.fn,i(s,"find",function(t){var r=Array.prototype.slice.call(arguments);if("string"==typeof t&&h.test(t))try{n.document.querySelector(t)}catch(e){t=t.replace(g,function(e,t,r,n){return"["+t+r+'"'+n+'"]'});try{n.document.querySelector(t),u("selector-hash","Attribute selector with '#' must be quoted: "+r[0]),r[0]=t}catch(e){u("selector-hash","Attribute selector with '#' was not fixed: "+r[0])}}return y.apply(this,r)},"selector-hash"),y)Object.prototype.hasOwnProperty.call(y,d)&&(s.find[d]=y[d]);c(s.fn,"size",function(){return this.length},"size","jQuery.fn.size() is deprecated and removed; use the .length property"),c(s,"parseJSON",function(){return JSON.parse.apply(null,arguments)},"parseJSON","jQuery.parseJSON is deprecated; use JSON.parse"),c(s,"holdReady",s.holdReady,"holdReady","jQuery.holdReady is deprecated"),c(s,"unique",s.uniqueSort,"unique","jQuery.unique is deprecated; use jQuery.uniqueSort"),r(s.expr,"filters",s.expr.pseudos,"expr-pre-pseudos","jQuery.expr.filters is deprecated; use jQuery.expr.pseudos"),r(s.expr,":",s.expr.pseudos,"expr-pre-pseudos","jQuery.expr[':'] is deprecated; use jQuery.expr.pseudos"),e("3.1.1")&&c(s,"trim",function(e){return null==e?"":(e+"").replace(v,"$1")},"trim","jQuery.trim is deprecated; use String.prototype.trim"),e("3.2.0")&&(c(s,"nodeName",function(e,t){return e.no
15deName&&e.nodeName.toLowerCase()===t.toLowerCase()},"nodeName","jQuery.nodeName is deprecated"),c(s,"isArray",Array.isArray,"isArray","jQuery.isArray is deprecated; use Array.isArray")),e("3.3.0")&&(c(s,"isNumeric",function(e){var t=typeof e;return("number"==t||"string"==t)&&!isNaN(e-parseFloat(e))},"isNumeric","jQuery.isNumeric() is deprecated"),s.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){f["[object "+t+"]"]=t.toLowerCase()}),c(s,"type",function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?f[Object.prototype.toString.call(e)]||"object":typeof e},"type","jQuery.type is deprecated"),c(s,"isFunction",function(e){return"function"==typeof e},"isFunction","jQuery.isFunction() is deprecated"),c(s,"isWindow",function(e){return null!=e&&e===e.window},"isWindow","jQuery.isWindow() is deprecated")),s.ajax&&(l=s.ajax,p=/(=)\?(?=&|$)|\?\?/,i(s,"ajax",function(){var e=l.apply(this,arguments);return e.promise&&(c(e,"success",e.done,"jqXHR-methods","jQXHR.success is deprecated and removed"),c(e,"error",e.fail,"jqXHR-methods","jQXHR.error is deprecated and removed"),c(e,"complete",e.always,"jqXHR-methods","jQXHR.complete is deprecated and removed")),e},"jqXHR-methods"),e("4.0.0")||s.ajaxPrefilter("+json",function(e){!1!==e.jsonp&&(p.test(e.url)||"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&p.test(e.data))&&u("jsonp-promotion","JSON-to-JSONP auto-promotion is deprecated")}));var j=s.fn.removeAttr,b=s.fn.toggleClass,w=/\S+/g;function x(e){return e.replace(/-([a-z])/g,function(e,t){return t.toUpperCase()})}i(s.fn,"removeAttr",function(e){var r=this,n=!1;return s.each(e.match(w),function(e,t){s.expr.match.bool.test(t)&&r.each(function(){if(!1!==s(this).prop(t))return!(n=!0)}),n&&(u("removeAttr-bool","jQuery.fn.removeAttr no longer sets boolean properties: "+t),r.prop(t,!1))}),j.apply(this,arguments)},"removeAttr-bool"),i(s.fn,"toggleClass",function(t){return void 0!==t&&"boolean"!=typeof t?b.apply(this,arguments):(u("toggleClass-bool","jQuery.fn.toggleClass( boolean ) is deprecated"),this.each(function(){var e=this.getAttribute&&this.getAttribute("class")||"";e&&s.data(this,"__className__",e),this.setAttribute&&this.setAttribute("class",!e&&!1!==t&&s.data(this,"__className__")||"")}))},"toggleClass-bool");var Q,A,R=!1,C=/^[a-z]/,N=/^(?:Border(?:Top|Right|Bottom|Left)?(?:Width|)|(?:Margin|Padding)?(?:Top|Right|Bottom|Left)?|(?:Min|Max)?(?:Width|Height))$/;s.swap&&s.each(["height","width","reliableMarginRight"],function(e,t){var r=s.cssHooks[t]&&s.cssHooks[t].get;r&&(s.cssHooks[t].get=function(){var e;return R=!0,e=r.apply(this,arguments),R=!1,e})}),i(s,"swap",function(e,t,r,n){var o,a,i={};for(a in R||u("swap","jQuery.swap() is undocumented and deprecated"),t)i[a]=e.style[a],e.style[a]=t[a];for(a in o=r.apply(e,n||[]),t)e.style[a]=i[a];return o},"swap"),e("3.4.0")&&"undefined"!=typeof Proxy&&(s.cssProps=new Proxy(s.cssProps||{},{set:function(){return u("cssProps","jQuery.cssProps is deprecated"),Reflect.set.apply(this,arguments)}})),e("4.0.0")?(A={animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},"undefined"!=typeof Proxy?s.cssNumber=new Proxy(A,{get:function(){return u("css-number","jQuery.cssNumber is deprecated"),Reflect.get.apply(this,arguments)},set:function(){return u("css-number","jQuery.cssNumber is deprecated"),Reflect.set.apply(this,arguments)}}):s.cssNumber=A):A=s.cssNumber,Q=s.fn.css,i(s.fn,"css",function(e,t){var r,n,o=this;return e&&"object"==typeof e&&!Array.isArray(e)?(s.each(e,function(e,t){s.fn.css.call(o,e,t)}),this):("number"==typeof t&&(r=x(e),n=r,C.test(n)&&N.test(n[0].toUpperCase()+n.slice(1))||A[r]||u("css-number",'Number-typed values are deprecated for jQuery.fn.css( "'+e+'", value )')),Q.apply(this,arguments))},"css-number");var S,P,k,H,E=s.data;i(s,"data",function(e,t,r){var n,o,a;if(t&&"object"==typeof t&&2===arguments.length){for(a in n=s.hasData(e)&&E.call(this,e),o={},t)a!==x(a)?(u("data-camelCase","jQuery.data() always sets/gets camelCased names: "+a),n[a]=t[a]):o[a]=t[a];return E.call(this,e,o),t}return t&&"string"==typeof t&&t!==x(t)&&(n=s.hasData(e)&&E.call(this,e))&&t in n?(u("data-camelCase","jQuery.data() always sets/gets camelCased names: "+t),2<arguments.length&&(n[t]=r),n[t]):E.apply(this,arguments)},"data-camelCase"),s.fx&&(k=s.Tween.prototype.run,H=function(e){return e},i(s.Tween.prototype,"run",function(){1<s.easing[this.easing].length&&(u("easing-one-arg","'jQuery.easing."+this.easing.toString()+"' should use only one argument"),s.easing[this.easing]=H),k.apply(this,arguments)},"easing-one-arg"),S=s.fx.interval,P="jQuery.fx.interval is deprecated",n.requestAnimationFrame&&Object.defineProperty(s.fx,"interval",{configurable:!0,enumerable:!0,get:function(){return n.document.hidden||u("fx-interval",P),s.migrateIsPatchEnabled("fx-interval")&&void 0===S?13:S},set:function(e){u("fx-interval",P),S=e}}));var M=s.fn.load,q=s.event.add,O=s.event.fix;s.event.props=[],s.event.fixHooks={}
15,r(s.event.props,"concat",s.event.props.concat,"event-old-patch","jQuery.event.props.concat() is deprecated and removed"),i(s.event,"fix",function(e){var t,r=e.type,n=this.fixHooks[r],o=s.event.props;if(o.length){u("event-old-patch","jQuery.event.props are deprecated and removed: "+o.join());while(o.length)s.event.addProp(o.pop())}if(n&&!n._migrated_&&(n._migrated_=!0,u("event-old-patch","jQuery.event.fixHooks are deprecated and removed: "+r),(o=n.props)&&o.length))while(o.length)s.event.addProp(o.pop());return t=O.call(this,e),n&&n.filter?n.filter(t,e):t},"event-old-patch"),i(s.event,"add",function(e,t){return e===n&&"load"===t&&"complete"===n.document.readyState&&u("load-after-event","jQuery(window).on('load'...) called after load event occurred"),q.apply(this,arguments)},"load-after-event"),s.each(["load","unload","error"],function(e,t){i(s.fn,t,function(){var e=Array.prototype.slice.call(arguments,0);return"load"===t&&"string"==typeof e[0]?M.apply(this,e):(u("shorthand-removed-v3","jQuery.fn."+t+"() is deprecated"),e.splice(0,0,t),arguments.length?this.on.apply(this,e):(this.triggerHandler.apply(this,e),this))},"shorthand-removed-v3")}),s.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,r){c(s.fn,r,function(e,t){return 0<arguments.length?this.on(r,null,e,t):this.trigger(r)},"shorthand-deprecated-v3","jQuery.fn."+r+"() event shorthand is deprecated")}),s(function(){s(n.document).triggerHandler("ready")}),s.event.special.ready={setup:function(){this===n.document&&u("ready-event","'ready' event is deprecated")}},c(s.fn,"bind",function(e,t,r){return this.on(e,null,t,r)},"pre-on-methods","jQuery.fn.bind() is deprecated"),c(s.fn,"unbind",function(e,t){return this.off(e,null,t)},"pre-on-methods","jQuery.fn.unbind() is deprecated"),c(s.fn,"delegate",function(e,t,r,n){return this.on(t,e,r,n)},"pre-on-methods","jQuery.fn.delegate() is deprecated"),c(s.fn,"undelegate",function(e,t,r){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",r)},"pre-on-methods","jQuery.fn.undelegate() is deprecated"),c(s.fn,"hover",function(e,t){return this.on("mouseenter",e).on("mouseleave",t||e)},"pre-on-methods","jQuery.fn.hover() is deprecated");function T(e){var t=n.document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body&&t.body.innerHTML}var F=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi;s.UNSAFE_restoreLegacyHtmlPrefilter=function(){s.migrateEnablePatches("self-closed-tags")},i(s,"htmlPrefilter",function(e){var t,r;return(r=(t=e).replace(F,"<$1></$2>"))!==t&&T(t)!==T(r)&&u("self-closed-tags","HTML tags must be properly nested and closed: "+t),e.replace(F,"<$1></$2>")},"self-closed-tags"),s.migrateDisablePatches("self-closed-tags");var D,W,_,I=s.fn.offset;return i(s.fn,"offset",function(){ 16 var e=this[0]; 17 // BUBBLE PATCH NOTES - offset() changed below, see comment in non-minified 18 if (!e) return {left:0, top:0}; 19 return(!e||e.nodeType&&e.getBoundingClientRect) 20 ?I.apply(this,arguments) 21 :(u("offset-valid-elem","jQuery.fn.offset() requires a valid DOM element"),arguments.length 22 ?this 23 :({left:0,top:0}))},"offset-valid-elem" 24),s.ajax&&(D=s.param,i(s,"param",function(e,t){var r=s.ajaxSettings&&s.ajaxSettings.traditional;return void 0===t&&r&&(u("param-ajax-traditional","jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),t=r),D.call(this,e,t)},"param-ajax-traditional")),c(s.fn,"andSelf",s.fn.addBack,"andSelf","jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),s.Deferred&&(W=s.Deferred,_=[["resolve","done",s.Callbacks("once memory"),s.Callbacks("once memory"),"resolved"],["reject","fail",s.Callbacks("once memory"),s.Callbacks("once memory"),"rejected"],["notify","progress",s.Callbacks("memory"),s.Callbacks("memory")]],i(s,"Deferred",function(e){var a=W(),i=a.promise();function t(){var o=arguments;return s.Deferred(function(n){s.each(_,function(e,t){var r="function"==typeof o[e]&&o[e];a[t[1]](function(){var e=r&&r.apply(this,arguments);e&&"function"==typeof e.promise?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[t[0]+"With"](this===i?n.promise():this,r?[e]:arguments)})}),o=null}).promise()}return c(a,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),c(i,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),e&&e.call(a,a),a},"deferred-pipe"),s.Deferred.exceptionHook=W.exceptionHook),s}); 25 26window.preloaded['js/vendor:jquery-migrate-3.4.1.min.js'] = true; 27 28window.bubble_version = 29; 29window.preloaded['app/metadata:bubble_version'] = true; 30window._bubble_page_load_data.hardcoded_plugins = window._bubble_page_load_data.hardcoded_plugins || {}; 31window._bubble_page_load_data.hardcoded_plugins['ionic'] = true; 32window.__code__ = window.__code__ || {}; 33if(!window.__code__['b932683b7c71fbe9edf258c20897513d9278643155cd4750df5077722efab57c']){window.__code__['b932683b7c71fbe9edf258c20897513d9278643155cd4750df5077722efab57c']=1; 34 35"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exp
vendor: 5,994 bytes, line 35
35orts:{}}).exports,mod),mod.exports};var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod)),__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>
vendor: 23,595 bytes, line 35
35K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 35
35)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 35
35if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
35var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});var require_global=__commonJS({"node_modules/core-js/internals/global.js"(exports,module){"use strict";init_define_process_env();init_shim();var check=function(it){return it&&it.Math===Math&&it};module.exports=check(typeof globalThis=="object"&&globalThis)||check(typeof window=="object"&&window)||check(typeof self=="object"&&self)||check(typeof window=="object"&&window)||check(typeof exports=="object"&&exports)||function(){return this}()||Function("return this")()}});var require_fails=__commonJS({"node_modules/core-js/internals/fails.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(exec){try{return!!exec()}catch{return!0}}}});var require_descriptors=__commonJS({"node_modules/core-js/internals/descriptors.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})}});var require_function_bind_native=__commonJS({"node_modules/core-js/internals/function-bind-native.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){var test=(function(){}).bind();return typeof test!="function"||test.hasOwnProperty("prototype")})}});var require_function_call=__commonJS({"node_modules/core-js/internals/function-call.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),call=Function.prototype.call;module.exports=NATIVE_BIND?call.bind(call):function(){return call.apply(call,arguments)}}});var require_object_property_is_enumerable=__commonJS({"node_modules/core-js/internals/object-property-is-enumerable.js"(exports){"use strict";init_define_process_env();init_shim();var $propertyIsEnumerable={}.propertyIsEnumerable,getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,NASHORN_BUG=getOwnPropertyDescriptor&&!$propertyIsEnumerable.call({1:2},1);exports.f=NASHORN_BUG?function(V){var descriptor=getOwnPropertyDescriptor(this,V);return!!descriptor&&descriptor.enumerable}:$propertyIsEnumerable}});var require_create_property_descriptor=__commonJS({"node_modules/core-js/internals/create-property-descriptor.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(bitmap,value){return{enumerable:!(bitmap&1),configurable:!(bitmap&2),writable:!(bitmap&4),value}}}});var require_function_uncurry_this=__commonJS({"node_modules/core-js/internals/function-uncurr
35y-this.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),FunctionPrototype=Function.prototype,call=FunctionPrototype.call,uncurryThisWithBind=NATIVE_BIND&&FunctionPrototype.bind.bind(call,call);module.exports=NATIVE_BIND?uncurryThisWithBind:function(fn){return function(){return call.apply(fn,arguments)}}}});var require_classof_raw=__commonJS({"node_modules/core-js/internals/classof-raw.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toString=uncurryThis({}.toString),stringSlice=uncurryThis("".slice);module.exports=function(it){return stringSlice(toString(it),8,-1)}}});var require_indexed_object=__commonJS({"node_modules/core-js/internals/indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),classof=require_classof_raw(),$Object=Object,split=uncurryThis("".split);module.exports=fails(function(){return!$Object("z").propertyIsEnumerable(0)})?function(it){return classof(it)==="String"?split(it,""):$Object(it)}
35:$Object}});var require_is_null_or_undefined=__commonJS({"node_modules/core-js/internals/is-null-or-undefined.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(it){return it==null}}});var require_require_object_coercible=__commonJS({"node_modules/core-js/internals/require-object-coercible.js"(exports,module){"use strict";init_define_process_env();init_shim();var isNullOrUndefined=require_is_null_or_undefined(),$TypeError=TypeError;module.exports=function(it){if(isNullOrUndefined(it))throw new $TypeError("Can't call method on "+it);return it}}});var require_to_indexed_object=__commonJS({"node_modules/core-js/internals/to-indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var IndexedObject=require_indexed_object(),requireObjectCoercible=require_require_object_coercible();module.exports=function(it){return IndexedObject(requireObjectCoercible(it))}}});var require_is_callable=__commonJS({"node_modules/core-js/internals/is-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var documentAll=typeof document=="object"&&document.all;module.exports=typeof documentAll>"u"&&documentAll!==void 0?function(argument){return typeof argument=="function"||argument===documentAll}:function(argument){return typeof argument=="function"}}});var require_is_object=__commonJS({"node_modules/core-js/internals/is-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable();module.exports=function(it){return typeof it=="object"?it!==null:isCallable(it)}}});var require_get_built_in=__commonJS({"node_modules/core-js/internals/get-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),aFunction=function(argument){return isCallable(argument)?argument:void 0};module.exports=function(namespace,method){return arguments.length<2?aFunction(global[namespace]):global[namespace]&&global[namespace][method]}}});var require_object_is_prototype_of=__commonJS({"node_modules/core-js/internals/object-is-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this();module.exports=uncurryThis({}.isPrototypeOf)}});var require_engine_user_agent=__commonJS({"node_modules/core-js/internals/engine-user-agent.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=typeof navigator<"u"&&String(navigator.userAgent)||""}});var require_engine_v8_version=__commonJS({"node_modules/core-js/internals/engine-v8-version.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),userAgent=require_engine_user_agent(),process2=global.process,Deno=global.Deno,versions=process2&&process2.versions||Deno&&Deno.version,v8=versions&&versions.v8,match,version;v8&&(match=v8.split("."),version=match[0]>0&&match[0]<4?1:+(match[0]+match[1]));!version&&userAgent&&(match=userAgent.match(/Edge\/(\d+)/),(!match||match[1]>=74)&&(match=userAgent.match(/Chrome\/(\d+)/),match&&(version=+match[1])));module.exports=version}});var require_symbol_constructor_detection=__commonJS({"node_modules/core-js/internals/symbol-constructor-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var V8_VERSION=require_engine_v8_version(),fails=require_fails(),global=require_global(),$String=global.String;module.exports=!!Object.getOwnPropertySymbols&&!fails(function(){var symbol=Symbol("symbol detection");return!$String(symbol)||!(Object(symbol)instanceof Symbol)||!Symbol.sham&&V8_VERSION&&V8_VERSION<41})}});var require_use_symbol_as_uid=__commonJS({"node_modules/core-js/internals/use-symbol-as-uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_SYMBOL=require_symbol_constructor_detection();module.exports=NATIVE_SYMBOL&&!Symbol.sham&&typeof Symbol.iterator=="symbol"}});var require_is_symbol=__commonJS({"node_modules/core-js/internals/is-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),isCallable=require_is_callable(),isPrototypeOf=require_object_is_prototype_of(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),$Object=Object;module.exports=USE_SYMBOL_AS_UID?function(it){return typeof it=="symbol"}:function(it){var $Symbol=getBuiltIn("Symbol");return isCallable($Symbol)&&isPrototypeOf($Symbol.prototype,$Object(it))}}});var require_try_to_string=__commonJS({"node_modules/core-js/internals/try-to-string.js"(exports,module){"use strict";init_define_process_env();init_shim();var $String=String;module.exports=function(argument){try{return $String(argument)}catch{return"Object"}}}});var require_a_callable=__commonJS({"node_modules/core-js/internals/a-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),tryToString=require_try_to_string(),$TypeError=TypeError;module.exports=function(argument){if(isCallable(argument))return argument;throw new $TypeError(tryToString(argument)+" is not a function")}}});var require_get_method=__commonJS({"node_modules/core-js/internals/get-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var aCallable=require_a_callable(),isNullOrUndefined=require_is_null_or_undefined();module.exports=function(V,P){var func=V[P];return isNullOrUndefined(func)?void 0:aCallable(func)}}});var require_ordinary_to_primitive=__commonJS({"node_modules/core-js/internals/ordinary-to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isCallable=require_is_callable(),isObject=require_is_object(),$TypeError=TypeError;module.exports=function(input,pref){var fn,val;if(pref==="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input))||isCallable(fn=input.valueOf)&&!isObject(val=call(fn,input))||pref!=="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input)))return val;throw new $TypeError("Can't convert object to primitive value")}}});var require_is_pure=__commonJS({"node_modules/core-js/internals/is-pure.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=!1}});var require_define_global_property=__commonJS({"node_modules/core-js/internals/define-global-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineProperty=Object.defineProperty;module.exports=function(key,value){try{defineProperty(global,key,{value,configurable:!0,writable:!0})}catch{global[key]=value}return value}}});var require_shared_store=__commonJS({"node_modules/core-js/internals/shared-store.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineGlobalProperty=require_define_global_property(),SHARED="__core-js_shared__",store=global[SHARED]||defineGlobalProperty(S
35HARED,{});module.exports=store}});var require_shared=__commonJS({"node_modules/core-js/internals/shared.js"(exports,module){"use strict";init_define_process_env();init_shim();var IS_PURE=require_is_pure(),store=require_shared_store();(module.exports=function(key,value){return store[key]||(store[key]=value!==void 0?value:{})})("versions",[]).push({version:"3.35.1",mode:IS_PURE?"pure":"global",copyright:"\xA9 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE",source:"https://github.com/zloirock/core-js"})}});var require_to_object=__commonJS({"node_modules/core-js/internals/to-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var requireObjectCoercible=require_require_object_coercible(),$Object=Object;module.exports=function(argument){return $Object(requireObjectCoercible(argument))}}});var require_has_own_property=__commonJS({"node_modules/core-js/internals/has-own-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toObject=require_to_object(),hasOwnProperty=uncurryThis({}.hasOwnProperty);module.exports=Object.hasOwn||function(it,key){return hasOwnProperty(toObject(it),key)}}});var require_uid=__commonJS({"node_modules/core-js/internals/uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),id=0,postfix=Math.random(),toString=uncurryThis(1 .toString);module.exports=function(key){return"Symbol("+(key===void 0?"":key)+")_"+toString(++id+postfix,36)}}});var require_well_known_symbol=__commonJS({"node_modules/core-js/internals/well-known-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),shared=require_shared(),hasOwn=require_has_own_property(),uid=require_uid(),NATIVE_SYMBOL=require_symbol_constructor_detection(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),Symbol2=global.Symbol,WellKnownSymbolsStore=shared("wks"),createWellKnownSymbol=USE_SYMBOL_AS_UID?Symbol2.for||Symbol2:Symbol2&&Symbol2.withoutSetter||uid;module.exports=function(name){return hasOwn(WellKnownSymbolsStore,name)||(WellKnownSymbolsStore[name]=NATIVE_SYMBOL&&hasOwn(Symbol2,name)?Symbol2[name]:createWellKnownSymbol("Symbol."+name)),WellKnownSymbolsStore[name]}}});var require_to_primitive=__commonJS({"node_modules/core-js/internals/to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isObject=require_is_object(),isSymbol
35=require_is_symbol(),getMethod=require_get_method(),ordinaryToPrimitive=require_ordinary_to_primitive(),wellKnownSymbol=require_well_known_symbol(),$TypeError=TypeError,TO_PRIMITIVE=wellKnownSymbol("toPrimitive");module.exports=function(input,pref){if(!isObject(input)||isSymbol(input))return input;var exoticToPrim=getMethod(input,TO_PRIMITIVE),result;if(exoticToPrim){if(pref===void 0&&(pref="default"),result=call(exoticToPrim,input,pref),!isObject(result)||isSymbol(result))return result;throw new $TypeError("Can't convert object to primitive value")}return pref===void 0&&(pref="number"),ordinaryToPrimitive(input,pref)}}});var require_to_property_key=__commonJS({"node_modules/core-js/internals/to-property-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPrimitive=require_to_primitive(),isSymbol=require_is_symbol();module.exports=function(argument){var key=toPrimitive(argument,"string");return isSymbol(key)?key:key+""}}});var require_document_create_element=__commonJS({"node_modules/core-js/internals/document-create-element.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isObject=require_is_object(),document2=global.document,EXISTS=isObject(document2)&&isObject(document2.createElement);module.exports=function(it){return EXISTS?document2.createElement(it):{}}}});var require_ie8_dom_define=__commonJS({"node_modules/core-js/internals/ie8-dom-define.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails(),createElement=require_document_create_element();module.exports=!DESCRIPTORS&&!fails(function(){return Object.defineProperty(createElement("div"),"a",{get:function(){return 7}}).a!==7})}});var require_object_get_own_property_descriptor=__commonJS({"node_modules/core-js/internals/object-get-own-property-descriptor.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),call=require_function_call(),propertyIsEnumerableModule=require_object_property_is_enumerable(),createPropertyDescriptor=require_create_property_descriptor(),toIndexedObject=require_to_indexed_object(),toPropertyKey=require_to_property_key(),hasOwn=require_has_own_property(),IE8_DOM_DEFINE=require_ie8_dom_define(),$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor;exports.f=DESCRIPTORS?$getOwnPropertyDescriptor:function(O,P){if(O=toIndexedObject(O),P=toPropertyKey(P),IE8_DOM_DEFINE)try{return $getOwnPropertyDescriptor(O,P)}catch{}if(hasOwn(O,P))return createPropertyDescriptor(!call(propertyIsEnumerableModule.f,O,P),O[P])}}});var require_v8_prototype_define_bug=__commonJS({"node_modules/core-js/internals/v8-prototype-define-bug.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails();module.exports=DESCRIPTORS&&fails(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})}});var require_an_object=__commonJS({"node_modules/core-js/internals/an-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isObject=require_is_object(),$String=String,$TypeError=TypeError;module.exports=function(argument){if(isObject(argument))return argument;throw new $TypeError($String(argument)+" is not an object")}}});var require_object_define_property=__commonJS({"node_modules/core-js/internals/object-define-property.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),IE8_DOM_DEFINE=require_ie8_dom_define(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),anObject=require_an_object(),toPropertyKey=require_to_property_key(),$TypeError=TypeError,$defineProperty=Object.defineProperty,$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,ENUMERABLE="enumerable",CONFIGURABLE="configurable",WRITABLE="writable";exports.f=DESCRIPTORS?V8_PROTOTYPE_DEFINE_BUG?function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),typeof O=="function"&&P==="prototype"&&"value"in Attributes&&WRITABLE in Attributes&&!Attributes[WRITABLE]){var current=$getOwnPropertyDescriptor(O,P);current&¤t[WRITABLE]&&(O[P]=Attributes.value,Attributes={configurable:CONFIGURABLE in Attributes?Attributes[CONFIGURABLE]:current[CONFIGURABLE],enumerable:ENUMERABLE in Attributes?Attributes[ENUMERABLE]:current[ENUMERABLE],writable:!1})}return $defineProperty(O,P,Attributes)}
35:$defineProperty:function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),IE8_DOM_DEFINE)try{return $defineProperty(O,P,Attributes)}catch{}if("get"in Attributes||"set"in Attributes)throw new $TypeError("Accessors not supported");return"value"in Attributes&&(O[P]=Attributes.value),O}}});var require_create_non_enumerable_property=__commonJS({"node_modules/core-js/internals/create-non-enumerable-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=DESCRIPTORS?function(object,key,value){return definePropertyModule.f(object,key,createPropertyDescriptor(1,value))}:function(object,key,value){return object[key]=value,object}}});var require_function_name=__commonJS({"node_modules/core-js/internals/function-name.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),hasOwn=require_has_own_property(),FunctionPrototype=Function.prototype,getDescriptor=DESCRIPTORS&&Object.getOwnPropertyDescriptor,EXISTS=hasOwn(FunctionPrototype,"name"),PROPER=EXISTS&&(function(){}).name==="something",CONFIGURABLE=EXISTS&&(!DESCRIPTORS||DESCRIPTORS&&getDescriptor(FunctionPrototype,"name").configurable);module.exports={EXISTS,PROPER,CONFIGURABLE}}});
35var require_inspect_source=__commonJS({"node_modules/core-js/internals/inspect-source.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),isCallable=require_is_callable(),store=require_shared_store(),functionToString=uncurryThis(Function.toString);isCallable(store.inspectSource)||(store.inspectSource=function(it){return functionToString(it)});module.exports=store.inspectSource}});var require_weak_map_basic_detection=__commonJS({"node_modules/core-js/internals/weak-map-basic-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),WeakMap=global.WeakMap;module.exports=isCallable(WeakMap)&&/native code/.test(String(WeakMap))}});var require_shared_key=__commonJS({"node_modules/core-js/internals/shared-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var shared=require_shared(),uid=require_uid(),keys=shared("keys");module.exports=function(key){return keys[key]||(keys[key]=uid(key))}}});var require_hidden_keys=__commonJS({"node_modules/core-js/internals/hidden-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports={}}});var require_internal_state=__commonJS({"node_modules/core-js/internals/internal-state.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_WEAK_MAP=require_weak_map_basic_detection(),global=require_global(),isObject=require_is_object(),createNonEnumerableProperty=require_create_non_enumerable_property(),hasOwn=require_has_own_property(),shared=require_shared_store(),sharedKey=require_shared_key(),hiddenKeys=require_hidden_keys(),OBJECT_ALREADY_INITIALIZED="Object already initialized",TypeError2=global.TypeError,WeakMap=global.WeakMap,set,get,has,enforce=function(it){return has(it)?get(it):set(it,{})},getterFor=function(TYPE){return function(it){var state;if(!isObject(it)||(state=get(it)).type!==TYPE)throw new TypeError2("Incompatible receiver, "+TYPE+" required");return state}};NATIVE_WEAK_MAP||shared.state?(store=shared.state||(shared.state=new WeakMap),store.get=store.get,store.has=store.has,store.set=store.set,set=function(it,metadata){if(store.has(it))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,store.set(it,metadata),metadata},get=function(it){return store.get(it)||{}},has=function(it){return store.has(it)}):(STATE=sharedKey("state"),hiddenKeys[STATE]=!0,set=function(it,metadata){if(hasOwn(it,STATE))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,createNonEnumerableProperty(it,STATE,metadata),metadata},get=function(it){return hasOwn(it,STATE)?it[STATE]:{}},has=function(it){return hasOwn(it,STATE)});var store,STATE;module.exports={set,get,has,enforce,getterFor}}});var require_make_built_in=__commonJS({"node_modules/core-js/internals/make-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),isCallable=require_is_callable(),hasOwn=require_has_own_property(),DESCRIPTORS=require_descriptors(),CONFIGURABLE_FUNCTION_NAME=require_function_name().CONFIGURABLE,inspectSource=require_inspect_source(),InternalStateModule=require_internal_state(),enforceInternalState=InternalStateModule.enforce,getInternalState=InternalStateModule.get,$String=String,defineProperty=Object.defineProperty,stringSlice=uncurryThis("".slice),replace=uncurryThis("".replace),join=uncurr
35yThis([].join),CONFIGURABLE_LENGTH=DESCRIPTORS&&!fails(function(){return defineProperty(function(){},"length",{value:8}).length!==8}),TEMPLATE=String(String).split("String"),makeBuiltIn=module.exports=function(value,name,options){stringSlice($String(name),0,7)==="Symbol("&&(name="["+replace($String(name),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),options&&options.getter&&(name="get "+name),options&&options.setter&&(name="set "+name),(!hasOwn(value,"name")||CONFIGURABLE_FUNCTION_NAME&&value.name!==name)&&(DESCRIPTORS?defineProperty(value,"name",{value:name,configurable:!0}):value.name=name),CONFIGURABLE_LENGTH&&options&&hasOwn(options,"arity")&&value.length!==options.arity&&defineProperty(value,"length",{value:options.arity});try{options&&hasOwn(options,"constructor")&&options.constructor?DESCRIPTORS&&defineProperty(value,"prototype",{writable:!1}):value.prototype&&(value.prototype=void 0)}catch{}var state=enforceInternalState(value);return hasOwn(state,"source")||(state.source=join(TEMPLATE,typeof name=="string"?name:"")),value};Function.prototype.toString=makeBuiltIn(function(){return isCallable(this)&&getInternalState(this).source||inspectSource(this)},"toString")}});var require_define_built_in=__commonJS({"node_modules/core-js/internals/define-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),definePropertyModule=require_object_define_property(),makeBuiltIn=require_make_built_in(),defineGlobalProperty=require_define_global_property();module.exports=function(O,key,value,options){options||(options={});var simple=options.enumerable,name=options.name!==void 0?options.name:key;if(isCallable(value)&&makeBuiltIn(value,name,options),options.global)simple?O[key]=value:defineGlobalProperty(key,value);else{try{options.unsafe?O[key]&&(simple=!0):delete O[key]}catch{}simple?O[key]=value:definePropertyModule.f(O,key,{value,enumerable:!1,configurable:!options.nonConfigurable,writable:!options.nonWritable})}return O}}});var require_math_trunc=__commonJS({"node_modules/core-js/internals/math-trunc.js"(exports,module){"use strict";init_define_process_env();init_shim();var ceil=Math.ceil,floor=Math.floor;module.exports=Math.trunc||function(x){var n=+x;return(n>0?floor:ceil)(n)}}});var require_to_integer_or_infinity=__commonJS({"node_modules/core-js/internals/to-integer-or-infinity.js"(exports,module){"use strict";init_define_process_env();init_shim();var trunc=require_math_trunc();module.exports=function(argument){var number=+argument;return number!==number||number===0?0:trunc(number)}}});var require_to_absolute_index=__commonJS({"node_modules/core-js/internals/to-absolute-index.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),max=Math.max,min=Math.min;module.exports=function(index,length){var integer=toIntegerOrInfinity(index);return integer<0?max(integer+length,0):min(integer,length)}}});var require_to_length=__commonJS({"node_modules/core-js/internals/to-length.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),min=Math.min;module.exports=function(argument){var len=toIntegerOrInfinity(argument);return len>0?min(len,9007199254740991):0}}});var require_length_of_array_like=__commonJS({"node_modules/core-js/internals/length-of-array-like.js"(exports,module){"use strict";init_define_process_env();init_shim();var toLength=require_to_length();module.exports=function(obj){return toLength(obj.length)}}});var require_array_includes=__commonJS({"node_modules/core-js/internals/array-includes.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIndexedObject=require_to_indexed_object(),toAbsoluteIndex=require_to_absolute_index(),lengthOfArrayLike=require_length_of_array_like(),createMethod=function(IS_INCLUDES){return function($this,el,fromIndex){var O=toIndexedObject($this),length=lengthOfArrayLike(O),index=toAbsoluteIndex(fromIndex,length),value;if(IS_INCLUDES&&el!==el){for(;length>index;)if(value=O[index++],value!==value)return!0}else for(;length>index;index++)if((IS_INCLUDES||index in O)&&O[index]===el)return IS_INCLUDES||index||0;return!IS_INCLUDES&&-1}};module.exports={includes:createMethod(!0),indexOf:createMethod(!1)}}});var require_object_keys_internal=__commonJS({"node_modules/core-js/internals/object-keys-internal.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),hasOwn=require_has_own_property(),toIndexedObject=require_to_indexed_object(),indexOf=require_array_includes().indexOf,hiddenKeys=require_hidden_keys(),push=uncurryThis([].push);module.exports=function(object,names){var O=toIndexedObject(object),i=0,result=[],key;for(key in O)!hasOwn(hiddenKeys,key)&&hasOwn(O,key)&&push(result,key);for(;names.length>i;)hasOwn(O,key=names[i++])&&(~indexOf(result,key)||push(result,key));return result}}});var require_enum_bug_keys=__commonJS({"node_modules/core-js/internals/enum-bug-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleStr
35ing","toString","valueOf"]}});var require_object_get_own_property_names=__commonJS({"node_modules/core-js/internals/object-get-own-property-names.js"(exports){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=enumBugKeys.concat("length","prototype");exports.f=Object.getOwnPropertyNames||function(O){return internalObjectKeys(O,hiddenKeys)}}});var require_object_get_own_property_symbols=__commonJS({"node_modules/core-js/internals/object-get-own-property-symbols.js"(exports){"use strict";init_define_process_env();init_shim();exports.f=Object.getOwnPropertySymbols}});var require_own_keys=__commonJS({"node_modules/core-js/internals/own-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),uncurryThis=require_function_uncurry_this(),getOwnPropertyNamesModule=require_object_get_own_property_names(),getOwnPropertySymbolsModule=require_object_get_own_property_symbols(),anObject=require_an_object(),concat=uncurryThis([].concat);module.exports=getBuiltIn("Reflect","ownKeys")||function(it){var keys=getOwnPropertyNamesModule.f(anObject(it)),getOwnPropertySymbols=getOwnPropertySymbolsModule.f;return getOwnPropertySymbols?concat(keys,getOwnPropertySymbols(it)):keys}}});var require_copy_constructor_properties=__commonJS({"node_modules/core-js/internals/copy-constructor-properties.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),ownKeys=require_own_keys(),getOwnPropertyDescriptorModule=require_object_get_own_property_descriptor(),definePropertyModule=require_object_define_property();module.exports=function(target,source,exceptions){for(var keys=ownKeys(source),defineProperty=definePropertyModule.f,getOwnPropertyDescriptor=getOwnPropertyDescriptorModule.f,i=0;i<keys.length;i++){var key=keys[i];!hasOwn(target,key)&&!(exceptions&&hasOwn(exceptions,key))&&defineProperty(target,key,getOwnPropertyDescriptor(source,key))}}}});var require_is_forced=__commonJS({"node_modules/core-js/internals/is-forced.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),replacement=/#|\.prototype\./,isForced=function(feature,detection){var value=data[normalize(feature)];return value===POLYFILL?!0:value===NATIVE?!1:isCallable(detection)?fails(detection):!!detection},normalize=isForced.normalize=function(string){return String(string).replace(replacement,".").toLowerCase()},data=isForced.data={},NATIVE=isForced.NATIVE="N",POLYFILL=isForced.POLYFILL="P";module.exports=isForced}});var require_export=__commonJS({"node_modules/core-js/internals/export.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),getOwnPropertyDescriptor=require_object_get_own_property_descriptor().f,createNonEnumerableProperty=require_create_non_enumerable_property(),defineBuiltIn=require_define_built_in(),defineGlobalProperty=require_define_global_property(),copyConstructorProperties=require_copy_constructor_properties(),isForced=require_is_forced();module.exports=function(options,source){var TARGET=options.target,GLOBAL=options.global,STATIC=options.stat,FORCED,target,key,targetProperty,sourceProperty,descriptor;if(GLOBAL?target=global:STATIC?target=global[TARGET]||defineGlobalProperty(TARGET,{}):target=global[TARGET]&&global[TARGET].prototype,target)for(key in source){if(sourceProperty=source[key],options.dontCallGetSet?(descriptor=getOwnPropertyDescriptor(target,key),targetProperty=descriptor&&descriptor.value):targetProperty=target[key],FORCED=isForced(GLOBAL?key:TARGET+(STATIC?".":"#")+key,options.forced),!FORCED&&targetProperty!==void 0){if(typeof sourceProperty==typeof targetProperty)continue;copyConstructorProperties(sourceProperty,targetProperty)}(options.sham||targetProperty&&targetProperty.sham)&&createNonEnumerableProperty(sourceProperty,"sham",!0),defineBuiltIn(target,key,sourceProperty,options)}}}});var require_an_instance=__commonJS({"node_modules/core-js/internals/an-instance.js"(exports,module){"use strict";init_define_process_env();init_shim();var isPrototypeOf=require_object_is_prototype_of(),$TypeError=TypeError;module.exports=function(it,Prototype){if(isPrototypeOf(Prototype,it))return it;throw new $TypeError("Incorrect invocation")}}});var require_correct_prototype_getter=__commonJS({"node_modules/core-js/internals/correct-prototype-getter.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){function F(){}return F.prototype.constructor=null,Object.getPrototypeOf(new F)!==F.prototype})}});var require_object_get_prototype_of=__commonJS({"node_modules/core-js/internals/object-get-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),isCallable=require_is_callable(),toObject=require_to_object(),sharedKey=require_shared_key(),CORRECT_PROTOTYPE_GETTER=require_correct_prototype_getter(),IE_PROTO=sharedKey("IE_PROTO"),$Object=Object,ObjectPrototype=$Object.prototype;module.exports=CORRECT_PROTOTYPE_GETTER?$Object.getPrototypeOf:function(O){var object=toObject(O);if(hasOwn(object,IE_PROTO))return object[IE_PROTO];var constructor=object.constructor;return isCallable(constructor)&&object instanceof constructor?constructor.prototype:object instanceof $Object?ObjectPrototype:null}}});var require_define_built_in_accessor=__commonJS({"node_modules/core-js/internals/define-built-in-accessor.js"(exports,module){"use strict";init_define_process_env();init_shim();var makeBuiltIn=require_make_built_in(),defineProperty=require_object_define_property();module.exports=function(target,name,descriptor){return descriptor.get&&makeBuiltIn(descriptor.get,name,{getter:!0}),descriptor.set&&makeBuiltIn(descriptor.set,name,{setter:!0}),defineProperty.f(target,name,descriptor)}}});var require_create_property=__commonJS({"node_modules/core-js/internals/create-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPropertyKey=require_to_property_key(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=function(object,key,value){var propertyKey=toPropertyKey(key);propertyKey in object?definePropertyModule.f(object,propertyKey,createPropertyDescriptor(0,value)):object[propertyKey]=value}}});var require_object_keys=__commonJS({"node_modules/core-js/internals/object-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys();module.exports=Object.keys||function(O){return internalObjectKeys(O,enumBugKeys)}}});var require_object_define_properties=__commonJS({"node_modules/core-js/internals/object-define-properties.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),definePropertyModule=require_object_define_property(),anObject=require_an_object(),toIndexedObject=require_to_indexed_object(),objectKeys=require_object_keys();exports.f=DESCRIPTORS&&!V8_PROTOTYPE_DEFINE_BUG?Object.defineProperties:function(O,Properties){anObject(O);for(var props=toIndexedObject(Properties),keys=objectKeys(Properties),length=keys.length,index=0,key;length>index;)definePropertyModule.f(O,key=keys[index++],props[key]);return O}}});var require_html=__commonJS({"node_modules/core-js/internals/html.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in();module.exports=getBuiltIn("document","documentElement")}});var require_object_create=__commonJS({"node_modules/core-js/internals/object-create.js"(exports,module){"use strict";init_define_process_env();init_shim();var anObject=require_an_object(),definePropertiesModule=require_object_define_properties(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=require_hidden_keys(),html=require_html(),documentCreateElement=require_document_create_element
vendor: 4,762 bytes, line 35
35(),sharedKey=require_shared_key(),GT=">",LT="<",PROTOTYPE="prototype",SCRIPT="script",IE_PROTO=sharedKey("IE_PROTO"),EmptyConstructor=function(){},scriptTag=function(content){return LT+SCRIPT+GT+content+LT+"/"+SCRIPT+GT},NullProtoObjectViaActiveX=function(activeXDocument2){activeXDocument2.write(scriptTag("")),activeXDocument2.close();var temp=activeXDocument2.parentWindow.Object;return activeXDocument2=null,temp},NullProtoObjectViaIFrame=function(){var iframe=documentCreateElement("iframe"),JS="java"+SCRIPT+":",iframeDocument;return iframe.style.display="none",html.appendChild(iframe),iframe.src=String(JS),iframeDocument=iframe.contentWindow.document,iframeDocument.open(),iframeDocument.write(scriptTag("document.F=Object")),iframeDocument.close(),iframeDocument.F},activeXDocument,NullProtoObject=function(){try{activeXDocument=new ActiveXObject("htmlfile")}catch{}NullProtoObject=typeof document<"u"?document.domain&&activeXDocument?NullProtoObjectViaActiveX(activeXDocument):NullProtoObjectViaIFrame():NullProtoObjectViaActiveX(activeXDocument);for(var length=enumBugKeys.length;length--;)delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];return NullProtoObject()};hiddenKeys[IE_PROTO]=!0;module.exports=Object.create||function(O,Properties){var result;return O!==null?(EmptyConstructor[PROTOTYPE]=anObject(O),result=new EmptyConstructor,EmptyConstructor[PROTOTYPE]=null,result[IE_PROTO]=O):result=NullProtoObject(),Properties===void 0?result:definePropertiesModule.f(result,Properties)}}});var require_iterators_core=__commonJS({"node_modules/core-js/internals/iterators-core.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),isObject=require_is_object(),create=require_object_create(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltIn=require_define_built_in(),wellKnownSymbol=require_well_known_symbol(),IS_PURE=require_is_pure(),ITERATOR=wellKnownSymbol("iterator"),BUGGY_SAFARI_ITERATORS=!1,IteratorPrototype,PrototypeOfArrayIteratorPrototype,arrayIterator;[].keys&&(arrayIterator=[].keys(),"next"in arrayIterator?(PrototypeOfArrayIteratorPrototype=getPrototypeOf(getPrototypeOf(arrayIterator)),PrototypeOfArrayIteratorPrototype!==Object.prototype&&(IteratorPrototype=PrototypeOfArrayIteratorPrototype)):BUGGY_SAFARI_ITERATORS=!0);var NEW_ITERATOR_PROTOTYPE=!isObject(IteratorPrototype)||fails(function(){var test={};return IteratorPrototype[ITERATOR].call(test)!==test});NEW_ITERATOR_PROTOTYPE?IteratorPrototype={}:IS_PURE&&(IteratorPrototype=create(IteratorPrototype));isCallable(IteratorPrototype[ITERATOR])||defineBuiltIn(IteratorPrototype,ITERATOR,function(){return this});module.exports={IteratorPrototype,BUGGY_SAFARI_ITERATORS}}});var require_esnext_iterator_constructor=__commonJS({"node_modules/core-js/modules/esnext.iterator.constructor.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),global=require_global(),anInstance=require_an_instance(),anObject=require_an_object(),isCallable=require_is_callable(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltInAccessor=require_define_built_in_accessor(),createProperty=require_create_property(),fails=require_fails(),hasOwn=require_has_own_property(),wellKnownSymbol=require_well_known_symbol(),IteratorPrototype=require_iterators_core().IteratorPrototype,DESCRIPTORS=require_descriptors(),IS_PURE=require_is_pure(),CONSTRUCTOR="constructor",ITERATOR="Iterator",TO_STRING_TAG=wellKnownSymbol("toStringTag"),$TypeError=TypeError,NativeIterator=global[ITERATOR],FORCED=IS_PURE||!isCallable(NativeIterator)||NativeIterator.prototype!==IteratorPrototype||!fails(function(){NativeIterator({})}),IteratorConstructor=function(){if(anInstance(this,IteratorPrototype),getPrototypeOf(this)===IteratorPrototype)throw new $TypeError("Abstract class Iterator not directly constructable")},defineIteratorPrototypeAccessor=function(key,value){DESCRIPTORS?defineBuiltInAccessor(IteratorPrototype,key,{configurable:!0,get:function(){return value},set:function(replacement){if(anObject(this),this===IteratorPrototype)throw new $TypeError("You can't redefine this property");hasOwn(this,key)?this[key]=replacement:createProperty(this,key,replacement)}}):IteratorPrototype[key]=value};hasOwn(IteratorPrototype,TO_STRING_TAG)||defineIteratorPrototypeAccessor(TO_STRING_TAG,ITERATOR);(FORCED||!hasOwn(IteratorPrototype,CONSTRUCTOR)||IteratorPrototype[CONSTRUCTOR]===Object)&&defineIteratorPrototypeAccessor(CONSTRUCTOR,IteratorConstructor);IteratorConstructor.prototype=IteratorPrototype;$2({global:!0,constructor:!0,forced:FORCED},{Iterator:IteratorConstructor})}});var require_function_uncurry_this_clause=__commonJS({"node_modules/core-js/internals/function-uncurr
35y-this-clause.js"(exports,module){"use strict";init_define_process_env();init_shim();var classofRaw=require_classof_raw(),uncurryThis=require_function_uncurry_this();module.exports=function(fn){if(classofRaw(fn)==="Function")return uncurryThis(fn)}}});var require_function_bind_context=__commonJS({"node_modules/core-js/internals/function-bind-context.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this_clause(),aCallable=require_a_callable(),NATIVE_BIND=require_function_bind_native(),bind=uncurryThis(uncurryThis.bind);module.exports=function(fn,that){return aCallable(fn),that===void 0?fn:NATIVE_BIND?bind(fn,that):function(){return fn.apply(that,arguments)}}}});var require_iterators=__commonJS({"node_modules/core-js/internals/iterators.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports={}}});var require_is_array_iterator_method=__commonJS({"node_modules/core-js/internals/is-array-iterator-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var wellKnownSymbol=require_well_known_symbol(),Iterators=require_iterators(),ITERATOR=wellKnownSymbol("iterator"),ArrayPrototype=Array.prototype;module.exports=function(it){return it!==void 0&&(Iterators.Array===it||ArrayPrototype[ITERATOR]===it)}}});var require_to_string_tag_support=__commonJS({"node_modules/core-js/internals/to-string-tag-support.js"(exports,module){"use strict";init_define_process_env();init_shim();var wellKnownSymbol=require_well_known_symbol(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),test={};test[TO_STRING_TAG]="z";module.exports=String(test)==="[object z]"}});var require_classof=__commonJS({"node_modules/core-js/internals/classof.js"(exports,module){"use strict";init_define_process_env();init_shim();var TO_STRING_TAG_SUPPORT=require_to_string_tag_support(),isCallable=require_is_callable(),classofRaw=require_classof_raw(),wellKnownSymbol=require_well_known_symbol(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),$Object=Object,CORRECT_ARGUMENTS=classofRaw(function(){return arguments}())==="Arguments",tryGet=function(it,key){try{return it[key]}catch{}};module.exports=TO_STRING_TAG_SUPPORT?classofRaw:function(it){var O,tag,result;return it===void 0?"Undefined":it===null?"Null":typeof(tag=tryGet(O=$Object(it),TO_STRING_TAG))=="string"?tag:CORRECT_ARGUMENTS?classofRaw(O):(result=classofRaw(O))==="Object"&&isCallable(O.callee)?"Arguments":result}}});var require_get_iterator_method=__commonJS({"node_modules/core-js/internals/get-iterator-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var classof=require_classof(),getMethod=require_get_method(),isNullOrUndefined=require_is_null_or_undefined(),Iterators=require_iterators(),wellKnownSymbol=require_well_known_symbol(),ITERATOR=wellKnownSymbol("iterator");module.exports=function(it){if(!isNullOrUndefined(it))return getMethod(it,ITERATOR)||getMethod(it,"@@iterator")||Iterators[classof(it)]}}});var require_get_iterator=__commonJS({"node_modules/core-js/internals/get-iterator.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),tryToString=require_try_to_string(),getIteratorMethod=require_get_iterator_method(),$TypeError=TypeError;module.exports=function(argument,usingIterator){var iteratorMethod=arguments.length<2?getIteratorMethod(argument):usingIterator;if(aCallable(iteratorMethod))return anObject(call(iteratorMethod,argument));throw new $TypeError(tryToString(argument)+" is not iterable")}}});var require_iterator_close=__commonJS({"node_modules/core-js/internals/iterator-close.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),anObject=require_an_object(),getMethod=require_get_method();module.exports=function(iterator,kind,value){var innerResult,innerError;anObject(iterator);try{if(innerResult=getMethod(iterator,"return"),!innerResult){if(kind==="throw")throw value;return value}innerResult=call(innerResult,iterator)}catch(error){innerError=!0,innerResult=error}if(kind==="throw")throw value;if(innerError)throw innerResult;return anObject(innerResult),value}}});var require_iterate=__commonJS({"node_modules/core-js/internals/iterate.js"(exports,module){"use strict";init_define_process_env();init_shim();var bind=require_function_bind_context(),call=require_function_call(),anObject=require_an_object(),tryToString=require_try_to_string(),isArrayIteratorMethod=require_is_array_iterator_method(),lengthOfArrayLike=require_length_of_array_like(),isPrototypeOf=require_object_is_prototype_of(),getIterator=require_get_iterator(),getIteratorMethod=require_get_iterator_method(),iteratorClose=require_iterator_close(),$TypeError=TypeError,Result=function(stopped,result){this.stopped=stopped,this.result=result},ResultPrototype=Result.prototype;module.exports=function(iterable,unboundFunction,options){var that=options&&options.that,AS_ENTRIES=!!(options&&options.AS_ENTRIES),IS_RECORD=!!(options&&options.IS_RECORD),IS_ITERATOR=!!(options&&options.IS_ITERATOR),INTERRUPTED=!!(options&&options.INTERRUPTED),fn=bind(unboundFunction,that),iterator,iterFn,index,length,result,next,step,stop=function(condition){return iterator&&iteratorClose(iterator,"normal",condition),new Result(!0,condition)},callFn=function(value){return AS_ENTRIES?(anObject(value),INTERRUPTED?fn(value[0],value[1],stop):fn(value[0],value[1])):INTERRUPTED?fn(value,stop):fn(value)};if(IS_RECORD)iterator=iterable.iterator;else if(IS_ITERATOR)iterator=iterable;else{if(iterFn=getIteratorMethod(iterable),!iterFn)throw new $TypeError(tryToString(iterable)+" is not iterable");if(isArrayIteratorMethod(iterFn)){for(index=0,length=lengthOfArrayLike(iterable);length>index;index++)if(result=callFn(iterable[index]),result&&isPrototypeOf(ResultPrototype,result))return result;return new Result(!1)}iterator=getIterator(iterable,iterFn)}for(next=IS_RECORD?iterable.next:iterator.next;!(step=call(next,iterator)).done;){try{result=callFn(step.value)}catch(error){iteratorClose(iterator,"throw",error)}if(typeof result=="object"&&result&&isPrototypeOf(ResultPrototype,result))return result}return new Result(!1)}}});var require_get_iterator_direct=__commonJS({"node_modules/core-js/internals/get-iterator-direct.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(obj){return{iterator:obj,next:obj.next,done:!1}}}});var require_esnext_iterator_find=__commonJS({"node_modules/core-js/modules/esnext.iterator.find.js"(
35){"use strict";init_define_process_env();init_shim();var $2=require_export(),iterate=require_iterate(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct();$2({target:"Iterator",proto:!0,real:!0},{find:function(predicate){anObject(this),aCallable(predicate);var record=getIteratorDirect(this),counter=0;return iterate(record,function(value,stop){if(predicate(value,counter++))return stop(value)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})}});function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var u,base_safe_require,legacy_keys,safe_require,init_window_register=__esm({"lib-browser/window_register.js"(){"use strict";init_define_process_env();init_shim();u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register}}});var ionic_IonicIcon_exports={};__export(ionic_IonicIcon_exports,{additional_data:()=>additional_data,initialize:()=>initialize,property_applications:()=>property_applications_internal});function initialize(instance){let canvas=instance.get_canvas();property_applications.patch_user_agent_styles(canvas),instance.wait_for_visible_lite(()=>{element_eval.on_property_change(instance,"icon",icon=>{let add=canvas.hasClass(runmode_consts.CLICKABLE_ELEMENT);canvas.attr("class",""),canvas.addClass(`${icon} inner-element bubble-element`),add&&canvas.addClass(runmode_consts.CLICKABLE_ELEMENT)}),element_eval.on_property_change(instance,"icon_color",icon_color=>canvas[0].style.color=icon_color),element_eval.on_property_change(instance,["height","top","left","width"],_ref=>{let{height}=_ref,correction=height*.08;canvas[0].style.height=`${correction+height}px`,canvas[0].style["margin-top"]=`${-correction}px`}),icons_legacy.calculate_font_size_for_fontawesome(instance)})}var property_applications,runmode_consts,element_eval,icons_legacy,property_applications_internal,additional_data,init_ionic_IonicIcon=__esm({"lib-browser/optional/services/legacy/responsive_v0/ionic_IonicIcon.js"(){"use strict";init_define_process_env();init_shim();init_window_register();property_applications=safe_require.safe_require("./core/property_applications"),runmode_consts=safe_require.safe_require("./constants/runmode"),element_eval=safe_require.safe_require("./lang/evaluation/element_eval"),icons_legacy=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/shared/icons"),property_applications_internal=[new property_applications.MinWidth];additional_data={notify_width(instance,width){instance.state("notify_width",width)}}}});init_define_process_env();init_shim();var import_esnext_iterator_constructor=__toESM(require_esnext_iterator_constructor()),import_esnext_iterator_find=__toESM(require_esnext_iterator_find());init_window_register();var external=safe_require.safe_require("./external"),services=safe_require.safe_require("./services"),Lib=safe_require.safe_require("./lib"),appquery=safe_require.safe_require("./lang/appquery"),shared_fields=safe_require.safe_require("./core/shared_fields"),inputs=safe_require.safe_require("./core/core_elements/shared/inputs"),element_workflows=safe_require.safe_require("./core/core_elements/core_elements_utilities/element_workflows"),property_applications2=safe_require.safe_require("./core/property_applications"),runmode_consts2=safe_require.safe_require("./constants/runmode"),icons=safe_require.safe_require("./core/core_elements/shared/icons"),element_eval2=safe_require.safe_require("./lang/evaluation/element_eval"),element_modifications=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/element_modifications"),goToElementEvent,core_elements_fields,shared_field_metadata;u.is_edit_mode()&&!u.is_plugin_edit_mode()&&({goToElementEvent}=safe_require.safe_require("./editor/workflow_tab/logic/events"));u.uses_field_metadata()&&(core_elements_fields=safe_require.safe_require("./core/core_elements_fields"),core_elements_fields=core_elements_fields.default??core_elements_fields,shared_field_metadata=safe_require.safe_require("./core/shared_field_metadata"));element_modifications.set_legacy_element_modifications("ionic-IonicIcon",(init_ionic_IonicIcon(),__toCommonJS(ionic_IonicIcon_exports)));element_modifications.set_legacy_element_modifications("ionic-IonicToggle",{});element_modifications.set_legacy_element_modifications("ionic-IonicCheckbox",{});element_modifications.set_legacy_element_modifications("ionic-IonicRange");var PLUGIN_FILE="ionic";function _include_user_non_select(div){div.css({"webkit-user-select":"none","-khtml-user-select":"none","-moz-user-select":"none","-o-user-select":"none","user-select":"none"})}var _checkbox_field_names=u.extend({contents:{default:"checked"},dynamic:{},mandatory:{no_states:!0},color:{default:"balanced",in_style:!0}},inputs.get_disabled_field_name,inputs.get_auto_binding_field_names);function to_bool(val){return typeof val=="string"&&["false","no","null","none","undefined"].includes(val.toLowerCase())&&(val=!1),!!val}function checkbox_get_starting_content(instance){if(instance.get_static_property("auto_binding"))return input
35s.get_input_autobind_thing_field(instance);let content=element_eval2.evaluate_property(instance,"contents");return content==="checked"?!0:content==="unchecked"?!1:element_eval2.evaluate_property(instance,"dynamic")}function checkbox_content_validated(val,instance){return val!=null||!instance.get_static_property("mandatory")}function plugin_version(){return Lib()?appquery.get_public_setting("ionic_installed_version")??0:1}function uses_css_responsive(){return Lib()?plugin_version()>=1||appquery.get_public_setting("ionic_css_responsive")===!0:!0}var cls=class extends external.Service{constructor(){super(),this.authenticator=new external.NoAuth,this.elements=this._get_initial_elements()}_get_initial_elements(){return{IonicToggle:{display:"Ionic Toggle",category:"input forms",icon:"ion-toggle-filled",condition(root){return!root?.is_mobile?.()},defaults:{width:51,height:31},field_names:_checkbox_field_names,primary_field(){},_fields(element){return _checkbox_fields(element)},mandatory_sections(){return["IonicContent"]},get_field_metadata(element){return{...shared_field_metadata.get_is_visible_property(),...shared_field_metadata.get_binding_properties(element,()=>["boolean"],()=>!0),...checkbox_field_metadata(element),...new property_applications2.PositionOnly().get_property_metadata(element),...new property_applications2.ResponsiveElement().get_property_metadata(element),...new property_applications2.UniqueID().get_property_metadata(element)}},property_applications:[new property_applications2.PositionOnly,new property_applications2.ResponsiveElement],get uses_css_responsive(){return uses_css_responsive()},get_html(instance){return"<div></div>"},initialize(instance){return services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE}),instance.wait_for_visible_lite(()=>{let html=`<label class="ionic-toggle"> 36 <input type="checkbox"> 37 <div class="ionic-track"> 38 <div class="ionic-handle"></div> 39 </div> 40</label>`,canvas=instance.get_canvas();canvas.append($(html));let toggle_element=canvas.find(".ionic-toggle");if(instance.edit_mode()){let{element}=instance;element.set_property("width",51),element.set_property("height",31)}instance.run_mode()&&(canvas.addClass(runmode_consts2.CLICKABLE_ELEMENT),canvas.css({overflow:"visible"})),element_eval2.on_property_change(instance,"color",color=>{toggle_element.attr("class","");let class_name="ionic-toggle toggle-"+color;toggle_element.attr("class",class_name)}),_include_user_non_select(canvas);let ip=canvas.find("input");return instance.run_mode()&&(ip.change(()=>(instance.message("user_submit",ip[0].checked??!1),!0)),element_eval2.on_property_change(instance,"disabled",value=>{ip[0].disabled=value})),inputs.input_change_autorun(instance,val=>{ip[0].checked=to_bool(val)})})},get_starting_content:checkbox_get_starting_content,get_state_value(element,name){if(name==="value")return"sys.bool"},content_validated:checkbox_content_validated,change_cursor_style_if_clickable:!1,add_an_invisible_div_on_the_top:!0,register(instance){inputs.register_checkbox_states(this,instance)},is_input:!0,is_checkbox:!0,contains_group_data:!1,not_resizable(){return!0},no_is_focused:!0,css_files:["css/optional/ionic/toggle.css"],actions:["ResetInputs"]},IonicCheckbox:{display:"Ionic Checkbox",category:"input forms",icon:"ion-checkmark-circled",condition(root){return!root?.is_mobile?.()},defaults:{width:28,height:28},field_names:_checkbox_field_names,primary_field(){},_fields(element){return _checkbox_fields(element)},mandatory_sections(){return["IonicContent"]},get_field_metadata(element){return{...shared_field_metadata.get_is_visible_property(),...shared_field_metadata.get_binding_properties(element,()=>["boolean"],()=>!0),...checkbox_field_metadata(element),...new property_applications2.PositionOnly().get_property_metadata(element),...new property_applications2.ResponsiveElement().get_property_metadata(element),...new property_applications2.UniqueID().get_property_metadata(element)}},property_applications:[new property_applications2.PositionOnly,new property_applications2.ResponsiveElement],get uses_css_responsive(){return uses_css_responsive()},get_html(instance){return"<div></div>"},initialize(instance){return services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE}),instance.wait_for_visible_lite(()=>{let html=`<label class="ionic-checkbox"> 41 <input type="checkbox"> 42</label>`,canvas=instance.get_canvas();canvas.append($(html));let toggle_element=canvas.find(".ionic-checkbox");if(element_eval2.on_property_change(instance,"color",color=>{toggle_element.attr("class","");let class_name="ionic-checkbox checkbox-"+color;toggle_element.attr("class",class_name)}),_include_user_non_select(canvas),instance.edit_mode()){let{element}=instance;element.set_property("width",28),element.set_property("height",28)}let ip=canvas.find("input");return instance.run_mode()&&(canvas.addClass(runmode_consts2.CLICKABLE_ELEMENT),ip.change(()=>(instance.message("user_submit",ip[0].checked??!1),!0)),element_eval2.on_property_change(instance,"disabled",value=>{ip[0].disabled=value})),inputs.input_change_autorun(instance,val=>{ip[0].checked=to_bool(val)})})},get_starting_content:checkbox_get_starting_content,get_state_value(element,name){if(name==="value")return"sys.bool"},content_validated:checkbox_content_validated,change_cursor_style_if_clickable:!1,add_an_invisible_div_on_the_top:!0,register(instance){inputs.register_checkbox_states(this,instance)},is_input:!0,is_checkbox:!0,contains_group_data:!1,not_resizable(){return!0},no_is_focused:!0,css_files:["css/optional/ionic/checkbox.css"],actions:["ResetInputs"]},IonicRange:{display:"Ionic Range",category:"input forms",icon:"ion-ios-settings",condition(root){return!root?.is_mobile?.()},defaults:{width:300,height:58},field_names:u.extend({min:{default:0},max:{default:10},step:{default:1},content:{},color:{default:"balanced"}},inputs.get_disabled_field_name,inputs.get_auto_binding_field_names),property_applications:[new property_applications2.Dimensions,new property_applications2.Backgroun
42d,new property_applications2.Border,new property_applications2.BoxShadow,new property_applications2.ResponsiveElement],get uses_css_responsive(){return uses_css_responsive()},get_html(instance){return"<div></div>"},get_min_width(){return 0},initialize(instance){return services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE}),instance.wait_for_visible_lite(()=>{let html=`<div class="item ionic-range"> 43 <input type="range" min="0" max="100" value="33"> 44</div>`,canvas=instance.get_canvas();canvas.append($(html));let range_element=canvas.find(".ionic-range");element_eval2.on_property_change(instance,"color",color=>{range_element.attr("class","");let class_name="ionic-range range-"+color;range_element.attr("class",class_name)}),element_eval2.on_property_change(instance,["min","max","step"],res=>{for(let key in res){let val=res[key];canvas.find("input").attr(key,val)}}),_include_user_non_select(canvas);let ip=canvas.find("input");return instance.run_mode()&&(canvas.addClass(runmode_consts2.CLICKABLE_ELEMENT),ip.change(()=>(instance.message("user_submit",ip[0].value??0),!0)),element_eval2.on_property_change(instance,"disabled",value=>{ip[0].disabled=value})),inputs.input_change_autorun(instance,val=>{ip[0].value=val})})},get_starting_content(instance){return instance.edit_mode()?element_eval2.evaluate_property(instance,"content")??(element_eval2.evaluate_property(instance,"min")+element_eval2.evaluate_property(instance,"max"))/2:instance.get_static_property("auto_binding")?inputs.get_input_autobind_thing_field(instance):element_eval2.evaluate_property(instance,"content")??element_eval2.evaluate_property(instance,"min")??0},get_state_value(element,name){if(name==="value")return"number"},change_cursor_style_if_clickable:!1,add_an_invisible_div_on_the_top:!0,is_input:!0,contains_group_data:!1,no_is_focused:!0,css_files:["css/optional/ionic/range.css"],actions:["ResetInputs"]},IonicIcon:{display:"Ionic Icon",category:"visual elements",icon:"ion-ionic",condition(root){return!root?.is_mobile?.()},defaults:{font_alignment:"center",background_style:"none",border_style:"none",border_roundness:4,border_width:2,border_color:"#6B6B6B",boxshadow_style:"none",width:80,height:80},field_names:u.extend({icon:{default:"ion-ionic"},icon_color:{default:"#373737",in_style:!0}},element_workflows.start_workflow_field_names),property_applications:[new property_applications2.Dimensions,new property_applications2.FontShadow,new property_applications2.Border,new property_applications2.BoxShadow,new property_applications2.Background,new property_applications2.ResponsiveElement,new property_applications2.ToolTip],uses_css_responsive:!0,get_html(instance){return"<button></button>"},get_min_width(element){return 0},transition_properties:{icon_color:"color"},change_cursor_style_if_clickable:!0,initialize(instance){services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE});let canvas=instance.get_canvas();property_applications2.patch_user_agent_styles(canvas),instance.wait_for_visible_lite(()=>{$(document).ready(()=>{instance.autorun(()=>{canvas.empty();let icon=element_eval2.evaluate_property(instance,"icon");canvas.append(icons.get_icon_svg("ionicons",icon)),element_eval2.evaluate_property(instance,"button_disabled")&&canvas.attr("tabindex","-1")})}),element_eval2.on_property_change(instance,"icon_color",icon_color=>{canvas[0].style.color=icon_color})})},is_input:!1,contains_group_data:!1,events:["ButtonClicked","ElementPressed"],add_an_invisible_div_on_the_top:!1,css_files:["css/optional/ionic/ionicons.min.css"]}}}keys(){return plugin_version()>=1?{}:{css_responsive:{caption:"Use new responsive properties for this plugin's elements",type:"client_safe",editor:"Checkbox"}}}},ionic={cls};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.ionic=ionic);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("ionic",ionic);})(); 45/*! Bundled license information: 46 47buffer/index.js: 48 (*! 49 * The buffer module from node.js, for the browser. 50 * 51 * @author Feross Aboukhadijeh <https://feross.org> 52 * @license MIT 53 *) 54*/ 55 56} 57 58
vendor: 6,782 bytes, lines 59-64
59window.preloaded['plugin/first_party:ionic'] = true; 60window._bubble_page_load_data.hardcoded_plugins['select2'] = true; 61window.__code__ = window.__code__ || {}; 62if(!window.__code__['72cfda4646fc75796175600b74cb4f4b4a2df064438392d2a6ac4f61e51d8d36']){window.__code__['72cfda4646fc75796175600b74cb4f4b4a2df064438392d2a6ac4f61e51d8d36']=1; 63 64"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exports:{}}).exports,mod),mod.exports};var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod)),__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>
vendor: 23,595 bytes, line 64
64K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 64
64)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 64
64if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
64var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});var require_global=__commonJS({"node_modules/core-js/internals/global.js"(exports,module){"use strict";init_define_process_env();init_shim();var check=function(it){return it&&it.Math===Math&&it};module.exports=check(typeof globalThis=="object"&&globalThis)||check(typeof window=="object"&&window)||check(typeof self=="object"&&self)||check(typeof window=="object"&&window)||check(typeof exports=="object"&&exports)||function(){return this}()||Function("return this")()}});var require_fails=__commonJS({"node_modules/core-js/internals/fails.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(exec){try{return!!exec()}catch{return!0}}}});var require_descriptors=__commonJS({"node_modules/core-js/internals/descriptors.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})}});var require_function_bind_native=__commonJS({"node_modules/core-js/internals/function-bind-native.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){var test=(function(){}).bind();return typeof test!="function"||test.hasOwnProperty("prototype")})}});var require_function_call=__commonJS({"node_modules/core-js/internals/function-call.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),call=Function.prototype.call;module.exports=NATIVE_BIND?call.bind(call):function(){return call.apply(call,arguments)}}});var require_object_property_is_enumerable=__commonJS({"node_modules/core-js/internals/object-property-is-enumerable.js"(exports){"use strict";init_define_process_env();init_shim();var $propertyIsEnumerable={}.propertyIsEnumerable,getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,NASHORN_BUG=getOwnPropertyDescriptor&&!$propertyIsEnumerable.call({1:2},1);exports.f=NASHORN_BUG?function(V){var descriptor=getOwnPropertyDescriptor(this,V);return!!descriptor&&descriptor.enumerable}:$propertyIsEnumerable}});var require_create_property_descriptor=__commonJS({"node_modules/core-js/internals/create-property-descriptor.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(bitmap,value){return{enumerable:!(bitmap&1),configurable:!(bitmap&2),writable:!(bitmap&4),value}}}});var require_function_uncurry_this=__commonJS({"node_modules/core-js/internals/function-uncurr
64y-this.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),FunctionPrototype=Function.prototype,call=FunctionPrototype.call,uncurryThisWithBind=NATIVE_BIND&&FunctionPrototype.bind.bind(call,call);module.exports=NATIVE_BIND?uncurryThisWithBind:function(fn){return function(){return call.apply(fn,arguments)}}}});var require_classof_raw=__commonJS({"node_modules/core-js/internals/classof-raw.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toString=uncurryThis({}.toString),stringSlice=uncurryThis("".slice);module.exports=function(it){return stringSlice(toString(it),8,-1)}}});var require_indexed_object=__commonJS({"node_modules/core-js/internals/indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),classof=require_classof_raw(),$Object=Object,split=uncurryThis("".split);module.exports=fails(function(){return!$Object("z").propertyIsEnumerable(0)})?function(it){return classof(it)==="String"?split(it,""):$Object(it)}
64:$Object}});var require_is_null_or_undefined=__commonJS({"node_modules/core-js/internals/is-null-or-undefined.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(it){return it==null}}});var require_require_object_coercible=__commonJS({"node_modules/core-js/internals/require-object-coercible.js"(exports,module){"use strict";init_define_process_env();init_shim();var isNullOrUndefined=require_is_null_or_undefined(),$TypeError=TypeError;module.exports=function(it){if(isNullOrUndefined(it))throw new $TypeError("Can't call method on "+it);return it}}});var require_to_indexed_object=__commonJS({"node_modules/core-js/internals/to-indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var IndexedObject=require_indexed_object(),requireObjectCoercible=require_require_object_coercible();module.exports=function(it){return IndexedObject(requireObjectCoercible(it))}}});var require_is_callable=__commonJS({"node_modules/core-js/internals/is-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var documentAll=typeof document=="object"&&document.all;module.exports=typeof documentAll>"u"&&documentAll!==void 0?function(argument){return typeof argument=="function"||argument===documentAll}:function(argument){return typeof argument=="function"}}});var require_is_object=__commonJS({"node_modules/core-js/internals/is-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable();module.exports=function(it){return typeof it=="object"?it!==null:isCallable(it)}}});var require_get_built_in=__commonJS({"node_modules/core-js/internals/get-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),aFunction=function(argument){return isCallable(argument)?argument:void 0};module.exports=function(namespace,method){return arguments.length<2?aFunction(global[namespace]):global[namespace]&&global[namespace][method]}}});var require_object_is_prototype_of=__commonJS({"node_modules/core-js/internals/object-is-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this();module.exports=uncurryThis({}.isPrototypeOf)}});var require_engine_user_agent=__commonJS({"node_modules/core-js/internals/engine-user-agent.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=typeof navigator<"u"&&String(navigator.userAgent)||""}});var require_engine_v8_version=__commonJS({"node_modules/core-js/internals/engine-v8-version.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),userAgent=require_engine_user_agent(),process2=global.process,Deno=global.Deno,versions=process2&&process2.versions||Deno&&Deno.version,v8=versions&&versions.v8,match,version;v8&&(match=v8.split("."),version=match[0]>0&&match[0]<4?1:+(match[0]+match[1]));!version&&userAgent&&(match=userAgent.match(/Edge\/(\d+)/),(!match||match[1]>=74)&&(match=userAgent.match(/Chrome\/(\d+)/),match&&(version=+match[1])));module.exports=version}});var require_symbol_constructor_detection=__commonJS({"node_modules/core-js/internals/symbol-constructor-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var V8_VERSION=require_engine_v8_version(),fails=require_fails(),global=require_global(),$String=global.String;module.exports=!!Object.getOwnPropertySymbols&&!fails(function(){var symbol=Symbol("symbol detection");return!$String(symbol)||!(Object(symbol)instanceof Symbol)||!Symbol.sham&&V8_VERSION&&V8_VERSION<41})}});var require_use_symbol_as_uid=__commonJS({"node_modules/core-js/internals/use-symbol-as-uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_SYMBOL=require_symbol_constructor_detection();module.exports=NATIVE_SYMBOL&&!Symbol.sham&&typeof Symbol.iterator=="symbol"}});var require_is_symbol=__commonJS({"node_modules/core-js/internals/is-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),isCallable=require_is_callable(),isPrototypeOf=require_object_is_prototype_of(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),$Object=Object;module.exports=USE_SYMBOL_AS_UID?function(it){return typeof it=="symbol"}:function(it){var $Symbol=getBuiltIn("Symbol");return isCallable($Symbol)&&isPrototypeOf($Symbol.prototype,$Object(it))}}});var require_try_to_string=__commonJS({"node_modules/core-js/internals/try-to-string.js"(exports,module){"use strict";init_define_process_env();init_shim();var $String=String;module.exports=function(argument){try{return $String(argument)}catch{return"Object"}}}});var require_a_callable=__commonJS({"node_modules/core-js/internals/a-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),tryToString=require_try_to_string(),$TypeError=TypeError;module.exports=function(argument){if(isCallable(argument))return argument;throw new $TypeError(tryToString(argument)+" is not a function")}}});var require_get_method=__commonJS({"node_modules/core-js/internals/get-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var aCallable=require_a_callable(),isNullOrUndefined=require_is_null_or_undefined();module.exports=function(V,P){var func=V[P];return isNullOrUndefined(func)?void 0:aCallable(func)}}});var require_ordinary_to_primitive=__commonJS({"node_modules/core-js/internals/ordinary-to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isCallable=require_is_callable(),isObject=require_is_object(),$TypeError=TypeError;module.exports=function(input,pref){var fn,val;if(pref==="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input))||isCallable(fn=input.valueOf)&&!isObject(val=call(fn,input))||pref!=="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input)))return val;throw new $TypeError("Can't convert object to primitive value")}}});var require_is_pure=__commonJS({"node_modules/core-js/internals/is-pure.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=!1}});var require_define_global_property=__commonJS({"node_modules/core-js/internals/define-global-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineProperty=Object.defineProperty;module.exports=function(key,value){try{defineProperty(global,key,{value,configurable:!0,writable:!0})}catch{global[key]=value}return value}}});var require_shared_store=__commonJS({"node_modules/core-js/internals/shared-store.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineGlobalProperty=require_define_global_property(),SHARED="__core-js_shared__",store=global[SHARED]||defineGlobalProperty(S
64HARED,{});module.exports=store}});var require_shared=__commonJS({"node_modules/core-js/internals/shared.js"(exports,module){"use strict";init_define_process_env();init_shim();var IS_PURE=require_is_pure(),store=require_shared_store();(module.exports=function(key,value){return store[key]||(store[key]=value!==void 0?value:{})})("versions",[]).push({version:"3.35.1",mode:IS_PURE?"pure":"global",copyright:"\xA9 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE",source:"https://github.com/zloirock/core-js"})}});var require_to_object=__commonJS({"node_modules/core-js/internals/to-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var requireObjectCoercible=require_require_object_coercible(),$Object=Object;module.exports=function(argument){return $Object(requireObjectCoercible(argument))}}});var require_has_own_property=__commonJS({"node_modules/core-js/internals/has-own-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toObject=require_to_object(),hasOwnProperty=uncurryThis({}.hasOwnProperty);module.exports=Object.hasOwn||function(it,key){return hasOwnProperty(toObject(it),key)}}});var require_uid=__commonJS({"node_modules/core-js/internals/uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),id=0,postfix=Math.random(),toString=uncurryThis(1 .toString);module.exports=function(key){return"Symbol("+(key===void 0?"":key)+")_"+toString(++id+postfix,36)}}});var require_well_known_symbol=__commonJS({"node_modules/core-js/internals/well-known-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),shared=require_shared(),hasOwn=require_has_own_property(),uid=require_uid(),NATIVE_SYMBOL=require_symbol_constructor_detection(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),Symbol2=global.Symbol,WellKnownSymbolsStore=shared("wks"),createWellKnownSymbol=USE_SYMBOL_AS_UID?Symbol2.for||Symbol2:Symbol2&&Symbol2.withoutSetter||uid;module.exports=function(name){return hasOwn(WellKnownSymbolsStore,name)||(WellKnownSymbolsStore[name]=NATIVE_SYMBOL&&hasOwn(Symbol2,name)?Symbol2[name]:createWellKnownSymbol("Symbol."+name)),WellKnownSymbolsStore[name]}}});var require_to_primitive=__commonJS({"node_modules/core-js/internals/to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isObject=require_is_object(),isSymbol
64=require_is_symbol(),getMethod=require_get_method(),ordinaryToPrimitive=require_ordinary_to_primitive(),wellKnownSymbol=require_well_known_symbol(),$TypeError=TypeError,TO_PRIMITIVE=wellKnownSymbol("toPrimitive");module.exports=function(input,pref){if(!isObject(input)||isSymbol(input))return input;var exoticToPrim=getMethod(input,TO_PRIMITIVE),result;if(exoticToPrim){if(pref===void 0&&(pref="default"),result=call(exoticToPrim,input,pref),!isObject(result)||isSymbol(result))return result;throw new $TypeError("Can't convert object to primitive value")}return pref===void 0&&(pref="number"),ordinaryToPrimitive(input,pref)}}});var require_to_property_key=__commonJS({"node_modules/core-js/internals/to-property-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPrimitive=require_to_primitive(),isSymbol=require_is_symbol();module.exports=function(argument){var key=toPrimitive(argument,"string");return isSymbol(key)?key:key+""}}});var require_document_create_element=__commonJS({"node_modules/core-js/internals/document-create-element.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isObject=require_is_object(),document2=global.document,EXISTS=isObject(document2)&&isObject(document2.createElement);module.exports=function(it){return EXISTS?document2.createElement(it):{}}}});var require_ie8_dom_define=__commonJS({"node_modules/core-js/internals/ie8-dom-define.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails(),createElement=require_document_create_element();module.exports=!DESCRIPTORS&&!fails(function(){return Object.defineProperty(createElement("div"),"a",{get:function(){return 7}}).a!==7})}});var require_object_get_own_property_descriptor=__commonJS({"node_modules/core-js/internals/object-get-own-property-descriptor.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),call=require_function_call(),propertyIsEnumerableModule=require_object_property_is_enumerable(),createPropertyDescriptor=require_create_property_descriptor(),toIndexedObject=require_to_indexed_object(),toPropertyKey=require_to_property_key(),hasOwn=require_has_own_property(),IE8_DOM_DEFINE=require_ie8_dom_define(),$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor;exports.f=DESCRIPTORS?$getOwnPropertyDescriptor:function(O,P){if(O=toIndexedObject(O),P=toPropertyKey(P),IE8_DOM_DEFINE)try{return $getOwnPropertyDescriptor(O,P)}catch{}if(hasOwn(O,P))return createPropertyDescriptor(!call(propertyIsEnumerableModule.f,O,P),O[P])}}});var require_v8_prototype_define_bug=__commonJS({"node_modules/core-js/internals/v8-prototype-define-bug.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails();module.exports=DESCRIPTORS&&fails(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})}});var require_an_object=__commonJS({"node_modules/core-js/internals/an-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isObject=require_is_object(),$String=String,$TypeError=TypeError;module.exports=function(argument){if(isObject(argument))return argument;throw new $TypeError($String(argument)+" is not an object")}}});var require_object_define_property=__commonJS({"node_modules/core-js/internals/object-define-property.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),IE8_DOM_DEFINE=require_ie8_dom_define(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),anObject=require_an_object(),toPropertyKey=require_to_property_key(),$TypeError=TypeError,$defineProperty=Object.defineProperty,$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,ENUMERABLE="enumerable",CONFIGURABLE="configurable",WRITABLE="writable";exports.f=DESCRIPTORS?V8_PROTOTYPE_DEFINE_BUG?function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),typeof O=="function"&&P==="prototype"&&"value"in Attributes&&WRITABLE in Attributes&&!Attributes[WRITABLE]){var current=$getOwnPropertyDescriptor(O,P);current&¤t[WRITABLE]&&(O[P]=Attributes.value,Attributes={configurable:CONFIGURABLE in Attributes?Attributes[CONFIGURABLE]:current[CONFIGURABLE],enumerable:ENUMERABLE in Attributes?Attributes[ENUMERABLE]:current[ENUMERABLE],writable:!1})}return $defineProperty(O,P,Attributes)}
64:$defineProperty:function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),IE8_DOM_DEFINE)try{return $defineProperty(O,P,Attributes)}catch{}if("get"in Attributes||"set"in Attributes)throw new $TypeError("Accessors not supported");return"value"in Attributes&&(O[P]=Attributes.value),O}}});var require_create_non_enumerable_property=__commonJS({"node_modules/core-js/internals/create-non-enumerable-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=DESCRIPTORS?function(object,key,value){return definePropertyModule.f(object,key,createPropertyDescriptor(1,value))}:function(object,key,value){return object[key]=value,object}}});var require_function_name=__commonJS({"node_modules/core-js/internals/function-name.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),hasOwn=require_has_own_property(),FunctionPrototype=Function.prototype,getDescriptor=DESCRIPTORS&&Object.getOwnPropertyDescriptor,EXISTS=hasOwn(FunctionPrototype,"name"),PROPER=EXISTS&&(function(){}).name==="something",CONFIGURABLE=EXISTS&&(!DESCRIPTORS||DESCRIPTORS&&getDescriptor(FunctionPrototype,"name").configurable);module.exports={EXISTS,PROPER,CONFIGURABLE}}});
64var require_inspect_source=__commonJS({"node_modules/core-js/internals/inspect-source.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),isCallable=require_is_callable(),store=require_shared_store(),functionToString=uncurryThis(Function.toString);isCallable(store.inspectSource)||(store.inspectSource=function(it){return functionToString(it)});module.exports=store.inspectSource}});var require_weak_map_basic_detection=__commonJS({"node_modules/core-js/internals/weak-map-basic-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),WeakMap=global.WeakMap;module.exports=isCallable(WeakMap)&&/native code/.test(String(WeakMap))}});var require_shared_key=__commonJS({"node_modules/core-js/internals/shared-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var shared=require_shared(),uid=require_uid(),keys=shared("keys");module.exports=function(key){return keys[key]||(keys[key]=uid(key))}}});var require_hidden_keys=__commonJS({"node_modules/core-js/internals/hidden-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports={}}});var require_internal_state=__commonJS({"node_modules/core-js/internals/internal-state.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_WEAK_MAP=require_weak_map_basic_detection(),global=require_global(),isObject=require_is_object(),createNonEnumerableProperty=require_create_non_enumerable_property(),hasOwn=require_has_own_property(),shared=require_shared_store(),sharedKey=require_shared_key(),hiddenKeys=require_hidden_keys(),OBJECT_ALREADY_INITIALIZED="Object already initialized",TypeError2=global.TypeError,WeakMap=global.WeakMap,set,get,has,enforce=function(it){return has(it)?get(it):set(it,{})},getterFor=function(TYPE){return function(it){var state;if(!isObject(it)||(state=get(it)).type!==TYPE)throw new TypeError2("Incompatible receiver, "+TYPE+" required");return state}};NATIVE_WEAK_MAP||shared.state?(store=shared.state||(shared.state=new WeakMap),store.get=store.get,store.has=store.has,store.set=store.set,set=function(it,metadata){if(store.has(it))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,store.set(it,metadata),metadata},get=function(it){return store.get(it)||{}},has=function(it){return store.has(it)}):(STATE=sharedKey("state"),hiddenKeys[STATE]=!0,set=function(it,metadata){if(hasOwn(it,STATE))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,createNonEnumerableProperty(it,STATE,metadata),metadata},get=function(it){return hasOwn(it,STATE)?it[STATE]:{}},has=function(it){return hasOwn(it,STATE)});var store,STATE;module.exports={set,get,has,enforce,getterFor}}});var require_make_built_in=__commonJS({"node_modules/core-js/internals/make-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),isCallable=require_is_callable(),hasOwn=require_has_own_property(),DESCRIPTORS=require_descriptors(),CONFIGURABLE_FUNCTION_NAME=require_function_name().CONFIGURABLE,inspectSource=require_inspect_source(),InternalStateModule=require_internal_state(),enforceInternalState=InternalStateModule.enforce,getInternalState=InternalStateModule.get,$String=String,defineProperty=Object.defineProperty,stringSlice=uncurryThis("".slice),replace=uncurryThis("".replace),join=uncurr
64yThis([].join),CONFIGURABLE_LENGTH=DESCRIPTORS&&!fails(function(){return defineProperty(function(){},"length",{value:8}).length!==8}),TEMPLATE=String(String).split("String"),makeBuiltIn=module.exports=function(value,name,options){stringSlice($String(name),0,7)==="Symbol("&&(name="["+replace($String(name),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),options&&options.getter&&(name="get "+name),options&&options.setter&&(name="set "+name),(!hasOwn(value,"name")||CONFIGURABLE_FUNCTION_NAME&&value.name!==name)&&(DESCRIPTORS?defineProperty(value,"name",{value:name,configurable:!0}):value.name=name),CONFIGURABLE_LENGTH&&options&&hasOwn(options,"arity")&&value.length!==options.arity&&defineProperty(value,"length",{value:options.arity});try{options&&hasOwn(options,"constructor")&&options.constructor?DESCRIPTORS&&defineProperty(value,"prototype",{writable:!1}):value.prototype&&(value.prototype=void 0)}catch{}var state=enforceInternalState(value);return hasOwn(state,"source")||(state.source=join(TEMPLATE,typeof name=="string"?name:"")),value};Function.prototype.toString=makeBuiltIn(function(){return isCallable(this)&&getInternalState(this).source||inspectSource(this)},"toString")}});var require_define_built_in=__commonJS({"node_modules/core-js/internals/define-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),definePropertyModule=require_object_define_property(),makeBuiltIn=require_make_built_in(),defineGlobalProperty=require_define_global_property();module.exports=function(O,key,value,options){options||(options={});var simple=options.enumerable,name=options.name!==void 0?options.name:key;if(isCallable(value)&&makeBuiltIn(value,name,options),options.global)simple?O[key]=value:defineGlobalProperty(key,value);else{try{options.unsafe?O[key]&&(simple=!0):delete O[key]}catch{}simple?O[key]=value:definePropertyModule.f(O,key,{value,enumerable:!1,configurable:!options.nonConfigurable,writable:!options.nonWritable})}return O}}});var require_math_trunc=__commonJS({"node_modules/core-js/internals/math-trunc.js"(exports,module){"use strict";init_define_process_env();init_shim();var ceil=Math.ceil,floor=Math.floor;module.exports=Math.trunc||function(x){var n=+x;return(n>0?floor:ceil)(n)}}});var require_to_integer_or_infinity=__commonJS({"node_modules/core-js/internals/to-integer-or-infinity.js"(exports,module){"use strict";init_define_process_env();init_shim();var trunc=require_math_trunc();module.exports=function(argument){var number=+argument;return number!==number||number===0?0:trunc(number)}}});var require_to_absolute_index=__commonJS({"node_modules/core-js/internals/to-absolute-index.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),max=Math.max,min=Math.min;module.exports=function(index,length){var integer=toIntegerOrInfinity(index);return integer<0?max(integer+length,0):min(integer,length)}}});var require_to_length=__commonJS({"node_modules/core-js/internals/to-length.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),min=Math.min;module.exports=function(argument){var len=toIntegerOrInfinity(argument);return len>0?min(len,9007199254740991):0}}});var require_length_of_array_like=__commonJS({"node_modules/core-js/internals/length-of-array-like.js"(exports,module){"use strict";init_define_process_env();init_shim();var toLength=require_to_length();module.exports=function(obj){return toLength(obj.length)}}});var require_array_includes=__commonJS({"node_modules/core-js/internals/array-includes.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIndexedObject=require_to_indexed_object(),toAbsoluteIndex=require_to_absolute_index(),lengthOfArrayLike=require_length_of_array_like(),createMethod=function(IS_INCLUDES){return function($this,el,fromIndex){var O=toIndexedObject($this),length=lengthOfArrayLike(O),index=toAbsoluteIndex(fromIndex,length),value;if(IS_INCLUDES&&el!==el){for(;length>index;)if(value=O[index++],value!==value)return!0}else for(;length>index;index++)if((IS_INCLUDES||index in O)&&O[index]===el)return IS_INCLUDES||index||0;return!IS_INCLUDES&&-1}};module.exports={includes:createMethod(!0),indexOf:createMethod(!1)}}});var require_object_keys_internal=__commonJS({"node_modules/core-js/internals/object-keys-internal.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),hasOwn=require_has_own_property(),toIndexedObject=require_to_indexed_object(),indexOf=require_array_includes().indexOf,hiddenKeys=require_hidden_keys(),push=uncurryThis([].push);module.exports=function(object,names){var O=toIndexedObject(object),i=0,result=[],key;for(key in O)!hasOwn(hiddenKeys,key)&&hasOwn(O,key)&&push(result,key);for(;names.length>i;)hasOwn(O,key=names[i++])&&(~indexOf(result,key)||push(result,key));return result}}});var require_enum_bug_keys=__commonJS({"node_modules/core-js/internals/enum-bug-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleStr
64ing","toString","valueOf"]}});var require_object_get_own_property_names=__commonJS({"node_modules/core-js/internals/object-get-own-property-names.js"(exports){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=enumBugKeys.concat("length","prototype");exports.f=Object.getOwnPropertyNames||function(O){return internalObjectKeys(O,hiddenKeys)}}});var require_object_get_own_property_symbols=__commonJS({"node_modules/core-js/internals/object-get-own-property-symbols.js"(exports){"use strict";init_define_process_env();init_shim();exports.f=Object.getOwnPropertySymbols}});var require_own_keys=__commonJS({"node_modules/core-js/internals/own-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),uncurryThis=require_function_uncurry_this(),getOwnPropertyNamesModule=require_object_get_own_property_names(),getOwnPropertySymbolsModule=require_object_get_own_property_symbols(),anObject=require_an_object(),concat=uncurryThis([].concat);module.exports=getBuiltIn("Reflect","ownKeys")||function(it){var keys=getOwnPropertyNamesModule.f(anObject(it)),getOwnPropertySymbols=getOwnPropertySymbolsModule.f;return getOwnPropertySymbols?concat(keys,getOwnPropertySymbols(it)):keys}}});var require_copy_constructor_properties=__commonJS({"node_modules/core-js/internals/copy-constructor-properties.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),ownKeys=require_own_keys(),getOwnPropertyDescriptorModule=require_object_get_own_property_descriptor(),definePropertyModule=require_object_define_property();module.exports=function(target,source,exceptions){for(var keys=ownKeys(source),defineProperty=definePropertyModule.f,getOwnPropertyDescriptor=getOwnPropertyDescriptorModule.f,i=0;i<keys.length;i++){var key=keys[i];!hasOwn(target,key)&&!(exceptions&&hasOwn(exceptions,key))&&defineProperty(target,key,getOwnPropertyDescriptor(source,key))}}}});var require_is_forced=__commonJS({"node_modules/core-js/internals/is-forced.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),replacement=/#|\.prototype\./,isForced=function(feature,detection){var value=data[normalize(feature)];return value===POLYFILL?!0:value===NATIVE?!1:isCallable(detection)?fails(detection):!!detection},normalize=isForced.normalize=function(string){return String(string).replace(replacement,".").toLowerCase()},data=isForced.data={},NATIVE=isForced.NATIVE="N",POLYFILL=isForced.POLYFILL="P";module.exports=isForced}});var require_export=__commonJS({"node_modules/core-js/internals/export.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),getOwnPropertyDescriptor=require_object_get_own_property_descriptor().f,createNonEnumerableProperty=require_create_non_enumerable_property(),defineBuiltIn=require_define_built_in(),defineGlobalProperty=require_define_global_property(),copyConstructorProperties=require_copy_constructor_properties(),isForced=require_is_forced();module.exports=function(options,source){var TARGET=options.target,GLOBAL=options.global,STATIC=options.stat,FORCED,target,key,targetProperty,sourceProperty,descriptor;if(GLOBAL?target=global:STATIC?target=global[TARGET]||defineGlobalProperty(TARGET,{}):target=global[TARGET]&&global[TARGET].prototype,target)for(key in source){if(sourceProperty=source[key],options.dontCallGetSet?(descriptor=getOwnPropertyDescriptor(target,key),targetProperty=descriptor&&descriptor.value):targetProperty=target[key],FORCED=isForced(GLOBAL?key:TARGET+(STATIC?".":"#")+key,options.forced),!FORCED&&targetProperty!==void 0){if(typeof sourceProperty==typeof targetProperty)continue;copyConstructorProperties(sourceProperty,targetProperty)}(options.sham||targetProperty&&targetProperty.sham)&&createNonEnumerableProperty(sourceProperty,"sham",!0),defineBuiltIn(target,key,sourceProperty,options)}}}});var require_an_instance=__commonJS({"node_modules/core-js/internals/an-instance.js"(exports,module){"use strict";init_define_process_env();init_shim();var isPrototypeOf=require_object_is_prototype_of(),$TypeError=TypeError;module.exports=function(it,Prototype){if(isPrototypeOf(Prototype,it))return it;throw new $TypeError("Incorrect invocation")}}});var require_correct_prototype_getter=__commonJS({"node_modules/core-js/internals/correct-prototype-getter.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){function F(){}return F.prototype.constructor=null,Object.getPrototypeOf(new F)!==F.prototype})}});var require_object_get_prototype_of=__commonJS({"node_modules/core-js/internals/object-get-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),isCallable=require_is_callable(),toObject=require_to_object(),sharedKey=require_shared_key(),CORRECT_PROTOTYPE_GETTER=require_correct_prototype_getter(),IE_PROTO=sharedKey("IE_PROTO"),$Object=Object,ObjectPrototype=$Object.prototype;module.exports=CORRECT_PROTOTYPE_GETTER?$Object.getPrototypeOf:function(O){var object=toObject(O);if(hasOwn(object,IE_PROTO))return object[IE_PROTO];var constructor=object.constructor;return isCallable(constructor)&&object instanceof constructor?constructor.prototype:object instanceof $Object?ObjectPrototype:null}}});var require_define_built_in_accessor=__commonJS({"node_modules/core-js/internals/define-built-in-accessor.js"(exports,module){"use strict";init_define_process_env();init_shim();var makeBuiltIn=require_make_built_in(),defineProperty=require_object_define_property();module.exports=function(target,name,descriptor){return descriptor.get&&makeBuiltIn(descriptor.get,name,{getter:!0}),descriptor.set&&makeBuiltIn(descriptor.set,name,{setter:!0}),defineProperty.f(target,name,descriptor)}}});var require_create_property=__commonJS({"node_modules/core-js/internals/create-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPropertyKey=require_to_property_key(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=function(object,key,value){var propertyKey=toPropertyKey(key);propertyKey in object?definePropertyModule.f(object,propertyKey,createPropertyDescriptor(0,value)):object[propertyKey]=value}}});var require_object_keys=__commonJS({"node_modules/core-js/internals/object-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys();module.exports=Object.keys||function(O){return internalObjectKeys(O,enumBugKeys)}}});var require_object_define_properties=__commonJS({"node_modules/core-js/internals/object-define-properties.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),definePropertyModule=require_object_define_property(),anObject=require_an_object(),toIndexedObject=require_to_indexed_object(),objectKeys=require_object_keys();exports.f=DESCRIPTORS&&!V8_PROTOTYPE_DEFINE_BUG?Object.defineProperties:function(O,Properties){anObject(O);for(var props=toIndexedObject(Properties),keys=objectKeys(Properties),length=keys.length,index=0,key;length>index;)definePropertyModule.f(O,key=keys[index++],props[key]);return O}}});var require_html=__commonJS({"node_modules/core-js/internals/html.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in();module.exports=getBuiltIn("document","documentElement")}});var require_object_create=__commonJS({"node_modules/core-js/internals/object-create.js"(exports,module){"use strict";init_define_process_env();init_shim();var anObject=require_an_object(),definePropertiesModule=require_object_define_properties(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=require_hidden_keys(),html=require_html(),documentCreateElement=require_document_create_element
64(),sharedKey=require_shared_key(),GT=">",LT="<",PROTOTYPE="prototype",SCRIPT="script",IE_PROTO=sharedKey("IE_PROTO"),EmptyConstructor=function(){},scriptTag=function(content){return LT+SCRIPT+GT+content+LT+"/"+SCRIPT+GT},NullProtoObjectViaActiveX=function(activeXDocument2){activeXDocument2.write(scriptTag("")),activeXDocument2.close();var temp=activeXDocument2.parentWindow.Object;return activeXDocument2=null,temp},NullProtoObjectViaIFrame=function(){var iframe=documentCreateElement("iframe"),JS="java"+SCRIPT+":",iframeDocument;return iframe.style.display="none",html.appendChild(iframe),iframe.src=String(JS),iframeDocument=iframe.contentWindow.document,iframeDocument.open(),iframeDocument.write(scriptTag("document.F=Object")),iframeDocument.close(),iframeDocument.F},activeXDocument,NullProtoObject=function(){try{activeXDocument=new ActiveXObject("htmlfile")}catch{}NullProtoObject=typeof document<"u"?document.domain&&activeXDocument?NullProtoObjectViaActiveX(activeXDocument):NullProtoObjectViaIFrame():NullProtoObjectViaActiveX(activeXDocument);for(var length=enumBugKeys.length;length--;)delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];return NullProtoObject()};hiddenKeys[IE_PROTO]=!0;module.exports=Object.create||function(O,Properties){var result;return O!==null?(EmptyConstructor[PROTOTYPE]=anObject(O),result=new EmptyConstructor,EmptyConstructor[PROTOTYPE]=null,result[IE_PROTO]=O):result=NullProtoObject(),Properties===void 0?result:definePropertiesModule.f(result,Properties)}}});var require_iterators_core=__commonJS({"node_modules/core-js/internals/iterators-core.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),isObject=require_is_object(),create=require_object_create(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltIn=require_define_built_in(),wellKnownSymbol=require_well_known_symbol(),IS_PURE=require_is_pure(),ITERATOR=wellKnownSymbol("iterator"),BUGGY_SAFARI_ITERATORS=!1,IteratorPrototype,PrototypeOfArrayIteratorPrototype,arrayIterator;[].keys&&(arrayIterator=[].keys(),"next"in arrayIterator?(PrototypeOfArrayIteratorPrototype=getPrototypeOf(getPrototypeOf(arrayIterator)),PrototypeOfArrayIteratorPrototype!==Object.prototype&&(IteratorPrototype=PrototypeOfArrayIteratorPrototype)):BUGGY_SAFARI_ITERATORS=!0);var NEW_ITERATOR_PROTOTYPE=!isObject(IteratorPrototype)||fails(function(){var test={};return IteratorPrototype[ITERATOR].call(test)!==test});NEW_ITERATOR_PROTOTYPE?IteratorPrototype={}:IS_PURE&&(IteratorPrototype=create(IteratorPrototype));isCallable(IteratorPrototype[ITERATOR])||defineBuiltIn(IteratorPrototype,ITERATOR,function(){return this});module.exports={IteratorPrototype,BUGGY_SAFARI_ITERATORS}}});var require_esnext_iterator_constructor=__commonJS({"node_modules/core-js/modules/esnext.iterator.constructor.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),global=require_global(),anInstance=require_an_instance(),anObject=require_an_object(),isCallable=require_is_callable(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltInAccessor=require_define_built_in_accessor(),createProperty=require_create_property(),fails=require_fails(),hasOwn=require_has_own_property(),wellKnownSymbol=require_well_known_symbol(),IteratorPrototype=require_iterators_core().IteratorPrototype,DESCRIPTORS=require_descriptors(),IS_PURE=require_is_pure(),CONSTRUCTOR="constructor",ITERATOR="Iterator",TO_STRING_TAG=wellKnownSymbol("toStringTag"),$TypeError=TypeError,NativeIterator=global[ITERATOR],FORCED=IS_PURE||!isCallable(NativeIterator)||NativeIterator.prototype!==IteratorPrototype||!fails(function(){NativeIterator({})}),IteratorConstructor=function(){if(anInstance(this,IteratorPrototype),getPrototypeOf(this)===IteratorPrototype)throw new $TypeError("Abstract class Iterator not directly constructable")},defineIteratorPrototypeAccessor=function(key,value){DESCRIPTORS?defineBuiltInAccessor(IteratorPrototype,key,{configurable:!0,get:function(){return value},set:function(replacement){if(anObject(this),this===IteratorPrototype)throw new $TypeError("You can't redefine this property");hasOwn(this,key)?this[key]=replacement:createProperty(this,key,replacement)}}):IteratorPrototype[key]=value};hasOwn(IteratorPrototype,TO_STRING_TAG)||defineIteratorPrototypeAccessor(TO_STRING_TAG,ITERATOR);(FORCED||!hasOwn(IteratorPrototype,CONSTRUCTOR)||IteratorPrototype[CONSTRUCTOR]===Object)&&defineIteratorPrototypeAccessor(CONSTRUCTOR,IteratorConstructor);IteratorConstructor.prototype=IteratorPrototype;$2({global:!0,constructor:!0,forced:FORCED},{Iterator:IteratorConstructor})}});var require_get_iterator_direct=__commonJS({"node_modules/core-js/internals/get-iterator-direct.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(obj){return{iterator:obj,next:obj.next,done:!1}}}});var require_define_built_ins=__commonJS({"node_modules/core-js/internals/define-built-ins.js"(exports,module){"use strict";init_define_process_env();init_shim();var defineBuiltIn=require_define_built_in();module.exports=function(target,src,options){for(var key in src)defineBuiltIn(target,key,src[key],options);return target}}});var require_create_iter_result_object=__commonJS({"node_modules/core-js/internals/create-iter-result-object.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(value,done){return{value,done}}}});var require_iterator_close=__commonJS({"node_modules/core-js/internals/iterator-close.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),anObject=require_an_object(),getMethod=require_get_method();module.exports=function(iterator,kind,value){var innerResult,innerError;anObject(iterator);try{if(innerResult=getMethod(iterator,"return"),!innerResult){if(kind==="throw")throw value;return value}innerResult=call(innerResult,iterator)}catch(error){innerError=!0,innerResult=error}if(kind==="throw")throw value;if(innerError)throw innerResult;return anObject(innerResult),value}}});var require_iterator_create_proxy=__commonJS({"node_modules/core-js/internals/iterator-create-proxy.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),create=require_object_create(),createNonEnumerableProperty=require_create_non_enumerable_property(),defineBuiltIns=require_define_built_ins(),wellKnownSymbol=require_well_known_symbol(),InternalStateModule=require_internal_state(),getMethod=require_get_method(),IteratorPrototype=require_iterators_core().IteratorPrototype,createIterResultObject=require_create_iter_result_object(),iteratorClose=require_iterator_close(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),ITERATOR_HELPER="IteratorHelper",WRAP_FOR_VALID_ITERATOR="WrapForValidIterator",setInternalState=InternalStateModule.set,createIteratorProxyPrototype=function(IS_ITERATOR){var getInternalState=InternalStateModule.getterFor(IS_ITERATOR?WRAP_FOR_VALID_ITERATOR:ITERATOR_HELPER);return defineBuiltIns(create(IteratorPrototype),{next:function(){var state=getInternalState(this);if(IS_ITERATOR)return state.nextHandler();try{var result=state.done?void 0:state.nextHandler();return createIterResultObject(result,state.done)}catch(error){throw state.done=!0,error}},return:function(){var state=getInternalState(this),iterator=state.iterator;if(state.done=!0,IS_ITERATOR){var returnMethod=getMethod(iterator,"return");return returnMethod?call(returnMethod,iterator):createIterResultObject(void 0,!0)}if(state.inner)try{iteratorClose(state.inner.iterator,"normal")}catch(error){return iteratorClose(iterator,"throw",error)}return iteratorClose(iterator,"normal"),createIterResultObject(void 0,!0)}})},WrapForValidIteratorPrototype=createIteratorProxyPrototype(!0),IteratorHelperPrototype=createIteratorProxyPrototype(!1);createNonEnumerableProperty(IteratorHelperPrototype,TO_STRING_TAG,"Iterator Helper");module.exports=function(nextHandler,IS_ITERATOR){var IteratorProxy=function(record,state){state?(state.iterator=record.iterator,state.next=record.next):state=record,state.type=IS_ITERATOR?WRAP_FOR_VALID_ITERATOR:ITERATOR_HELPER,state.nextHandler=nextHandler,state.counter=0,state.done=!1,setInternalState(this,state)};return IteratorProxy.prototype=IS_ITERATOR?WrapForValidIteratorPrototype:IteratorHelperPrototype,IteratorProxy}}});var require_call_with_safe_iteration_closing=__commonJS({"node_modules/core-js/internals/call-with-safe-iteration-closing.js"(exports,module){"use strict";init_define_process_env();init_shim();var anObject=require_an_object(),iteratorClose=require_iterator_close();module.exports=function(iterator,fn,value,ENTRIES){try{return ENTRIES?fn(anObject(value)[0],value[1]):fn(value)}catch(error){iteratorClose(iterator,"throw",error)}}}});var require_esnext_iterator_filter=__commonJS({"node_modules/core-js/modules/esnext.iterator.filter.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct(),createIteratorProxy=require_iterator_create_proxy(),callWithSafeIterationClosing=require_call_with_safe_iteration_closing(),IS_PURE=require_is_pure(),IteratorProxy=createIteratorProxy(function(){for(var iterator=this.iterator,predicate=this.predicate,next=this.next,result,done,value;;){if(result=anObject(call(next,iterator)),done=this.done=!!result.done,done)return;if(value=result.value,callWithSafeIterationClosing(iterator,predicate,[value,this.counter++],!0))return value}});$2({target:"Iterator",proto:!0,real:!0,forced:IS_PURE},{filter:function(predicate){return anObject(this),aCallable(predicate),new IteratorProxy(getIteratorDirect(this),{predicate})}})}});var require_function_uncurry_this_clause=__commonJS({"node_modules/core-js/internals/function-uncurr
64y-this-clause.js"(exports,module){"use strict";init_define_process_env();init_shim();var classofRaw=require_classof_raw(),uncurryThis=require_function_uncurry_this();module.exports=function(fn){if(classofRaw(fn)==="Function")return uncurryThis(fn)}}});var require_function_bind_context=__commonJS({"node_modules/core-js/internals/function-bind-context.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this_clause(),aCallable=require_a_callable(),NATIVE_BIND=require_function_bind_native(),bind=uncurryThis(uncurryThis.bind);module.exports=function(fn,that){return aCallable(fn),that===void 0?fn:NATIVE_BIND?bind(fn,that):function(){return fn.apply(that,arguments)}}}});var require_iterators=__commonJS({"node_modules/core-js/internals/iterators.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports={}}});var require_is_array_iterator_method=__commonJS({"node_modules/core-js/internals/is-array-iterator-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var wellKnownSymbol=require_well_known_symbol(),Iterators=require_iterators(),ITERATOR=wellKnownSymbol("iterator"),ArrayPrototype=Array.prototype;module.exports=function(it){return it!==void 0&&(Iterators.Array===it||ArrayPrototype[ITERATOR]===it)}}});var require_to_string_tag_support=__commonJS({"node_modules/core-js/internals/to-string-tag-support.js"(exports,module){"use strict";init_define_process_env();init_shim();var wellKnownSymbol=require_well_known_symbol(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),test={};test[TO_STRING_TAG]="z";module.exports=String(test)==="[object z]"}});var require_classof=__commonJS({"node_modules/core-js/internals/classof.js"(exports,module){"use strict";init_define_process_env();init_shim();var TO_STRING_TAG_SUPPORT=require_to_string_tag_support(),isCallable=require_is_callable(),classofRaw=require_classof_raw(),wellKnownSymbol=require_well_known_symbol(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),$Object=Object,CORRECT_ARGUMENTS=classofRaw(function(){return arguments}())==="Arguments",tryGet=function(it,key){try{return it[key]}catch{}};module.exports=TO_STRING_TAG_SUPPORT?classofRaw:function(it){var O,tag,result;return it===void 0?"Undefined":it===null?"Null":typeof(tag=tryGet(O=$Object(it),TO_STRING_TAG))=="string"?tag:CORRECT_ARGUMENTS?classofRaw(O):(result=classofRaw(O))==="Object"&&isCallable(O.callee)?"Arguments":result}}});var require_get_iterator_method=__commonJS({"node_modules/core-js/internals/get-iterator-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var classof=require_classof(),getMethod=require_get_method(),isNullOrUndefined=require_is_null_or_undefined(),Iterators=require_iterators(),wellKnownSymbol=require_well_known_symbol(),ITERATOR=wellKnownSymbol("iterator");module.exports=function(it){if(!isNullOrUndefined(it))return getMethod(it,ITERATOR)||getMethod(it,"@@iterator")||Iterators[classof(it)]}}});var require_get_iterator=__commonJS({"node_modules/core-js/internals/get-iterator.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),tryToString=require_try_to_string(),getIteratorMethod=require_get_iterator_method(),$TypeError=TypeError;module.exports=function(argument,usingIterator){var iteratorMethod=arguments.length<2?getIteratorMethod(argument):usingIterator;if(aCallable(iteratorMethod))return anObject(call(iteratorMethod,argument));throw new $TypeError(tryToString(argument)+" is not iterable")}}});var require_iterate=__commonJS({"node_modules/core-js/internals/iterate.js"(exports,module){"use strict";init_define_process_env();init_shim();var bind=require_function_bind_context(),call=require_function_call(),anObject=require_an_object(),tryToString=require_try_to_string(),isArrayIteratorMethod=require_is_array_iterator_method(),lengthOfArrayLike=require_length_of_array_like(),isPrototypeOf=require_object_is_prototype_of(),getIterator=require_get_iterator(),getIteratorMethod=require_get_iterator_method(),iteratorClose=require_iterator_close(),$TypeError=TypeError,Result=function(stopped,result){this.stopped=stopped,this.result=result},ResultPrototype=Result.prototype;module.exports=function(iterable,unboundFunction,options){var that=options&&options.that,AS_ENTRIES=!!(options&&options.AS_ENTRIES),IS_RECORD=!!(options&&options.IS_RECORD),IS_ITERATOR=!!(options&&options.IS_ITERATOR),INTERRUPTED=!!(options&&options.INTERRUPTED),fn=bind(unboundFunction,that),iterator,iterFn,index,length,result,next,step,stop=function(condition){return iterator&&iteratorClose(iterator,"normal",condition),new Result(!0,condition)},callFn=function(value){return AS_ENTRIES?(anObject(value),INTERRUPTED?fn(value[0],value[1],stop):fn(value[0],value[1])):INTERRUPTED?fn(value,stop):fn(value)};if(IS_RECORD)iterator=iterable.iterator;else if(IS_ITERATOR)iterator=iterable;else{if(iterFn=getIteratorMethod(iterable),!iterFn)throw new $TypeError(tryToString(iterable)+" is not iterable");if(isArrayIteratorMethod(iterFn)){for(index=0,length=lengthOfArrayLike(iterable);length>index;index++)if(result=callFn(iterable[index]),result&&isPrototypeOf(ResultPrototype,result))return result;return new Result(!1)}iterator=getIterator(iterable,iterFn)}for(next=IS_RECORD?iterable.next:iterator.next;!(step=call(next,iterator)).done;){try{result=callFn(step.value)}catch(error){iteratorClose(iterator,"throw",error)}if(typeof result=="object"&&result&&isPrototypeOf(ResultPrototype,result))return result}return new Result(!1)}}});var require_esnext_iterator_find=__commonJS({"node_modules/core-js/modules/esnext.iterator.find.js"(
64){"use strict";init_define_process_env();init_shim();var $2=require_export(),iterate=require_iterate(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct();$2({target:"Iterator",proto:!0,real:!0},{find:function(predicate){anObject(this),aCallable(predicate);var record=getIteratorDirect(this),counter=0;return iterate(record,function(value,stop){if(predicate(value,counter++))return stop(value)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})}});var require_iterator_map=__commonJS({"node_modules/core-js/internals/iterator-map.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct(),createIteratorProxy=require_iterator_create_proxy(),callWithSafeIterationClosing=require_call_with_safe_iteration_closing(),IteratorProxy=createIteratorProxy(function(){var iterator=this.iterator,result=anObject(call(this.next,iterator)),done=this.done=!!result.done;if(!done)return callWithSafeIterationClosing(iterator,this.mapper,[result.value,this.counter++],!0)});module.exports=function(mapper){return anObject(this),aCallable(mapper),new IteratorProxy(getIteratorDirect(this),{mapper})}}});var require_esnext_iterator_map=__commonJS({"node_modules/core-js/modules/esnext.iterator.map.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),map=require_iterator_map(),IS_PURE=require_is_pure();$2({target:"Iterator",proto:!0,real:!0,forced:IS_PURE},{map})}});function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var u,base_safe_require,legacy_keys,safe_require,init_window_register=__esm({"lib-browser/window_register.js"(){"use strict";init_define_process_env();init_shim();u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register}}});var require_function_apply=__commonJS({"node_modules/core-js/internals/function-apply.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),FunctionPrototype=Function.prototype,apply=FunctionPrototype.apply,call=FunctionPrototype.call;module.exports=typeof Reflect=="object"&&Reflect.apply||(NATIVE_BIND?call.bind(apply):function(){return call.apply(apply,arguments)})}});var require_array_slice=__commonJS({"node_modules/core-js/internals/array-slice.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this();module.exports=uncurryThis([].slice)}});var require_validate_arguments_length=__commonJS({"node_modules/core-js/internals/validate-arguments-length.js"(exports,module){"use strict";init_define_process_env();init_shim();var $TypeError=TypeError;module.exports=function(passed,required){if(passed<required)throw new $TypeError("Not enough arguments");return passed}}});var require_engine_is_ios=__commonJS({"node_modules/core-js/internals/engine-is-ios.js"(exports,module){"use strict";init_define_process_env();init_shim();var userAgent=require_engine_user_agent();
64module.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent)}});var require_engine_is_node=__commonJS({"node_modules/core-js/internals/engine-is-node.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),classof=require_classof_raw();module.exports=classof(global.process)==="process"}});var require_task=__commonJS({"node_modules/core-js/internals/task.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),apply=require_function_apply(),bind=require_function_bind_context(),isCallable=require_is_callable(),hasOwn=require_has_own_property(),fails=require_fails(),html=require_html(),arraySlice=require_array_slice(),createElement=require_document_create_element(),validateArgumentsLength=require_validate_arguments_length(),IS_IOS=require_engine_is_ios(),IS_NODE=require_engine_is_node(),set=global.setImmediate,clear=global.clearImmediate,process2=global.process,Dispatch=global.Dispatch,Function2=global.Function,MessageChannel=global.Me
64ssageChannel,String2=global.String,counter=0,queue={},ONREADYSTATECHANGE="onreadystatechange",$location,defer,channel,port;fails(function(){$location=global.location});var run=function(id){if(hasOwn(queue,id)){var fn=queue[id];delete queue[id],fn()}},runner=function(id){return function(){run(id)}},eventListener=function(event){run(event.data)},globalPostMessageDefer=function(id){global.postMessage(String2(id),$location.protocol+"//"+$location.host)};(!set||!clear)&&(set=function(handler){validateArgumentsLength(arguments.length,1);var fn=isCallable(handler)?handler:Function2(handler),args=arraySlice(arguments,1);return queue[++counter]=function(){apply(fn,void 0,args)},defer(counter),counter},clear=function(id){delete queue[id]},IS_NODE?defer=function(id){process2.nextTick(runner(id))}:Dispatch&&Dispatch.now?defer=function(id){Dispatch.now(runner(id))}:MessageChannel&&!IS_IOS?(channel=new MessageChannel,port=channel.port2,channel.port1.onmessage=eventListener,defer=bind(port.postMessage,port)):global.addEventListener&&isCallable(global.postMessage)&&!global.importScripts&&$location&&$location.protocol!=="file:"&&!fails(globalPostMessageDefer)?(defer=globalPostMessageDefer,global.addEventListener("message",eventListener,!1)):ONREADYSTATECHANGE in createElement("script")?defer=function(id){html.appendChild(createElement("script"))[ONREADYSTATECHANGE]=function(){html.removeChild(this),run(id)}}:defer=function(id){setTimeout(runner(id),0)});module.exports={set,clear}}});var require_web_clear_immediate=__commonJS({"node_modules/core-js/modules/web.clear-immediate.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),global=require_global(),clearImmediate=require_task().clear;$2({global:!0,bind:!0,enumerable:!0,forced:global.clearImmediate!==clearImmediate},{clearImmediate})}});var require_engine_is_bun=__commonJS({"node_modules/core-js/internals/engine-is-bun.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=typeof Bun=="function"&&Bun&&typeof Bun.version=="string"}});var require_schedulers_fix=__commonJS({"node_modules/core-js/internals/schedulers-fix.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),apply=require_function_apply(),isCallable=require_is_callable(),ENGINE_IS_BUN=require_engine_is_bun(),USER_AGENT=require_engine_user_agent(),arraySlice=require_array_slice(),validateArgumentsLength=require_validate_arguments_length(),Function2=global.Function,WRAP=/MSIE .\./.test(USER_AGENT)||ENGINE_IS_BUN&&function(){var version=global.Bun.version.split(".");return version.length<3||version[0]==="0"&&(version[1]<3||version[1]==="3"&&version[2]==="0")}();module.exports=function(scheduler,hasTimeArg){var firstParamIndex=hasTimeArg?2:1;return WRAP?function(handler,timeout){var boundArgs=validateArgumentsLength(arguments.length,1)>firstParamIndex,fn=isCallable(handler)?handler:Function2(handler),params=boundArgs?arraySlice(arguments,firstParamIndex):[],callback=boundArgs?function(){apply(fn,this,params)}:fn;return hasTimeArg?scheduler(callback,timeout):scheduler(callback)}:scheduler}}});var require_web_set_immediate=__commonJS({"node_modules/core-js/modules/web.set-immediate.js"(){"use strict";init_define_process_env();init_shim();var $2=require_export(),global=require_global(),setTask=require_task().set,schedulersFix=require_schedulers_fix(),setImmediate2=global.setImmediate?schedulersFix(setTask,!1):setTask;$2({global:!0,bind:!0,enumerable:!0,forced:global.setImmediate!==setImmediate2},{setImmediate:setImmediate2})}});var require_web_immediate=__commonJS({"node_modules/core-js/modules/web.immediate.js"(){"use strict";init_define_process_env();init_shim();require_web_clear_immediate();require_web_set_immediate()}});var select2_MultiDropdown_exports={};__export(select2_MultiDropdown_exports,{additional_data:()=>additional_data,initialize:()=>initialize,property_applications:()=>property_applications_internal});function get_translation(key){return Lib().get_text("select2",key)}function initialize(instance){let canvas=instance.get_canvas(),div=$('<select class="inner-dropdown select2-hidden-accessible"></select>');canvas.append(div),div.attr("multiple","multiple"),div.css({width:"100%",height:"100%"});let current_displayed_value=null;function select_value(val){let select_raw_values=[];for(let v of val?.all?.()??val??[])select_raw_values.push(hydrate.dehydrate_tree_to_string_safe(v));div.val(select_raw_values).trigger("change",{source:"triggered_js"})}function restyle_tags(data){property_applications.apply_css_style(canvas.find(".select2-selection__choice"),{color:data.tag_font_color,"background-color":data.tag_bgcolor,"border-radius":`${data.tag_border_roundness}px`,"border-color":data.tag_border_color,"border-width":`${data.tag_border_width}px`,"border-style":"solid",padding:"3px 5px 3px 5px"}),property_applications.apply_css_style(canvas.find(".select2-selection__choice__remove"),{color:data.tag_delete_color})}let list_defined=b_async.MakeSwitch(void 0,"select2_list"),get_choice_list;if(instance.run_mode()){let recalculate_height2=function(){let items=canvas.find(".select2-selection__rendered");if(items.length){let inner_height=parseInt(items.css("height").replace("px",""))+5,padding_top=parseInt(canvas[0].style["padding-top"]);isNaN(padding_top)||(inner_height+=padding_top*2);let min_height=instance.element.get_height();instance.set_height(Math.max(min_height,inner_height)),instance.state("should_recalc",!1)}};var recalculate_height=recalculate_height2;canvas.css("overflow","visible"),element_eval.on_property_change(instance,"disabled",value=>div.prop("disabled",value??!1)),get_choice_list=()=>{let raw_choices=this._get_raw_choice_list(instance),get_display=v=>this._get_display_option(instance)(v)?.trim(),already_listed_captions=[],raw_choice_list=raw_choices.get_children(0,MAX_DROPDOWN);autorun.run_once(30,()=>raw_choice_list.map(raw_choice=>get_display(raw_choice)));let choice_list=[];for(let v of raw_choice_list)choice_list.push({text:get_display(v),id:hydrate.dehydrate_tree_to_string_safe(v)}
64),already_listed_captions.push(get_display(v));if((instance.get_static_property("dynamic_type")==="text"||instance.get_static_property("choices_style")!=="dynamic")&&instance.get_static_property("enable_tagging"))for(let a of current_displayed_value??[])already_listed_captions.includes(a.trim())||choice_list.push({text:a,id:a});return choice_list};let bad_value_watcher=autorun.Watcher(()=>{if(!instance.state("has_been_changed"))return!1;let val=instance.state("value"),items=val?.all?.()??val;if(!items?.length||this._tagging_enabled(instance))return!1;for(let v of items)if(!this._choice_list_contains(instance,v))return!0;return!1});instance.on_destroy(()=>{bad_value_watcher.destroy()}),bad_value_watcher.on_value(is_bad=>{is_bad&&instance.message("reset_input")});let run_mode_tag_styling=()=>autorun.run_once(30,()=>{let props={};for(let prop of["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color"])props[prop]=element_eval.evaluate_property(instance,prop);return props},(err,data)=>{if(err){logger.log(err);return}instance.setTimeout(()=>{restyle_tags(data)},1)});autorun.autorun(()=>{instance.is_visible()&&(instance.state("notify_width"),instance.state("value"),instance.state("should_recalc"),setImmediate(recalculate_height2))}),element_utils.register_tab_index_listener(instance,num=>{div.attr("tabindex",num)});let retrieve_properties=instance2=>({font_face:element_props.get_font_face(instance2),font_size:element_eval.evaluate_property(instance2,"font_size"),border_radius:element_eval.evaluate_property(instance2,"border_roundness"),border_width:element_eval.evaluate_property(instance2,"border_width"),border_color:element_eval.evaluate_property(instance2,"border_color"),background_style:element_eval.evaluate_property(instance2,"background_style"),background_color:element_eval.evaluate_property(instance2,"bgcolor")}),set_property_styles=data=>{property_applications.apply_css_style($(".select2-dropdown"),{"font-family":webfonts.get_face_and_variant(data.font_face).font_family,"font-size":data.font_size+"px","border-radius":data.border_radius+"px","border-width":data.border_width+"px","border-color":"#aaa","background-color":data.background_style==="bgcolor"?data.background_color??"white":"transparent"}),property_applications.apply_css_style($(".select2-container.select2-container--open .select2-dropdown--below"),{left:"-"+data.border_width+"px",top:"-"+data.border_width+"px"})};instance.wait_for_visible_lite(()=>{div.change((e,data)=>{let new_val=div.val();if(current_displayed_value=new_val,run_mode_tag_styling(),instance.state("should_recalc",!0),data?.source==="triggered_js")return;let res=[];for(let v of new_val??[])res.push(dropdowns.rehydrate_dropdown_value(v));instance.message("user_submit",res)});let _last_val=null;inputs.input_change_autorun(instance,val=>{_last_val=val,b_async.WaitFor(list_defined,()=>select_value(_last_val))}),instance.on_message("set_focus",()=>canvas.find("input").focus());let interval=null;div.on("select2:open",()=>{instance.state("is_focused",!0),instance.run_mode()?instance.setTimeout(()=>{autorun.run_once(30,()=>retrieve_properties(instance),(err,data)=>{if(err){logger.log(err);return}run_mode_tag_styling();let search_input=canvas.find(".select2-search__field");search_input.off("keydown.styling keyup.styling keypress.styling"),search_input.on("keydown.styling keyup.styling keypress.styling",()=>run_mode_tag_styling()),interval=instance.setInterval(()=>run_mode_tag_styling(),5),set_property_styles(data)})},1):autorun.run_once(30,()=>{retrieve_properties(instance)},(err,data)=>{if(err){logger.log(err);return}set_property_styles(data)})}),div.on("select2:close",()=>{run_mode_tag_styling(),instance.clearInterval(interval),canvas.find("input").is(":focus")||instance.state("is_focused",!1)}),$(document).on("click",evt=>{$.contains(canvas[0],evt.target)||instance.state("is_focused",!1)})})}else current_displayed_value=["tag1"];let is_dropdown_focused=autorun.Box(!1);div.on("focus",()=>is_dropdown_focused(!0)),div.on("blur",()=>is_dropdown_focused(!1));let succesfully_updated_once=autorun.Box(!1);element_eval.pre_cache(instance,["height","placeholder"]),instance.autorun(()=>
64{if(instance.is_visible()&&(!succesfully_updated_once()||!is_dropdown_focused())){list_defined.turn_off(),succesfully_updated_once(!0);let props={};for(let prop of["height","placeholder"])props[prop]=element_eval.evaluate_property(instance,prop);let choices=instance.run_mode()?get_choice_list():[{id:"tag1",text:"Tag 1"}],options={placeholder:props.placeholder,data:choices,maximumSelectionLength:instance.get_static_property("limit_selection"),dir:languages.is_rtl(Lib().app_language())&&"rtl",language:{errorLoading(){return get_translation("ERROR_LOADING")},inputTooLong(){return get_translation("INPUT_TOO_LONG")},inputTooShort(){return get_translation("INPUT_TOO_SHORT")},loadingMore(){return get_translation("LOADING_MORE")},maximumSelected(){return get_translation("MAXIMUM_SELECTED")},noResults(){return get_translation("NO_RESULTS")},searching(){return get_translation("SEARCHING")},removeAllItems(){return get_translation("REMOVE_ALL_ITEMS")}}};this._tagging_enabled(instance)&&(options.tags=!0,options.tokenSeparators=[","],instance.get_static_property("tags_with_spaces")||options.tokenSeparators.push(" ")),div.data("select2")!=null&&div.select2("destroy").empty(),div.select2(options),canvas.find(".select2-selection, .select2-container--default").height(props.height),canvas.find("input").is(":focus")&&instance.message("set_focus"),instance.run_mode()&&inputs.register_focus(instance,canvas.find(".select2-selection, input")),select_value(current_displayed_value),instance.state("has_been_changed")||select_value(instance.state("value")),list_defined.turn_on(),element_eval.pre_cache(instance,["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color","font_face","font_family","font_weight","font_size","font_color","placeholder_color"]),instance.autorun(()=>{props={};for(let prop of["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color","font_size","font_color","placeholder_color"])props[prop]=element_eval.evaluate_property(instance,prop);props.font_face=element_props.get_font_face(instance),restyle_tags(props);let font_data=webfonts.get_quoted_face_and_variant(props.font_face),search_field=canvas.find(".select2-search__field");property_applications.apply_css_style(search_field,{"font-family":font_data.font_family,"font-weight":font_data.variant,"font-size":`${props.font_size}px`,color:props.font_color,width:"100%"}),new property_applications.PlaceholderColor().apply(props,search_field,instance),property_applications.apply_css_style(canvas.find(".select2-search--inline"),{width:instance.run_mode()&¤t_displayed_value.length>0?"":"100%"})})}})}var import_esnext_iterator_constructor,import_esnext_iterator_find,import_esnext_iterator_map,import_web_immediate,b_async,autorun,Lib,property_applications,inputs,dropdowns,element_utils,hydrate,languages,webfonts,logger,element_eval,element_props,MAX_DROPDOWN,property_applications_internal,additional_data,init_select2_MultiDropdown=__esm({"lib-browser/optional/services/legacy/responsive_v0/select2_MultiDropdown.js"(){"use strict";init_define_process_env();init_shim();import_esnext_iterator_constructor=__toESM(require_esnext_iterator_constructor()),import_esnext_iterator_find=__toESM(require_esnext_iterator_find()),import_esnext_iterator_map=__toESM(require_esnext_iterator_map()),import_web_immediate=__toESM(require_web_immediate());init_window_register();b_async=safe_require.safe_require("./u/shared/async/b_async"),autorun=safe_require.safe_require("./u/shared/async/autorun"),Lib=safe_require.safe_require("./lib"),property_applications=safe_require.safe_require("./core/property_applications"),inputs=safe_require.safe_require("./core/core_elements/shared/inputs"),dropdowns=safe_require.safe_require("./core/core_elements/shared/dropdowns"),element_utils=safe_require.safe_require("./core/core_elements/core_elements_utilities/element_utils"),hydrate=safe_require.safe_require("@bubblegroup/db/hydrate"),languages=safe_require.safe_require("./languages"),webfonts=safe_require.safe_require("./webfonts"),logger=safe_require.safe_require("./logger"),element_eval=safe_require.safe_require("./lang/evaluation/element_eval"),element_props=safe_require.safe_require("./lang/evaluation/element_props");MAX_DROPDOWN=5e3,property_applications_internal=[new property_applications.MinWidth];additional_data={notify_width(instance,width){instance.state("notify_width",width)}}}});init_define_process_env();init_shim();var import_esnext_iterator_constructor2=__toESM(require_esnext_iterator_constructor()),import_esnext_iterator_filter=__toESM(require_esnext_iterator_filter()),import_esnext_iterator_find2=__toESM(require_esnext_iterator_find()),import_esnext_iterator_map2=__toESM(require_esnext_iterator_map());init_window_register();var external=safe_require.safe_require("./external"),services=safe_require.safe_require("./services"),Lib2=safe_require.safe_require("./lib"),property_applications2=safe_require.safe_require("./core/property_applications"),shared_fields=safe_require.safe_require("./core/shared_fields"),inputs2=safe_require.safe_require("./core/core_elements/shared/inputs"),dropdowns2=safe_require.safe_require("./core/core_elements/shared/dropdowns"),hydrate2=safe_require.safe_require("@bubblegroup/db/hydrate"),btypes=safe_require.safe_require("./lang/btypes"),lang=safe_require.safe_require("./lang/lang"),languages2=safe_require.safe_require("./languages"),webfonts2=safe_require.safe_require("./webfonts"),logger2=safe_require.safe_require("./logger"),element_eval2=safe_require.safe_require("./lang/evaluation/element_eval"),element_props2=safe_require.safe_require("./lang/evaluation/element_props"),element_modifications=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/element_modifications"),shared_field_metadata;u.uses_field_metadata()&&(shared_field_metadata=safe_require.safe_require("./core/shared_field_metadata"));var btype_ids=safe_require.safe_require("./lang/btype_ids"),PLUGIN_FILE="select2";element_modifications.set_legacy_element_modifications("select2-MultiDropdown",(init_select2_MultiDropdown(),__toCommonJS(select2_MultiDropdown_exports)));var MAX_DROPDOWN2=5e3,cls=class extends external.Service{constructor(){super(),this.elements=this._get_initial_elements(),this.authenticator=new external.NoAuth}_get_initial_elements(){return{MultiDropdown:{category:"input forms",display:"Multi dropdown",icon:"ion-pricetags",condition(root){return!root?.is_mobile?.()},defaults:{font_size:14,background_style:"bgcolor",bgcolor:"#FFFFFF",border_style:"solid",border_width:1,border_color:"#858585",border_roundness:3,width:250,height:45,placeholder:"Choose some options...",use_max_width:!0,max_width:150},default_states:[{condition:{type:"ThisElement",next:{type:"Message",name:"is_focused"}},properties:{border_color:"#52A8EC",boxshadow_color:"#52A8EC",boxshadow_style:"outset",boxshadow_horizontal:0,boxshadow_vertical:0,boxshadow_blur:6}}],field_names:u.extend({choices_style:{default:"static",no_states:!0},choices:{no_states:!0,default:`Choice 1 65Choice 2 66Choice 3`},dynamic_type:{no_states:!0},data_source:{},option_display_expression:{no_states:!0},default:{},enable_tagging:{no_states:!0},tags_with_spaces:{no_states:!0},placeholder:{},tag_font_color:{default:"#252525"},tag_bgcolor:{default:"#e4e4e4"},tag_delete_color:{default:"#999"},tag_border_roundness:{default:2},tag_border_width:{default:1},tag_border_color:{default:"#C9C9C9"},limit_selection:{no_states:!0,optional:!0}},inputs2.get_disabled_field_name,inputs2.get_auto_binding_field_names),property_applications:[new property_applications2.Dimensions,new property_applications2.Font,new property_applications2.Backgroun
66d,new property_applications2.ResponsiveElement,new property_applications2.Border(void 0,void 0,{only_main_border:!0}),new property_applications2.PaddingText,new property_applications2.BoxShadow,new property_applications2.PlaceholderColor("input.select2-search__field")],get_html(instance){return"<div></div>"},get_min_width(element){return 0},_get_display_option:dropdowns2._get_display_option,uses_css_responsive:!0,can_fit_height:!0,initialize(instance){services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE});let canvas=instance.get_canvas(),div=$('<select class="inner-dropdown select2-hidden-accessible"></select>');canvas.append(div),div.attr("multiple","multiple"),div.css({width:"100%",height:"100%"});let current_displayed_value=null;function select_value(val){let select_raw_values=(val?.all?.()??val??[]).map(v=>hydrate2.dehydrate_tree_to_string_safe(v));div.val(select_raw_values).trigger("change",{source:"triggered_js"})}function restyle_tags(data){property_applications2.apply_css_style(canvas.find(".select2-selection__choice"),{color:data.tag_font_color,"background-color":data.tag_bgcolor,"border-radius":data.tag_border_roundness+"px","border-color":data.tag_border_color,"border-width":data.tag_border_width+"px","border-style":"solid",padding:"3px 5px 3px 5px"}),property_applications2.apply_css_style(canvas.find(".select2-selection__choice__remove"),{color:data.tag_delete_color})}let list_defined=u.MakeSwitch(void 0,"select2_list"),get_choice_list;if(instance.run_mode()){canvas.css({"overflow-x":"visible","overflow-y":"auto"}),element_eval2.on_property_change(instance,"disabled",value=>{div.prop("disabled",value??!1),div.prop("disabled")?canvas.css("pointer-events","none"):canvas.css("pointer-events","")}),get_choice_list=()=>{let raw_choices=this._get_raw_choice_list(instance),get_display=v=>this._get_display_option(instance)(v)?.trim(),already_listed_captions=[],raw_choice_list=raw_choices.get_children(0,MAX_DROPDOWN2);u.run_once(30,()=>{for(let raw_choice in raw_choice_list)get_display(raw_choice)});let choice_list=[];for(let v of raw_choice_list)choice_list.push({text:get_display(v),id:hydrate2.dehydrate_tree_to_string_safe(v)}),already_listed_captions.push(get_display(v));if((instance.get_static_property("dynamic_type")==="text"||instance.get_static_property("choices_style")!=="dynamic")&&instance.get_static_property("enable_tagging"))for(let a of current_displayed_value??[])already_listed_captions.includes(a.trim())||choice_list.push({text:a,id:a});return choice_list};let bad_value_watcher=u.Watcher(()=>{if(!instance.state("has_been_changed"))return!1;let val=instance.state("value"),items=val?.all?.()??val;if(!items?.length||this._tagging_enabled(instance))return!1;for(let v of items)if(!this._choice_list_contains(instance,v))return!0;return!1});instance.on_destroy(()=>{bad_value_watcher.destroy()}),bad_value_watcher.on_value(is_bad=>{is_bad&&instance.message("reset_input")});let run_mode_tag_styling=()=>u.run_once(30,()=>{let props={};for(let prop of["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color"])props[prop]=element_eval2.evaluate_property(instance,prop);return props},(err,data)=>{if(err){logger2.log(err);return}instance.setTimeout(()=>restyle_tags(data),1)}),retrieve_properties=instance2=>({font_face:element_props2.get_font_face(instance2),font_size:element_eval2.evaluate_property(instance2,"font_size"),border_radius:element_eval2.evaluate_property(instance2,"border_roundness"),border_width:element_eval2.evaluate_property(instance2,"border_width"),border_color:element_eval2.evaluate_property(instance2,"border_color"),background_style:element_eval2.evaluate_property(instance2,"background_style"),background_color:element_eval2.evaluate_property(instance2,"bgcolor")}),set_property_styles=data=>{property_applications2.apply_css_style($(".select2-dropdown"),{"font-family":webfonts2.get_face_and_variant(data.font_face).font_family,"font-size":data.font_size+"px","border-radius":data.border_radius+"px","border-width":data.border_width+"px","border-color":"#aaa","background-color":data.background_style==="bgcolor"?data.background_color??"white":"transparent"}),property_applications2.apply_css_style($(".select2-container.select2-container--open .select2-dropdown--below"),{left:"-"+data.border_width+"px",top:"-"+data.border_width+"px"})};instance.on_message("add_tab_index",num=>{div.attr("tabindex",num)}),instance.wait_for_visible_lite(()=>{div.change((e,data)=>{let new_val=div.val();if(current_displayed_value=new_val,run_mode_tag_styling(),instance.state("should_recalc",!0),data?.source==="triggered_js")return;let res=(new_val??[]).map(v=>dropdowns2.rehydrate_dropdown_value(v));instance.message("user_submit",res)});let _last_val=null;inputs2.input_change_autorun(instance,val=>{_last_val=val,u.WaitFor(list_defined,()=>{select_value(_last_val)})}),instance.on_message("set_focus",()=>{canvas.find("input").focus()});let interval=null;div.on("select2:open",()=>{instance.state("is_focused",!0),instance.run_mode()?instance.setTimeout(()=>{u.run_once(30,()=>retrieve_properties(instance),(err,data)=>
66{if(err){logger2.log(err);return}run_mode_tag_styling();let search_input=canvas.find(".select2-search__field");search_input.off("keydown.styling keyup.styling keypress.styling"),search_input.on("keydown.styling keyup.styling keypress.styling",()=>{run_mode_tag_styling()}),interval=instance.setInterval(()=>{run_mode_tag_styling()},5),set_property_styles(data)})},1):u.run_once(30,()=>{retrieve_properties(instance)},(err,data)=>{if(err){logger2.log(err);return}set_property_styles(data)})}),div.on("select2:close",()=>{run_mode_tag_styling(),instance.clearInterval(interval),canvas.find("input").is(":focus")||instance.state("is_focused",!1)}),$(document).on("click",evt=>{$.contains(canvas[0],evt.target)||instance.state("is_focused",!1)})})}else current_displayed_value=["tag1"];let is_dropdown_focused=u.Box(!1);div.on("focus",()=>is_dropdown_focused(!0)),div.on("blur",()=>is_dropdown_focused(!1));let succesfully_updated_once=u.Box(!1);element_eval2.pre_cache(instance,["placeholder"]),instance.autorun(()=>{if(instance.is_visible()&&(!succesfully_updated_once()||!is_dropdown_focused())){list_defined.turn_off(),succesfully_updated_once(!0);let props={};for(let prop of["placeholder"])props[prop]=element_eval2.evaluate_property(instance,prop);let choices=instance.run_mode()?get_choice_list():[{id:"tag1",text:"Tag 1"}
66],options={placeholder:props.placeholder,data:choices,maximumSelectionLength:instance.get_static_property("limit_selection"),dir:languages2.is_rtl(Lib2().app_language())&&"rtl",language:{errorLoading(){return get_translation2("ERROR_LOADING")},inputTooLong(){return get_translation2("INPUT_TOO_LONG")},inputTooShort(){return get_translation2("INPUT_TOO_SHORT")},loadingMore(){return get_translation2("LOADING_MORE")},maximumSelected(){return get_translation2("MAXIMUM_SELECTED")},noResults(){return get_translation2("NO_RESULTS")},searching(){return get_translation2("SEARCHING")},removeAllItems(){return get_translation2("REMOVE_ALL_ITEMS")}}};this._tagging_enabled(instance)&&(options.tags=!0,options.tokenSeparators=[","],instance.get_static_property("tags_with_spaces")||options.tokenSeparators.push(" "));let is_focused=canvas.find("input").is(":focus");div.data("select2")!=null&&div.select2("destroy").empty(),div.select2(options),canvas.find(".select2-selection, .select2-container--default").css("height","100%"),is_focused&&instance.message("set_focus"),instance.run_mode()&&inputs2.register_focus(instance,canvas.find(".select2-selection, input")),select_value(current_displayed_value),instance.state("has_been_changed")||select_value(instance.state("value")),list_defined.turn_on(),element_eval2.pre_cache(instance,["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color","font_face","font_family","font_weight","font_size","font_color","placeholder_color"]),instance.autorun(()=>{props={};for(let prop of["tag_font_color","tag_bgcolor","tag_border_roundness","tag_border_width","tag_border_color","tag_delete_color","font_size","font_color","placeholder_color"])props[prop]=element_eval2.evaluate_property(instance,prop);props.font_face=element_props2.get_font_face(instance),restyle_tags(props);let font_data=webfonts2.get_quoted_face_and_variant(props.font_face),search_field=canvas.find(".select2-search__field");property_applications2.apply_css_style(search_field,{"font-family":font_data.font_family,"font-weight":font_data.variant,"font-size":props.font_size+"px",color:props.font_color}),new property_applications2.PlaceholderColor().apply(props,search_field,instance),property_applications2.apply_css_style(canvas.find(".select2-search--inline"),{width:instance.run_mode()&¤t_displayed_value.length>0?"":"100%"})})}})},_tagging_enabled(instance){return this._supports_tagging(instance)&&instance.get_static_property("enable_tagging")},_supports_tagging(instance){return!(instance.get_static_property("choices_style")==="dynamic"&&instance.get_static_property("dynamic_type")!=="text")},_get_raw_btype(element){return element.get_static_property("choices_style")==="dynamic"?element.get_static_property("dynamic_type"):"text"},_get_raw_choice_list(instance){return dropdowns2._get_raw_choice_list_dropdown(instance,this)},_choice_list_contains(instance,val){let V=btypes.get(this._get_raw_btype(instance.element));return this._get_raw_choice_list(instance).contains(val,V)},get_starting_content(instance){let starting_content;return instance.run_mode()&&instance.get_static_property("auto_binding")?starting_content=inputs2.get_input_autobind_thing_field(instance):(starting_content=element_eval2.evaluate_property(instance,"default"),instance.get_static_property("choices_style")!=="dynamic"&&(starting_content=starting_content?.split?.(","),starting_content=(starting_content??[]).map(a=>a.trim()))),starting_content=starting_content?.all?.()??starting_content??[],this._tagging_enabled(instance)?starting_content:starting_content.filter(val=>this._choice_list_contains(instance,val))},get_state_value(element,name){if(name==="value")return btype_ids.list_type(this._get_raw_btype(element))},get_injected_btype(element){return element.get_static_property("dynamic_type")},get_injected_display(){return"Current option"},use_injected_datasource(node,element){return node.path().indexOf(element.property("option_display_expression").path())===0},change_cursor_style_if_clickable:!1,add_an_invisible_div_on_the_top:!0,is_input:!0,contains_group_data:!1,jquery_plugins(){return["jquery_plugins/select2.min"]},css_files:["css/optional/select2.min.css"],actions:["ResetInputs"]}}}};function get_translation2(key){return Lib2().get_text("select2",key)}var select2={cls};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.select2=select2);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("select2",select2);})(); 67/*! Bundled license information: 68 69buffer/index.js: 70 (*! 71 * The buffer module from node.js, for the browser. 72 * 73 * @author Feross Aboukhadijeh <https://feross.org> 74 * @license MIT 75 *) 76*/ 77 78} 79 80 81window.preloaded['plugin/first_party:select2'] = true; 82window._bubble_page_load_data.hardcoded_plugins['mixpanel'] = true; 83window.__code__ = window.__code__ || {}; 84if(!window.__code__['28e5dbb69549b111cfe9e365a116b6f70c28700b5c06b11f82be695a8ecf653a']){window.__code__['28e5dbb69549b111cfe9e365a116b6f70c28700b5c06b11f82be695a8ecf653a']=1; 85 86"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exp
vendor: 5,823 bytes, line 86
86orts:{}}).exports,mod),mod.exports};var __copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod));var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>
vendor: 23,595 bytes, line 86
86K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 86
86)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 86
86if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
86var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});var require_global=__commonJS({"node_modules/core-js/internals/global.js"(exports,module){"use strict";init_define_process_env();init_shim();var check=function(it){return it&&it.Math===Math&&it};module.exports=check(typeof globalThis=="object"&&globalThis)||check(typeof window=="object"&&window)||check(typeof self=="object"&&self)||check(typeof window=="object"&&window)||check(typeof exports=="object"&&exports)||function(){return this}()||Function("return this")()}});var require_fails=__commonJS({"node_modules/core-js/internals/fails.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(exec){try{return!!exec()}catch{return!0}}}});var require_descriptors=__commonJS({"node_modules/core-js/internals/descriptors.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})}});var require_function_bind_native=__commonJS({"node_modules/core-js/internals/function-bind-native.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){var test=(function(){}).bind();return typeof test!="function"||test.hasOwnProperty("prototype")})}});var require_function_call=__commonJS({"node_modules/core-js/internals/function-call.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),call=Function.prototype.call;module.exports=NATIVE_BIND?call.bind(call):function(){return call.apply(call,arguments)}}});var require_object_property_is_enumerable=__commonJS({"node_modules/core-js/internals/object-property-is-enumerable.js"(exports){"use strict";init_define_process_env();init_shim();var $propertyIsEnumerable={}.propertyIsEnumerable,getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,NASHORN_BUG=getOwnPropertyDescriptor&&!$propertyIsEnumerable.call({1:2},1);exports.f=NASHORN_BUG?function(V){var descriptor=getOwnPropertyDescriptor(this,V);return!!descriptor&&descriptor.enumerable}:$propertyIsEnumerable}});var require_create_property_descriptor=__commonJS({"node_modules/core-js/internals/create-property-descriptor.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(bitmap,value){return{enumerable:!(bitmap&1),configurable:!(bitmap&2),writable:!(bitmap&4),value}}}});var require_function_uncurry_this=__commonJS({"node_modules/core-js/internals/function-uncurr
86y-this.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_BIND=require_function_bind_native(),FunctionPrototype=Function.prototype,call=FunctionPrototype.call,uncurryThisWithBind=NATIVE_BIND&&FunctionPrototype.bind.bind(call,call);module.exports=NATIVE_BIND?uncurryThisWithBind:function(fn){return function(){return call.apply(fn,arguments)}}}});var require_classof_raw=__commonJS({"node_modules/core-js/internals/classof-raw.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toString=uncurryThis({}.toString),stringSlice=uncurryThis("".slice);module.exports=function(it){return stringSlice(toString(it),8,-1)}}});var require_indexed_object=__commonJS({"node_modules/core-js/internals/indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),classof=require_classof_raw(),$Object=Object,split=uncurryThis("".split);module.exports=fails(function(){return!$Object("z").propertyIsEnumerable(0)})?function(it){return classof(it)==="String"?split(it,""):$Object(it)}
86:$Object}});var require_is_null_or_undefined=__commonJS({"node_modules/core-js/internals/is-null-or-undefined.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(it){return it==null}}});var require_require_object_coercible=__commonJS({"node_modules/core-js/internals/require-object-coercible.js"(exports,module){"use strict";init_define_process_env();init_shim();var isNullOrUndefined=require_is_null_or_undefined(),$TypeError=TypeError;module.exports=function(it){if(isNullOrUndefined(it))throw new $TypeError("Can't call method on "+it);return it}}});var require_to_indexed_object=__commonJS({"node_modules/core-js/internals/to-indexed-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var IndexedObject=require_indexed_object(),requireObjectCoercible=require_require_object_coercible();module.exports=function(it){return IndexedObject(requireObjectCoercible(it))}}});var require_is_callable=__commonJS({"node_modules/core-js/internals/is-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var documentAll=typeof document=="object"&&document.all;module.exports=typeof documentAll>"u"&&documentAll!==void 0?function(argument){return typeof argument=="function"||argument===documentAll}:function(argument){return typeof argument=="function"}}});var require_is_object=__commonJS({"node_modules/core-js/internals/is-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable();module.exports=function(it){return typeof it=="object"?it!==null:isCallable(it)}}});var require_get_built_in=__commonJS({"node_modules/core-js/internals/get-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),aFunction=function(argument){return isCallable(argument)?argument:void 0};module.exports=function(namespace,method){return arguments.length<2?aFunction(global[namespace]):global[namespace]&&global[namespace][method]}}});var require_object_is_prototype_of=__commonJS({"node_modules/core-js/internals/object-is-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this();module.exports=uncurryThis({}.isPrototypeOf)}});var require_engine_user_agent=__commonJS({"node_modules/core-js/internals/engine-user-agent.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=typeof navigator<"u"&&String(navigator.userAgent)||""}});var require_engine_v8_version=__commonJS({"node_modules/core-js/internals/engine-v8-version.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),userAgent=require_engine_user_agent(),process2=global.process,Deno=global.Deno,versions=process2&&process2.versions||Deno&&Deno.version,v8=versions&&versions.v8,match,version;v8&&(match=v8.split("."),version=match[0]>0&&match[0]<4?1:+(match[0]+match[1]));!version&&userAgent&&(match=userAgent.match(/Edge\/(\d+)/),(!match||match[1]>=74)&&(match=userAgent.match(/Chrome\/(\d+)/),match&&(version=+match[1])));module.exports=version}});var require_symbol_constructor_detection=__commonJS({"node_modules/core-js/internals/symbol-constructor-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var V8_VERSION=require_engine_v8_version(),fails=require_fails(),global=require_global(),$String=global.String;module.exports=!!Object.getOwnPropertySymbols&&!fails(function(){var symbol=Symbol("symbol detection");return!$String(symbol)||!(Object(symbol)instanceof Symbol)||!Symbol.sham&&V8_VERSION&&V8_VERSION<41})}});var require_use_symbol_as_uid=__commonJS({"node_modules/core-js/internals/use-symbol-as-uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_SYMBOL=require_symbol_constructor_detection();module.exports=NATIVE_SYMBOL&&!Symbol.sham&&typeof Symbol.iterator=="symbol"}});var require_is_symbol=__commonJS({"node_modules/core-js/internals/is-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),isCallable=require_is_callable(),isPrototypeOf=require_object_is_prototype_of(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),$Object=Object;module.exports=USE_SYMBOL_AS_UID?function(it){return typeof it=="symbol"}:function(it){var $Symbol=getBuiltIn("Symbol");return isCallable($Symbol)&&isPrototypeOf($Symbol.prototype,$Object(it))}}});var require_try_to_string=__commonJS({"node_modules/core-js/internals/try-to-string.js"(exports,module){"use strict";init_define_process_env();init_shim();var $String=String;module.exports=function(argument){try{return $String(argument)}catch{return"Object"}}}});var require_a_callable=__commonJS({"node_modules/core-js/internals/a-callable.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),tryToString=require_try_to_string(),$TypeError=TypeError;module.exports=function(argument){if(isCallable(argument))return argument;throw new $TypeError(tryToString(argument)+" is not a function")}}});var require_get_method=__commonJS({"node_modules/core-js/internals/get-method.js"(exports,module){"use strict";init_define_process_env();init_shim();var aCallable=require_a_callable(),isNullOrUndefined=require_is_null_or_undefined();module.exports=function(V,P){var func=V[P];return isNullOrUndefined(func)?void 0:aCallable(func)}}});var require_ordinary_to_primitive=__commonJS({"node_modules/core-js/internals/ordinary-to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isCallable=require_is_callable(),isObject=require_is_object(),$TypeError=TypeError;module.exports=function(input,pref){var fn,val;if(pref==="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input))||isCallable(fn=input.valueOf)&&!isObject(val=call(fn,input))||pref!=="string"&&isCallable(fn=input.toString)&&!isObject(val=call(fn,input)))return val;throw new $TypeError("Can't convert object to primitive value")}}});var require_is_pure=__commonJS({"node_modules/core-js/internals/is-pure.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=!1}});var require_define_global_property=__commonJS({"node_modules/core-js/internals/define-global-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineProperty=Object.defineProperty;module.exports=function(key,value){try{defineProperty(global,key,{value,configurable:!0,writable:!0})}catch{global[key]=value}return value}}});var require_shared_store=__commonJS({"node_modules/core-js/internals/shared-store.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),defineGlobalProperty=require_define_global_property(),SHARED="__core-js_shared__",store=global[SHARED]||defineGlobalProperty(S
86HARED,{});module.exports=store}});var require_shared=__commonJS({"node_modules/core-js/internals/shared.js"(exports,module){"use strict";init_define_process_env();init_shim();var IS_PURE=require_is_pure(),store=require_shared_store();(module.exports=function(key,value){return store[key]||(store[key]=value!==void 0?value:{})})("versions",[]).push({version:"3.35.1",mode:IS_PURE?"pure":"global",copyright:"\xA9 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE",source:"https://github.com/zloirock/core-js"})}});var require_to_object=__commonJS({"node_modules/core-js/internals/to-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var requireObjectCoercible=require_require_object_coercible(),$Object=Object;module.exports=function(argument){return $Object(requireObjectCoercible(argument))}}});var require_has_own_property=__commonJS({"node_modules/core-js/internals/has-own-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),toObject=require_to_object(),hasOwnProperty=uncurryThis({}.hasOwnProperty);module.exports=Object.hasOwn||function(it,key){return hasOwnProperty(toObject(it),key)}}});var require_uid=__commonJS({"node_modules/core-js/internals/uid.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),id=0,postfix=Math.random(),toString=uncurryThis(1 .toString);module.exports=function(key){return"Symbol("+(key===void 0?"":key)+")_"+toString(++id+postfix,36)}}});var require_well_known_symbol=__commonJS({"node_modules/core-js/internals/well-known-symbol.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),shared=require_shared(),hasOwn=require_has_own_property(),uid=require_uid(),NATIVE_SYMBOL=require_symbol_constructor_detection(),USE_SYMBOL_AS_UID=require_use_symbol_as_uid(),Symbol2=global.Symbol,WellKnownSymbolsStore=shared("wks"),createWellKnownSymbol=USE_SYMBOL_AS_UID?Symbol2.for||Symbol2:Symbol2&&Symbol2.withoutSetter||uid;module.exports=function(name){return hasOwn(WellKnownSymbolsStore,name)||(WellKnownSymbolsStore[name]=NATIVE_SYMBOL&&hasOwn(Symbol2,name)?Symbol2[name]:createWellKnownSymbol("Symbol."+name)),WellKnownSymbolsStore[name]}}});var require_to_primitive=__commonJS({"node_modules/core-js/internals/to-primitive.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),isObject=require_is_object(),isSymbol
86=require_is_symbol(),getMethod=require_get_method(),ordinaryToPrimitive=require_ordinary_to_primitive(),wellKnownSymbol=require_well_known_symbol(),$TypeError=TypeError,TO_PRIMITIVE=wellKnownSymbol("toPrimitive");module.exports=function(input,pref){if(!isObject(input)||isSymbol(input))return input;var exoticToPrim=getMethod(input,TO_PRIMITIVE),result;if(exoticToPrim){if(pref===void 0&&(pref="default"),result=call(exoticToPrim,input,pref),!isObject(result)||isSymbol(result))return result;throw new $TypeError("Can't convert object to primitive value")}return pref===void 0&&(pref="number"),ordinaryToPrimitive(input,pref)}}});var require_to_property_key=__commonJS({"node_modules/core-js/internals/to-property-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPrimitive=require_to_primitive(),isSymbol=require_is_symbol();module.exports=function(argument){var key=toPrimitive(argument,"string");return isSymbol(key)?key:key+""}}});var require_document_create_element=__commonJS({"node_modules/core-js/internals/document-create-element.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isObject=require_is_object(),document2=global.document,EXISTS=isObject(document2)&&isObject(document2.createElement);module.exports=function(it){return EXISTS?document2.createElement(it):{}}}});var require_ie8_dom_define=__commonJS({"node_modules/core-js/internals/ie8-dom-define.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails(),createElement=require_document_create_element();module.exports=!DESCRIPTORS&&!fails(function(){return Object.defineProperty(createElement("div"),"a",{get:function(){return 7}}).a!==7})}});var require_object_get_own_property_descriptor=__commonJS({"node_modules/core-js/internals/object-get-own-property-descriptor.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),call=require_function_call(),propertyIsEnumerableModule=require_object_property_is_enumerable(),createPropertyDescriptor=require_create_property_descriptor(),toIndexedObject=require_to_indexed_object(),toPropertyKey=require_to_property_key(),hasOwn=require_has_own_property(),IE8_DOM_DEFINE=require_ie8_dom_define(),$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor;exports.f=DESCRIPTORS?$getOwnPropertyDescriptor:function(O,P){if(O=toIndexedObject(O),P=toPropertyKey(P),IE8_DOM_DEFINE)try{return $getOwnPropertyDescriptor(O,P)}catch{}if(hasOwn(O,P))return createPropertyDescriptor(!call(propertyIsEnumerableModule.f,O,P),O[P])}}});var require_v8_prototype_define_bug=__commonJS({"node_modules/core-js/internals/v8-prototype-define-bug.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),fails=require_fails();module.exports=DESCRIPTORS&&fails(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})}});var require_an_object=__commonJS({"node_modules/core-js/internals/an-object.js"(exports,module){"use strict";init_define_process_env();init_shim();var isObject=require_is_object(),$String=String,$TypeError=TypeError;module.exports=function(argument){if(isObject(argument))return argument;throw new $TypeError($String(argument)+" is not an object")}}});var require_object_define_property=__commonJS({"node_modules/core-js/internals/object-define-property.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),IE8_DOM_DEFINE=require_ie8_dom_define(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),anObject=require_an_object(),toPropertyKey=require_to_property_key(),$TypeError=TypeError,$defineProperty=Object.defineProperty,$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,ENUMERABLE="enumerable",CONFIGURABLE="configurable",WRITABLE="writable";exports.f=DESCRIPTORS?V8_PROTOTYPE_DEFINE_BUG?function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),typeof O=="function"&&P==="prototype"&&"value"in Attributes&&WRITABLE in Attributes&&!Attributes[WRITABLE]){var current=$getOwnPropertyDescriptor(O,P);current&¤t[WRITABLE]&&(O[P]=Attributes.value,Attributes={configurable:CONFIGURABLE in Attributes?Attributes[CONFIGURABLE]:current[CONFIGURABLE],enumerable:ENUMERABLE in Attributes?Attributes[ENUMERABLE]:current[ENUMERABLE],writable:!1})}return $defineProperty(O,P,Attributes)}
86:$defineProperty:function(O,P,Attributes){if(anObject(O),P=toPropertyKey(P),anObject(Attributes),IE8_DOM_DEFINE)try{return $defineProperty(O,P,Attributes)}catch{}if("get"in Attributes||"set"in Attributes)throw new $TypeError("Accessors not supported");return"value"in Attributes&&(O[P]=Attributes.value),O}}});var require_create_non_enumerable_property=__commonJS({"node_modules/core-js/internals/create-non-enumerable-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=DESCRIPTORS?function(object,key,value){return definePropertyModule.f(object,key,createPropertyDescriptor(1,value))}:function(object,key,value){return object[key]=value,object}}});var require_function_name=__commonJS({"node_modules/core-js/internals/function-name.js"(exports,module){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),hasOwn=require_has_own_property(),FunctionPrototype=Function.prototype,getDescriptor=DESCRIPTORS&&Object.getOwnPropertyDescriptor,EXISTS=hasOwn(FunctionPrototype,"name"),PROPER=EXISTS&&(function(){}).name==="something",CONFIGURABLE=EXISTS&&(!DESCRIPTORS||DESCRIPTORS&&getDescriptor(FunctionPrototype,"name").configurable);module.exports={EXISTS,PROPER,CONFIGURABLE}}});
86var require_inspect_source=__commonJS({"node_modules/core-js/internals/inspect-source.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),isCallable=require_is_callable(),store=require_shared_store(),functionToString=uncurryThis(Function.toString);isCallable(store.inspectSource)||(store.inspectSource=function(it){return functionToString(it)});module.exports=store.inspectSource}});var require_weak_map_basic_detection=__commonJS({"node_modules/core-js/internals/weak-map-basic-detection.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),isCallable=require_is_callable(),WeakMap=global.WeakMap;module.exports=isCallable(WeakMap)&&/native code/.test(String(WeakMap))}});var require_shared_key=__commonJS({"node_modules/core-js/internals/shared-key.js"(exports,module){"use strict";init_define_process_env();init_shim();var shared=require_shared(),uid=require_uid(),keys=shared("keys");module.exports=function(key){return keys[key]||(keys[key]=uid(key))}}});var require_hidden_keys=__commonJS({"node_modules/core-js/internals/hidden-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports={}}});var require_internal_state=__commonJS({"node_modules/core-js/internals/internal-state.js"(exports,module){"use strict";init_define_process_env();init_shim();var NATIVE_WEAK_MAP=require_weak_map_basic_detection(),global=require_global(),isObject=require_is_object(),createNonEnumerableProperty=require_create_non_enumerable_property(),hasOwn=require_has_own_property(),shared=require_shared_store(),sharedKey=require_shared_key(),hiddenKeys=require_hidden_keys(),OBJECT_ALREADY_INITIALIZED="Object already initialized",TypeError2=global.TypeError,WeakMap=global.WeakMap,set,get,has,enforce=function(it){return has(it)?get(it):set(it,{})},getterFor=function(TYPE){return function(it){var state;if(!isObject(it)||(state=get(it)).type!==TYPE)throw new TypeError2("Incompatible receiver, "+TYPE+" required");return state}};NATIVE_WEAK_MAP||shared.state?(store=shared.state||(shared.state=new WeakMap),store.get=store.get,store.has=store.has,store.set=store.set,set=function(it,metadata){if(store.has(it))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,store.set(it,metadata),metadata},get=function(it){return store.get(it)||{}},has=function(it){return store.has(it)}):(STATE=sharedKey("state"),hiddenKeys[STATE]=!0,set=function(it,metadata){if(hasOwn(it,STATE))throw new TypeError2(OBJECT_ALREADY_INITIALIZED);return metadata.facade=it,createNonEnumerableProperty(it,STATE,metadata),metadata},get=function(it){return hasOwn(it,STATE)?it[STATE]:{}},has=function(it){return hasOwn(it,STATE)});var store,STATE;module.exports={set,get,has,enforce,getterFor}}});var require_make_built_in=__commonJS({"node_modules/core-js/internals/make-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),fails=require_fails(),isCallable=require_is_callable(),hasOwn=require_has_own_property(),DESCRIPTORS=require_descriptors(),CONFIGURABLE_FUNCTION_NAME=require_function_name().CONFIGURABLE,inspectSource=require_inspect_source(),InternalStateModule=require_internal_state(),enforceInternalState=InternalStateModule.enforce,getInternalState=InternalStateModule.get,$String=String,defineProperty=Object.defineProperty,stringSlice=uncurryThis("".slice),replace=uncurryThis("".replace),join=uncurr
86yThis([].join),CONFIGURABLE_LENGTH=DESCRIPTORS&&!fails(function(){return defineProperty(function(){},"length",{value:8}).length!==8}),TEMPLATE=String(String).split("String"),makeBuiltIn=module.exports=function(value,name,options){stringSlice($String(name),0,7)==="Symbol("&&(name="["+replace($String(name),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),options&&options.getter&&(name="get "+name),options&&options.setter&&(name="set "+name),(!hasOwn(value,"name")||CONFIGURABLE_FUNCTION_NAME&&value.name!==name)&&(DESCRIPTORS?defineProperty(value,"name",{value:name,configurable:!0}):value.name=name),CONFIGURABLE_LENGTH&&options&&hasOwn(options,"arity")&&value.length!==options.arity&&defineProperty(value,"length",{value:options.arity});try{options&&hasOwn(options,"constructor")&&options.constructor?DESCRIPTORS&&defineProperty(value,"prototype",{writable:!1}):value.prototype&&(value.prototype=void 0)}catch{}var state=enforceInternalState(value);return hasOwn(state,"source")||(state.source=join(TEMPLATE,typeof name=="string"?name:"")),value};Function.prototype.toString=makeBuiltIn(function(){return isCallable(this)&&getInternalState(this).source||inspectSource(this)},"toString")}});var require_define_built_in=__commonJS({"node_modules/core-js/internals/define-built-in.js"(exports,module){"use strict";init_define_process_env();init_shim();var isCallable=require_is_callable(),definePropertyModule=require_object_define_property(),makeBuiltIn=require_make_built_in(),defineGlobalProperty=require_define_global_property();module.exports=function(O,key,value,options){options||(options={});var simple=options.enumerable,name=options.name!==void 0?options.name:key;if(isCallable(value)&&makeBuiltIn(value,name,options),options.global)simple?O[key]=value:defineGlobalProperty(key,value);else{try{options.unsafe?O[key]&&(simple=!0):delete O[key]}catch{}simple?O[key]=value:definePropertyModule.f(O,key,{value,enumerable:!1,configurable:!options.nonConfigurable,writable:!options.nonWritable})}return O}}});var require_math_trunc=__commonJS({"node_modules/core-js/internals/math-trunc.js"(exports,module){"use strict";init_define_process_env();init_shim();var ceil=Math.ceil,floor=Math.floor;module.exports=Math.trunc||function(x){var n=+x;return(n>0?floor:ceil)(n)}}});var require_to_integer_or_infinity=__commonJS({"node_modules/core-js/internals/to-integer-or-infinity.js"(exports,module){"use strict";init_define_process_env();init_shim();var trunc=require_math_trunc();module.exports=function(argument){var number=+argument;return number!==number||number===0?0:trunc(number)}}});var require_to_absolute_index=__commonJS({"node_modules/core-js/internals/to-absolute-index.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),max=Math.max,min=Math.min;module.exports=function(index,length){var integer=toIntegerOrInfinity(index);return integer<0?max(integer+length,0):min(integer,length)}}});var require_to_length=__commonJS({"node_modules/core-js/internals/to-length.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIntegerOrInfinity=require_to_integer_or_infinity(),min=Math.min;module.exports=function(argument){var len=toIntegerOrInfinity(argument);return len>0?min(len,9007199254740991):0}}});var require_length_of_array_like=__commonJS({"node_modules/core-js/internals/length-of-array-like.js"(exports,module){"use strict";init_define_process_env();init_shim();var toLength=require_to_length();module.exports=function(obj){return toLength(obj.length)}}});var require_array_includes=__commonJS({"node_modules/core-js/internals/array-includes.js"(exports,module){"use strict";init_define_process_env();init_shim();var toIndexedObject=require_to_indexed_object(),toAbsoluteIndex=require_to_absolute_index(),lengthOfArrayLike=require_length_of_array_like(),createMethod=function(IS_INCLUDES){return function($this,el,fromIndex){var O=toIndexedObject($this),length=lengthOfArrayLike(O),index=toAbsoluteIndex(fromIndex,length),value;if(IS_INCLUDES&&el!==el){for(;length>index;)if(value=O[index++],value!==value)return!0}else for(;length>index;index++)if((IS_INCLUDES||index in O)&&O[index]===el)return IS_INCLUDES||index||0;return!IS_INCLUDES&&-1}};module.exports={includes:createMethod(!0),indexOf:createMethod(!1)}}});var require_object_keys_internal=__commonJS({"node_modules/core-js/internals/object-keys-internal.js"(exports,module){"use strict";init_define_process_env();init_shim();var uncurryThis=require_function_uncurry_this(),hasOwn=require_has_own_property(),toIndexedObject=require_to_indexed_object(),indexOf=require_array_includes().indexOf,hiddenKeys=require_hidden_keys(),push=uncurryThis([].push);module.exports=function(object,names){var O=toIndexedObject(object),i=0,result=[],key;for(key in O)!hasOwn(hiddenKeys,key)&&hasOwn(O,key)&&push(result,key);for(;names.length>i;)hasOwn(O,key=names[i++])&&(~indexOf(result,key)||push(result,key));return result}}});var require_enum_bug_keys=__commonJS({"node_modules/core-js/internals/enum-bug-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleStr
86ing","toString","valueOf"]}});var require_object_get_own_property_names=__commonJS({"node_modules/core-js/internals/object-get-own-property-names.js"(exports){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=enumBugKeys.concat("length","prototype");exports.f=Object.getOwnPropertyNames||function(O){return internalObjectKeys(O,hiddenKeys)}}});var require_object_get_own_property_symbols=__commonJS({"node_modules/core-js/internals/object-get-own-property-symbols.js"(exports){"use strict";init_define_process_env();init_shim();exports.f=Object.getOwnPropertySymbols}});var require_own_keys=__commonJS({"node_modules/core-js/internals/own-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in(),uncurryThis=require_function_uncurry_this(),getOwnPropertyNamesModule=require_object_get_own_property_names(),getOwnPropertySymbolsModule=require_object_get_own_property_symbols(),anObject=require_an_object(),concat=uncurryThis([].concat);module.exports=getBuiltIn("Reflect","ownKeys")||function(it){var keys=getOwnPropertyNamesModule.f(anObject(it)),getOwnPropertySymbols=getOwnPropertySymbolsModule.f;return getOwnPropertySymbols?concat(keys,getOwnPropertySymbols(it)):keys}}});var require_copy_constructor_properties=__commonJS({"node_modules/core-js/internals/copy-constructor-properties.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),ownKeys=require_own_keys(),getOwnPropertyDescriptorModule=require_object_get_own_property_descriptor(),definePropertyModule=require_object_define_property();module.exports=function(target,source,exceptions){for(var keys=ownKeys(source),defineProperty=definePropertyModule.f,getOwnPropertyDescriptor=getOwnPropertyDescriptorModule.f,i=0;i<keys.length;i++){var key=keys[i];!hasOwn(target,key)&&!(exceptions&&hasOwn(exceptions,key))&&defineProperty(target,key,getOwnPropertyDescriptor(source,key))}}}});var require_is_forced=__commonJS({"node_modules/core-js/internals/is-forced.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),replacement=/#|\.prototype\./,isForced=function(feature,detection){var value=data[normalize(feature)];return value===POLYFILL?!0:value===NATIVE?!1:isCallable(detection)?fails(detection):!!detection},normalize=isForced.normalize=function(string){return String(string).replace(replacement,".").toLowerCase()},data=isForced.data={},NATIVE=isForced.NATIVE="N",POLYFILL=isForced.POLYFILL="P";module.exports=isForced}});var require_export=__commonJS({"node_modules/core-js/internals/export.js"(exports,module){"use strict";init_define_process_env();init_shim();var global=require_global(),getOwnPropertyDescriptor=require_object_get_own_property_descriptor().f,createNonEnumerableProperty=require_create_non_enumerable_property(),defineBuiltIn=require_define_built_in(),defineGlobalProperty=require_define_global_property(),copyConstructorProperties=require_copy_constructor_properties(),isForced=require_is_forced();module.exports=function(options,source){var TARGET=options.target,GLOBAL=options.global,STATIC=options.stat,FORCED,target,key,targetProperty,sourceProperty,descriptor;if(GLOBAL?target=global:STATIC?target=global[TARGET]||defineGlobalProperty(TARGET,{}):target=global[TARGET]&&global[TARGET].prototype,target)for(key in source){if(sourceProperty=source[key],options.dontCallGetSet?(descriptor=getOwnPropertyDescriptor(target,key),targetProperty=descriptor&&descriptor.value):targetProperty=target[key],FORCED=isForced(GLOBAL?key:TARGET+(STATIC?".":"#")+key,options.forced),!FORCED&&targetProperty!==void 0){if(typeof sourceProperty==typeof targetProperty)continue;copyConstructorProperties(sourceProperty,targetProperty)}(options.sham||targetProperty&&targetProperty.sham)&&createNonEnumerableProperty(sourceProperty,"sham",!0),defineBuiltIn(target,key,sourceProperty,options)}}}});var require_an_instance=__commonJS({"node_modules/core-js/internals/an-instance.js"(exports,module){"use strict";init_define_process_env();init_shim();var isPrototypeOf=require_object_is_prototype_of(),$TypeError=TypeError;module.exports=function(it,Prototype){if(isPrototypeOf(Prototype,it))return it;throw new $TypeError("Incorrect invocation")}}});var require_correct_prototype_getter=__commonJS({"node_modules/core-js/internals/correct-prototype-getter.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails();module.exports=!fails(function(){function F(){}return F.prototype.constructor=null,Object.getPrototypeOf(new F)!==F.prototype})}});var require_object_get_prototype_of=__commonJS({"node_modules/core-js/internals/object-get-prototype-of.js"(exports,module){"use strict";init_define_process_env();init_shim();var hasOwn=require_has_own_property(),isCallable=require_is_callable(),toObject=require_to_object(),sharedKey=require_shared_key(),CORRECT_PROTOTYPE_GETTER=require_correct_prototype_getter(),IE_PROTO=sharedKey("IE_PROTO"),$Object=Object,ObjectPrototype=$Object.prototype;module.exports=CORRECT_PROTOTYPE_GETTER?$Object.getPrototypeOf:function(O){var object=toObject(O);if(hasOwn(object,IE_PROTO))return object[IE_PROTO];var constructor=object.constructor;return isCallable(constructor)&&object instanceof constructor?constructor.prototype:object instanceof $Object?ObjectPrototype:null}}});var require_define_built_in_accessor=__commonJS({"node_modules/core-js/internals/define-built-in-accessor.js"(exports,module){"use strict";init_define_process_env();init_shim();var makeBuiltIn=require_make_built_in(),defineProperty=require_object_define_property();module.exports=function(target,name,descriptor){return descriptor.get&&makeBuiltIn(descriptor.get,name,{getter:!0}),descriptor.set&&makeBuiltIn(descriptor.set,name,{setter:!0}),defineProperty.f(target,name,descriptor)}}});var require_create_property=__commonJS({"node_modules/core-js/internals/create-property.js"(exports,module){"use strict";init_define_process_env();init_shim();var toPropertyKey=require_to_property_key(),definePropertyModule=require_object_define_property(),createPropertyDescriptor=require_create_property_descriptor();module.exports=function(object,key,value){var propertyKey=toPropertyKey(key);propertyKey in object?definePropertyModule.f(object,propertyKey,createPropertyDescriptor(0,value)):object[propertyKey]=value}}});var require_object_keys=__commonJS({"node_modules/core-js/internals/object-keys.js"(exports,module){"use strict";init_define_process_env();init_shim();var internalObjectKeys=require_object_keys_internal(),enumBugKeys=require_enum_bug_keys();module.exports=Object.keys||function(O){return internalObjectKeys(O,enumBugKeys)}}});var require_object_define_properties=__commonJS({"node_modules/core-js/internals/object-define-properties.js"(exports){"use strict";init_define_process_env();init_shim();var DESCRIPTORS=require_descriptors(),V8_PROTOTYPE_DEFINE_BUG=require_v8_prototype_define_bug(),definePropertyModule=require_object_define_property(),anObject=require_an_object(),toIndexedObject=require_to_indexed_object(),objectKeys=require_object_keys();exports.f=DESCRIPTORS&&!V8_PROTOTYPE_DEFINE_BUG?Object.defineProperties:function(O,Properties){anObject(O);for(var props=toIndexedObject(Properties),keys=objectKeys(Properties),length=keys.length,index=0,key;length>index;)definePropertyModule.f(O,key=keys[index++],props[key]);return O}}});var require_html=__commonJS({"node_modules/core-js/internals/html.js"(exports,module){"use strict";init_define_process_env();init_shim();var getBuiltIn=require_get_built_in();module.exports=getBuiltIn("document","documentElement")}});var require_object_create=__commonJS({"node_modules/core-js/internals/object-create.js"(exports,module){"use strict";init_define_process_env();init_shim();var anObject=require_an_object(),definePropertiesModule=require_object_define_properties(),enumBugKeys=require_enum_bug_keys(),hiddenKeys=require_hidden_keys(),html=require_html(),documentCreateElement=require_document_create_element
86(),sharedKey=require_shared_key(),GT=">",LT="<",PROTOTYPE="prototype",SCRIPT="script",IE_PROTO=sharedKey("IE_PROTO"),EmptyConstructor=function(){},scriptTag=function(content){return LT+SCRIPT+GT+content+LT+"/"+SCRIPT+GT},NullProtoObjectViaActiveX=function(activeXDocument2){activeXDocument2.write(scriptTag("")),activeXDocument2.close();var temp=activeXDocument2.parentWindow.Object;return activeXDocument2=null,temp},NullProtoObjectViaIFrame=function(){var iframe=documentCreateElement("iframe"),JS="java"+SCRIPT+":",iframeDocument;return iframe.style.display="none",html.appendChild(iframe),iframe.src=String(JS),iframeDocument=iframe.contentWindow.document,iframeDocument.open(),iframeDocument.write(scriptTag("document.F=Object")),iframeDocument.close(),iframeDocument.F},activeXDocument,NullProtoObject=function(){try{activeXDocument=new ActiveXObject("htmlfile")}catch{}NullProtoObject=typeof document<"u"?document.domain&&activeXDocument?NullProtoObjectViaActiveX(activeXDocument):NullProtoObjectViaIFrame():NullProtoObjectViaActiveX(activeXDocument);for(var length=enumBugKeys.length;length--;)delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];return NullProtoObject()};hiddenKeys[IE_PROTO]=!0;module.exports=Object.create||function(O,Properties){var result;return O!==null?(EmptyConstructor[PROTOTYPE]=anObject(O),result=new EmptyConstructor,EmptyConstructor[PROTOTYPE]=null,result[IE_PROTO]=O):result=NullProtoObject(),Properties===void 0?result:definePropertiesModule.f(result,Properties)}}});var require_iterators_core=__commonJS({"node_modules/core-js/internals/iterators-core.js"(exports,module){"use strict";init_define_process_env();init_shim();var fails=require_fails(),isCallable=require_is_callable(),isObject=require_is_object(),create=require_object_create(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltIn=require_define_built_in(),wellKnownSymbol=require_well_known_symbol(),IS_PURE=require_is_pure(),ITERATOR=wellKnownSymbol("iterator"),BUGGY_SAFARI_ITERATORS=!1,IteratorPrototype,PrototypeOfArrayIteratorPrototype,arrayIterator;[].keys&&(arrayIterator=[].keys(),"next"in arrayIterator?(PrototypeOfArrayIteratorPrototype=getPrototypeOf(getPrototypeOf(arrayIterator)),PrototypeOfArrayIteratorPrototype!==Object.prototype&&(IteratorPrototype=PrototypeOfArrayIteratorPrototype)):BUGGY_SAFARI_ITERATORS=!0);var NEW_ITERATOR_PROTOTYPE=!isObject(IteratorPrototype)||fails(function(){var test={};return IteratorPrototype[ITERATOR].call(test)!==test});NEW_ITERATOR_PROTOTYPE?IteratorPrototype={}:IS_PURE&&(IteratorPrototype=create(IteratorPrototype));isCallable(IteratorPrototype[ITERATOR])||defineBuiltIn(IteratorPrototype,ITERATOR,function(){return this});module.exports={IteratorPrototype,BUGGY_SAFARI_ITERATORS}}});var require_esnext_iterator_constructor=__commonJS({"node_modules/core-js/modules/esnext.iterator.constructor.js"(){"use strict";init_define_process_env();init_shim();var $=require_export(),global=require_global(),anInstance=require_an_instance(),anObject=require_an_object(),isCallable=require_is_callable(),getPrototypeOf=require_object_get_prototype_of(),defineBuiltInAccessor=require_define_built_in_accessor(),createProperty=require_create_property(),fails=require_fails(),hasOwn=require_has_own_property(),wellKnownSymbol=require_well_known_symbol(),IteratorPrototype=require_iterators_core().IteratorPrototype,DESCRIPTORS=require_descriptors(),IS_PURE=require_is_pure(),CONSTRUCTOR="constructor",ITERATOR="Iterator",TO_STRING_TAG=wellKnownSymbol("toStringTag"),$TypeError=TypeError,NativeIterator=global[ITERATOR],FORCED=IS_PURE||!isCallable(NativeIterator)||NativeIterator.prototype!==IteratorPrototype||!fails(function(){NativeIterator({})}),IteratorConstructor=function(){if(anInstance(this,IteratorPrototype),getPrototypeOf(this)===IteratorPrototype)throw new $TypeError("Abstract class Iterator not directly constructable")},defineIteratorPrototypeAccessor=function(key,value){DESCRIPTORS?defineBuiltInAccessor(IteratorPrototype,key,{configurable:!0,get:function(){return value},set:function(replacement){if(anObject(this),this===IteratorPrototype)throw new $TypeError("You can't redefine this property");hasOwn(this,key)?this[key]=replacement:createProperty(this,key,replacement)}}):IteratorPrototype[key]=value};hasOwn(IteratorPrototype,TO_STRING_TAG)||defineIteratorPrototypeAccessor(TO_STRING_TAG,ITERATOR);(FORCED||!hasOwn(IteratorPrototype,CONSTRUCTOR)||IteratorPrototype[CONSTRUCTOR]===Object)&&defineIteratorPrototypeAccessor(CONSTRUCTOR,IteratorConstructor);IteratorConstructor.prototype=IteratorPrototype;$({global:!0,constructor:!0,forced:FORCED},{Iterator:IteratorConstructor})}});var require_get_iterator_direct=__commonJS({"node_modules/core-js/internals/get-iterator-direct.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(obj){return{iterator:obj,next:obj.next,done:!1}}}});var require_define_built_ins=__commonJS({"node_modules/core-js/internals/define-built-ins.js"(exports,module){"use strict";init_define_process_env();init_shim();var defineBuiltIn=require_define_built_in();module.exports=function(target,src,options){for(var key in src)defineBuiltIn(target,key,src[key],options);return target}}});var require_create_iter_result_object=__commonJS({"node_modules/core-js/internals/create-iter-result-object.js"(exports,module){"use strict";init_define_process_env();init_shim();module.exports=function(value,done){return{value,done}}}});var require_iterator_close=__commonJS({"node_modules/core-js/internals/iterator-close.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),anObject=require_an_object(),getMethod=require_get_method();module.exports=function(iterator,kind,value){var innerResult,innerError;anObject(iterator);try{if(innerResult=getMethod(iterator,"return"),!innerResult){if(kind==="throw")throw value;return value}innerResult=call(innerResult,iterator)}catch(error){innerError=!0,innerResult=error}if(kind==="throw")throw value;if(innerError)throw innerResult;return anObject(innerResult),value}}});var require_iterator_create_proxy=__commonJS({"node_modules/core-js/internals/iterator-create-proxy.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),create=require_object_create(),createNonEnumerableProperty=require_create_non_enumerable_property(),defineBuiltIns=require_define_built_ins(),wellKnownSymbol=require_well_known_symbol(),InternalStateModule=require_internal_state(),getMethod=require_get_method(),IteratorPrototype=require_iterators_core().IteratorPrototype,createIterResultObject=require_create_iter_result_object(),iteratorClose=require_iterator_close(),TO_STRING_TAG=wellKnownSymbol("toStringTag"),ITERATOR_HELPER="IteratorHelper",WRAP_FOR_VALID_ITERATOR="WrapForValidIterator",setInternalState=InternalStateModule.set,createIteratorProxyPrototype=function(IS_ITERATOR){var getInternalState=InternalStateModule.getterFor(IS_ITERATOR?WRAP_FOR_VALID_ITERATOR:ITERATOR_HELPER);return defineBuiltIns(create(IteratorPrototype),{next:function(){var state=getInternalState(this);if(IS_ITERATOR)return state.nextHandler();try{var result=state.done?void 0:state.nextHandler();return createIterResultObject(result,state.done)}catch(error){throw state.done=!0,error}},return:function(){var state=getInternalState(this),iterator=state.iterator;if(state.done=!0,IS_ITERATOR){var returnMethod=getMethod(iterator,"return");return returnMethod?call(returnMethod,iterator):createIterResultObject(void 0,!0)}if(state.inner)try{iteratorClose(state.inner.iterator,"normal")}catch(error){return iteratorClose(iterator,"throw",error)}return iteratorClose(iterator,"normal"),createIterResultObject(void 0,!0)}})},WrapForValidIteratorPrototype=createIteratorProxyPrototype(!0),IteratorHelperPrototype=createIteratorProxyPrototype(!1);createNonEnumerableProperty(IteratorHelperPrototype,TO_STRING_TAG,"Iterator Helper");module.exports=function(nextHandler,IS_ITERATOR){var IteratorProxy=function(record,state){state?(state.iterator=record.iterator,state.next=record.next):state=record,state.type=IS_ITERATOR?WRAP_FOR_VALID_ITERATOR:ITERATOR_HELPER,state.nextHandler=nextHandler,state.counter=0,state.done=!1,setInternalState(this,state)};return IteratorProxy.prototype=IS_ITERATOR?WrapForValidIteratorPrototype:IteratorHelperPrototype,IteratorProxy}}});var require_call_with_safe_iteration_closing=__commonJS({"node_modules/core-js/internals/call-with-safe-iteration-closing.js"(exports,module){"use strict";init_define_process_env();init_shim();var anObject=require_an_object(),iteratorClose=require_iterator_close();module.exports=function(iterator,fn,value,ENTRIES){try{return ENTRIES?fn(anObject(value)[0],value[1]):fn(value)}catch(error){iteratorClose(iterator,"throw",error)}}}});var require_esnext_iterator_filter=__commonJS({"node_modules/core-js/modules/esnext.iterator.filter.js"(){"use strict";init_define_process_env();init_shim();var $=require_export(),call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct(),createIteratorProxy=require_iterator_create_proxy(),callWithSafeIterationClosing=require_call_with_safe_iteration_closing(),IS_PURE=require_is_pure(),IteratorProxy=createIteratorProxy(function(){for(var iterator=this.iterator,predicate=this.predicate,next=this.next,result,done,value;;){if(result=anObject(call(next,iterator)),done=this.done=!!result.done,done)return;if(value=result.value,callWithSafeIterationClosing(iterator,predicate,[value,this.counter++],!0))return value}});$({target:"Iterator",proto:!0,real:!0,forced:IS_PURE},{filter:function(predicate){return anObject(this),aCallable(predicate),new IteratorProxy(getIteratorDirect(this),{predicate})}})}});var require_iterator_map=__commonJS({"node_modules/core-js/internals/iterator-map.js"(exports,module){"use strict";init_define_process_env();init_shim();var call=require_function_call(),aCallable=require_a_callable(),anObject=require_an_object(),getIteratorDirect=require_get_iterator_direct(),createIteratorProxy=require_iterator_create_proxy(),callWithSafeIterationClosing=require_call_with_safe_iteration_closing(),IteratorProxy=createIteratorProxy(function(){var iterator=this.iterator,result=anObject(call(this.next,iterator)),done=this.done=!!result.done;if(!done)return callWithSafeIterationClosing(iterator,this.mapper,[result.value,this.counter++],!0)});module.exports=function(mapper){return anObject(this),aCallable(mapper),new IteratorProxy(getIteratorDirect(this),{mapper})}}});var require_esnext_iterator_map=__commonJS({"node_modules/core-js/modules/esnext.iterator.map.js"(){"use strict";init_define_process_env();init_shim();var $=require_export(),map=require_iterator_map(),IS_PURE=require_is_pure();$({target:"Iterator",proto:!0,real:!0,forced:IS_PURE},{map})}});init_define_process_env();init_shim();var import_esnext_iterator_constructor=__toESM(require_esnext_iterator_constructor()),import_esnext_iterator_filter=__toESM(require_esnext_iterator_filter()),import_esnext_iterator_map=__toESM(require_esnext_iterator_map());init_define_process_env();init_shim();var u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register};var external=safe_require.safe_require("./external"),services_editor_utils=safe_require.safe_require("./services/client/editor_utils"),appquery=safe_require.safe_require("./lang/appquery"),logger=safe_require.safe_require("./logger"),Lib=safe_require.safe_require("./lib"),workflow_utils=safe_require.safe_require("./lang/workflow/workflow_utils"),_mixpanel_init=!1;
86function init_mixpanel(){if(_mixpanel_init||!window?.b_mp_key)return;_mixpanel_init=!0;let api_host=appquery.get_public_setting("mixpanel_api_host");return api_host?mixpanel.init(window.b_mp_key,{api_host}):mixpanel.init(window.b_mp_key)}function reset_mixpanel_init_for_tests(){_mixpanel_init=!1}function generate_object_from_key(obj){let res={},object=obj??{};for(let idx in object){let a=object[idx];res[a.key]=a.value}return res}var cls=class extends external.Service{constructor(){super(),this.authenticator=new external.NoAuth,this.actions=this._get_initial_actions()}get keys(){return{token:{caption:"Token",type:"client_safe"},appsecret:{caption:"API Secret",type:"secure"},appid:{caption:"API Key",type:"client_safe"},api_host:{caption:"API Host (optional)",type:"client_safe",editor:"Dropdown",get set(){return Lib().sets.get_set("Object")({"https://api.mixpanel.com":"US","https://api-eu.mixpanel.com":"EU","https://api-in.mixpanel.com":"India"})},default_value:"https://api.mixpanel.com"}}}_get_initial_actions(){return{SendEventToMixpanel:{category:"analytics",field_names:u.extend({event_name:{},additional_values:{}},services_editor_utils.enter_your_api_key_button_field_names),run(action,properties,context,cb){let cb_called=!1;function new_cb(_err){if(!cb_called)return cb_called=!0,cb(_err)}return setTimeout(new_cb,1e3),Lib().user.is_cookie_opt_in()||new_cb(),Lib().user.on_cookie_opt_in(()=>{if(typeof mixpanel>"u"||mixpanel===null){logger.error("missing mixpanel! did it get left out of run_js_page?"),new_cb();return}if(init_mixpanel(),properties.event_name){let values=generate_object_from_key(properties.additional_values),current_user=Lib().current_user(),id=current_user._id();try{mixpanel.identify(id)}catch(error){let err=error;logger.error("mixpanel.identify failed",{id,error:err})}return u.run_once(30,()=>current_user.is_logged_in()?current_user.get_email():null,(err,email)=>{if(err){new_cb(err);return}try{return email&&mixpanel.name_tag(email),mixpanel.track(properties.event_name,values,()=>new_cb())}catch(error1){return err=error1,logger.error("Error in mixpanel.name_tag or mixpanel.track with",{event_name:properties.event_name,values,email,err}),new_cb()}})}else return new_cb()})},data_to_refresh:null},SendUserToMixpanel:{category:"analytics",field_names:u.extend({user_name:{},additional_values:{}},services_editor_utils.enter_your_api_key_button_field_names),run(action,properties,context,cb){let cb_called=!1;function new_cb(_err){if(!cb_called)return cb_called=!0,cb(_err)}return setTimeout(new_cb,1e3),Lib().user.is_cookie_opt_in()||new_cb(),Lib().user.on_cookie_opt_in(()=>{if(typeof mixpanel>"u"||mixpanel===null){logger.error("missing mixpanel! did it get left out of run_js_page?"),new_cb();return}init_mixpanel();let values=generate_object_from_key(properties.additional_values);mixpanel?.register(values);let current_user=Lib().current_user();return mixpanel.identify(current_user._id()),u.run_once(30,()=>{let date,email,is_logged_in=current_user.is_logged_in();return is_logged_in&&(email=current_user.get_email(),date=current_user.child("Created Date").get()),{is_logged_in,email,date}},(err,_ref)=>{let{is_logged_in,email,date}=_ref;return err||!is_logged_in?new_cb(err):(mixpanel.name_tag(email??properties.user_name),values.$email=email,values.$created=new Date(date),values.$name=properties.user_name,mixpanel.people.set(values,response=>(response!==1&&logger.error("issue with Mixpanel people set",{response,values}),new_cb())))})})},data_to_refresh:null},SendChargeToMixpanel:{category:"analytics",field_names:u.extend({charge_value:{},additional_values:{}},services_editor_utils.enter_your_api_key_button_field_names),run(action,properties,context,cb){let cb_called=!1;function new_cb(_err){if(!cb_called)return cb_called=!0,cb(_err)}return setTimeout(new_cb,1e3),Lib().user.is_cookie_opt_in()||new_cb(),Lib().user.on_cookie_opt_in(()=>{if(typeof mixpanel>"u"||mixpanel===null){logger.error("missing mixpanel! did it get left out of run_js_page?"),new_cb();return}return init_mixpanel(),u.run_once(30,()=>{let current_user=Lib().current_user();if(current_user.is_logged_in())return{email:current_user.get_email(),id:current_user._id()}},(err,response)=>{if(err){new_cb(err);return}if(response.email)if(mixpanel.identify(response.id),mixpanel.people.set({$email:response.email}),properties.charge_value){let values=generate_object_from_key(properties.additional_values);return mixpanel.people.track_charge(properties.charge_value,values,()=>new_cb())}else return new_cb();else return new_cb()})})},data_to_refresh:null},DeleteCurrentUserFromMixpanel:{category:"analytics",field_names:services_editor_utils.enter_your_api_key_button_field_names,display(){return"Delete the current user from Mixpanel"},not_api:!0,_fields(){return[]},run(action,properties,context,cb){if(mixpanel?.people?.delete_user==null){logger.error("missing mixpanel! did it get left out of run_js_page?"),cb();return}
86return init_mixpanel(),mixpanel.people.delete_user(),setTimeout(cb,300)},data_to_refresh:null}}}},mixpanel_exports={cls,init_mixpanel};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.mixpanel=mixpanel_exports);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("mixpanel",mixpanel_exports);})(); 87/*! Bundled license information: 88 89buffer/index.js: 90 (*! 91 * The buffer module from node.js, for the browser. 92 * 93 * @author Feross Aboukhadijeh <https://feross.org> 94 * @license MIT 95 *) 96*/ 97 98} 99 100 101window.preloaded['plugin/first_party:mixpanel'] = true; 102window._bubble_page_load_data.hardcoded_plugins['progressbar'] = true; 103window.__code__ = window.__code__ || {}; 104if(!window.__code__['3715b72e6109c185c3496bb9665da7f9f968deab9034763a31a4bcf5416ad40e']){window.__code__['3715b72e6109c185c3496bb9665da7f9f968deab9034763a31a4bcf5416ad40e']=1; 105 106"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exports:{}}).exports,mod),mod.exports};var __copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod));var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;
vendor: 26,589 bytes, line 106
106i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 106
106)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 106
106if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
106var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});init_define_process_env();init_shim();init_define_process_env();init_shim();var u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register};var Lib=safe_require.safe_require("./lib"),external=safe_require.safe_require("./external"),services=safe_require.safe_require("./services"),property_applications=safe_require.safe_require("./core/property_applications"),appquery=safe_require.safe_require("./lang/appquery"),element_eval=safe_require.safe_require("./lang/evaluation/element_eval"),PLUGIN_FILE="progressbar",element_modifications=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/element_modifications");element_modifications.set_legacy_element_modifications("progressbar-ProgressBar");var shared_field_metadata;u.uses_field_metadata()&&(shared_field_metadata=safe_require.safe_require("./core/shared_field_metadata"));function get_bar_label_styles(_ref){let{animation_delay="0s",bar_element,instance,percentage}=_ref,element_width=instance.current_width(),padding_left=0,padding_right=0;
106bar_element?.[0]&&(padding_left=parseInt(bar_element[0]?.style?.["padding-left"]||padding_left,10),padding_right=parseInt(bar_element[0]?.style?.["padding-right"]||padding_right,10));let total_left_right_padding=padding_left+padding_right,bar_width=element_width*percentage/100,transition="width "+animation_delay+", clip-path"+animation_delay,bar_label_styles={"clip-path":`inset(0px 0px 0px ${bar_width-padding_left}px)`,padding:"inherit",transition,width:element_width-total_left_right_padding},bar_label_overlay_styles={"clip-path":`inset(0px ${element_width-bar_width-padding_right}px 0px 0px)`,padding:"inherit",transition,width:element_width-total_left_right_padding};return{bar_label_styles,bar_label_overlay_styles}}function plugin_version(){return Lib()?appquery.get_public_setting("progressbar_installed_version")??0:1}function uses_css_responsive(){return Lib()?plugin_version()>=1||appquery.get_public_setting("progressbar_css_responsive")===!0:!0}var cls=class extends external.Service{constructor(){super(),this.authenticator=new external.NoAuth,this.elements=this._get_initial_elements()}_get_initial_elements(){return{ProgressBar:{display:"Progress Bar",category:"visual elements",icon:"ion-ios-speedometer",condition(root){return!root?.is_mobile?.()},defaults:{font_alignment:"center",font_color:"#FFFFFF",background_style:"bgcolor",bgcolor:"#FFFFFF",border_roundness:3,border_width:1,border_style:"solid",border_color:"#211A66",width:300,height:25},field_names:{percentage:{},animate:{default:!0,no_states:!0},bar_color:{default:"#7F95EB"}},primary_field(){return"percentage"},get_field_metadata(element){return{percentage:{caption:"Percentage",btype_id:"number"},bar_color:{caption:"Progress bar color",btype_id:"text"},animate:{caption:"Animate progress",btype_id:"boolean"},...new property_applications.Dimensions().get_property_metadata(element,"Dimensions"),...new property_applications.InputPadding(".inner-progressbar").get_property_metadata(element),...new property_applications.Font().get_property_metadata(element),...new property_applications.FontShadow().get_property_metadata(element),...new property_applications.Border().get_property_metadata(element),...new property_applications.BoxShadow().get_property_metadata(element),...new property_applications.Background().get_property_metadata(element),...new property_applications.Rotation().get_property_metadata(element),...new property_applications.ResponsiveElement().get_property_metadata(element),...new property_applications.MinWidth().get_property_metadata(element),...new property_applications.UniqueID().get_property_metadata(element),...shared_field_metadata.get_is_visible_property()}},_fields(element){return[{name:"percentage",caption:"Percentage",editor:"Basic",btype:"number",pretty:{section:"ProgressBarContent"}},{name:"bar_color",caption:"Progress bar color",editor:"Color",dynamic:!0,pretty:{section:"ProgressBarContent"}},{name:"animate",caption:"Animate progress",editor:"Checkbox",pretty:{section:"ProgressBarContent"}}]},property_applications:[new property_applications.Dimensions,new property_applications.InputPadding(".inner-progressbar"),new property_applications.Font,new property_applications.FontShadow,new property_applications.Border,new property_applications.BoxShadow,new property_applications.Background,new property_applications.Rotation,new property_applications.ResponsiveElement],get uses_css_responsive(){return uses_css_responsive()},get_html(instance){return"<div></div>"},get_min_width(){return 0},change_cursor_style_if_clickable:!0,initialize(instance){services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE});let canvas=instance.get_canvas(),bar=u.div("inner-progressbar",canvas),bar_label=u.div("progressbar-label",bar),bar_label_overlay=u.div("progressbar-label-overlay",bar);return instance.autorun(()=>{let percentage=element_eval.evaluate_property(instance,"percentage");instance.run_mode()?percentage??=0:percentage??=60,percentage>100?percentage=100:percentage<0&&(percentage=0);let prop_node=instance.element.property("percentage");instance.run_mode()||prop_node.is_static()?(bar_label.html(Lib().locale().format_decimal(percentage)+"%"),bar_label_overlay.html(Lib().locale().format_decimal(percentage)+"%")):(bar_label.html(prop_node.get_tree_display()+" %"),bar_label_overlay.html(prop_node.get_tree_display()+" %"));let animation_delay=instance.run_mode()&&instance.get_static_property("animate")?".3s":"0s";bar.css({"background-color":element_eval.evaluate_property(instance,"bar_color"),"line-height":instance.current_height()+"px",transition:"width "+animation_delay,width:percentage+"%"});let{bar_label_styles,bar_label_overlay_styles}=get_bar_label_styles({animation_delay,bar_element:bar,instance,percentage});return bar_label.css(bar_label_styles),bar_label_overlay.css(bar_label_overlay_styles),bar})},add_an_invisible_div_on_the_top:!1,css_files:["css/optional/progressbar.css"],events:["ButtonClicked","ElementPressed"],contains_group_data:!1,is_input:!1}}}keys(){return plugin_version()>=1?{}:{css_responsive:{caption:"Use new responsive properties for this plugin's elements",type:"client_safe",editor:"Checkbox"}}}},progressbar={cls};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.progressbar=progressbar);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("progressbar",progressbar);})(); 107/*! Bundled license information: 108 109buffer/index.js: 110 (*! 111 * The buffer module from node.js, for the browser. 112 * 113 * @author Feross Aboukhadijeh <https://feross.org> 114 * @license MIT 115 *) 116*/ 117 118} 119 120 121window.preloaded['plugin/first_party:progressbar'] = true; 122window._bubble_page_load_data.hardcoded_plugins['materialicons'] = true; 123window.__code__ = window.__code__ || {}; 124if(!window.__code__['43fcf961fef273a0bb0d8a2f2fe7b3e8e9be71bf091c7fda5a26de690b11ffce']){window.__code__['43fcf961fef273a0bb0d8a2f2fe7b3e8e9be71bf091c7fda5a26de690b11ffce']=1; 125 126"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exp
vendor: 5,994 bytes, line 126
126orts:{}}).exports,mod),mod.exports};var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod)),__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>
vendor: 23,595 bytes, line 126
126K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 126
126)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 126
126if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
126var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var u,base_safe_require,legacy_keys,safe_require,init_window_register=__esm({"lib-browser/window_register.js"(){"use strict";init_define_process_env();init_shim();u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register}}});var materialicons_Materialicon_exports={};__export(materialicons_Materialicon_exports,{additional_data:()=>additional_data,initialize:()=>initialize,property_applications:()=>property_applications_internal});function initialize(instance){return services.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE}),instance.wait_for_visible_lite(()=>{let canvas=instance.get_canvas();return property_applications.patch_user_agent_styles(canvas),canvas.addClass("inner-element bubble-element material-icons"),element_eval.on_property_change(instance,"icon",icon=>{icon.includes(".outline")?(canvas.removeClass("material-icons"),canvas.addClass("material-icons-outline")):(canvas.removeClass("material-icons-outline"),canvas.addClass("material-icons")),canvas.text(icon.replace(".outline",""))}),element_eval.on_property_change(instance,"icon_color",icon_color=>canvas.css("color",icon_color)),icons_legacy.calculate_font_size_for_fontawesome(instance)})}var services,property_applications,icons_legacy,element_eval,PLUGIN_FILE,property_applications_internal,additional_data,init_materialicons_Materialicon=__esm({"lib-browser/optional/services/legacy/responsive_v0/materialicons_Materialicon.js"(){"use strict";init_define_process_env();init_shim();init_window_register();services=safe_require.safe_require("./services"),property_applications=safe_require.safe_require("./core/property_applications"),icons_legacy=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/shared/icons"),element_eval=safe_require.safe_require("./lang/evaluation/element_eval"),PLUGIN_FILE="materialicons",property_applications_internal=[new property_applications.MinWidth];additional_data={notify_width(instance,width){return instance.state("notify_width",width)}}}});init_define_process_env();init_shim();init_window_register();var element_eval2=safe_require.safe_require("./lang/evaluation/element_eval"),external=safe_require.safe_require("./external"),services2=safe_require.safe_require("./services"),Lib=safe_require.safe_require("./lib"),appquery=safe_require.safe_require("./lang/appquery"),property_applications2=safe_require.safe_require("./core/property_applications"),element_workflows=safe_require.safe_require("./core/core_elements/core_elements_utilities/element_workflows"),icons=safe_require.safe_require("./core/core_elements/shared/icons"),{MATERIAL_ICONS}
126=safe_require.safe_require("./constants/plugin"),element_modifications=safe_require.safe_require("./core/core_elements/legacy/responsive_v0/element_modifications");element_modifications.set_legacy_element_modifications("materialicons-Materialicon",(init_materialicons_Materialicon(),__toCommonJS(materialicons_Materialicon_exports)));var core_elements_fields,shared_field_metadata,goToElementEvent;u.is_edit_mode()&&!u.is_plugin_edit_mode()&&({goToElementEvent}=safe_require.safe_require("./editor/workflow_tab/logic/events"));u.uses_field_metadata()&&(core_elements_fields=safe_require.safe_require("./core/core_elements_fields"),core_elements_fields=core_elements_fields.default??core_elements_fields,shared_field_metadata=safe_require.safe_require("./core/shared_field_metadata"));var PLUGIN_FILE2="materialicons";function plugin_version(){return Lib()?appquery.get_public_setting("materialicons_installed_version")??0:1}function uses_css_responsive(){return Lib()?plugin_version()>=1||appquery.get_public_setting("materialicons_css_responsive")===!0:!0}var cls=class extends external.Service{constructor(){super(),this.authenticator=new external.NoAuth,this.elements=this._get_initial_elements()}_get_initial_elements(){return{Materialicon:{display:"Material Icon",category:"visual elements",icon:"ion-social-google",condition(root){return!root?.is_mobile?.()},defaults:{font_alignment:"center",background_style:"none",border_style:"none",border_roundness:4,border_width:2,border_color:"#6B6B6B",boxshadow_style:"none",width:80,height:80},field_names:u.extend({icon:{default:"insert_emoticon"},icon_color:{default:"#373737",in_style:!0}},element_workflows.start_workflow_field_names),property_applications:[new property_applications2.Dimensions,new property_applications2.FontShadow,new property_applications2.Border,new property_applications2.BoxShadow,new property_applications2.Background,new property_applications2.ToolTip,new property_applications2.ResponsiveElement],get uses_css_responsive(){return uses_css_responsive()},get_html(instance){return"<button></button>"},get_min_width(element){return 0},transition_properties:{icon_color:"color"},change_cursor_style_if_clickable:!0,initialize(instance){return services2.log_plugin_element_init({name:this.plugin_name,plugin:PLUGIN_FILE2}),instance.wait_for_visible_lite(()=>{let canvas=instance.get_canvas();property_applications2.patch_user_agent_styles(canvas),$(document).ready(()=>{instance.autorun(()=>{canvas.empty();let icon=element_eval2.evaluate_property(instance,"icon"),icon_name=icon;icon?.includes(".outline")?(icon_name=icon.replace(".outline",""),canvas.append(icons.get_svg_canvas("material-icons-outline",icon_name,icons.ICON_SIZE/2,-icons.ICON_SIZE/2,"start"))):canvas.append(icons.get_svg_canvas("material-icons",icon_name,icons.ICON_SIZE/2,-icons.ICON_SIZE/2,"start")),element_eval2.evaluate_property(instance,"button_disabled")&&canvas.attr("tabindex","-1")})}),element_eval2.on_property_change(instance,"icon_color",icon_color=>canvas.css("color",icon_color))})},is_input:!1,contains_group_data:!1,events:["ButtonClicked","ElementPressed"],add_an_invisible_div_on_the_top:!1,css_files:["css/optional/material-icons.css"]}}}keys(){return plugin_version()>=1?{}:{css_responsive:{caption:"Use new responsive properties for this plugin's elements",type:"client_safe",editor:"Checkbox"}}}},materialicons={cls};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.materialicons=materialicons);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("materialicons",materialicons);})(); 127/*! Bundled license information: 128 129buffer/index.js: 130 (*! 131 * The buffer module from node.js, for the browser. 132 * 133 * @author Feross Aboukhadijeh <https://feross.org> 134 * @license MIT 135 *) 136*/ 137 138} 139 140 141window.preloaded['plugin/first_party:materialicons'] = true; 142window._bubble_page_load_data.hardcoded_plugins['apple'] = true; 143window.__code__ = window.__code__ || {}; 144if(!window.__code__['ddc8ef3b5f9f97173a25ed9bbab113a122f1d51f220e9b6eeba43c320f7c1b33']){window.__code__['ddc8ef3b5f9f97173a25ed9bbab113a122f1d51f220e9b6eeba43c320f7c1b33']=1; 145 146"use strict";(()=>{var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __esm=(fn,res)=>function(){return fn&&(res=(0,fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exp
vendor: 5,823 bytes, line 146
146orts:{}}).exports,mod),mod.exports};var __copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod));var init_define_process_env=__esm({"<define:process.env>"(){}});var require_base64_js=__commonJS({"node_modules/base64-js/index.js"(exports){"use strict";init_define_process_env();init_shim();exports.byteLength=byteLength;exports.toByteArray=toByteArray;exports.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;var i,len;revLookup["-".charCodeAt(0)]=62;revLookup["_".charCodeAt(0)]=63;function getLens(b64){var len2=b64.length;if(len2%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var validLen=b64.indexOf("=");validLen===-1&&(validLen=len2);var placeHoldersLen=validLen===len2?0:4-validLen%4;return[validLen,placeHoldersLen]}function byteLength(b64){var lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1];return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function _byteLength(b64,validLen,placeHoldersLen){return(validLen+placeHoldersLen)*3/4-placeHoldersLen}function toByteArray(b64){var tmp,lens=getLens(b64),validLen=lens[0],placeHoldersLen=lens[1],arr=new Arr(_byteLength(b64,validLen,placeHoldersLen)),curByte=0,len2=placeHoldersLen>0?validLen-4:validLen,i2;for(i2=0;i2<len2;i2+=4)tmp=revLookup[b64.charCodeAt(i2)]<<18|revLookup[b64.charCodeAt(i2+1)]<<12|revLookup[b64.charCodeAt(i2+2)]<<6|revLookup[b64.charCodeAt(i2+3)],arr[curByte++]=tmp>>16&255,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255;return placeHoldersLen===2&&(tmp=revLookup[b64.charCodeAt(i2)]<<2|revLookup[b64.charCodeAt(i2+1)]>>4,arr[curByte++]=tmp&255),placeHoldersLen===1&&(tmp=revLookup[b64.charCodeAt(i2)]<<10|revLookup[b64.charCodeAt(i2+1)]<<4|revLookup[b64.charCodeAt(i2+2)]>>2,arr[curByte++]=tmp>>8&255,arr[curByte++]=tmp&255),arr}function tripletToBase64(num){return lookup[num>>18&63]+lookup[num>>12&63]+lookup[num>>6&63]+lookup[num&63]}function encodeChunk(uint8,start,end){for(var tmp,output=[],i2=start;i2<end;i2+=3)tmp=(uint8[i2]<<16&16711680)+(uint8[i2+1]<<8&65280)+(uint8[i2+2]&255),output.push(tripletToBase64(tmp));return output.join("")}function fromByteArray(uint8){for(var tmp,len2=uint8.length,extraBytes=len2%3,parts=[],maxChunkLength=16383,i2=0,len22=len2-extraBytes;i2<len22;i2+=maxChunkLength)parts.push(encodeChunk(uint8,i2,i2+maxChunkLength>len22?len22:i2+maxChunkLength));return extraBytes===1?(tmp=uint8[len2-1],parts.push(lookup[tmp>>2]+lookup[tmp<<4&63]+"==")):extraBytes===2&&(tmp=(uint8[len2-2]<<8)+uint8[len2-1],parts.push(lookup[tmp>>10]+lookup[tmp>>4&63]+lookup[tmp<<2&63]+"=")),parts.join("")}}});var require_ieee754=__commonJS({"node_modules/ieee754/index.js"(exports){init_define_process_env();init_shim();exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];for(i+=d,e=s&(1<<-nBits)-1,s>>=-nBits,nBits+=eLen;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);for(m=e&(1<<-nBits)-1,e>>=-nBits,nBits+=mLen;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0)e=1-eBias;else{if(e===eMax)return m?NaN:(s?-1:1)*(1/0);m=m+Math.pow(2,mLen),e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;for(value=Math.abs(value),isNaN(value)||value===1/0?(m=isNaN(value)?1:0,e=eMax):(e=Math.floor(Math.log(value)/Math.LN2),value*(c=Math.pow(2,-e))<1&&(e--,c*=2),e+eBias>=1?value+=rt/c:value+=rt*Math.pow(2,1-eBias),value*c>=2&&(e++,c/=2),e+eBias>=eMax?(m=0,e=eMax):e+eBias>=1?(m=(value*c-1)*Math.pow(2,mLen),e=e+eBias):(m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen),e=0));mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);for(e=e<<mLen|m,eLen+=mLen;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}}});var require_buffer=__commonJS({"node_modules/node-stdlib-browser/node_modules/buffer/index.js"(exports){"use strict";init_define_process_env();init_shim();var base64=require_base64_js(),ieee754=require_ieee754(),customInspectSymbol=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;exports.Buffer=Buffer3;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;var K_MAX_LENGTH=2147483647;exports.kMaxLength=K_MAX_LENGTH;Buffer3.TYPED_ARRAY_SUPPORT=typedArraySupport();!Buffer3.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function typedArraySupport(){try{var arr=new Uint8Array(1),proto={foo:function(){return 42}};return Object.setPrototypeOf(proto,Uint8Array.prototype),Object.setPrototypeOf(arr,proto),arr.foo()===42}catch{return!1}}Object.defineProperty(Buffer3.prototype,"parent",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.buffer}});Object.defineProperty(Buffer3.prototype,"offset",{enumerable:!0,get:function(){if(Buffer3.isBuffer(this))return this.byteOffset}});function createBuffer(length){if(length>
vendor: 23,595 bytes, line 146
146K_MAX_LENGTH)throw new RangeError('The value "'+length+'" is invalid for option "size"');var buf=new Uint8Array(length);return Object.setPrototypeOf(buf,Buffer3.prototype),buf}function Buffer3(arg,encodingOrOffset,length){if(typeof arg=="number"){if(typeof encodingOrOffset=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(arg)}return from(arg,encodingOrOffset,length)}Buffer3.poolSize=8192;function from(value,encodingOrOffset,length){if(typeof value=="string")return fromString(value,encodingOrOffset);if(ArrayBuffer.isView(value))return fromArrayView(value);if(value==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value);if(isInstance(value,ArrayBuffer)||value&&isInstance(value.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(isInstance(value,SharedArrayBuffer)||value&&isInstance(value.buffer,SharedArrayBuffer)))return fromArrayBuffer(value,encodingOrOffset,length);if(typeof value=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var valueOf=value.valueOf&&value.valueOf();if(valueOf!=null&&valueOf!==value)return Buffer3.from(valueOf,encodingOrOffset,length);var b=fromObject(value);if(b)return b;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof value[Symbol.toPrimitive]=="function")return Buffer3.from(value[Symbol.toPrimitive]("string"),encodingOrOffset,length);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof value)}Buffer3.from=function(value,encodingOrOffset,length){return from(value,encodingOrOffset,length)};Object.setPrototypeOf(Buffer3.prototype,Uint8Array.prototype);Object.setPrototypeOf(Buffer3,Uint8Array);function assertSize(size){if(typeof size!="number")throw new TypeError('"size" argument must be of type number');if(size<0)throw new RangeError('The value "'+size+'" is invalid for option "size"')}function alloc(size,fill,encoding){return assertSize(size),size<=0?createBuffer(size):fill!==void 0?typeof encoding=="string"?createBuffer(size).fill(fill,encoding):createBuffer(size).fill(fill):createBuffer(size)}Buffer3.alloc=function(size,fill,encoding){return alloc(size,fill,encoding)};function allocUnsafe(size){return assertSize(size),createBuffer(size<0?0:checked(size)|0)}Buffer3.allocUnsafe=function(size){return allocUnsafe(size)};Buffer3.allocUnsafeSlow=function(size){return allocUnsafe(size)};function fromString(string,encoding){if((typeof encoding!="string"||encoding==="")&&(encoding="utf8"),!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);var length=byteLength(string,encoding)|0,buf=createBuffer(length),actual=buf.write(string,encoding);return actual!==length&&(buf=buf.slice(0,actual)),buf}function fromArrayLike(array){for(var length=array.length<0?0:checked(array.length)|0,buf=createBuffer(length),i=0;i<length;i+=1)buf[i]=array[i]&255;return buf}function fromArrayView(arrayView){if(isInstance(arrayView,Uint8Array)){var copy=new Uint8Array(arrayView);return fromArrayBuffer(copy.buffer,copy.byteOffset,copy.byteLength)}return fromArrayLike(arrayView)}function fromArrayBuffer(array,byteOffset,length){if(byteOffset<0||array.byteLength<byteOffset)throw new RangeError('"offset" is outside of buffer bounds');if(array.byteLength<byteOffset+(length||0))throw new RangeError('"length" is outside of buffer bounds');var buf;return byteOffset===void 0&&length===void 0?buf=new Uint8Array(array):length===void 0?buf=new Uint8Array(array,byteOffset):buf=new Uint8Array(array,byteOffset,length),Object.setPrototypeOf(buf,Buffer3.prototype),buf}function fromObject(obj){if(Buffer3.isBuffer(obj)){var len=checked(obj.length)|0,buf=createBuffer(len);return buf.length===0||obj.copy(buf,0,0,len),buf}if(obj.length!==void 0)return typeof obj.length!="number"||numberIsNaN(obj.length)?createBuffer(0):fromArrayLike(obj);if(obj.type==="Buffer"&&Array.isArray(obj.data))return fromArrayLike(obj.data)}function checked(length){if(length>=K_MAX_LENGTH)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K_MAX_LENGTH.toString(16)+" bytes");return length|0}function SlowBuffer(length){return+length!=length&&(length=0),Buffer3.alloc(+length)}Buffer3.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==Buffer3.prototype};Buffer3.compare=function(a,b){if(isInstance(a,Uint8Array)&&(a=Buffer3.from(a,a.offset,a.byteLength)),isInstance(b,Uint8Array)&&(b=Buffer3.from(b,b.offset,b.byteLength)),!Buffer3.isBuffer(a)||!Buffer3.isBuffer(b))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(a===b)return 0;for(var x=a.length,y=b.length,i=0,len=Math.min(x,y);i<len;++i)if(a[i]!==b[i]){x=a[i],y=b[i];break}return x<y?-1:y<x?1:0};Buffer3.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};Buffer3.concat=function(list,length){if(!Array.isArray(list))throw new TypeError('"list" argument must be an Array of Buffers');if(list.length===0)return Buffer3.alloc(0);var i;if(length===void 0)for(length=0,i=0;i<list.length;++i)length+=list[i].length;var buffer=Buffer3.allocUnsafe(length),pos=0;for(i=0;i<list.length;++i){var buf=list[i];if(isInstance(buf,Uint8Array))pos+buf.length>buffer.length?Buffer3.from(buf).copy(buffer,pos):Uint8Array.prototype.set.call(buffer,buf,pos);else if(Buffer3.isBuffer(buf))buf.copy(buffer,pos);else throw new TypeError('"list" argument must be an Array of Buffers');pos+=buf.length}return buffer};function byteLength(string,encoding){if(Buffer3.isBuffer(string))return string.length;if(ArrayBuffer.isView(string)||isInstance(string,ArrayBuffer))return string.byteLength;if(typeof string!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof string);var len=string.length,mustMatch=arguments.length>2&&arguments[2]===!0;if(!mustMatch&&len===0)return 0;for(var loweredCase=!1;;)switch(encoding){case"ascii":case"latin1":case"binary":return len;case"utf8":case"utf-8":return utf8ToBytes(string).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return len*2;case"hex":return len>>>1;case"base64":return base64ToBytes(string).length;default:if(loweredCase)return mustMatch?-1:utf8ToBytes(string).length;encoding=(""+encoding).toLowerCase(),loweredCase=!0}}Buffer3.byteLength=byteLength;function slowToString(encoding,start,end){var loweredCase=!1;if((start===void 0||start<0)&&(start=0),start>this.length||((end===void 0||end>this.length)&&(end=this.length),end<=0)||(end>>>=0,start>>>=0,end<=start))return"";for(encoding||(encoding="utf8");;)switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"latin1":case"binary":return latin1Slice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase(),loweredCase=!0}}Buffer3.prototype._isBuffer=!0;function swap(b,n,m){var i=b[n];b[n]=b[m],b[m]=i}Buffer3.prototype.swap16=function(){var len=this.length;if(len%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var i=0;i<len;i+=2)swap(this,i,i+1);return this};Buffer3.prototype.swap32=function(){var len=this.length;if(len%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var i=0;i<len;i+=4)swap(this,i,i+3),swap(this,i+1,i+2);return this};Buffer3.prototype.swap64=function(){var len=this.length;if(len%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var i=0;i<len;i+=8)swap(this,i,i+7),swap(this,i+1,i+6),swap(this,i+2,i+5),swap(this,i+3,i+4);return this};Buffer3.prototype.toString=function(){var length=this.length;return length===0?"":arguments.length===0?utf8Slice(this,0,length):slowToString.apply(this,arguments)};Buffer3.prototype.toLocaleString=Buffer3.prototype.toString;Buffer3.prototype.equals=function(b){if(!Buffer3.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b?!0:Buffer3.compare(this,b)===0};Buffer3.prototype.inspect=function(){var str="",max=exports.INSPECT_MAX_BYTES;return str=this.toString("hex",0,max).replace(/(.{2})/g,"$1 ").trim(),this.length>max&&(str+=" ... "),"<Buffer "+str+">"};customInspectSymbol&&(Buffer3.prototype[customInspectSymbol]=Buffer3.prototype.inspect);Buffer3.prototype.compare=function(target,start,end,thisStart,thisEnd){if(isInstance(target,Uint8Array)&&(target=Buffer3.from(target,target.offset,target.byteLength)),!Buffer3.isBuffer(target))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof target);if(start===void 0&&(start=0),end===void 0&&(end=target?target.length:0),thisStart===void 0&&(thisStart=0),thisEnd===void 0&&(thisEnd=this.length),start<0||end>target.length||thisStart<0||thisEnd>this.length)throw new RangeError("out of range index");if(thisStart>=thisEnd&&start>=end)return 0;if(thisStart>=thisEnd)return-1;if(start>=end)return 1;if(start>>>=0,end>>>=0,thisStart>>>=0,thisEnd>>>=0,this===target)return 0;for(var x=thisEnd-thisStart,y=end-start,len=Math.min(x,y),thisCopy=this.slice(thisStart,thisEnd),targetCopy=target.slice(start,end),i=0;i<len;++i)if(thisCopy[i]!==targetCopy[i]){x=thisCopy[i],y=targetCopy[i];break}return x<y?-1:y<x?1:0};function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){if(buffer.length===0)return-1;if(typeof byteOffset=="string"?(encoding=byteOffset,byteOffset=0):byteOffset>2147483647?byteOffset=2147483647:byteOffset<-2147483648&&(byteOffset=-2147483648),byteOffset=+byteOffset,numberIsNaN(byteOffset)&&(byteOffset=dir?0:buffer.length-1),byteOffset<0&&(byteOffset=buffer.length+byteOffset),byteOffset>=buffer.length){if(dir)return-1;byteOffset=buffer.length-1}else if(byteOffset<0)if(dir)byteOffset=0;else return-1;if(typeof val=="string"&&(val=Buffer3.from(val,encoding)),Buffer3.isBuffer(val))return val.length===0?-1:arrayIndexOf(buffer,val,byteOffset,encoding,dir);if(typeof val=="number")return val=val&255,typeof Uint8Array.prototype.indexOf=="function"?dir?Uint8Array.prototype.indexOf.call(buffer,val,byteOffset):Uint8Array.prototype.lastIndexOf.call(buffer,val,byteOffset):arrayIndexOf(buffer,[val],byteOffset,encoding,dir);throw new TypeError("val must be string, number or Buffer")}function arrayIndexOf(arr,val,byteOffset,encoding,dir){var indexSize=1,arrLength=arr.length,valLength=val.length;if(encoding!==void 0&&(encoding=String(encoding).toLowerCase(),encoding==="ucs2"||encoding==="ucs-2"||encoding==="utf16le"||encoding==="utf-16le")){if(arr.length<2||val.length<2)return-1;indexSize=2,arrLength/=2,valLength/=2,byteOffset/=2}function read(buf,i2){return indexSize===1?buf[i2]:buf.readUInt16BE(i2*indexSize)}var i;if(dir){var foundIndex=-1;for(i=byteOffset;i<arrLength;i++)if(read(arr,i)===read(val,foundIndex===-1?0:i-foundIndex)){if(foundIndex===-1&&(foundIndex=i),i-foundIndex+1===valLength)return foundIndex*indexSize}else foundIndex!==-1&&(i-=i-foundIndex),foundIndex=-1}else for(byteOffset+valLength>arrLength&&(byteOffset=arrLength-valLength),i=byteOffset;i>=0;i--){for(var found=!0,j=0;j<valLength;j++)if(read(arr,i+j)!==read(val,j)){found=!1;break}if(found)return i}return-1}Buffer3.prototype.includes=function(val,byteOffset,encoding){return this.indexOf(val,byteOffset,encoding)!==-1};Buffer3.prototype.indexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!0)};Buffer3.prototype.lastIndexOf=function(val,byteOffset,encoding){return bidirectionalIndexOf(this,val,byteOffset,encoding,!1)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;length?(length=Number(length),length>remaining&&(length=remaining)):length=remaining;var strLen=string.length;length>strLen/2&&(length=strLen/2);for(var i=0;i<length;++i){var parsed=parseInt(string.substr(i*2,2),16);if(numberIsNaN(parsed))return i;buf[offset+i]=parsed}return i}function utf8Write(buf,string,offset,length){return blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length)}function asciiWrite(buf,string,offset,length){return blitBuffer(asciiToBytes(string),buf,offset,length)}function base64Write(buf,string,offset,length){return blitBuffer(base64ToBytes(string),buf,offset,length)}function ucs2Write(buf,string,offset,length){return blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length)}Buffer3.prototype.write=function(string,offset,length,encoding){if(offset===void 0)encoding="utf8",length=this.length,offset=0;else if(length===void 0&&typeof offset=="string")encoding=offset,length=this.length,offset=0;else if(isFinite(offset))offset=offset>>>0,isFinite(length)?(length=length>>>0,encoding===void 0&&(encoding="utf8")):(encoding=length,length=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var remaining=this.length-offset;if((length===void 0||length>remaining)&&(length=remaining),string.length>0&&(length<0||offset<0)||offset>this.length)throw new RangeError("Attempt to write outside buffer bounds");encoding||(encoding="utf8");for(var loweredCase=!1;;)switch(encoding){case"hex":return hexWrite(this,string,offset,length);case"utf8":case"utf-8":return utf8Write(this,string,offset,length);case"ascii":case"latin1":case"binary":return asciiWrite(this,string,offset,length);case"base64":return base64Write(this,string,offset,length);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,string,offset,length);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(""+encoding).toLowerCase(),loweredCase=!0}};Buffer3.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){return start===0&&end===buf.length?base64.fromByteArray(buf):base64.fromByteArray(buf.slice(start,end))}function utf8Slice(buf,start,end){end=Math.min(buf.length,end);for(var res=[],i=start;i<end;){var firstByte=buf[i],codePoint=null,bytesPerSequence=firstByte>239?4:firstByte>223?3:firstByte>191?2:1;if(i+bytesPerSequence<=end){var secondByte,thirdByte,fourthByte,tempCodePoint;switch(bytesPerSequence){case 1:firstByte<128&&(codePoint=firstByte);break;case 2:secondByte=buf[i+1],(secondByte&192)===128&&(tempCodePoint=(firstByte&31)<<6|secondByte&63,tempCodePoint>127&&(codePoint=tempCodePoint));break;case 3:secondByte=buf[i+1],thirdByte=buf[i+2],(secondByte&192)===128&&(thirdByte&192)===128&&(tempCodePoint=(firstByte&15)<<12|(secondByte&63)<<6|thirdByte&63,tempCodePoint>2047&&(tempCodePoint<55296||tempCodePoint>57343)&&(codePoint=tempCodePoint));break;case 4:secondByte=buf[i+1],thirdByte=buf[i+2],fourthByte=buf[i+3],(secondByte&192)===128&&(thirdByte&192)===128&&(fourthByte&192)===128&&(tempCodePoint=(firstByte&15)<<18|(secondByte&63)<<12|(thirdByte&63)<<6|fourthByte&63,tempCodePoint>65535&&tempCodePoint<1114112&&(codePoint=tempCodePoint))}}codePoint===null?(codePoint=65533,bytesPerSequence=1):codePoint>65535&&(codePoint-=65536,res.push(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),res.push(codePoint),i+=bytesPerSequence}return decodeCodePointsArray(res)}var MAX_ARGUMENTS_LENGTH=4096;function decodeCodePointsArray(codePoints){var len=codePoints.length;if(len<=MAX_ARGUMENTS_LENGTH)return String.fromCharCode.apply(String,codePoints);for(var res="",i=0;i<len;)res+=String.fromCharCode.apply(String,codePoints.slice(i,i+=MAX_ARGUMENTS_LENGTH));return res}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]&127);return ret}function latin1Slice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;++i)ret+=String.fromCharCode(buf[i]);return ret}function hexSlice(buf,start,end){var len=buf.length;(!start||start<0)&&(start=0),(!end||end<0||end>len)&&(end=len);for(var out="",i=start;i<end;++i)out+=hexSliceLookupTable[buf[i]];return out}function utf16leSlice(buf,start,end){for(var bytes=buf.slice(start,end),res="",i=0;i<bytes.length-1;i+=2)res+=String.fromCharCode(bytes[i]+bytes[i+1]*256);return res}Buffer3.prototype.slice=function(start,end){var len=this.length;start=~~start,end=end===void 0?len:~~end,start<0?(start+=len,start<0&&(start=0)):start>len&&(start=len),end<0?(end+=len,end<0&&(end=0)):end>len&&(end=len),end<start&&(end=start);var newBuf=this.subarray(start,end);return Object.setPrototypeOf(newBuf,Buffer3.prototype),newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer3.prototype.readUintLE=Buffer3.prototype.readUIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return val};Buffer3.prototype.readUintBE=Buffer3.prototype.readUIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset+--byteLength2],mul=1;byteLength2>0&&(mul*=256);)val+=this[offset+--byteLength2]*mul;return val};Buffer3.prototype.readUint8=Buffer3.prototype.readUInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]};Buffer3.prototype.readUint16LE=Buffer3.prototype.readUInt16LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]|this[offset+1]<<8};Buffer3.prototype.readUint16BE=Buffer3.prototype.readUInt16BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,2,this.length),this[offset]<<8|this[offset+1]};Buffer3.prototype.readUint32LE=Buffer3.prototype.readUInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer3.prototype.readUint32BE=Buffer3.prototype.readUInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer3.prototype.readIntLE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var val=this[offset],mul=1,i=0;++i<byteLength2&&(mul*=256);)val+=this[offset+i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readIntBE=function(offset,byteLength2,noAssert){offset=offset>>>0,byteLength2=byteLength2>>>0,noAssert||checkOffset(offset,byteLength2,this.length);for(var i=byteLength2,mul=1,val=this[offset+--i];i>0&&(mul*=256);)val+=this[offset+--i]*mul;return mul*=128,val>=mul&&(val-=Math.pow(2,8*byteLength2)),val};Buffer3.prototype.readInt8=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,1,this.length),this[offset]&128?(255-this[offset]+1)*-1:this[offset]};Buffer3.prototype.readInt16LE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt16BE=function(offset,noAssert){offset=offset>>>0,noAssert||checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer3.prototype.readInt32LE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer3.prototype.readInt32BE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer3.prototype.readFloatLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!0,23,4)};Buffer3.prototype.readFloatBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,4,this.length),ieee754.read(this,offset,!1,23,4)};Buffer3.prototype.readDoubleLE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!0,52,8)};Buffer3.prototype.readDoubleBE=function(offset,noAssert){return offset=offset>>>0,noAssert||checkOffset(offset,8,this.length),ieee754.read(this,offset,!1,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer3.isBuffer(buf))throw new TypeError('"buffer" argument must be a Buffer instance');if(value>max||value<min)throw new RangeError('"value" argument is out of bounds');if(offset+ext>buf.length)throw new RangeError("Index out of range")}Buffer3.prototype.writeUintLE=Buffer3.prototype.writeUIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var mul=1,i=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUintBE=Buffer3.prototype.writeUIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,byteLength2=byteLength2>>>0,!noAssert){var maxBytes=Math.pow(2,8*byteLength2)-1;checkInt(this,value,offset,byteLength2,maxBytes,0)}var i=byteLength2-1,mul=1;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)this[offset+i]=value/mul&255;return offset+byteLength2};Buffer3.prototype.writeUint8=Buffer3.prototype.writeUInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,255,0),this[offset]=value&255,offset+1};Buffer3.prototype.writeUint16LE=Buffer3.prototype.writeUInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeUint16BE=Buffer3.prototype.writeUInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,65535,0),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeUint32LE=Buffer3.prototype.writeUInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset+3]=value>>>24,this[offset+2]=value>>>16,this[offset+1]=value>>>8,this[offset]=value&255,offset+4};Buffer3.prototype.writeUint32BE=Buffer3.prototype.writeUInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,4294967295,0),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};Buffer3.prototype.writeIntLE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=0,mul=1,sub=0;for(this[offset]=value&255;++i<byteLength2&&(mul*=256);
vendor: 3,223 bytes, line 146
146)value<0&&sub===0&&this[offset+i-1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeIntBE=function(value,offset,byteLength2,noAssert){if(value=+value,offset=offset>>>0,!noAssert){var limit=Math.pow(2,8*byteLength2-1);checkInt(this,value,offset,byteLength2,limit-1,-limit)}var i=byteLength2-1,mul=1,sub=0;for(this[offset+i]=value&255;--i>=0&&(mul*=256);)value<0&&sub===0&&this[offset+i+1]!==0&&(sub=1),this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength2};Buffer3.prototype.writeInt8=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,1,127,-128),value<0&&(value=255+value+1),this[offset]=value&255,offset+1};Buffer3.prototype.writeInt16LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value&255,this[offset+1]=value>>>8,offset+2};Buffer3.prototype.writeInt16BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,2,32767,-32768),this[offset]=value>>>8,this[offset+1]=value&255,offset+2};Buffer3.prototype.writeInt32LE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),this[offset]=value&255,this[offset+1]=value>>>8,this[offset+2]=value>>>16,this[offset+3]=value>>>24,offset+4};Buffer3.prototype.writeInt32BE=function(value,offset,noAssert){return value=+value,offset=offset>>>0,noAssert||checkInt(this,value,offset,4,2147483647,-2147483648),value<0&&(value=4294967295+value+1),this[offset]=value>>>24,this[offset+1]=value>>>16,this[offset+2]=value>>>8,this[offset+3]=value&255,offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(offset+ext>buf.length)throw new RangeError("Index out of range");if(offset<0)throw new RangeError("Index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,4,34028234663852886e22,-34028234663852886e22),ieee754.write(buf,value,offset,littleEndian,23,4),offset+4}Buffer3.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,!0,noAssert)};Buffer3.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,!1,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){return value=+value,offset=offset>>>0,noAssert||checkIEEE754(buf,value,offset,8,17976931348623157e292,-17976931348623157e292),ieee754.write(buf,value,offset,littleEndian,52,8),offset+8}Buffer3.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,!0,noAssert)};Buffer3.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,!1,noAssert)};Buffer3.prototype.copy=function(target,targetStart,start,end){if(!Buffer3.isBuffer(target))throw new TypeError("argument should be a Buffer");if(start||(start=0),!end&&end!==0&&(end=this.length),targetStart>=target.length&&(targetStart=target.length),targetStart||(targetStart=0),end>0&&end<start&&(end=start),end===start||target.length===0||this.length===0)return 0;
vendor: 5,180 bytes, line 146
146if(targetStart<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=this.length)throw new RangeError("Index out of range");if(end<0)throw new RangeError("sourceEnd out of bounds");end>this.length&&(end=this.length),target.length-targetStart<end-start&&(end=target.length-targetStart+start);var len=end-start;return this===target&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(targetStart,start,end):Uint8Array.prototype.set.call(target,this.subarray(start,end),targetStart),len};Buffer3.prototype.fill=function(val,start,end,encoding){if(typeof val=="string"){if(typeof start=="string"?(encoding=start,start=0,end=this.length):typeof end=="string"&&(encoding=end,end=this.length),encoding!==void 0&&typeof encoding!="string")throw new TypeError("encoding must be a string");if(typeof encoding=="string"&&!Buffer3.isEncoding(encoding))throw new TypeError("Unknown encoding: "+encoding);if(val.length===1){var code=val.charCodeAt(0);(encoding==="utf8"&&code<128||encoding==="latin1")&&(val=code)}}else typeof val=="number"?val=val&255:typeof val=="boolean"&&(val=Number(val));if(start<0||this.length<start||this.length<end)throw new RangeError("Out of range index");if(end<=start)return this;start=start>>>0,end=end===void 0?this.length:end>>>0,val||(val=0);var i;if(typeof val=="number")for(i=start;i<end;++i)this[i]=val;else{var bytes=Buffer3.isBuffer(val)?val:Buffer3.from(val,encoding),len=bytes.length;if(len===0)throw new TypeError('The value "'+val+'" is invalid for argument "value"');for(i=0;i<end-start;++i)this[i+start]=bytes[i%len]}return this};var INVALID_BASE64_RE=/[^+/0-9A-Za-z-_]/g;function base64clean(str){if(str=str.split("=")[0],str=str.trim().replace(INVALID_BASE64_RE,""),str.length<2)return"";for(;str.length%4!==0;)str=str+"=";return str}function utf8ToBytes(string,units){units=units||1/0;for(var codePoint,length=string.length,leadSurrogate=null,bytes=[],i=0;i<length;++i){if(codePoint=string.charCodeAt(i),codePoint>55295&&codePoint<57344){if(!leadSurrogate){if(codePoint>56319){(units-=3)>-1&&bytes.push(239,191,189);continue}else if(i+1===length){(units-=3)>-1&&bytes.push(239,191,189);continue}leadSurrogate=codePoint;continue}if(codePoint<56320){(units-=3)>-1&&bytes.push(239,191,189),leadSurrogate=codePoint;continue}codePoint=(leadSurrogate-55296<<10|codePoint-56320)+65536}else leadSurrogate&&(units-=3)>-1&&bytes.push(239,191,189);if(leadSurrogate=null,codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<1114112){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else throw new Error("Invalid code point")}return bytes}function asciiToBytes(str){for(var byteArray=[],i=0;i<str.length;++i)byteArray.push(str.charCodeAt(i)&255);return byteArray}function utf16leToBytes(str,units){for(var c,hi,lo,byteArray=[],i=0;i<str.length&&!((units-=2)<0);++i)c=str.charCodeAt(i),hi=c>>8,lo=c%256,byteArray.push(lo),byteArray.push(hi);return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length&&!(i+offset>=dst.length||i>=src.length);++i)dst[i+offset]=src[i];return i}function isInstance(obj,type){return obj instanceof type||obj!=null&&obj.constructor!=null&&obj.constructor.name!=null&&obj.constructor.name===type.name}function numberIsNaN(obj){return obj!==obj}var hexSliceLookupTable=function(){for(var alphabet="0123456789abcdef",table=new Array(256),i=0;i<16;++i)for(var i16=i*16,j=0;j<16;++j)table[i16+j]=alphabet[i]+alphabet[j];return table}()}});var require_browser=__commonJS({"node_modules/process/browser.js"(exports,module){init_define_process_env();init_shim();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}
146var queue=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)args[i-1]=arguments[i];queue.push(new Item(fun,args)),queue.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var import_buffer,import_process,_globalThis,init_shim=__esm({"node_modules/node-stdlib-browser/helpers/esbuild/shim.js"(){import_buffer=__toESM(require_buffer()),import_process=__toESM(require_browser()),_globalThis=function(Object2){function get(){var _global3=this||self;return delete Object2.prototype.__magic__,_global3}if(typeof globalThis=="object")return globalThis;if(this)return get();Object2.defineProperty(Object2.prototype,"__magic__",{configurable:!0,get});var _global2=__magic__;return _global2}(Object)}});init_define_process_env();init_shim();init_define_process_env();init_shim();var u=window?.u??_u,base_safe_require=window?.safe_require??_safe_require,legacy_keys={"@bubblegroup/db":["./db/runtime/db","./db/db"],"@bubblegroup/db/hydrate":["./db/runtime/hydrate","./db/hydrate"],"@bubblegroup/db/values/db_values":["./db/runtime/values/db_values","./db/values/db_values"],"@bubblegroup/db/values/StaticObject":["./db/runtime/values/StaticObject","./db/values/StaticObject"],"@bubblegroup/evaluation/engine/context":["@bubblegroup/evaluation/context","./lang/evaluation/context"],"@bubblegroup/evaluation/engine/eval_node_state":["@bubblegroup/evaluation/eval_node_state","./lang/evaluation/eval_node_state"],"@bubblegroup/evaluation/engine/node_eval":["@bubblegroup/evaluation/node_eval","./lang/evaluation/node_eval"],"@bubblegroup/evaluation/engine/page_state":["@bubblegroup/evaluation/page_state","./lang/evaluation/page_state"],"@bubblegroup/evaluation/engine/state_keys":["@bubblegroup/evaluation/state_keys","./lang/evaluation/state_keys"]};function safe_require_with_legacy_keys(path){try{return base_safe_require.safe_require(path)}catch(err){for(let legacy_key of legacy_keys[path]??[])try{return base_safe_require.safe_require(legacy_key)}catch{}throw err}}var safe_require={safe_require:safe_require_with_legacy_keys,safe_register:base_safe_require.safe_register};var external=safe_require.safe_require("./external"),appquery=safe_require.safe_require("./lang/appquery"),AUTH_URL="https://appleid.apple.com/auth/authorize",AppleAuthenticator=class extends external.Oauth2{native_login(native_bridge,authentication_url,api_data,options){return typeof native_bridge?.appleNativeLogin!="function"?Promise.resolve(null):native_bridge.appleNativeLogin(authentication_url,api_data,options)}get_oauth_user_data(login_data){}get_public_key(){return appquery.get_private_setting("mobile.apple.service_id")}get_secret_key(){return null}use_server_side_redirect(){return!0}get_data_for_login(data){let login_data=super.get_data_for_login(data);return data?.user!=null&&(login_data.user=data.user),login_data}
146is_still_valid(){return!0}generate_validity_object(){return{}}},cls=class extends external.Service{constructor(){super(),this.authenticator=new AppleAuthenticator({scope:"name email",response_mode:"form_post",authentication_url:AUTH_URL})}get oauth_providers(){return["apple"]}display(){return"Apple"}},apple={cls};typeof window<"u"&&window!==null&&(window.optional_modules??={},window.optional_modules.apple=apple);var plugin_registry=safe_require.safe_require("./services/shared/plugin_registry");plugin_registry.register_plugin("apple",apple);})(); 147/*! Bundled license information: 148 149buffer/index.js: 150 (*! 151 * The buffer module from node.js, for the browser. 152 * 153 * @author Feross Aboukhadijeh <https://feross.org> 154 * @license MIT 155 *) 156*/ 157 158} 159 160 161window.preloaded['plugin/first_party:apple'] = true; 162window.plugins = window.plugins || {}; 163window._bubble_page_load_data.plugins_size = window._bubble_page_load_data.plugins_size || {}; 164window.plugins["1488796042609x768734193128308700"] = {"human":"Toolbox","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"List of Numbers","property_applications":{"resizable":true},"add_is_visible":true,"fields":{"AAE":{"caption":"Start number","name":"number_start","editor":"DynamicValue","value":"number","rank":2},"AAF":{"caption":"Length of list","name":"list_length","editor":"DynamicValue","value":"number","is_list":false,"rank":3},"AAG":{"caption":"Increment","name":"increment","editor":"DynamicValue","value":"number","rank":4},"ABS":{"caption":"List of Numbers.","name":"doctitle","rank":0,"editor":"Label"},"ABT":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"}},"states":{"AAD":{"caption":"list","name":"list","value":"number","is_list":true,"initialization_code":{"fn":"function(properties,context){}"}}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){properties.number_start,properties.list_length,properties.increment;var result=[];if(null!==properties.number_start&&null!==properties.list_length&&null!==properties.increment)for(var mynumber=properties.number_start,i=0;i<properties.list_length;i++)result.push(mynumber),mynumber+=properties.increment;instance.publishState(\"list\",result)}"},"preview":{"fn":"function(instance, properties) {\n var div = document.createElement(\"div\");\n div.style.overflow = \"hidden\";\n div.style.width = \"100%\";\n div.style.height = \"100%\";\n div.style[\"font-style\"] = \"italic\";\n div.style[\"text-wrap\"] = \"nowrap\";\n div.style[\"font-size\"] = \"\" + Math.floor(properties.bubble.height() * 0.75) + \"px\";\n div.textContent = \"1 2 3 ...\";\n instance.canvas.append(div);\n}"}},"platform_type":"web"},"AAI":{"display":"Expression","property_applications":{"resizable":true},"add_is_visible":true,"fields":{"AAJ":{"caption":"Expression","name":"expression","editor":"DynamicValue","value":"text","rank":2,"optional":true},"AAL":{"caption":"Result type","name":"result_type","editor":"custom_type","rank":3},"AAM":{"caption":"Result is a list","name":"result_is_list","editor":"Checkbox","default_val":false,"rank":4},"ABU":{"caption":"Expression. Evaluates with javascript.","name":"doctitle","rank":0,"editor":"Label"},"ABV":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"}},"states":{"AAN":{"caption":"value","name":"value","value":"custom_data_AAL","initialization_code":{"fn":"function(properties,context){}"}},"AAO":{"caption":"value list","name":"value_list","value":"custom_data_AAL","is_list":true,"initialization_code":{"fn":"function(properties,context){}"}}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){var result;properties.expression,properties.result_type,properties.result_is_list,result=null!=properties.expression?eval(properties.expression):null,properties.result_is_list?instance.publishState(\"value_list\",result):instance.publishState(\"value\",result)}","add_debugger":false},"preview":{"fn":"function(instance, properties) {\n var div = document.createElement(\"div\");\n div.style.overflow = \"hidden\";\n div.style.width = \"100%\";\n div.style.height = \"100%\";\n div.style[\"font-style\"] = \"italic\";\n div.style[\"text-wrap\"] = \"nowrap\";\n div.style[\"font-size\"] = \"\" + Math.floor(properties.bubble.height() * 0.75
164) + \"px\";\n div.textContent = \"Expression\";\n instance.canvas.append(div);\n}"}},"platform_type":"web"},"AAP":{"display":"Javascript to Bubble","property_applications":{"resizable":true},"add_is_visible":true,"fields":{"AAQ":{"caption":"bubble_fn_suffix","name":"fn_name_suffix","editor":"DynamicValue","value":"text","rank":2},"AAR":{"caption":"Trigger event","name":"trigger_event","editor":"Checkbox","default_val":false,"rank":3},"AAS":{"caption":"Publish value","name":"publish_value","editor":"Checkbox","default_val":false,"rank":4},"AAT":{"caption":"Value type","name":"value_type","editor":"custom_type","optional":true,"rank":8},"AAU":{"caption":"Value is a list","name":"value_is_list","editor":"Checkbox","default_val":false,"rank":9},"ABN":{"caption":"Queue","name":"queue","rank":5,"editor":"Checkbox","default_val":false},"ABW":{"caption":"Javascript to Bubble. Brings a value and event to Bubble.","name":"doctitle","rank":0,"editor":"Label"},"ABX":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"},"ABx":{"caption":"------------ Outputs -------------","name":"docoutputs","rank":6,"editor":"Label"},"ABy":{"caption":"Multiple Outputs","name":"multipleoutputs","rank":7,"editor":"Checkbox","default_val":false},"ABz":{"caption":"output1 type","name":"output1type","rank":10,"editor":"custom_type","optional":true},"ACA":{"caption":"output2 type","name":"output2type","rank":11,"editor":"custom_type","optional":true},"ACC":{"caption":"output3 type","name":"output3type","rank":12,"editor":"custom_type","optional":true},"ACD":{"caption":"output4 type","name":"output4type","rank":13,"editor":"custom_type","optional":true},"ACE":{"caption":"outputlist1 type","name":"outputlist1type","rank":14,"editor":"custom_type","optional":true},"ACF":{"caption":"outputlist2 type","name":"outputlist2type","rank":15,"editor":"custom_type","optional":true},"ACG":{"caption":"outputlist3 type","name":"outputlist3type","rank":16,"editor":"custom_type","optional":true},"ACH":{"caption":"outputlist4 type","name":"outputlist4type","rank":17,"editor":"custom_type","optional":true}},"states":{"AAV":{"caption":"value","name":"value","value":"custom_data_AAT","initialization_code":{"fn":"function(properties,context){}"}},"AAW":{"caption":"value list","name":"value_list","value":"custom_data_AAT","is_list":true,"initialization_code":{"fn":"function(properties,context){}"}},"ACI":{"caption":"output1","name":"output1","value":"custom_data_ABz","initialization_code":{"fn":"function(properties,context){}"}},"ACJ":{"caption":"output2","name":"output2","value":"custom_data_ACA","initialization_code":{"fn":"function(properties,context){}"}},"ACK":{"caption":"output3","name":"output3","value":"custom_data_ACC","initialization_code":{"fn":"function(properties,context){}"}},"ACL":{"caption":"output4","name":"output4","value":"custom_data_ACD","initialization_code":{"fn":"function(properties,context){}"}},"ACM":{"caption":"outputlist1","name":"outputlist1","value":"custom_data_ACE","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ACN":{"caption":"outputlist2","name":"outputlist2","value":"custom_data_ACF","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ACO":{"caption":"outputlist3","name":"outputlist3","value":"custom_data_ACG","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ACP":{"caption":"outputlist4","name":"outputlist4","value":"custom_data_ACH","initialization_code":{"fn":"function(properties,context){}"},"is_list":true}},"events":{"AAX":{"caption":"event","name":"event"}},"actions":{"ABL":{"caption":"Dequeue","code":{"fn":"function(instance,properties,context){instance.data.fn_dequeue()}"}},"ABM":{"caption":"ClearQueue","code":{"fn":"function(instance,properties,context){instance.data.fn_clearqueue()}"}}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){var fnNameSuffix=properties.fn_name_suffix,trigger_event=properties.trigger_event,publish_value=properties.publish_value,value_is_list=properties.value_is_list,queueActive=properties.queue,multipleoutputs=properties.multipleoutputs,fnName;(instance.data.queue=[],instance.data.fn_clearvalues=function(){publish_value&&(instance.publishState(\"value_list\",[]),instance.publishState(\"value\",null),instance.publishState(\"output1\",null),instance.publishState(\"output2\",null),instance.publishState(\"output3\",null),instance.publishState(\"output4\",null),instance.publishState(\"outputlist1\",[]),instance.publishState(\"outputlist2\",[]),instance.publishState(\"outputlist3\",[]),instance.publishState(\"outputlist4\",[]))},instance.data.fn_publish=function(value){publish_value&&(multipleoutputs?(instance.publishState(\"value\",value?.value),instance.publishState(\"value_list\",value?.value_list),instance.publishState(\"output1\",value?.output1),instance.publishState(\"output2\",value?.output2),instance.publishState(\"output3\",value?.output3),instance.publishState(\"output4\",value?.output4),instance.publishState(\"outputlist1\",value?.outputlist1),instance.publishState(\"outputlist2\",value?.outputlist2),instance.publishState(\"outputlist3\",value?.outputlist3),instance.publishState(\"outputlist4\",value?.outputlist4)):value_is_list?instance.publishState(\"value_list\",value):instance.publishState(\"value\",value))},fnNameSuffix)&&(window[\"bubble_fn_\"+fnNameSuffix]=function(value){queueActive&&0!=instance.data.queue.length||publish_value&&instance.data.fn_publish(value),queueActive&&(publish_value?instance.data.queue.push(value):instance.data.queue.push(null)),trigger_event&&instance.data.queue.length<2&&instance.triggerEvent(\"event\")});instance.data.fn_dequeue=function(){if(instance.data.queue.shift(),queueActive&&instance.data.queue.length>0){if(publish_value){var value=instance.data.queue[0];instance.data.fn_publish(value)}trigger_event&&instance.triggerEvent(\"event\")}queueActive&&0==instance.data.queue.length&&publish_value&&instance.data.fn_clearvalues()},instance.data.fn_clearqueue=function(){instance.data.queue=[],queueActive&&instance.data.fn_clearvalues()}}"},"preview":{"fn":"function(instance, properties) {\n var div = document.createElement(\"div\");\n div.style.overflow = \"hidden\";\n div.style.width = \"100%\";\n div.style.height = \"100%\";\n div.style[\"font-style\"] = \"italic\";\n div.style[\"text-wrap\"] = \"nowrap\";\n div.style[\"font-size\"] = \"\" + Math.floor(properties.bubble.height() * 0.75
164) + \"px\";\n div.textContent = \"JS2Bubble\";\n instance.canvas.append(div);\n}"}},"platform_type":"web"},"AAY":{"display":"List Item Expression","property_applications":{"resizable":true},"add_is_visible":true,"fields":{"AAZ":{"caption":"Source item type","name":"sourcetype","editor":"custom_type","rank":2},"AAa":{"caption":"Data source (list)","name":"sourcelist","editor":"DynamicValue","optional":true,"value":"custom_data_AAZ","is_list":true,"rank":3},"AAb":{"caption":"Item expression","name":"itemexpression","editor":"DynamicValue","value":"text","default_val":"","rank":5,"optional":true},"AAc":{"caption":"Result type","name":"resultlisttype","editor":"custom_type","rank":6},"AAl":{"caption":"Lookup values with value() or field(\"field_name\") or field(\"other_data_type\", \"field_name\"). Alternatively, use chained functions item() and lookup() ... item().lookup(\"Product\").lookup(\"Name\")","name":"infoexpression","rank":4,"editor":"Label"},"ABY":{"caption":"List Item Expression. Evaluates for each list item to make a new list.","name":"doctitle","rank":0,"editor":"Label"},"ABZ":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"}},"states":{"AAd":{"caption":"list","name":"resultlist","value":"custom_data_AAc","is_list":true,"initialization_code":{"fn":"function(properties,context){}"}}},"actions":{"AAe":{"caption":"Set data source","code":{"fn":"function(instance,properties,context){var _objvars={result:[],len:0};if(properties.sourcelist&&properties.sourcelist.length&&(_objvars.len=properties.sourcelist.length()),_objvars.len>0)for(_objvars.i=0;_objvars.i<_objvars.len;_objvars.i++)if(_objvars.listRetrieved=properties.sourcelist.get(_objvars.i,1),instance.data.item=_objvars.listRetrieved[0],void 0!==typeof instance.data.item)try{_objvars.result.push(window.toolboxEval({value:instance.data.value,field:instance.data.field,item:instance.data.createItem,lookup:instance.data.lookup,expression:instance.data.itemexpression}))}catch(err){throw\"not ready\"!==err.message&&console.error(err),err}instance.publishState(\"resultlist\",_objvars.result)}"},"fields":{"AAf":{"caption":"Data source (list)","name":"sourcelist","editor":"DynamicValue","value":"custom_data_element_AAZ","is_list":true,"optional":true,"rank":0}}}},"code":{"initialize":{"fn":"function(instance,context){instance.data.value=function(){return void 0===typeof instance.data.item||null==instance.data.item||instance.data.item.listProperties?null:instance.data.item},instance.data.field=function(){if(instance.data.item&&instance.data.item.listProperties){for(var myfield=instance.data.item,fieldType=instance.data.sourcetype,i=0;i<arguments.length;i++){var codeField=arguments[i],fieldUserType=fieldType.replace(\"custom.\",\"\");app.user_types[fieldUserType];var kfs=app.user_types[fieldUserType][\"%f3\"];if(Object.keys(kfs).forEach((function(kf){kfs[kf][\"%d\"]==codeField&&(codeField=kf,fieldType=kfs[kf][\"%v\"])})),null===myfield)break;myfield=myfield.get(codeField)}return myfield}return null},instance.data.createItem=function(pBubbleItem,pFieldType){return{fieldType:pFieldType||instance.data.sourcetype,bubbleItem:pBubbleItem||instance.data.item,lookup:function(codeField){return instance.data.lookup(this,codeField)}}},instance.data.lookup=function(specialItem,codeField){if(\"object\"!=typeof specialItem||!(\"fieldType\"in specialItem)||!(\"bubbleItem\"in specialItem))return console.error(\"List Item Expression - lookup() cannot retrieve from a non-item.\"),null;var thisItem=specialItem.bubbleItem,fieldType=specialItem.fieldType;if(\"object\"!=typeof thisItem||!(\"listProperties\"in thisItem)||!(\"get\"in thisItem))return console.error(\"List Item Expression - lookup() cannot retrieve from a non-item.\"),null;var fieldUserType=fieldType.replace(\"custom.\",\"\");app.user_types[fieldUserType];var kfs=app.user_types[fieldUserType][\"%f3\"],newfieldType=null;Object.keys(kfs).forEach((function(kf){kfs[kf][\"%d\"]==codeField&&(codeField=kf,newfieldType=kfs[kf][\"%v\"])}));var result=thisItem.get(codeField),newItem;if(result&&\"object\"==typeof result&&\"length\"in result&&\"get\"in result){newresult=[],newfieldType=newfieldType.replace(\"list.\",\"\");for(var ilookup=0;ilookup<result.length();ilookup++){var newobject=result.get(ilookup,1)[0];if(\"object\"==typeof newobject&&\"listProperties\"in newobject&&\"get\"in newobject){var newItem=instance.data.createItem(newobject,newfieldType);newresult.push(newItem)}else newresult.push(newobject)}return newresult}return result&&\"object\"==typeof result&&\"listProperties\"in result&&\"get\"in result?newItem=instance.data.createItem(result,newfieldType):result}}"},"update":{"fn":"function(instance,properties,context){var _objvars={};if(instance.data.sourcetype=properties.sourcetype,instance.data.itemexpression=properties.itemexpression,_objvars.result=[],_objvars.len=0,properties.sourcelist&&properties.sourcelist.length&&(_objvars.len=properties.sourcelist.length()),_objvars.len>0)for(_objvars.i=0;_objvars.i<_objvars.len;_objvars.i++)if(_objvars.listRetrieved=properties.sourcelist.get(_objvars.i,1),instance.data.item=_objvars.listRetrieved[0],void 0!==typeof instance.data.item)try{_objvars.result.push(window.toolboxEval({value:instance.data.value,field:instance.data.field,item:instance.data.createItem,lookup:instance.data.lookup,expression:instance.data.itemexpression}))}catch(err){throw\"not ready\"!==err.message&&console.error(err),err}instance.publishState(\"resultlist\",_objvars.result)}"},"preview":{"fn":"function(instance, properties) {\n var div = document.createElement(\"div\");\n div.style.overflow = \"hidden\";\n div.style.width = \"100%\";\n div.style.height = \"100%\";\n div.style[\"font-style\"] = \"italic\";\n div.style[\"text-wrap\"] = \"nowrap\";\n div.style[\"font-size\"] = \"\" + Math.floor(properties.bubble.height() * 0.75
164) + \"px\";\n div.textContent = \"List Item Expression\";\n instance.canvas.append(div);\n}"}},"platform_type":"web"}},"plugin_actions":{"AAg":{"display":"Run javascript","type":"client_side","fields":{"AAh":{"caption":"Script","name":"script","editor":"DynamicValue","value":"text","rank":2},"AAi":{"caption":"Asynchronous","name":"async","editor":"Checkbox","default_val":true,"rank":3},"ABB":{"caption":"param1","name":"param1","rank":4,"editor":"DynamicValue","value":"_any_thing","optional":true},"ABC":{"caption":"param2","name":"param2","rank":5,"editor":"DynamicValue","value":"_any_thing","optional":true},"ABD":{"caption":"param3","name":"param3","rank":6,"editor":"DynamicValue","value":"_any_thing","optional":true},"ABE":{"caption":"param4","name":"param4","rank":7,"editor":"DynamicValue","value":"_any_thing","optional":true},"ABF":{"caption":"param5","name":"param5","rank":8,"editor":"DynamicValue","value":"_any_thing","optional":true},"ABG":{"caption":"paramlist1","name":"paramlist1","rank":9,"editor":"DynamicValue","value":"_any_thing","is_list":true,"optional":true},"ABH":{"caption":"paramlist2","name":"paramlist2","rank":10,"editor":"DynamicValue","value":"_any_thing","is_list":true,"optional":true},"ABI":{"caption":"paramlist3","name":"paramlist3","rank":11,"editor":"DynamicValue","value":"_any_thing","is_list":true,"optional":true},"ABJ":{"caption":"paramlist4","name":"paramlist4","rank":12,"editor":"DynamicValue","value":"_any_thing","is_list":true,"optional":true},"ABK":{"caption":"paramlist5","name":"paramlist5","rank":13,"editor":"DynamicValue","value":"_any_thing","is_list":true,"optional":true},"ABQ":{"caption":"Run Javascript.","name":"doctitle","rank":0,"editor":"Label"},"ABR":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"}},"code":{"client":{"fn":"function(properties,context){var script=properties.script,async=properties.async,_p1=properties.param1,_p2=properties.param2,_p3=properties.param3,_p4=properties.param4,_p5=properties.param5,_pl1=properties.paramlist1,_pl2=properties.paramlist2,_pl3=properties.paramlist3,_pl4=properties.paramlist4,_pl5=properties.paramlist5;eval(\"var properties = arguments[0]; context = arguments[1];\"),async?setTimeout((function(){eval(script)}),1):eval(script)}"}}},"AAn":{"display":"Server script","type":"server_side","return_value":{"AAz":{"caption":"result","name":"result","rank":0,"value":"custom_data_AAp"},"ABA":{"caption":"result list","name":"resultlist","rank":1,"is_list":true,"value":"custom_data_AAp"},"ABg":{"caption":"output1","name":"output1","rank":2,"value":"custom_data_ABf"},"ABp":{"caption":"output2","name":"output2","rank":3,"value":"custom_data_ABh"},"ABq":{"caption":"output3","name":"output3","rank":4,"value":"custom_data_ABi"},"ABr":{"caption":"output4","name":"output4","rank":5,"value":"custom_data_ABj"},"ABs":{"caption":"outputlist1","name":"outputlist1","rank":6,"value":"custom_data_ABk","is_list":true},"ABt":{"caption":"outputlist2","name":"outputlist2","rank":7,"value":"custom_data_ABm","is_list":true},"ABu":{"caption":"outputlist3","name":"outputlist3","rank":8,"value":"custom_data_ABn","is_list":true},"ABv":{"caption":"outputlist4","name":"outputlist4","rank":9,"value":"custom_data_ABo","is_list":true}},"fields":{"AAo":{"caption":"Node script","name":"script","rank":2,"editor":"DynamicValue","value":"text","optional":true},"AAp":{"caption":"Return type","name":"returntype","rank":16,"editor":"custom_type","optional":true},"AAq":{"caption":"Returns a list","name":"returnslist","rank":17,"editor":"Checkbox","default_val":false},"AAr":{"caption":"Data","name":"data","rank":7,"editor":"DynamicValue","value":"text","optional":true},"AAs":{"caption":"Keys and values","name":"keyvalues","rank":8,"editor":"key_value_list","value":"text"},"AAt":{"caption":"Thing 1","name":"thing1","rank":9,"editor":"DynamicValue","value":"_any_thing","optional":true},"AAu":{"caption":"Thing 2","name":"thing2","rank":10,"editor":"DynamicValue","value":"_any_thing","optional":true},"AAv":{"caption":"Thing 3","name":"thing3","rank":11,"editor":"DynamicValue","optional":true,"value":"_any_thing"},"AAw":{"caption":"Thing list 1","name":"thinglist1","rank":12,"optional":true,"editor":"DynamicValue","is_list":true,"value":"_any_thing"},"AAx":{"caption":"Thing list 2","name":"thinglist2","rank":13,"editor":"DynamicValue","is_list":true,"optional":true,"value":"_any_thing"},"AAy":{"caption":"Thing list 3","name":"thinglist3","rank":14,"editor":"DynamicValue","optional":true,"is_list":true,"value":"_any_thing"},"ABO":{"caption":"Server Script. Runs a Node.js AWS Lambda instance.","name":"doctitle","rank":0,"editor":"Label"},"ABP":{"caption":"Docs at toolboxdocs.netlify.app","name":"doclink","rank":1,"editor":"Label"},"ABa":{"caption":"Script is async function","name":"scriptasfn","rank":3,"editor":"Checkbox","default_val":false},"ABb":{"caption":"Ignore errors","name":"ignore_error","rank":4,"editor":"Checkbox","default_val":false},"ABc":{"caption":"Multiple Outputs","name":"multipleoutputs","rank":18,"editor":"Checkbox","default_val":false},"ABd":{"caption":"------------ Inputs ------------","name":"docin
164puts","rank":6,"editor":"Label"},"ABe":{"caption":"------------ Outputs -------------","name":"docoutputs","rank":15,"editor":"Label"},"ABf":{"caption":"output1 type","name":"output1type","rank":19,"editor":"custom_type","optional":true},"ABh":{"caption":"output2 type","name":"output2type","rank":20,"editor":"custom_type","optional":true},"ABi":{"caption":"output3 type","name":"output3type","rank":21,"editor":"custom_type","optional":true},"ABj":{"caption":"output4 type","name":"output4type","rank":22,"editor":"custom_type","optional":true},"ABk":{"caption":"outputlist1 type","name":"outputlist1type","rank":23,"editor":"custom_type","optional":true},"ABm":{"caption":"outputlist2 type","name":"outputlist2type","rank":24,"editor":"custom_type","optional":true},"ABn":{"caption":"outputlist3 type","name":"outputlist3type","rank":25,"editor":"custom_type","optional":true},"ABo":{"caption":"outputlist4 type","name":"outputlist4type","rank":26,"editor":"custom_type","optional":true},"ABw":{"caption":"Log errors","name":"log_error","rank":5,"editor":"Checkbox","default_val":false}}}}}; 165window._bubble_page_load_data.plugins_size['1488796042609x768734193128308700'] = 22168; 166window.preloaded['plugin/third_party:1488796042609x768734193128308700:2.1.3'] = true; 167window.plugins["1498952719168x889602776416649200"] = {"human":"Air Color Picker","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"Air Color picker","property_applications":{"resizable":true,"MinWidth":true,"Background":false,"Border":false,"BoxShadow":false,"Padding":false},"add_hover_pressed":true,"add_is_visible":true,"support_autobinding":true,"autobinding_value":"text","has_reset_fn":false,"fields":{"AAD":{"caption":"Initial color","name":"initial_color","editor":"Color","rank":0,"value":"text","optional":false,"default_val":"rgba(114,28,29,1)"},"AAE":{"caption":"Show input","name":"show_input","editor":"Checkbox","rank":1,"default_val":false},"AAF":{"caption":"Show transparency slider","name":"show_alpha","editor":"Checkbox","rank":2,"default_val":true},"AAG":{"caption":"Disabled","name":"disabled","editor":"Checkbox","rank":3,"default_val":false},"AAH":{"caption":"Show palette","name":"show_palette","editor":"Checkbox","rank":4,"default_val":false},"AAI":{"caption":"Palette colors","name":"palette_colors","editor":"DynamicValue","rank":7,"value":"text","is_list":true,"optional":true},"AAJ":{"caption":"Show palette only","name":"palette_only","editor":"Checkbox","rank":5,"default_val":false},"AAK":{"caption":"Toggle palette only","name":"toggle_palette_only","editor":"Checkbox","rank":6,"default_val":false},"AAL":{"caption":"Show selection palette","name":"show_selection_palette","editor":"Checkbox","rank":8,"default_val":false},"AAM":{"caption":"Max selection size","name":"max_selection_size","editor":"DynamicValue","rank":9,"value":"number","optional":true,"default_val":24},"AAN":{"caption":"Hide after palette select","name":"hide_after_select","editor":"Checkbox","rank":10,"default_val":true},"AAO":{"caption":"Clickout will accept color","name":"clickout_fires_change","editor":"Checkbox","rank":11,"default_val":true},"AAP":{"caption":"Show previous color","name":"show_previous_color","editor":"Checkbox","rank":12,"default_val":false},"AAQ":{"caption":"Show buttons","name":"show_buttons","editor":"Checkbox","rank":13,"default_val":true},"AAV":{"caption":"Format","name":"preferred_format","editor":"Dropdown","rank":14,"default_val":"hex","optional":false},"AAW":{"caption":"Toggle palette more text","name":"togglepalettemoretext","editor":"StaticText","rank":15,"optional":true,"default_val":"more"},"AAX":{"caption":"Toggle palette less text","name":"togglepalettelesstext","editor":"StaticText","rank":16,"optional":true,"default_val":"less"},"AAZ":{"caption":"Cancel button text","name":"cancel_text","editor":"StaticText","rank":17,"default_val":"cancel","optional":true},"AAa":{"caption":"Choose button text","name":"choose_text","editor":"StaticText","rank":18,"default_val":"select","optional":true}
167,"AAb":{"caption":"Background color","name":"background_color","editor":"Color","rank":21,"default_val":"rgba(238, 238, 238, 1)"},"AAc":{"caption":"Border color","name":"border_color","editor":"Color","rank":22,"default_val":"rgba(158, 158, 158, 1)"},"AAe":{"caption":"Corner roundness","name":"border_radius","editor":"Dropdown","rank":25,"default_val":"2","optional":true},"AAf":{"caption":"Allow empty color","name":"allow_empty","rank":19,"editor":"Checkbox","default_val":false},"AAn":{"caption":"Padding left/right","name":"padding_left_right","rank":26,"editor":"StaticNumber","default_val":4},"AAo":{"caption":"Padding top/bottom","name":"padding_top_bottom","rank":27,"editor":"StaticNumber","default_val":4},"AAp":{"caption":"Border hover color","name":"border_hover_color","rank":23,"editor":"Color","default_val":"rgba(240, 196, 155, 1)"},"AAq":{"caption":"Border width","name":"border_width","rank":24,"editor":"StaticNumber","default_val":1},"AAr":{"caption":"â¢â¤ View","name":"view_infromation","rank":20,"editor":"Label"}},"states":{"AAT":{"caption":"value","name":"value","value":"text","initialization_code":{"fn":"function(properties,context){properties.initial_color}"}}},"events":{"AAU":{"caption":"color changed","name":"color_changed"}},"actions":{"AAk":{"caption":"Reset picker","code":{"fn":"function(instance,properties,context){function _0x3d46(){const _0x51947a=[\"92LVaECX\",\"104255ntNIqI\",\"2362056HlGjxc\",\"set\",\"1240482sHwAOH\",\"data\",\"2rnXyCv\",\"21wBxlle\",\"spectrum\",\"696368GvRBpc\",\"107623hutcXC\",\"8971074hYGlGZ\",\"451BlvDvk\",\"539290pXQMVR\"];return(_0x3d46=function(){return _0x51947a})()}function _0x3cb4(_0x523316,_0x517e5d){const _0x3d4606=_0x3d46();return(_0x3cb4=function(_0x3cb449,_0x4198e8){let _0x31b5a0;return _0x3d4606[_0x3cb449-=478]})(_0x523316,_0x517e5d)}function run(_0xd006a8,_0x468cce,_0x2ebeed){const _0x3115e6=_0x3cb4;let _0x301713=_0xd006a8[_0x3115e6(487)].colorTest;$(\".\"+_0xd006a8[_0x3115e6(487)].id)[_0x3115e6(490)](_0x3115e6(485),_0x301713),_0xd006a8.publishState(\"value\",_0x301713)}!function(_0x15b84f,_0x31153f){const _0x12ec09=_0x3cb4,_0x769882=_0x15b84f();for(;;)try{const _0x1c9d40=undefined;if(547042===parseInt(_0x12ec09(478))/1*(-parseInt(_0x12ec09(488))/2)+-parseInt(_0x12ec09(484))/3+-parseInt(_0x12ec09(482))/4*(parseInt(_0x12ec09(483))/5)+parseInt(_0x12ec09(486))/6*(parseInt(_0x12ec09(489))/7)+parseInt(_0x12ec09(491))/8+-parseInt(_0x12ec09(479))/9+-parseInt(_0x12ec09(481))/10*(-parseInt(_0x12ec09(480))/11))break;_0x769882.push(_0x769882.shift())}catch(_0x54f533){_0x769882.push(_0x769882.shift())}}(_0x3d46,547042),run(instance,properties,context)}"}}},"code":{"initialize":{"fn":"function(instance,context){function _0x27a0(_0x3ebae4,_0x40b80f){var _0x405436=_0x4054();return(_0x27a0=function(_0x27a07b,_0x1ba71e){var _0x3d389a;return _0x405436[_0x27a07b-=341]})(_0x3ebae4,_0x40b80f)}function initialize(_0x43bc99,_0x1d93e7){var _0x491cb0=_0x27a0,_0x2ee02f=\"picker\"+(Math[_0x491cb0(359)]()*Math.pow(2,54))[_0x491cb0(341)](18),_0x8b90c1;(_0x8b90c1=$('<input type=\"text\" class=\"'+_0x2ee02f+_0x491cb0(361)))[_0x491cb0(352)](_0x491cb0(342),_0x491cb0(346)),_0x8b90c1.css(_0x491cb0(350),_0x491cb0(346)),_0x43bc99[_0x491cb0(347)].append(_0x8b90c1),_0x43bc99[_0x491cb0(355)][_0x491cb0(360)]=_0x8b90c1,_0x43bc99[_0x491cb0(355)].id=_0x2ee02f}function _0x4054(){var _0xcdc27d=[\"735237HcJcAa\",\"295227mrGlWx\",\"height\",\"11heAFYL\",\"css\",\"5DVdPDv\",\"10DEwpMo\",\"data\",\"2564088PWRpyU\",\"449811ATLeoU\",\"22029xDzhpI\",\"random\",\"div\",'\"/>',\"toString\",\"width\",\"18490230ZVUuNt\",\"2648kXgjwf\",\"1134786wiNYYI\",\"100%\",\"canvas\"];return(_0x4054=function(){return _0xcdc27d})()}!function(_0x18cc95,_0x2848b3){for(var _0x122c25=_0x27a0,_0x1339dc=_0x18cc95();;)try{var _0x14e93b;if(783266===-parseInt(_0x122c25(348))/1+-parseInt(_0x122c25(354))/2*(parseInt(_0x122c25(349))/3)+-parseInt(_0x122c25(356))/4*(parseInt(_0x122c25(353))/5)+-parseInt(_0x122c25(345))/6+parseInt(_0x122c25(358))/7*(parseInt(_0x122c25(344))/8)+-parseInt(_0x122c25(357))/9+parseInt(_0x122c25(343))/10*(parseInt(_0x122c25(351))/11))break;_0x1339dc.push(_0x1339dc.shift())}catch(_0x1bba5f){_0x1339dc.push(_0x1339dc.shift())}}(_0x4054,783266),initialize(instance,context)}"},"update":{"fn":"function(instance,properties,context){function _0x1599(){const _0x46b869=[\";\\nborder-radius: \",\"rgb(\",\"2114448OEqkYC\",\"toRgb\",\"blue\",\"7370379LjutAR\",\" { \\nbackground-color: \",\"297990zTowdk\",\"togglepalettelesstext\",\"palette_colors\",\"getComputedStyle\",\"data\",\"red\",\"style\",\"max_selection_size\",\"267932Ujllfr\",\"hex\",\"filter\",\"className\",\"px;\\n}\\n.\",\"disabled\",\"#ffffff\",\"px \",\"show_alpha\",\"spectrum\",\"initial_color\",\"show_selection_palette\",\"preferred_format\",\"color\",\"replace\",\"slice\",\"#9b59b6\",\"#f1c40f\",\"show_previous_color\",\"getPropertyValue\",\"hsla\",\"<style>\",\"lime\",\"hex3\",\"</style>\",\"rgba\",\"head\",\"palette_only\",\"object\",\"#0000ff\",\"172240QPQBQc\",\"rgb\",\"autobinding\",\"trim\",\".sp-container\",\"appendChild\",\"choose_text\",\"join\",\"split\",\"sp-hidden\",\"each\",\"15yaKWoY\",\"55734PkfSEE\",\"594672pYIMSX\",\"%, \",\"appendTo\",\"value\",\";\\nborder-color: \",\"show_buttons\",\"#2980b9\",\"aircolorpicker.bubble\",\"ready\",\"#bdc3c7\",\"name\",\"cancel_text\",\"toString\",\"body\",\"removeChild\",\"rgba(\",\"includes\",\"7nbNXjm\",\"magenta\",\"color_changed\",\"cyan\",\"string\",\"div\",\"white\",\"lastSelectedColor\",\"publishState\",\"map\",\"hsla(\",\"match\",\"createElement\",\"yellow\",\"unset\",\"#f39c12\",\"round\",\"; }\\n\",\"#1abc9c\",\":hover { border-color: \",\"#17d9fd\",\"triggerEvent\",\"hide_after_select\"];return(_0x1599=function(){return _0x46b869})()}function _0x55bd(_0x3acf45,_0x5b4b23){const _0x1599f8=_0x1599();return(_0x55bd=function(_0x55bd6a,_0x4ae272){let _0x4bbdf7;return _0x1599f8[_0x55bd6a-=343]})(_0x3acf45,_0x5b4b23)}function update(_0x756dab,_0x575e29,_0x4f1b9f){const _0x4a6143=_0x55bd,_0x1ffaa2=\"#FFFFFF\",_0x1c6e22=_0x756dab[_0x4a6143(436)].id,_0x4107a1=_0x1c6e22+_0x4a6143(438),_0x22bdb2=$(\".\"+_0x1c6e22);function _0x28b012(_0x38552e){const _0x2a6ca6=_0x4a6143;return _0x38552e&&(_0x38552e[_0x2a6ca6(401)](\"#\")||_0x38552e.includes(_0x2a6ca6(373)))?_0x38552e:\"#FFFFFF\"}function _0x46f354(_0x3addff){const _0x54dc29=_0x4a6143;if(!_0x3addff[_0x54dc29(401)](\"#\")&&!_0x3addff[_0x54dc29(401)](_0x54dc29(373))){const _0x39d8a0=undefined;return window.getComputedStyle(document.documentElement)[_0x54dc29(361)](_0x3addff.replace(\"var(\",\"\")[_0x54dc29(356)](\")\",\"\"))}return _0x3addff}_0x756dab.data[_0x4a6143(409)]=_0x575e29[_0x4a6143(352)]||_0x756dab[_0x4a6143(436)][_0x4a6143(409)]||\"#FFFFFF\";const _0x5dbc1d=_0x4294d7((_0x3e1ce9=>{const _0x3da0fe=_0x4a6143,_0x1581bb=_0x6444e2(_0x3e1ce9,_0x575e29[_0x3da0fe(354)]);_0x756dab[_0x3da0fe(436)][_0x3da0fe(355)]!==_0x1581bb&&(_0x756dab[_0x3da0fe(423)](_0x3da0fe(404)),_0x756dab.data.color=_0x1581bb,_0x756dab[_0x3da0fe(410)](_0x3da0fe(388),_0x1581bb))}),150);function _0x250c22(_0x33c53b){const _0x44958b=_0x4a6143,_0x20ed3e=_0x231847(_0x33c53b,_0x575e29[_0x44958b(354)]);_0x756dab[_0x44958b(410)](_0x44958b(388),_0x20ed3e),_0x756dab.data[_0x44958b(409)]=_0x20ed3e||\"#FFFFFF\",_0x756dab.publishAutobinding(_0x20ed3e),_0x5dbc1d(_0x20ed3e)}function _0x231847(_0x5747be,_0x5b1f40){const _0x341d04=_0x4a6143;if(!_0x5747be)return null;if(typeof _0x5747be===_0x341d04(370)&&_0x5747be[_0x341d04(428)]){const _0x5b1f35=undefined;return _0xbaf208(_0x5747be[_0x341d04(428)](),_0x5b1f40)}return typeof _0x5747be===_0x341d04(406)?_0x6444e2(_0x5747be,_0x5b1f40):_0x6444e2(_0x5747be[_0x341d04(397)](),_0x5b1f40)}function _0xbaf208(_0x3adcee,_0x266048){const _0x4114a6=_0x4a6143,{r:_0xafc783,g:_0x449a0f,b:_0x3f59ee,a:_0x22de14}=_0x3adcee;switch(_0x266048){case _0x4114a6(343):return\"#\"+((1<<24)+(_0xafc783<<16)+(_0x449a0f<<8)+_0x3f59ee).toString(16)[_0x4114a6(357)](1);case _0x4114a6(365):return\"#\"+[_0xafc783,_0x449a0f,_0x3f59ee][_0x4114a6(411)]((_0
167x599380=>Math.round(_0x599380/17)[_0x4114a6(397)](16)))[_0x4114a6(379)](\"\");case _0x4114a6(373):return _0x4114a6(426)+_0xafc783+\", \"+_0x449a0f+\", \"+_0x3f59ee+\")\";case\"rgba\":return _0x4114a6(400)+_0xafc783+\", \"+_0x449a0f+\", \"+_0x3f59ee+\", \"+(void 0!==_0x22de14?_0x22de14:1)+\")\";case\"hsl\":return _0x281e96(_0xafc783,_0x449a0f,_0x3f59ee);case _0x4114a6(362):const _0x1dab3a=undefined;return _0x281e96(_0xafc783,_0x449a0f,_0x3f59ee,!0)[_0x4114a6(356)](\"hsl(\",_0x4114a6(412))[_0x4114a6(356)](\")\",\", \"+(void 0!==_0x22de14?_0x22de14:1)+\")\");case _0x4114a6(395):return _0x83e73e(_0xafc783,_0x449a0f,_0x3f59ee)||_0x4114a6(426)+_0xafc783+\", \"+_0x449a0f+\", \"+_0x3f59ee+\")\";default:return void 0!==_0x22de14&&_0x22de14<1?_0x4114a6(400)+_0xafc783+\", \"+_0x449a0f+\", \"+_0x3f59ee+\", \"+_0x22de14+\")\":_0x4114a6(426)+_0xafc783+\", \"+_0x449a0f+\", \"+_0x3f59ee+\")\"}}function _0x289eb2(){const _0x1c10bb=_0x4a6143;let _0x5d2e9a,_0x4b44d2=_0x6444e2(_0x28b012(_0x46f354(_0x575e29[_0x1c10bb(374)]||_0x756dab.data[_0x1c10bb(409)])),_0x575e29[_0x1c10bb(354)]);_0x756dab.publishState(_0x1c10bb(388),_0x4b44d2);const _0x3d371d=_0x575e29[_0x1c10bb(434)]?_0x575e29[_0x1c10bb(434)].get(0,99):[[_0x1c10bb(348),_0x1c10bb(394),_0x1c10bb(359),_0x1c10bb(417),\"#e74c3c\",_0x1c10bb(420),_0x1c10bb(422),_0x1c10bb(371),_0x1c10bb(391),_0x1c10bb(358),\"#000000\"]];_0x320d04(),_0x22bdb2[_0x1c10bb(351)]({color:_0x4b44d2,showInput:_0x575e29.show_input,showInitial:_0x575e29[_0x1c10bb(360)],allowEmpty:_0x575e29.allow_empty,showAlpha:_0x575e29[_0x1c10bb(350)],disabled:_0x575e29[_0x1c10bb(347)],localStorageKey:_0x1c10bb(392),showPalette:_0x575e29.show_palette,showPaletteOnly:_0x575e29[_0x1c10bb(369)],togglePaletteOnly:_0x575e29.toggle_palette_only,showSelectionPalette:_0x575e29[_0x1c10bb(353)],clickoutFiresChange:_0x575e29.clickout_fires_change,cancelText:_0x575e29[_0x1c10bb(396)],chooseText:_0x575e29[_0x1c10bb(378)],togglePaletteMoreText:_0x575e29.togglepalettemoretext,togglePaletteLessText:_0x575e29[_0x1c10bb(433)],replacerClassName:_0x4107a1,preferredFormat:_0x575e29[_0x1c10bb(354)],maxSelectionSize:_0x575e29[_0x1c10bb(439)],palette:_0x3d371d,hideAfterPaletteSelect:_0x575e29[_0x1c10bb(424)],showButtons:_0x575e29[_0x1c10bb(390)],change:_0x250c22,hide:_0x250c22,show:()=>{const _0x1c3759=_0x1c10bb;$(_0x1c3759(376))[_0x1c3759(382)](((_0x224985,_0x2450ec)=>{const _0x2ab9ea=_0x1c3759;!_0x2450ec[_0x2ab9ea(345)].includes(_0x2ab9ea(381))&&(_0x2450ec.style[_0x2ab9ea(344)]=_0x2ab9ea(416))}))}})}function _0x320d04(){const _0x4de018=_0x4a6143,{background_color:_0x54bf60,border_color:_0x165ab6,border_radius:_0x43e589,padding_left_right:_0x1be249,padding_top_bottom:_0x3b9860,border_hover_color:_0x45bebb,border_width:_0x5a8821}=_0x575e29,_0x16f8b4=\"\\n.\"+_0x4107a1+_0x4de018(431)+_0x54bf60+_0x4de018(389)+_0x165ab6+_0x4de018(425)+_0x43e589+\"px;\\nborder-width: \"+_0x5a8821+\"px;\\npadding: \"+_0x3b9860+_0x4de018(349)+_0x1be249+_0x4de018(346)+_0x4107a1+_0x4de018(421)+_0x45bebb+_0x4de018(419);$(_0x4de018(363)+_0x16f8b4+_0x4de018(366))[_0x4de018(387)](_0x4de018(368))}function _0x4294d7(_0x15032d,_0xe0bbd4=100){let _0xcea185;return function(..._0x137638){clearTimeout(_0xcea185),_0xcea185=setTimeout((()=>_0x15032d.apply(this,_0x137638)),_0xe0bbd4)}}function _0x6444e2(_0x25e4ac,_0x537269){const _0x2e1350=_0x4a6143,_0x30d100=document[_0x2e1350(414)](_0x2e1350(407));_0x30d100.style.color=_0x25e4ac,document[_0x2e1350(398)][_0x2e1350(377)](_0x30d100);const _0x5c9ac3=window[_0x2e1350(435)](_0x30d100).color;document[_0x2e1350(398)][_0x2e1350(399)](_0x30d100);const _0x5b84d9=_0x5c9ac3[_0x2e1350(413)](/rgba?\\(([^)]+)\\)/);if(!_0x5b84d9)return _0x25e4ac;const _0x1a6081=_0x5b84d9[1][_0x2e1350(380)](\",\")[_0x2e1350(411)]((_0x38172c=>parseFloat(_0x38172c[_0x2e1350(375)]()))),_0x210126=parseInt(_0x1a6081[0]),_0x3965dc=parseInt(_0x1a6081[1]),_0x1da2b4=parseInt(_0x1a6081[2]),_0x44298e=void 0!==_0x1a6081[3]?parseFloat(_0x1a6081[3]):1;switch(_0x537269){case _0x2e1350(343):return\"#\"+((1<<24)+(_0x210126<<16)+(_0x3965dc<<8)+_0x1da2b4).toString(16).slice(1);case _0x2e1350(365):return\"#\"+[_0x210126,_0x3965dc,_0x1da2b4][_0x2e1350(411)]((_0
167x5284e0=>Math[_0x2e1350(418)](_0x5284e0/17)[_0x2e1350(397)](16)))[_0x2e1350(379)](\"\");case _0x2e1350(373):return _0x2e1350(426)+_0x210126+\", \"+_0x3965dc+\", \"+_0x1da2b4+\")\";case _0x2e1350(367):return\"rgba(\"+_0x210126+\", \"+_0x3965dc+\", \"+_0x1da2b4+\", \"+_0x44298e+\")\";case\"hsl\":return _0x281e96(_0x210126,_0x3965dc,_0x1da2b4);case _0x2e1350(362):const _0x5e277e=undefined;return _0x281e96(_0x210126,_0x3965dc,_0x1da2b4,!0).replace(\"hsl(\",\"hsla(\")[_0x2e1350(356)](\")\",\", \"+_0x44298e+\")\");case _0x2e1350(395):return _0x83e73e(_0x210126,_0x3965dc,_0x1da2b4)||_0x2e1350(426)+_0x210126+\", \"+_0x3965dc+\", \"+_0x1da2b4+\")\";default:return _0x25e4ac}}function _0x281e96(_0x3fb6bc,_0x2a3a2e,_0x1d7fe6,_0x15b734=!1){const _0x35dfc2=_0x4a6143;_0x3fb6bc/=255,_0x2a3a2e/=255,_0x1d7fe6/=255;const _0x4d25ef=Math.max(_0x3fb6bc,_0x2a3a2e,_0x1d7fe6),_0x5474d6=Math.min(_0x3fb6bc,_0x2a3a2e,_0x1d7fe6);let _0x52ae9a,_0x34023e,_0x5a729b=(_0x4d25ef+_0x5474d6)/2;if(_0x4d25ef==_0x5474d6)_0x52ae9a=_0x34023e=0;else{const _0x1531d0=_0x4d25ef-_0x5474d6;switch(_0x34023e=_0x5a729b>.5?_0x1531d0/(2-_0x4d25ef-_0x5474d6):_0x1531d0/(_0x4d25ef+_0x5474d6),_0x4d25ef){case _0x3fb6bc:_0x52ae9a=(_0x2a3a2e-_0x1d7fe6)/_0x1531d0+(_0x2a3a2e<_0x1d7fe6?6:0);break;case _0x2a3a2e:_0x52ae9a=(_0x1d7fe6-_0x3fb6bc)/_0x1531d0+2;break;case _0x1d7fe6:_0x52ae9a=(_0x3fb6bc-_0x2a3a2e)/_0x1531d0+4}_0x52ae9a/=6}const _0x145ee3={h:Math[_0x35dfc2(418)](360*_0x52ae9a),s:Math.round(100*_0x34023e),l:Math[_0x35dfc2(418)](100*_0x5a729b)};return _0x15b734?_0x145ee3:\"hsl(\"+_0x145ee3.h+\", \"+_0x145ee3.s+_0x35dfc2(386)+_0x145ee3.l+\"%)\"}function _0x83e73e(_0x2cbd79,_0x3b2284,_0x2dab22){const _0x28bb41=_0x4a6143,_0x2b021e=undefined;return{\"255,0,0\":_0x28bb41(437),\"0,255,0\":_0x28bb41(364),\"0,0,255\":_0x28bb41(429),\"0,0,0\":\"black\",\"255,255,255\":_0x28bb41(408),\"255,255,0\":_0x28bb41(415),\"0,255,255\":_0x28bb41(405),\"255,0,255\":_0x28bb41(403)}[_0x2cbd79+\",\"+_0x3b2284+\",\"+_0x2dab22]}$(document)[_0x4a6143(393)](_0x289eb2)}!function(_0x13d166,_0x39ee7d){const _0x1f3dd6=_0x55bd,_0x2d3e0b=_0x13d166();for(;;)try{const _0x98f3e0=undefined;if(187727===parseInt(_0x1f3dd6(384))/1+-parseInt(_0x1f3dd6(440))/2+-parseInt(_0x1f3dd6(383))/3*(parseInt(_0x1f3dd6(372))/4)+-parseInt(_0x1f3dd6(432))/5+-parseInt(_0x1f3dd6(427))/6*(parseInt(_0x1f3dd6(402))/7)+parseInt(_0x1f3dd6(385))/8+parseInt(_0x1f3dd6(430))/9)break;_0x2d3e0b.push(_0x2d3e0b.shift())}catch(_0x214315){_0x2d3e0b.push(_0x2d3e0b.shift())}}(_0x1599,187727),update(instance,properties,context)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n const img = $(\"<img/>\")\n const src = 'https://s3.amazonaws.com/appforest_uf/f1499130874654x508908465737476900/placeholder.png'\n img.attr('src', src);\n img.css({\n \theight: \"100%\",\n \twidth: \"100%\",\n })\n \n instance.canvas.css({\n \theight: \"100%\",\n \twidth: \"100%\",\n })\n \n instance.canvas.closest(\"html\").css({\n \theight: \"100%\",\n \twidth: \"100%\",\n })\n \n instance.canvas.closest(\"body\").css({\n \toverflow: \"hidden\",\n height: \"100%\",\n })\n \n //debugger\n\tinstance.canvas.append(img)\n\n\n}"}},"platform_type":"web"}}}; 168window._bubble_page_load_data.plugins_size['1498952719168x889602776416649200'] = 18204; 169window.preloaded['plugin/third_party:1498952719168x889602776416649200:1.37.0'] = true; 170window.plugins["1551365877078x445243110416449540"] = {"human":"Date & Time Toolkit","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_api":{"human":"Date & Time Toolkit","calls":{"ACX":{"name":"ð¡ï¸ Recurring Dates Schema","method":"get","publish_as":"data","should_reinitialize":false,"url":"#","initialized":true,"types":"{\"plugin_api.ACX\":{\"caption\":\"ð¡ï¸ Recurring Dates Schema\",\"fields\":{\"_p_id\":{\"ret_value\":\"text\",\"caption\":\"id\",\"sample_value\":\"string\"},\"_p_configuration.frequency\":{\"ret_value\":\"text\",\"caption\":\"configuration frequency\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"frequency\"]},\"_p_configuration.starts_on\":{\"ret_value\":\"date\",\"caption\":\"configuration starts_on\",\"sample_value\":\"date\",\"path\":[\"configuration\",\"starts_on\"]},\"_p_configuration.interval\":{\"ret_value\":\"number\",\"caption\":\"configuration interval\",\"sample_value\":1,\"path\":[\"configuration\",\"interval\"]}
170,\"_p_configuration.week_start_day\":{\"ret_value\":\"text\",\"caption\":\"configuration week_start_day\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"week_start_day\"]},\"_p_configuration.count\":{\"ret_value\":\"number\",\"caption\":\"configuration count\",\"sample_value\":1,\"path\":[\"configuration\",\"count\"]},\"_p_configuration.until\":{\"ret_value\":\"date\",\"caption\":\"configuration until\",\"sample_value\":\"date\",\"path\":[\"configuration\",\"until\"]},\"_p_configuration.by_step_position\":{\"ret_value\":\"text\",\"caption\":\"configuration by_step_position\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_step_position\"]},\"_p_configuration.by_month\":{\"ret_value\":\"text\",\"caption\":\"configuration by_month\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_month\"]},\"_p_configuration.by_month_day\":{\"ret_value\":\"text\",\"caption\":\"configuration by_month_day\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_month_day\"]},\"_p_configuration.by_year_day\":{\"ret_value\":\"text\",\"caption\":\"configuration by_year_day\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_year_day\"]},\"_p_configuration.by_week_no\":{\"ret_value\":\"text\",\"caption\":\"configuration by_week_no\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_week_no\"]},\"_p_configuration.by_week_day\":{\"ret_value\":\"text\",\"caption\":\"configuration by_week_day\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_week_day\"]},\"_p_configuration.by_hour\":{\"ret_value\":\"text\",\"caption\":\"configuration by_hour\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_hour\"]},\"_p_configuration.by_minute\":{\"ret_value\":\"text\",\"caption\":\"configuration by_minute\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_minute\"]},\"_p_configuration.by_second\":{\"ret_value\":\"text\",\"caption\":\"configuration by_second\",\"sample_value\":\"string\",\"path\":[\"configuration\",\"by_second\"]},\"_p_ical\":{\"ret_value\":\"text\",\"caption\":\"ical\",\"sample_value\":\"string\"},\"_p_readable\":{\"ret_value\":\"text\",\"caption\":\"readable\",\"sample_value\":\"string\"}}}}","ret_value":"api.1551365877078x445243110416449540.plugin_api.ACX"}}},"shared_keys":{"ACE":{"caption":"Verbose Logging","type":"client_safe"},"ACF":{"caption":"Retry Every (ms)","type":"client_safe"},"ACG":{"caption":"No. of Retries","type":"client_safe"},"ACH":{"caption":"Exponential Delay","type":"client_safe"}},"plugin_elements":{"AAC":{"display":"Split Date Ranges","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"has_reset_fn":false,"fields":{"AAD":{"caption":"Use this element to split two dates by years, quarters, months, weeks, days, hours, or minutes.","name":"use_this_element_to_split_two_dates_by_weeks,_days,_hours,_minutes","rank":1,"editor":"Label"},"AAE":{"caption":"Timex-Split Date Ranges","name":"telex_-_split_dates","rank":0,"editor":"Label"},"AAF":{"caption":"Start Date/Time","name":"day_start","rank":3,"editor":"DynamicValue","value":"date"},"AAG":{"caption":"End Date/Time","name":"day_end","rank":4,"editor":"DynamicValue","value":"date"},"AAI":{"caption":"Steps","name":"steps","rank":6,"editor":"DynamicValue","value":"number","default_val":30},"AAM":{"caption":"Step Units","name":"step_units","rank":5,"editor":"Dropdown","value":"text","default_val":"minutes"},"AAP":{"caption":"INPUT VARIABLES","name":"input_options","rank":2,"editor":"Label"},"AAQ":{"caption":"OUTPUT OPTIONS","name":"output_options","rank":7,"editor":"Label"},"AAS":{"caption":"Range Option","name":"range_option","rank":8,"editor":"Dropdown","default_val":"Start Date/Time"}},"states":{"AAJ":{"caption":"Date List","name":"date_list","value":"date","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAN":{"caption":"Date Range List","name":"date_range_list","value":"date_range","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAO":{"caption":"Count","name":"count","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AAK":{"caption":"Results Available","name":"results_available"}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){let day_start=properties.day_start,day_end=properties.day_end,step_units=properties.step_units,steps=properties.steps,range_option=properties.range_option;function splitDatesHours(start,end,unit,steps){start=new Date(start),end=new Date(end);let day_start=moment(start),day_end=moment(end),day=moment.range(day_start,day_end),time_slots=Array.from(day.by(unit,{step:steps})),result={},date_list=[],date_range_list=[];
170return time_slots.forEach((e=>{switch(range_option){case\"Start Date/Time\":default:date_range_list.push([day.start._d,e._d]);break;case\"End Date/Time\":date_range_list.push([e._d,day.end._d]);break;case\"Previous Date/Time\":date_range_list.push([date_list.slice(-1)[0],e._d])}date_list.push(e._d)})),result.date_list=date_list,result.count=date_list.length,date_range_list.shift(),result.date_range_list=date_range_list,result}$(document).ready((function(){setTimeout((function(){let results=splitDatesHours(day_start,day_end,step_units,steps);instance.publishState(\"date_list\",results.date_list),instance.publishState(\"date_range_list\",results.date_range_list),instance.publishState(\"count\",results.count),instance.triggerEvent(\"results_available\")}),250)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AAV":{"display":"List Dates","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"fields":{"AAW":{"caption":"Timex-List Dates","name":"timex-list_dates","rank":0,"editor":"Label"},"AAX":{"caption":"Use this element to get the quarter, month, or week of where a date belongs","name":"use_this_element_to_get_the_quarter,_month,_or_week_of_where_a_date_belongs","rank":1,"editor":"Label"},"AAY":{"caption":"INPUT VARIABLES","name":"input_variables","rank":2,"editor":"Label"},"AAZ":{"caption":"Focus Date","name":"focus_date","rank":3,"editor":"DynamicValue","value":"date"},"AAa":{"caption":"Target Start","name":"target_start","rank":4,"editor":"Dropdown","default_val":"week"},"AAb":{"caption":"Target Stretch","name":"target_stretch","rank":6,"editor":"DynamicValue","value":"number","default_val":0,"optional":true},"AAc":{"caption":"Unit Type","name":"unit_type","rank":7,"editor":"Dropdown","default_val":"day"},"AAd":{"caption":"Target End","name":"target_end","rank":5,"editor":"Dropdown","default_val":"week"},"AAh":{"caption":"OUTPUT OPTIONS","name":"output_options","rank":8,"editor":"Label"},"AAj":{"caption":"Range Option","name":"range_option","rank":9,"editor":"Dropdown","default_val":"Start Date/Time"}},"states":{"AAe":{"caption":"Date Results","name":"date_results","value":"date","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAf":{"caption":"Range Results","name":"range_results","value":"date_range","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAg":{"caption":"Count","name":"count","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AAl":{"caption":"Results Available","name":"results_available"}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){let focus_date=properties.focus_date,target_start=properties.target_start,target_end=properties.target_end,target_stretch=properties.target_stretch,unit_type=properties.unit_type,range_option=properties.range_option;function targetDates(initialDate,startRange,endRange,getDate,getOffset){let currentDate=moment(initialDate).milliseconds(0),startTarget=currentDate.clone().startOf(startRange),endTarget=currentDate.clone().endOf(endRange),results={},maxi;maxi=endTarget.diff(startTarget,getDate)+getOffset;let date_list=[],date_range_list=[],i;for(i=0;i<=maxi;i++){let date_extract=moment(startTarget).add(i,getDate);switch(range_option){case\"Start Date/Time\":date_range_list.push([startTarget._d,date_extract._d]);break;case\"End Date/Time\":date_range_list.push([date_extract._d,endTarget._d]);break;case\"Previous Date/Time\":if(0==date_list.length||null==date_list){let last_date=currentDate.clone().startOf(startRange).subtract(1,\"days\")._d;date_range_list.push([last_date,date_extract._d])}else{let last_date=date_list.slice(-1)[0];date_range_list.push([last_date,date_extract._d])}break;default:console.log(\"Timex Plugin\",\"No option selected for a Rang Option!\"),date_range_list.push([startTarget.start._d,i._d])}date_list.push(date_extract._d)}return results.days=date_list,results.count=date_list.length,results.range_results=date_range_list,results}$(document).ready((function(){setTimeout((function(){let re=targetDates(focus_date,target_start,target_end,unit_type,target_stretch);instance.publishState(\"date_results\",re.days),instance.publishState(\"count\",re.count),instance.triggerEvent(\"results_available\")}),150)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ACK":{"display":"Recurring Dates (BETA)","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"has_reset_fn":true,"fields":{"ACU":{"caption":"Please use associate workflow actions to generate a list of recurring dates","name":"info","rank":0,"editor":"Label"},"ACW":{"caption":"Disable Cache","name":"disable_cache","rank":2,"editor":"Checkbox","default_val":true},"ACw":{"caption":"Data Schema","name":"data_schema","rank":1,"editor":"custom_type"}},"states":{"ACL":{"caption":"Ready","name":"ready","value":"boolean","initialization_code":{"fn":"function(properties,context){return!1}"}},"ACy":{"caption":"Configurations","name":"configurations","value":"custom_data_ACw","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ACz":{"caption":"Occurrences","name":"occurrences","value":"date","initialization_code":{"fn":"function(properties,context){}"},"is_list":true}},"events":{"ACM":{"caption":"Ready","name":"ready"},"ACv":{"caption":"Occurrences Loaded","name":"occurrences_loaded"},"ADI":{"caption":"Configuration Loaded","name":"configuration_loaded"}},"actions":{"ACY":{"caption":"Load configuration","code":{"fn":"let action=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog;if(!instance.data.ready)return void vLog(\"Plugin not ready yet\");let l=instance.data.rules,rule_id=properties.rule_id?properties.rule_id:l.length+1,freq=instance.data.getFrequency(properties.frequency),dtstart=properties.starts_on?properties.starts_on:new Date,interval=properties.interval,wkst=instance.data.getWeekStartDay(properties.week_start_day),count=properties.count,until=properties.until,bysetpos=properties.by_step_position?properties.by_step_position.split(\",\").map(Number):null,bymonth=properties.by_month?properties.by_month.split(\",\").map(Number):null,bymonthday=properties.by_month_day?properties.by_month_day.split(\",\").map(Number):null,byyearday=properties.by_year_day?properties.by_year_day.split(\",\").map(Number):null,byweekno=properties.by_week_no?properties.by_week_no.split(\",\").map(Number):null,byweekday=properties.by_week_day?properties.by_week_day.split(\",\").map(Number):null,byhour=properties.by_hour?properties.by_hour.split(\",\").map(Number):null,byminute=properties.by_minute?properties.by_minute.split(\",\").map(Number):null,bysecond=properties.by_second?properties.by_second.split(\",\").map(Number):null;if(vLog(\"Requested configuration\",properties),!freq)return void vError(\"No frequency defined. Please use one of the following: yearly, monthly, weekly, daily, hourly, minutely, secondly\");if(!count&&!until)return void vError(\"a count limit or an until date must be defined\");let preRule={freq:freq,dtstart:dtstart,interval:interval,wkst:wkst,count:count,until:until,bysetpos:bysetpos,bymonth:bymonth,bymonthday:bymonthday,byyearday:byyearday,byweekno:byweekno,byweekday:byweekday,byhour:byhour,byminute:byminute,bysecond:bysecond};vLog(\"Converted preRule\",preRule),preRule=Object.fromEntries(Object.entries(preRule).filter((([_,v])=>null!=v)));let config=Object.fromEntries(Object.entries(properties).filter((([_,v])=>null!=v))),rule=instance.data.configToRule(preRule);instance.data.rules.push({id:rule_id.toString(),config:config,...rule}),vLog(`New rule id ${rule_id.toString()} added. ${l.length}
170 rules total`,instance.data.rules),instance.data.appendToConfigState()};"},"fields":{"ACZ":{"caption":"Frequency","name":"frequency","rank":1,"editor":"DynamicValue","value":"text"},"ACa":{"caption":"Starts On","name":"starts_on","rank":2,"editor":"DynamicValue","value":"date","optional":true},"ACb":{"caption":"Interval","name":"interval","rank":3,"editor":"DynamicValue","value":"number","optional":true},"ACc":{"caption":"Week Start Day","name":"week_start_day","rank":4,"editor":"DynamicValue","value":"text","optional":true},"ACd":{"caption":"Count","name":"count","rank":5,"editor":"DynamicValue","value":"number","optional":true},"ACe":{"caption":"Until","name":"until","rank":6,"editor":"DynamicValue","value":"date","optional":true},"ACf":{"caption":"By Step Position","name":"by_step_position","rank":7,"editor":"DynamicValue","value":"text","is_list":false,"optional":true},"ACg":{"caption":"By Month","name":"by_month","rank":8,"editor":"DynamicValue","value":"text","optional":true},"ACh":{"caption":"By Month Day","name":"by_month_day","rank":9,"editor":"DynamicValue","value":"text","optional":true},"ACi":{"caption":"By Year Day","name":"by_year_day","rank":10,"editor":"DynamicValue","value":"text","optional":true},"ACj":{"caption":"By Week No","name":"by_week_no","rank":11,"editor":"DynamicValue","value":"text","optional":true},"ACk":{"caption":"By Hour","name":"by_hour","rank":13,"editor":"DynamicValue","value":"text","optional":true},"ACl":{"caption":"By Minute","name":"by_minute","rank":14,"editor":"DynamicValue","value":"text","optional":true},"ACm":{"caption":"By Second","name":"by_second","rank":15,"editor":"DynamicValue","value":"text","optional":true},"ACo":{"caption":"Rule ID","name":"rule_id","rank":0,"editor":"DynamicValue","value":"text","optional":true},"ACx":{"caption":"By Week Day","name":"by_week_day","rank":12,"editor":"DynamicValue","value":"text","optional":true}}},"ACn":{"caption":"Clear all configurations","code":{"fn":"let action=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog;if(instance.data.ready)if(instance.data.rules){let l;vLog(`${instance.data.rules.length} rules cleared`),instance.data.rules=[],instance.data.appendToConfigState()}else vLog(\"No rules to clear\");else vLog(\"Plugin not ready yet\")};"}},"ACp":{"caption":"Remove configuration","code":{"fn":"let action=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog,rule_id=properties.rule_id.toString();if(!instance.data.ready)return void vLog(\"Plugin not ready yet\");if(!instance.data.rules)return void vLog(\"No rules added\");let l=instance.data.rules;l.forEach((e=>{e.id===rule_id&&l.splice(l.indexOf(e),1)})),instance.data.rules=l,vLog(`Rule ID ${rule_id} removed`,instance.data.rules),instance.data.appendToConfigState()};"},"fields":{"ACq":{"caption":"Rule ID","name":"rule_id","rank":0,"editor":"DynamicValue","value":"text"}}},"ACr":{"caption":"Generate date occurrences","code":{"fn":"let action=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog,DateTime=luxon.DateTime,browser_timezone=properties.browser_timezone;browser_timezone&&(browser_timezone=Intl.DateTimeFormat().resolvedOptions().timeZone,vLog(\"Using browser timezone\",browser_timezone));let rule_id=properties.rule_id?properties.rule_id.toString():null;if(!instance.data.ready)return void vLog(\"Plugin not ready yet\");let l=instance.data.rules;function publishResults(data){let r;vLog(`Timezone: ${browser_timezone}`),r=browser_timezone?data.rule.all().map((date=>DateTime.fromJSDate(date).toUTC().setZone(browser_timezone).toJSDate())):data.rule.all().map((date=>DateTime.fromJSDate(date).toUTC().setZone(\"local\",{keepLocalTime:!0}).toJSDate())),instance.publishState(\"occurrences\",r),instance.triggerEvent(\"occurrences_loaded\"),vLog(\"Occurrences loaded\",r)}l.length<=0?vLog(\"No rules added\"):rule_id?l.forEach((e=>{e.id===rule_id&&publishResults(e)})):publishResults(l[0])};"},"fields":{"ACs":{"caption":"Gets all date occurrences of dates from a rule","name":"gets_all_occurrences_of_dates_from_a_rule","rank":0,"editor":"Label"},"ACt":{"caption":"Rule ID","name":"rule_id","rank":1,"editor":"DynamicValue","value":"text","optional":true},"ADN":{"caption":"UTC","name":"browser_timezone","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false,"optional":false}}},"ADA":{"caption":"Load configuration","code":{"fn":"function(instance,properties,context){}"},"fields":{"ADB":{"caption":"This action loads a configuration to be used","name":"this_action_loads_a_configuration_to_be_used","rank":0,"editor":"Label"}}},"ADC":{"caption":"Load configuration from iCal","code":{"fn":"function(instance,properties,context){}"},"fields":{"ADE":{"caption":"This action loads an iCal configuration. For example \"DTSTART:20120201T093000Z\\nRRULE:FREQ=WEEKLY;INTERVAL=5;UNTIL=20130130T230000Z;BYDAY=MO,FR\"","name":"this_action_loads_an_ical_configuration.__for_example_\"dtstart:20120201t093000z\\nrrule:freq=weekly;interval=5;until=20130130t230000z;byday=mo,fr\"","rank":0,"editor":"Label"}}},"ADD":{"caption":"Load configuration from human-friendly","code":{"fn":"function(instance,properties,context){}"},"fields":{"ADF":{"caption":"This action loads a human friendly configuration. For example \"every 5 weeks on Monday, Friday until January 31, 2013\"","name":"this_action_loads_a_human_friendly_configuration.__for_example_\"every_5_weeks_on_monday,_friday_until_january_31,_2013\"","rank":0,"editor":"Label"}}},"ADG":{"caption":"Get a slice","code":{"fn":"function(instance,properties,context){}"},"fields":{"ADH":{"caption":"This action gets date occurrences that fall between two dates","name":"this_action_gets_occurances_that_fall_between_two_dates","rank":0,"editor":"Label"}}},"ADO":{"caption":"Reset","code":{"fn":"let action=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog;instance.data.rules=[],instance.data.appendToConfigState(),instance.publishState(\"occurrences\",[]),vLog(\"reset complete\")};"}}},"code":{"preview":{"fn":"function(instance, properties) {\nconst pluginName = 'Recurring Dates';\nconst backgroundImageURL = 'https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1657909891733x252060774418280580/watch-grey.svg';\n\nconst box = $(`<div style=\"font-family: Lato; font-size: 14px; display: flex; align-items: center; justify-content: center; width: 200px; \nheight: 140px; padding: 10px 40px; style=\"text-align: center;\"><div style=\"text-align: center; padding: 10px; background-color: #fff; \nborder-radius:13px; box-shadow: 1px 10px 24px -9px rgba(0,0,0,.50);\"><p style=\"font-weight: 400; color:#000; margin: 0px;\">${pluginName}</p></div></div>`);\n\nbox.css('background-image', `url(${backgroundImageURL})`);\nbox.css('background-repeat', 'repeat');\nbox.css('background-size', '28px 28px');\nbox.css('background-position', 'top');\nbox.css('padding', 0);\nbox.css('height', properties.bubble.height - 0);\nbox.css('width', properties.bubble.width - 0);\n\ninstance.canvas.append(box);\nif (instance.isResponsive) {\n instance.setHeight(properties.bubble.width);\n}\n\n\n\n}"},"initialize":{"fn":"let initialize=function(instance,context){const verboseUser=context.keys[\"Verbose Logging\"];instance.data.vError=function(message,object=\"\",plugin=\"Date & Time Toolkit - Recurrence\"){console.log(`%cð ${plugin} Error`,\"background: #ffb0b0; color: black; display: block; padding:2px\",message,object),context.reportDebugger(`â²ï¸ ${plugin} Error ${message}`)};let vError=instance.data.vError;instance.data.vLog=function(message,object=\"\",plugin=\"Date & Time Toolkit - Recurrence\"){const verbose=(void 0!==verboseUser||\"\"!==verboseUser||null!=verboseUser)&&verboseUser;\"true\"!==verbose&&\"yes\"!==verbose&&!0!==verbose||console.log(`%câ²ï¸ ${plugin} Log`,\"background: #acf2be; color: black; display: block; padding:2px\",message,object)};let vLog=instance.data.vLog,retryEvery=parseInt(context.keys[\"Retry Every (ms)\"]),noRetries=p
170arseInt(context.keys[\"No. of Retries\"]),expDelay=parseInt(context.keys[\"Exponential Delay\"]);function checkScripts(callback,result){vLog(\"Checking for required typeof(s)...\");let allLoaded=[];return\"undefined\"==typeof rrule?(allLoaded.push(!1),vLog(\"ð´ rrule type missing\")):(allLoaded.push(!0),vLog(\"ð¢ rrule typeof found\")),vLog(\"typeof loaded?\",allLoaded),allLoaded.includes(!1)||allLoaded.length<=0?(vLog(\"Retrying typeof check with max 10 retries...\"),callback({message:\"typeof not loaded\",typeof:allLoaded},null)):callback(null,!0)}function initGmap(){vLog(\"All scripts are loaded\"),instance.data.ready=!0,vLog(\"Initialization complete\"),instance.publishState(\"ready\",instance.data.state),instance.triggerEvent(\"ready\");let instanceid=(Math.random()*Math.pow(2,54)).toString(36),div;div=$('<div class=\"rrule\" id=\"rrule_'+instanceid+'\"></div>'),instance.canvas.append(div);let parentDiv=$(div).parent();instance.data.instanceid=instanceid,instance.data.instanceName=`rrule_${instanceid}`,instance.data.currentDiv=div,instance.data.parentDiv=parentDiv,vLog(\"Instance details\",{instanceid:instance.data.instanceid,div:instance.data.div,parentDiv:instance.data.parentDiv}),instance.data.rules=[]}retryEvery=retryEvery>=5?retryEvery:15,noRetries=noRetries>=10?noRetries:15,expDelay=expDelay>=1&&expDelay<=5?expDelay:1,vLog(\"Custom retry settings (if applicable)\",{retryEvery:retryEvery,noRetries:noRetries,expDelay:expDelay}),$(document).ready((function(){vLog(\"Checking requirements...\"),async.retry({times:10,interval:function(retryCount){let t=10*Math.pow(1,retryCount);return vLog(`Retry ${retryCount} (${t}ms)`),t}},checkScripts,(function(err,result){err&&vLog(\"Bubble did not load required typeof(s)! Loading internal requirements...\",err),result&&initGmap()}))}))};"},"update":{"fn":"let update=function(instance,properties,context){let vError=instance.data.vError,vLog=instance.data.vLog;instance.data.getFrequency=function(frequency){let f=frequency.trim().toLowerCase(),r;if(f){switch(f){case\"yearly\":r=rrule.RRule.YEARLY;break;case\"monthly\":r=rrule.RRule.MONTHLY;break;case\"weekly\":r=rrule.RRule.WEEKLY;break;case\"daily\":r=rrule.RRule.DAILY;break;case\"hourly\":r=rrule.RRule.HOURLY;break;case\"minutely\":r=rrule.RRule.MINUTELY;break;case\"secondly\":r=rrule.RRule.SECONDLY;break;default:vError(`${f} is not a valid frequency. Please use one of the following: yearly, monthly, weekly, daily, hourly, minutely, secondly`)}return r}vError(\"No frequency defined. Please use one of the following: yearly, monthly, weekly, daily, hourly, minutely, secondly\")},instance.data.getWeekStartDay=function(weekStartDay){let r;if(isNaN(weekStartDay))switch(weekStartDay){case\"monday\":r=rrule.RRule.MO;break;case\"tuesday\":r=rrule.RRule.TU;break;case\"wednesday\":r=rrule.RRule.WE;break;case\"thursday\":r=rrule.RRule.TH;break;case\"friday\":r=rrule.RRule.FR;break;case\"saturday\":r=rrule.RRule.SA;break;case\"sunday\":r=rrule.RRule.SU}else parseInt(weekStartDay)?r=weekStartDay:vLog(`${weekStartDay} is not a valid week start day. Please use one of the following: 0, 1, 2, 3, 4, 5, 6 or a weekday name`);return r},instance.data.configToRule=function(config){let{RRule:RRule}=rrule,rule=new RRule(config),ical,readable;return{ical:rule.toString(),readable:rule.toText(),rule:rule}},instance.data.remapObj=(obj,param_prefix)=>{if(\"object\"!=typeof obj||obj&&Array.isArray(obj))return{};\"string\"==typeof param_prefix&¶m_prefix&&(\"string\"!=typeof param_prefix||[\"_p_\",\"_api_c2_\"].includes(param_prefix))||(param_prefix=\"_p_\");const convert=(obj,key_parent,is_array)=>{let result={};return Object.keys(obj).forEach((key=>{let cell=obj[key],key_new=`${param_prefix}${key}`;key_parent&&!is_array&&(key_new=`${key_parent}.${key}`),!cell&&0!==cell&&!1!==cell||void 0===cell?result[key_new]=null:\"object\"==typeof cell||Array.isArray(cell)?\"object\"!=typeof cell||Array.isArray(cell)?Array.isArray(cell)&&(\"object\"==typeof cell[0]?(result[key_new]=[],cell.forEach((value=>{result[key_new].push(convert(value,key_new,!0))}))):result[key_new]=cell):result=Object.assign(result,convert(cell,key_new)):result[key_new]=cell})),result};let r=convert(obj);return vLog(\"Remapped object\",r),r},instance.data.appendToConfigState=function(){let configArray=instance.data.rules,exposedState=[];configArray.forEach((e=>{let element={},c=e.config;
170element.id=e.id.toString(),element.configuration=c,element.ical=e.ical,element.readable=e.readable,exposedState.push(instance.data.remapObj(element))})),instance.publishState(\"configurations\",exposedState),instance.triggerEvent(\"configuration_loaded\")}};"},"reset":{"fn":"function(instance,context){let vError=instance.data.vError,vLog=instance.data.vLog;instance.data.rules=[],instance.data.appendToConfigState(),instance.publishState(\"occurrences\",[]),vLog(\"reset complete\")}"}},"platform_type":"web"}},"plugin_actions":{"AAm":{"display":"Convert Decimal to Time","type":"server_side","return_value":{"AAq":{"caption":"Minutes","name":"minutes","rank":0,"value":"number"},"AAr":{"caption":"Hours","name":"hours","rank":1,"value":"number"},"AAs":{"caption":"Days","name":"days","rank":2,"value":"number"},"AAv":{"caption":"Human readable","name":"human_readable","rank":3,"value":"text"}},"fields":{"AAn":{"caption":"This action converts decimal hours notation to readable hours","name":"this_action_converts_decimal_hours_notation_to_readable_hours","rank":1,"editor":"Label"},"AAo":{"caption":"Decimal Hours","name":"decimal_hours","rank":2,"editor":"DynamicValue","value":"number","default_val":0},"ABj":{"caption":"Date & Time Toolkit","name":"date_&_time_toolkit","rank":0,"editor":"Label"}}},"AAw":{"display":"Convert Time to Decimal","type":"server_side","return_value":{"ABC":{"caption":"Output","name":"output","rank":0,"value":"number"}},"fields":{"AAx":{"caption":"This action converts Hours, Minutes & Seconds to decimal notation. For example 1 Hour 30 Mins will become 1.5 Hours","name":"this_action_converts_hours,_minutes_&_seconds_to_decimal_notation.__for_example_1_hour_30_mins_will_become_1.5_hours","rank":1,"editor":"Label"},"AAy":{"caption":"Hours","name":"hours","rank":2,"editor":"DynamicValue","value":"number","default_val":1},"AAz":{"caption":"Minutes","name":"minutes","rank":3,"editor":"DynamicValue","value":"number","default_val":30},"ABA":{"caption":"Seconds","name":"seconds","rank":4,"editor":"DynamicValue","value":"number","default_val":30},"ABB":{"caption":"Precision","name":"precision","rank":5,"editor":"StaticNumber","default_val":4},"ABU":{"caption":"Round to closest","name":"round_to_closest","rank":7,"editor":"DynamicValue","value":"number","default_val":0.25},"ABV":{"caption":"Round Up/Down","name":"round_updown","rank":6,"editor":"Dropdown","default_val":"Don't Round"},"ABi":{"caption":"Date & Time Toolkit","name":"date_&_time_toolkit","rank":0,"editor":"Label"}}},"ABD":{"display":"Next Day of Week","type":"server_side","return_value":{"ABG":{"caption":"Next Date","name":"next_date","rank":0,"value":"date"}},"fields":{"ABE":{"caption":"Day of the week","name":"day_of_the_week","rank":1,"editor":"DynamicValue","value":"number","default_val":5},"ABM":{"caption":"Starting Date ISO","name":"starting_date_iso","rank":2,"editor":"DynamicValue","value":"text"},"ABh":{"caption":"Date & Time Toolkit","name":"date_&_time_toolkit","rank":0,"editor":"Label"}}},"ABN":{"display":"Round Time","type":"server_side","return_value":{"ABQ":{"caption":"Rounded Date","name":"rounded_date","rank":0,"value":"date"}},"fields":{"ABO":{"caption":"Date to round","name":"date_to_round","rank":2,"editor":"DynamicValue","value":"date"},"ABP":{"caption":"Round to X","name":"round_to_x","rank":3,"editor":"DynamicValue","value":"number","default_val":15},"ABR":{"caption":"Round for","name":"round_for","rank":4,"editor":"Dropdown","default_val":"minutes"},"ABS":{"caption":"This action rounds a date/time value to the closest settings below","name":"this_action_rounds_a_date/time_value_to_the_closest_settings_below","rank":1,"editor":"Label"},"ABT":{"caption":"Round to","name":"round_to","rank":5,"editor":"Dropdown","default_val":"ceil"},"ABg":{"caption":"Date & Time Toolkit","name":"date_&_time_toolkit","rank":0,"editor":"Label"}}},"ABW":{"display":"Split Date Ranges","type":"server_side","return_value":{"ABc":{"caption":"Date List","name":"date_list","rank":0,"value":"date","is_list":true},"ABd":{"caption":"Date List Ranges","name":"date_list_ranges","rank":1,"value":"date_range","is_list":true},"ABe":{"caption":"Count","name":"count","rank":2,"value":"number"}},"fields":{"ABX":{"caption":"Day Start","name":"day_start","rank":1,"editor":"DynamicValue","value":"date"},"ABY":{"caption":"Day End","name":"day_end","rank":2,"editor":"DynamicValue","value":"date"},"ABZ":{"caption":"Step Units","name":"step_units","rank":3,"editor":"Dropdown","default_val":"minutes"},"ABa":{"caption":"Steps","name":"steps","rank":4,"editor":"DynamicValue","value":"number","default_val":30},"ABb":{"caption":"Range Option","name":"range_option","rank":5,"editor":"Dropdown","default_val":"Previous Date/Time"},"ABf":{"caption":"Date & Time Toolkit","name":"date_&_time_toolkit","rank":0,"editor":"Label"}}}}}; 171window._bubble_page_load_data.plugins_size['1551365877078x445243110416449540'] = 30796; 172window.preloaded['plugin/third_party:1551365877078x445243110416449540:5.0.0'] = true; 173window.plugins["1553006094610x835866904531566600"] = {"human":"Fuzzy search & Autocomplete","dependencies":{"use_jquery":true},"plugin_elements":{"AAC":{"display":"Fuzzy search & Autocomplete","property_applications":{"MinWidth":true,"resizable":true},"add_is_visible":true,"fields":{"AAD":{"caption":"Data Type","name":"app_data","rank":0,"editor":"custom_type"},"AAE":{"caption":"Data Source","name":"data_source","rank":1,"editor":"DynamicValue","is_list":true,"value":"custom_data_AAD"},"AAF":{"caption":"Field To Search 1","name":"search_field","rank":2,"editor":"custom_field_AAD","optional":false},"AAG":{"caption":"Field To Search 2","name":"search_field_2","rank":3,"editor":"custom_field_AAD","optional":true},"AAH":{"caption":"Field To Search 3","name":"search_field_3","rank":4,"editor":"custom_field_AAD","optional":true},"AAI":{"caption":"Field To Search 4","name":"search_field_4","rank":5,"editor":"custom_field_AAD","optional":true},"AAJ":{"caption":"Field To Search 5","name":"search_field_5","rank":6,"editor":"custom_field_AAD","optional":true},"AAK":{"caption":"Text To Match","name":"string_to_match","rank":7,"editor":"DynamicValue","value":"text","optional":true},"AAL":{"caption":"OR Set Text to Match from an Input Box","name":"search_type","rank":8,"editor":"Checkbox","default_val":false},"AAM":{"caption":"Check for fast updates from an Input Box value. Make sure you set the Input Box ID value below. See documentation for more info.","name":"search_type_info","rank":9,"editor":"Label"},"AAN":{"caption":"Input Box ID","name":"input_box_id","rank":10,"editor":"DynamicValue","optional":true,"value":"text"},"AAO":{"caption":"___ Options ___","name":"options","rank":11,"editor":"Label"},"AAP":{"caption":"Threshold","name":"threshold","rank":12,"editor":"StaticNumber","default_val":0.6},"AAQ":{"caption":"A threshold of 0.0 requires a perfect match (of both letters and location), a threshold of 1.0 would match anything.","name":"threshold_info","rank":13,"editor":"Label"},"AAR":{"caption":"Case Sensitive","name":"case_sensitive","rank":14,"editor":"Checkbox","default_val":false},"AAS":{"caption":"___ Advanced Options ___","name":"advanced_options","rank":15,"editor":"Label"},"AAV":{"caption":"Find All Matches","name":"find_all_matches","rank":16,"editor":"Checkbox","default_val":true},"AAW":{"caption":"Location","name":"location","rank":17,"editor":"StaticNumber","default_val":0},"AAX":{"caption":"Distance","name":"distance","rank":18,"editor":"StaticNumber","default_val":100},"AAZ":{"caption":"Exclude Terms Shorter Than","name":"exclude_under","rank":19,"editor":"StaticNumber","default_val":2}},"states":{"AAa":{"caption":"Matches","name":"match_array","value":"custom_data_AAD","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAb":{"caption":"Match Scores","name":"match_scores_array","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AAc":{"caption":"Input Box's Value","name":"input_box_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"actions":{"AAd":{"caption":"Reset input","code":{"fn":"function(instance,properties,context){instance.data.input_box_id&&
173($(\"#\"+instance.data.input_box_id).val(\"\"),instance.publishState(\"match_array\",null),instance.publishState(\"match_scores_array\",null),instance.publishState(\"input_box_value\",null))}"}}},"code":{"initialize":{"fn":"function(instance,context){function _0x1746(_0x3c82a4,_0x23d1a4){var _0xca773a=_0xca77();return(_0x1746=function(_0x174668,_0x33600b){var _0x111725;return _0xca773a[_0x174668-=201]})(_0x3c82a4,_0x23d1a4)}function _0xca77(){var _0x6cfc1f=[\"resultSearch\",\"322lNHwee\",\"211799Axycof\",\"298nUlWbC\",\"input_box_id\",\"23346xKIPRn\",\"123NRPbXL\",\"Search & Autocorrect: Instance variables not declared\",\"data_source\",\"match\",\"result\",\"input_box_value\",\"push\",\"2711137YdMwIJ\",\"publishState\",\"1016NzFgqn\",\"1738595rHqJZf\",\"dictionary\",\"match_scores_array\",\"data\",\"get\",\"score\",\"input\",\"getResults\",\"options\",\"val\",\"item\",\"6tmDMHh\",\"newID\",\"filter\",\"length\",\"join\",\"3704sOaGeV\",\"ready\",\"log\",\"search_type\",\"163240ttwsqK\"];return(_0xca77=function(){return _0x6cfc1f})()}function initialize(_0x46dd11,_0x184ee1){var _0x5734c7=_0x1746;_0x46dd11.data.resultSearch=[],_0x46dd11[_0x5734c7(216)][_0x5734c7(207)]=\"\",_0x46dd11[_0x5734c7(216)].initialSource=async function(){var _0x504da4=_0x5734c7;try{_0x46dd11[_0x504da4(216)].resultSearch=await _0x46dd11[_0x504da4(216)][_0x504da4(205)][_0x504da4(217)](0,_0x46dd11[_0x504da4(216)][_0x504da4(205)][_0x504da4(227)]()+1),console[_0x504da4(231)](\"The database is loaded!\")}catch(_0x4eda3b){console[_0x504da4(231)](\"The database is not loaded!\")}},_0x46dd11[_0x5734c7(216)][_0x5734c7(220)]=function _0x1bf1c6(){var _0x4a18ea=_0x5734c7;if(_0x46dd11[_0x4a18ea(216)][_0x4a18ea(207)]&&_0x46dd11[_0x4a18ea(216)][_0x4a18ea(207)].length){var _0x133547=[],_0x3cfe7b=[];for(i=0;i<_0x46dd11.data[_0x4a18ea(207)][_0x4a18ea(227)];i++){var _0x534724=_0x46dd11[_0x4a18ea(216)][_0x4a18ea(234)][_0x46dd11[_0x4a18ea(216)][_0x4a18ea(207)][i][_0x4a18ea(223)].id];_0x133547[_0x4a18ea(209)](_0x534724),_0x3cfe7b[_0x4a18ea(209)](_0x46dd11[_0x4a18ea(216)][_0x4a18ea(207)][i][_0x4a18ea(218)])}_0x46dd11[_0x4a18ea(211)](\"match_array\",_0x133547),_0x46dd11.publishState(\"match_scores_array\",_0x3cfe7b)}else _0x46dd11[_0x4a18ea(211)](\"match_array\",null),_0x46dd11.publishState(_0x4a18ea(215),null)},_0x46dd11[_0x5734c7(216)][_0x5734c7(225)]=function(_0x20e38e){var _0x2f72e0=_0x5734c7;_0x46dd11[_0x2f72e0(216)][_0x2f72e0(201)]&&_0x46dd11[_0x2f72e0(216)][_0x2f72e0(232)]&&$(\"#\"+_0x20e38e).on(_0x2f72e0(219),null,null,(function(){var _0x89c9d3=_0x2f72e0;if(_0x46dd11.data.dictionary&&_0x46dd11[_0x89c9d3(216)][_0x89c9d3(221)]){var _0x482147=$(\"#\"+_0x46dd11[_0x89c9d3(216)][_0x89c9d3(201)])[_0x89c9d3(222)]().trim();_0x482147=_0x482147.split(\" \")[_0x89c9d3(226)]((function(_0x33e502){var _0x1742c9=_0x89c9d3;let _0x2a0bbc=/[\\u0000-\\u007f\\u0080-\\u00ff\\u0100-\\u0180\\u024f\\u017f\\u0400-\\u04ff\\u3040-\\u30ff\\u3400-\\u4dbf\\u4e00-\\u9fff\\uf900-\\ufa2d\\uff66-\\uff9f\\u3131-\\uD79D\\u0590-\\u05ff\\u0600â\\u06ff\\u10A0-\\u10ff\\u0530-\\u058f\\u0750-\\u07ff\\u08a0-\\u08ff\\ufa30-\\ufa6a\\ufa70-\\ufad9\\ufb50-\\ufdff\\ufe70-\\ufeff\\u10e60-\\u10e7f\\u1ec70-\\u1ecbf\\u1ed00-\\u1ed4f\\u1ee00-\\u1eeff\\u20000-\\u2a6d6\\u2f800-\\u2fa1d]+/;var _0x21f014=_0x33e502[_0x1742c9(206)](_0x2a0bbc);return _0x21f014&&_0x21f014[0][_0x1742c9(227)]>=_0x46dd11[_0x1742c9(216)].exclude_under}))[_0x89c9d3(228)](\" \");var _0x187ec2=new Fuse(_0x46dd11[_0x89c9d3(216)][_0x89c9d3(214)],_0x46dd11.data[_0x89c9d3(221)]);_0x46dd11.data.result=_0x187ec2.search(_0x482147),_0x46dd11[_0x89c9d3(216)].getResults()}else console.log(_0x89c9d3(204));_0x46dd11.publishState(_0x89c9d3(208),$(\"#\"+_0x46dd11.data[_0x89c9d3(201)]).val())}))},$(document)[_0x5734c7(230)]((function(){var _0x137666=_0x5734c7;_0x46dd11[_0x137666(216)][_0x137666(225)](_0x46dd11[_0x137666(216)][_0x137666(201)])}))}!function(_0x352b1d,_0x24e74a){for(var _0x2ddf7d=_0x1746,_0x1f8e25=_0x352b1d();;)try{var _0xd54484;if(252131===parseInt(_0x2ddf7d(235))/1*(parseInt(_0x2ddf7d(237))/2)+-parseInt(_0x2ddf7d(203))/3*(parseInt(_0x2ddf7d(229))/4)+-parseInt(_0x2ddf7d(213))/5+parseInt(_0x2ddf7d(224))/6*(parseInt(_0x2ddf7d(236))/7)+parseInt(_0x2ddf7d(212))/8*(parseInt(_0x2ddf7d(202))/9)+-parseInt(_0x2ddf7d(233))/10+parseInt(_0x2ddf7d(210))/11)break;_0x1f8e25.push(_0x1f8e25.shift())}catch(_0x17a476){_0x1f8e25.push(_0x1f8e25.shift())}}(_0xca77,252131),initialize(instance,context)}","add_debugger":false},"update":{"fn":"function(instance,properties,context){function _0x1fe0(_0x99e0a1,_0x21a5ca){const _0x32e0d2=_0x32e0();return(_0x1fe0=function(_0x1fe0f6,_0x2a7d53){let _0x59887e;return _0x32e0d2[_0x1fe0f6-=399]})(_0x99e0a1,_0x21a5ca)}
173function update(_0x126c2b,_0x5d6392,_0x4baaa1){const _0x558e4e=_0x1fe0;_0x126c2b[_0x558e4e(422)].data_source=_0x5d6392[_0x558e4e(449)],_0x126c2b[_0x558e4e(422)].initialSource=async function(){const _0x2e6142=_0x558e4e;try{_0x126c2b[_0x2e6142(422)][_0x2e6142(408)]=await _0x126c2b.data[_0x2e6142(449)].get(0,_0x126c2b.data.data_source[_0x2e6142(425)]()+1)}catch(_0xfc3fa2){}},_0x126c2b.data[_0x558e4e(407)]=function _0x408198(){const _0x2134c6=_0x558e4e;if(_0x126c2b[_0x2134c6(422)][_0x2134c6(448)]=_0x5d6392.string_to_match,_0x126c2b[_0x2134c6(422)][_0x2134c6(402)]=[],_0x126c2b.data[_0x2134c6(428)]=_0x5d6392.input_box_id,_0x126c2b[_0x2134c6(422)][_0x2134c6(419)]=_0x5d6392[_0x2134c6(419)],_0x126c2b.data.search_type=_0x5d6392.search_type,_0x126c2b[_0x2134c6(422)][_0x2134c6(413)](_0x5d6392[_0x2134c6(428)]),_0x5d6392[_0x2134c6(449)]){var _0x17e537=_0x126c2b[_0x2134c6(422)][_0x2134c6(449)][_0x2134c6(425)]();_0x126c2b[_0x2134c6(422)].len=_0x17e537}else console[_0x2134c6(432)](\"Search & Autocorrect: Data source not defined\");var _0x367aa=[];if(_0x5d6392[_0x2134c6(426)]&&_0x367aa.push(_0x2134c6(412)),_0x5d6392[_0x2134c6(445)]&&_0x367aa[_0x2134c6(409)](_0x2134c6(415)),_0x5d6392[_0x2134c6(399)]&&_0x367aa.push(_0x2134c6(417)),_0x5d6392[_0x2134c6(416)]&&_0x367aa[_0x2134c6(409)](\"word4\"),_0x5d6392[_0x2134c6(435)]&&_0x367aa[_0x2134c6(409)](_0x2134c6(404)),_0x126c2b[_0x2134c6(422)].makearray=function _0x10fd14(){const _0x48f43c=_0x2134c6;for(let _0x45167b=0;_0x45167b<_0x17e537;_0x45167b++){let _0x353f7e=_0x126c2b[_0x48f43c(422)].data_source[_0x48f43c(423)](0,_0x17e537)[_0x45167b],_0x4dca04={id:_0x45167b,word1:_0x5d6392.search_field?_0x353f7e.get(_0x5d6392[_0x48f43c(426)]):_0x48f43c(450),word2:_0x5d6392[_0x48f43c(445)]?_0x353f7e[_0x48f43c(423)](_0x5d6392[_0x48f43c(445)]):_0x48f43c(450),word3:_0x5d6392[_0x48f43c(399)]?_0x353f7e[_0x48f43c(423)](_0x5d6392.search_field_3):_0x48f43c(450),word4:_0x5d6392[_0x48f43c(416)]?_0x353f7e[_0x48f43c(423)](_0x5d6392[_0x48f43c(416)]):_0x48f43c(450),word5:_0x5d6392.search_field_5?_0x353f7e[_0x48f43c(423)](_0x5d6392[_0x48f43c(435)]):_0x48f43c(450)};_0x126c2b[_0x48f43c(422)].dictionary[_0x48f43c(409)](_0x4dca04)}},_0x126c2b[_0x2134c6(422)].data_source&&_0x126c2b.data[_0x2134c6(441)](),_0x126c2b[_0x2134c6(422)][_0x2134c6(444)]={shouldSort:!0,includeScore:!0,threshold:_0x5d6392[_0x2134c6(446)],isCaseSensitive:_0x5d6392[_0x2134c6(410)],location:_0x5d6392.location,distance:_0x5d6392[_0x2134c6(437)],findAllMatches:_0x5d6392[_0x2134c6(420)],keys:_0x367aa,ignoreFieldNorm:!1},_0x126c2b[_0x2134c6(422)][_0x2134c6(406)]=function _0x3f72c3(){const _0x47bd78=_0x2134c6;if(_0x126c2b[_0x47bd78(422)][_0x47bd78(400)]&&_0x126c2b[_0x47bd78(422)].result.length){var _0x4a61a6=[],_0x4d656c=[];for(let _0x40fde1=0;_0x40fde1<_0x126c2b[_0x47bd78(422)][_0x47bd78(400)][_0x47bd78(425)];_0x40fde1++){let _0x171b2a=_0x126c2b[_0x47bd78(422)][_0x47bd78(408)][_0x126c2b[_0x47bd78(422)].result[_0x40fde1][_0x47bd78(427)].id];_0x4a61a6[_0x47bd78(409)](_0x171b2a),_0x4d656c[_0x47bd78(409)](_0x126c2b[_0x47bd78(422)][_0x47bd78(400)][_0x40fde1][_0x47bd78(447)])}_0x126c2b[_0x47bd78(430)](_0x47bd78(421),_0x4a61a6),_0x126c2b[_0x47bd78(430)](\"match_scores_array\",_0x4d656c)}else _0x126c2b[_0x47bd78(430)](_0x47bd78(421),null),_0x126c2b.publishState(_0x47bd78(443),null)},!_0x5d6392[_0x2134c6(424)]&&_0x5d6392[_0x2134c6(448)]){var _0x32cb13=_0x5d6392[_0x2134c6(448)].trim();_0x32cb13=_0x32cb13[_0x2134c6(439)](\" \")[_0x2134c6(442)]((function(_0x23ba6f){const _0x58fcd5=_0x2134c6;let _0x1c6b29=/[\\u0000-\\u007f\\u0080-\\u00ff\\u0100-\\u0180\\u024f\\u017f\\u0400-\\u04ff\\u3040-\\u30ff\\u3400-\\u4dbf\\u4e00-\\u9fff\\uf900-\\ufa2d\\uff66-\\uff9f\\u3131-\\uD79D\\u0590-\\u05ff\\u0600â\\u06ff\\u10A0-\\u10ff\\u0530-\\u058f\\u0750-\\u07ff\\u08a0-\\u08ff\\ufa30-\\ufa6a\\ufa70-\\ufad9\\ufb50-\\ufdff\\ufe70-\\ufeff\\u10e60-\\u10e7f\\u1ec70-\\u1ecbf\\u1ed00-\\u1ed4f\\u1ee00-\\u1eeff\\u20000-\\u2a6d6\\u2f800-\\u2fa1d]+/,_0x589718=_0x23ba6f[_0x58fcd5(411)](_0x1c6b29);return _0x589718&&_0x589718[0][_0x58fcd5(425)]>=_0x126c2b[_0x58fcd5(422)][_0x58fcd5(419)]}))[_0x2134c6(440)](\" \");var _0xd7df89=new Fuse(_0x126c2b[_0x2134c6(422)][_0x2134c6(402)],_0x126c2b[_0x2134c6(422)][_0x2134c6(444)]);_0x126c2b[_0x2134c6(422)].result=_0xd7df89[_0x2134c6(418)](_0x32cb13),_0x126c2b[_0x2134c6(422)][_0x2134c6(406)]()}else!_0x5d6392.search_type&&!_0x5d6392.string_to_match&&(_0x126c2b[_0x2134c6(430)](_0x2134c6(421),null),_0x126c2b.publishState(_0x2134c6(443),null))},_0x126c2b[_0x558e4e(422)].initialSource().then((()=>{const _0x22ea6e=undefined;_0x126c2b[_0x558e4e(422)].loadFuzzy()}))[_0x558e4e(433)]((_0x429b4f=>{}))}function _0x32e0(){const _0x37d97d=[\"filter\",\"match_scores_array\",\"options\",\"search_field_2\",\"threshold\",\"score\",\"string_to_match\",\"data_source\",\"Empty\",\"1735401LWYgdE\",\"search_field_3\",\"result\",\"2wRQkhp\",\"dictionary\",\"5BrUIwf\",\"word5\",\"5879150eKoDFK\",\"getResults\",\"loadFuzzy\",\"resultSearch\",\"push\",\"case_sensitive\",\"match\",\"word1\",\"newID\",\"1149135QIgZjc\",\"word2\",\"search_field_4\",\"word3\",\"search\",\"exclude_under\",\"find_all_matches\",\"match_array\",\"data\",\"get\",\"search_type\",\"length\",\"search_field\",\"item\",\"
173input_box_id\",\"9192Codnus\",\"publishState\",\"39280TbwgiI\",\"log\",\"catch\",\"7525896CPnYKU\",\"search_field_5\",\"2797494CedUCD\",\"distance\",\"7137GinBVq\",\"split\",\"join\",\"makearray\"];return(_0x32e0=function(){return _0x37d97d})()}!function(_0x2d2f26,_0x47abbb){const _0x16e549=_0x1fe0,_0x320a8f=_0x2d2f26();for(;;)try{const _0x9ef0ce=undefined;if(622793===parseInt(_0x16e549(414))/1+-parseInt(_0x16e549(401))/2*(parseInt(_0x16e549(451))/3)+parseInt(_0x16e549(431))/4*(parseInt(_0x16e549(403))/5)+parseInt(_0x16e549(436))/6+parseInt(_0x16e549(434))/7+-parseInt(_0x16e549(429))/8*(parseInt(_0x16e549(438))/9)+-parseInt(_0x16e549(405))/10)break;_0x320a8f.push(_0x320a8f.shift())}catch(_0x1c662){_0x320a8f.push(_0x320a8f.shift())}}(_0x32e0,622793),update(instance,properties,context)}","add_debugger":false},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":""}},"platform_type":"web"}}}; 174window._bubble_page_load_data.plugins_size['1553006094610x835866904531566600'] = 13981; 175window.preloaded['plugin/third_party:1553006094610x835866904531566600:1.38.0'] = true; 176window.plugins["1553183744528x903111989944909800"] = {"human":"Premium Charts Bundle - Chart JS","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"Chart - Bar/Line/Area","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AAJ":{"caption":"X-Axis Values","default_val":"Mon, Tue, Wed, Thu, Fri","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":3,"value":"text"},"AAK":{"caption":"Series 1 - y-values","default_val":"120, 260, 240, 310, 330","editor":"DynamicValue","name":"series1","rank":7,"value":"text","optional":false},"AAL":{"caption":"Series 2 - y-values","editor":"DynamicValue","is_list":false,"name":"series2","optional":true,"rank":10,"value":"text","default_val":"200, 210, 190, 240, 230"},"AAM":{"caption":"Series 3 - y-values","editor":"DynamicValue","name":"series3","optional":true,"rank":13,"value":"text","default_val":""},"AAN":{"caption":"Series 1 - color","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series1color","rank":6},"AAO":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":5,"value":"text","optional":true},"AAP":{"caption":"Chart Type","default_val":"Bar","editor":"Dropdown","name":"chartType","rank":0},"AAQ":{"caption":"Series 2 - name","default_val":"Series 2","editor":"DynamicValue","name":"series2name","rank":8,"value":"text","optional":true},"AAR":{"caption":"Series 2 - color","default_val":"rgba(235, 235, 235, 1)","editor":"Color","name":"series2color","rank":9},"AAY":{"caption":"Series 3 - name","default_val":"Series 3","editor":"DynamicValue","name":"series3name","rank":11,"value":"text","optional":true},"AAZ":{"caption":"Series 3 color","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":12},"AAa":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":38,"value":"text"},"AAb":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":39,"value":"text"},"AAe":{"caption":"Y Axis - Max (Optional)","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":37,"value":"number"},"AAf":{"caption":"Y Axis - Min (Optional)","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":36,"value":"number"},"AAj":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":25,"value":"text","default_val":"Top"},"ABC":{"caption":"Series 4 - name","default_val":"Series 4","editor":"DynamicValue","name":"series4name","optional":true,"rank":14,"value":"text"},"ABD":{"caption":"Series 4 color","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":15},"ABE":{"caption":"Series 4 - y-values","editor":"DynamicValue","name":"series4","optional":true,"rank":16,"value":"text"},"ABF":{"caption":"Series 5 - name","default_val":"Series 5","editor":"DynamicValue","name":"series5name","optional":true,"rank":17,"value":"text"},"ABG":{"caption":"Series 5 - color","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":18},"ABH":{"caption":"Series 5 - y-values","editor":"DynamicValue","name":"series5","optional":true,"rank":19,"value":"text"},"ABI":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":60,"value":"boolean"},"ABQ":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":41,"editor":"DynamicValue","value":"boolean","default_val":true},"ABR":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":40,"editor":"DynamicValue","value":"boolean","default_val":true},"ACE":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":35,"editor":"Label"},"ACG":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_main_fields_-------------------","rank":1,"editor":"Label"},"ACH":{"caption":"X = Zero Line Width","name":"x_zero_line_width","rank":54,"editor":"DynamicValue","value":"number","default_val":1},"ACI":{"caption":"Y = Zero Line Width","name":"y_zero_line_width","rank":55,"editor":"DynamicValue","value":"number","default_val":1},"ACK":{"caption":"X = Zero Line Color","name":"x_zero_line_color","rank":56,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ACL":{"caption":"Y = Zero Line Color","name":"y_zero_line_color","rank":57,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ACM":{"caption":"Vert. Gridlines Color","name":"vert_gridlines_color","rank":51,"editor":"Color","default_val":"rgba(255, 255, 255, 0)"},"ACN":{"caption":"Horiz. Gridlines Color","name":"horiz_gridlines_color","rank":50,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ACW":{"caption":"Line Width","name":"border_width","rank":74,"editor":"DynamicValue","value":"number","default_val":3},"ACX":{"caption":"Line Curve","name":"curve_line_charts","rank":78,"editor":"DynamicValue","value":"number","default_val":0.3},"ACg":{"caption":"Unit Before the Label","name":"data_labels_unit_before","rank":65,"editor":"DynamicValue","value":"text","optional":true},"ACh":{"caption":"Unit After the Label","name":"data_labels_unit_after","rank":66,"editor":"DynamicValue","value":"text","optional":true},"ACi":{"caption":"Point Radius","name":"line_point_radius","rank":76,"editor":"DynamicValue","value":"number","default_val":5},"ACj":{"caption":"Thousands Separator","name":"thousands_separator","rank":31,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"ACz":{"caption":"Horiz. Dash Gridlines","name":"horizontal_dashed_gridlines","rank":52,"editor":"DynamicValue","value":"boolean","default_val":true}
176,"ADA":{"caption":"Vert. Dash Gridlines","name":"vertical_dashed_gridlines","rank":53,"editor":"DynamicValue","value":"boolean","default_val":false},"ADC":{"caption":"------------------------------ Data Labels ----------------------------","name":"---------------------------_data_labels_---------------------------","rank":59,"editor":"Label"},"ADD":{"caption":"Vertical Offset","name":"datalabel_offset","rank":64,"editor":"DynamicValue","value":"number","default_val":3},"ADE":{"caption":"Label Backgrnd Color","name":"datalabel_background_color","rank":67,"editor":"Color","default_val":"rgba(255, 255, 255, 0.32)","optional":false},"ADF":{"caption":"Font Color (Optional)","name":"datalabel_font_color","rank":70,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"ADG":{"caption":"Font Color Setting","name":"font_color_setting","rank":69,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"ADH":{"caption":"Anchor","name":"datalabel_anchor","rank":61,"editor":"Dropdown","default_val":"end"},"ADU":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":27,"editor":"DynamicValue","value":"text","optional":true},"ADb":{"caption":"Font Size","name":"datalabel_size","rank":71,"editor":"DynamicValue","value":"number","default_val":12},"AFw":{"caption":"Series 6 - name","name":"series6name","rank":20,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 6"},"AFx":{"caption":"Series 6 - color","name":"series6color","rank":21,"editor":"Color","default_val":"rgba(59, 227, 129, 1)","optional":true},"AFy":{"caption":"Series 6 - y-values","name":"series6","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AGI":{"caption":"-------------------- Line/Area Chart Settings ---------------------","name":"---------------------------Line---------------------------","rank":73,"editor":"Label"},"AGJ":{"caption":"------------------------- Bar Chart Settings ------------------------","name":"-------------------------_barchart_settings_-------------------------","rank":81,"editor":"Label"},"AGK":{"caption":"Bar Width (Bar)","name":"bar_width","rank":82,"editor":"DynamicValue","value":"number","default_val":0.5},"AGO":{"caption":"Category Width (Bar)","name":"category_width","rank":85,"editor":"DynamicValue","value":"number","default_val":0.5},"AHw":{"caption":"Animation Duration","name":"animation_duration","rank":28,"editor":"DynamicValue","value":"number","default_val":1500},"AHx":{"caption":"Point Hover Radius","name":"point_hover_radius","rank":75,"editor":"DynamicValue","value":"number","default_val":12},"AHy":{"caption":"Point Border Width","name":"point_border_width","rank":77,"editor":"DynamicValue","value":"number","default_val":3},"AIR":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":44,"editor":"DynamicValue","value":"number","default_val":11},"AIS":{"caption":"Max X Ticks","name":"max_x_ticks","rank":43,"editor":"DynamicValue","value":"number","default_val":11},"AKc":{"caption":"Bar Width (px)","name":"bar_width_pixels","rank":83,"editor":"DynamicValue","value":"text","optional":true},"AKe":{"caption":"Chart Padding (px)","name":"chart_padding","rank":30,"editor":"DynamicValue","value":"number","default_val":10},"AKs":{"caption":"Bar Corner Radius","name":"bar_corner_radius","rank":84,"editor":"DynamicValue","value":"number","default_val":0},"AQQ":{"caption":"Y Axis - Tick Length","name":"tick_mark_length_y","rank":42,"editor":"DynamicValue","value":"number","default_val":"0"},"AQS":{"caption":"Label Border Color","name":"label_border_color","rank":68,"editor":"Color","default_val":"rgba(240, 240, 240, 0)"},"AQn":{"caption":"â¹ï¸ To customize Tick Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties. Please avoid using âApp Fontsâ (in other words, please select the exact font you want to use from the font menu)","name":"to_customize_the_axis_tick_label_font_style,_color,_and_size,_edit_this_element's_font_style,_color,_size_as_you_would_for_a_text_element_(by_scrolling_down_to_the_bottom_of_this_menu_and_editing_the_standard_bubble_properties)","rank":49,"editor":"Label"},"ARA":{"caption":"Draggable Values?","name":"draggable_values","rank":33,"editor":"DynamicValue","value":"boolean","default_val":false},"ARB":{"caption":"Drag Data Rounded","name":"drag_data_round","rank":34,"editor":"DynamicValue","value":"number","default_val":2},"ARP":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"-----_(you_can_also_add_infinite_series_via_w
176orkflows)_-----","rank":23,"editor":"Label"},"AVf":{"caption":"Tick Label Color","name":"tick_label_color","rank":46,"editor":"Color","default_val":"rgba(174, 185, 194, 1)","in_style":true},"AVg":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":47,"editor":"DynamicValue","value":"number","default_val":12},"AWD":{"caption":"Span Gaps?","name":"span_gaps","rank":79,"editor":"DynamicValue","value":"boolean","default_val":false},"AWM":{"caption":"X Tick Label Rotation","name":"x_ticks_rotation","rank":45,"editor":"DynamicValue","value":"number","optional":true},"AWk":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":62,"editor":"DynamicValue","value":"boolean","default_val":false},"AWr":{"caption":"Hide if Less Than","name":"hide_if_less_than","rank":63,"editor":"DynamicValue","value":"number","optional":true},"AWt":{"caption":"Decimal Place Char.","name":"decimal_place_character","rank":32,"editor":"DynamicValue","value":"text","default_val":"."},"AXn":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":24,"editor":"Label"},"AXo":{"caption":"â¹ï¸ Add series names, colors, and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"----------------------------_series_colors_----------------------------","rank":4,"editor":"Label"},"AXp":{"caption":"â¹ï¸ Enter you chart's X-Axis values (the X-Axis labels that will go from left to right) separated by comma and space (\", \"). Can be a dynamic expression.","name":"â¹ï¸_add_series_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_(\",_\")._you_can_dynamically_search_your_bubble_database_to_get_these_comma-separated_lists_(\"do_a_search_for...\")","rank":2,"editor":"Label"},"AXr":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"if_your_data_points_are_getting_cut_off_near_the_edges_of_the_chart_element,_increase_this_number","rank":29,"editor":"Label"},"AXs":{"caption":"â¹ï¸ For extra styling options (Area gradient, point border color, point images), add the data series using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_for_extra_styling_options_(area_gradient,_point_border_color,_point_images)_add_the_data_series_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":80,"editor":"Label"},"AXt":{"caption":"â¹ï¸ For extra styling options (Bar gradient, different color bars in a single series), add the data series using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_for_extra_styling_options_(area_gradient,_point_border_color,_point_images),_add_the_data_series_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":93,"editor":"Label"},"AYM":{"caption":"yLabels Decimal Places","name":"y_labels_decimal_places","rank":58,"editor":"DynamicValue","value":"number","optional":true},"AZY":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":72,"editor":"Dropdown","default_val":" 400"},"AZc":{"caption":"Legend Color Style","name":"legend_color_style","rank":26,"editor":"Dropdown","default_val":"Circle"},"Asm":{"caption":"------------------ Chart and Axes Titles (BETA) -----------------","name":"chart_and_axes_titles","rank":94,"editor":"Label"},"Asn":{"caption":"Chart Title","name":"chart_title","rank":95,"editor":"DynamicValue","value":"text","optional":true},"Aso":{"caption":"Chart Title Font Size","name":"chart_title_font_size","rank":96,"editor":"DynamicValue","value":"number","optional":true,"default_val":16},"Asp":{"caption":"Chart Title Font Color","name":"chart_title_font_color","rank":97,"editor":"Color","default_val":"rgba(210,210,210,1)","optional":true},"Asq":{"caption":"X Axis Name","name":"x_axis_name","rank":98,"editor":"DynamicValue","value":"text","optional":true},"Asr":{"caption":"X Axis Name: Font Size","name":"x_axis_name_font_size","rank":99,"editor":"DynamicValue","value":"number","default_val":14,"optional":false},"Ass":{"caption":"X Axis Name: Font Color","name":"x_axis_name_font_color","rank":100,"editor":"Color","default_val":"rgba(210, 210, 210, 1)","optional":true},"Ast":{"caption":"Y Axis Name","name":"y_axis_name","rank":101,"editor":"DynamicValue","value":"text","optional":true},"Asu":{"caption":"Y Axis Name: Font Size","name":"y_axis_name:_font_size","rank":102,"editor":"DynamicValue","value":"number","default_val":14},"Asv":{"caption":"Y Axis Name: Font Color","name":"y_axis_name:_font_color","rank":103,"editor":"Color","default_val":"rgba(210, 210, 210, 1)","optional":true},"AtR":{"caption":"Series 1 - Border","name":"series_1_border","rank":87,"editor":"Color","optional":true},"AtS":{"caption":"Series 2 - Border","name":"series_2_border","rank":88,"editor":"Color","optional":true},"AtT":{"caption":"Series 3 - Border","name":"series_3_border","rank":89,"editor":"Color","optional":true},"AtU":{"caption":"Series 4 - Border","name":"series_4_border","rank":90,"editor":"Color","optional":true},"AtV":{"caption":"Series 5 - Border","name":"series_5_border","rank":91,"editor":"Color","optional":true},"AtW":{"caption":"Series 6 - Border","name":"series_6_border","rank":92,"editor":"Color","optional":true},"AtX":{"caption":"Bar Border Width","name":"bar_border_width","rank":86,"editor":"DynamicValue","value":"number","optional":false,"default_val":0},"AyH":{"caption":"Max # Char Per Line","name":"max_num_char_per_line","rank":48,"editor":"DynamicValue","value":"number","optional":true}},"states":{"AAv":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"ABU":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ABV":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ADQ":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ADR":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADS":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ADV":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFz":{"caption":"Clicked Item Series Color","name":"clicked_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AGB":{"caption":"Clicked Item All Series Values","name":"click_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGC":{"caption":"Clicked Item All Series Colors","name":"clicked_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGD":{"caption":"Clicked Item All Series Names","name":"clicked_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGE":{"caption":"Hovered Item All Series Values","name":"hovered_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGF":{"caption":"Hovered Item All Series Colors","name":"hovered_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGG":{"caption":"Hovered Item All Series Names","name":"hovered_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AGH":{"caption":"Chart Loaded?","name":"chart_loaded","value":"boolean","initialization_code":{"fn":"function(properties,context){return!1}"}}
176,"AKq":{"caption":"Hovered Item X Index","name":"hovered_item_x_index","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AQv":{"caption":"Dragged Item Data Series Name","name":"dragged_item_data_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQw":{"caption":"Dragged Item Index Number","name":"dragged_item_index_number","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AQx":{"caption":"Dragged Item - X Value","name":"dragged_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQy":{"caption":"Dragged Value - Starting Value","name":"dragged_item_starting_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AQz":{"caption":"Dragged Value - Ending Value","name":"dragged_item_ending_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AWA":{"caption":"Dragged Item - All of this Series' Y Values","name":"dragged_item_all_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AWh":{"caption":"Currently Dragging Bar/Value","name":"currently_dragging","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ACn":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"ADT":{"caption":"Chart Value Hovered","name":"chart_value_hovered"},"AQu":{"caption":"Chart Value Dragged","name":"chart_value_dragged"}},"actions":{"ABr":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){instance.publishState(\"chart_loaded\",!1);let numAttempts=0;function mainAddSeries(){if(numAttempts>15)return void console.log(\"The Chart you are trying to update is not visible on the page\");if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);let customChartType=instance.data.chartType,backgroundColors,pointImage;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType,properties.point_color_line,properties.point_border_color_line,backgroundColors,pointImage,properties.chart_type,properties.bar_outline_color),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}if(properties.background_colors&&(backgroundColors=instance.data.createDataArray(properties.background_colors)),null!=properties.chart_type&&(properties.chart_type.toLowerCase()!=instance.data.chartType&&(customChartType=properties.chart_type.toLowerCase()),\"area\"==customChartType&&(customChartType=\"line\")),pointImage=properties.point_style,properties.use_image_as_point&&(pointImage=new Image(1,1),pointImage.src=properties.use_image_as_point,pointImage.onload=function(){var width=pointImage.naturalWidth,height=pointImage.naturalHeight;pointImage.width=width*properties.image_scale,pointImage.height=height*properties.image_scale}),addSeries(),\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain||\"Bar\"==properties.chart_type||\"Bar\"==instance.data.originalChartTypeMain){let mycanvas;var chart_gradient=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\").createLinearGradient(0,0,0,instance.data.height);(\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain&&\"Bar\"!=properties.chart_type)&&(chart_gradient.addColorStop(0,properties.area_chart_start_color),chart_gradient.addColorStop(.5,properties.area_chart_middle_color),chart_gradient.addColorStop(1,properties.area_chart_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),(\"Bar\"==properties.chart_type&&!properties.background_colors||\"Bar\"==instance.data.originalChartTypeMain&&\"Area\"!=properties.chart_type&&!properties.background_colors)&&properties.bar_gradient&&(chart_gradient.addColorStop(0,properties.bar_gradient_start_color),chart_gradient.addColorStop(.6,properties.bar_gradient_middle_color),chart_gradient.addColorStop(1,properties.bar_gradient_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),instance.data.chart.update(
176)}}mainAddSeries(),instance.publishState(\"chart_loaded\",!0)}"},"fields":{"ABu":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"ABv":{"caption":"Series Color","name":"series_color","rank":4,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ABw":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"ACP":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true},"AQo":{"caption":"Point Color","name":"point_color_line","rank":6,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","optional":true},"AQp":{"caption":"Point Border Color","name":"point_border_color_line","rank":7,"editor":"Color","default_val":"rgba(51, 181, 229, 1)","optional":true},"ARQ":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"ARR":{"caption":"-------------------- Line/Area Series Settings --------------------","name":"-------------------------_line_chart_settings_------------------------","rank":5,"editor":"Label"},"ARY":{"caption":"Multi-Colored Series (comma-separated hex codes)","name":"background_colors","rank":22,"editor":"DynamicValue","value":"text","optional":true},"ARZ":{"caption":"-------------------------- Bar Series Settings -----------------------","name":"--------------------------_bar_chart_settings_-----------------------","rank":16,"editor":"Label"},"AWG":{"caption":" ","name":"use_image_as_point","rank":13,"editor":"DynamicValue","value":"image","optional":true},"AWH":{"caption":"Image Point Scale","name":"image_scale","rank":14,"editor":"DynamicValue","value":"number","optional":false,"default_val":1},"AWP":{"caption":"Gradient Start Color","name":"area_chart_start_color","rank":8,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AWQ":{"caption":"Gradient End Color","name":"area_chart_end_color","rank":10,"editor":"Color","default_val":"rgba(51, 181, 229, 0)"},"AWR":{"caption":"Use Image as Point. Below you can upload an image (or use dynamic one) to set the image instead of having a circle for line chart points","name":"use_image_as_point.__below_you_can_upload_an_image_(or_use_dynamic_one)_to_set_the_","rank":12,"editor":"Label"},"AWV":{"caption":" ","name":"_","rank":15,"editor":"Label"},"AWW":{"caption":"Gradient Middle Color","name":"area_chart_middle_color","rank":9,"editor":"Color","default_val":"rgba(51, 179, 230, 0.58)"},"AXg":{"caption":"The field below is optional: for multi-colored series (overrides colors set above)","name":"info","rank":21,"editor":"Label"},"AXh":{"caption":"Gradient Start Color","name":"bar_gradient_start_color","rank":18,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AXi":{"caption":"Gradient End Color","name":"bar_gradient_end_color","rank":20,"editor":"Color","default_val":"rgba(51,181,229,0.1)"},"AXj":{"caption":"Bar Gradient Middle Color","name":"bar_gradient_middle_color","rank":19,"editor":"Color","default_val":"rgba(51,179,230,0.5)"},"AXk":{"caption":"Bar Gradient?","name":"bar_gradient","rank":17,"editor":"Checkbox","default_val":false},"AYS":{"caption":"Point Style","name":"point_style","rank":11,"editor":"Dropdown","default_val":"circle"}}},"ABs":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"},"fields":{"ABt":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AON":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update(
176)}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"}},"AsG":{"caption":"Add Annotation","code":{"fn":"function(instance,properties,context){var newAnnotation;\"vertical\"==properties.type?newAnnotation={type:\"line\",mode:\"vertical\",scaleID:\"x-axis-0\",value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"horizontal\"==properties.type?newAnnotation={type:\"line\",mode:\"horizontal\",scaleID:\"y\",value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"box\"==properties.type&&(newAnnotation={type:\"box\",xMin:1,xMax:2,yMin:1,yMax:2,backgroundColor:properties.background_color,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}),instance.data.chart.options.annotation||(instance.data.chart.options.annotation={annotations:[]}),instance.data.chart.options.annotation.annotations.push(newAnnotation),console.log(instance.data.chart),instance.data.chart.update()}"},"fields":{"AsH":{"caption":"Type","name":"type","rank":0,"editor":"Dropdown","default_val":"horizontal"},"AsI":{"caption":"----------------------- General Settings -----------------------","name":"information","rank":1,"editor":"Label"},"AsJ":{"caption":"-------------- Vertical/Horizontal Annotations --------------","name":"vertical/horizontal_settings","rank":8,"editor":"Label"},"AsK":{"caption":"------------------- Box Annotations (in beta) -------------------","name":"box_settings (ignore if type=vertical or horizontal)","rank":11,"editor":"Label"},"AsL":{"caption":"Value","name":"value","rank":9,"editor":"DynamicValue","value":"text","optional":true},"AsM":{"caption":"Label text","name":"label","rank":2,"editor":"DynamicValue","value":"text","default_val":""},"AsN":{"caption":"Line Color","name":"line_color","rank":3,"editor":"Color","default_val":"rgba(150,162,164,1)"},"AsO":{"caption":"Background color","name":"background_color","rank":12,"editor":"Color","default_val":"rgba(220,223,224,1)"},"AsP":{"caption":"Y Min","name":"y_min","rank":13,"editor":"DynamicValue","value":"number","optional":true},"AsQ":{"caption":"Y Max","name":"y_max","rank":14,"editor":"DynamicValue","value":"number","optional":true},"AsR":{"caption":"X Min","name":"x_min","rank":15,"editor":"DynamicValue","value":"number","optional":true},"AsS":{"caption":"X Max","name":"x_max","rank":16,"editor":"DynamicValue","value":"number","optional":true},"AsT":{"caption":"Border Width","name":"border_width","rank":10,"editor":"DynamicValue","value":"number","default_val":2},"AsU":{"caption":"Position: X Offset","name":"x_offset","rank":6,"editor":"DynamicValue","value":"number","default_val":0},"AsV":{"caption":"Position: Y Offset","name":"y_offset","rank":7,"editor":"DynamicValue","value":"number","default_val":0},"AsW":{"caption":"Position: Alignment","name":"alignment","rank":5,"editor":"Dropdown","default_val":"start"},"AsX":{"caption":"Position","name":"position","rank":4,"editor":"Dropdown","default_val":"top"}}}},"code":{"initialize":{"fn":"function(instance,context){instance.publishState(\"chart_loaded\",!1),instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function reduceOpacity(originalRGBAColor,scale){if(originalRGBAColor||(console.warn(\"Color is undefined. Using default color.\"),originalRGBAColor=\"rgba(0, 0, 0, 1)\"),6===originalRGBAColor.length||7===originalRGBAColor.length){const hexToRgb=undefined;originalRGBAColor=(hex=>{const result=/^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);return result?`rgba(${parseInt(result[1],16)}, ${parseInt(result[2],16)}, ${parseInt(result[3],16)}, 1)`:(console.error(\"Invalid hex color:\",hex),\"rgba(0, 0, 0, 1)\")})(originalRGBAColor)}if(!/^rgba/.test(originalRGBAColor))return console.error(\"Unsupported color format:\",originalRGBAColor),\"rgba(0, 0, 0, 1)\";const rgbaParts=originalRGBAColor.match(/rgba?\\(([^)]+)\\)/)[1].split(\",\").map(Number),[r,g,b,a=1]=rgbaParts;return`rgba(${r}, ${g}, ${b}, ${a*scale})`}function updateChartDatasets(){let i;for(instance.data.chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)instance.data.chart.data.datasets.push(instance.data.datasets[i]),instance.data.chartType.includes(\"Area\")&&(instance.data.datasets[i].backgroundColor=instance.data.reduceOpacity(instance.data.datasets[i].borderColor,.5),instance.data.datasets[i].fill=\"origin\"),instance.data.chartType.includes(\"Line\")&&(instance.data.datasets[i].fill=!1)}function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[],instance.data.reduceOpacity=reduceOpacity,instance.data.updateChartDatasets=updateChartDatasets,setTimeout(forceUpdate,200)}","add_debugger":false},"update":{"fn":"function(instance,properties,context){if(Chart.plugins.unregister(ChartDataLabels),instance.data.justDragged)return void(instance.data.justDAragged=!1);
176if(null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height(),divWidth=$(\"#\"+properties.custom_tooltip_id).width(),xOffset=15,yOffset=divHeight/2;e.clientX+xOffset+divWidth>screen.width&&(xOffset=-1*(25+divWidth),0>e.clientX-(divWidth+25)&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=-15),screen.height<divHeight+e.clientY&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=divHeight+15)),e.clientY-divHeight/2<0&&(yOffset=0),$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+xOffset,top:e.clientY-yOffset,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId);instance.data.mainChartCanvas=chartcanvas;var ctxchart=chartcanvas.getContext(\"2d\");let chartType,legendState,showLegend;function createDataArray(xString){if(!xString)return null;const spanGaps=properties.span_gaps,chartType=properties.chartType,isLineChart=[\"Area\",\"Line\",\"Stepped Line (Step Before)\",\"Stepped Line (Step After)\"].includes(chartType),xArray=undefined;return xString.split(\",\").map((item=>{const trimmedItem=item.trim();return spanGaps&&isLineChart&&!trimmedItem?null:trimmedItem}))}instance.data.originalChartTypeMain=properties.chartType,chartType=properties.chartType.toLowerCase(),\"Horizontal Bar\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"100% Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Area\"==properties.chartType&&(chartType=\"line\"),\"Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"Overlapped Bar (Vertical)\"==properties.chartType&&(chartType=\"bar\"),\"100% Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"100% Stacked Area (Vertical)\"==properties.chartType&&(chartType=\"line\"),\"Stacked Area\"==properties.chartType&&(chartType=\"line\"),\"Stepped Line (Step Before)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"before\"),\"Stepped Line (Step After)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"after\"),\"Stepped Area (Step Before)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"before\"),\"Stepped Area (Step After)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"after\"),\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),series1string=properties.series1,series1array,series2array,series3array,series4array,series5array,series6array,yMin,yMax;series1array=createDataArray(properties.series1),series2array=createDataArray(properties.series2),series3array=createDataArray(properties.series3),series4array=createDataArray(properties.series4),series5array=createDataArray(properties.series5),series6array=createDataArray(properties.series6);let allYValuesArray=series1array,chartLabelsOn;properties.show_data_labels&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]),instance.data.horizontalGridlineColor=properties.horiz_gridlines_color,instance.data.verticalGridlineColor=properties.vert_gridlines_color;let horizDashed=[],vertDashed=[];properties.horizontal_dashed_gridlines&&(horizDashed=[8,4]),properties.vertical_dashed_gridlines&&(vertDashed=[8,4]);let hundredPercentStacked=!1;\"100% Stacked Bar (Horizontal)\"!=properties.chartType&&\"100% Stacked Bar\"!=properties.chartType&&\"100% Stacked Area (Vertical)\"!=properties.chartType||(hundredPercentStacked=!0);let customTooltip=!1,chartTooltipMode;
176null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),chartTooltipMode=\"horizontalBar\"!=chartType?\"interpolate\":\"nearest\";var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:chartType,data:{labels:arrayofxvalues},options:{title:{display:!!properties.chart_title,text:properties.chart_title,fontSize:properties.chart_title_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontColor:properties.chart_title_font_color},spanGaps:properties.span_gaps,dragData:properties.draggable_values,onDrag:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data;for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i]&&\" \"!=draggedItemAllSeriesValues[i]||(draggedItemAllSeriesValues[i]=0);instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_x_value\",arrayofxvalues[index]),instance.publishState(\"dragged_item_ending_value\",value),instance.publishState(\"dragged_item_all_series_values\",draggedItemAllSeriesValues),instance.triggerEvent(\"chart_value_dragged\",(function(err){})),instance.publishState(\"currently_dragging\",!0)},onDragEnd:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data;for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i]&&\" \"!=draggedItemAllSeriesValues[i]||(draggedItemAllSeriesValues[i]=0);instance.publishState(\"dragged_item_starting_value\",instance.data.datasets[datasetIndex].data[index]),instance.publishState(\"currently_dragging\",!1),instance.data.justDragged=!0},dragDataRound:properties.drag_data_round,cornerRadius:properties.bar_corner_radius,animation:{duration:properties.animation_duration},hover:{mode:\"nearest\",intersect:!1},onHover:function(event,elements){if(properties.draggable_values?$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"grab\":\"default\"):customTooltip&&null==document.getElementById(properties.custom_tooltip_id)?$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",(elements[0],\"default\")):$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=elements,clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex];\"\"!=value&&\" \"!=value||(value=0);var series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.borderColor;null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"!=remainingSeriesValues[i]&&\" \"!=remainingSeriesValues[i]||(remainingSeriesValues[i]=0);instance.publishState(\"hovered_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"hovered_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"hovered_item_other_series_names\",remainingSeriesNames),instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color),instance.publishState(\"hovered_item_x_index\",clickedElementindex+1),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))}
176,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:properties.chart_padding,left:properties.chart_padding,top:properties.chart_padding,bottom:properties.chart_padding}},maintainAspectRatio:!1,scales:{yAxes:[{yAxixID:\"y\",id:\"y\",scaleLabel:{display:!!properties.y_axis_name,labelString:properties.y_axis_name,fontSize:properties.y_axis_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontColor:properties.y_axis_font_color},stacked:\"Stacked Bar\"==properties.chartType||\"Stacked Area\"==properties.chartType||\"Stacked Bar (Horizontal)\"==properties.chartType||\"100% Stacked Bar\"==properties.chartType||\"100% Stacked Bar (Horizontal)\"==properties.chartType||\"100% Stacked Area (Vertical)\"==properties.chartType,gridLines:{borderDash:horizDashed,drawBorder:!1,color:\"rgba(0,0,0,0)\",zeroLineColor:\"rgba(0,0,0,0)\",zeroLineWidth:properties.y_zero_line_width,tickMarkLength:properties.tick_mark_length_y},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value;if(yLabel=null!=properties.y_labels_decimal_places?parseFloat(value).toFixed(properties.y_labels_decimal_places):value.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.includes(\".\")?yLabel.substring(0,yLabel.indexOf(\".\")).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+properties.decimal_place_character+yLabel.substring(yLabel.indexOf(\".\")+1):yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),properties.max_num_char_per_line&&\"horizontalBar\"===chartType){const maxCharsPerLine=properties.max_num_char_per_line,words=yLabel.split(\" \"),lines=[];let currentLine=\"\";return words.forEach((word=>{(currentLine+word).length<=maxCharsPerLine?currentLine+=word+\" \":(lines.push(currentLine.trim()),currentLine=word+\" \")})),currentLine&&lines.push(currentLine.trim()),lines}return yLabel}}}],xAxes:[{scaleLabel:{display:!!properties.x_axis_name,labelString:properties.x_axis_name,fontSize:properties.x_axis_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontColor:properties.x_axis_font_color},stacked:\"Stacked Bar\"==properties.chartType||\"Stacked Area\"==properties.chartType||\"Stacked Bar (Horizontal)\"==properties.chartType||\"100% Stacked Bar\"==properties.chartType||\"100% Stacked Bar (Horizontal)\"==properties.chartType||\"Overlapped Bar (Vertical)\"==properties.chartType,gridLines:{borderDash:vertDashed,drawBorder:!1,color:instance.data.verticalGridlineColor,zeroLineColor:properties.x_zero_line_color,tickMarkLength:0,zeroLineWidth:properties.x_zero_line_width},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;if(null!=xLabel){if(value<1&&value>-1&&0!=value&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(xLabel=properties.yAxisUnitBeforeNumber+xLabel),properties.yAxisUnitAfterNumber&&(xLabel+=properties.yAxisUnitAfterNumber),properties.max_num_char_per_line&&\"horizontalBar\"!=chartType){const maxCharsPer
176Line=properties.max_num_char_per_line;let words=originalXLabel.split(\" \");const lines=[];let currentLine=\"\";words.forEach((word=>{(currentLine+word).length<=maxCharsPerLine?currentLine+=word+\" \":(lines.push(currentLine.trim()),currentLine=word+\" \")})),currentLine&&lines.push(currentLine.trim()),originalXLabel=lines}return\"horizontalBar\"==chartType?xLabel:originalXLabel}}}}]},plugins:{stacked100:{enable:hundredPercentStacked},crosshair:!1},tooltips:{intersect:!1,enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let beforeDecimal=Math.floor(parseFloat(tooltipItem.value));parseFloat(tooltipItem.value)<0&&(beforeDecimal=Math.ceil(parseFloat(tooltipItem.value)));let afterDecimalCalc=parseFloat(tooltipItem.value)-parseFloat(beforeDecimal),numDecimalPlaces,afterDecimal,commaValue,finalLabel;return numDecimalPlaces=-1!=tooltipItem.value.indexOf(\".\")?tooltipItem.value.substring(tooltipItem.value.indexOf(\".\")+1).length:0,numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before&&(beforeDecimal=properties.data_labels_unit_before+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),properties.data_labels_unit_after&&(finalLabel+=properties.data_labels_unit_after),finalLabel}}}}});instance.data.chartType=chartType,\"horizontalBar\"!=chartType?(null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum)):(null!=properties.yMaxNum&&(chart.options.scales.xAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.xAxes[0].ticks.min=properties.yMinNum));var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);let showDataLabelsOverlap;function pushDataset(dataLabel,newData,newColor,customChartType,pointBackgroun
176dColor,pointBorderColor,backgroundColorArray,pointImage,actionChartType,barBorderColor,barBorderColor){let chart_type,customType,border_color;border_color=chartType.includes(\"bar\")?0==properties.bar_border_width?newColor:barBorderColor:newColor,chart_type=chartType?customChartType:properties.chart_type,customChartType&&(customType=!0);let myDataset={data:newData,customType:customType,type:customChartType,label:dataLabel,steppedLine:instance.data.steppedLine,backgroundColor:function(value){return value=properties.chartType.includes(\"Area\")?instance.data.reduceOpacity(newColor,.5):!backgroundColorArray||\"Bar\"!=properties.chartType&&\"Horizontal Bar\"!=properties.chartType?newColor:backgroundColorArray},fill:function(value){return value=!(!properties.chartType.includes(\"Area\")&&\"Area\"!=actionChartType)&&\"origin\"},borderWidth:function(value){return value=chartType.includes(\"area\")||chartType.includes(\"line\")?properties.border_width:chartType.includes(\"bar\")?properties.bar_border_width:0},lineTension:properties.curve_line_charts,borderColor:border_color,pointBorderColor:function(value){return value=pointBorderColor||\"#FFFFFF\"}
176,pointBackgroundColor:function(value){return value=null!=pointBackgroundColor?pointBackgroundColor:newColor},pointStyle:pointImage,pointBorderWidth:properties.point_border_width,pointRadius:properties.line_point_radius,pointHitRadius:20,pointHoverRadius:properties.point_hover_radius,barPercentage:properties.bar_width,categoryPercentage:properties.category_width,barThickness:properties.bar_width_pixels,datalabels:{display:showDataLabelsOverlap,color:function(value){return value=\"Default (Same as Series Color)\"!=properties.font_color_setting?properties.datalabel_font_color:newColor},align:function(value){return\"end\"},font:{size:properties.datalabel_size,family:properties.bubble.font_face().split(\":\")[0],weight:properties.datalabel_fontweight},anchor:function(context){return properties.chartType.includes(\"horizontal\"),context.dataset.data[context.dataIndex]<0?\"end\"==properties.datalabel_anchor?\"start\":\"start\"==properties.datalabel_anchor?\"end\":properties.datalabel_anchor:properties.datalabel_anchor},formatter:function(value){if(instance.data.data_label_value=value,Math.abs(value)<properties.hide_if_less_than)return\"\";if(\"\"==value||\" \"==value)return\"\";let beforeDecimal=Math.floor(parseFloat(value));parseFloat(value)<0&&(beforeDecimal=Math.ceil(parseFloat(value)));let afterDecimalCalc=parseFloat(value)-parseFloat(beforeDecimal),numDecimalPlaces,valueString,afterDecimal,commaValue,finalLabel;return valueString=value.toString(),numDecimalPlaces=-1!=valueString.indexOf(\".\")?valueString.substring(valueString.indexOf(\".\")+1).length:0,numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before?parseFloat(value)<0?(beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+properties.data_labels_unit_before+beforeDecimal):beforeDecimal=properties.data_labels_unit_before+beforeDecimal:parseFloat(value)<0&&(parseFloat(value)>-1&&(beforeDecimal=\"0\"+beforeDecimal),beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),properties.data_labels_unit_after&&(finalLabel+=properties.data_labels_unit_after),finalLabel},offset:function(context){return context.dataset.data[context.dataIndex]<0?-1*(properties.datalabel_offset+1.25*properties.datalabel_size):properties.datalabel_offset},borderWidth:\"1\",borderRadius:\"3\",borderColor:function(value){return instance.data.data_label_value>properties.hide_if_less_than?properties.label_border_color:\"rgba(0, 0, 0, 0)\"},backgroundColor:function(value){return Math.abs(instance.data.data_label_value)>properties.hide_if_less_than?(instance.data.mycolor=properties.datalabel_background_color,instance.data.mycolor):\"rgba(0, 0, 0, 0)\"},padding:\"1\"}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}function updateStyle(chart){chart.options.scales.yAxes[0].gridLines.zeroLineColor=properties.y_zero_line_color,chart.options.scales.yAxes[0].ticks.display=properties.show_y_tick_labels,chart.options.scales.yAxes[0].gridLines.color=instance.data.horizontalGridlineColor}function animate1(){instance.data.updateChartDatasets(),updateStyle(instance.data.chart),instance.data.chart.update()}chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.mainCh
176artCanvas.style.borderRadius=properties.bubble.border_roundness(),instance.data.lineWidth=properties.border_width,null!=properties.x_ticks_rotation&&(chart.options.scales.xAxes[0].ticks.minRotation=properties.x_ticks_rotation,chart.options.scales.xAxes[0].ticks.maxRotation=properties.x_ticks_rotation),showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\",instance.data.pushDataset=pushDataset,removeOldSeriesProperty(instance.data.series1_oldname),removeOldSeriesProperty(instance.data.series2_oldname),removeOldSeriesProperty(instance.data.series3_oldname),removeOldSeriesProperty(instance.data.series4_oldname),removeOldSeriesProperty(instance.data.series5_oldname),removeOldSeriesProperty(instance.data.series6_oldname),properties.series1&&(properties.series1name?(pushDataset(properties.series1name,series1array,properties.series1color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_1_border),instance.data.series1_oldname=properties.series1name):(instance.data.series1_oldname=\"Series 1\",pushDataset(instance.data.series1_oldname,series1array,properties.series1color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_1_border))),properties.series2&&(properties.series2name?(pushDataset(properties.series2name,series2array,properties.series2color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_2_border),instance.data.series2_oldname=properties.series2name):(instance.data.series2_oldname=\"Series 2\",pushDataset(instance.data.series2_oldname,series2array,properties.series2color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_2_border))),properties.series3&&(properties.series3name?(pushDataset(properties.series3name,series3array,properties.series3color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_3_border),instance.data.series3_oldname=properties.series3name):(instance.data.series3_oldname=\"Series 3\",pushDataset(instance.data.series3_oldname,series3array,properties.series3color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_3_border))),properties.series4&&(properties.series4name?(pushDataset(properties.series4name,series4array,properties.series4color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_4_border),instance.data.series4_oldname=properties.series4name):(instance.data.series4_oldname=\"Series 4\",pushDataset(instance.data.series4_oldname,series4array,properties.series4color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_4_border))),properties.series5&&(properties.series5name?(pushDataset(properties.series5name,series5array,properties.series5color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_5_border),instance.data.series5_oldname=properties.series5name):(instance.data.series5_oldname=\"Series 5\",pushDataset(instance.data.series5_oldname,series5array,properties.series5color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_5_border))),properties.series6&&(properties.series6name?(pushDataset(properties.series6name,series6array,properties.series6color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_6_border),instance.data.series6_oldname=properties.series6name):(instance.data.series6_oldname=\"Series 6\",pushDataset(instance.data.series6_oldname,series6array,properties.series6color,void 0,void 0,void 0,void 0,void 0,void 0,void 0,properties.series_6_border))),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(evt);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex];\"\"!=value&&\" \"!=value||(value=0);var series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._model.backgroundColor;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value),instance.publishState(\"clicked_item_series_name\",series_name),instance.publishState(\"clicked_item_series_color\",series_color);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"!=remainingSeriesValues[i]&&\" \"!=remainingSeriesValues[i]||(remainingSeriesValues[i]=0);instance.publishState(\"click_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"clicked_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"clicked_item_other_series_names\",remainingSeriesNames)}else null!=document.getElementById(properties.custom_tooltip_id)&&$(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},instance.data.chart=chart,setTimeout(animate1,300),setTimeout(animate1,1e3),setTimeout(animate1,5e3),instance.publishState(\"chart_loaded\",!0)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element for the chart description\n var textElement = document.createElement('p');\n textElement.innerText = 'Bar/Line/Area Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the chart description to the container\n container.appendChild(textElement);\n\n // Create a text element for the support message\n var supportText = document.createElement('p');\n\tsupportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '0px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n\n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AAn":{"display":"List Calculator - Basic","add_is_visible":true,"fields":{"AAo":{"caption":"List A","editor":"DynamicValue","name":"listA","rank":0,"value":"text"},"AAp":{"caption":"Operation","default_val":"Multiply","editor":"Dropdown","name":"operation1","rank":1},"AAq":{"caption":"Number or List B","editor":"DynamicValue","name":"numberOrListB","rank":2,"value":"text","optional":true}},"states":{"AAr":{"caption":"Output List (number)","initialization_code":{"fn":"function(properties,context){let result;if(\"Concatenate\"==properties.operation1)result=concatenate(properties.listA,properties.numberOrListB);else if(\"Multiply\"==properties.operation1||\"Divide\"==properties.operation1)result=multiply(properties.listA,properties.numberOrListB);else if(\"Add\"==properties.operation1)result=add(properties.listA,properties.numberOrListB);else{let array1=properties.listA.split(\", \").map((x=>+x));const cumulativeSum=(sum=0,value=>sum+=value);result=array1.map(cumulativeSum)}var sum;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\", \");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}function add(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Subtract\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return addTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),addArrayAndNumber(array1,multiple,array1.length)}}function addTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(array2[i]);resultingArray.push(product)}return resultingArray}function addArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(number);resultingArray.push(product)}return resultingArray}return result}"},"is_list":true,"name":"outputList","value":"number"}
176,"ABP":{"caption":"Output List (text)","name":"outputliststring","value":"text","initialization_code":{"fn":"function(properties,context){let result;if(\"Concatenate\"==properties.operation1)result=concatenate(properties.listA,properties.numberOrListB);else if(\"Multiply\"==properties.operation1||\"Divide\"==properties.operation1)result=multiply(properties.listA,properties.numberOrListB);else if(\"Add\"==properties.operation1)result=add(properties.listA,properties.numberOrListB);else{let array1=properties.listA.split(\", \").map((x=>+x));const cumulativeSum=(sum=0,value=>sum+=value);result=array1.map(cumulativeSum)}var sum;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\", \");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}function add(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Subtract\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return addTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),addArrayAndNumber(array1,multiple,array1.length)}}function addTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(array2[i]);resultingArray.push(product)}return resultingArray}function addArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(number);resultingArray.push(product)}return resultingArray}return result}"},"is_list":true}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element for the chart description\n var textElement = document.createElement('p');\n textElement.innerText = 'List Calculator - Basic';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the chart description to the container\n container.appendChild(textElement);\n\n // Create a text element for the support message\n var supportText = document.createElement('p');\n\tsupportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '0px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n\n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AAx":{"display":"Chart - Pie/Donut","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_hover_pressed":false,"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AAJ":{"caption":"Series Labels","default_val":"Category A, Category B, Category C, Category D","editor":"DynamicValue","is_list":false,"name":"chartlabels","rank":2,"value":"text"},"AAK":{"caption":"Series Values","default_val":"2525, 743, 431, 1540","editor":"DynamicValue","name":"series1","rank":3,"value":"text"},"AAN":{"caption":"Value's Colors","default_val":"#00A2FF, #24E082, #FF8961, #BC61E6","editor":"DynamicValue","is_list":false,"name":"series1color","rank":4,"value":"text"},"AAa":{"caption":"Tooltip Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":39,"value":"text"},"AAb":{"caption":"Tooltip Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":40,"value":"text"},"ABK":{"caption":"labelValue: Unit Before","default_val":"$","editor":"DynamicValue","name":"data_label_unit_before","rank":26,"value":"text"},"ABL":{"caption":"labelValue: Unit After","default_val":" USD","editor":"DynamicValue","name":"data_label_unit_after","rank":27,"value":"text"},"ABO":{"caption":"Show/Hide Legend","name":"showLegend2","rank":6,"editor":"Dropdown","default_val":"Top"},"ACB":{"caption":"Section Border Width","name":"section_border_width","rank":18,"editor":"DynamicValue","value":"number","default_val":5},"ACC":{"caption":"Section Border Color","name":"section_border_color","rank":19,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"ACD":{"caption":"Cutout Percentage","name":"cutout_percentage","rank":17,"editor":"DynamicValue","value":"number","default_val":82},"ACS":{"caption":"-------------------------- General Settings --------------------------","name":"-------------------------_general_settings_-------------------------","rank":5,"editor":"Label"},"ACU":{"caption":"---------------------------- Chart Styling ----------------------------","name":"-------------------------_chart_styling_-------------------------","rank":16,"editor":"Label"},"ACV":{"caption":"-------------------------- Tooltip Settings ---------------------------","name":"-------------------------_tooltip_settings_-------------------------","rank":38,"editor":"Label"},"ACk":{"caption":"Thousands Separator","name":"thousands_separator","rank":12,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"ADB":{"caption":"Hover Border Width","name":"hover_border_width","rank":21,"editor":"DynamicValue","value":"number","optional":false,"default_val":3},"ADJ":{"caption":"----------------------------- Data Labels ------------------------------","name":"--------------------------_data_labels_---------------------------","rank":23,"editor":"Label"},"ADK":{"caption":"Font Color","name":"datalabel_font_color","rank":34,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"ADL":{"caption":"Anchor","name":"anchor","rank":31,"editor":"Dropdown","default_val":"end"},"ADM":{"caption":"Font Color Setting","name":"font_color_setting","rank":33,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"ADN":{"caption":"Offset","name":"offset","rank":32,"editor":"DynamicValue","value":"number","default_val":3},"ADW":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":11,"editor":"DynamicValue","value":"text","optional":true},"ADc":{"caption":"Font Size","name":"datalabel_size","rank":35,"editor":"DynamicValue","value":"number","default_val":12},"AKu":{"caption":"Section Corner Roundness","name":"section_corner_roundness","rank":42,"editor":"Dropdown","default_val":"Square Corners"},"AKv":{"caption":"Round Corner Section#","name":"rounded_corner_section_number","rank":43,"editor":"DynamicValue","value":"number","default_val":0},"AKw":{"caption":"------------------ Section Corner Roundness -------------------","name":"---------------------_section_corner_roundness_----------------------","rank":41,"editor":"Label"},"AQt":{"caption":"Chart Padding","name":"padding","rank":14,"editor":"DynamicValue","value":"number","default_val":15},"AWX":{"caption":"Rotation","name":"rotation","rank":22,"editor":"DynamicValue","value":"number","default_val":0},"AWY":{"caption":"Total Circumference","name":"total_circumference","rank":20,"editor":"DynamicValue","value":"number","default_val":360},"AWj":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":29,"editor":"DynamicValue","value":"boolean","default_val":false},"AWp":{"caption":"Legend Padding","name":"legend_padding","rank":10,"editor":"DynamicValue","value":"number","default_val":0},"AWq":{"caption":"Hide Labels Less Than #","name":"hide_if_less_than","rank":30,"editor":"DynamicValue","value":"number","optional":true},"AWs":{"caption":"Animation Duration","name":"animation_duration","rank":15,"editor":"DynamicValue","value":"number","default_val":1500},"AXd":{"caption":"Legend Font Color","name":"legend_font_color","rank":8,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AXe":{"caption":"Hide from Legend if <","name":"hide_from_legend_if_less_than","rank":9,"editor":"DynamicValue","value":"number","optional":true},"AXz":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"}
176,"AYA":{"caption":"â¹ï¸ Enter your chart's labels, values, and colors. Values in each list should be comma-separated (with comma and space \", \"). The 1st item in the \"Series Labels\" list matches with the 1st item in \"Series Values\" and \"Value's Colors\" lists; the 2nd items all match with each other, and so on","name":"â¹ï¸_enter_you_chart's_x-axis_values_(the_x-axis_labels_that_will_go_from_left_to_right)_separated_by_comma_and_space_(\",_\").__can_be_a_dynamic_expression.","rank":1,"editor":"Label"},"AYB":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"â ï¸_if_data_points_get_cut_off_near_edges_of_the_chart_element,_increase_the_chart_padding_below:","rank":13,"editor":"Label"},"AYP":{"caption":"Data Label Text","name":"data_label_text","rank":25,"editor":"DynamicValue","value":"text","optional":true,"default_val":"labelPercent, labelValue, labelName"},"AYQ":{"caption":"Show Data Label?","name":"show_label","rank":24,"editor":"DynamicValue","value":"boolean","default_val":false},"AYR":{"caption":"Percent Decimal Places","name":"labelpercent_decimal","rank":28,"editor":"DynamicValue","value":"number","default_val":2},"AZZ":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":36,"editor":"Dropdown","default_val":" 400","in_style":false},"AZd":{"caption":"Legend Color Style","name":"legend_color_style","rank":7,"editor":"Dropdown","default_val":"Circle"},"AuI":{"caption":"Wrap text #characters","name":"wrap_text_num_characters","rank":37,"editor":"DynamicValue","value":"number","optional":true}},"states":{"ABX":{"caption":"Clicked Item Label Value","name":"clicked_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ABY":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADX":{"caption":"Hovered Item Label Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ADY":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADZ":{"caption":"Hovered Item Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ABa":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"ADa":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){if(!/[0-9]/.test(properties.series1))return void console.log(\"No numbers in series1.\");if(Chart.plugins.unregister(ChartDataLabels),Chart.Legend.prototype.afterFit=function(){this.height=this.height+properties.legend_padding,this.width=this.width+properties.legend_padding},null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),null==properties.chartlabels||null==properties.series1)return;if($(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId),ctxchart=chartcanvas.getContext(\"2d\");let legendState,showLegend;\"Don't Show Legend\"==properties.showLegend2?showLegend=!1:(legendState=properties.showLegend2.toLowerCase(),showLegend=!0);let listofchartlabels=properties.chartlabels,arrayoflabels=[];null!=properties.chartlabels&&(properties.chartlabels.includes(\",\")?arrayoflabels=listofchartlabels.split(\",\"):arrayoflabels.push(properties.chartlabels));let series1array=[];if(!properties.series1)return void series1array.push(5);if(properties.series1.includes(\",\")){let series1string=properties.series1;series1array=series1string.split(\",\")}else series1array.push(properties.series1);let pieChartColorsArray=[];if(properties.series1color.includes(\",\")){pieChartColorsArray=properties.series1color.split(\",\");for(let i=0;i<pieChartColorsArray.length;i++)pieChartColorsArray[i]=pieChartColorsArray[i].replace(/\\s/g,\"\")}else pieChartColorsArray.push(properties.series1color);let allYValuesArray=series1array,chartLabelsOn;1==properties.show_label&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]);let customTooltip=!1;
176null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),Chart.defaults.RoundedDoughnut=Chart.helpers.clone(Chart.defaults.doughnut),Chart.controllers.RoundedDoughnut=Chart.controllers.doughnut.extend({draw:function(ease){var ctx=this.chart.ctx,easingDecimal=ease||1,arcs=this.getMeta().data;Chart.helpers.each(arcs,(function(arc,i){arc.transition(easingDecimal).draw();var pArc,pColor=arcs[0===i?arcs.length-1:i-1]._view.backgroundColor,vm=arc._view,radius=(vm.outerRadius+vm.innerRadius)/2,thickness=(vm.outerRadius-vm.innerRadius)/2,startAngle=Math.PI-vm.startAngle-Math.PI/2,angle=Math.PI-vm.endAngle-Math.PI/2;ctx.save(),ctx.translate(vm.x,vm.y),ctx.fillStyle=0===i?vm.backgroundColor:pColor,ctx.beginPath(),ctx.arc(radius*Math.sin(startAngle),radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.fill(),ctx.fillStyle=vm.backgroundColor,ctx.beginPath(),ctx.arc(radius*Math.sin(angle),radius*Math.cos(angle),thickness,0,2*Math.PI),ctx.fill(),ctx.restore()}))}}),Chart.pluginService.register({afterUpdate:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor];arc.round={x:(chart.chartArea.left+chart.chartArea.right)/2,y:(chart.chartArea.top+chart.chartArea.bottom)/2,radius:(chart.outerRadius+chart.innerRadius)/2,thickness:(chart.outerRadius-chart.innerRadius)/2-1,backgroundColor:arc._model.backgroundColor}}},afterDraw:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var ctx=chart.chart.ctx,arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor],startAngle=Math.PI/2-arc._view.startAngle,endAngle=Math.PI/2-arc._view.endAngle;let vm=arc._view,thickness=(vm.outerRadius-vm.innerRadius)/2;ctx.save(),ctx.translate(arc.round.x,arc.round.y),ctx.fillStyle=arc.round.backgroundColor,ctx.beginPath(),ctx.arc(arc.round.radius*Math.sin(startAngle),arc.round.radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.arc(arc.round.radius*Math.sin(endAngle),arc.round.radius*Math.cos(endAngle),thickness,0,2*Math.PI),ctx.closePath(),ctx.fill(),ctx.restore()}}});let chartType=\"pie\",showDataLabelsOverlap;\"Rounded Corners (All Sections)\"==properties.section_corner_roundness&&(chartType=\"RoundedDoughnut\"),showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\";let config={plugins:chartLabelsOn,type:chartType,data:{labels:arrayoflabels,datasets:[{fill:!1,borderWidth:properties.section_border_width,borderColor:properties.section_border_color,hoverBorderWidth:properties.hover_border_width,hoverBorderColor:properties.section_border_color,label:properties.series1name,backgroundColor:pieChartColorsArray,data:series1array,datalabels:{display:showDataLabelsOverlap,anchor:properties.anchor,align:function(value){return value=0==properties.offset?\"center\":\"end\"},offset:properties.offset,color:function(value){return value=\"Custom (Define Color Below)\"==properties.font_color_setting?properties.datalabel_font_color:pieChartColorsArray},formatter:function(value,context){let completeLabel=\"\",percent,labelValue,labelName;if(value<properties.hide_if_less_than)return\"\";let total=eval(series1array.join(\"+\")),labelArray;if(percent=String((value/total*100).toFixed(properties.labelpercent_decimal))+\"%\",labelName=arrayoflabels[context.dataIndex],labelValue=value.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator),properties.data_label_unit_before&&(labelValue=(properties.data_label_unit_before+labelValue).replace(/\\s/g,\"\")),properties.data_label_unit_after&&(labelValue+=properties.data_label_unit_after),properties.data_label_text&&(labelArray=properties.data_label_text.split(\", \")),properties.data_label_text)for(;labelArray.length>0;)completeLabel&&(completeLabel+=\" \"),\"labelPercent\"==labelArray[0]&&(completeLabel+=percent),\"labelValue\"==labelArray[0]&&(completeLabel+=labelValue),\"labelName\"==labelArray[0]&&(completeLabel+=labelName),\"placeholder\"==labelArray[0]&&(completeLabel+=\"placeholder\"),labelArray.shift();if(properties.wrap_text_num_characters){for(var line=\"\",result=\"\",words=completeLabel.split(\" \"),i=0;i<words.length;i++)(line+words[i]).length>properties.wrap_text_num_characters&&(result+=line.trim()+\"\\n\",line=\"\"),line+=words[i]+\" \";return result+=line.trim(),result}return completeLabel},font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.datalabel_size,weight:properties.datalabel_fontweight}}}]},options:{plugins:{crosshair:!1},animation:{duration:properties.animation_duration},onHover:function(event,elements){if(elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.backgroundColor;customTooltip&&(instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_color\",series_color),$(\"#\"+properties.custom_tooltip_id).fadeIn(250),null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\"))}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))},cutoutPercentage:properties.cutout_percentage,rotation:-.5*Math.PI+properties.rotation*(Math.PI/180),circumference:properties.total_circumference*(Math.PI/180),legend:{align:\"left\",dis
176play:showLegend,position:legendState,labels:{filter:function(legendItem,data){return null==properties.hide_from_legend_if_less_than||data.datasets[0].data[legendItem.index]>properties.hide_from_legend_if_less_than},usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.legend_font_color,fontSize:properties.bubble.font_size(),fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},maintainAspectRatio:!1,layout:{padding:{right:properties.padding,left:properties.padding,top:properties.padding,bottom:properties.padding}},tooltips:{enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let label=\"\";label+=data.labels[tooltipItem.index],label+=\": \";let commaYLabel=data.datasets[0].data[tooltipItem.index];return null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(commaYLabel=properties.yAxisUnitBeforeNumber+commaYLabel),label+=commaYLabel,properties.yAxisUnitAfterNumber&&(label+=properties.yAxisUnitAfterNumber),label}}}}},chart=new Chart(instance.data.ctxChartState,config);instance.data.chart=chart,chart.update();var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function updateData(dataLabel,newData,newColor){chart.data.datasets.push({label:dataLabel,backgroundColor:newColor,data:newData,fill:!1,borderColor:newColor}),chart.update()}chartContainer.parentNode.removeChild(chartContainer),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId),chartContainer.style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value)}instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},\"Rounded Corners (Single Section)\"==properties.section_corner_roundness&&(chart.options.elements.arc.roundedCornersFor=properties.rounded_corner_section_number),chart.destroy(),chart=new Chart(instance.data.ctxChartState,config)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Pie/Donut Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '0px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"ABb":{"display":"Chart - Scatter/Line with Time-Series","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AAJ":{"caption":"Series 1 - x-values","default_val":"1.2, 2.2, 4.9, 3.8, 6.3, 2.7","editor":"DynamicValue","is_list":false,"name":"series1xvalues","rank":3,"value":"text"},"AAK":{"caption":"Series 1 - y-values","default_val":"220, 485, 500, 470, 590, 310","editor":"DynamicValue","name":"series1yvalues","rank":4,"value":"text"},"AAN":{"caption":"Series 1 - point color","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series1color","rank":6},"AAO":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":1,"value":"text"},"AAa":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":39,"value":"text"},"AAb":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":40,"value":"text"},"AAe":{"caption":"Y Axis - Max Value","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":38,"value":"number"},"AAf":{"caption":"Y Axis - Min Value","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":37,"value":"number"},"AAj":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":26,"value":"text","default_val":"Top"},"ABQ":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":55,"editor":"DynamicValue","value":"boolean","default_val":true},"ABR":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":56,"editor":"DynamicValue","value":"boolean","default_val":true},"ABc":{"caption":"X Axis - Min Value","name":"xMinNum","rank":44,"editor":"DynamicValue","value":"number","optional":true},"ABd":{"caption":"X Axis - Max Value","name":"xMaxNum","rank":45,"editor":"DynamicValue","value":"number","optional":true},"ABo":{"caption":"X Unit - Before","name":"xAxisUnitBeforeNumber","rank":46,"editor":"DynamicValue","value":"text","optional":true},"ABp":{"caption":"X Unit - After","name":"xAxisUnitAfterNumber","rank":47,"editor":"DynamicValue","value":"text","optional":true},"ABq":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"to_add_more_dataset_series,_go_to_your_workflow_tab_and_choose_the_\"add_a_data_series_scatter/pointchart\"_action!","rank":24,"editor":"Label"},"ABz":{"caption":"Point Radius","name":"point_radius","rank":66,"editor":"DynamicValue","value":"number","default_val":8},"ACA":{"caption":"Point Hover Radius","name":"point_hover_radius","rank":67,"editor":"DynamicValue","value":"number","default_val":12},"ACQ":{"caption":"----------------------------- Chart Data -----------------------------","name":"--------------------------_data_series_values_---------------------------_(you_can_also_add_infinite_series_via_workflows)_-----","rank":0,"editor":"Label"},"ACR":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":25,"editor":"Label"},"ACl":{"caption":"Thousands Separator","name":"thousands_separator","rank":28,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"ACo":{"caption":"Point Border Width","name":"point_border_width","rank":68,"editor":"DynamicValue","value":"number","default_val":5},"ACr":{"caption":"Series 1 - point style","name":"point_style","rank":8,"editor":"Dropdown","default_val":"circle"},"ACs":{"caption":"Series 1 - point border","name":"point_border_color","rank":7,"editor":"Color","default_val":"rgba(0, 162, 255, 0.25)"},"ACx":{"caption":"Horiz. Dashed Gridlines?","name":"horizontal_dashed_gridlines","rank":53,"editor":"DynamicValue","value":"boolean","default_val":true},"ACy":{"caption":"Vert. Dashed Gridlines?","name":"vertical_dashed_gridlines","rank":54,"editor":"DynamicValue","value":"boolean","default_val":true},"AIA":{"caption":"Connect Points?","name":"show_line","rank":69,"editor":"DynamicValue","value":"boolean","default_val":false},"AIB":{"caption":"---------------------------- Axis Settings ----------------------------","name":"----------------------------_axis_settings_----------------------------","rank":36,"editor":"Label"},"AIC":{"caption":"------------------------- Gridlines Settings -------------------------","name":"-------------------------_gridlines_settings_-------------------------","rank":50,"editor":"Label"},"AID":{"caption":"---------------------------- Point Settings ----------------------------","name":"--------------------------_point_settings_--------------------------","rank":65,"editor":"Label"},"AIE":{"caption":"X Axis Unit","name":"x_axis_unit","rank":41,"editor":"Dropdown","default_val":"Number"},"AIG":{"caption":"X Axis Date Format","name":"x_axis_date_format","rank":42,"editor":"DynamicValue","value":"text","optional":false,"default_val":"H:mma do MMM, YYYY"},"AIO":{"caption":"Max X Ticks","name":"max_x_ticks","rank":58,"editor":"DynamicValue","value":"number","optional":false,"default_val":11},"AIP":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":59,"editor":"DynamicValue","value":"number","optional":false,"default_val":11},"AIT":{"caption":"Vert. Crosshair Color","name":"vertical_crosshair_color","rank":73,"editor":"Color","default_val":"rgba(230, 230, 230, 1)"},"AIU":{"caption":"Vert. Crosshair Width","name":"vertical_crosshair_width","rank":74,"editor":"DynamicValue","value":"number","default_val":1},"AIV":{"caption":"Vert. Crosshairs On?","name":"vertical_crosshair_on","rank":72,"editor":"DynamicValue","value":"boolean","default_val":false},"AIW":{"caption":"------------------------ Crosshair Settings ------------------------","name":"------------------------_crosshair_settings_------------------------","rank":71,"editor":"Label"},"AKI":{"caption":"Synced Crosshairs?","name":"synced_crosshairs","rank":75,"editor":"DynamicValue","value":"boolean","default_val":false},"AKJ":{"caption":"Group Number","name":"group_number","rank":76,"editor":"DynamicValue","value":"number","optional":false,"default_val":1},"AKK":{"caption":"Suppress Tooltips?","name":"suppress_tooltips","rank":77,"editor":"DynamicValue","value":"boolean","default_val":false},"AKR":{"caption":"Custom Tooltip HTML ID","name":"custom_tooltip_id","rank":30,"editor":"DynamicValue","value":"text","optional":true},"AKx":{"caption":"Animation Duration","name":"animation_duration","rank":33,"editor":"DynamicValue","value":"number","default_val":1500},"ANi":{"caption":"----------------------------- Data Labels --------------------------","name":"----------------------------------_data_labels_-------------","rank":78,"editor":"Label"},"ANj":{"caption":"Distance from Point","name":"distance_from_point","rank":83,"editor":"DynamicValue","value":"number","default_val":0},"ANk":{"caption":"Angle","name":"angle","rank":82,"editor":"DynamicValue","value":"number","default_val":0,"optional":false},"ANl":{"caption":"Data Label Text","name":"data_label_text","rank":79,"editor":"DynamicValue","value":"text","optional":true},"ANm":{"caption":"Unit Before X","name":"unit_before_x","rank":84,"editor":"DynamicValue","value":"text","optional":true},"ANn":{"caption":"Unit After X","name":"unit_after_x","rank":85,"editor":"DynamicValue","value":"text","optional":true,"default_val":"km"},"ANo":{"caption":"Unit Before Y","name":"unit_before_y","rank":86,"editor":"DynamicValue","value":"text","optional":true},"ANp":{"caption":"Unit After Y","name":"unit_after_y","rank":87,"editor":"DynamicValue","value":"text","optional":true,"default_val":"cal"},"ANq":{"caption":"Font Color Setting","name":"font_color_setting","rank":88,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"ANr":{"caption":"Font Color (Optional)","name":"font_color_optional","rank":89,"editor":"Color","default_val":"rgba(191, 191, 191, 1)","optional":true},"ANs":{"caption":"Font Size","name":"font_size","rank":90,"editor":"DynamicValue","value":"number","default_val":12},"ANt":{"caption":"Alignment","name":"alignment","rank":81,"editor":"DynamicValue","value":"text","default_val":"end","optional":false},"AQU":{"caption":"Line Border Width","name":"line_border_width","rank":70,"editor":"DynamicValue","value":"number","default_val":2},"AQk":{"caption":"Chart Padding (px)","name":"chart_padding","rank":32,"editor":"DynamicValue","value":"number","default_val":1},"AQl":{"caption":"Y = Zero Line Color","name":"y_is_zero_color","rank":60,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AQm":{"caption":"X = Zero Line Color","name":"x_is_zero_color","rank":61,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ARE":{"caption":"Draggable Values?","name":"draggable_values","rank":34,"editor":"DynamicValue","value":"boolean","default_val":false},"ARF":{"caption":"Drag Data Round","name":"drag_data_round","rank":35,"editor":"DynamicValue","value":"number","default_val":1},"AVi":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":63,"editor":"DynamicValue","value":"number","default_val":12},"AVj":{"caption":"Tick Label Font Color","name":"tick_label_color","rank":62,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVk":{"caption":"â¹ï¸ To customize Tick Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties","name":"to_customize_tick_label_font_style/family_you_can_edit_this_element's_font_style_as_you_would_for_a_standard_text_element_(by_scrolling_down_to_the_bottom_of_this_menu_and_editing_the_standard_bubble_properties_for_the_font_in_the_font_dropdown_menu)","rank":64,"editor":"Label"},"AVw":{"caption":"X Tick Labels Rotation","name":"x_ticks_rotation","rank":57,"editor":"DynamicValue","value":"number","optional":true},"AVx":{"caption":"Vertical Gridline Color","name":"vertical_gridlines_color","rank":51,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AVy":{"caption":"Horiz. Gridlines Color","name":"horizontal_gridlines_color","rank":52,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AWn":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":80,"editor":"DynamicValue","value":"boolean","default_val":false},"AWo":{"caption":"â¹ï¸ To use an image for the point style above, add the series using the workflow action called \"Add/update a data series\", where there is a property for datapoint image","name":"â¹ï¸ To_use_an_image_for_the_point_style,_add_the_serie_via_workflow_action_instead","rank":9,"editor":"Label"},"AXM":{"caption":"Series 2 - name","name":"series2name","rank":10,"editor":"DynamicValue","value":"text","default_val":"Series 2","optional":true},"AXN":{"caption":"Series 2 - point color","name":"series2color","rank":14,"editor":"Color","default_val":"rgba(0, 200, 81, 1)","optional":true},"AXO":{"caption":"Series 2 - point border","name":"series2_point_border_color","rank":15,"editor":"Color","default_val":"rgba(0, 199, 83, 0.28)","optional":true},"AXP":{"caption":"Series 2 - point style","name":"series2_point_style","rank":16,"editor":"Dropdown","default_val":"circle","optional":true},"AXQ":{"caption":"Series 2 - x-values","name":"series2xvalues","rank":11,"editor":"DynamicValue","value":"text","optional":true},"AXR":{"caption":"Series 2 - y-values","name":"series2yvalues","rank":12,"editor":"DynamicValue","value":"text","optional":true},"AXS":{"caption":"Series 3 - name","name":"series3name","rank":17,"editor":"DynamicValue","value":"text","optional":true},"AXT":{"caption":"Series 3 - point color","name":"series3color","rank":21,"editor":"Color","default_val":"rgba(170, 102, 204, 1)","optional":true},"AXU":{"caption":"Series 3 - point border","name":"series3_point_border_color","rank":22,"editor":"Color","default_val":"rgba(170, 102, 204, 0.22)","optional":true},"AXV":{"caption":"Series 3 - point style","name":"series3_point_style","rank":23,"editor":"Dropdown","default_val":"circle","optional":true},"AXW":{"caption":"Series 3 - x-alues","name":"series3xvalues","rank":18,"editor":"DynamicValue","value":"text","optional":true},"AXX":{"caption":"Series 3 - y-alues","name":"series3yvalues","rank":19,"editor":"DynamicValue","value":"text","optional":true},"AXY":{"caption":"Series 1 - labels","name":"series_1_labels","rank":5,"editor":"DynamicValue","value":"text","optional":true},"AXZ":{"caption":"Series 2 - labels","name":"series_2_labels","rank":13,"editor":"DynamicValue","value":"text","optional":true},"AXa":{"caption":"Series 3 - labels","name":"series_3_labels","rank":20,"editor":"DynamicValue","value":"text","optional":true},"AYC":{"caption":"â¹ï¸ Below, add series data (x, y, label values). Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"â¹ï¸_add_series_names,_colors,_and_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_and_can_be_dynamically_(e.g._\"do_a_search_for\")","rank":2,"editor":"Label"},"AYD":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"â ï¸_if_data_points_get_cut_off_near_edges_of_the_chart_element,_increase_the_chart_padding_below:","rank":31,"editor":"Label"},"AYK":{"caption":"yLabel Decimal Places","name":"y_labels_decimal_places","rank":48,"editor":"DynamicValue","value":"number","optional":true},"AYL":{"caption":"Decimal Separator","name":"decimal_separator","rank":29,"editor":"DynamicValue","value":"text","default_val":"."},"AZa":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":91,"editor":"Dropdown","default_val":" 400","in_style":true},"AZe":{"caption":"Legend Color Style","name":"legend_color_style","rank":27,"editor":"Dropdown","default_val":"Circle"},"AyO":{"caption":"xLabel Decimal Places","name":"x_labels_decimal_places","rank":49,"editor":"DynamicValue","value":"number","optional":true},"AyQ":{"caption":"Tooltip Date Format","name":"tooltip_date_format","rank":43,"editor":"DynamicValue","value":"text","default_val":"H:mma do MMM, YYYY"}},"states":{"AAv":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"number"},"ABU":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ABV":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}}
176,"AKS":{"caption":"Hovered Item X Value (number)","name":"hovered_item_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKT":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKU":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AKV":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ARG":{"caption":"Dragged Item Data Series Name","name":"dragged_item_data_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ARJ":{"caption":"Dragged Item Index Number","name":"dragged_item_index_number","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ARK":{"caption":"Dragged Item Starting Y Value","name":"dragged_item_starting_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ARL":{"caption":"Dragged Item Starting X Value","name":"dragged_item_starting_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ARM":{"caption":"Dragged Item Ending Y Value","name":"dragged_item_ending_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ARN":{"caption":"Dragged Item Ending X Value","name":"dragged_item_ending_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AVz":{"caption":"Hovered Item X Value (Date)","name":"hovered_item_x_value_date","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AWB":{"caption":"Dragged Item - all Y Values of this Serie","name":"dragged_item_all_series_values_y","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AWC":{"caption":"Dragged Item - all X Values of this Serie","name":"dragged_item_all_series_values_x","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AWi":{"caption":"Currently Dragging Bar/Value","name":"currently_dragging","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AXb":{"caption":"Hovered Item Point Label","name":"hovered_item_point_label","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ABW":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"ARa":{"caption":"Chart Value Dragged","name":"chart_value_dragged"}},"actions":{"ABi":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){let numAttempts=0;function mainAddSeries(){if(numAttempts>15)console.log(\"The Chart you are trying to update is not visible on the page or the data you're attempting to load is taking too long\");else{if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);if(properties.use_image_as_point){var pointImage=new Image(1,1);pointImage.src=properties.use_image_as_point,pointImage.onload=function(){var width=pointImage.naturalWidth,height=pointImage.naturalHeight;pointImage.width=width*properties.image_point_scale,pointImage.height=height*properties.image_point_scale}}instance.data.createPointArray&&properties.xValues?addSeries():setTimeout(addSeries,1500)}function addSeries(){let seriesArray=[];instance.data.createPointArray(properties.xValues,properties.yValues,seriesArray,properties.point_labels);let pointColors=properties.series_points_colors_list?properties.series_points_colors_list.split(\",\").map((color=>color.trim())):[],borderColors=properties.series_border_colors_list?properties.series_border_colors_list.split(\",\").map((color=>color.trim())):[];console.log(properties.series_points_colors_list),console.log(pointColors),console.log(properties.series_border_colors_list),console.log(borderColors),instance.data.pushDataset(properties.series_name,seriesArray,properties.series_color,properties.point_border_color,properties.point_style,properties.point_radius,properties.show_line,properties.show_data_labels,pointImage,pointColors,borderColors),instance.data.updateChartDatasets(),instance.data.chart.update(
176)}}mainAddSeries()}","add_debugger":false},"fields":{"ABk":{"caption":"Y-Values (comma-separated numbers)","name":"yValues","rank":5,"editor":"DynamicValue","value":"text"},"ABl":{"caption":"X-Values (comma-separated numbers)","name":"xValues","rank":4,"editor":"DynamicValue","value":"text"},"ABm":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"ABn":{"caption":"Series Point Color","name":"series_color","rank":9,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ACt":{"caption":"Point Style","name":"point_style","rank":8,"editor":"Dropdown","default_val":"circle"},"ACu":{"caption":"Point Border Color","name":"point_border_color","rank":11,"editor":"Color","default_val":"rgba(51, 179, 230, 0.73)"},"ADP":{"caption":"Point Radius (px)","name":"point_radius","rank":13,"editor":"DynamicValue","value":"number","default_val":6},"AHz":{"caption":"Show Line?","name":"show_line","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false},"ANv":{"caption":"Show Data Labels?","name":"show_data_labels","rank":3,"editor":"DynamicValue","value":"boolean","default_val":false,"optional":true},"ARU":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"ARV":{"caption":"------------------------ Point Style Settings -----------------------","name":"---------------------_point_style_settings_---------------------","rank":7,"editor":"Label"},"AWI":{"caption":"Use Image As Point","name":"use_image_as_point","rank":14,"editor":"DynamicValue","value":"image","optional":true},"AWJ":{"caption":"Image Point Scale","name":"image_point_scale","rank":15,"editor":"DynamicValue","value":"number","default_val":1,"optional":false},"AYJ":{"caption":"Point Labels","name":"point_labels","rank":6,"optional":true,"editor":"DynamicValue","value":"text"},"AyR":{"caption":"Optional: Multi-colored Series Points (list)","name":"series_points_colors_list","rank":10,"editor":"DynamicValue","value":"text","optional":true},"AyS":{"caption":"Optional: Multi-colored Series Borders (List)","name":"series_border_colors_list","rank":12,"editor":"DynamicValue","value":"text","optional":true}}},"ABx":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.datasets.find((element=>element.label==properties.series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"},"fields":{"ABy":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AOO":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"}}},"code":{"initialize":{"fn":"function(instance,context){function loadScriptOnce(src){if(!document.querySelector(`script[src=\"${src}\"]`)){const script=document.createElement(\"script\");script.src=src,script.defer=!0,document.head.appendChild(script)}}loadScriptOnce(\"https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.4/Chart.bundle.min.js\"),instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[]}"},"update":{"fn":"function(instance,properties,context){if(Chart.plugins.unregister(ChartDataLabels),instance.data.justDragged)return void(instance.data.justDragged=!1);function reduceOpacity(originalRGBAColor){let stringlength=originalRGBAColor.length-1,colorArray=(originalRGBAColor=originalRGBAColor.substring(5,stringlength)).split(\", \"),newOpacity=.5*colorArray[3],result;return\"rgba(\"+colorArray[0]+\", \"+colorArray[1]+\", \"+colorArray[2]+\", \"+ne
176wOpacity+\")\"}$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})}));let customTooltip=!1;if(null!=properties.custom_tooltip_id&&(customTooltip=!0,instance.data.custom_tooltip_id=properties.custom_tooltip_id,setTimeout((function(){$(\"#\"+properties.custom_tooltip_id).fadeOut(1)}),200)),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas,ctxchart=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\");let chartType,legendState,showLegend;function createPointArray(xString,yString,outputArray,labelString){let xArray,yArray,labelArray;if(null!=xString&&(xArray=xString.split(\",\")),null!=yString&&(yArray=yString.split(\",\")),null!=labelString&&(labelArray=labelString.split(\", \")),null!=xArray&&null!=yArray)for(let i=0;i<xArray.length;i++){let newDate=new Date(1*xArray[i]),nextPoint;nextPoint=\"Number\"==properties.x_axis_unit?{x:xArray[i],y:yArray[i],...null!=labelString&&{label:labelArray[i]}}:{t:newDate,y:yArray[i],...null!=labelString&&{label:labelArray[i]}},outputArray.push(nextPoint)}}\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createPointArray=createPointArray;let series1array=[],series2array=[],series3array=[],arrayofxvalues;instance.data.createPointArray(properties.series1xvalues,properties.series1yvalues,series1array,properties.series_1_labels),instance.data.createPointArray(properties.series2xvalues,properties.series2yvalues,series2array,properties.series_2_labels),instance.data.createPointArray(properties.series3xvalues,properties.series3yvalues,series3array,properties.series_3_labels);let allYValuesArray=series1array,chartLabelsOn=[ChartDataLabels];instance.data.horizontalGridlineColor=properties.horizontal_gridlines_color,instance.data.verticalGridlineColor=properties.vertical_gridlines_color;let horizDashedGridlines=[];properties.horizontal_dashed_gridlines&&(horizDashedGridlines=[8,4]);let vertDashedGridlines=[],showDataLabelsOverlap;properties.vertical_dashed_gridlines&&(vertDashedGridlines=[8,4]),\"Number\"==properties.x_axis_unit?instance.data.xAxisType=\"linear\":instance.data.xAxisType=\"time\",showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\";var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:\"scatter\",data:{labels:undefined,datasets:[{showLine:properties.show_line,stepped:!0,pointRadius:properties.point_radius,pointHoverRadius:properties.point_hover_radius,pointBorderWidth:properties.point_border_width,pointBorderColor:properties.point_border_color,pointStyle:properties.point_style,fill:function(value){return value=!1,false},borderWidth:1,borderColor:properties.series1color,label:properties.series1name,backgroundColor:function(value){return value=properties.series1color},data:series1array,datalabels:{display:showDataLabelsOverlap,color:\"orange\",align:\"end\",anchor:\"end\",clamp:\"true\",rotation:45,formatter:function(value){return value.y},offset:200,borderWidth:\"1\",borderRadius:\"3\",borderColor:\"#000000\",backgroundColor:\"#000000\",padding:\"1\"}}]},options:{dragData:properties.draggable_values,dragX:properties.draggable_values,onDrag:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data,draggedItemAllSeriesValuesX=[],draggedItemAllSeriesValuesY=[];for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i].x&&\" \"!=draggedItemAllSeriesValues[i].x?draggedItemAllSeriesValuesX.push(draggedItemAllSeriesValues[i].x):draggedItemAllSeriesValuesX.push(0),\"\"!=draggedItemAllSeriesValues[i].y&&\" \"!=draggedItemAllSeriesValues[i].y?draggedItemAllSeriesValuesY.push(draggedItemAllSeriesValues[i].y):draggedItemAllSeriesValuesY.push(0);instance.publishState(\"currently_dragging\",!0),instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_ending_y_value\",value.y),instance.publishState(\"dragged_item_ending_x_value\",value.x),instance.publishState(\"dragged_item_all_series_values_y\",draggedItemAllSeriesValuesY),instance.publishState(\"dragged_item_all_series_values_x\",draggedItemAllSeriesValuesX)},onDragEnd:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data,draggedItemAllSeriesValuesX=[],draggedItemAllSeriesValuesY=[];for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i].x&&\" \"!=draggedItemAllSeriesValues[i].x?draggedItemAllSeriesValuesX.push(draggedItemAllSeriesValues[i].x):draggedItemAllSeriesValuesX.push(0),\"\"!=draggedItemAllSeriesValues[i].y&&\" \"!=draggedItemAllSeriesValues[i].y?draggedItemAllSeriesValuesY.push(draggedItemAllSeriesValues[i].y):draggedItemAllSeriesValuesY.push(0);instance.publishState(\"currently_dragging\",!1),instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_ending_y_value\",value.y),instance.publishState(\"dragged_item_ending_x_value\",value.x),instance.publishState(\"dragged_item_all_series_values_y\",draggedItemAllSeriesValuesY),instance.publishState(\"dragged_item_all_series_values_x\",draggedItemAllSeriesValuesX),instance.triggerEvent(\"chart_value_dragged\",(function(err){})),instance.data.justDragged=!0},onDragStart:function(e,element){instance.publishState(\"dragged_item_starting_y_value\",instance.data.datasets[element._datasetIndex].data[element._index].y),instance.publishState(\"dragged_item_starting_x_value\",instance.data.datasets[element._datasetIndex].data[element._index].x)},dragDataRound:properties.drag_data_round,animation:{duration:properties.animation_duration}
176,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},onHover:function(event,elements){if(properties.draggable_values?$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"grab\":\"default\"):$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.backgroundColor;let radius_value;if(null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor),null!=value.t)instance.publishState(\"hovered_item_x_value\",activePoint[0]._xScale._ticks[activePoint[0]._index].value),instance.publishState(\"hovered_item_x_value_date\",JSON.stringify(value.t));else{let valueX=value.x;\"\"==valueX&&(valueX=0),instance.publishState(\"hovered_item_x_value\",valueX)}let valueY=value.y;\"\"==valueY&&(valueY=0),instance.publishState(\"hovered_item_y_value\",valueY),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color);let valuePointLabel=\"\";value.label&&(valuePointLabel=value.label),instance.publishState(\"hovered_item_point_label\",value.label),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))},plugins:{crosshair:{line:{color:properties.vertical_crosshair_color,width:properties.vertical_crosshair_width},sync:{enabled:properties.synced_crosshairs,group:properties.group_number,suppressTooltips:properties.suppress_tooltips},zoom:{enabled:!1}}},maintainAspectRatio:!1,scales:{yAxes:[{stacked:!1,gridLines:{color:instance.data.horizontalGridlineColor,zeroLineColor:properties.y_is_zero_color,tickMarkLength:0,borderDash:horizDashedGridlines,drawBorder:!1},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:properties.show_y_tick_labels,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value;return yLabel=null!=properties.y_labels_decimal_places?parseFloat(value).toFixed(properties.y_labels_decimal_places):value.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.includes(\".\")?yLabel.substring(0,yLabel.indexOf(\".\")).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+properties.decimal_separator+yLabel.substring(yLabel.indexOf(\".\")+1):yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}}}],xAxes:[{type:instance.data.xAxisType,time:{displayFormats:{millisecond:properties.x_axis_date_format,second:properties.x_axis_date_format,minute:properties.x_axis_date_format,hour:properties.x_axis_date_format,day:properties.x_axis_date_format,week:properties.x_axis_date_format,month:properties.x_axis_date_format,quarter:properties.x_axis_date_format,year:properties.x_axis_date_format}},stacked:!1,gridLines:{color:instance.data.verticalGridlineColor,zeroLineColor:properties.x_is_zero_color,tickMarkLength:0,borderDash:vertDashedGridlines,drawBorder:!1},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let xLabel=value;return xLabel=null!=properties.x_labels_decimal_places?parseFloat(value).toFixed(properties.x_labels_decimal_places):value.toString(),null!=properties.thousands_separator&&\"Number\"===properties.x_axis_unit&&(xLabel=xLabel.includes(\".\")?xLabel.substring(0,xLabel.
176indexOf(\".\")).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+properties.decimal_separator+xLabel.substring(xLabel.indexOf(\".\")+1):xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.xAxisUnitBeforeNumber&&(xLabel=properties.xAxisUnitBeforeNumber+xLabel),properties.xAxisUnitAfterNumber&&(xLabel+=properties.xAxisUnitAfterNumber),xLabel}}}]},layout:{padding:{right:properties.chart_padding,left:properties.chart_padding,top:properties.chart_padding,bottom:properties.chart_padding}},tooltips:{intersect:!1,enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let label=\"\";data.datasets[tooltipItem.datasetIndex].label&&(label+=data.datasets[tooltipItem.datasetIndex].label,label+=\": \");let currentLabel,commaYLabel=tooltipItem.yLabel.toString();null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator));let currentXLabel,commaXLabel=tooltipItem.xLabel.toString();if(null!=properties.thousands_separator&&(commaXLabel=commaXLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.unit_before_x&&(commaYLabel=properties.unit_before_x+commaYLabel),label+=commaYLabel,properties.unit_after_x&&(label+=properties.unit_after_x),label+=\", \",properties.unit_before_y&&(commaXLabel=properties.unit_before_y+commaXLabel),properties.unit_after_y&&(commaXLabel+=properties.unit_after_y),label+=commaXLabel,\"Date and time\"!=properties.x_axis_unit)return label;if(\"Date and time\"==properties.x_axis_unit){let formattedXLabel,yValue,finalLabel=tooltipItem.xLabel.replace(/,/g,\"\")+\" \"+tooltipItem.yLabel.toString();return console.log(\"Final Tooltip Output:\",finalLabel),finalLabel}}}}}});null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum),null!=properties.xMinNum&&(chart.options.scales.xAxes[0].ticks.min=properties.xMinNum),null!=properties.xMaxNum&&(chart.options.scales.xAxes[0].ticks.max=properties.xMaxNum),0==properties.vertical_crosshair_on&&(chart.options.plugins.crosshair=!1),null!=properties.x_ticks_rotation&&(chart.options.scales.xAxes[0].ticks.minRotation=properties.x_ticks_rotation,chart.options.scales.xAxes[0].ticks.maxRotation=properties.x_ticks_rotation);var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function pushDataset(dataLabel,newData,newColor,borderColor,pointStyle,pointRadius,showLine,showDatalabels,pointImage,pointColors,borderColors){let myDataset={
176showLine:showLine,pointRadius:pointRadius,pointHoverRadius:properties.point_hover_radius,pointBorderWidth:properties.point_border_width,pointBorderColor:function(context){return null!=borderColors&&borderColors.length>0&&borderColors[context.dataIndex]||borderColor},pointStyle:function(value){return value=pointImage||pointStyle},label:dataLabel,borderWidth:properties.line_border_width,backgroundColor:function(context){return null!=pointColors&&pointColors.length>0&&pointColors[context.dataIndex]||newColor},data:newData,fill:function(value){return value=!1,false},borderColor:newColor,datalabels:{color:function(value){return value=\"Default (Same as Series Color)\"==properties.font_color_setting?newColor:properties.font_color_optional},align:properties.alignment,anchor:\"end\",font:{family:properties.bubble.font_face().split(\":\")[0],size:properties.font_size,weight:properties.datalabel_fontweight},clamp:\"true\",rotation:properties.angle,formatter:function(value){let resultingLabel=\"\";if(!showDatalabels)return resultingLabel;let resultingX=\"\";properties.unit_before_x&&(resultingX+=properties.unit_before_x),resultingX+=value.x,properties.unit_after_x&&(resultingX+=properties.unit_after_x);let resultingY=\"\",resultingPointLabel,labelArray;if(properties.unit_before_y&&(resultingY+=properties.unit_before_y),resultingY+=value.y,properties.unit_after_y&&(resultingY+=properties.unit_after_y),null!=newData[0].label&&null!=value.label&&(resultingPointLabel=value.label),properties.data_label_text&&(labelArray=properties.data_label_text.split(\", \")),properties.data_label_text)for(;labelArray.length>0;)\"seriesName\"==labelArray[0]&&(resultingLabel+=dataLabel),\"x\"==labelArray[0]&&(resultingLabel+=resultingX),\"y\"==labelArray[0]&&(resultingLabel+=resultingY),\"pointLabel\"==labelArray[0]&&(resultingLabel+=resultingPointLabel),labelArray.shift();return resultingLabel},offset:properties.distance_from_point,display:showDataLabelsOverlap}};if(null!=instance.data.datasets&&instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}if(chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.pushDataset=pushDataset,properties.series1xvalues){properties.series1name||(properties.series1name=\"Series 1\"),removeOldSeriesProperty(instance.data.series1_oldname);let showDL=!1;properties.data_label_text&&(showDL=!0),pushDataset(properties.series1name,series1array,properties.series1color,properties.point_border_color,properties.point_style,properties.point_radius,properties.show_line,showDL),instance.data.series1_oldname=properties.series1name}if(properties.series2xvalues){properties.series2name||(properties.series2name=\"Series 2\"),removeOldSeriesProperty(instance.data.series2_oldname);let showDL=!1;properties.data_label_text&&(showDL=!0),pushDataset(properties.series2name,series2array,properties.series2color,properties.series2_point_border_color,properties.series2_point_style,properties.point_radius,properties.show_line,showDL),instance.data.series2_oldname=properties.series2name}if(properties.series3xvalues){properties.series3name||(properties.series3name=\"Series 3\"),removeOldSeriesProperty(instance.data.series3_oldname);let showDL=!1;properties.data_label_text&&(showDL=!0),pushDataset(properties.series3name,series3array,properties.series3color,properties.series3_point_border_color,properties.series3_point_style,properties.point_radius,properties.show_line,showDL),instance.data.series3_oldname=properties.series3name}function updateChartDatasets(){let i;for(chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)chart.data.datasets.push(instance.data.datasets[i])}instance.data.updateChartDatasets=updateChartDatasets,updateChartDatasets(),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;let valueX=value.x;\"\"==valueX&&(valueX=0);let valueY=value.y;\"\"==valueY&&(valueY=0),valueX?instance.publishState(\"clicked_item_x_value\",valueX):instance.publishState(\"clicked_item_x_value\",activePoint[0]._xScale._ticks[activePoint[0]._index].value),instance.publishState(\"clicked_item_y_value\",valueY),instance.publishState(\"clicked_item_series_name\",series_name)}
176series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},chart.update(),instance.data.chart=chart}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Scatter/Connected Scatter/Line Chart';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"ACY":{"display":"Chart - Radar","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AAJ":{"caption":"X Axis Values (comma-separated strings or #s)","default_val":"Category 1, Category 2, Category 3, Category 4, Category 5, Category 6","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":1,"value":"text"},"AAK":{"caption":"Series 1 - y-values","default_val":"52, 59, 34, 21, 10, 35","editor":"DynamicValue","name":"series1","rank":4,"value":"text","optional":true},"AAN":{"caption":"Series 1 - border color","default_val":"rgba(51, 181, 229, 1)","editor":"Color","name":"series1color","rank":5,"optional":false},"AAO":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":3,"value":"text"},"AAa":{"caption":"Tick Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":28,"value":"text"},"AAb":{"caption":"Tick Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":29,"value":"text"},"AAe":{"caption":"Main Axis - Max Value","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":24,"value":"number"},"AAf":{"caption":"Main Axis - Min Value","default_val":0,"editor":"DynamicValue","name":"yMinNum","optional":true,"rank":23,"value":"number"},"AAj":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":12,"value":"text","default_val":"Top"},"ABI":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":37,"value":"boolean"},"ACE":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":22,"editor":"Label"},"ACF":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":0,"editor":"Label"},"ACG":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":11,"editor":"Label"},"ACK":{"caption":"Y Ticks Backgrnd Color","name":"backDropColor","rank":32,"editor":"Color","default_val":"rgba(255, 255, 255, 0)"},"ACL":{"caption":"Gridline Color","name":"y_zero_line_color","rank":33,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ACN":{"caption":"Angled Axis Color","name":"horiz_gridlines_color","rank":34,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ACW":{"caption":"Line Border Width","name":"border_width","rank":18,"editor":"DynamicValue","value":"number","default_val":3},"ACX":{"caption":"Line Curve","name":"curve_line_charts","rank":17,"editor":"DynamicValue","value":"number","default_val":0},"ACZ":{"caption":"Show X Axis Ticks?","name":"show_ticks","rank":26,"editor":"DynamicValue","value":"boolean","default_val":true},"ACm":{"caption":"Thousands Separator","name":"thousands_separator","rank":14,"editor":"DynamicValue","value":"text","default_val":","},"ACw":{"caption":"Dashed Gridlines","name":"dashed_gridlines","rank":35,"editor":"DynamicValue","value":"boolean","default_val":false},"ADI":{"caption":"Show Y Axis Ticks","name":"show_y_axis_ticks","rank":27,"editor":"DynamicValue","value":"boolean","default_val":false},"AIH":{"caption":"Point Radius","name":"point_radius","rank":19,"editor":"DynamicValue","value":"number","default_val":5},"AII":{"caption":"Point Hovered Radius","name":"point_hovered_radius","rank":20,"editor":"DynamicValue","value":"number","default_val":8},"AIJ":{"caption":"Point Border Width","name":"point_border_width","rank":21,"editor":"DynamicValue","value":"number","default_val":2},"AIK":{"caption":"Series 1 - point border Color","name":"series1_point_border_color","rank":6,"editor":"Color","default_val":"rgba(255, 255, 255, 0.94)","optional":false},"AKW":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":16,"editor":"DynamicValue","value":"text","optional":true},"AKy":{"caption":"Main Axis - Max Ticks","name":"max_ticks","rank":25,"editor":"DynamicValue","value":"number","default_val":7}
176,"AVl":{"caption":" Tick Label Font Color","name":"tick_label_color","rank":30,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVm":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":31,"editor":"DynamicValue","value":"number","default_val":12},"AWZ":{"caption":"------------------------- Data Labels -------------------------","name":"-------------------------_data_labels_-------------------------","rank":36,"editor":"Label"},"AWa":{"caption":"Font Size","name":"datalabels_font_size","rank":38,"editor":"DynamicValue","value":"number","default_val":12},"AXI":{"caption":"Series 2 - name","name":"series2name","rank":7,"editor":"DynamicValue","value":"text","default_val":"Series 2","optional":true},"AXJ":{"caption":"Series 2 - border color","name":"series2color","rank":9,"editor":"Color","default_val":"rgba(0, 200, 81, 1)","optional":true},"AXK":{"caption":"Series 2 - point border Color","name":"series2_point_border_color","rank":10,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","optional":true},"AXL":{"caption":"Series 2 - y-values","name":"series2","rank":8,"editor":"DynamicValue","value":"text","optional":true},"AXc":{"caption":"Animation Duration","name":"animation_duration","rank":15,"editor":"DynamicValue","value":"number","default_val":1500},"AYF":{"caption":"â¹ï¸ Add series names and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"â¹ï¸_add_series_names,_colors,_and_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_and_can_be_dynamically_(e.g._\"do_a_search_for\")","rank":2,"editor":"Label"},"AYG":{"caption":"â¹ï¸ To customize Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties","name":"â¹ï¸_to_customize_label_font_family,_scroll_down_to_the_bottom_of_this_properties_menu_and_change_the_standard_bubble_font_properties","rank":39,"editor":"Label"},"AZf":{"caption":"Legend Color Style","name":"legend_color_style","rank":13,"editor":"Dropdown","default_val":"Circle"}},"states":{"AAv":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"ABU":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ABV":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AKX":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AKY":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKZ":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AKb":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ABW":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AKa":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"actions":{"ACa":{"caption":"Add/Update Data Series on Radar Chart","code":{"fn":"function(instance,properties,context){let numAttempts=0;function mainAddSeries(){if(numAttempts>15)console.log(\"The Chart you are trying to update is not visible on the page\");else{if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);addSeries()}function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,properties.point_border_color,properties.fill_color),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}}mainAddSeries()}"},"fields":{"ACb":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"ACc":{"caption":"Series Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ACd":{"caption":"Series Y Values","name":"yValues","rank":4,"editor":"DynamicValue","value":"text"},"AIL":{"caption":"Point Border Color","name":"point_border_color","rank":2,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AWb":{"caption":"Fill Color","name":"fill_color","rank":3,"editor":"Color","default_val":"rgba(51, 179, 230, 0.39)"}}},"ACe":{"caption":"Remove a Data Series from Radar Chart","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update(
176)}else console.log(\"The Chart you are trying to update is not visible on the page\")}"},"fields":{"ACf":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AOM":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop();instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"}}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[]}"},"update":{"fn":"function(instance,properties,context){function reduceOpacity(originalColor,scale){if(6==originalColor.length||7==originalColor.length){function hexToRgb(hex){var result=/^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);return\"rgba(\"+parseInt(result[1],16)+\", \"+parseInt(result[2],16)+\", \"+parseInt(result[3],16)+\", 1)\"}originalColor=hexToRgb(originalColor)}let rgbaValues=originalColor.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+),?\\s*(\\d*(?:\\.\\d+)?)?\\)/);if(rgbaValues){let r,g,b,a,newOpacity,result;return`rgba(${rgbaValues[1]}, ${rgbaValues[2]}, ${rgbaValues[3]}, ${scale*(rgbaValues[4]?parseFloat(rgbaValues[4]):1)})`}return console.error(\"Invalid color format\"),null}Chart.plugins.unregister(ChartDataLabels),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})}));let customTooltip=!1;if(null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas,ctxchart=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\");let chartType=\"radar\",legendState,showLegend;function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\")),xArray}\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),series1string=properties.series1,series1array,series2array,series3array,series4array,series5array,yMin,yMax;series1array=createDataArray(properties.series1),series2array=createDataArray(properties.series2),series3array=createDataArray(properties.series3),series4array=createDataArray(properties.series4),series5array=createDataArray(properties.series5);let allYValuesArray=series1array,chartLabelsOn;properties.show_data_labels&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]),instance.data.horizontalGridlineColor=properties.horiz_gridlines_color;let dashed_gridlines=[];properties.dashed_gridlines&&(dashed_gridlines=[8,5]);var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:\"radar\",data:{labels:arrayofxvalues},options:{plugins:{crosshair:!1},animation:{duration:properties.animation_duration},onHover:function(event,elements){if($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.borderColor;null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor);let valueY=value;\"\"==valueY&&(valueY=0),instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",valueY),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))}
176,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:10,left:10,top:10,bottom:10}},maintainAspectRatio:!1,scale:{pointLabels:{fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,display:properties.show_ticks},gridLines:{color:properties.y_zero_line_color,circular:!1,borderDash:dashed_gridlines},ticks:{padding:7,maxTicksLimit:properties.max_ticks,display:properties.show_y_axis_ticks,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,backdropColor:properties.backDropColor,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],tickMarkLength:0,callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}},angleLines:{color:instance.data.horizontalGridlineColor}},tooltips:{enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{title:function(tooltipItem,data){let tooltipTitle;return data.datasets[tooltipItem[0].datasetIndex].label},label:function(tooltipItem,data){let label=\"\";data.labels[tooltipItem.index]&&(label+=data.labels[tooltipItem.index],label+=\": \");let currentLabel,commaYLabel=tooltipItem.yLabel.toString();return null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(commaYLabel=properties.yAxisUnitBeforeNumber+commaYLabel),label+=commaYLabel,properties.yAxisUnitAfterNumber&&(label+=properties.yAxisUnitAfterNumber),label}}}}}),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function hexToRgbA(hex){var c;if(/^#([A-Fa-f0-9]{3}){1,2}$/.test(hex))return 3==(c=hex.substring(1).split(\"\")).length&&(c=[c[0],c[0],c[1],c[1],c[2],c[2]]),\"rgba(\"+[(c=\"0x\"+c.join(\"\"))>>16&255,c>>8&255,255&c].join(\",\")+\",1)\";throw new Error(\"Bad Hex\")}function pushDataset(dataLabel,newData,newColor,pointBorderColor,fillColor){let seriesBackgroundColor;seriesBackgroundColor=null!=fillColor?fillColor:reduceOpacity(newColor,.5);let myDataset={data:newData,label:dataLabel,backgroundColor:seriesBackgroundColor,fill:\"start\",borderWidth:function(value){return value=properties.border_width},lineTension:properties.curve_line_charts,borderColor:newColor,pointBackgroun
176dColor:newColor,pointBorderColor:pointBorderColor,pointBorderWidth:properties.point_border_width,pointRadius:properties.point_radius,pointHitRadius:8,pointHoverRadius:properties.point_hovered_radius,datalabels:{color:newColor,font:{size:properties.datalabels_font_size},align:\"end\",anchor:\"end\",formatter:function(value){return null!=properties.thousands_separator&&(value=value.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),value},offset:function(value){return value=\"Bar\"==properties.chartType?1:-2},display:!0,borderWidth:\"1\",borderRadius:\"3\",borderColor:function(value){return value=\"Line\"!=properties.chartType?\"rgba(0, 0, 0, 0)\":\"rgba(0, 0, 0, 0.2)\"},backgroundColor:function(value){return value=\"Line\"!=properties.chartType?\"rgba(255, 255, 255, 0.6)\":\"rgba(255, 255, 255, 0.85)\"},padding:\"1\"}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.find((element=>element.label==dataLabel))||instance.data.datasets.push(myDataset)}function updateChartDatasets(){let i;for(chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)chart.data.datasets.push(instance.data.datasets[i])}chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),null!=properties.yMaxNum&&(chart.options.scale.ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scale.ticks.min=properties.yMinNum),instance.data.pushDataset=pushDataset,properties.series1&&pushDataset(properties.series1name,series1array,properties.series1color,properties.series1_point_border_color),properties.series2&&pushDataset(properties.series2name,series2array,properties.series2color,properties.series2_point_border_color),instance.data.updateChartDatasets=updateChartDatasets,updateChartDatasets(),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;let valueY=value;\"\"==valueY&&(valueY=0),instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",valueY),instance.publishState(\"clicked_item_series_name\",series_name)}label&&value&&series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},instance.data.chart=chart,chart.update()}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Radar Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AFt":{"display":"Chart - Bubble","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AFO":{"caption":"Series 1 - x-values","default_val":"518, 729, 109, 258, 200, 410","editor":"DynamicValue","is_list":false,"name":"series1xvalues","rank":3,"value":"text"},"AFP":{"caption":"Series 1 - y-values","default_val":"125, 122, 23, 57, 30, 59","editor":"DynamicValue","name":"series1yvalues","rank":4,"value":"text"},"AFQ":{"caption":"Series 1 - point color","default_val":"rgba(24, 217, 127, 1)","editor":"Color","name":"series1color","rank":7},"AFR":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":2,"value":"text"},"AFS":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":35,"value":"text"},"AFT":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":36,"value":"text"},"AFU":{"caption":"Y Axis - Max Value","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":30,"value":"number"},"AFV":{"caption":"Y Axis - Min Value","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":29,"value":"number"},"AFW":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":18,"value":"text","default_val":"Top"},"AFX":{"caption":"Show Horiz. Gridlines?","default_val":true,"editor":"DynamicValue","name":"showHorizontalGridlines","rank":41,"value":"boolean"},"AFY":{"caption":"Show Vert. Gridlines?","default_val":true,"editor":"DynamicValue","name":"showVerticalGridlines","optional":false,"rank":40,"value":"boolean"},"AFZ":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":38,"editor":"DynamicValue","value":"boolean","default_val":true},"AFa":{"caption":"Show X Tick Labels","name":"show_x_tick_labels","rank":37,"editor":"DynamicValue","value":"boolean","default_val":true},"AFb":{"caption":"X Axis - Min Value","name":"xMinNum","rank":31,"editor":"DynamicValue","value":"number","optional":true},"AFc":{"caption":"X Axis - Max Value","name":"xMaxNum","rank":32,"editor":"DynamicValue","value":"number","optional":true},"AFd":{"caption":"X Unit - Before","name":"xAxisUnitBeforeNumber","rank":33,"editor":"DynamicValue","value":"text","optional":true},"AFe":{"caption":"X Unit - After","name":"xAxisUnitAfterNumber","rank":34,"editor":"DynamicValue","value":"text","optional":true},"AFf":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"to_add_more_dataset_series,_go_to_your_workflow_tab_and_choose_the_\"add_a_data_series_scatter/pointchart\"_action!","rank":16,"editor":"Label"},"AFi":{"caption":"----------------------------- Chart Data -----------------------------","name":"--------------------------_data_series_values_---------------------------_(you_can_also_add_infinite_series_via_workflows)_-----","rank":0,"editor":"Label"},"AFj":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":17,"editor":"Label"},"AFk":{"caption":"Thousand Separator X","name":"thousands_separator","rank":20,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AFl":{"caption":"Point Border Width","name":"point_border_width","rank":23,"editor":"DynamicValue","value":"number","default_val":12},"AFm":{"caption":"Series 1 - point style","name":"point_style","rank":6,"editor":"Dropdown","default_val":"circle"},"AFn":{"caption":"Series 1 - point border","name":"point_border_color","rank":8,"editor":"Color","default_val":"rgba(21, 217, 129, 0.26)"},"AFo":{"caption":"Horiz. Dashed Gridlines?","name":"horizontal_dashed_gridlines","rank":42,"editor":"DynamicValue","value":"boolean","default_val":true},"AFp":{"caption":"Vert. Dashed Gridlines?","name":"vertical_dashed_gridlines","rank":43,"editor":"DynamicValue","value":"boolean","default_val":true}
176,"AFu":{"caption":"Series 1 - radius values - px (comma-separated list)","name":"series1radiusvalues","rank":5,"editor":"DynamicValue","value":"text","default_val":"10, 25, 5, 18, 15, 8"},"AKL":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AKf":{"caption":"------------------------------- Axes Settings -------------------------","name":"--------------------------_axes_and_gridline_settings_---------------------_(you_can_also_add_infinite_series_via_workflows)_-----","rank":28,"editor":"Label"},"AKg":{"caption":"Horiz. Gridline Color","name":"horiz_gridline_color","rank":44,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AKh":{"caption":"Vert Gridline Color","name":"vert_gridline_color","rank":45,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AKi":{"caption":"----------------------------- Gridline Settings -----------------------","name":"-----------------------------Gridline----------------------","rank":39,"editor":"Label"},"AKj":{"caption":"X = 0 Line Color","name":"horiz_zero_line_color","rank":46,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AKk":{"caption":"Y = 0 Line Color","name":"vert_zero_line_color","rank":47,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AKl":{"caption":"Max X Ticks","name":"max_x_ticks","rank":48,"editor":"DynamicValue","value":"number","default_val":11},"AKm":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":49,"editor":"DynamicValue","value":"number","default_val":11},"ANw":{"caption":"----------------------------- Data Labels ---------------------------","name":"-------_data_labels_------","rank":53,"editor":"Label"},"ANx":{"caption":"Data Label Text","name":"data_label_text","rank":54,"editor":"DynamicValue","value":"text","optional":true},"ANy":{"caption":"Alignment","name":"alignment","rank":57,"editor":"DynamicValue","value":"text","default_val":"end"},"ANz":{"caption":"Distance From Point","name":"distance_from_point","rank":58,"editor":"DynamicValue","value":"number","default_val":0},"AOA":{"caption":"Angle","name":"angle","rank":59,"editor":"DynamicValue","value":"number","default_val":0},"AOB":{"caption":"Unit Before X","name":"unit_before_x","rank":60,"editor":"DynamicValue","value":"text","optional":true},"AOC":{"caption":"Unit Before Y","name":"unit_before_y","rank":62,"editor":"DynamicValue","value":"text","optional":true},"AOD":{"caption":"Unit After X","name":"unit_after_x","rank":61,"editor":"DynamicValue","value":"text","optional":true},"AOE":{"caption":"Unit After Y","name":"unit_after_y","rank":63,"editor":"DynamicValue","value":"text","optional":true},"AOF":{"caption":"Unit Before R","name":"unit_before_r","rank":64,"editor":"DynamicValue","value":"text","optional":true},"AOG":{"caption":"Unit After R","name":"unit_after_r","rank":65,"editor":"DynamicValue","value":"text","optional":true},"AOH":{"caption":"Font Color Setting","name":"font_color_setting","rank":66,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"AOI":{"caption":"Font Color (Optional)","name":"font_color_optional","rank":67,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AOJ":{"caption":"Font Size","name":"font_size","rank":68,"editor":"DynamicValue","value":"text","default_val":"12"},"AVn":{"caption":"Tick Label Font Color","name":"tick_label_color","rank":51,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVo":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":52,"editor":"DynamicValue","value":"number","default_val":12},"AWN":{"caption":"X Tick Labels Rotation","name":"x_ticks_rotation","rank":50,"editor":"DynamicValue","value":"number","optional":true},"AWx":{"caption":"Series 2 - name","name":"series2name","rank":9,"editor":"DynamicValue","value":"text","default_val":"Series 2","optional":true},"AWy":{"caption":"Series 2 - point color","name":"series2color","rank":14,"editor":"Color","default_val":"rgba(51, 181, 229, 1)","optional":true},"AWz":{"caption":"Series 2 - point border color","name":"series2_point_border_color","rank":15,"editor":"Color","default_val":"rgba(51, 179, 230, 0.23)","optional":true},"AXA":{"caption":"Series 2 - point style","name":"series2_point_style","rank":13,"editor":"Dropdown","default_val":"circle"},"AXB":{"caption":"Series 2 - x-values","name":"series2xvalues","rank":10,"editor":"DynamicValue","value":"text","optional":true},"AXC":{"caption":"Series 2 - y-values","name":"series2yvalues","rank":11,"editor":"DynamicValue","value":"text","optional":true},"AXD":{"caption":"Series 2 - radius values","name":"series2radiusvalues","rank":12,"editor":"DynamicValue","value":"text","optional":true}
176,"AYE":{"caption":"â¹ï¸ Add series names and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"â¹ï¸_add_series_names,_colors,_and_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_and_can_be_dynamically_(e.g._\"do_a_search_for\")","rank":1,"editor":"Label"},"AYT":{"caption":"Chart Padding","name":"chart_padding","rank":27,"editor":"DynamicValue","value":"number","default_val":10},"AYU":{"caption":"â ï¸ If data points get cut of near edges of the chart element, increase the Chart Padding below","name":"â ï¸_if_data_points_get_cut_of_near_edges_of_the_chart_element,_increase_the_chart_padding_below","rank":26,"editor":"Label"},"AZg":{"caption":"Legend Color Style","name":"legend_color_style","rank":19,"editor":"Dropdown","default_val":"Circle"},"AsF":{"caption":"Thousand Separator Y","name":"thousand_separator_y","rank":21,"editor":"DynamicValue","value":"text","optional":true,"default_val":","},"Atp":{"caption":"Hide Overlap'd Labels","name":"hide_overlapped_labels","rank":55,"editor":"DynamicValue","value":"boolean","default_val":false},"Atq":{"caption":"Hide if R less than","name":"hide_if_r_less_than","rank":56,"editor":"DynamicValue","value":"number","optional":true},"Atr":{"caption":"Draggable Values?","name":"draggable_values","rank":24,"editor":"DynamicValue","value":"boolean","default_val":false},"AuE":{"caption":"Drag Data Round","name":"drag_data_round","rank":25,"editor":"DynamicValue","value":"number","default_val":1,"optional":true}},"states":{"AFq":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"number"},"AFr":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AFs":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AGA":{"caption":"Clicked Item Radius Value","name":"clicked_item_radius_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKM":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKN":{"caption":"Hovered item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKO":{"caption":"Hovered Item Radius Value","name":"hovered_item_radius_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKP":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AKQ":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Ats":{"caption":"Currently Dragging","name":"currently_dragging","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Att":{"caption":"Dragged Item Data Series Name","name":"dragged_item_data_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Atu":{"caption":"Dragged Item Index Number","name":"dragged_item_index_number","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Atv":{"caption":"Dragged Item Ending Y Value","name":"dragged_item_ending_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Atw":{"caption":"Dragged Item Ending X Value ","name":"dragged_item_ending_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Atx":{"caption":"Dragged Item Ending R Value","name":"dragged_item_ending_r_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Aty":{"caption":"Dragged Item - all Y Values of this Serie","name":"dragged_item_all_series_values_y","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Atz":{"caption":"Dragged Item - all X Values of this Serie","name":"dragged_item_all_series_values_x","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AuA":{"caption":"Dragged Item - all R Values of this Serie","name":"dragged_item_all_series_values_r","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AuB":{"caption":"Dragged Item Starting Y Value","name":"dragged_item_starting_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AuC":{"caption":"Dragged Item Starting X Value","name":"dragged_item_starting_x_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AuD":{"caption":"Dragged Item Starting R Value","name":"dragged_item_starting_r_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AFN":{"caption":"Chart Value Clicked","name":"chart_value_clicked"}},"actions":{"AFD":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){let numAttempts=0;function mainAddSeries(){if(!(numAttempts>15)){if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);instance.data.createPointArray?addSeries():setTimeout(addSeries,1500)}function addSeries(){let seriesArray=[],pointColorsArray,pointBorderColorsArray;instance.data.createPointArray(properties.xValues,properties.yValues,properties.radiusValues,seriesArray,properties.point_labels),properties.point_colors&&(point
176ColorsArray=instance.data.splitTextOnCommas(properties.point_colors)),properties.point_border_colors&&(pointBorderColorsArray=instance.data.splitTextOnCommas(properties.point_border_colors)),instance.data.pushDataset(properties.series_name,seriesArray,properties.series_color,properties.point_border_color,properties.point_style,properties.display_data_labels,pointColorsArray,pointBorderColorsArray),instance.data.updateChartDatasets(),instance.data.chart.update()}}mainAddSeries()}","add_debugger":false},"fields":{"AFE":{"caption":"Y-Values (comma-separated numbers)","name":"yValues","rank":4,"editor":"DynamicValue","value":"text"},"AFF":{"caption":"X-Values (comma-separated numbers)","name":"xValues","rank":3,"editor":"DynamicValue","value":"text"},"AFG":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"AFH":{"caption":"Series Point Color","name":"series_color","rank":11,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AFI":{"caption":"Point Style","name":"point_style","rank":10,"editor":"Dropdown","default_val":"circle"},"AFJ":{"caption":"Point Border Color","name":"point_border_color","rank":12,"editor":"Color","default_val":"rgba(51, 179, 230, 0.73)"},"AFv":{"caption":"Radius-Values (comma-separated numbers)","name":"radiusValues","rank":5,"editor":"DynamicValue","value":"text"},"AOL":{"caption":"Display Data Label","name":"display_data_label","rank":2,"editor":"DynamicValue","value":"boolean","optional":false,"default_val":false},"ARW":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"ARX":{"caption":"------------------------ Point Style Settings -----------------------","name":"------------------------_point_style_settings_-----------------------","rank":9,"editor":"Label"},"AsE":{"caption":"Point Labels","name":"point_labels","rank":6,"editor":"DynamicValue","value":"text","optional":true},"Atm":{"caption":"Optional: Point Colors (if different color per point in series)","name":"point_colors","rank":7,"editor":"DynamicValue","value":"text","optional":true},"Atn":{"caption":"Optional: Point Border Colors (if different color per point in series)","name":"point_border_colors","rank":8,"editor":"DynamicValue","value":"text","optional":true},"Ato":{"caption":"Display Data Labels?","name":"display_data_labels","rank":13,"editor":"DynamicValue","value":"boolean","default_val":false}}},"AFL":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.datasets.find((element=>element.label==properties.series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"},"fields":{"AFM":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AOP":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"}}},"code":{"initialize":{"fn":"function(instance,context){function loadScriptOnce(src){if(!document.querySelector(`script[src=\"${src}\"]`)){const script=document.createElement(\"script\");script.src=src,script.defer=!0,document.head.appendChild(script)}}loadScriptOnce(\"https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.4/Chart.bundle.min.js\"),instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'>
176<canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function updateChartDatasets(){let i;for(instance.data.chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)instance.data.chart.data.datasets.push(instance.data.datasets[i])}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[],instance.data.updateChartDatasets=updateChartDatasets}"},"update":{"fn":"function(instance,properties,context){Chart.plugins.unregister(ChartDataLabels),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})}));let customTooltip=!1;function reduceOpacity(originalRGBAColor){let stringlength=originalRGBAColor.length-1,colorArray=(originalRGBAColor=originalRGBAColor.substring(5,stringlength)).split(\", \"),newOpacity=.5*colorArray[3],result;return\"rgba(\"+colorArray[0]+\", \"+colorArray[1]+\", \"+colorArray[2]+\", \"+newOpacity+\")\"}if(null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas,ctxchart=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\");let chartType,legendState,showLegend;function splitTextOnCommas(text){return text.split(\",\").map((item=>item.trim()))}function createPointArray(xString,yString,radiusString,outputArray,labelString){let xArray,yArray,radiusArray,labelArray;if(null!=xString&&(xArray=xString.split(\",\")),null!=yString&&(yArray=yString.split(\",\")),null!=radiusString&&(radiusArray=radiusString.split(\",\")),null!=labelString&&(labelArray=labelString.split(\", \")),null!=xArray&&null!=yArray)for(let i=0;i<xArray.length;i++){let nextPoint={x:xArray[i],y:yArray[i],r:parseInt(radiusArray[i]),...null!=labelString&&{label:labelArray[i]}};outputArray.push(nextPoint)}}\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.splitTextOnCommas=splitTextOnCommas,instance.data.createPointArray=createPointArray;let series1array=[],series2array=[],arrayofxvalues,yMin,yMax;instance.data.createPointArray(properties.series1xvalues,properties.series1yvalues,properties.series1radiusvalues,series1array),instance.data.createPointArray(properties.series2xvalues,properties.series2yvalues,properties.series2radiusvalues,series2array);let allYValuesArray=series1array,chartLabelsOn=[ChartDataLabels];instance.data.horizontalGridlineColor=\"#E0E0E0\",properties.showHorizontalGridlines||(instance.data.horizontalGridlineColor=\"rgba(0,0,0,0)\"),instance.data.verticalGridlineColor=\"#E0E0E0\",properties.showVerticalGridlines||(instance.data.verticalGridlineColor=\"rgba(0,0,0,0)\");let horizDashedGridlines=[];properties.horizontal_dashed_gridlines&&(horizDashedGridlines=[8,4]);let vertDashedGridlines=[];properties.vertical_dashed_gridlines&&(vertDashedGridlines=[8,4]);var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:\"bubble\",data:{labels:undefined,datasets:[{hitRadius:1,borderWidth:properties.point_border_width,borderColor:properties.point_border_color,pointStyle:properties.point_style,fill:function(value){return value=!1,false},label:properties.series1name,backgroundColor:function(value){return value=properties.series1color}}]},options:{animation:{duration:0},dragData:properties.draggable_values,dragX:properties.draggable_values,dragDataRound:properties.drag_data_round,onDragStart:function(e,element){instance.publishState(\"dragged_item_starting_y_value\",instance.data.datasets[element._datasetIndex].data[element._index].y),instance.publishState(\"dragged_item_starting_x_value\",instance.data.datasets[element._datasetIndex].data[element._index].x),instance.publishState(\"dragged_item_starting_r_value\",instance.data.datasets[element._datasetIndex].data[element._index].r)},dragDataRound:properties.drag_data_round,onDrag:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data,draggedItemAllSeriesValuesX=[],draggedItemAllSeriesValuesY=[],draggedItemAllSeriesValuesR=[];for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i].x&&\" \"!=draggedItemAllSeriesValues[i].x?draggedItemAllSeriesValuesX.push(draggedItemAllSeriesValues[i].x):draggedItemAllSeriesValuesX.push(0),\"\"!=draggedItemAllSeriesValues[i].y&&\" \"!=draggedItemAllSeriesValues[i].y?draggedItemAllSeriesValuesY.push(draggedItemAllSeriesValues[i].y):draggedItemAllSeriesValuesY.push(0),\"\"!=draggedItemAllSeriesValues[i].r&&\" \"!=draggedItemAllSeriesValues[i].r?draggedItemAllSeriesValuesR.push(draggedItemAllSeriesValues[i].r):draggedItemAllSeriesValuesR.push(0);instance.publishState(\"currently_dragging\",!0),instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_ending_y_value\",value.y),instance.publishState(\"dragged_item_ending_x_value\",value.x),instance.publishState(\"dragged_item_ending_r_value\",value.r),instance.publishState(\"dragged_item_all_series_values_y\",draggedItemAllSeriesValuesY),instance.publishState(\"dragged_item_all_series_values_x\",draggedItemAllSeriesValuesX),instance.publishState(\"dragged_item_all_series_values_r\",draggedItemAllSeriesValuesR)},onDragEnd:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data,draggedItemAllSeriesValuesX=[],draggedItemAllSeriesValuesY=[],draggedItemAllSeriesValuesR=[];for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i].x&&\" \"!=draggedItemAllSeriesValues[i].x?draggedItemAllSeriesValuesX.push(draggedItemAllSeriesValues[i].x):draggedItemAllSeriesValuesX.push(0),\"\"!=draggedItemAllSeriesValues[i].y&&\" \"!=draggedItemAllSeriesValues[i].y?draggedItemAllSeriesValuesY.push(draggedItemAllSeriesValues[i].y):draggedItemAllSeriesValuesY.push(0),\"\"!=draggedItemAllSeriesValues[i].r&&\" \"!=draggedItemAllSeriesValues[i].r?draggedItemAllSeriesValuesR.push(draggedItemAllSeriesValues[i].r):draggedItemAllSeriesValuesR.push(0);instance.publishState(\"currently_dragging\",!1),instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_ending_y_value\",value.y),instance.publishState(\"dragged_item_ending_x_value\",value.x),instance.publishState(\"dragged_item_ending_r_value\",value.r),instance.publishState(\"dragged_item_all_series_values_y\",draggedItemAllSeriesValuesY),instance.publishState(\"dragged_item_all_series_values_x\",draggedItemAllSeriesValuesX),instance.publishState(\"dragged_item_all_series_values_r\",draggedItemAllSeriesValuesR),instance.triggerEvent(\"chart_value_dragged\",(function(err){})),instance.data.justDragged=!0},plugins:{crosshair:!1},onHover:function(event,elements){if($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.backgroundColor;let radius_value;null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor);let valueX=value.x,valueY=value.y,valueR=value.r;\"\"==valueX&&(valueX=0),\"\"==valueY&&(valueY=0),\"\"==valueR&&(valueR=0),instance.publishState(\"hovered_item_x_value\",valueX),instance.publishState(\"hovered_item_y_value\",valueY),instance.publishState(\"hovered_item_radius_value\",valueR),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))}
176,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:properties.chart_padding,left:properties.chart_padding,top:properties.chart_padding,bottom:properties.chart_padding}},maintainAspectRatio:!1,scales:{yAxes:[{stacked:!1,gridLines:{color:\"rgba(0,0,0,0)\",zeroLineColor:\"rgba(0,0,0,0)\",tickMarkLength:0,borderDash:horizDashedGridlines,drawBorder:!1},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,null!==properties.thousand_separator_y?properties.thousand_separator_y:\"\")),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}}}],xAxes:[{stacked:!1,gridLines:{color:properties.vert_gridline_color,zeroLineColor:properties.horiz_zero_line_color,tickMarkLength:0,borderDash:vertDashedGridlines,drawBorder:!1},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;return value<1&&value>-1&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,null!==properties.thousands_separator?properties.thousands_separator:\"\")),properties.xAxisUnitBeforeNumber&&(xLabel=properties.xAxisUnitBeforeNumber+xLabel),properties.xAxisUnitAfterNumber&&(xLabel+=properties.xAxisUnitAfterNumber),xLabel}}}]},tooltips:{enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let label=\"\";data.datasets[tooltipItem.datasetIndex].label&&(label+=data.datasets[tooltipItem.datasetIndex].label,label+=\": \");let currentLabel,commaYLabel=tooltipItem.yLabel.toString();null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,null!==properties.thousand_separator_y?properties.thousand_separator_y:\"\"));let currentXLabel,commaXLabel=tooltipItem.xLabel.toString();null!=properties.thousands_separator&&(commaXLabel=commaXLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,null!==properties.thousands_separator?properties.thousands_separator:\"\"));let currentRLabel,commaRLabel=data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index].r.toString();return null!=properties.thousands_separator&&(commaRLabel=commaRLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,null!==properties.thousands_separator?properties.thousands_separator:\"\")),properties.unit_before_y&&(commaYLabel=properties.unit_before_y+commaYLabel),label+=commaYLabel,properties.unit_after_x&&(label+=properties.unit_after_x),label+=\", \",properties.unit_before_x&&(commaXLabel=properties.unit_before_x+commaXLabel),properties.unit_after_y&&(commaXLabel+=properties.unit_after_y),label+=commaXLabel,label+=\", \",properties.unit_before_r&&(commaRLabel=properties.unit_before_r+commaRLabel),properties.unit_after_r&&(commaRLabel+=properties.unit_after_r),label+=commaRLabel,label}}}}});null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum),null!=properties.xMinNum&&(chart.options.scales.xAxes[0].ticks.min=properties.xMinNum),null!=properties.xMaxNum&&(chart.options.scales.xAxes[0].ticks.max=properties.xMaxNum);var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function pushDataset(dataLabel,newData,newColor,borderColor,pointStyle,displayDataLabel,pointsColor,borderColorsArray){let myDataset={borderWidth:properties.point_border_width,borderColor:Array.isArray(borderColorsArray)&&borderColorsArray.length>0?borderColorsArray:borderColor,backgroundColor:Array.isArray(pointsColor)&&pointsColor.length>0?pointsColor:newColor,pointStyle:pointStyle,label:dataLabel,data:newData,fill:function(value){return value=!1,false},datalabels:{color:function(value){return value=\"Default (Same as Series Color)\"==properties.font_color_setting?newColor:properties.font_color_optional},align:properties.alignment,anchor:\"end\",font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.font_size},clamp:\"true\",rotation:properties.angle,display:displayDataLabel,formatter:function(value){let resultingLabel=\"\",resultingX=\"\";properties.unit_before_x&&(resultingX+=properties.unit_before_x),resultingX+=value.x,properties.unit_after_x&&(resultingX+=properties.unit_after_x);let resultingY=\"\";properties.unit_before_y&&(resultingY+=properties.unit_before_y),resultingY+=value.y,properties.unit_after_y&&(resultingY+=properties.unit_after_y);let resultingR=\"\",resultingPointLabel,labelArray;
176if(properties.unit_before_r&&(resultingR+=properties.unit_before_r),resultingR+=value.r,properties.unit_after_r&&(resultingR+=properties.unit_after_r),null!=newData[0].label&&null!=value.label&&(resultingPointLabel=value.label),properties.data_label_text&&(labelArray=properties.data_label_text.split(\", \")),properties.data_label_text)for(;labelArray.length>0;)\"seriesName\"==labelArray[0]&&(resultingLabel+=dataLabel),\"x\"==labelArray[0]&&(resultingLabel+=resultingX),\"y\"==labelArray[0]&&(resultingLabel+=resultingY),\"r\"==labelArray[0]&&(resultingLabel+=resultingR),\"pointLabel\"==labelArray[0]&&(resultingLabel+=resultingPointLabel),labelArray.shift();return resultingLabel}}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}function updateStyle(chart){chart.options.scales.yAxes[0].gridLines.zeroLineColor=properties.vert_zero_line_color,chart.options.scales.yAxes[0].ticks.display=properties.show_y_tick_labels,chart.options.scales.yAxes[0].gridLines.color=properties.horiz_gridline_color}function animate1(){instance.data.updateChartDatasets(),updateStyle(chart),instance.data.chart.update()}chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),null!=properties.x_ticks_rotation&&(chart.options.scales.xAxes[0].ticks.minRotation=properties.x_ticks_rotation,chart.options.scales.xAxes[0].ticks.maxRotation=properties.x_ticks_rotation),instance.data.pushDataset=pushDataset,properties.series1xvalues&&(removeOldSeriesProperty(instance.data.series1_oldname),pushDataset(properties.series1name,series1array,properties.series1color,properties.point_border_color,properties.point_style),instance.data.series1_oldname=properties.series1name),properties.series2xvalues&&(removeOldSeriesProperty(instance.data.series2_oldname),pushDataset(properties.series2name,series2array,properties.series2color,properties.series2_point_border_color,properties.series2_point_style),instance.data.series2_oldname=properties.series2name),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;let valueX=value.x,valueY=value.y,valueR=value.r;\"\"==valueX&&(valueX=0),\"\"==valueY&&(valueY=0),\"\"==valueR&&(valueR=0),instance.publishState(\"clicked_item_x_value\",valueX),instance.publishState(\"clicked_item_y_value\",valueY),instance.publishState(\"clicked_item_radius_value\",valueR),instance.publishState(\"clicked_item_series_name\",series_name)}series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},instance.data.chart=chart,setTimeout(animate1,450),instance.data.chart.update()}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Bubble Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AKC":{"display":"Chart - Boxplot","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AIi":{"caption":"X Axis Values (comma-separated strings or #s)","default_val":"January, February, March","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":1,"value":"text"},"AIj":{"caption":"Series 1 - Y-Values (SEMI-COLON-separated numbers)","default_val":"100, 200, 300; 200, 300, 400; 300, 400, 500; 200, 300, 400; 300, 400, 500","editor":"DynamicValue","name":"series1","rank":4,"value":"text","optional":true},"AIm":{"caption":"Series 1 - Color","default_val":"rgba(51, 181, 229, 1)","editor":"Color","name":"series1color","rank":3},"AIn":{"caption":"Series 1 - Name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":2,"value":"text"},"AIt":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":18,"value":"text"},"AIu":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":19,"value":"text"},"AIv":{"caption":"Y Axis - Max Value","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":17,"value":"number"},"AIw":{"caption":"Y Axis - Min Value","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":16,"value":"number"},"AIx":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":11,"value":"text","default_val":"Top"},"AJF":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":21,"editor":"DynamicValue","value":"boolean","default_val":true},"AJG":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":20,"editor":"DynamicValue","value":"boolean","default_val":true},"AJH":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":15,"editor":"Label"},"AJI":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":0,"editor":"Label"},"AJJ":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":9,"editor":"Label"},"AJK":{"caption":"X Zero Line Width","name":"x_zero_line_width","rank":28,"editor":"DynamicValue","value":"number","default_val":1},"AJL":{"caption":"Y Zero Line Width","name":"y_zero_line_width","rank":29,"editor":"DynamicValue","value":"number","default_val":1},"AJM":{"caption":"X = Zero Line Color","name":"x_zero_line_color","rank":30,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AJN":{"caption":"Y = Zero Line Color","name":"y_zero_line_color","rank":31,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AJO":{"caption":"Vert Gridlines Color","name":"vert_gridlines_color","rank":24,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AJP":{"caption":"Horiz Gridlines Color","name":"horiz_gridlines_color","rank":25,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AJQ":{"caption":"Boxplot Border Width","name":"border_width","rank":35,"editor":"DynamicValue","value":"number","default_val":3},"AJV":{"caption":"Thousands Separator","name":"thousands_separator","rank":13,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AJW":{"caption":"Horiz. Dash Gridlines","name":"horizontal_dashed_gridlines","rank":26,"editor":"DynamicValue","value":"boolean","default_val":false},"AJX":{"caption":"Vert. Dash Gridlines","name":"vertical_dashed_gridlines","rank":27,"editor":"DynamicValue","value":"boolean","default_val":false},"AJe":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":14,"editor":"DynamicValue","value":"text","optional":true},"AJj":{"caption":"--------------------- Boxplot Style Settings ---------------------","name":"---------------------------Line---------------------------","rank":34,"editor":"Label"},"AJl":{"caption":"Boxplot Width","name":"bar_width","rank":36,"editor":"DynamicValue","value":"number","default_val":0.7},"AJm":{"caption":"Category Width","name":"category_width","rank":37,"editor":"DynamicValue","value":"number","default_val":0.8},"AKD":{"caption":"Chart Type","name":"chart_type_boxplot","rank":10,"editor":"Dropdown","value":"text","default_val":"Boxplot"},"AKn":{"caption":"Max X Ticks","name":"max_x_ticks","rank":32,"editor":"DynamicValue","value":"number","default_val":11},"AKo":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":33,"editor":"DynamicValue","value":"number","default_val":11},"AVp":{"caption":"Tick Label Color","name":"tick_label_color","rank":22,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVq":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":23,"editor":"DynamicValue","value":"number","default_val":12},"AXE":{"caption":"Series 2 - Name","name":"series2name","rank":5,"editor":"DynamicValue","value":"text","optional":false,"default_val":"Series 2"},"AXF":{"caption":"Series 2 - Color","name":"series2color","rank":6,"editor":"Color","default_val":"rgba(0, 200, 81, 1)"},"AXG":{"caption":"Series 2 - Y-Values (SEMI-COLON-separated numbers)","name":"series2","rank":7,"editor":"DynamicValue","value":"text","optional":true},"AXH":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"***_if_you_need_to_add_more_series_to_the_chart,_you_can_add_infinite_series_via_w
176orkflow_actions","rank":8,"editor":"Label"},"AZh":{"caption":"Legend Color Style","name":"legend_color_style","rank":12,"editor":"Dropdown","default_val":"Circle"}},"states":{"AJn":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"AJo":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AJp":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AJq":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AJr":{"caption":"Hovered Item Y Min","name":"hovered_item_y_min","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AJs":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AJt":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AJu":{"caption":"Clicked Item Series Color","name":"clicked_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AJv":{"caption":"Clicked Item Other Series Values","name":"click_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AJw":{"caption":"Clicked Item Other Series Colors","name":"clicked_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AJx":{"caption":"Clicked Item Other Series Names","name":"clicked_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AJy":{"caption":"Hovered Item Other Series Values","name":"hovered_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AJz":{"caption":"Hovered Item Other Series Colors","name":"hovered_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AKA":{"caption":"Hovered Item Other Series Names","name":"hovered_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AKE":{"caption":"Hovered Item Y Q1","name":"hovered_item_y_q1","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKF":{"caption":"Hovered Item Y Median","name":"hovered_item_y_median","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKG":{"caption":"Hovered Item Y Q3","name":"hovered_item_y_q3","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AKH":{"caption":"Hovered Item Y Max","name":"hovered_item_y_max","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AIg":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AIh":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"actions":{"AIZ":{"caption":"Add a Data Series","code":{"fn":"function(instance,properties,context){let numAttempts=0;function mainAddSeries(){if(numAttempts>15)console.log(\"The Chart you are trying to update is not visible on the page\");else{if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);addSeries()}function addSeries(){if(instance.data.convertStringToArrayOfArrays){let newSeries=instance.data.convertStringToArrayOfArrays(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}}mainAddSeries()}"},"fields":{"AIa":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"AIb":{"caption":"Series Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AIc":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"}}},"AIe":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update(
176)}else console.log(\"The Chart you are trying to update is not visible on the page\")}"},"fields":{"AIf":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}}},"code":{"initialize":{"fn":"function(instance,context){function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy),instance.data.chartcanvas2=document.getElementById(instance.data.uniqueChartId),instance.data.ctxChartState=instance.data.chartcanvas2.getContext(\"2d\"),instance.data.datasets=[],setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){Chart.plugins.unregister(ChartDataLabels);var script=document.createElement(\"script\");script.src=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1626696512600x242171415776436740/bpcharts232.js\",script.addEventListener(\"load\",(function(){null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id);let chartType=properties.chart_type_boxplot.toLowerCase();function reduceOpacity(originalRGBAColor){const rgbaValues=originalRGBAColor.match(/\\d+(\\.\\d+)?/g),r=undefined,g=undefined,b=undefined,a=undefined,newA=undefined,newRgbaColor=undefined;return`rgba(${parseInt(rgbaValues[0],10)},${parseInt(rgbaValues[1],10)},${parseInt(rgbaValues[2],10)},${.5*parseFloat(rgbaValues[3])})`}if(\"horizontal boxplot\"==chartType&&(chartType=\"horizontalBoxplot\"),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId);instance.data.mainChartCanvas=chartcanvas;var ctxchart=chartcanvas.getContext(\"2d\");let legendState,showLegend;function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\")),xArray}\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),chartLabelsOn,series1array,series2array;function convertStringToArrayOfArrays(str){var arr=str.split(\";\").map((function(item){return item.trim()})),seriesArray=[];return $.each(arr,(function(k,v){var a=v.split(\",\").map((function(item){return parseFloat(item.trim(),10)}));seriesArray.push(a)})),seriesArray}properties.show_data_labels&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]),instance.data.convertStringToArrayOfArrays=convertStringToArrayOfArrays,properties.series1&&(series1array=convertStringToArrayOfArrays(properties.series1)),properties.series2&&(series2array=convertStringToArrayOfArrays(properties.series2)),instance.data.horizontalGridlineColor=properties.horiz_gridlines_color,instance.data.verticalGridlineColor=properties.vert_gridlines_color;let horizDashed=[],vertDashed=[];properties.horizontal_dashed_gridlines&&(horizDashed=[8,4]),properties.vertical_dashed_gridlines&&(vertDashed=[8,4]);let customTooltip=!1,tooltipBackgroundColor,tooltipTitleColor,tooltipBodyColor;null!=properties.custom_tooltip_id&&(customTooltip=!0),customTooltip?(tooltipBackgroundColor=\"rgba(0, 0, 0, 0)\",tooltipTitleColor=\"rgba(0, 0, 0, 0)\",tooltipBodyColor=\"rgba(0, 0, 0, 0)\"):(tooltipBackgroun
176dColor=\"rgba(0, 0, 0, 0.8)\",tooltipTitleColor=\"#FFFFFF\",tooltipBodyColor=\"#FFFFFF\");let boxplotData={labels:arrayofxvalues,datasets:[]};instance.data.boxplotData=boxplotData;var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:chartType,data:boxplotData,options:{plugins:{crosshair:!1},responsive:!0,maintainAspectRatio:!1,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},onHover:function(event,elements){$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&elements[0]?($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\"):$(\"#\"+properties.custom_tooltip_id).fadeOut(100)},scales:{yAxes:[{gridLines:{borderDash:horizDashed,drawBorder:!1,color:instance.data.horizontalGridlineColor,zeroLineColor:properties.y_zero_line_color,zeroLineWi
176dth:properties.y_zero_line_width,tickMarkLength:0},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:properties.show_y_tick_labels,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&0!=value&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}}}],xAxes:[{gridLines:{borderDash:vertDashed,drawBorder:!1,color:instance.data.verticalGridlineColor,zeroLineColor:properties.x_zero_line_color,tickMarkLength:0,zeroLineWidth:properties.x_zero_line_width},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;return value<1&&value>-1&&0!=value&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(xLabel=properties.yAxisUnitBeforeNumber+xLabel),properties.yAxisUnitAfterNumber&&(xLabel+=properties.yAxisUnitAfterNumber),\"horizontalBar\"==chartType?xLabel:originalXLabel}}}]},tooltips:{displayColors:!customTooltip,backgroundColor:tooltipBackgroundColor,titleFontColor:tooltipTitleColor,bodyFontColor:tooltipBodyColor,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{boxplotLabel:function(item,data,stats,hoveredOutlierIndex){let label=\"\";return label+=data.datasets[item.datasetIndex].label,label+=\": \",label+=item.label,instance.publishState(\"hovered_item_x_value\",item.label),instance.publishState(\"hovered_item_series_name\",data.datasets[item.datasetIndex].label),instance.publishState(\"hovered_item_y_min\",stats.min),instance.publishState(\"hovered_item_y_q1\",stats.q1),instance.publishState(\"hovered_item_y_median\",stats.median),instance.publishState(\"hovered_item_y_q3\",stats.q3),instance.publishState(\"hovered_item_y_max\",stats.max),instance.publishState(\"hovered_item_series_color\",data.datasets[item.datasetIndex].borderColor),label+=\" (Min: \"+stats.min+\", Q1: \"+stats.q1+\", Median: \"+stats.median+\", Q3: \"+stats.q3+\", Max: \"+stats.max,label}}}}});function pushDataset(dataLabel,newData,newColor){let chart_type=properties.chart_type,customType,myDataset={data:newData,label:dataLabel,backgroundColor:reduceOpacity(newColor),borderWidth:properties.border_width,borderColor:newColor,pointBorderColor:\"#FFFFFF\",pointBorderWidth:1,pointRadius:properties.line_point_radius,pointHoverRadius:1.3*properties.line_point_radius,pointHitRadius:5,barPercentage:properties.bar_width,categoryPercentage:properties.category_width,datalabels:{color:function(value){return value=\"Default (Same as Series Color)\"!=properties.font_color_setting?properties.datalabel_font_color:newColor},align:\"end\",font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.datalabel_size,weight:\"bold\"},anchor:properties.datalabel_anchor,formatter:function(value){let commaValue;return null!=properties.thousands_separator&&(commaValue=value.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before&&(commaValue=properties.data_labels_unit_before+commaValue),properties.data_labels_unit_after&&(commaValue+=properties.data_labels_unit_after),commaValue},offset:properties.datalabel_offset,display:!0,borderWidth:\"1\",borderRadius:\"3\",borderColor:function(value){return value=\"rgba(0, 0, 0, 0)\"},backgroundColor:function(value){return value=properties.datalabel_background_color},padding:\"1\"}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}function updateChartDatasets(){let i;for(chart.data.datasets=[],i=0;i<instance.data.datasets.length;
176i++)chart.data.datasets.push(instance.data.datasets[i]),console.log(i),console.log(instance.data.datasets[i].borderColor),instance.data.datasets[i].backgroundColor=reduceOpacity(instance.data.datasets[i].borderColor)}instance.data.chartType=chartType,\"horizontalBoxplot\"!=chartType?(null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum)):(null!=properties.yMaxNum&&(chart.options.scales.xAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.xAxes[0].ticks.min=properties.yMinNum)),instance.data.pushDataset=pushDataset,properties.series1&&(removeOldSeriesProperty(instance.data.series1_oldname),pushDataset(properties.series1name,series1array,properties.series1color),instance.data.series1_oldname=properties.series1name),properties.series2&&(removeOldSeriesProperty(instance.data.series2_oldname),pushDataset(properties.series2name,series2array,properties.series2color),instance.data.series2_oldname=properties.series2name),instance.data.updateChartDatasets=updateChartDatasets,updateChartDatasets(),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(evt);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._model.backgroundColor;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value),instance.publishState(\"clicked_item_series_name\",series_name),instance.publishState(\"clicked_item_series_color\",series_color);let remainingSeriesObjects=chart.data.datasets.slice();remainingSeriesObjects.splice(clickedDatasetIndex,1);let remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex]));instance.publishState(\"click_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"clicked_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"clicked_item_other_series_names\",remainingSeriesNames)}else null!=document.getElementById(properties.custom_tooltip_id)&&$(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))};var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.chartcanvas2.height=properties.bubble.height(),instance.data.chartcanvas2.width=properties.bubble.width(),instance.data.chartcanvas2.style.height=properties.bubble.height().toString()+\"px\",instance.data.chartcanvas2.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.mainChartCanvas.style.borderRadius=properties.bubble.border_roundness(),instance.data.lineWidth=properties.border_width,instance.data.chart=chart,chart.update()})),document.head.appendChild(script)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Boxplot Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"ANb":{"display":"Chart - Candlestick/OHLC","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AMi":{"caption":"Series 1 - X-Values (comma-separated numbers)","default_val":"1, 2, 3","editor":"DynamicValue","is_list":false,"name":"series1xvalues","rank":35,"value":"text"},"AMj":{"caption":"Open (comma-separated numbers)","default_val":"3, 5, 4","editor":"DynamicValue","name":"series1openvalues","rank":36,"value":"text"},"AMk":{"caption":"Up Color","default_val":"rgba(0, 200, 81, 1)","editor":"Color","name":"up_color","rank":32},"AMl":{"caption":"Series - Name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":31,"value":"text"},"AMm":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":15,"value":"text"},"AMn":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":16,"value":"text"},"AMo":{"caption":"Y Axis - Max Value","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":8,"value":"number"},"AMp":{"caption":"Y Axis - Min Value","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":7,"value":"number"},"AMq":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":2,"value":"text","default_val":"Don't Show Legend"},"AMt":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":18,"editor":"DynamicValue","value":"boolean","default_val":true},"AMu":{"caption":"Show X Tick Labels","name":"show_x_tick_labels","rank":17,"editor":"DynamicValue","value":"boolean","default_val":true},"AMv":{"caption":"X Axis - Min Value","name":"xMinNum","rank":9,"editor":"DynamicValue","value":"number","optional":true},"AMw":{"caption":"X Axis - Max Value","name":"xMaxNum","rank":10,"editor":"DynamicValue","value":"number","optional":true},"AMx":{"caption":"X Unit - Before","name":"xAxisUnitBeforeNumber","rank":13,"editor":"DynamicValue","value":"text","optional":true},"AMy":{"caption":"X Unit - After","name":"xAxisUnitAfterNumber","rank":14,"editor":"DynamicValue","value":"text","optional":true},"AMz":{"caption":"To add more dataset series, go to your workflow tab and choose the \"Add a Data Series Scatter/PointChart\" action!","name":"to_add_more_dataset_series,_go_to_your_workflow_tab_and_choose_the_\"add_a_data_series_scatter/pointchart\"_action!","rank":40,"editor":"Label"},"ANA":{"caption":"-------------------------- Data Series Values --------------------------- (You can also add infinite series via workflows) -----","name":"--------------------------_data_series_values_---------------------------_(you_can_also_add_infinite_series_via_workflows)_-----","rank":30,"editor":"Label"},"ANB":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"ANC":{"caption":"Thousands Separator","name":"thousands_separator","rank":3,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AND":{"caption":"Point Border Width","name":"point_border_width","rank":5,"editor":"DynamicValue","value":"number","default_val":1},"ANG":{"caption":"Horiz. Dashed Gridlines?","name":"horizontal_dashed_gridlines","rank":20,"editor":"DynamicValue","value":"boolean","default_val":false},"ANH":{"caption":"Vert. Dashed Gridlines?","name":"vertical_dashed_gridlines","rank":21,"editor":"DynamicValue","value":"boolean","default_val":false},"ANI":{"caption":"Close (comma-separated list)","name":"series1closevalues","rank":37,"editor":"DynamicValue","value":"text","default_val":"10, 5, 20"},"ANJ":{"caption":"Custom Tooltip HTML ID","name":"custom_tooltip_id","rank":4,"editor":"DynamicValue","value":"text","optional":true},"ANK":{"caption":"------------------------------- Axes Settings -------------------------","name":"--------------------------_axes_and_gridline_settings_---------------------_(you_can_also_add_infinite_series_via_w
176orkflows)_-----","rank":6,"editor":"Label"},"ANL":{"caption":"Horiz. Gridline Color","name":"horiz_gridline_color","rank":22,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ANM":{"caption":"Vert Gridline Color","name":"vert_gridline_color","rank":23,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ANN":{"caption":"----------------------------- Gridline Settings -----------------------","name":"-----------------------------Gridline----------------------","rank":19,"editor":"Label"},"ANO":{"caption":"X = 0 Line Color","name":"horiz_zero_line_color","rank":24,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ANP":{"caption":"Y = 0 Line Color","name":"vert_zero_line_color","rank":25,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"ANQ":{"caption":"Max X Ticks","name":"max_x_ticks","rank":26,"editor":"DynamicValue","value":"number","default_val":11},"ANR":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":27,"editor":"DynamicValue","value":"number","default_val":11},"ANc":{"caption":"High (comma-separated list)","name":"series1highvalues","rank":38,"editor":"DynamicValue","value":"text","default_val":"12, 20, 50"},"ANd":{"caption":"Low (comma-separated list)","name":"series1lowvalues","rank":39,"editor":"DynamicValue","value":"text","default_val":"1, 2, 3"},"ANe":{"caption":"Down Color","name":"down_color","rank":33,"editor":"Color","default_val":"rgba(255, 94, 94, 1)"},"ANf":{"caption":"Unchanged Color","name":"unchanged_color","rank":34,"editor":"Color","default_val":"rgba(173, 173, 173, 1)"},"ANg":{"caption":"Chart Type","name":"chart_type","rank":1,"editor":"Dropdown","default_val":"candlestick"},"ANh":{"caption":"X Axis - Date Format","name":"x_axis_date_format","rank":12,"editor":"DynamicValue","value":"text","default_val":"h:mma LLL d, yyyy"},"AVr":{"caption":"Tick Label Color","name":"tick_label_color","rank":28,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVs":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":29,"editor":"DynamicValue","value":"number","default_val":12},"AWc":{"caption":"X Axis Equal Spacing","name":"x_axis_equal_spacing","rank":11,"editor":"DynamicValue","value":"boolean","default_val":false}},"states":{"ANS":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"date"},"ANT":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ANU":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ANV":{"caption":"Clicked Item Radius Value","name":"clicked_item_radius_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ANW":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"date","initialization_code":{"fn":"function(properties,context){}"}},"ANX":{"caption":"Hovered item Open Value","name":"hovered_item_open_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ANY":{"caption":"Hovered Item High Value","name":"hovered_item_high_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ANZ":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ANa":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AWf":{"caption":"Hovered Item Low Value","name":"hovered_item_low_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AWg":{"caption":"Hovered Item Close Value","name":"hovered_item_close_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AMh":{"caption":"Chart Value Clicked","name":"chart_value_clicked"}},"actions":{"AMX":{"caption":"Add a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){function addSeries(){let seriesArray=[];instance.data.createPointArray(properties.xValues,properties.yValues,properties.radiusValues,seriesArray),instance.data.pushDataset(properties.series_name,seriesArray,properties.series_color,properties.point_border_color,properties.point_style,properties.point_radius),instance.data.updateChartDatasets(),instance.data.chart.update(
176)}instance.data.createPointArray?addSeries():setTimeout(addSeries,1500)}else console.log(\"The Chart you are trying to update is not visible on the page\")}","add_debugger":false},"fields":{"AMY":{"caption":"Y-Values (comma-separated numbers)","name":"yValues","rank":5,"editor":"DynamicValue","value":"text"},"AMZ":{"caption":"X-Values (comma-separated numbers)","name":"xValues","rank":4,"editor":"DynamicValue","value":"text"},"AMa":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"AMb":{"caption":"Series Point Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AMc":{"caption":"Point Style","name":"point_style","rank":3,"editor":"Dropdown","default_val":"circle"},"AMd":{"caption":"Point Border Color","name":"point_border_color","rank":2,"editor":"Color","default_val":"rgba(51, 179, 230, 0.73)"},"AMe":{"caption":"Radius-Values (comma-separated numbers)","name":"radiusValues","rank":6,"editor":"DynamicValue","value":"text"}}},"AMf":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.datasets.find((element=>element.label==properties.series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to update is not visible on the page\")}"},"fields":{"AMg":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"}}}},"code":{"initialize":{"fn":"function(instance,context){function updateChartDatasets(){let i;for(instance.data.chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)instance.data.chart.data.datasets.push(instance.data.datasets[i])}function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}$(document).ready((function(){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")})),instance.data.datasets=[],instance.data.updateChartDatasets=updateChartDatasets,setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){Chart.plugins.unregister(ChartDataLabels),$(document).ready((function(){let openValuesArray=properties.series1openvalues.split(\", \"),closeValuesArray=properties.series1closevalues.split(\", \"),highValuesArray=properties.series1highvalues.split(\", \"),lowValuesArray=properties.series1lowvalues.split(\", \"),xTimeValuesArray=[16217424e5,16223472e5,1622952e6];properties.series1xvalues&&(xTimeValuesArray=properties.series1xvalues.split(\",\"));var barCount=openValuesArray.length;let horizDashedGridlines=[];properties.horizontal_dashed_gridlines&&(horizDashedGridlines=[8,4]);let vertDashedGridlines=[];properties.vertical_dashed_gridlines&&(vertDashedGridlines=[8,4]),null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height(),divWidth=$(\"#\"+properties.custom_tooltip_id).width(),xOffset=15,yOffset=divHeight/2;e.clientX+xOffset+divWidth>screen.width&&(xOffset=-1*(25+divWidth),0>e.clientX-(divWidth+25)&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=-15),screen.height<divHeight+e.clientY&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=divHeight+15)),e.clientY-divHeight/2<0&&(yOffset=0),$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+xOffset,top:e.clientY-yOffset,zIndex:1e21})}));let customTooltip=!1;function addDataPoint(itemNum){return{x:parseInt(xTimeValuesArray[itemNum]),o:openValuesArray[itemNum],h:highValuesArray[itemNum],l:lowValuesArray[itemNum],c:closeValuesArray[itemNum]}}function getRandomData(count){var data=[addDataPoint(0)];let i=1;for(;data.length<count;)data.push(addDataPoint(i)),i++;return data}
176if(null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas,ctxchart=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\"),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);chartContainer.parentNode.removeChild(chartContainer),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);let xAxisType=\"time\";properties.x_axis_equal_spacing&&(xAxisType=\"timeseries\"),chartContainer.style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height();var chart=new Chartv301(instance.data.ctxChartState,{type:properties.chart_type,data:{datasets:[{label:properties.series1name,data:getRandomData(barCount),color:{up:properties.up_color,down:properties.down_color,unchanged:properties.unchanged_color},borderColor:{up:properties.up_color,down:properties.down_color,unchanged:properties.unchanged_color}}]},options:{onHover:function(event,elements){for(let i=0;i<xTimeValuesArray.length;i++)event.x>=i*(event.chart.chartArea.width/xTimeValuesArray.length)&&event.x<(i+1)*(event.chart.chartArea.width/xTimeValuesArray.length)&&(instance.publishState(\"hovered_item_x_value\",event.chart._metasets[0]._parsed[i].x),instance.publishState(\"hovered_item_open_value\",event.chart._metasets[0]._parsed[i].o),instance.publishState(\"hovered_item_high_value\",event.chart._metasets[0]._parsed[i].h),instance.publishState(\"hovered_item_low_value\",event.chart._metasets[0]._parsed[i].l),instance.publishState(\"hovered_item_close_value\",event.chart._metasets[0]._parsed[i].c));\"mouseout\"!=event.type?customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\"):$(\"#\"+properties.custom_tooltip_id).fadeOut(100)},plugins:{tooltip:{enabled:!properties.custom_tooltip_id},legend:{display:!1}},maintainAspectRatio:!1,scales:{y:{grid:{display:properties.showHorizontalGridlines,color:properties.horiz_gridline_color,zeroLineColor:properties.horiz_gridline_color,tickMarkLength:0,borderDash:horizDashedGridlines},ticks:{maxTicksLimit:properties.max_y_ticks,display:properties.show_y_tick_labels,color:properties.tick_label_color,font:{size:properties.tick_label_font_size,family:properties.bubble.font_face().split(\":\")[0]},callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}}},x:{type:xAxisType,time:{displayFormats:{millisecond:properties.x_axis_date_format,second:properties.x_axis_date_format,minute:properties.x_axis_date_format,hour:properties.x_axis_date_format,day:properties.x_axis_date_format,week:properties.x_axis_date_format,month:properties.x_axis_date_format,quarter:properties.x_axis_date_format,year:properties.x_axis_date_format}},grid:{color:properties.vert_gridline_color,zeroLineColor:\"#E0E0E0\",tickMarkLength:0,borderDash:vertDashedGridlines},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,color:properties.tick_label_color,font:{size:properties.tick_label_font_size,family:properties.bubble.font_face().split(\":\")[0]}}}}}});chart.update();var update=function(){var dataset=chart.config.data.datasets[0],scaleType=document.getElementById(\"scale-type\").value;
176chart.config.options.scales.y.type=scaleType,chart.update()}}))}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Candlestick/OHLC Chart';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AQJ":{"display":"Chart - Mixed Bar/Line/Area","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AOf":{"caption":"X Axis Values (comma-separated strings or #s)","default_val":"Mon, Tue, Wed, Thu, Fri","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":2,"value":"text"},"AOg":{"caption":"Series 1 - y-values","default_val":"120, 260, 240, 310, 330","editor":"DynamicValue","name":"series1","rank":7,"value":"text","optional":true},"AOh":{"caption":"Series 2 - y-values","editor":"DynamicValue","is_list":false,"name":"series2","optional":true,"rank":13,"value":"text","default_val":"200, 210, 190, 240, 230"},"AOi":{"caption":"Series 3 - y-values","editor":"DynamicValue","name":"series3","optional":true,"rank":17,"value":"text"},"AOj":{"caption":"Series 1 - color","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series1color","rank":8},"AOk":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":4,"value":"text"},"AOm":{"caption":"Series 2 - name","default_val":"Series 2","editor":"DynamicValue","name":"series2name","rank":9,"value":"text","optional":false},"AOn":{"caption":"Series 2 - color","default_val":"rgba(235, 235, 235, 1)","editor":"Color","name":"series2color","rank":12},"AOo":{"caption":"Series 3 - name","default_val":"Series 3","editor":"DynamicValue","name":"series3name","rank":14,"value":"text"},"AOp":{"caption":"Series 3 - color","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":18},"AOq":{"caption":"Y Axis \"A\" - Unit Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":64,"value":"text"},"AOr":{"caption":"Y Axis \"A\" - Unit After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":65,"value":"text"},"AOs":{"caption":"Y Axis \"A\" - Max","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":62,"value":"number"},"AOt":{"caption":"Y Axis \"A\" - Min","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":61,"value":"number"},"AOu":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":36,"value":"text","default_val":"Top"},"AOv":{"caption":"Series 4 - name","default_val":"Series 4","editor":"DynamicValue","name":"series4name","optional":true,"rank":19,"value":"text"},"AOw":{"caption":"Series 4 - color","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":23},"AOx":{"caption":"Series 4 - y-values","editor":"DynamicValue","name":"series4","optional":true,"rank":22,"value":"text"},"AOy":{"caption":"Series 5 - name","default_val":"Series 5","editor":"DynamicValue","name":"series5name","optional":true,"rank":24,"value":"text"},"AOz":{"caption":"Series 5 - color","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":28},"APA":{"caption":"Series 5 - y-values","editor":"DynamicValue","name":"series5","optional":true,"rank":27,"value":"text"},"APB":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":75,"value":"boolean"},"APC":{"caption":"Y Axis \"A\" - Show Ticks?","name":"show_y_tick_labels","rank":60,"editor":"DynamicValue","value":"boolean","default_val":true},"APD":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":45,"editor":"DynamicValue","value":"boolean","default_val":true},"APE":{"caption":"-------------------------- Gridline Settings -------------------------","name":"axis_and_gridline_settings","rank":44,"editor":"Label"},"APF":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":0,"editor":"Label"},"APG":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":35,"editor":"Label"},"APH":{"caption":"X Zero Line Width","name":"x_zero_line_width","rank":51,"editor":"DynamicValue","value":"number","default_val":1},"API":{"caption":"Y Zero Line Width","name":"y_zero_line_width","rank":52,"editor":"DynamicValue","value":"number","default_val":1},"APJ":{"caption":"X = Zero Line Color","name":"x_zero_line_color","rank":53,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"APK":{"caption":"Y = Zero Line Color","name":"y_zero_line_color","rank":54,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"APL":{"caption":"Vert Gridlines Color","name":"vert_gridlines_color","rank":48,"editor":"Color","default_val":"rgba(255, 255, 255, 0)"},"APM":{"caption":"Horiz Gridlines Color","name":"horiz_gridlines_color","rank":47,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"APN":{"caption":"Line Width","name":"border_width","rank":89,"editor":"DynamicValue","value":"number","default_val":3},"APO":{"caption":"Line Curve","name":"curve_line_charts","rank":93,"editor":"DynamicValue","value":"number","default_val":0.3},"APP":{"caption":"\"A\" Labels - Unit Before","name":"data_labels_unit_before","rank":79,"editor":"DynamicValue","value":"text","optional":true},"APQ":{"caption":"\"A\" Labels - Unit After","name":"data_labels_unit_after","rank":80,"editor":"DynamicValue","value":"text","optional":true},"APR":{"caption":"Point Radius","name":"line_point_radius","rank":90,"editor":"DynamicValue","value":"number","default_val":5},"APS":{"caption":"Thousands Separator","name":"thousands_separator","rank":42,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"APT":{"caption":"Horiz. Dash Gridlines","name":"horizontal_dashed_gridlines","rank":49,"editor":"DynamicValue","value":"boolean","default_val":true},"APU":{"caption":"Vert. Dash Gridlines","name":"vertical_dashed_gridlines","rank":50,"editor":"DynamicValue","value":"boolean","default_val":false},"APV":{"caption":"--------------------------- Data Labels ---------------------------","name":"----------------------------_data_labels_----------------------------","rank":74,"editor":"Label"},"APW":{"caption":"Vertical Offset","name":"datalabel_offset","rank":77,"editor":"DynamicValue","value":"number","default_val":3}
176,"APX":{"caption":"Data Label Background Color","name":"datalabel_background_color","rank":83,"editor":"Color","default_val":"rgba(255, 255, 255, 0.32)","optional":false},"APY":{"caption":"Font Color (Optional)","name":"datalabel_font_color","rank":84,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","optional":true},"APZ":{"caption":"Font Color Setting","name":"font_color_setting","rank":85,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"APa":{"caption":"Anchor","name":"datalabel_anchor","rank":76,"editor":"Dropdown","default_val":"end"},"APb":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":38,"editor":"DynamicValue","value":"text","optional":true},"APc":{"caption":"Font Size","name":"datalabel_size","rank":86,"editor":"DynamicValue","value":"number","default_val":12},"APd":{"caption":"Series 6 - name","name":"series6name","rank":29,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 6"},"APe":{"caption":"Series 6 - color","name":"series6color","rank":33,"editor":"Color","default_val":"rgba(59, 227, 129, 1)","optional":true},"APf":{"caption":"Series 6 - y-values","name":"series6","rank":32,"editor":"DynamicValue","value":"text","optional":true},"APg":{"caption":"-------------------- Line/Area Chart Settings ---------------------","name":"---------------------------Line---------------------------","rank":88,"editor":"Label"},"APh":{"caption":"------------------------- Bar Chart Settings ------------------------","name":"-------------------------_barchart_settings_-------------------------","rank":95,"editor":"Label"},"APi":{"caption":"Bar Width (Bar)","name":"bar_width","rank":96,"editor":"DynamicValue","value":"number","default_val":0.5},"APj":{"caption":"Category Width (Bar)","name":"category_width","rank":97,"editor":"DynamicValue","value":"number","default_val":0.5},"APk":{"caption":"Animation Duration","name":"animation_duration","rank":39,"editor":"DynamicValue","value":"number","default_val":1500},"APl":{"caption":"Point Hover Radius","name":"point_hover_radius","rank":91,"editor":"DynamicValue","value":"number","default_val":12},"APm":{"caption":"Point Border Width","name":"point_border_width","rank":92,"editor":"DynamicValue","value":"number","default_val":3},"APn":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":55,"editor":"DynamicValue","value":"number","default_val":11},"APo":{"caption":"Max X Ticks","name":"max_x_ticks","rank":56,"editor":"DynamicValue","value":"number","default_val":11},"APp":{"caption":"Bar Width (px)","name":"bar_width_pixels","rank":98,"editor":"DynamicValue","value":"text","optional":true},"APq":{"caption":"Chart Padding (px)","name":"chart_padding","rank":41,"editor":"DynamicValue","value":"number","default_val":15},"APr":{"caption":"Bar Corner Radius","name":"bar_corner_radius","rank":99,"editor":"DynamicValue","value":"number","default_val":0},"APs":{"caption":"Series 6 - type","name":"series_6_type","rank":30,"editor":"DynamicValue","value":"text","optional":false,"default_val":"Bar"},"AQK":{"caption":"Series 5 - type","name":"series_5_type","rank":25,"editor":"DynamicValue","value":"text","default_val":"Line"},"AQM":{"caption":"Series 4 - type","name":"series_4_type","rank":20,"editor":"DynamicValue","value":"text","default_val":"Line"},"AQN":{"caption":"Series 1 - type","name":"series_1_type","rank":6,"editor":"DynamicValue","value":"text","default_val":"Bar"},"AQO":{"caption":"Series 2 - type","name":"series_2_type","rank":10,"editor":"DynamicValue","value":"text","default_val":"Line"},"AQP":{"caption":"Series 3 - type","name":"series_3_type","rank":15,"editor":"DynamicValue","value":"text","default_val":"Area"},"AQW":{"caption":"-------------------------- Y Axis \"B\" Settings ------------------------","name":"-----------------------_x_axis_settings_----------------------","rank":66,"editor":"Label"},"AQX":{"caption":"------------------------- Y Axis \"A\" Settings ------------------------","name":"-----------------------_y_axis_\"a\"_settings_----------------------","rank":59,"editor":"Label"},"AQY":{"caption":"Y Axis \"B\" - Min","name":"yAxisMinB","rank":68,"editor":"DynamicValue","value":"number","optional":true},"AQZ":{"caption":"Y Axis \"B\" - Max","name":"yAxisMaxB","rank":69,"editor":"DynamicValue","value":"number","optional":true},"AQa":{"caption":"Y Axis \"B\" - Unit Before","name":"yAxisUnitBeforeB","rank":71,"editor":"DynamicValue","value":"text","optional":true},"AQb":{"caption":"Y Axis \"B\" - Unit After","name":"yAxisUnitAfterB","rank":72,"editor":"DynamicValue","value":"text","optional":true},"AQd":{"caption":"Series 6 - y-axis ID","name":"series_6_y_axis_id","rank":31,"editor":"Dropdown","default_val":"A"},"AQf":{"caption":"Series 5 - y-axis ID","name":"series_5_y_axis_id","rank":26,"editor":"Dropdown","default_val":"A"},"AQg":{"caption":"Series 1 - y-axis ID","name":"series_1_y_axis_id","rank":5,"editor":"Dropdown","value":"text","default_val":"A"},"AQh":{"caption":"Series 2 - y-axis ID","name":"series_2_y_axis_id","rank":11,"editor":"Dropdown","value":"text","default_val":"B"},"AQi":{"caption":"Series 3 - y-axis ID","name":"series_3_y_axis_id","rank":16,"editor":"Dropdown","default_val":"A"},"AQj":{"caption":"Series 4 - y-axis ID","name":"series_4_y_axis_id","rank":21,"editor":"Dropdown","default_val":"A"},"ARb":{"caption":"Y Axis \"B\" - Show Ticks?","name":"show_y_tick_labels_b","rank":67,"editor":"DynamicValue","value":"boolean","default_val":true},"ARc":{"caption":"â¹ï¸ To customize Tick Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties","name":"to_customize_tick_label_font_style,_color,_and_size,_you_can_edit_this_element's_font_style,_color,_size_as_you_would_for_a_standard_text_element_(by_scrolling_down_to_the_bottom_of_this_menu_and_editing_the_standard_bubble_properties_for_font,_color,_size)","rank":73,"editor":"Label"},"AVt":{"caption":"Tick Label Font Color","name":"tick_label_color","rank":57,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AVu":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":58,"editor":"DynamicValue","value":"number","default_val":12},"AWL":{"caption":"X Tick Labels Rotation","name":"x_ticks_rotation","rank":46,"editor":"DynamicValue","optional":true,"value":"number"},"AWd":{"caption":"\"B\" Labels - Unit Before","name":"b_data_labels_unit_before","rank":81,"editor":"DynamicValue","value":"text","optional":true},"AWe":{"caption":"\"B\" Labels - Unit After","name":"b_data_labels_unit_after","rank":82,"editor":"DynamicValue","value":"text","optional":true},"AWu":{"caption":"Decimal Place Character","name":"decimal_place_character","rank":43,"editor":"DynamicValue","value":"text","default_val":"."},"AWv":{"caption":"Tick Step Size","name":"step_size_a","rank":63,"editor":"DynamicValue","value":"number","optional":true},"AWw":{"caption":"Tick Step Size","name":"step_size_b","rank":70,"editor":"DynamicValue","value":"number","optional":true},"AXl":{"caption":"Span Gaps?","name":"span_gaps","rank":94,"editor":"DynamicValue","value":"boolean","default_val":true}
176,"AXv":{"caption":"â¹ï¸ Enter you chart's X-Axis values (the X-Axis labels that will go from left to right) separated by comma and space (\", \"). Can be a dynamic expression.","name":"â¹ï¸_enter_you_chart's_x-axis_values_(the_x-axis_labels_that_will_go_from_left_to_right)_separated_by_comma_and_space_(\",_\").__can_be_a_dynamic_expression.","rank":1,"editor":"Label"},"AXw":{"caption":"â¹ï¸ Add series names, colors, and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"â¹ï¸_add_series_names,_colors,_and_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_and_can_be_dynamically_(e.g._\"do_a_search_for\")","rank":3,"editor":"Label"},"AXx":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_add_more_series_to_the_chart_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":34,"editor":"Label"},"AXy":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"â ï¸_if_data_points_get_cut_off_near_edges_of_the_chart_element,_increase_the_chart_padding_below:","rank":40,"editor":"Label"},"AZb":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":87,"editor":"Dropdown","default_val":" 400"},"AZi":{"caption":"Legend Color Style","name":"legend_color_style","rank":37,"editor":"Dropdown","default_val":"Circle"},"Atl":{"caption":"Hide if Less Than","name":"hide_if_less_than","rank":78,"editor":"DynamicValue","value":"number","optional":true}},"states":{"APt":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"APu":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"APv":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"APw":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"APx":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"APy":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"APz":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQA":{"caption":"Clicked Item Series Color","name":"clicked_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQB":{"caption":"Clicked Item All Series Values","name":"click_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQC":{"caption":"Clicked Item All Series Colors","name":"clicked_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQD":{"caption":"Clicked Item All Series Names","name":"clicked_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQE":{"caption":"Hovered Item All Series Values","name":"hovered_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQF":{"caption":"Hovered Item All Series Colors","name":"hovered_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQG":{"caption":"Hovered Item All Series Names","name":"hovered_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AQH":{"caption":"Chart Loaded?","name":"chart_loaded","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}
176,"AQI":{"caption":"Hovered Item X Index","name":"hovered_item_x_index","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AOd":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AOe":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"actions":{"AOV":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){let numAttempts=0;function mainAddSeries(){if(numAttempts>15)return void console.log(\"The Chart you are trying to update is not visible on the page\");if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);let customChartType=instance.data.chartType,backgroundColors;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType,properties.y_axis_id,properties.point_color_line,properties.point_border_color_line,backgroundColors),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}properties.background_colors&&(backgroundColors=instance.data.createDataArray(properties.background_colors)),null!=properties.chart_type&&properties.chart_type.toLowerCase()!=instance.data.chartType&&(customChartType=properties.chart_type.toLowerCase()),addSeries()}mainAddSeries()}"},"fields":{"AOW":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"AOX":{"caption":"Series Color","name":"series_color","rank":5,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AOY":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"AOZ":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true},"AQq":{"caption":"Point Color (line)","name":"point_color_line","rank":7,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AQr":{"caption":"Point Border (line)","name":"point_border_color_line","rank":8,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AQs":{"caption":"Y Axis ID","name":"y_axis_id","rank":4,"editor":"Dropdown","default_val":"A"},"ARS":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"ART":{"caption":"------------------------- Line Series Settings -----------------------","name":"-------------------------_line_chart_settings_-----------------------","rank":6,"editor":"Label"},"Ati":{"caption":"-------------------------- Bar Series Settings -----------------------","name":"--------------------------_bar_series_settings_-----------------------","rank":9,"editor":"Label"},"Atj":{"caption":"Multi-Colored Series (comma-separated hex codes)","name":"background_colors","rank":11,"editor":"DynamicValue","value":"text","optional":true},"Atk":{"caption":"The field below is optional: for multi-colored series (overrides colors set above)","name":"the_field_below_is_optional:_for_multi-colored_series_(overrides_colors_set_above)","rank":10,"editor":"Label"}}},"AOa":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"},"fields":{"AOb":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AOc":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update()}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"}},"AQV":{"caption":"Add a Y Axis","code":{"fn":"function(instance,properties,context){console.log(instance.data.chart.options.scales.yAxes);let anotherYaxis={id:\"test\",position:\"right\"};instance.data.chart.options.scales.yAxes.push(anotherYaxis)}"}},"AsY":{"caption":"Add Annotation","code":{"fn":"function(instance,properties,context){var newAnnotation;\"vertical\"==properties.type?newAnnotation={type:\"line\",mode:\"vertical\",scaleID:\"x-axis-0\",value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"horizontal\"==properties.type?newAnnotation={type:\"line\",mode:\"horizontal\",scaleID:properties.y_axis_id,value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"box\"==properties.type&&(newAnnotation={type:\"box\",xMin:1,xMax:2,yMin:1,yMax:2,backgroundColor:properties.background_color,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}),instance.data.chart.options.annotation||(instance.data.chart.options.annotation={annotations:[]}),instance.data.chart.options.annotation.annotations.push(newAnnotation),instance.data.chart.update(
176)}"},"fields":{"AsZ":{"caption":"Type","name":"type","rank":0,"editor":"Dropdown","default_val":"horizontal"},"Asb":{"caption":"----------------------- General Settings -----------------------","name":"-----------------------_general_settings_-----------------------","rank":1,"editor":"Label"},"Asc":{"caption":"Label text","name":"label","rank":2,"editor":"DynamicValue","value":"text","default_val":"My annotation label"},"Asd":{"caption":"Line Color","name":"line_color","rank":3,"editor":"Color","default_val":"rgba(150, 162, 164, 1)"},"Ase":{"caption":"Position","name":"position","rank":4,"editor":"Dropdown","default_val":"top"},"Asf":{"caption":"Position: Alignment","name":"alignment","rank":5,"editor":"Dropdown","default_val":"start"},"Asg":{"caption":"Position: X Offset","name":"x_offset","rank":6,"editor":"DynamicValue","value":"number","default_val":0},"Ash":{"caption":"Position: Y Offset","name":"y_offset","rank":7,"editor":"DynamicValue","value":"number","default_val":0},"Asi":{"caption":"-------------- Vertical/Horizontal Annotations --------------","name":"--------------_vertical/horizontal_annotations_--------------","rank":8,"editor":"Label"},"Asj":{"caption":"Value","name":"value","rank":9,"editor":"DynamicValue","value":"text","optional":true},"Ask":{"caption":"Border Width","name":"border_width","rank":11,"editor":"DynamicValue","value":"number","default_val":2},"Asl":{"caption":"Y Axis ID (if horizontal annotation)","name":"y_axis_id","rank":10,"editor":"Dropdown","default_val":"A"}}}},"code":{"initialize":{"fn":"function(instance,context){function reduceOpacity(originalRGBAColor,scale){if(6==originalRGBAColor.length||7==originalRGBAColor.length){function hexToRgb(hex){var result=/^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);originalRGBAColor=\"rgba(\"+parseInt(result[1],16)+\", \"+parseInt(result[2],16)+\", \"+parseInt(result[3],16)+\", 1)\"}hexToRgb(originalRGBAColor)}let stringlength=originalRGBAColor.length-1,colorArray=(originalRGBAColor=originalRGBAColor.substring(5,stringlength)).split(\", \"),newOpacity=scale*colorArray[3],result;return\"rgba(\"+colorArray[0]+\", \"+colorArray[1]+\", \"+colorArray[2]+\", \"+newOpacity+\")\"}function updateChartDatasets(){let i;for(instance.data.chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)instance.data.chart.data.datasets.push(instance.data.datasets[i]),instance.data.chartType.includes(\"Area\")&&(instance.data.datasets[i].backgroundColor=instance.data.reduceOpacity(instance.data.datasets[i].borderColor,.5),instance.data.datasets[i].fill=\"origin\"),instance.data.chartType.includes(\"Line\")&&(instance.data.datasets[i].fill=!1)}function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}$(document).ready((function(){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")})),instance.data.datasets=[],instance.data.reduceOpacity=reduceOpacity,instance.data.updateChartDatasets=updateChartDatasets,setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){Chart.plugins.unregister(ChartDataLabels),null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),$(document).ready((function(){if(properties.chartType=\"Bar\",$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId);
176instance.data.mainChartCanvas=chartcanvas;var ctxchart=chartcanvas.getContext(\"2d\");let chartType,legendState,showLegend;function createDataArray(xString){let outputArray,xArray;if(null!=xString&&(xArray=xString.includes(\", \")?xString.split(\", \"):xString.split(\",\"),properties.span_gaps))for(let i=0;i<xArray.length;i++)\"\"==xArray[i]||\" \"==xArray[i]?xArray[i]=null:\" \"==xArray[i].charAt(0)&&(xArray[i]=xArray[i].substring(1));return xArray}chartType=properties.chartType.toLowerCase(),\"Horizontal Bar\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"100% Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Area\"==properties.chartType&&(chartType=\"line\"),\"Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"100% Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"Stacked Area\"==properties.chartType&&(chartType=\"line\"),\"Stepped Line (Step Before)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"before\"),\"Stepped Line (Step After)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"after\"),\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),series1string=properties.series1,series1array,series2array,series3array,series4array,series5array,series6array,yMin,yMax;series1array=createDataArray(properties.series1),series2array=createDataArray(properties.series2),series3array=createDataArray(properties.series3),series4array=createDataArray(properties.series4),series5array=createDataArray(properties.series5),series6array=createDataArray(properties.series6);let allYValuesArray=series1array,chartLabelsOn;properties.show_data_labels&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]),instance.data.horizontalGridlineColor=properties.horiz_gridlines_color,instance.data.verticalGridlineColor=properties.vert_gridlines_color;let horizDashed=[],vertDashed=[];properties.horizontal_dashed_gridlines&&(horizDashed=[8,4]),properties.vertical_dashed_gridlines&&(vertDashed=[8,4]);let hundredPercentStacked=!1;\"100% Stacked Bar (Horizontal)\"!=properties.chartType&&\"100% Stacked Bar\"!=properties.chartType||(hundredPercentStacked=!0);let customTooltip=!1;null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1));var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:chartType,data:{labels:arrayofxvalues},options:{cornerRadius:properties.bar_corner_radius,animation:{duration:properties.animation_duration},spanGaps:properties.span_gaps,onHover:function(event,elements){if($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.borderColor;null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"==remainingSeriesValues[i]&&(remainingSeriesValues[i]=0);instance.publishState(\"hovered_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"hovered_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"hovered_item_other_series_names\",remainingSeriesNames),instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color),instance.publishState(\"hovered_item_x_index\",clickedElementindex+1),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))}
176,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:properties.chart_padding,left:properties.chart_padding,top:properties.chart_padding,bottom:properties.chart_padding}},maintainAspectRatio:!1,scales:{yAxes:[{display:!0,stacked:\"Stacked Bar\"==properties.series_1_type&&properties.series1||\"Stacked Bar\"==properties.series_2_type&&properties.series2||\"Stacked Bar\"==properties.series_3_type&&properties.series3||\"Stacked Bar\"==properties.series_4_type&&properties.series4||\"Stacked Bar\"==properties.series_5_type&&properties.series5||\"Stacked Bar\"==properties.series_6_type&&properties.series6,id:\"A\",position:\"left\",gridLines:{borderDash:horizDashed,drawBorder:!1,color:\"rgba(0,0,0,0)\",zeroLineColor:\"rgba(0,0,0,0)\",zeroLineWidth:properties.y_zero_line_width,tickMarkLength:0},ticks:{autoSkip:!0,maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&0!=value&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),yLabel}}},{stacked:\"Stacked Bar\"==properties.series_1_type&&properties.series1||\"Stacked Bar\"==properties.series_2_type&&properties.series2||\"Stacked Bar\"==properties.series_3_type&&properties.series3||\"Stacked Bar\"==properties.series_4_type&&properties.series4||\"Stacked Bar\"==properties.series_5_type&&properties.series5||\"Stacked Bar\"==properties.series_6_type&&properties.series6,id:\"B\",position:\"right\",gridLines:{borderDash:horizDashed,drawBorder:!1,color:\"rgba(0,0,0,0)\",zeroLineColor:\"rgba(0,0,0,0)\",zeroLineWidth:properties.y_zero_line_width,tickMarkLength:0},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&0!=value&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeB&&(yLabel=properties.yAxisUnitBeforeB+yLabel),properties.yAxisUnitAfterB&&(yLabel+=properties.yAxisUnitAfterB),yLabel}}}],xAxes:[{stacked:\"Stacked Bar\"==properties.series_1_type&&properties.series1||\"Stacked Bar\"==properties.series_2_type&&properties.series2||\"Stacked Bar\"==properties.series_3_type&&properties.series3||\"Stacked Bar\"==properties.series_4_type&&properties.series4||\"Stacked Bar\"==properties.series_5_type&&properties.series5||\"Stacked Bar\"==properties.series_6_type&&properties.series6,gridLines:{borderDash:vertDashed,drawBorder:!1,color:instance.data.verticalGridlineColor,zeroLineColor:properties.x_zero_line_color,tickMarkLength:0,zeroLineWidth:properties.x_zero_line_width},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;return value<1&&value>-1&&0!=value&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(xLabel=properties.yAxisUnitBeforeNumber+xLabel),properties.yAxisUnitAfterNumber&&(xLabel+=properties.yAxisUnitAfterNumber),\"horizontalBar\"==chartType?xLabel:originalXLabel}}}]},plugins:{stacked100:{enable:hundredPercentStacked},crosshair:!1},tooltips:{intersect:!1,enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let beforeDecimal=Math.floor(parseFloat(tooltipItem.value));parseFloat(tooltipItem.value)<0&&(beforeDecimal=Math.ceil(parseFloat(tooltipItem.value)));let afterDecimalCalc=parseFloat(tooltipItem.value)-parseFloat(beforeDecimal),numDecimalPlaces,afterDecimal,commaValue;numDecimalPlaces=-1!=tooltipItem.value.indexOf(\".\")?tooltipItem.value.substring(tooltipItem.value.indexOf(\".\")+1).length:0,numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator));let axisID=data.datasets[tooltipItem.datasetIndex].yAxisID,finalLabel;return\"A\"==axisID&&properties.data_labels_unit_before&&(beforeDecimal=properties.data_labels_unit_before+beforeDecimal),\"B\"==axisID&&properties.b_data_labels_unit_before&&(beforeDecimal=properties.b_data_labels_unit_before+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),\"A\"==axisID&&properties.data_labels_unit_after&&(finalLabel+=properties.data_labels_unit_after),\"B\"==axisID&&properties.b_data_labels_unit_after&&(finalLabel+=properties.b_data_labels_unit_after),finalLabel}}}}});instance.data.chartType=chartType,null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum),null!=properties.yAxisMinB&&(chart.options.scales.yAxes[1].ticks.min=properties.yAxisMinB),null!=properties.yAxisMaxB&&(chart.options.scales.yAxes[1].ticks.max=properties.yAxisMaxB),null!=properties.step_size_a&&(chart.options.scales.yAxes[0].ticks.stepSize=properties.step_size_a),null!=properties.step_size_b&&(chart.options.scales.yAxes[1].ticks.stepSize=properties.step_size_b);var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function pushDataset(dataLabel,newData,newColor,customChartType,yAxisID,pointBackgroun
176dColor,pointBorderColor,backgroundColorArray){let chart_type,customType,chartTypeMaster;yAxisID||(yAxisID=\"A\"),chartTypeMaster=\"area\"==customChartType?\"line\":\"stacked bar\"==customChartType?\"bar\":customChartType,\"stepped line (step before)\"==customChartType&&(chartTypeMaster=\"line\",instance.data.steppedLine=\"before\"),\"stepped line (step after)\"==customChartType&&(chartTypeMaster=\"line\",instance.data.steppedLine=\"after\"),chart_type=chartType?customChartType:properties.chart_type;let myDataset={yAxisID:yAxisID,data:newData,customType:undefined,type:chartTypeMaster,label:dataLabel,steppedLine:instance.data.steppedLine,backgroundColor:function(value){return value=customChartType.includes(\"area\")?instance.data.reduceOpacity(newColor,.5):!backgroundColorArray||\"Bar\"!=properties.chartType&&\"Horizontal Bar\"!=properties.chartType?newColor:backgroundColorArray},fill:function(value){return value=!!customChartType.includes(\"area\")&&\"origin\"},borderWidth:function(value){return value=\"line\"==customChartType||\"area\"==customChartType?properties.border_width:0},lineTension:properties.curve_line_charts,borderColor:newColor,pointBorderColor:function(value){return value=pointBorderColor||\"#FFFFFF\"}
176,pointBackgroundColor:function(value){return value=null!=pointBackgroundColor?pointBackgroundColor:newColor},pointBorderWidth:properties.point_border_width,pointRadius:properties.line_point_radius,pointHitRadius:20,pointHoverRadius:properties.point_hover_radius,barPercentage:properties.bar_width,categoryPercentage:properties.category_width,barThickness:properties.bar_width_pixels,datalabels:{color:function(value){return value=\"Default (Same as Series Color)\"!=properties.font_color_setting?properties.datalabel_font_color:newColor},align:\"end\",font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.datalabel_size,weight:properties.datalabel_fontweight},anchor:function(context){return context.dataset.data[context.dataIndex]<0&&\"bar\"==chartTypeMaster?\"end\"==properties.datalabel_anchor?\"start\":\"start\"==properties.datalabel_anchor?\"end\":properties.datalabel_anchor:properties.datalabel_anchor},formatter:function(value){if(value<properties.hide_if_less_than)return\"\";if(\"\"==value||\" \"==value)return\"\";let beforeDecimal=Math.floor(parseFloat(value));parseFloat(value)<0&&(beforeDecimal=Math.ceil(parseFloat(value)));let afterDecimalCalc=parseFloat(value)-parseFloat(beforeDecimal),numDecimalPlaces=0,afterDecimal,commaValue,finalLabel;return null!=value&&-1!=value.indexOf(\".\")&&(numDecimalPlaces=value.substring(value.indexOf(\".\")+1).length),numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before&&\"A\"==yAxisID?parseFloat(value)<0?(parseFloat(value)>-1&&(beforeDecimal=\"0\"+beforeDecimal),beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+properties.data_labels_unit_before+beforeDecimal):beforeDecimal=properties.data_labels_unit_before+beforeDecimal:properties.data_labels_unit_before&&\"B\"==yAxisID?parseFloat(value)<0?(parseFloat(value)>-1&&(beforeDecimal=\"0\"+beforeDecimal),beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+properties.b_data_labels_unit_before+beforeDecimal):beforeDecimal=properties.b_data_labels_unit_before+beforeDecimal:parseFloat(value)<0&&(parseFloat(value)>-1&&(beforeDecimal=\"0\"+beforeDecimal),beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),properties.data_labels_unit_after&&\"A\"==yAxisID&&(finalLabel+=properties.data_labels_unit_after),properties.data_labels_unit_after&&\"B\"==yAxisID&&(finalLabel+=properties.b_data_labels_unit_after),finalLabel},offset:function(context){return context.dataset.data[context.dataIndex]<0&&\"bar\"==chartTypeMaster?-1*(properties.datalabel_offset+1.33*properties.datalabel_size):properties.datalabel_offset},display:!0,borderWidth:\"1\",borderRadius:\"3\",borderColor:function(value){return value=\"Line\"!=properties.chartType?\"rgba(0, 0, 0, 0)\":\"rgba(0, 0, 0, 0.2)\"},backgroundColor:function(value){return value=(properties.chartType,properties.datalabel_background_color)},padding:\"1\"}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}function updateStyle(chart){chart.options.scales.yAxes[0].gridLines.zeroLineColor=properties.y_zero_line_color,chart.options.scales.yAxes[0].ticks.display=properties.show_y_tick_labels,chart.options.scales.yAxes[0].gridLines.color=instance.data.horizontalGridlineColor,chart.options.scales.yAxes[1].gridLines.zeroLineColor=properties.y_zero_line_color,chart.options.scales.yAxes[1].ticks.display=properties.show_y_tick_labels_b}function animate1(){instance.data.updateChartDatasets(),updateStyle(instance.data.chart),instance.data.chart.update(
176)}chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.mainChartCanvas.style.borderRadius=properties.bubble.border_roundness(),instance.data.lineWidth=properties.border_width,null!=properties.x_ticks_rotation&&(chart.options.scales.xAxes[0].ticks.minRotation=properties.x_ticks_rotation,chart.options.scales.xAxes[0].ticks.maxRotation=properties.x_ticks_rotation),instance.data.pushDataset=pushDataset,properties.series1&&properties.series1name?(removeOldSeriesProperty(instance.data.series1_oldname),pushDataset(properties.series1name,series1array,properties.series1color,properties.series_1_type.toLowerCase(),properties.series_1_y_axis_id),instance.data.series1_oldname=properties.series1name):removeOldSeriesProperty(instance.data.series1_oldname),properties.series2&&properties.series2name?(removeOldSeriesProperty(instance.data.series2_oldname),pushDataset(properties.series2name,series2array,properties.series2color,properties.series_2_type.toLowerCase(),properties.series_2_y_axis_id),instance.data.series2_oldname=properties.series2name):removeOldSeriesProperty(instance.data.series2_oldname),properties.series3&&properties.series3name?(removeOldSeriesProperty(instance.data.series3_oldname),pushDataset(properties.series3name,series3array,properties.series3color,properties.series_3_type.toLowerCase(),properties.series_3_y_axis_id),instance.data.series3_oldname=properties.series3name):removeOldSeriesProperty(instance.data.series3_oldname),properties.series4&&properties.series4name?(removeOldSeriesProperty(instance.data.series4_oldname),pushDataset(properties.series4name,series4array,properties.series4color,properties.series_4_type.toLowerCase(),properties.series_4_y_axis_id),instance.data.series4_oldname=properties.series4name):removeOldSeriesProperty(instance.data.series4_oldname),properties.series5&&properties.series5name?(removeOldSeriesProperty(instance.data.series5_oldname),pushDataset(properties.series5name,series5array,properties.series5color,properties.series_5_type.toLowerCase(),properties.series_5_y_axis_id),instance.data.series5_oldname=properties.series5name):removeOldSeriesProperty(instance.data.series5_oldname),properties.series6&&properties.series6name?(removeOldSeriesProperty(instance.data.series6_oldname),pushDataset(properties.series6name,series6array,properties.series6color,properties.series_6_type.toLowerCase(),properties.series_6_y_axis_id),instance.data.series6_oldname=properties.series6name):removeOldSeriesProperty(instance.data.series6_oldname),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(evt);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._model.backgroundColor;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value),instance.publishState(\"clicked_item_series_name\",series_name),instance.publishState(\"clicked_item_series_color\",series_color);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"==remainingSeriesValues[i]&&(remainingSeriesValues[i]=0);instance.publishState(\"click_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"clicked_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"clicked_item_other_series_names\",remainingSeriesNames)}else null!=document.getElementById(properties.custom_tooltip_id)&&$(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},instance.data.chart=chart,setTimeout(animate1,400)})),instance.publishState(\"chart_loaded\",!0)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Mixed Bar/Line/Area Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"AVN":{"display":"List Calculator - Advanced","property_applications":{"resizable":true},"add_is_visible":true,"fields":{"AVO":{"caption":"List 1 - Input HTML id","name":"list_1_html_id","rank":3,"editor":"DynamicValue","value":"text","default_val":"List_1"},"AVP":{"caption":"List 2 - Input HTML id","name":"list_2_html_id","rank":4,"editor":"DynamicValue","value":"text","default_val":"List_2"},"AVQ":{"caption":"List 3 - Input HTML id","name":"list_3_html_id","rank":5,"editor":"DynamicValue","value":"text","default_val":"List_3"},"AVR":{"caption":"List 4 - Input HTML id","name":"list_4_html_id","rank":6,"editor":"DynamicValue","value":"text","default_val":"List_4"},"AVS":{"caption":"List 5 - Input HTML id","name":"list_5_html_id","rank":7,"editor":"DynamicValue","value":"text","default_val":"List_5"},"AVT":{"caption":"List 6 - Input HTML id","name":"list_6_html_id","rank":8,"editor":"DynamicValue","value":"text","default_val":"List_6"},"AVU":{"caption":"List 7 - Input HTML id","name":"list_7_html_id","rank":9,"editor":"DynamicValue","value":"text","default_val":"List_7"},"AVc":{"caption":"This element helps extract input values from repeating groups to populate the data in your charts!","name":"this_element_helps_extract_input_values_from_repeating_groups._to_use_it,_add_a_repeating_group_to_the_page","rank":0,"editor":"Label"},"AVd":{"caption":"The following HTML ids should be added to the HTML id property for inputs in repeating groups on your page","name":"the_following_html_ids_should_be_added_to_the_html_id_property_for_inputs","rank":1,"editor":"Label"},"AVv":{"caption":"For full documentation on how to use this element, visit the following URL: https://techblocksco.bubbleapps.io/advanced-list-calculators","name":"for_full_documentation_on_how_to_use_this_element,_visit_the_following_url:_https://techblocksco.bubbleapps.io/advanced-list-calculators","rank":2,"editor":"Label"},"AYI":{"caption":"List 8 - Input HTML id","name":"list_8_html_id","rank":10,"editor":"DynamicValue","value":"text"}},"states":{"AVV":{"caption":"Output List 1","name":"output_list_1","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVW":{"caption":"Output List 2","name":"output_list_2","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVX":{"caption":"Output List 3","name":"output_list_3","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVY":{"caption":"Output List 4","name":"output_list_4","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVZ":{"caption":"Output List 5","name":"output_list_5","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVa":{"caption":"Output List 6","name":"output_list_6","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AVb":{"caption":"Output List 7","name":"output_list_7","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AYH":{"caption":"Output List 8","name":"output_list_8","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"actions":{"AVe":{"caption":"Get Input Values","code":{"fn":"function(instance,properties,context){instance.data.getValues()}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'List Calculator - Advanced';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){var props={},ctr=1;$.each(properties,(function(k,v){var id=\"List\"+ctr+\"_id\";k.includes(\"list\")&&(props[id]=v,ctr++)}));let list=props;function getValues(){if(document.getElementById(properties.list_1_html_id)||document.getElementById(properties.list_2_html_id)||document.getElementById(properties.list_3_html_id)||document.getElementById(properties.list_4_html_id)||document.getElementById(properties.list_5_html_id)||document.getElementById(properties.list_6_html_id)||document.getElementById(properties.list_7_html_id)||document.getElementById(properties.list_8_html_id)){var lists=[],ctr=1;let arryOfListItems=document.querySelectorAll(\"#\"+properties.list_1_html_id),maxNumListItems=0;for(var i=0;i<arryOfListItems.length;i++)\"none\"!=arryOfListItems[i].parentNode.style.display&&(console.log(arryOfListItems[i]),maxNumListItems++);$.each(list,(function(k,v){var values=[],display=0;$(\"[id='\"+v+\"']\").each((function(){display<maxNumListItems&&(values.push($(this).val()),display++)})),lists.push(values.join(\", \"))})),$.each(lists,(function(k,v){var output=\"output_list_\"+ctr;ctr<9&&instance.publishState(output,v),ctr++}))}else{if(!(instance.data.startTime<instance.data.timeLimit))return console.log(\"Could not find the input element in the repeating group. Make sure it is loaded on the page (set to visible)\"),null;instance.data.startTime+=50,setTimeout(getValues,50)}}instance.data.timeLimit=15e3,instance.data.startTime=0,instance.data.getValues=getValues,getValues(),$(document).on(\"change\",\".bubble-element.Input\",(function(){getValues()}));const observerFunction=undefined,observer=new MutationObserver((mutations=>{mutations.forEach((mutation=>{\"attributes\"===mutation.type&&\"style\"===mutation.attributeName&&getValues()}))})),config={childList:!0,attributes:!0,attributeFilter:[\"style\"],subtree:!0},targetElement=document.body;observer.observe(targetElement,config)}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AZT":{"display":"Chart - Funnel","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AYf":{"caption":"Funnel Section Labels","default_val":"Leads, Prospects, Opportunities, Win","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":1,"value":"text"},"AYg":{"caption":"Series 1 Color Start","default_val":"rgba(255, 177, 120, 1)","editor":"Color","name":"series1color","rank":4},"AYh":{"caption":"Series 1 Color End","editor":"Color","name":"series2color","rank":5,"default_val":"rgba(255, 60, 142, 1)"},"AYi":{"caption":"Series 2 Color Start","default_val":"rgba(0,161,255,0.5)","editor":"Color","name":"series3color","rank":8},"AYj":{"caption":"Series 2 Color End","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series4color","optional":true,"rank":9},"AYk":{"caption":"Series 3 Color Start","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":12},"AYl":{"caption":"Show Value Labels?","default_val":true,"editor":"DynamicValue","name":"show_data_labels_value","rank":24,"value":"boolean"},"AYm":{"caption":"------------------------- Section Colors ---------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":38,"editor":"Label"},"AYn":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":0,"editor":"Label"},"AYo":{"caption":"Data Label Unit Before","name":"data_labels_unit_before","rank":30,"editor":"DynamicValue","value":"text","optional":true},"AYp":{"caption":"Data Labels Unit After","name":"data_labels_unit_after","rank":31,"editor":"DynamicValue","value":"text","optional":true},"AYq":{"caption":"Thousands Separator","name":"thousands_separator","rank":14,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AYr":{"caption":"--------------------------- Data Labels ---------------------------","name":"---------------------------_data_labels_---------------------------","rank":23,"editor":"Label"},"AYs":{"caption":"Vertical Offset","name":"datalabel_offset","rank":29,"editor":"DynamicValue","value":"number","default_val":3},"AYt":{"caption":"Percent - Font Color","name":"datalabel_font_color_percent","rank":34,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"AYu":{"caption":"Anchor","name":"datalabel_anchor","rank":27,"editor":"Dropdown","default_val":"left"},"AYv":{"caption":"Series 3 Color End","name":"series6color","rank":13,"editor":"Color","default_val":"rgba(92, 92, 92, 1)","optional":true},"AYw":{"caption":"Additional Colors (Comma-Separated List)","name":"additional_colors","rank":39,"editor":"DynamicValue","value":"text","default_val":"#33B5E5, #36D184, #F7B733, #AA66CC, #636363, #FF7300"},"AYx":{"caption":"Series 1 Values","name":"values","rank":3,"editor":"DynamicValue","value":"text","default_val":"2450, 705, 581, 322"},"AYy":{"caption":"Funnel Alignment","name":"side","rank":16,"editor":"Dropdown","default_val":"vertical"},"AYz":{"caption":"Left Padding","name":"left_padding","rank":17,"editor":"DynamicValue","value":"number","default_val":10},"AZA":{"caption":"Right Padding","name":"right_padding","rank":18,"editor":"DynamicValue","value":"number","default_val":10},"AZB":{"caption":"Horizontal Offset","name":"datalabel_horizontal_offset","rank":28,"editor":"DynamicValue","value":"number","default_val":0},"AZC":{"caption":"Show Hover Tooltips?","name":"show_hover_tooltips","rank":19,"editor":"DynamicValue","value":"boolean","default_val":false},"AZD":{"caption":"Title - Font Color","name":"datalabel_font_color_title","rank":33,"editor":"Color","default_val":"rgba(122, 122, 122, 1)"},"AZE":{"caption":"Value - Font Color","name":"datalabel_font_color_value","rank":32,"editor":"Color","default_val":"rgba(122, 122, 122, 1)"},"AZF":{"caption":"Value - Font Size","name":"datalabel_font_size_value","rank":35,"editor":"DynamicValue","value":"number","default_val":15},"AZG":{"caption":"Title - Font Size","name":"datalabel_font_size_title","rank":36,"editor":"DynamicValue","value":"number","default_val":10},"AZH":{"caption":"Percent - Font Size","name":"datalabel_font_size_percent","rank":37,"editor":"DynamicValue","value":"number","default_val":18},"AZI":{"caption":"Show Percent Labels?","name":"show_data_labels_percent","rank":26,"editor":"DynamicValue","value":"boolean","default_val":true},"AZJ":{"caption":"Show Title Labels?","name":"show_data_labels_title","rank":25,"editor":"DynamicValue","value":"boolean","default_val":true},"AZK":{"caption":"Separator Color","name":"separator_color","rank":15,"editor":"Color","value":"_any_thing","default_val":"rgba(174, 185, 194, 1)"},"AZL":{"caption":"Series 1 Name","name":"series_1_name","rank":2,"editor":"DynamicValue","value":"text","default_val":"Series 1"},"AZM":{"caption":"Series 2 Name","name":"series_2_name","rank":6,"editor":"DynamicValue","value":"text","default_val":"Series 2","optional":true},"AZN":{"caption":"Series 2 Values","name":"series_2_values","rank":7,"editor":"DynamicValue","value":"text","optional":true,"default_val":"1050, 210, 108, 52"},"AZO":{"caption":"Series 3 Name","name":"series_3_name","rank":10,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 3"},"AZP":{"caption":"Series 3 Values","name":"series_3_values","rank":11,"editor":"DynamicValue","value":"text","optional":true,"default_val":"500, 200, 100, 50"}
176,"AZU":{"caption":"Tooltip Background Color","name":"tooltip_background_color","rank":20,"editor":"Color","default_val":"rgba(255,255,255,0.8)"},"AZV":{"caption":"Tooltip Series Name Color","name":"tooltip_series_name_color","rank":21,"editor":"Color","default_val":"rgba(99, 99, 99, 1)"},"AZW":{"caption":"Tooltip Value Color","name":"tooltip_value_color","rank":22,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"}},"states":{"AZQ":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"AZR":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AZS":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AYe":{"caption":"chart_value_clicked","name":"chart_value_clicked"}},"actions":{"AYX":{"caption":"Add a Data Series","code":{"fn":"function(instance,properties,context){let customChartType;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}properties.chart_type&&(customChartType=properties.chart_type.toLowerCase()),addSeries()}"},"fields":{"AYY":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"AYZ":{"caption":"Series Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AYa":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"AYb":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true}}},"AYc":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.chart.data.datasets.splice(instance.data.chart.data.datasets.indexOf(foundSeries),1),instance.data.chart.update())}"},"fields":{"AYd":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy)}"},"update":{"fn":"function(instance,properties,context){let labels=properties.xvalues.split(\",\"),values=properties.values.split(\",\").map(Number),sublabelsArray=[];sublabelsArray.push(properties.series_1_name);let arrayOfArrayValues=[];if(properties.series_2_values){let values2=properties.series_2_values.split(\",\").map(Number);for(let i=0;i<values.length;i++){let newArray=[values[i],values2[i]];arrayOfArrayValues.push(newArray)}values=arrayOfArrayValues,sublabelsArray.push(properties.series_2_name)}if(properties.series_3_values){let values3=properties.series_3_values.split(\",\").map(Number);for(let i=0;i<arrayOfArrayValues.length;i++)arrayOfArrayValues[i].push(values3[i]);values=arrayOfArrayValues,sublabelsArray.push(properties.series_3_name)}let colors=[],colors2=[],colors3=[];colors.push(properties.series1color),colors.push(properties.series2color),colors2.push(properties.series3color),colors2.push(properties.series4color),colors3.push(properties.series5color),colors3.push(properties.series6color);let colorsArray=[];colorsArray.push(colors),colorsArray.push(colors2),colorsArray.push(colors3),colorsArray=colorsArray.slice(0,values.length);let additionalColors=properties.additional_colors,additionalColorsArray;null!=additionalColors&&(additionalColorsArray=additionalColors.split(\", \"));let fullColorArray,finalColorArray=colors.concat(additionalColorsArray).slice(0,labels.length);colors=colors.slice(0,labels.length);let direction=properties.side,borderColor=properties.separator_color;var data={labels:labels,subLabels:sublabelsArray,colors:colorsArray,values:values};if(instance.data.funnel?instance.data.funnel.update({data:data}):(instance.data.funnel=new FunnelGraph({container:\"#\"+instance.data.uniqueChartId,gradientDirection:direction,data:data,displayPercent:properties.display_percent,direction:direction,width:0,height:0,subLabelValue:\"raw\"}),instance.data.funnel.draw()),\"horizontal\"==direction){let labelNodes;instance.data.funnel.updateHeight(properties.bubble.height()-130),instance.data.funnel.updateWidth(properties.bubble.width()),$(instance.canvas[0]).find(\".svg-funnel-js__labels .svg-funnel-js__label\").each((function(i){0!==i&&$($(this)).css({borderLeft:`1px solid ${borderColor}`})}))}else{let labelNodes;instance.data.funnel.updateHeight(properties.bubble.height()),instance.data.funnel.updateWidth(properties.bubble.width()-130),$(instance.canvas[0]).find(\".svg-funnel-js__labels .svg-funnel-js__label\").each((function(i){0!==i&&$($(this)).css({borderTop:`1px solid ${borderColor}`})}))}instance.data.funnel.update({displayPercent:properties.show_data_labels_percent,direction:direction,gradientDirection:direction}),$(instance.canvas[0]).find(\".label__segment-percentages\").each((function(i){let seriesNames;$(this).css({backgroundColor:properties.tooltip_background_color}),this.querySelectorAll(\"li\").forEach((function(item){item.style.color=properties.tooltip_series_name_color,item.style.fontFamily=properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],item.style.fontSize=12}))})),$(instance.canvas[0]).find(\".percentage__list-label\").each((function(i){$(this).css({color:properties.tooltip_value_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:12})})),$(instance.canvas[0]).find(\".svg-funnel-js__subLabel--title\").each((function(i){$(this).css({color:\"gray\",fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}),instance.data.labelPercentElement=this.cloneNode(!0)})),$(instance.canvas[0]).find(\".label__title\").each((function(i){properties.show_data_labels_title||$(this).text(\"\"),$(this).css({color:properties.datalabel_font_color_title,fontSize:properties.datalabel_font_size_title,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]})})),$(instance.canvas[0]).find(\".label__percentage\").each((function(i){properties.show_data_labels_percent||$(this).text(\"\"),-1==i&&$(this).text(\"100%\"),$(this).css({color:properties.datalabel_font_color_percent,fontSize:properties.datalabel_font_size_percent,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}),instance.data.labelPercentElement=this.cloneNode(!0)})),$(instance.canvas[0]).find(\".label__value\").each((function(i){0==i&&properties.show_data_labels_percent&&($(instance.data.labelPercentElement).text(\"100%\"),this.parentNode.appendChild(instance.data.labelPercentElement));let rawCommaValue=$(this).text(),newCommaSeparatedValue;rawCommaValue=rawCommaValue.replace(/,/g,\"\"),newCommaSeparatedValue=rawCommaValue.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator),properties.data_labels_unit_before&&(newCommaSeparatedValue=properties.data_labels_unit_before+newCommaSeparatedValue),properties.data_labels_unit_after&&(newCommaSeparatedValue+=properties.data_labels_unit_after),$(this).text(newCommaSeparatedValue),properties.show_data_labels_value||$(this).text(\"\"),$(this).css({color:properties.datalabel_font_color_value,fontSize:properties.datalabel_font_size_value})}))}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Funnel Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"Aah":{"display":"Chart - Polar Area","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_hover_pressed":false,"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AZl":{"caption":"Series Labels","default_val":"Category A, Category B, Category C, Category D","editor":"DynamicValue","is_list":false,"name":"chartlabels","rank":2,"value":"text"},"AZm":{"caption":"Series Values","default_val":"2525, 743, 431, 1540","editor":"DynamicValue","name":"series1","rank":3,"value":"text"},"AZn":{"caption":"Value's Colors","default_val":"#00A2FF, #24E082, #FF8961, #BC61E6","editor":"DynamicValue","is_list":false,"name":"series1color","rank":4,"value":"text"},"AZo":{"caption":"Tooltip Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":38,"value":"text"},"AZp":{"caption":"Tooltip Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":39,"value":"text"},"AZq":{"caption":"labelValue: Unit Before","default_val":"$","editor":"DynamicValue","name":"data_label_unit_before","rank":26,"value":"text"},"AZr":{"caption":"labelValue: Unit After","default_val":" USD","editor":"DynamicValue","name":"data_label_unit_after","rank":27,"value":"text"},"AZs":{"caption":"Show/Hide Legend","name":"showLegend2","rank":6,"editor":"Dropdown","default_val":"Top"},"AZt":{"caption":"Section Border Width","name":"section_border_width","rank":18,"editor":"DynamicValue","value":"number","default_val":5},"AZu":{"caption":"Section Border Color","name":"section_border_color","rank":19,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AZv":{"caption":"Cutout Percentage","name":"cutout_percentage","rank":17,"editor":"DynamicValue","value":"number","default_val":82},"AZw":{"caption":"-------------------------- General Settings --------------------------","name":"-------------------------_general_settings_-------------------------","rank":5,"editor":"Label"},"AZx":{"caption":"---------------------------- Chart Styling ----------------------------","name":"-------------------------_chart_styling_-------------------------","rank":16,"editor":"Label"},"AZy":{"caption":"-------------------------- Tooltip Settings ---------------------------","name":"-------------------------_tooltip_settings_-------------------------","rank":37,"editor":"Label"},"AZz":{"caption":"Thousands Separator","name":"thousands_separator","rank":12,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AaA":{"caption":"Hover Border Width","name":"hover_border_width","rank":21,"editor":"DynamicValue","value":"number","optional":false,"default_val":3},"AaB":{"caption":"----------------------------- Data Labels ------------------------------","name":"--------------------------_data_labels_---------------------------","rank":23,"editor":"Label"},"AaC":{"caption":"Font Color","name":"datalabel_font_color","rank":34,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AaD":{"caption":"Anchor","name":"anchor","rank":31,"editor":"Dropdown","default_val":"end"},"AaE":{"caption":"Font Color Setting","name":"font_color_setting","rank":33,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"AaF":{"caption":"Offset","name":"offset","rank":32,"editor":"DynamicValue","value":"number","default_val":3},"AaG":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":11,"editor":"DynamicValue","value":"text","optional":true},"AaH":{"caption":"Font Size","name":"datalabel_size","rank":35,"editor":"DynamicValue","value":"number","default_val":12},"AaI":{"caption":"Section Corner Roundness","name":"section_corner_roundness","rank":41,"editor":"Dropdown","default_val":"Square Corners"},"AaJ":{"caption":"Round Corner Section#","name":"rounded_corner_section_number","rank":42,"editor":"DynamicValue","value":"number","default_val":0},"AaK":{"caption":"------------------ Section Corner Roundness -------------------","name":"---------------------_section_corner_roundness_----------------------","rank":40,"editor":"Label"},"AaL":{"caption":"Chart Padding","name":"padding","rank":14,"editor":"DynamicValue","value":"number","default_val":15},"AaM":{"caption":"Rotation","name":"rotation","rank":22,"editor":"DynamicValue","value":"number","default_val":0},"AaN":{"caption":"Total Circumference","name":"total_circumference","rank":20,"editor":"DynamicValue","value":"number","default_val":360},"AaO":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":29,"editor":"DynamicValue","value":"boolean","default_val":false},"AaP":{"caption":"Legend Padding","name":"legend_padding","rank":10,"editor":"DynamicValue","value":"number","default_val":0},"AaQ":{"caption":"Hide Labels Less Than #","name":"hide_if_less_than","rank":30,"editor":"DynamicValue","value":"number","optional":true},"AaR":{"caption":"Animation Duration","name":"animation_duration","rank":15,"editor":"DynamicValue","value":"number","default_val":1500},"AaS":{"caption":"Legend Font Color","name":"legend_font_color","rank":8,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AaT":{"caption":"Hide from Legend if <","name":"hide_from_legend_if_less_than","rank":9,"editor":"DynamicValue","value":"number","optional":true},"AaU":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"}
176,"AaV":{"caption":"â¹ï¸ Enter your chart's labels, values, and colors. Values in each list should be comma-separated (with comma and space \", \"). The 1st item in the \"Series Labels\" list matches with the 1st item in \"Series Values\" and \"Value's Colors\" lists; the 2nd items all match with each other, and so on","name":"â¹ï¸_enter_you_chart's_x-axis_values_(the_x-axis_labels_that_will_go_from_left_to_right)_separated_by_comma_and_space_(\",_\").__can_be_a_dynamic_expression.","rank":1,"editor":"Label"},"AaW":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"â ï¸_if_data_points_get_cut_off_near_edges_of_the_chart_element,_increase_the_chart_padding_below:","rank":13,"editor":"Label"},"AaX":{"caption":"Data Label Text","name":"data_label_text","rank":25,"editor":"DynamicValue","value":"text","optional":true,"default_val":"labelPercent, labelValue, labelName"},"AaY":{"caption":"Show Data Label?","name":"show_label","rank":24,"editor":"DynamicValue","value":"boolean","default_val":false},"AaZ":{"caption":"Percent Decimal Places","name":"labelpercent_decimal","rank":28,"editor":"DynamicValue","value":"number","default_val":2},"Aaa":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":36,"editor":"Dropdown","default_val":" 400","in_style":false},"Aab":{"caption":"Legend Color Style","name":"legend_color_style","rank":7,"editor":"Dropdown","default_val":"Circle"}},"states":{"Aac":{"caption":"Clicked Item Label Value","name":"clicked_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Aad":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Aae":{"caption":"Hovered Item Label Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Aaf":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Aag":{"caption":"Hovered Item Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AZj":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AZk":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){if(Chart.plugins.unregister(ChartDataLabels),Chart.Legend.prototype.afterFit=function(){this.height=this.height+properties.legend_padding,this.width=this.width+properties.legend_padding},null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),null==properties.chartlabels||null==properties.series1)return;if($(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId),ctxchart=chartcanvas.getContext(\"2d\");let legendState,showLegend;\"Don't Show Legend\"==properties.showLegend2?showLegend=!1:(legendState=properties.showLegend2.toLowerCase(),showLegend=!0);let listofchartlabels=properties.chartlabels,arrayoflabels=[];null!=properties.chartlabels&&(properties.chartlabels.includes(\",\")?arrayoflabels=listofchartlabels.split(\",\"):arrayoflabels.push(properties.chartlabels));let series1array=[];if(!properties.series1)return void series1array.push(5);if(properties.series1.includes(\",\")){let series1string=properties.series1;series1array=series1string.split(\",\")}else series1array.push(properties.series1);let pieChartColorsArray=[];if(properties.series1color.includes(\",\")){pieChartColorsArray=properties.series1color.split(\",\");for(let i=0;i<pieChartColorsArray.length;i++)pieChartColorsArray[i]=pieChartColorsArray[i].replace(/\\s/g,\"\")}else pieChartColorsArray.push(properties.series1color);let allYValuesArray=series1array,chartLabelsOn;1==properties.show_label&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]);let customTooltip=!1;
176null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),Chart.defaults.RoundedDoughnut=Chart.helpers.clone(Chart.defaults.doughnut),Chart.controllers.RoundedDoughnut=Chart.controllers.doughnut.extend({draw:function(ease){var ctx=this.chart.ctx,easingDecimal=ease||1,arcs=this.getMeta().data;Chart.helpers.each(arcs,(function(arc,i){arc.transition(easingDecimal).draw();var pArc,pColor=arcs[0===i?arcs.length-1:i-1]._view.backgroundColor,vm=arc._view,radius=(vm.outerRadius+vm.innerRadius)/2,thickness=(vm.outerRadius-vm.innerRadius)/2,startAngle=Math.PI-vm.startAngle-Math.PI/2,angle=Math.PI-vm.endAngle-Math.PI/2;ctx.save(),ctx.translate(vm.x,vm.y),ctx.fillStyle=0===i?vm.backgroundColor:pColor,ctx.beginPath(),ctx.arc(radius*Math.sin(startAngle),radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.fill(),ctx.fillStyle=vm.backgroundColor,ctx.beginPath(),ctx.arc(radius*Math.sin(angle),radius*Math.cos(angle),thickness,0,2*Math.PI),ctx.fill(),ctx.restore()}))}}),Chart.pluginService.register({afterUpdate:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor];arc.round={x:(chart.chartArea.left+chart.chartArea.right)/2,y:(chart.chartArea.top+chart.chartArea.bottom)/2,radius:(chart.outerRadius+chart.innerRadius)/2,thickness:(chart.outerRadius-chart.innerRadius)/2-1,backgroundColor:arc._model.backgroundColor}}},afterDraw:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var ctx=chart.chart.ctx,arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor],startAngle=Math.PI/2-arc._view.startAngle,endAngle=Math.PI/2-arc._view.endAngle;let vm=arc._view,thickness=(vm.outerRadius-vm.innerRadius)/2;ctx.save(),ctx.translate(arc.round.x,arc.round.y),ctx.fillStyle=arc.round.backgroundColor,ctx.beginPath(),ctx.arc(arc.round.radius*Math.sin(startAngle),arc.round.radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.arc(arc.round.radius*Math.sin(endAngle),arc.round.radius*Math.cos(endAngle),thickness,0,2*Math.PI),ctx.closePath(),ctx.fill(),ctx.restore()}}});let chartType=\"pie\",showDataLabelsOverlap;\"Rounded Corners (All Sections)\"==properties.section_corner_roundness&&(chartType=\"RoundedDoughnut\"),showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\";let config={plugins:chartLabelsOn,type:\"polarArea\",data:{labels:arrayoflabels,datasets:[{fill:!1,borderWidth:properties.section_border_width,borderColor:properties.section_border_color,hoverBorderWidth:properties.hover_border_width,hoverBorderColor:properties.section_border_color,label:properties.series1name,backgroundColor:pieChartColorsArray,data:series1array,datalabels:{display:showDataLabelsOverlap,anchor:properties.anchor,align:function(value){return value=0==properties.offset?\"center\":\"end\"},offset:properties.offset,color:function(value){return value=\"Custom (Define Color Below)\"==properties.font_color_setting?properties.datalabel_font_color:pieChartColorsArray},formatter:function(value,context){let completeLabel=\"\",percent,labelValue,labelName;if(value<properties.hide_if_less_than)return\"\";let total=eval(series1array.join(\"+\")),labelArray;if(percent=String((value/total*100).toFixed(properties.labelpercent_decimal))+\"%\",labelName=arrayoflabels[context.dataIndex],labelValue=value.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator),properties.data_label_unit_before&&(labelValue=(properties.data_label_unit_before+labelValue).replace(/\\s/g,\"\")),properties.data_label_unit_after&&(labelValue+=properties.data_label_unit_after),properties.data_label_text&&(labelArray=properties.data_label_text.split(\", \")),properties.data_label_text)for(;labelArray.length>0;)completeLabel&&(completeLabel+=\" \"),\"labelPercent\"==labelArray[0]&&(completeLabel+=percent),\"labelValue\"==labelArray[0]&&(completeLabel+=labelValue),\"labelName\"==labelArray[0]&&(completeLabel+=labelName),\"placeholder\"==labelArray[0]&&(completeLabel+=\"placeholder\"),labelArray.shift();return completeLabel},font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.datalabel_size,weight:properties.datalabel_fontweight}}}]},options:{scale:{ticks:{display:!1}},plugins:{crosshair:!1},animation:{duration:properties.animation_duration},onHover:function(event,elements){if(elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.backgroundColor;customTooltip&&(instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_color\",series_color),$(\"#\"+properties.custom_tooltip_id).fadeIn(250),null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\"))}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))},cutoutPercentage:properties.cutout_percentage,rotation:-.5*Math.PI+properties.rotation*(Math.PI/180),circumference:properties.total_circumference*(Math.PI/180),legend:{align:\"left\",dis
176play:showLegend,position:legendState,labels:{filter:function(legendItem,data){return null==properties.hide_from_legend_if_less_than||data.datasets[0].data[legendItem.index]>properties.hide_from_legend_if_less_than},usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.legend_font_color,fontSize:properties.bubble.font_size(),fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},maintainAspectRatio:!1,layout:{padding:{right:properties.padding,left:properties.padding,top:properties.padding,bottom:properties.padding}},tooltips:{enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let label=\"\";label+=data.labels[tooltipItem.index],label+=\": \";let commaYLabel=data.datasets[0].data[tooltipItem.index];return null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(commaYLabel=properties.yAxisUnitBeforeNumber+commaYLabel),label+=commaYLabel,properties.yAxisUnitAfterNumber&&(label+=properties.yAxisUnitAfterNumber),label}}}}},chart=new Chart(instance.data.ctxChartState,config);instance.data.chart=chart,chart.update();var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function updateData(dataLabel,newData,newColor){chart.data.datasets.push({label:dataLabel,backgroundColor:newColor,data:newData,fill:!1,borderColor:newColor}),chart.update()}chartContainer.parentNode.removeChild(chartContainer),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId),chartContainer.style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value)}instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},\"Rounded Corners (Single Section)\"==properties.section_corner_roundness&&(chart.options.elements.arc.roundedCornersFor=properties.rounded_corner_section_number),chart.destroy(),chart=new Chart(instance.data.ctxChartState,config)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Polar Area Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"},"Asw":{"display":"Chart - Heatmap Beta","property_applications":{"resizable":true,"MinWidth":true,"Border":true,"Padding":true,"Font":true},"add_is_visible":true,"fields":{"Asx":{"caption":"X Axis Values","name":"xLabels","rank":1,"editor":"DynamicValue","value":"text","default_val":"x1, x2, x3"},"Asy":{"caption":"Y Axis Values","name":"yLabels","rank":2,"editor":"DynamicValue","value":"text","default_val":"y1, y2, y3"},"Asz":{"caption":"Heatmap Values","name":"values","rank":3,"editor":"DynamicValue","value":"text","default_val":"1, 2, 3; 4, 5, 6; 7, 8, 9"},"AtA":{"caption":"Color","name":"color","rank":4,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"AtB":{"caption":"Show Toolbar?","name":"show_toolbar","rank":6,"editor":"DynamicValue","value":"boolean","default_val":true},"AtC":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":5,"editor":"Label"},"AtD":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"},"AyF":{"caption":"Values Unit Before","name":"values_unit_before","rank":7,"editor":"DynamicValue","value":"text"},"AyG":{"caption":"Values Unit After","name":"values_unit_after","rank":8,"editor":"DynamicValue","value":"text"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Heatmap Chart';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';
176\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\")),xArray}function convertStringToArrayOfArrays(str){var arr=str.split(\";\").map((function(item){return item.trim()})),seriesArray=[];return $.each(arr,(function(k,v){var a=v.split(\",\").map((function(item){return parseFloat(item.trim(),10)}));seriesArray.push(a)})),seriesArray}function rgbaToHex(rgba){const match=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+)(?:,\\s*(0|1|0?\\.\\d+))?\\)/);if(!match)throw new Error(\"Invalid RGBA color\");const hex=undefined;return`#${match.slice(1,4).map((num=>parseInt(num).toString(16).padStart(2,\"0\"))).join(\"\")}`}instance.data.createDataArray=createDataArray,instance.data.convertStringToArrayOfArrays=convertStringToArrayOfArrays,instance.data.rgbaToHex=rgbaToHex;let xLabels=[\"x1\",\"x2\",\"x3\"],yLabels=[\"y1\",\"y2\",\"y3\"],values=[[100,200,300],[200,300,400],[300,400,500]],myseries=yLabels.map(((label,index)=>{let data;return{name:label,data:xLabels.map(((xLabel,idx)=>({x:xLabel,y:values[index][idx]})))}})),yourseries=xLabels.map(((label,index)=>{let data;return{name:label,data:yLabels.map(((xLabel,idx)=>({x:xLabel,y:values[index][idx]})))}}));var options={series:myseries,chart:{height:350,type:\"heatmap\"},dataLabels:{enabled:!1},colors:[\"#008FFB\"]};instance.data.uniqueChartId=\"apexChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chart=new ApexCharts(document.querySelector(\"#\"+instance.data.uniqueChartId),options);instance.data.chart=chart,chart.render()}"},"update":{"fn":"function(instance,properties,context){try{let xLabels=instance.data.createDataArray(properties.xLabels),yLabels=instance.data.createDataArray(properties.yLabels),values=instance.data.convertStringToArrayOfArrays(properties.values),colors=[];const hexColor=instance.data.rgbaToHex(properties.color);colors.push(hexColor);let myseries=yLabels.map(((label,index)=>{let data;return{name:label,data:xLabels.map(((xLabel,idx)=>({x:xLabel,y:values[index][idx]})))}}));if(instance.data.chart){const options={series:myseries,chart:{height:properties.bubble.height(),type:\"heatmap\",toolbar:{show:properties.show_toolbar}},dataLabels:{enabled:!1},colors:colors,tooltip:{y:{formatter:function(value){const unitBefore=undefined,unitAfter=undefined;return(properties.values_unit_before||\"\")+value+(properties.values_unit_after||\"\")}}}};instance.data.chart.updateOptions(options,!0,!1)}else{console.warn(\"Chart instance missing. Reinitializing chart...\");const chartContainerId=instance.data.uniqueChartId;document.getElementById(chartContainerId)||(instance.canvas.html(\"\"),instance.canvas.append(instance.data.chartCanvasCopy));const options={series:myseries,chart:{height:properties.bubble.height(),type:\"heatmap\",toolbar:{show:properties.show_toolbar}},dataLabels:{enabled:!1},colors:colors,tooltip:{y:{formatter:function(value){const unitBefore=undefined,unitAfter=undefined;return(properties.values_unit_before||\"\")+value+(properties.values_unit_after||\"\")}}}};instance.data.chart=new ApexCharts(document.querySelector(\"#\"+chartContainerId),options),instance.data.chart.render()}}catch(error){console.error(\"Error updating chart:\",error)}}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AtL":{"display":"Chart - Treemap Beta","property_applications":{"resizable":true,"MinWidth":true,"Border":true,"Padding":true,"Font":true},"add_is_visible":true,"fields":{"AtE":{"caption":"X Axis Values","name":"xLabels","rank":1,"editor":"DynamicValue","value":"text","default_val":"x1, x2, x3"},"AtG":{"caption":"Heatmap Values","name":"values","rank":2,"editor":"DynamicValue","value":"text","default_val":"1, 2, 3"},"AtH":{"caption":"Color","name":"color","rank":3,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"AtI":{"caption":"Show Toolbar?","name":"show_toolbar","rank":5,"editor":"DynamicValue","value":"boolean","default_val":true},"AtJ":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":4,"editor":"Label"},"AtK":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"},"AtM":{"caption":"Show Data Labels?","name":"show_datalabels","rank":10,"editor":"DynamicValue","value":"boolean","default_val":true},"AtN":{"caption":"Multi Colored?","name":"multi_colored","rank":6,"editor":"DynamicValue","value":"boolean","default_val":true},"AyD":{"caption":"Values - Unit Before","name":"values_unit_before","rank":7,"editor":"DynamicValue","value":"text"},"AyE":{"caption":"Values - Unit After","name":"values_unit_after","rank":8,"editor":"DynamicValue","value":"text"},"AyW":{"caption":"Max # Char Per Line","name":"max_num_char_per_line_datalabels","rank":11,"editor":"DynamicValue","value":"number","optional":true},"AyX":{"caption":"----------------------- Data Labels Settings -----------------------","name":"-----------------------_data_labels_settings_-----------------------","rank":9,"editor":"Label"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Treemap Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\")),xArray}function transformArrays(xLabels,yLabels){if(xLabels.length!==yLabels.length)throw new Error(\"The lengths of xLabels and yLabels must be equal.\");return xLabels.map(((x,index)=>({x:x,y:yLabels[index]})))}function rgbaToHex(rgba){const match=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+)(?:,\\s*(0|1|0?\\.\\d+))?\\)/);if(!match)throw new Error(\"Invalid RGBA color\");const hex=undefined;return`#${match.slice(1,4).map((num=>parseInt(num).toString(16).padStart(2,\"0\"))).join(\"\")}`}instance.data.createDataArray=createDataArray,instance.data.transformArrays=transformArrays,instance.data.rgbaToHex=rgbaToHex;let xLabels=[\"x1\",\"x2\",\"x3\"],yLabels=[\"y1\",\"y2\",\"y3\"],values=[[100,200,300],[200,300,400],[300,400,500]],myseries=yLabels.map(((label,index)=>{let data;return{name:label,data:xLabels.map(((xLabel,idx)=>({x:xLabel,y:values[index][idx]})))}})),yourseries=xLabels.map(((label,index)=>{let data;return{name:label,data:yLabels.map(((xLabel,idx)=>({x:xLabel,y:values[index][idx]})))}}));var options={series:myseries,chart:{height:350,type:\"treemap\"},dataLabels:{enabled:!1}};instance.data.uniqueChartId=\"apexChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chart=new ApexCharts(document.querySelector(\"#\"+instance.data.uniqueChartId),options);instance.data.chart=chart,chart.render()}"},"update":{"fn":"function(instance,properties,context){let xLabels=instance.data.createDataArray(properties.xLabels),yLabels=instance.data.createDataArray(properties.yLabels),values=instance.data.createDataArray(properties.values),colors=[];const transformedArray=instance.data.transformArrays(xLabels,values),hexColor=instance.data.rgbaToHex(properties.color);colors.push(hexColor);var options={series:[{data:transformedArray}],chart:{height:properties.bubble.height(),type:\"treemap\",toolbar:{show:properties.show_toolbar}},dataLabels:{enabled:properties.show_datalabels},tooltip:{y:{formatter:function(value){const unitBefore=undefined,unitAfter=undefined;return(properties.values_unit_before||\"\")+value+(properties.values_unit_after||\"\")}}}};!0===properties.multi_colored?options.plotOptions={treemap:{distributed:properties.multi_colored}}:options.colors=colors,instance.data.chart.updateOptions(options,!0,!1)}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"Atg":{"display":"Chart - Range Bar/Area Gantt Beta","property_applications":{"resizable":true,"MinWidth":true,"Border":true,"Padding":true,"Font":true},"add_is_visible":true,"fields":{"AtY":{"caption":"Category Name","name":"xLabels","rank":2,"editor":"DynamicValue","value":"text","default_val":"x1, x2, x3"},"AtZ":{"caption":"Min Values","name":"minValues","rank":3,"editor":"DynamicValue","value":"text","default_val":"1, 2, 3"},"Ata":{"caption":"Color","name":"color","rank":5,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"Atb":{"caption":"Show Toolbar?","name":"show_toolbar","rank":7,"editor":"DynamicValue","value":"boolean","default_val":true},"Atc":{"caption":"------------------------- General Settings --------------------------","name":"-------------------------_general_settings_-------------------------","rank":6,"editor":"Label"},"Atd":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"},"Ate":{"caption":"Show Data Labels?","name":"show_datalabels","rank":9,"editor":"DynamicValue","value":"boolean","default_val":true},"Ath":{"caption":"Max Values","name":"maxValues","rank":4,"editor":"DynamicValue","value":"text","default_val":"2, 3, 4"},"AuK":{"caption":"Horizontal","name":"horizontal","rank":10,"editor":"DynamicValue","value":"boolean","default_val":true},"AuL":{"caption":"Chart Type","name":"chart_type","rank":1,"editor":"Dropdown","default_val":"rangeBar"},"AuM":{"caption":"X Axis Type","name":"x_axis_type","rank":13,"editor":"Dropdown","value":"text","default_val":"numeric"},"Axv":{"caption":"Show Tooltips?","name":"show_tooltips","rank":8,"editor":"DynamicValue","value":"boolean","default_val":true},"Axw":{"caption":"---------------------------- Axis Settings ----------------------------","name":"---------------------------_axis_settings_---------------------------","rank":12,"editor":"Label"},"Axx":{"caption":"Y Unit - Before","name":"y_unit_before","rank":15,"editor":"DynamicValue","value":"text"},"Axy":{"caption":"Y Unit - After","name":"y_unit_after","rank":16,"editor":"DynamicValue","value":"text"},"Axz":{"caption":"X Unit - Before","name":"x_unit_before","rank":17,"editor":"DynamicValue","value":"text"},"AyA":{"caption":"X Unit - After","name":"x_unit_after","rank":18,"editor":"DynamicValue","value":"text"},"AyN":{"caption":"X Axis Date Format","name":"x_axis_date_format","rank":14,"editor":"DynamicValue","value":"text","default_val":"H:mma do MMM, YYYY"},"AyP":{"caption":"Chart Padding (px)","name":"chart_padding","rank":11,"editor":"DynamicValue","value":"number","default_val":10},"AyU":{"caption":"Max X Ticks","name":"max_x_ticks","rank":19,"editor":"DynamicValue","value":"number","default_val":11},"AyV":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":20,"editor":"DynamicValue","value":"number","default_val":11}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Range Bar/Area/Gantt Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\")),xArray}function transformArrays(xLabels,minValues,maxValues){if(xLabels.length!==minValues.length||minValues.length!==maxValues.length)throw new Error(\"The lengths of xLabels, minValues, and maxValues must be equal.\");return xLabels.map(((x,index)=>{const minValue=parseFloat(minValues[index]),maxValue=parseFloat(maxValues[index]);if(isNaN(minValue)||isNaN(maxValue))throw new Error(\"Invalid number in minValues or maxValues\");return{x:x.trim(),y:[minValue,maxValue]}}))}function rgbaToHex(rgba){const match=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+)(?:,\\s*(0|1|0?\\.\\d+))?\\)/);if(!match)throw new Error(\"Invalid RGBA color\");const hex=undefined;return`#${match.slice(1,4).map((num=>parseInt(num).toString(16).padStart(2,\"0\"))).join(\"\")}`}instance.data.createDataArray=createDataArray,instance.data.transformArrays=transformArrays,instance.data.rgbaToHex=rgbaToHex;let xLabels=[\"x1\",\"x2\",\"x3\"],minValues=[\"100\",\"200\",\"300\"],maxValues=[\"200\",\"300\",\"400\"],seriesData;var options={series:[{data:instance.data.transformArrays(xLabels,minValues,maxValues)}],chart:{height:350,type:\"rangeBar\"},plotOptions:{bar:{horizontal:!0}},dataLabels:{enabled:!1}};instance.data.uniqueChartId=\"apexChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chart=new ApexCharts(document.querySelector(\"#\"+instance.data.uniqueChartId),options);instance.data.chart=chart,chart.render()}"},"update":{"fn":"function(instance,properties,context){instance.data.last=0;let xLabels=instance.data.createDataArray(properties.xLabels)||[],minValues=instance.data.createDataArray(properties.minValues)||[],maxValues=instance.data.createDataArray(properties.maxValues)||[],colors=[];const transformedArray=instance.data.transformArrays(xLabels,minValues,maxValues),hexColor=instance.data.rgbaToHex(properties.color);colors.push(hexColor),instance.data.chart&&instance.data.chart.destroy();const formatDate=(value,format)=>{if(!value||!format)return\"\";const date=moment(value);return date.isValid()?date.format(format):\"\"};var options={layout:{padding:properties.chart_padding},series:[{data:transformedArray}],chart:{height:properties.bubble.height(),type:properties.chart_type,toolbar:{show:properties.show_toolbar},zoom:{enabled:!1}},plotOptions:{bar:{horizontal:properties.horizontal}},dataLabels:{enabled:properties.show_datalabels},colors:colors,xaxis:{ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;if(null!=xLabel){if(value<1&&value>-1&&0!=value&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(xLabel=properties.yAxisUnitBeforeNumber+xLabel),properties.yAxisUnitAfterNumber&&(xLabel+=properties.yAxisUnitAfterNumber),properties.max_num_char_per_line&&\"horizontalBar\"!=chartType){const maxCharsPer
176Line=properties.max_num_char_per_line;let words=originalXLabel.split(\" \");const lines=[];let currentLine=\"\";words.forEach((word=>{(currentLine+word).length<=maxCharsPerLine?currentLine+=word+\" \":(lines.push(currentLine.trim()),currentLine=word+\" \")})),currentLine&&lines.push(currentLine.trim()),originalXLabel=lines}return\"horizontalBar\"==chartType?xLabel:originalXLabel}}},type:properties.x_axis_type,tickPlacement:\"between\",labels:{formatter:function(value,index,w){if(instance.data.last<1&&index<1e3)return instance.data.last++,\"\";const xUnitBefore=properties.x_unit_before?properties.x_unit_before:\"\",xUnitAfter=properties.x_unit_after?properties.x_unit_after:\"\";return\"datetime\"===properties.x_axis_type?xUnitBefore+formatDate(value,properties.x_axis_date_format)+xUnitAfter:xUnitBefore+value+xUnitAfter}}},yaxis:{ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value;if(yLabel=null!=properties.y_labels_decimal_places?parseFloat(value).toFixed(properties.y_labels_decimal_places):value.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.includes(\".\")?yLabel.substring(0,yLabel.indexOf(\".\")).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+properties.decimal_place_character+yLabel.substring(yLabel.indexOf(\".\")+1):yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),properties.max_num_char_per_line&&\"horizontalBar\"===chartType){const maxCharsPerLine=properties.max_num_char_per_line,words=yLabel.split(\" \"),lines=[];let currentLine=\"\";return words.forEach((word=>{(currentLine+word).length<=maxCharsPerLine?currentLine+=word+\" \":(lines.push(currentLine.trim()),currentLine=word+\" \")})),currentLine&&lines.push(currentLine.trim()),lines}return yLabel}},labels:{formatter:function(value){const yUnitBefore=properties.y_unit_before?properties.y_unit_before:\"\",yUnitAfter=properties.y_unit_after?properties.y_unit_after:\"\";return null!==value&&\"\"!==value?yUnitBefore+value+yUnitAfter:\"\"}}},tooltip:{enabled:properties.show_tooltips,x:{formatter:function(value){return\"rangeBar\"===properties.chart_type&&properties.horizontal?(properties.y_unit_before||\"\")+value+(properties.y_unit_after||\"\"):\"datetime\"===properties.x_axis_type?(properties.x_unit_before||\"\")+formatDate(value,properties.x_axis_date_format)+(properties.x_unit_after||\"\"):(properties.x_unit_before||\"\")+value+(properties.x_unit_after||\"\")}},y:{formatter:function(value){return\"rangeBar\"===properties.chart_type&&properties.horizontal?\"datetime\"===properties.x_axis_type?(properties.x_unit_before||\"\")+formatDate(value,properties.x_axis_date_format)+(properties.x_unit_after||\"\"):(properties.x_unit_before||\"\")+value+(properties.x_unit_after||\"\"):(properties.y_unit_before||\"\")+value+(properties.y_unit_after||\"\")}}}};const chartContainer=document.querySelector(\"#\"+instance.data.uniqueChartId);var chart=new ApexCharts(chartContainer,options);instance.data.chart=chart,chart.render()}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AuN":{"display":"Chart - Geo Map Beta","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"fields":{"AuO":{"caption":"Region","name":"region","rank":0,"editor":"DynamicValue","value":"text"},"AuP":{"caption":"Resolution","name":"resolution","rank":1,"editor":"Dropdown","value":"text","default_val":"provinces"},"AuQ":{"caption":"Labels List","name":"labels_list","rank":2,"editor":"DynamicValue","value":"text","default_val":"State, California, Texas, New York, Florida"},"AuR":{"caption":"Values List","name":"values_list","rank":3,"editor":"DynamicValue","value":"text","default_val":"Population, 39538223, 29145505, 20201249, 21538187"},"AuS":{"caption":"Color Starting Value","name":"color_starting_value","rank":4,"editor":"Color","default_val":"rgba(189,225,245,1)"},"AuT":{"caption":"Color Ending Value","name":"color_ending_value","rank":5,"editor":"Color","default_val":"rgba(26,154,223,1)"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Geo Map Chart';
176\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){instance.data.uniqueGeoChartId=\"geoChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.geoChartCanvas=\"<div id='\"+instance.data.uniqueGeoChartId+\"' style='width: 100%; height: 500px;'></div>\",instance.canvas.append(instance.data.geoChartCanvas),google.charts.load(\"current\",{packages:[\"geochart\"],mapsApiKey:\"AIzaSyADrnheg9iJcCaPBk-2Nm3czBUYW0Ro43k\"})}"},"update":{"fn":"function(instance,properties){function createDataTable(labelsString,dataString){const labels=labelsString.split(\",\").map((label=>label.trim())),dataValues=dataString.split(\",\").map((value=>value.trim())),dataArray=[];dataArray.push([labels[0],dataValues[0]]);for(let i=1;i<labels.length;i++)dataArray.push([labels[i],parseFloat(dataValues[i])]);return dataArray}function rgbaToHex(rgba){const matches=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+),?\\s*([\\d\\.]+)?\\)/);if(!matches)throw new Error(\"Invalid RGBA color format\");let r=parseInt(matches[1],10),g=parseInt(matches[2],10),b=parseInt(matches[3],10),hexR,hexG,hexB;return`#${r.toString(16).padStart(2,\"0\")}${g.toString(16).padStart(2,\"0\")}${b.toString(16).padStart(2,\"0\")}`}const labelsString=properties.labels_list,dataString=properties.values_list;console.log(createDataTable(labelsString,dataString)),google.charts.setOnLoadCallback((function(){var data=google.visualization.arrayToDataTable(createDataTable(labelsString,dataString)),options={region:properties.region,backgroundColor:\"transparent\",resolution:properties.resolution,colorAxis:{colors:[rgbaToHex(properties.color_starting_value),rgbaToHex(properties.color_ending_value)]}},chart;new google.visualization.GeoChart(document.getElementById(instance.data.uniqueGeoChartId)).draw(data,options)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"Axq":{"display":"Chart (Apex) - Area - Beta","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AvU":{"caption":"X-Axis Values","default_val":"Mon, Tue, Wed, Thu, Fri","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":3,"value":"text"},"AvV":{"caption":"Series 1 - y-values","default_val":"120, 260, 240, 310, 330","editor":"DynamicValue","name":"series1","rank":7,"value":"text","optional":false},"AvW":{"caption":"Series 2 - y-values","editor":"DynamicValue","is_list":false,"name":"series2","optional":true,"rank":10,"value":"text","default_val":"200, 210, 190, 240, 230"},"AvX":{"caption":"Series 3 - y-values","editor":"DynamicValue","name":"series3","optional":true,"rank":13,"value":"text","default_val":""},"AvY":{"caption":"Series 1 - color","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series1color","rank":6},"AvZ":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":5,"value":"text","optional":true},"Ava":{"caption":"Chart Type","default_val":"Area","editor":"Dropdown","name":"chartType","rank":0},"Avb":{"caption":"Series 2 - name","default_val":"Series 2","editor":"DynamicValue","name":"series2name","rank":8,"value":"text","optional":true},"Avc":{"caption":"Series 2 - color","default_val":"rgba(235, 235, 235, 1)","editor":"Color","name":"series2color","rank":9},"Avd":{"caption":"Series 3 - name","default_val":"Series 3","editor":"DynamicValue","name":"series3name","rank":11,"value":"text","optional":true},"Ave":{"caption":"Series 3 color","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":12},"Avf":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":36,"value":"text"},"Avg":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":37,"value":"text"},"Avh":{"caption":"Y Axis - Max (Optional)","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":35,"value":"number"},"Avi":{"caption":"Y Axis - Min (Optional)","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":34,"value":"number"},"Avj":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":25,"value":"text","default_val":"Top"},"Avk":{"caption":"Series 4 - name","default_val":"Series 4","editor":"DynamicValue","name":"series4name","optional":true,"rank":14,"value":"text"},"Avl":{"caption":"Series 4 color","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":15},"Avm":{"caption":"Series 4 - y-values","editor":"DynamicValue","name":"series4","optional":true,"rank":16,"value":"text"},"Avn":{"caption":"Series 5 - name","default_val":"Series 5","editor":"DynamicValue","name":"series5name","optional":true,"rank":17,"value":"text"},"Avo":{"caption":"Series 5 - color","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":18},"Avp":{"caption":"Series 5 - y-values","editor":"DynamicValue","name":"series5","optional":true,"rank":19,"value":"text"},"Avq":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":55,"value":"boolean"},"Avr":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":39,"editor":"DynamicValue","value":"boolean","default_val":true},"Avs":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":38,"editor":"DynamicValue","value":"boolean","default_val":true},"Avt":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":33,"editor":"Label"},"Avu":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_main_fields_-------------------","rank":1,"editor":"Label"},"Avx":{"caption":"Show Horizontal Gridlines","name":"show_horizontal_gridlines","rank":48,"editor":"DynamicValue","value":"boolean","default_val":true},"Avy":{"caption":"Show Vertical Gridlines","name":"show_vertical_gridlines","rank":49,"editor":"DynamicValue","value":"boolean","default_val":true},"AwA":{"caption":"Gridlines Color","name":"gridlines_color","rank":45,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AwB":{"caption":"Line Width","name":"line_width","rank":68,"editor":"DynamicValue","value":"number","default_val":3},"AwC":{"caption":"Line Curve","name":"curve_line_charts","rank":72,"editor":"Dropdown","value":"number"},"AwD":{"caption":"Unit Before the Label","name":"data_labels_unit_before","rank":59,"editor":"DynamicValue","value":"text","optional":true},"AwE":{"caption":"Unit After the Label","name":"data_labels_unit_after","rank":60,"editor":"DynamicValue","value":"text","optional":true},"AwF":{"caption":"Point Radius","name":"line_point_radius","rank":70,"editor":"DynamicValue","value":"number","default_val":5},"AwG":{"caption":"Thousands Separator","name":"thousands_separator","rank":31,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AwH":{"caption":"Horiz. Dash Gridlines","name":"horizontal_dashed_gridlines","rank":46,"editor":"DynamicValue","value":"boolean","default_val":true},"AwI":{"caption":"Vert. Dash Gridlines","name":"vertical_dashed_gridlines","rank":47,"editor":"DynamicValue","value":"boolean","default_val":false},"AwJ":{"caption":"------------------------------ Data Labels ----------------------------","name":"---------------------------_data_labels_---------------------------","rank":54,"editor":"Label"},"AwK":{"caption":"Vertical Offset","name":"datalabel_offset","rank":58,"editor":"DynamicValue","value":"number","default_val":3},"AwL":{"caption":"Label Backgrnd Color","name":"datalabel_background_color","rank":61,"editor":"Color","default_val":"rgba(255, 255, 255, 0.32)","optional":false},"AwM":{"caption":"Font Color (Optional)","name":"datalabel_font_color","rank":64,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AwN":{"caption":"Font Color Setting","name":"font_color_setting","rank":63,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"AwO":{"caption":"Anchor","name":"datalabel_anchor","rank":56,"editor":"Dropdown","default_val":"middle"},"AwP":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":27,"editor":"DynamicValue","value":"text","optional":true},"AwQ":{"caption":"Font Size","name":"datalabel_size","rank":65,"editor":"DynamicValue","value":"number","default_val":12},"AwR":{"caption":"Series 6 - name","name":"series6name","rank":20,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 6"},"AwS":{"caption":"Series 6 - color","name":"series6color","rank":21,"editor":"Color","default_val":"rgba(59, 227, 129, 1)","optional":true},"AwT":{"caption":"Series 6 - y-values","name":"series6","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AwU":{"caption":"-------------------- Line/Area Chart Settings ---------------------","name":"---------------------------Line---------------------------","rank":67,"editor":"Label"},"AwY":{"caption":"Animation Duration","name":"animation_duration","rank":28,"editor":"DynamicValue","value":"number","default_val":600},"AwZ":{"caption":"Point Hover Radius","name":"point_hover_radius","rank":69,"editor":"DynamicValue","value":"number","default_val":12},"Awa":{"caption":"Point Border Width","name":"point_border_width","rank":71,"editor":"DynamicValue","value":"number","default_val":3},"Awb":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":41,"editor":"DynamicValue","value":"number","optional":true},"Awc":{"caption":"Max X Ticks","name":"max_x_ticks","rank":40,"editor":"DynamicValue","value":"number","optional":true},"Awe":{"caption":"Chart Padding (px)","name":"chart_padding","rank":30,"editor":"DynamicValue","value":"number","default_val":10},"Awh":{"caption":"Label Border Color","name":"label_border_color","rank":62,"editor":"Color","default_val":"rgba(240, 240, 240, 0)"},"Awi":{"caption":"â¹ï¸ To customize Tick Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties. Please avoid using âApp Fontsâ (in other words, please select the exact font you want to use from the font menu)","name":"to_customize_the_axis_tick_label_font_style,_color,_and_size,_edit_this_element's_font_style,_color,_size_as_you_would_for_a_text_element_(by_scrolling_down_to_the_bottom_of_this_menu_and_editing_the_standard_bubble_properties)","rank":44,"editor":"Label"},"Awl":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"-----_(you_can_also_add_infinite_series_via_w
176orkflows)_-----","rank":23,"editor":"Label"},"Awm":{"caption":"Tick Label Color","name":"tick_label_color","rank":42,"editor":"Color","default_val":"rgba(174, 185, 194, 1)","in_style":true},"Awn":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":43,"editor":"DynamicValue","value":"number","default_val":12},"Awo":{"caption":"Span Gaps?","name":"span_gaps","rank":73,"editor":"DynamicValue","value":"boolean","default_val":true},"Awr":{"caption":"Hide if Less Than","name":"hide_if_less_than","rank":57,"editor":"DynamicValue","value":"number","optional":true},"Aws":{"caption":"Decimal Place Char.","name":"decimal_place_character","rank":32,"editor":"DynamicValue","value":"text","default_val":"."},"Awt":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":24,"editor":"Label"},"Awu":{"caption":"â¹ï¸ Add series names, colors, and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"----------------------------_series_colors_----------------------------","rank":4,"editor":"Label"},"Awv":{"caption":"â¹ï¸ Enter you chart's X-Axis values (the X-Axis labels that will go from left to right) separated by comma and space (\", \"). Can be a dynamic expression.","name":"â¹ï¸_add_series_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_(\",_\")._you_can_dynamically_search_your_bubble_database_to_get_these_comma-separated_lists_(\"do_a_search_for...\")","rank":2,"editor":"Label"},"Aww":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"if_your_data_points_are_getting_cut_off_near_the_edges_of_the_chart_element,_increase_this_number","rank":29,"editor":"Label"},"Awx":{"caption":"â¹ï¸ For extra styling options (Area gradient, point border color, point images), add the data series using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_for_extra_styling_options_(area_gradient,_point_border_color,_point_images)_add_the_data_series_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":74,"editor":"Label"},"Awz":{"caption":"yLabels Decimal Places","name":"y_labels_decimal_places","rank":50,"editor":"DynamicValue","value":"number","optional":true},"AxA":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":66,"editor":"Dropdown","default_val":" 400"},"AxC":{"caption":"------------------ Chart and Axes Titles (BETA) -----------------","name":"chart_and_axes_titles","rank":75,"editor":"Label"},"AxD":{"caption":"Chart Title","name":"chart_title","rank":76,"editor":"DynamicValue","value":"text","optional":true},"AxE":{"caption":"Chart Title Font Size","name":"chart_title_font_size","rank":77,"editor":"DynamicValue","value":"number","optional":true,"default_val":16},"AxF":{"caption":"Chart Title Font Color","name":"chart_title_font_color","rank":78,"editor":"Color","default_val":"rgba(210,210,210,1)","optional":true},"AxG":{"caption":"X Axis Name","name":"x_axis_name","rank":79,"editor":"DynamicValue","value":"text","optional":true},"AxH":{"caption":"X Axis Name: Font Size","name":"x_axis_name_font_size","rank":80,"editor":"DynamicValue","value":"number","default_val":14,"optional":false},"AxI":{"caption":"X Axis Name: Font Color","name":"x_axis_name_font_color","rank":81,"editor":"Color","default_val":"rgba(210, 210, 210, 1)","optional":true},"AxJ":{"caption":"Y Axis Name","name":"y_axis_name","rank":82,"editor":"DynamicValue","value":"text","optional":true},"AxK":{"caption":"Y Axis Name: Font Size","name":"y_axis_name_font_size","rank":83,"editor":"DynamicValue","value":"number","default_val":14},"AxL":{"caption":"Y Axis Name: Font Color","name":"y_axis_name_font_color","rank":84,"editor":"Color","default_val":"rgba(210, 210, 210, 1)","optional":true},"Axr":{"caption":"Show Crosshairs","name":"show_crosshairs","rank":51,"editor":"DynamicValue","value":"boolean","default_val":true},"Axs":{"caption":"Crosshair Color","name":"crosshair_color","rank":52,"editor":"Color","default_val":"rgba(210, 210, 210, 1)"},"Axt":{"caption":"Crosshair Width","name":"crosshair_width","rank":53,"editor":"DynamicValue","value":"number","default_val":1},"Axu":{"caption":"Enable Tooltips?","name":"enable_tooltips","rank":26,"editor":"Checkbox","default_val":true}},"states":{"AxT":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"AxU":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AxV":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AxW":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AxX":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AxY":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AxZ":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Axa":{"caption":"Clicked Item Series Color","name":"clicked_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Axb":{"caption":"Clicked Item All Series Values","name":"click_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axc":{"caption":"Clicked Item All Series Colors","name":"clicked_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axd":{"caption":"Clicked Item All Series Names","name":"clicked_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axe":{"caption":"Hovered Item All Series Values","name":"hovered_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axf":{"caption":"Hovered Item All Series Colors","name":"hovered_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axg":{"caption":"Hovered Item All Series Names","name":"hovered_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axh":{"caption":"Chart Loaded?","name":"chart_loaded","value":"boolean","initialization_code":{"fn":"function(properties,context){return!1}"}}
176,"Axi":{"caption":"Hovered Item X Index","name":"hovered_item_x_index","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Axj":{"caption":"Dragged Item Data Series Name","name":"dragged_item_data_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Axk":{"caption":"Dragged Item Index Number","name":"dragged_item_index_number","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Axl":{"caption":"Dragged Item - X Value","name":"dragged_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"Axm":{"caption":"Dragged Value - Starting Value","name":"dragged_item_starting_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Axn":{"caption":"Dragged Value - Ending Value","name":"dragged_item_ending_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"Axo":{"caption":"Dragged Item - All of this Series' Y Values","name":"dragged_item_all_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"Axp":{"caption":"Currently Dragging Bar/Value","name":"currently_dragging","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AvR":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AvS":{"caption":"Chart Value Hovered","name":"chart_value_hovered"},"AvT":{"caption":"Chart Value Dragged","name":"chart_value_dragged"}},"actions":{"AuY":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){instance.publishState(\"chart_loaded\",!1);let numAttempts=0;function mainAddSeries(){if(numAttempts>15)return void console.log(\"The Chart you are trying to update is not visible on the page\");if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);let customChartType=instance.data.chartType,backgroundColors,pointImage;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType,properties.point_color_line,properties.point_border_color_line,backgroundColors,pointImage,properties.chart_type,properties.bar_outline_color),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}if(properties.background_colors&&(backgroundColors=instance.data.createDataArray(properties.background_colors)),null!=properties.chart_type&&(properties.chart_type.toLowerCase()!=instance.data.chartType&&(customChartType=properties.chart_type.toLowerCase()),\"area\"==customChartType&&(customChartType=\"line\")),pointImage=properties.point_style,properties.use_image_as_point&&(pointImage=new Image(1,1),pointImage.src=properties.use_image_as_point,pointImage.onload=function(){var width=pointImage.naturalWidth,height=pointImage.naturalHeight;pointImage.width=width*properties.image_scale,pointImage.height=height*properties.image_scale}),addSeries(),\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain||\"Bar\"==properties.chart_type||\"Bar\"==instance.data.originalChartTypeMain){let mycanvas;var chart_gradient=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\").createLinearGradient(0,0,0,instance.data.height);(\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain&&\"Bar\"!=properties.chart_type)&&(chart_gradient.addColorStop(0,properties.area_chart_start_color),chart_gradient.addColorStop(.5,properties.area_chart_middle_color),chart_gradient.addColorStop(1,properties.area_chart_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),(\"Bar\"==properties.chart_type&&!properties.background_colors||\"Bar\"==instance.data.originalChartTypeMain&&\"Area\"!=properties.chart_type&&!properties.background_colors)&&properties.bar_gradient&&(chart_gradient.addColorStop(0,properties.bar_gradient_start_color),chart_gradient.addColorStop(.6,properties.bar_gradient_middle_color),chart_gradient.addColorStop(1,properties.bar_gradient_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),instance.data.chart.update(
176)}}mainAddSeries(),instance.publishState(\"chart_loaded\",!0)}"},"fields":{"AuZ":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"Aua":{"caption":"Series Color","name":"series_color","rank":4,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"Aub":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"Auc":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true},"Aud":{"caption":"Point Color","name":"point_color_line","rank":6,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","optional":true},"Aue":{"caption":"Point Border Color","name":"point_border_color_line","rank":7,"editor":"Color","default_val":"rgba(51, 181, 229, 1)","optional":true},"Auf":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"Aug":{"caption":"-------------------- Line/Area Series Settings --------------------","name":"-------------------------_line_chart_settings_------------------------","rank":5,"editor":"Label"},"Auh":{"caption":"Multi-Colored Series (comma-separated hex codes)","name":"background_colors","rank":22,"editor":"DynamicValue","value":"text","optional":true},"Aui":{"caption":"-------------------------- Bar Series Settings -----------------------","name":"--------------------------_bar_chart_settings_-----------------------","rank":16,"editor":"Label"},"Auj":{"caption":" ","name":"use_image_as_point","rank":13,"editor":"DynamicValue","value":"image","optional":true},"Auk":{"caption":"Image Point Scale","name":"image_scale","rank":14,"editor":"DynamicValue","value":"number","optional":false,"default_val":1},"Aul":{"caption":"Gradient Start Color","name":"area_chart_start_color","rank":8,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"Aum":{"caption":"Gradient End Color","name":"area_chart_end_color","rank":10,"editor":"Color","default_val":"rgba(51, 181, 229, 0)"},"Aun":{"caption":"Use Image as Point. Below you can upload an image (or use dynamic one) to set the image instead of having a circle for line chart points","name":"use_image_as_point.__below_you_can_upload_an_image_(or_use_dynamic_one)_to_set_the_","rank":12,"editor":"Label"},"Auo":{"caption":" ","name":"_","rank":15,"editor":"Label"},"Aup":{"caption":"Gradient Middle Color","name":"area_chart_middle_color","rank":9,"editor":"Color","default_val":"rgba(51, 179, 230, 0.58)"},"Auq":{"caption":"The field below is optional: for multi-colored series (overrides colors set above)","name":"info","rank":21,"editor":"Label"},"Aur":{"caption":"Gradient Start Color","name":"bar_gradient_start_color","rank":18,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"Aus":{"caption":"Gradient End Color","name":"bar_gradient_end_color","rank":20,"editor":"Color","default_val":"rgba(51,181,229,0.1)"},"Aut":{"caption":"Bar Gradient Middle Color","name":"bar_gradient_middle_color","rank":19,"editor":"Color","default_val":"rgba(51,179,230,0.5)"},"Auu":{"caption":"Bar Gradient?","name":"bar_gradient","rank":17,"editor":"Checkbox","default_val":false},"Auv":{"caption":"Point Style","name":"point_style","rank":11,"editor":"Dropdown","default_val":"circle"}}},"Auw":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"},"fields":{"Aux":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"Auy":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update(
176)}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"}},"Auz":{"caption":"Add Annotation","code":{"fn":"function(instance,properties,context){var newAnnotation;\"vertical\"==properties.type?newAnnotation={type:\"line\",mode:\"vertical\",scaleID:\"x-axis-0\",value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"horizontal\"==properties.type?newAnnotation={type:\"line\",mode:\"horizontal\",scaleID:\"y\",value:properties.value,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}:\"box\"==properties.type&&(newAnnotation={type:\"box\",xMin:1,xMax:2,yMin:1,yMax:2,backgroundColor:properties.background_color,borderColor:properties.line_color,borderWidth:properties.border_width,label:{enabled:!0,content:properties.label,xAdjust:properties.x_offset,yAdjust:properties.y_offset,position:properties.position,align:properties.alignment}}),instance.data.chart.options.annotation||(instance.data.chart.options.annotation={annotations:[]}),instance.data.chart.options.annotation.annotations.push(newAnnotation),console.log(instance.data.chart),instance.data.chart.update()}"},"fields":{"AvA":{"caption":"Type","name":"type","rank":0,"editor":"Dropdown","default_val":"horizontal"},"AvB":{"caption":"----------------------- General Settings -----------------------","name":"information","rank":1,"editor":"Label"},"AvC":{"caption":"-------------- Vertical/Horizontal Annotations --------------","name":"vertical/horizontal_settings","rank":8,"editor":"Label"},"AvD":{"caption":"------------------- Box Annotations (in beta) -------------------","name":"box_settings (ignore if type=vertical or horizontal)","rank":11,"editor":"Label"},"AvE":{"caption":"Value","name":"value","rank":9,"editor":"DynamicValue","value":"text","optional":true},"AvF":{"caption":"Label text","name":"label","rank":2,"editor":"DynamicValue","value":"text","default_val":""},"AvG":{"caption":"Line Color","name":"line_color","rank":3,"editor":"Color","default_val":"rgba(150,162,164,1)"},"AvH":{"caption":"Background color","name":"background_color","rank":12,"editor":"Color","default_val":"rgba(220,223,224,1)"},"AvI":{"caption":"Y Min","name":"y_min","rank":13,"editor":"DynamicValue","value":"number","optional":true},"AvJ":{"caption":"Y Max","name":"y_max","rank":14,"editor":"DynamicValue","value":"number","optional":true},"AvK":{"caption":"X Min","name":"x_min","rank":15,"editor":"DynamicValue","value":"number","optional":true},"AvL":{"caption":"X Max","name":"x_max","rank":16,"editor":"DynamicValue","value":"number","optional":true},"AvM":{"caption":"Border Width","name":"border_width","rank":10,"editor":"DynamicValue","value":"number","default_val":2},"AvN":{"caption":"Position: X Offset","name":"x_offset","rank":6,"editor":"DynamicValue","value":"number","default_val":0},"AvO":{"caption":"Position: Y Offset","name":"y_offset","rank":7,"editor":"DynamicValue","value":"number","default_val":0},"AvP":{"caption":"Position: Alignment","name":"alignment","rank":5,"editor":"Dropdown","default_val":"start"},"AvQ":{"caption":"Position","name":"position","rank":4,"editor":"Dropdown","default_val":"top"}}}},"code":{"initialize":{"fn":"function(instance,context){function rgbaToHex(rgba){const match=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+)(?:,\\s*(0|1|0?\\.\\d+))?\\)/);if(!match)throw new Error(\"Invalid RGBA color\");const hex=undefined;return`#${match.slice(1,4).map((num=>parseInt(num).toString(16).padStart(2,\"0\"))).join(\"\")}`}function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\",\").map((item=>\"\"===item.trim()?null:item.trim()))),xArray}function convertStringToArrayOfArrays(str){var arr=str.split(\";\").map((function(item){return item.trim()})),seriesArray=[];return $.each(arr,(function(k,v){var a=v.split(\",\").map((function(item){return parseFloat(item.trim(),10)}));seriesArray.push(a)})),seriesArray}instance.data.rgbaToHex=rgbaToHex,instance.data.createDataArray=createDataArray,instance.data.convertStringToArrayOfArrays=convertStringToArrayOfArrays;let xValues,series=[{name:\"Series 1\",data:[10,20,30]},{name:\"Series 2\",data:[15,25,35]}];var options={series:series,chart:{height:350,type:\"area\"},xaxis:{categories:[\"x1\",\"x2\",\"x3\"]},dataLabels:{enabled:!1},colors:series.map((s=>s.color)),legend:{position:\"top\"},grid:{show:!0,strokeDashArray:0}};instance.data.uniqueChartId=\"apexChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chart=new ApexCharts(document.querySelector(\"#\"+instance.data.uniqueChartId),options);instance.data.chart=chart,chart.render()}","add_debugger":false},"update":{"fn":"function(instance,properties,context){let xValues=instance.data.createDataArray(properties.xvalues)||[],seriesArray=[];function generateSeries(name,color,values){return{name:name,data:instance.data.createDataArray(values),color:instance.data.rgbaToHex(color)}}seriesArray.push(generateSeries(properties.series1name,properties.series1color,properties.series1)),properties.series2&&seriesArray.push(generateSeries(properties.series2name,properties.series2color,properties.series2)),properties.series3&&seriesArray.push(generateSeries(properties.series3name,properties.series3color,properties.series3)),properties.series4&&seriesArray.push(generateSeries(properties.series4name,properties.series4color,properties.series4)),properties.series5&&seriesArray.push(generateSeries(properties.series5name,properties.series5color,properties.series5)),properties.series6&&seriesArray.push(generateSeries(properties.series6name,properties.series6color,properties.series6));let isStacked=\"Stacked Area\"===properties.chartType,chartType=\"area\",curveType=\"smooth\";\"Line\"===properties.chartType?chartType=\"line\":\"Stepped Line\"===properties.chartType&&(chartType=\"line\",curveType=\"stepline\");let legendPosition=properties.showLegend.toLowerCase();\"don't show legend\"===legendPosition&&(legendPosition=!1);var options={series:seriesArray.map((s=>({name:s.name,data:s.data,color:s.color,connectNulls:properties.span_gaps}))),chart:{height:properties.bubble.height(),type:chartType,stacked:isStacked,toolbar:{show:properties.show_toolbar},animations:{enabled:!0,easing:\"easeinout\",speed:properties.animation_duration||800},zoom:{enabled:!1}},fill:{type:\"area\"===chartType?\"gradient\":\"solid\"},tooltip:{enabled:properties.enable_tooltips,followCursor:!0,style:{fontSize:\"12px\",color:\"#42525E\"}},title:{text:properties.chart_title||\"\",align:\"center\",style:{fontSize:properties.chart_title_font_size?`${properties.chart_title_font_size}px`:\"16px\",color:properties.chart_title_font_color||\"#000\"}},stroke:{width:properties.line_width||2,curve:curveType},markers:{size:properties.line_point_radius||0,hover:{size:properties.point_hover_radius||6},strokeWidth:properties.point_border_width||2},xaxis:{categories:xValues,labels:{show:properties.show_x_tick_labels,formatter:function(val){return null==val?\"\":val.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)},style:{colors:properties.tick_label_color||\"#000000\",fontSize:properties.tick_label_font_size?`${properties.tick_label_font_size}px`:\"12px\"}},title:{text:properties.x_axis_name||\"\",style:{fontSize:properties.x_axis_name_font_size?`${properties.x_axis_name_font_size}px`:\"12px\",color:properties.x_axis_name_font_color||\"#000\"}},tickAmount:properties.max_x_ticks||void 0,crosshairs:{show:properties.show_crosshairs,stroke:{color:properties.crosshair_color||\"#B3B6B7\",width:properties.crosshair_width}},tooltip:{enabled:!1},axisTicks:{show:!1}},yaxis:{min:properties.yMinNum||void 0,max:properties.yMaxNum||void 0,labels:{show:properties.show_y_tick_labels,formatter:function(val){const decimalPlaces=properties.y_labels_decimal_places||0;return(properties.yAxisUnitBeforeNumber||\"\")+val.toFixed(decimalPlaces).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+(properties.yAxisUnitAfterNumber||\"\")},style:{colors:properties.tick_label_color||\"#000000\",fontSize:properties.tick_label_font_size?`${properties.tick_label_font_size}px`:\"12px\"}},title:{text:properties.y_axis_name||\"\",style:{fontSize:properties.y_axis_name_font_size?`${properties.y_axis_name_font_size}px`:\"12px\",color:properties.y_axis_name_font_color||\"#000\"}}
176,tickAmount:properties.max_y_ticks||void 0},dataLabels:{enabled:properties.show_data_labels,formatter:function(val){return val<properties.hide_if_less_than?\"\":(properties.data_labels_unit_before||\"\")+val+(properties.data_labels_unit_after||\"\")},style:{fontSize:properties.datalabel_size?`${properties.datalabel_size}px`:\"12px\",fontWeight:properties.datalabel_fontweight||\"normal\",anchor:properties.datalabel_anchor||\"middle\"}},grid:{show:!0,borderColor:properties.gridlines_color,strokeDashArray:properties.horizontal_dashed_gridlines?5:0,xaxis:{lines:{show:properties.show_vertical_gridlines}},yaxis:{lines:{show:properties.show_horizontal_gridlines}},padding:{top:properties.chart_padding||0,left:properties.chart_padding||0,bottom:properties.chart_padding||0,right:properties.chart_padding||0}},colors:seriesArray.map((s=>s.color)),legend:{show:!!legendPosition,...legendPosition?{position:legendPosition}:{}}};instance.data.chart?instance.data.chart.updateOptions(options,!0,!0):(instance.data.chart=new ApexCharts(document.querySelector(\"#\"+instance.data.uniqueChartId),options),instance.data.chart.render())}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Area Chart';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"}},"platform_type":"web"}}}; 177window._bubble_page_load_data.plugins_size['1553183744528x903111989944909800'] = 410534; 178window.preloaded['plugin/third_party:1553183744528x903111989944909800:5.3.35'] = true; 179window.plugins["1553889862898x186125300131692540"] = {"human":"Feather Icons","dependencies":{"use_jquery":true},"plugin_elements":{"AAC":{"display":"Feather Icon","property_applications":{"resizable":true,"MinWidth":true,"BoxShadow":true,"Font":false,"Background":true,"Border":true,"Padding":true},"add_hover_pressed":true,"add_is_visible":true,"support_autobinding":false,"autobinding_value":"text","fields":{"AAD":{"caption":"Type","name":"type","rank":0,"editor":"Dropdown","default_val":"heart"},"AAE":{"caption":"Icon color","name":"color","rank":2,"editor":"Color","default_val":"rgba(51, 51, 51, 1)","in_style":true},"AAF":{"caption":"Stroke width (dynamic)","name":"strokeWidthDynamic","rank":7,"editor":"DynamicValue","in_style":true,"value":"number","optional":true},"AAI":{"caption":"Fill color","name":"fillColor","rank":5,"editor":"Color","default_val":"rgba(255, 255, 255, 0.01)","in_style":true},"AAJ":{"caption":"Include fill color? (dynamic)","name":"includeFillDynamic","rank":4,"editor":"DynamicValue","in_style":true,"value":"boolean","default_val":false,"optional":true},"AAK":{"caption":"Stroke line-cap","name":"strokeLineCap","rank":8,"editor":"Dropdown","default_val":"round","in_style":true},"AAL":{"caption":"Stroke line-join","name":"strokeLineJoin","rank":10,"editor":"Dropdown","in_style":true,"default_val":"round"},"AAP":{"caption":"Type (dynamic)","name":"typeDynamic","rank":1,"editor":"DynamicValue","optional":true,"value":"text"},"AAQ":{"caption":"Stroke line-cap (dynamic)","name":"strokeLineCapDynamic","rank":9,"editor":"DynamicValue","optional":true,"value":"text"},"AAR":{"caption":"Stroke line-join (dynamic)","name":"strokeLineJoinDynamic","rank":11,"editor":"DynamicValue","value":"text","optional":true},"AAT":{"caption":"Stroke width","name":"strokeWidth","rank":6,"editor":"StaticNumber","in_style":true,"default_val":1},"AAU":{"caption":"Include fill color?","name":"includeFill","rank":3,"editor":"Checkbox","default_val":false,"in_style":true},"AAV":{"caption":"Logs? (for developer)","name":"logs","rank":12,"editor":"DynamicValue","value":"boolean","default_val":false}},"states":{"AAO":{"caption":"Icon name","name":"iconName","value":"text","initialization_code":{"fn":"function(properties, context) {\n \n var type = properties.type;\n var typeDynamic = properties.typeDynamic;\n \n if (feather.icons[typeDynamic]) {\n type = typeDynamic;\n }\n\t\n\treturn type;\n\n}"}}},"events":{"AAM":{"caption":"is clicked","name":"onClick"}},"code":{"initialize":{"fn":"function(instance, context) {\n \n // Generate random string for div element ID\n \n var divId = \"id_\" + (Math.random() * Math.pow(2,54)).toString(18);\n \n // Create our div (a.k.a. wrapper) for the icon (which will be created in the 'update' function below)\n \n var div = document.createElement(\"div\");\n div['id'] = divId;\n div['style'] = 'width:100%;height:100%;';\n \n // Add the new div to the Bubble instance\n // Store the div ID to the Bubble instance so that we can locate it in the 'update' function\n \n instance.canvas.append(div);\n\tinstance.data.divId = divId;\n\n}"},"update":{"fn":"function(instance, properties, context) {\n\t\n // Define properties\n \n var width = properties.bubble.width;\n var height = properties.bubble.height;\n \n var type = properties.type;\n var typeDynamic = properties.typeDynamic;\n // var notClickable = properties.notClickable;\n var color = properties.color;\n var strokeWidth = properties.strokeWidth;\n var strokeWidthDynamic = properties.strokeWidthDynamic;\n var fill = properties.fillColor;\n var includeFill = properties.includeFill;\n var includeFillDynamic = properties.includeFillDynamic;\n var strokeLineCap = properties.strokeLineCap;\n var strokeLineCapDynamic = properties.strokeLineCapDynamic;\n var strokeLineJoin = properties.strokeLineJoin;\n var strokeLineJoinDynamic = properties.strokeLineJoinDynamic;\n \n // Updates properties (if dynamic fields provided)\n \n if (feather.icons[typeDynamic]) {\n type = typeDynamic;\n }\n \n if (strokeWidthDynamic) {\n strokeWidth = strokeWidthDynamic;\n }\n \n if (includeFillDynamic === true || includeFillDynamic === false) {\n includeFill = includeFillDynamic;\n }\n \n if (strokeLineCapDynamic === 'round' || strokeLineCapDynamic === 'square') {\n strokeLineCap = strokeLineCapDynamic;\n }\n if (strokeLineJoinDynamic === 'round' || strokeLineJoinDynamic === 'square') {\n strokeLineJoin = strokeLineJoinDynamic;\n }\n \n if (strokeLineCap === 'square') {\n strokeLineCap = 'butt';\n }\n if (strokeLineJoin === 'square') {\n strokeLineJoin = 'miter';\n }\n \n // Find our original div\n \n var divId = instance.data.divId;\n var div = instance.canvas.find('#' + divId)[0];\n \n // Set the attributes / customization for our icon \n \n attributes = {}\n attributes['height'] = height;\n attributes['width'] = width;\n attributes['color'] = color;\n attributes['stroke-width'] = strokeWidth;\n if (includeFill) {\n attributes['fill'] = fill;\n } \n attributes['stroke-linecap'] = strokeLineCap;\n attributes['stroke-linejoin'] = strokeLineJoin;\n \n attributes['pointer-events'] = \"none\";\n \n if (properties.logs) {\n console.log(attributes);\n }\n \n // Create an SVG string - the markup for a SVG HTML element - and add it to our div\n \n var icon = feather.icons[type].toSvg(attributes);\n \n if (properties.logs) {\n console.log(icon);\n }\n \n div.innerHTML = icon;\n \n}"},"reset":{"fn":"function(instance, context) {\n\n\n\n}"},"preview":{"fn":"function(instance, properties) {\n\t\n // Define properties\n \n var width = properties.bubble.width;\n var height = properties.bubble.height;\n \n var type = properties.type;\n var color = properties.color;\n var strokeWidth = properties.strokeWidth;\n var fill = properties.fillColor;\n var includeFill = properties.includeFill;\n var strokeLineCap = properties.strokeLineCap;\n var strokeLineJoin = properties.strokeLineJoin;\n \n if (strokeLineCap === 'square') {\n strokeLineCap = 'butt';\n }\n if (strokeLineJoin === 'square') {\n strokeLineJoin = 'miter';\n }\n \n // Add script to canvas\n \n /*\n var script = document.createElement(\"script\");\n script['src'] = \"https://unpkg.com/feather-icons/\";\n //instance.canvas.append(script);\n document.head.appendChild(script);\n */\n \n // Create div + add to canvas\n \n var div = document.createElement(\"div\");\n div['style'] = 'width:100%;height:100%;';\n //document.appendChild(div);\n instance.canvas.append(div);\n \n // Set the attributes / customization for our icon \n \n attributes = {}\n attributes['height'] = height;\n attributes['width'] = width;\n attributes['color'] = color;\n attributes['stroke-width'] = strokeWidth;\n if (includeFill) {\n attributes['fill'] = fill;\n } \n attributes['stroke-linecap'] = strokeLineCap;\n attributes['stroke-linejoin'] = strokeLineJoin;\n \n // Create an SVG string - the markup for a SVG HTML element - and add it to our div\n \n /*\n var icon = feather.icons[type].toSvg(attributes);\n div.innerHTML = icon;\n */\n \n var previewImg = document.createElement(\"img\");\n \n previewImg['src'] = '//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1560539190480x747431396671820500/feather.svg';\n previewImg['style'] = 'width:100%;height:100%;opacity:0.4;';\n \n div.appendChild(previewImg);\n \n}"}},"platform_type":"web"}}}; 180window._bubble_page_load_data.plugins_size['1553889862898x186125300131692540'] = 7806; 181window.preloaded['plugin/third_party:1553889862898x186125300131692540:1.1.2'] = true; 182window.plugins["1565920055521x927769972289306600"] = {"human":"ð¨ FabricJS Graphics Canvas - Draw","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"Canvas - Main","property_applications":{"resizable":true,"MinWidth":true,"Backgroun
182d":false,"Border":true,"BoxShadow":true,"Font":true},"add_hover_pressed":true,"add_is_visible":true,"can_fit_width":false,"can_fit_height":false,"fields":{"ABR":{"caption":"Background Color","name":"background_color","rank":2,"editor":"Color"},"ABX":{"caption":"Cursor Click Mode","name":"cursor_mode","rank":27,"editor":"Dropdown","default_val":"Free Draw/Paint","in_style":false},"ABZ":{"caption":"Draw Shape Type","name":"draw_shape_type","rank":36,"editor":"DynamicValue","value":"text","default_val":"Rectangle"},"ABa":{"caption":"Draw Mode Color","name":"cursor_mode_color","rank":32,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ABb":{"caption":"Stroke Width","name":"paint_stroke_width","rank":33,"editor":"DynamicValue","value":"number","default_val":3},"ABc":{"caption":"---------------- Click Mode Configuration Fields -------------- The setting of the dropdown below defines what happens when users click on the canvas:","name":"na0","rank":26,"editor":"Label"},"ABe":{"caption":"--------- 1: Properties for \"Free Draw/Paint\" mode -------","name":"na1","rank":31,"editor":"Label"},"ABf":{"caption":"----------- 2: Properties for \"Draw Shapes\" mode ----------","name":"na2","rank":34,"editor":"Label"},"ABh":{"caption":"Selector on?","name":"selector_on","rank":1,"editor":"DynamicValue","value":"boolean","default_val":true},"ABi":{"caption":"Shape Color (Fill)","name":"shape_color","rank":37,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ABo":{"caption":"Shape Outline Color","name":"shape_color_stroke","rank":35,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ACB":{"caption":"------------------------- General Settings -------------------------","name":"separator1","rank":0,"editor":"Label"},"ACI":{"caption":"------------- 3: Properties for \"Add Text\" mode --------------","name":"na3","rank":40,"editor":"Label"},"ACJ":{"caption":"Text Color","name":"text_color","rank":41,"editor":"Color","default_val":"rgba(13, 13, 13, 1)"},"ACK":{"caption":"Text Size","name":"text_size","rank":42,"editor":"DynamicValue","value":"number","default_val":18},"ACL":{"caption":"Default Text","name":"default_text","rank":46,"editor":"DynamicValue","value":"text","default_val":"...edit me..."},"ACM":{"caption":"Shape Outline Width","name":"shape_outline_width","rank":38,"editor":"DynamicValue","value":"number","default_val":2},"ACZ":{"caption":"Arrow Key Movement","name":"arrow_key_movement","rank":5,"editor":"DynamicValue","value":"number","default_val":2},"ACf":{"caption":"Context Menu HTML id","name":"context_menu_html_id","rank":8,"editor":"DynamicValue","value":"text","optional":true,"default_val":"my_context_menu_id"},"ACx":{"caption":"Each of the 3 sections below determines the properties for a specific cursor click mode (Draw/Paint Mode, Shapes Mode, Add Text Mode)","name":"each_of_the_3_sections_below_determines_the_settings_for_a_specific_cursor_click_mode_(draw/paint_mode,_shapes_mode,_add_text_mode)","rank":30,"editor":"Label"},"ADX":{"caption":"Fixed Aspect Ratio?","name":"fixed_aspect_ratio","rank":3,"editor":"DynamicValue","value":"number","optional":true},"ADY":{"caption":"Backspace: Deletes?","name":"delete_key_on","rank":4,"editor":"DynamicValue","value":"boolean","default_val":true},"ADa":{"caption":"Background Image","name":"background_image","rank":11,"optional":true,"editor":"DynamicValue","value":"image"},"ADc":{"caption":"------------------------------------------------------","name":"background_image_scale","rank":14,"editor":"Label","value":"number","optional":false},"ADd":{"caption":"------------------------ Background Image -----------------------","name":"------------------------_background_image_-----------------------","rank":10,"editor":"Label"},"ADo":{"caption":"The font style/family can be changed using this element's native font selector dropdown below","name":"info_text_1","rank":53,"editor":"Label"}
182,"ADu":{"caption":"-----------------------------------------------------------------------------","name":"------------------------------------------","rank":29,"editor":"Label"},"AEA":{"caption":"-----------------------------------------------------------------------------","name":"-----------------------------------------------------------------------------","rank":25,"editor":"Label"},"AER":{"caption":"Corner Radius (Rect)","name":"corner_roundness","rank":39,"editor":"DynamicValue","value":"number","default_val":0},"AEX":{"caption":"Auto-enter Edit Mode","name":"enter_editing_mode","rank":47,"editor":"DynamicValue","value":"boolean","default_val":true},"AEY":{"caption":"Auto Highlight text","name":"highlight_text","rank":48,"editor":"DynamicValue","value":"boolean","default_val":true},"AEd":{"caption":"Text Lines Wrap?","name":"wrappable","rank":51,"editor":"DynamicValue","value":"boolean","default_val":true},"AEf":{"caption":"Text Border Padding","name":"text_padding","rank":50,"editor":"DynamicValue","value":"number","default_val":3},"AEg":{"caption":"Textbox Border Color","name":"textbox_border_color","rank":49,"editor":"Color","default_val":"rgba(209, 209, 209, 0)"},"AEl":{"caption":"Click Mode (Override)","name":"cursor_mode_2","rank":28,"editor":"DynamicValue","value":"text","optional":true},"AEn":{"caption":"Unique ID","name":"unique_id","rank":9,"editor":"DynamicValue","value":"text","default_val":"","optional":true},"AEw":{"caption":"Custom Cursor","name":"custom_cursor","rank":6,"editor":"DynamicValue","value":"text","optional":true},"AFA":{"caption":"Controls/Resize Knobs Visibility","name":"controls_visibility","rank":17,"editor":"DynamicValue","value":"text","default_val":"topLeft, bottomLeft, topRight, bottomRight, middleLeft, middleBottom, middleRight, middleTop, middleTopRotation","optional":true},"AFB":{"caption":"Transparent Knob?","name":"controls_transparent_c
182orners","rank":18,"editor":"DynamicValue","value":"boolean","default_val":true},"AFC":{"caption":"Selected Border Color","name":"controls_border_color","rank":20,"editor":"Color","default_val":"rgba(125, 211, 245, 1)"},"AFD":{"caption":"Control Knob Color","name":"controls_corner_color","rank":19,"editor":"Color","default_val":"rgba(125, 211, 245, 1)"},"AFE":{"caption":"Controls Knob Style","name":"controls_corner_style","rank":16,"editor":"Dropdown","default_val":"circle"},"AFF":{"caption":"--------------------------- Control Knobs ---------------------------","name":"---------------------_controls_settings_--------------------","rank":15,"editor":"Label"},"AFI":{"caption":"Group HTML ID 1","name":"control_menu_html_id","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AFJ":{"caption":"Control Menu X Offset","name":"control_menu_x_offset","rank":23,"editor":"DynamicValue","value":"number","optional":true},"AFK":{"caption":"Control Menu Y Offset","name":"control_menu_y_offset","rank":24,"editor":"DynamicValue","value":"number","optional":true},"AFL":{"caption":"Custom Control Menu Settings (Optional)","name":"custom_control_menu","rank":21,"editor":"Label"},"AFM":{"caption":"Width rel. to Canvas","name":"canvas_width_multiplier","rank":12,"editor":"DynamicValue","value":"number","optional":true},"AFN":{"caption":"Height rel. to Canvas","name":"canvas_height_multiplier","rank":13,"editor":"DynamicValue","value":"number","optional":true},"AFj":{"caption":"-----------------------------------------------------------------------------","name":"-----------------------------------------------------------------------------","rank":54,"editor":"Label"},"AGL":{"caption":"Bold","name":"bold","rank":43,"editor":"DynamicValue","value":"boolean","default_val":false},"AGM":{"caption":"Italic","name":"italic","rank":44,"editor":"DynamicValue","value":"boolean","default_val":false},"AGN":{"caption":"Underline","name":"underline","rank":45,"editor":"DynamicValue","value":"boolean","default_val":false},"AGz":{"caption":"Horizontal Align","name":"horizontal_align_text","rank":52,"editor":"DynamicValue","value":"text","default_val":"left"},"AIK":{"caption":"Copy & Paste Keyboard shortcuts","name":"keyboard_shortcuts_copy_paste","rank":7,"editor":"Checkbox","default_val":true}},"states":{"AAV":{"caption":"PNG URL","name":"drawing","value":"image","initialization_code":{"fn":"function(properties,context){}"}},"ABJ":{"caption":"Element is Selected?","name":"objectIsSelected","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ACH":{"caption":"Serialized Canvas","name":"serialized_canvas","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ACT":{"caption":"Number of Undos Available","name":"num_undo_available","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ACU":{"caption":"Number of Redos Available","name":"num_redo_available","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ACt":{"caption":"Selected Elements IDs","name":"selected_elements_list","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ADT":{"caption":"Current Canvas Width (px)","name":"current_canvas_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADU":{"caption":"Current Canvas Height (px)","name":"current_canvas_height","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADh":{"caption":"Selected Element Widths","name":"selected_elements_width_list","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"ADi":{"caption":"Selected Element Heights","name":"selected_elements_height_list","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AEH":{"caption":"Selected Shape - Type","name":"selected_shape_type","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEI":{"caption":"Selected Shape - Fill Color","name":"selected_shape_fill_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEJ":{"caption":"Selected Shape - Outline Color","name":"selected_shape_outline_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEK":{"caption":"Selected Shape - Outline Width","name":"selected_shape_outline_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEL":{"caption":"Selected Drawing - Color","name":"selected_drawing_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEM":{"caption":"Selected Drawing - Stroke Width","name":"selected_drawing_stroke_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEN":{"caption":"Selected Text - Font Family","name":"selected_text_font_family","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEO":{"caption":"Selected Text - Font Color","name":"selected_text_font_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AEP":{"caption":"Selected Text - Font Size","name":"selected_text_font_size","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEQ":{"caption":"Selected Text - Text Value","name":"selected_text_text_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AET":{"caption":"Selected Element Type","name":"selected_element_type","value":"text","initialization_code":{"fn":"function(properties,context){}"}}
182,"AEm":{"caption":"Unique ID of Canvas","name":"unique_id","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFG":{"caption":"Selected Elements X Locations","name":"selected_elements_x_locations","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AFH":{"caption":"Selected Elements Y Locations","name":"selected_elements_y_locations","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AFO":{"caption":"Selected Element Rotation","name":"selected_element_rotation","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGn":{"caption":"Selected Advanced Line Width","name":"selected_advanced_line_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGo":{"caption":"Selected Advanced Line Height","name":"selected_advanced_line_height","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGp":{"caption":"Selected Advanced Line X","name":"selected_advanced_line_x","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGq":{"caption":"Selected Advanced Line Y","name":"selected_advanced_line_y","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGr":{"caption":"Fabric Canvas HTML Element ID","name":"fabric_canvas_html_element_id","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AGx":{"caption":"Background Image Width","name":"background_image_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AGy":{"caption":"Background Image Height","name":"background_image_height","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AHH":{"caption":"Selected Text Bold","name":"selected_text_bold","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHI":{"caption":"Selected Text Italic","name":"selected_text_italic","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHJ":{"caption":"Selected Text Underline","name":"selected_text_underline","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AHK":{"caption":"Selected Text Alignment","name":"selected_text_alignment","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHM":{"caption":"SVG value","name":"svg_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHq":{"caption":"Selected Text Shadow Color","name":"selected_text_shadow_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHr":{"caption":"Selected Text Shadow Radius","name":"selected_text_shadow_radius","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AHs":{"caption":"Selected Text Shadow X Offset","name":"selected_text_shadow_x_offset","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AHt":{"caption":"Selected Text Shadow Y Offset","name":"selected_text_shadow_y_offset","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AHu":{"caption":"Selected Text Outline Color","name":"selected_text_outline_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AHv":{"caption":"Selected Text Outline Width","name":"selected_text_outline_width","value":"number","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ABv":{"caption":"has generated a saved image URL","name":"saved_image_URL_is_generated"},"ACG":{"caption":"has generated a serialization","name":"saved_image_serialization_is_generated"},"ACg":{"caption":"has been modified","name":"canvas_modified"},"ACp":{"caption":"has deleted an element","name":"element_deleted"},"ACy":{"caption":"Shape Added","name":"shape_added"},"ACz":{"caption":"Text Added","name":"text_added"},"AFX":{"caption":"Shape has been Modified","name":"shape_modified"},"AFl":{"caption":"Element has been clicked","name":"element_clicked"},"AGG":{"caption":"has generated a saved SVG image","name":"saved_image_SVG_is_generated"},"AHN":{"caption":"SVG Generated","name":"svg_generated"}},"actions":{"AAc":{"caption":"Save (as PNG to URL)","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Save As PNG) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");let html2canvasOptions,screenshotElement;if(instance.data.savedPngName=properties.file_name,properties.height&&properties.width){var resizedCanvas=document.createElement(\"canvas\"),resizedContext=resizedCanvas.getContext(\"2d\");resizedCanvas.height=properties.height,resizedCanvas.width=properties.width;var canvas=document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId);resizedContext.drawImage(canvas,0,0,properties.width,properties.height);let myResizedData=resizedCanvas.toDataURL(),myResizedDataPng=myResizedData.substring(myResizedData.indexOf(\",\")+1);context.uploadContent(properties.file_name+\".png\",myResizedDataPng,instance.data.uploadContentCallback)}else instance.data.saveImage()}"},"fields":{"ACu":{"caption":"Image Height (px)","name":"height","rank":1,"editor":"DynamicValue","value":"number","optional":true},"ACv":{"caption":"Image Width (px)","name":"width","rank":2,"editor":"DynamicValue","value":"number","optional":true},"ADK":{"caption":"PNG File Name","name":"file_name","rank":3,"editor":"DynamicValue","value":"text","default_val":"myimage"},"AFy":{"caption":"â¹ï¸ To access the URL, refer to the Canvas's state called: \"Canvas-Main A's PNG URL.\" You can save this as a image in the database","name":"to_access_the_url,_refer_to_the_canvas's_state_called:_\"canvas-main_a's_drawing's_png_url\"","rank":0,"editor":"Label"}}},"AAg":{"caption":"Clear Canvas","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.fabricCanvas.clear(),instance.data.fabricCanvas.backgroundColor=properties.cleared_canvas_background_color,
182instance.data.updateUndoRedoArray(),instance.data.mousecursor=new fabric.Circle({left:0,top:0,radius:instance.data.drawCursorWidth,fill:instance.data.drawCursorColor,originX:\"right\",originY:\"bottom\"}),instance.data.fabricCanvas.add(instance.data.mousecursor),instance.data.erasercursor=new fabric.Rect({left:0,top:0,height:14,width:14,stroke:\"#808080\",strokeWidth:1,fill:\"#FFFFFF\",originX:\"right\",originY:\"bottom\"}),instance.data.fabricCanvas.add(instance.data.erasercursor)):alert(\"The Canvas isn't visible on your page. This workflow action (Clear Canvas) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ACY":{"caption":"Background Color","name":"cleared_canvas_background_color","rank":0,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"}}},"AAi":{"caption":"Add Shape(s) to","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Add Shapes) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");function createDataArray(xString){let outputArray,xArray=[];return xString.includes(\",\")?xArray=xString.split(\", \"):xArray.push(xString),xArray}let shapeArray=createDataArray(properties.shape),xLocationArray=createDataArray(properties.x_location),yLocationArray=createDataArray(properties.y_location),heightArray=createDataArray(properties.height),widthArray=createDataArray(properties.width),strokeWidthArray=createDataArray(properties.stroke_width),corner_roundnessArray=createDataArray(properties.corner_roundness),shape_unique_id_Array=[],shapeFillColorArray,shapeOutlineColorArray;null!=properties.shape_unique_id&&(shape_unique_id_Array=createDataArray(properties.shape_unique_id)),null!=properties.shape_colors_list&&(shapeFillColorArray=createDataArray(properties.shape_colors_list)),null!=properties.outline_colors_list&&(shapeOutlineColorArray=createDataArray(properties.outline_colors_list));for(let i=0;i<shapeArray.length;i++){let thisShapeColor=properties.shape_color;null!=properties.shape_colors_list&&(thisShapeColor=shapeFillColorArray[i]);let thisShapeOutlineColor=properties.shape_color_stroke;null!=properties.outline_colors_list&&(thisShapeOutlineColor=shapeOutlineColorArray[i]),instance.data.createShape(parseFloat(xLocationArray[i]),parseFloat(yLocationArray[i]),parseFloat(heightArray[i]),parseFloat(widthArray[i]),thisShapeColor,shapeArray[i],thisShapeOutlineColor,parseFloat(strokeWidthArray[i]),parseFloat(corner_roundnessArray[i]),shape_unique_id_Array[i])}instance.data.fabricCanvas.renderAll()}"},"fields":{"AAm":{"caption":"Shape","name":"shape","rank":1,"editor":"DynamicValue","value":"text","default_val":"Rectangle"},"AAv":{"caption":"X location (px)","name":"x_location","rank":2,"editor":"DynamicValue","value":"text","default_val":10,"is_list":false},"AAw":{"caption":"Y location (px)","name":"y_location","rank":3,"editor":"DynamicValue","value":"text","default_val":10},"AAx":{"caption":"Height (px)","name":"height","rank":4,"editor":"DynamicValue","value":"text","default_val":50},"AAy":{"caption":"Width (px)","name":"width","rank":5,"editor":"DynamicValue","value":"text","default_val":50},"AAz":{"caption":"Shape Color (Fill)","name":"shape_color","rank":10,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ABn":{"caption":"Shape Color (Outline)","name":"shape_color_stroke","rank":11,"editor":"Color","default_val":"rgba(52,73,229,1)"},"ACq":{"caption":"Stroke Width","name":"stroke_width","rank":6,"editor":"DynamicValue","value":"text","default_val":1},"ACr":{"caption":"Corner Roundness","name":"corner_roundness","rank":7,"editor":"DynamicValue","value":"text","default_val":1},"AEy":{"caption":"Shape's Unique ID","name":"shape_unique_id","rank":8,"editor":"DynamicValue","value":"text","optional":true},"AFm":{"caption":"Fill Colors List","name":"shape_colors_list","rank":13,"editor":"DynamicValue","value":"text","optional":true},"AFn":{"caption":"---------------------------- Shape Colors ---------------------------","name":"----------------_shape_colors_----------","rank":9,"editor":"Label"},"AFo":{"caption":"Optional. If adding a list of shapes, you can enter comma separate hex colors below. These override the colors set in the color picker above","name":"optional_if_adding_a_list_of_shapes","rank":12,"editor":"Label"},"AFp":{"caption":"Outline Colors List","name":"outline_colors_list","rank":14,"editor":"DynamicValue","value":"text","optional":true},"AFq":{"caption":"You can optionally add a list of shapes to the canvas by entering comma-separated lists for each of the fields below. For example, entering \"Rectangle, Triangle, Rectangle\" in the shape field would create 3 shapes: 2 rectangles and 1 triangle","name":"you_can_add_a_list_of_shapes_to_the_canvas_by_entering_comma-separated_lists_for_each_of_the_fields_below._for_example,_entering_\"rectangle,_triangle,_rectangle\"_in_the_shape_field_would_create_three_shapes:_2_rectangles_and_one_tri
182angle","rank":0,"editor":"Label"}}},"AAk":{"caption":"Add Image to","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Add Image To Canvas) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");let imageId=Math.floor(1e7*Math.random()).toString();function updateURArray(){null!=instance.data.updateUndoRedoArray&&instance.data.updateUndoRedoArray()}fabric.Image.fromURL(properties.image,(function(oImg){if(oImg.set({id:imageId,left:properties.x_location,top:properties.y_location,selectable:properties.selectable,hasBorders:properties.selectable,hasControls:properties.selectable,evented:properties.selectable,notSelectableOverride:!properties.selectable}),properties.width&&properties.height||properties.width&&!properties.height){let scale=properties.width/oImg.width;oImg.set({scaleX:scale,scaleY:scale})}else if(!properties.width&&properties.height){let scale=properties.height/oImg.height;oImg.set({scaleX:scale,scaleY:scale})}properties.unique_id?oImg.set({bubble_id:properties.unique_id}):oImg.set({bubble_id:\"image_unique_id_\"+Math.floor(1e6*Math.random()).toString()}),instance.data.fabricCanvas.add(oImg)}),{crossOrigin:\"anonymous\"}),setTimeout(updateURArray(),1500)}"},"fields":{"AAl":{"caption":"Image","name":"image","rank":0,"editor":"DynamicValue","value":"image"},"ABA":{"caption":"X Location (px)","name":"x_location","rank":1,"editor":"DynamicValue","value":"number","default_val":10},"ABB":{"caption":"Y Location (px)","name":"y_location","rank":2,"editor":"DynamicValue","value":"number","default_val":10},"ABk":{"caption":"Image Width (px)","name":"width","rank":3,"editor":"DynamicValue","value":"number","optional":true},"ACh":{"caption":"Selectable","name":"selectable","rank":5,"editor":"DynamicValue","value":"boolean","default_val":true},"ACn":{"caption":"Unique ID","name":"unique_id","rank":6,"editor":"DynamicValue","optional":true,"value":"text","is_list":false},"ADp":{"caption":"Image Height (px)","name":"height","rank":4,"editor":"DynamicValue","value":"number","optional":true}}},"AAn":{"caption":"Remove Selected Element(s) from","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.deleteElements():alert(\"The Canvas isn't visible on your page. This workflow action (Remove Selected Elements) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"AAo":{"caption":"Add Text to","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Add Text To Canvas) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");function createDataArray(inputString){return inputString&&\"\"!==inputString.trim()?inputString.includes(\",\")?inputString.split(\",\").map((item=>item.trim())):[inputString]:[]}let textBold=properties.bold?\"bold\":\"normal\",textItalic=properties.italic?\"italic\":\"normal\";if(properties.add_a_list_of_texts){let textToAddArray=createDataArray(properties.text_to_add),textXLocationArray=createDataArray(properties.x_location),textYLocationArray=createDataArray(properties.y_location),textColorArray=createDataArray(properties.text_color_list),textUniqueIdArray=createDataArray(properties.text_unique_id);for(let i=0;i<textToAddArray.length;i++)instance.data.createText(textToAddArray[i]||\"\",parseFloat(textXLocationArray[i]||0),parseFloat(textYLocationArray[i]||0),properties.font_size||16,textColorArray[i]||\"#000000\",properties.height||50,properties.width||100,properties.enter_edit_mode||!1,properties.highlight_text||!1,properties.wrappable||!1,properties.textbox_border_color||\"#000000\",properties.text_padding||0,textUniqueIdArray[i]||\"\",properties.selectable||!0,textBold,textItalic,properties.underline||!1,properties.horizontal_align||\"left\",properties.text_shadow_color||\"\",properties.text_shadow_radius||0,properties.text_shadow_y_offset||0,properties.text_shadow_x_offset||0,properties.text_outline_color||\"\",properties.text_outline_width||0)}else{const textObj=instance.data.createText(properties.text_to_add,parseFloat(properties.x_location||0),parseFloat(properties.y_location||0),properties.font_size||16,properties.text_color||\"#000000\",properties.height||50,properties.width||100,properties.enter_edit_mode||!1,properties.highlight_text||!1,properties.wrappable||!1,properties.textbox_border_color||\"#000000\",properties.text_padding||0,properties.text_unique_id||\"\",void 0===properties.selectable||properties.selectable,textBold,textItalic,properties.underline||!1,properties.horizontal_align||\"left\",properties.text_shadow_color||\"\",properties.text_shadow_radius||0,properties.text_shadow_y_offset||0,properties.text_shadow_x_offset||0,properties.text_outline_color||\"\",properties.text_outline_width||0)}}"},"fields":{"AAp":{"caption":"Text to Add","name":"text_to_add","rank":2,"editor":"DynamicValue","value":"text","default_val":"Sample text"},"ABE":{"caption":"X Location","name":"x_location","rank":3,"editor":"DynamicValue","value":"text","default_val":10},"ABF":{"caption":"Y Location","name":"y_location","rank":4,"editor":"DynamicValue","value":"text","default_val":10},"ABG":{"caption":"Font Size (px)","name":"font_size","rank":5,"editor":"DynamicValue","value":"number","default_val":36},"ABL":{"caption":"Text Color","name":"text_color","rank":16,"editor":"Color","default_val":"rgba(51, 51, 51, 1)"},"AEZ":{"caption":"Auto-Enter Edit Mode","name":"enter_edit_mode","rank":6,"editor":"DynamicValue","value":"boolean","default_val":true},"AEa":{"caption":"Highlight Text","name":"highlight_text","rank":7,"editor":"DynamicValue","value":"boolean","default_val":true},"AEb":{"caption":"Height","name":"height","rank":8,"editor":"DynamicValue","value":"number","default_val":200},"AEc":{"caption":"Width","name":"width","rank":9,"editor":"DynamicValue","value":"number","default_val":100},"AEe":{"caption":"Text Lines Wrap","name":"wrappable","rank":12,"editor":"DynamicValue","value":"boolean","default_val":true},"AEh":{"caption":"Textbox Border Color","name":"textbox_border_color","rank":10,"editor":"Color","default_val":"rgba(224, 224, 224, 0)"},"AEi":{"caption":"Text Border Padding","name":"text_padding","rank":11,"editor":"DynamicValue","value":"number","default_val":3},"AEz":{"caption":"Text Unique ID","name":"text_unique_id","rank":14,"editor":"DynamicValue","value":"text","optional":true},"AFc":{"caption":"Selectable?","name":"selectable","rank":13,"editor":"DynamicValue","value":"boolean","default_val":true},"AFr":{"caption":"By checking the box above, you can optionally add a list of texts to the canvas by entering comma-separated lists for each of the fields below.","name":"you_can_optionally_add_a_list_of_texts_to_the_canvas_by_entering_comma-separated_lists_for_each_of_the_fields_below._for_example,_entering_\"rectangle,_triangle,_rectangle\"_in_the_shape_field_would_create_3_shapes:_2_rectangles_and_1_triangle","rank":1,"editor":"Label"},"AFs":{"caption":"Add a list of text elements","name":"add_a_list_of_texts","rank":0,"editor":"Checkbox","default_val":false},"AFt":{"caption":"Text Color List","name":"text_color_list","rank":28,"editor":"DynamicValue","value":"text","optional":true},"AFu":{"caption":"-------------------------- Text Properties ------------------------","name":"----------------------------_shape_colors_---------------------------","rank":15,"editor":"Label"},"AFv":{"caption":"Optional: Add a list of Text Colors below for when you want to add multiple text elements (see checkbox at the top of this workflow action). Adding a comma-separated list of hex colors here overrides color input above)","name":"optional:_add_a_list_of_text_colors_for_when_you_want_to_add_multiple_text_elements_(see_checkbox_at_the_top_of_this_workflow_action)._adding_a_comma-separated_list_of_hex_colors_here_overrides_color_input_above)","rank":27,"editor":"Label"},"AGO":{"caption":"Bold","name":"bold","rank":17,"editor":"DynamicValue","value":"boolean","default_val":false},"AGP":{"caption":"Italic","name":"italic","rank":18,"editor":"DynamicValue","value":"boolean","default_val":false},"AGQ":{"caption":"Underline","name":"underline","rank":19,"editor":"DynamicValue","value":"boolean","default_val":false},"AHB":{"caption":"Horizontal Align","name":"horizontal_align","rank":20,"editor":"DynamicValue","value":"text","default_val":"left"},"AHQ":{"caption":"Text Shadow Color","name":"text_shadow_color","rank":21,"editor":"Color","optional":true},"AHR":{"caption":"Text Shadow Radius","name":"text_shadow_radius","rank":22,"editor":"DynamicValue","value":"number","optional":true},"AHS":{"caption":"Shadow Y Offset","name":"text_shadow_y_offset","rank":23,"editor":"DynamicValue","value":"number","optional":true},"AHT":{"caption":"Shadow X Offset","name":"text_shadow_x_offset","rank":24,"editor":"DynamicValue","optional":true,"value":"number"},"AHU":{"caption":"Text Outline Color","name":"text_outline_color","rank":25,"editor":"Color","optional":true},"AHV":{"caption":"Text Outline Width","name":"text_outline_width","rank":26,"editor":"DynamicValue","value":"number","default_val":0,"is_list":false,"optional":true}}},"AAr":{"caption":"Set Cursor Click Mode","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.cursorMode=properties.Mode,instance.data.setCursorMode()):alert(\"The Canvas isn't visible on your page. This workflow action (Set Cursor Click Mode) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"AAu":{"caption":"Click Mode","name":"Mode","rank":3,"editor":"DynamicValue","value":"text","default_val":"Free Draw/Paint"},"ADl":{"caption":"Set the cursor click mode using a workflow action by typing the mode you'd like the canvas to enter in the field below. The options are: \"Free Draw/Paint\", \"Draw Shape\", \"Select Elements\", \"Add Text\"","name":"info","rank":0,"editor":"Label"},"ADm":{"caption":"This will override the element property's Cursor Click Mode until the next time the Element Properties Cursor Click Mode is changed (e.g. in a conditional)","name":"info2","rank":2,"editor":"Label"},"ADn":{"caption":" ","name":"info_spacer","rank":1,"editor":"Label"}}},"ABH":{"caption":"Bring Forward an Element on","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.fabricCanvas.bringForward(instance.data.fabricCanvas.getActiveObject()),instance.data.updateUndoRedoArray()):alert(\"The Canvas isn't visible on your page. This workflow action (Bring Forward An Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ABI":{"caption":"Send Backward an Element on","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.fabricCanvas.sendBackwards(instance.data.fabricCanvas.getActiveObject()),instance.data.updateUndoRedoArray()):alert(\"The Canvas isn't visible on your page. This workflow action (Send Backward an Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ABK":{"caption":"Download","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Download) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");var link=document.createElement(\"a\");let data=instance.data.fabricCanvas.toDataURL({format:\"png\",resolution:5});link.setAttribute(\"href\",data),link.setAttribute(\"target\",\"_blank\"),link.setAttribute(\"download\",properties.file_name),link.click()}"},"fields":{"AEx":{"caption":"File Name","name":"file_name","rank":0,"editor":"DynamicValue","value":"text","default_val":"Enter your file name here"}}},"ABm":{"caption":"Toggle Selector Mode","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.fabricCanvas.item(0)&&(properties.can_select?instance.data.selectorIsOn=!0:(instance.data.selectorIsOn=!1,instance.data.fabricCanvas.discardActiveObject().renderAll())),instance.data.setCursorMode()):alert(\"The Canvas isn't visible on your page. This workflow action (Toggle Selector Mode) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ADk":{"caption":"Can select?","name":"can_select","rank":0,"editor":"DynamicValue","value":"boolean","default_val":false}}},"ACC":{"caption":"Save (as Serialization)","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.seri
182alizeCanvas():alert(\"The Canvas isn't visible on your page. This workflow action (Save As Serialization) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACE":{"caption":"Load Serialized Canvas","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?(instance.data.serializedCanvas=properties.serialized_canvas,properties.serialized_canvas||(instance.data.serializedCanvas='{\"version\":\"4.0.0-beta.8\",\"objects\":[]}'),instance.data.loadSerializedCanvas(),instance.data.setCursorMode(),instance.data.updateUndoRedoArray(),1==properties.undo_clear_all_prior&&(instance.data.resetUndoRedoArrays(),instance.data.undoArray.unshift(properties.serialized_canvas))):alert(\"The Canvas isn't visible on your page. This workflow action (Load Serialized Canvas) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ACF":{"caption":"Serialized Canvas","name":"serialized_canvas","rank":0,"editor":"DynamicValue","value":"text","default_val":""},"ADZ":{"caption":"Undo/Redo Reset","name":"undo_clear_all_prior","rank":1,"editor":"DynamicValue","value":"boolean","default_val":true}}},"ACR":{"caption":"Undo","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.undo():alert(\"The Canvas isn't visible on your page. This workflow action (Undo) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACS":{"caption":"Redo","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.redo():alert(\"The Canvas isn't visible on your page. This workflow action (Redo) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACX":{"caption":"Clear (Drawing's PNG URL)","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.clearImageURL():alert(\"The Canvas isn't visible on your page. This workflow action (Clear Drawing PNG URL) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACa":{"caption":"Copy Selected Elements on","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.copy():alert(\"The Canvas isn't visible on your page. This workflow action (Copy Selected Elements) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACb":{"caption":"Paste Elements on","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.paste():alert(\"The Canvas isn't visible on your page. This workflow action (Paste Selected Elements) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ACw":{"caption":"Deselect All Elements","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.fabricCanvas.discardActiveObject().renderAll():alert(\"The Canvas isn't visible on your page. This workflow action (Deselect All Elements) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ADA":{"caption":"Update Shape(s)","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Update Selected Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");if(!instance.data.selectedObject)return;let fillColor,outlineColor,selectable,outlineWidth;if(fillColor=null!=properties.fill_color?properties.fill_color:instance.data.selectedObject.fill,outlineColor=null!=properties.outline_color?properties.outline_color:instance.data.selectedObject.
182stroke,selectable=null!=properties.selectable?properties.selectable:instance.data.selectedObject.selectable,outlineWidth=null!=properties.outline_width?properties.outline_width:instance.data.selectedObject.strokeWidth,null==properties.element_ids)instance.data.selectedObject.set({fill:fillColor,stroke:outlineColor,selectable:selectable,strokeWidth:outlineWidth}),instance.data.fabricCanvas.renderAll();else{let element_ids_array=properties.element_ids.split(\", \"),element_array=[];var modifyObject=function(ObjectSet,ObjectName){ObjectSet.forEach((function(o){o.bubble_id===ObjectName&&(console.log(\"got in here\"),o.set({fill:fillColor,stroke:outlineColor,selectable:selectable,strokeWidth:outlineWidth}),element_array.push(o)),o._objects&&modifyObject(o._objects,ObjectName)}))};for(let i=0;i<element_ids_array.length;i++)modifyObject(instance.data.fabricCanvas.getObjects(),element_ids_array[i]);instance.data.fabricCanvas.requestRenderAll()}}"},"fields":{"ADB":{"caption":"Fill Color","name":"fill_color","rank":0,"editor":"DynamicValue","value":"text","optional":true},"ADC":{"caption":"Outline Color","name":"outline_color","rank":1,"editor":"DynamicValue","value":"text","optional":true},"ADD":{"caption":"Selectable?","name":"selectable","rank":3,"editor":"DynamicValue","value":"boolean","optional":true},"ADE":{"caption":"Outline Width","name":"outline_width","rank":2,"editor":"DynamicValue","value":"number","optional":true},"AFf":{"caption":"Element IDs","name":"element_ids","rank":5,"editor":"DynamicValue","value":"text","optional":true},"AFg":{"caption":"Optional: This workflow action defaults to updating selected shapes on the canvas. If you'd like to update specific shapes based on the Shape's Element ID, add a comma-separated list of element IDs below:","name":"this_action_defaults_to_updating_selected_shapes_on_the_canvas._if_you'd_like_to_update_specific_shapes_based_on_the_shape's_element_id,_add_a_comma-separated_list_of_element_ids_below:","rank":4,"editor":"Label"}}},"ADH":{"caption":"Download Canvas (sets a link to download)","code":{"fn":"function(instance,properties,context){var saveButton;instance.data.fabricCanvas?document.getElementById(properties.html_id).addEventListener(\"click\",(function(e){this.href=instance.data.fabricCanvas.toDataURL({format:\"png\"}),this.download=properties.file_name+\".png\"}),!1):alert(\"The Canvas isn't visible on your page. This workflow action (Download Canvase Sets Link) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ADI":{"caption":"HTML id","name":"html_id","rank":6,"editor":"DynamicValue","value":"text"},"ADJ":{"caption":"File name","name":"file_name","rank":7,"editor":"DynamicValue","value":"text","default_val":"Your File Name Here"},"AEp":{"caption":"**Due to complexities with JavaScript download functionality, you will need to closely follow the following instructions:","name":"instructions","rank":0,"editor":"Label"},"AEq":{"caption":"1. Add a standard Bubble link element to your page. This will be your Download button. Update the style of the link element as needed. See www.bit.ly/idattribute if you don't know how to do this.","name":"1._add_a_link_element_to_your_page._update_the_style_of_the_link_element_as_needed.","rank":1,"editor":"Label"},"AEr":{"caption":"2. Give that link element an HTML id attribute","name":"2._give_that_link_element_an_html_id_attribute","rank":2,"editor":"Label"},"AEs":{"caption":"---------------------------------- Fields --------------------------------","name":"----------------------------------_shape_---------------------------------","rank":5,"editor":"Label"},"AEt":{"caption":"3. Copy and paste that same HTML id attribute from step #2 into the field titled \"HTML id\" below","name":"3._copy_and_paste_that_same_html_id_attribute_from_step_#2_into_the_field_titled_\"html_id\"_below","rank":3,"editor":"Label"},"AEu":{"caption":"4. Run this workflow action when the link element is visible on the page (e.g. when the page is loaded, or when the group containing the link is visible)","name":"4._run_this_workflow_action_when_the_link_element_is_visible_on_the_page_(e.g._when_the_page_is_loaded,_or_when_the_group_containing_the_link_is_visible)","rank":4,"editor":"Label"}}},"ADM":{"caption":"Horizontally Flip Selected Element on ","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?null!=instance.data.fabricCanvas.getActiveObject()&&(instance.data.fabricCanvas.getActiveObject().set(\"flipX\",!instance.data.fabricCanvas.getActiveObject().get(\"flipX\")),instance.data.fabricCanvas.renderAll()):alert(\"The Canvas isn't visible on your page. This workflow action (Horizontally Flip Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ADO":{"caption":"Vertically Flip Selected Element on ","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?null!=instance.data.fabricCanvas.getActiveObject()&&(instance.data.fabricCanvas.getActiveObject().set(\"flipY\",!instance.data.fabricCanvas.getActiveObject().get(\"flipY\")),instance.data.fabricCanvas.renderAll()):alert(\"The Canvas isn't visible on your page. This workflow action (Vertically Flip Selected Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ADP":{"caption":"Set Canvas Dimensions","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas?instance.data.setCanvasDimensions(properties.width,properties.height):alert(\"The Canvas isn't visible on your page. This workflow action (Set Canvas Dimensions) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ADQ":{"caption":"Width","name":"width","rank":0,"editor":"DynamicValue","value":"number","optional":true,"default_val":"300"},"ADR":{"caption":"Height","name":"height","rank":1,"editor":"DynamicValue","value":"number","optional":true,"default_val":"400"},"ADS":{"caption":"Fixed Aspect Ratio?","name":"fixed_aspect_ratio","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false}}},"ADV":{"caption":"Scale All Elements","code":{"fn":"function(instance,properties,context){function GetCanvasAtResoution(newWidth){if(instance.data.fabricCanvas.width!=newWidth){var scaleMultiplier=properties.width,objects=instance.data.fabricCanvas.getObjects();for(var i in objects)objects[i].scaleX=objects[i].scaleX*scaleMultiplier,objects[i].scaleY=objects[i].scaleY*scaleMultiplier,objects[i].left=objects[i].left*scaleMultiplier,objects[i].top=objects[i].top*scaleMultiplier,objects[i].setCoords();var obj=instance.data.fabricCanvas.backgroundImage;obj&&(obj.scaleX=obj.scaleX*scaleMultiplier,obj.scaleY=obj.scaleY*scaleMultiplier),instance.data.fabricCanvas.discardActiveObject(),instance.data.fabricCanvas.renderAll(),instance.data.fabricCanvas.calcOffset()}}instance.data.fabricCanvas?GetCanvasAtResoution(properties.width):alert(\"The Canvas isn't visible on your page. This workflow action (Scale All Elements) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ADW":{"caption":"Multiple","name":"width","rank":0,"editor":"DynamicValue","value":"number"}}},"ADe":{"caption":"Reset Undo/Redo","code":{"fn":"function(instance,properties,context){function resetCanvas(){instance.data.seri
182alizeCanvas(),instance.data.resetUndoRedoArrays(),instance.data.undoArray.unshift(instance.data.serializedCanvasForUndoReset)}instance.data.fabricCanvas?setTimeout(resetCanvas,2e3):alert(\"The Canvas isn't visible on your page. This workflow action (Reset Undo/Redo) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"}},"ADf":{"caption":"Select Elements by ID","code":{"fn":"function(instance,properties,context){if(!instance.data.fabricCanvas)return void alert(\"The Canvas isn't visible on your page. This workflow action (Select Elements by ID) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\");let numTries=0,foundObject=!1,selected_ids=[],element_ids_array=properties.element_unique_id.split(\", \"),element_array=[];var addObject=function(ObjectName){instance.data.fabricCanvas.getObjects().forEach((function(o){o.bubble_id===ObjectName&&(element_array.push(o),foundObject=!0,selected_ids.push(o.bubble_id))}))};for(let i=0;i<element_ids_array.length;i++)addObject(element_ids_array[i]);instance.data.fabricCanvas.discardActiveObject();var sel=new fabric.ActiveSelection(element_array,{canvas:instance.data.fabricCanvas});instance.data.fabricCanvas.setActiveObject(sel),instance.data.fabricCanvas.requestRenderAll(),instance.data.updateSelectedObject(!0),instance.publishState(\"selected_elements_list\",selected_ids),setTimeout((function(){0==foundObject&&SelectObject(properties.element_unique_id)}),1e3),instance.data.fabricCanvas.renderAll()}","add_debugger":false},"fields":{"ADg":{"caption":"Element Unique ID","name":"element_unique_id","rank":0,"editor":"DynamicValue","value":"text"}}},"ADq":{"caption":"Modify Selected Element","code":{"fn":"function(instance,properties,context){if(instance.data.fabricCanvas){if(!instance.data.fabricCanvas.getActiveObject())return null;for(let i=0;i<instance.data.fabricCanvas.getActiveObjects().length;i++){let elementsList=instance.data.fabricCanvas.getActiveObjects();\"rect\"==elementsList[i].get(\"type\")||\"triangle\"==elementsList[i].get(\"type\")||\"ellipse\"==elementsList[i].get(\"type\")||\"line\"==elementsList[i].get(\"type\")?elementsList[i].set({fill:properties.fill_color,strokeWidth:properties.outline_width,stroke:properties.outline_color}):\"path\"==elementsList[i].get(\"type\")?elementsList[i].set({strokeWidth:properties.stroke_width,stroke:properties.draw_color}):\"i-text\"!=elementsList[i].get(\"type\")&&\"textbox\"!=elementsList[i].get(\"type\")||elementsList[i].set({fontFamily:properties.font_family,fill:properties.font_color,fontSize:properties.font_size,text:properties.text_value,textboxBorderColor:properties.textbox_border_color,padding:properties.text_padding,textAlign:properties.horizontal_align})}1==instance.data.fabricCanvas.getActiveObjects().length&&instance.data.updateSelectedElementStates(instance.data.fabricCanvas.getActiveObjects()[0]),instance.data.fabricCanvas.renderAll()}else alert(\"The Canvas isn't visible on your page. This workflow action (Modify Selected Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"ADr":{"caption":"If the selected element is not a drawing, then the drawing will be ignored","name":"shape","rank":1,"editor":"Label"},"ADs":{"caption":"---------------------------------- Shape ---------------------------------","name":"-------------_shape_-----------","rank":4,"editor":"Label"},"ADt":{"caption":"-------------------------------- Drawing -------------------------------","name":"----------_drawing_----------","rank":0,"editor":"Label"},"ADv":{"caption":"Fill Color","name":"fill_color","rank":6,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ADw":{"caption":"Outline Color","name":"outline_color","rank":7,"editor":"Color","default_val":"rgba(199, 199, 199, 1)"},"ADx":{"caption":"Outline Width","name":"outline_width","rank":8,"editor":"DynamicValue","value":"number","default_val":2},"ADy":{"caption":"Color","name":"draw_color","rank":2,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ADz":{"caption":"Stroke Width","name":"stroke_width","rank":3,"editor":"DynamicValue","value":"number","default_val":2},"AEB":{"caption":"------------------------------------ Text ---------------------------------","name":"----------------------------------_text_---------------------------------","rank":9,"editor":"Label"},"AEC":{"caption":"Font Family","name":"font_family","rank":11,"editor":"DynamicValue","value":"text","default_val":"Lato"},"AED":{"caption":"Font Color","name":"font_color","rank":12,"editor":"Color","default_val":"rgba(87, 87, 87, 1)"},"AEE":{"caption":"Font Size","name":"font_size","rank":13,"editor":"DynamicValue","value":"number","default_val":20},"AEF":{"caption":"Text Value","name":"text_value","rank":14,"editor":"DynamicValue","value":"text","default_val":"...edit me...","optional":true},"AEU":{"caption":"If the selected element is not a shape, then the shape section will be ignored","name":"if_the_selected_element_is_not_a_drawing,_then_the_drawing_will_be_ignored","rank":5,"editor":"Label"},"AEV":{"caption":"If the selected element is not a text, then the text section will be ignored","name":"if_the_selected_element_is_not_a_text,_then_the_text_section_will_be_ignored","rank":10},"AEj":{"caption":"Textbox Border Color","name":"textbox_border_color","rank":15,"editor":"Color","default_val":"rgba(217, 217, 217, 0)"},"AEk":{"caption":"Text Padding","name":"text_padding","rank":16,"editor":"DynamicValue","value":"number","default_val":3},"AHC":{"caption":"Horizontal Align","name":"horizontal_align","rank":17,"editor":"DynamicValue","value":"text","default_val":"left"}}},"AFS":{"caption":"Change Element Dimensions","code":{"fn":"function(instance,properties,context){if(instance.data.fabricCanvas){if(!instance.data.fabricCanvas.getActiveObject())return null;for(let i=0;i<instance.data.fabricCanvas.getActiveObjects().length;i++){let elementsList=instance.data.fabricCanvas.getActiveObjects();if(properties.rotation&&elementsList[i].rotate(properties.rotation),null==elementsList[i]._element)properties.width&&elementsList[i].set({width:properties.width,scaleX:1}),properties.height&&elementsList[i].set({height:properties.height,scaleY:1}
182);else{if(properties.width&&!properties.height){instance.data.old_img_width=elementsList[i].width;let imageScale=properties.width/instance.data.old_img_width;console.log(imageScale),elementsList[i].set({scaleX:imageScale,scaleY:imageScale})}if(properties.width&&properties.height){instance.data.old_img_width=elementsList[i].width,instance.data.old_img_height=elementsList[i].height;let imageScaleX=properties.width/instance.data.old_img_width,imageScaleY=properties.height/instance.data.old_img_height;elementsList[i].set({scaleX:imageScaleX,scaleY:imageScaleY})}if(!properties.width&&properties.height){instance.data.old_img_height=elementsList[i].height;let imageScale=properties.height/instance.data.old_img_height;elementsList[i].set({scaleX:imageScale,scaleY:imageScale})}}}1==instance.data.fabricCanvas.getActiveObjects().length&&instance.data.updateSelectedElementStates(instance.data.fabricCanvas.getActiveObjects()[0]),instance.data.fabricCanvas.renderAll()}else alert(\"The Canvas isn't visible on your page. This workflow action (Modify Selected Element) can only be run once the Main-Canvas Element is visible on the page. Set up this workflow action to occur only after your Canvas is visible on the page\")}"},"fields":{"AFT":{"caption":"Element Width","name":"width","rank":1,"editor":"DynamicValue","value":"number","optional":true},"AFU":{"caption":"Element Height","name":"height","rank":2,"editor":"DynamicValue","value":"number","optional":true},"AFV":{"caption":"Element Rotation","name":"rotation","rank":3,"editor":"DynamicValue","value":"number","optional":true},"AFW":{"caption":"Change the width, height (in pixels) or angle (in degrees) using the fields below. Keep blank to remain unchanged.","name":"change_the_width,_height_(in_pixels)_or_angle_(in_degrees)_using_the_fields_below.__keep_blank_to_remain_unchanged.","rank":0,"editor":"Label"}}},"AFd":{"caption":"Group Selected Elements","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas.getActiveObject()&&\"activeSelection\"===instance.data.fabricCanvas.getActiveObject().type&&(instance.data.fabricCanvas.getActiveObject().toGroup(),instance.data.fabricCanvas.requestRenderAll())}"}},"AFe":{"caption":"Ungroup Selected Elements","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas.getActiveObject()&&\"group\"===instance.data.fabricCanvas.getActiveObject().type&&(instance.data.fabricCanvas.getActiveObject().toActiveSelection(),instance.data.fabricCanvas.requestRenderAll())}"}},"AFx":{"caption":"Download as SVG","code":{"fn":"function(instance,properties,context){let mySVG=instance.data.fabricCanvas.toSVG();console.log(mySVG);const svgBlob=new Blob([mySVG],{type:\"image/svg+xml;charset=utf-8\"}),svgUrl=URL.createObjectURL(svgBlob);console.log(svgUrl);const downloadLink=document.createElement(\"a\");downloadLink.href=svgUrl,downloadLink.download=\"mySvgFile.svg\",document.body.appendChild(downloadLink),downloadLink.click(),document.body.removeChild(downloadLink),URL.revokeObjectURL(svgUrl)}"}},"AGH":{"caption":"Update Selected Text Font Style","code":{"fn":"function(instance,properties,context){if(console.log(\"font \"+properties.font_style),null!=instance.data.fabricCanvas.getActiveObject()){let textObject=instance.data.fabricCanvas.getActiveObject();if(properties.bold?textObject.set({fontWeight:\"bold\"}):textObject.set({fontWeight:\"normal\"}),properties.underline?textObject.set({underline:!0}):textObject.set({underline:!1}),properties.italic?textObject.set({fontStyle:\"italic\"}):textObject.set({fontStyle:\"normal\"}),console.log(properties.font_style),properties.font_style){const selectedFont=properties.font_style?properties.font_style.split(\":\")[0].trim():\"Roboto\",fontUrl=`https://fonts.googleapis.com/css2?family=${encodeURIComponent(selectedFont)}`,dynamicFont=new FontFace(selectedFont,`url(${fontUrl})`);dynamicFont.load().then((()=>{document.fonts.add(dynamicFont),textObject.set({fontFamily:selectedFont,dirty:!0}),instance.data.fabricCanvas.requestRenderAll()})).catch((()=>{console.error(`Failed to load font: ${selectedFont}`)}))}textObject.set({shadow:{color:properties.text_shadow_color,blur:properties.text_shadow_radius,offsetX:properties.text_shadow_x_offset,offsetY:properties.text_shadow_y_offset},stroke:properties.text_outline_color,strokeWidth:properties.text_outline_width}),instance.publishState(\"selected_text_bold\",textObject.get(\"fontWeight\")),instance.publishState(\"selected_text_italic\",textObject.get(\"fontStyle\")),instance.publishState(\"selected_text_underline\",textObject.get(\"underline\")),instance.publishState(\"selected_text_alignment\",textObject.get(\"textAlign\")),instance.publishState(\"selected_text_shadow_color\",properties.text_shadow_color),instance.publishState(\"selected_text_shadow_radius\",properties.text_shadow_radius),instance.publishState(\"selected_text_shadow_x_offset\",properties.text_shadow_x_offset),instance.publishState(\"selected_text_shadow_y_offset\",properties.text_shadow_y_offset),instance.publishState(\"selected_text_outline_color\",properties.text_outline_color),instance.publishState(\"selected_text_outline_width\",properties.text_outline_width),instance.data.fabricCanvas.requestRenderAll()}}"},"fields":{"AGI":{"caption":"Bold","name":"bold","rank":0,"editor":"DynamicValue","value":"boolean","default_val":false},"AGJ":{"caption":"Underline","name":"underline","rank":1,"editor":"DynamicValue","value":"boolean","default_val":false},"AGK":{"caption":"Italic","name":"italic","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false},"AHE":{"caption":"Font Family","name":"font_style","rank":3,"editor":"DynamicValue","value":"text","optional":true},"AHk":{"caption":"Text Shadow Color","name":"text_shadow_color","rank":4,"editor":"Color","optional":true},"AHl":{"caption":"Text Shadow Radius","name":"text_shadow_radius","rank":5,"editor":"DynamicValue","value":"number","optional":true,"default_val":0},"AHm":{"caption":"Shadow Y Offset","name":"shadow_y_offset","rank":6,"editor":"DynamicValue","optional":true,"value":"number"},"AHn":{"caption":"Shadow X Offset","name":"shadow_x_offset","rank":7,"editor":"DynamicValue","value":"number","optional":true},"AHo":{"caption":"Text Outline Color","name":"text_outline_color","rank":8,"optional":true,"editor":"Color"},"AHp":{"caption":"Text Outline Width","name":"text_outline_width","rank":9,"editor":"DynamicValue","value":"number","optional":true,"default_val":0}}},"AGR":{"caption":"Add Polygon","code":{"fn":"function(instance,properties,context){let xArray=properties.list_of_x_corners.split(\",\").map((item=>parseInt(item.trim()))),yArray=properties.list_of_y_corners.split(\",\").map((item=>parseInt(item.trim()))),points=xArray.map(((x,index)=>({x:x,y:yArray[index]})));var polygon=new fabric.Polygon(points,{left:100,top:50,fill:properties.fill_color,strokeWidth:2,stroke:properties.line_color,scaleX:4,scaleY:4,objectCaching:!1,transparentCorners:!1,cornerColor:\"blue\",id:properties.unique_id});instance.data.fabricCanvas.add(polygon),instance.data.fabricCanvas.requestRenderAll()}"},"fields":{"AGS":{"caption":"Unique ID","name":"unique_id","rank":0,"editor":"DynamicValue","value":"text","optional":true},"AGV":{"caption":"List of Corners - X","name":"list_of_x_corners","rank":1,"editor":"DynamicValue","value":"text","optional":true},"AGW":{"caption":"List of Corners - Y","name":"list_of_y_corners","rank":2,"editor":"DynamicValue","value":"text","optional":true},"AGZ":{"caption":"Fill Color","name":"fill_color","rank":3,"editor":"Color","default_val":"rgba(255,255,255,1)"},"AGa":{"caption":"Line Color","name":"line_color","rank":4,"editor":"Color","default_val":"rgba(130,130,130,1)"}}},"AGX":{"caption":"Enable Editing Polygon","code":{"fn":"function(instance,properties,context){function polygonPositionHandler(dim,finalMatrix,fabricObject){var x=fabricObject.points[this.pointIndex].x-fabricObject.pathOffset.x,y=fabricObject.points[this.pointIndex].y-fabricObject.pathOffset.
182y;return fabric.util.transformPoint({x:x,y:y},fabric.util.multiplyTransformMatrices(fabricObject.canvas.viewportTransform,fabricObject.calcTransformMatrix()))}function getObjectSizeWithStroke(object){var stroke=new fabric.Point(object.strokeUniform?1/object.scaleX:1,object.strokeUniform?1/object.scaleY:1).multiply(object.strokeWidth);return new fabric.Point(object.width+stroke.x,object.height+stroke.y)}function actionHandler(eventData,transform,x,y){var polygon=transform.target,currentControl=polygon.controls[polygon.__corner],mouseLocalPosition=polygon.toLocalPoint(new fabric.Point(x,y),\"center\",\"center\"),polygonBaseSize=getObjectSizeWithStroke(polygon),size=polygon._getTransformedDimensions(0,0),finalPointPosition={x:mouseLocalPosition.x*polygonBaseSize.x/size.x+polygon.pathOffset.x,y:mouseLocalPosition.y*polygonBaseSize.y/size.y+polygon.pathOffset.y};return polygon.points[currentControl.pointIndex]=finalPointPosition,!0}function anchorWrapper(anchorIndex,fn){return function(eventData,transform,x,y){var fabricObject=transform.target,absolutePoint=fabric.util.transformPoint({x:fabricObject.points[anchorIndex].x-fabricObject.pathOffset.x,y:fabricObject.points[anchorIndex].y-fabricObject.pathOffset.y},fabricObject.calcTransformMatrix()),actionPerformed=fn(eventData,transform,x,y),newDim=fabricObject._setPositionDimensions({}),polygonBaseSize=getObjectSizeWithStroke(fabricObject),newX=(fabricObject.points[anchorIndex].x-fabricObject.pathOffset.x)/polygonBaseSize.x,newY=(fabricObject.points[anchorIndex].y-fabricObject.pathOffset.y)/polygonBaseSize.y;return fabricObject.setPositionByOrigin(absolutePoint,newX+.5,newY+.5),actionPerformed}}const findObjectById=(canvas,id)=>instance.data.fabricCanvas.getObjects().find((obj=>obj.id===id));function Edit(){var poly=findObjectById(instance.data.fabricCanvas,properties.unique_id);if(instance.data.fabricCanvas.setActiveObject(poly),poly.edit=!poly.edit,poly.edit){var lastControl=poly.points.length-1;poly.cornerStyle=\"circle\",poly.cornerColor=properties.corner_color,poly.controls=poly.points.reduce((function(acc,point,index){return acc[\"p\"+index]=new fabric.Control({positionHandler:polygonPositionHandler,actionHandler:anchorWrapper(index>0?index-1:lastControl,actionHandler),actionName:\"modifyPolygon\",pointIndex:index}),acc}),{})}else poly.cornerColor=\"blue\",poly.cornerStyle=\"rect\",poly.controls=fabric.Object.prototype.controls;poly.hasBorders=!poly.edit,instance.data.fabricCanvas.requestRenderAll()}Edit()}"},"fields":{"AGY":{"caption":"Unique Id","name":"unique_id","rank":0,"editor":"DynamicValue","value":"text"},"AGb":{"caption":"Corner Color","name":"corner_color","rank":1,"editor":"Color","default_val":"rgba(82,156,179,1)"}}},"AGd":{"caption":"Add Line (Advanced)","code":{"fn":"function(instance,properties,context){fabric.Object.prototype.originX=fabric.Object.prototype.originY=\"center\";let xArray=properties.x_locations.split(\",\").map((item=>parseInt(item.trim()))),yArray=properties.y_locations.split(\",\").map((item=>parseInt(item.trim()))),points=xArray.map(((x,index)=>({x:x,y:yArray[index]})));var line=instance.data.makeLine([xArray[0],yArray[0],xArray[1],yArray[1]],properties.line_color,properties.line_thickness);instance.data.fabricCanvas.add(line),instance.data.fabricCanvas.add(instance.data.makeCircle(line.get(\"x1\"),line.get(\"y1\"),null,line,properties.controls_radiu
182s,properties.controls_fill,properties.controls_color,!0),instance.data.makeCircle(line.get(\"x2\"),line.get(\"y2\"),line,null,properties.controls_radius,properties.controls_fill,properties.controls_color,!0)),instance.data.fabricCanvas.on(\"object:moving\",(function(e){var p=e.target;p.line1&&p.line1.set({x2:p.left,y2:p.top}),p.line2&&p.line2.set({x1:p.left,y1:p.top});var advancedLineObjects=instance.data.fabricCanvas.getObjects().filter((function(obj){return\"advancedLine\"===obj.uniqueID}));for(let i=0;i<advancedLineObjects.length;i++)advancedLineObjects[i].selectable=!1;if(advancedLineObjects.length>0){var activeSelection=new fabric.ActiveSelection(advancedLineObjects,{canvas:instance.data.fabricCanvas});instance.data.fabricCanvas.setActiveObject(activeSelection)}instance.data.fabricCanvas.discardActiveObject().renderAll()}))}"},"fields":{"AGe":{"caption":"X locations","name":"x_locations","rank":0,"editor":"DynamicValue","value":"text","default_val":"20, 100"},"AGf":{"caption":"Y locations","name":"y_locations","rank":1,"editor":"DynamicValue","value":"text","default_val":"20, 100"},"AGg":{"caption":"Line Color","name":"line_color","rank":2,"editor":"Color","default_val":"rgba(177,177,177,1)"},"AGh":{"caption":"Line Thickness","name":"line_thickness","rank":3,"editor":"DynamicValue","value":"number","default_val":2}
182,"AGi":{"caption":"Controls radius","name":"controls_radius","rank":4,"editor":"DynamicValue","value":"number","default_val":5},"AGj":{"caption":"Controls Outline","name":"controls_color","rank":5,"editor":"Color","default_val":"rgba(174,174,174,1)"},"AGk":{"caption":"Controls Fill","name":"controls_fill","rank":6,"editor":"Color","default_val":"rgba(255,255,255,1)"},"AGl":{"caption":"Controles Outline (px)","name":"controles_outline_(px)","rank":7,"editor":"DynamicValue","value":"number","default_val":2}}},"AHL":{"caption":"Save Canvas as SVG","code":{"fn":"function(instance,properties,context){let cleanedSVG;function exportToSVG(){var svgString=instance.data.fabricCanvas.toSVG(),parser,xmlDoc=(new DOMParser).parseFromString(svgString,\"image/svg+xml\"),desc=xmlDoc.getElementsByTagName(\"desc\")[0];desc&&desc.parentNode.removeChild(desc);var defs=xmlDoc.getElementsByTagName(\"defs\")[0];defs&&0===defs.childNodes.length&&defs.parentNode.removeChild(defs);var serializer=new XMLSerializer;cleanedSVG=serializer.serializeToString(xmlDoc.documentElement)}if(instance.data.background_image){var backgroundImageUrl=\"https:\"+instance.data.background_image;function completeExport(){exportToSVG(),instance.publishState(\"svg_value\",cleanedSVG),instance.data.fabricCanvas.setBackgroundImage(null,instance.data.fabricCanvas.renderAll.bind(instance.data.fabricCanvas))}fabric.Image.fromURL(backgroundImageUrl,(function(img){var scaleX=null!==instance.data.background_image_width_multiplier?instance.data.background_image_width_multiplier:1,scaleY=null!==instance.data.background_image_height_multiplier?instance.data.background_image_height_multiplier:1;instance.data.fabricCanvas.setBackgroundImage(img,instance.data.fabricCanvas.renderAll.bind(instance.data.fabricCanvas),{scaleX:instance.data.bg_image_width,scaleY:instance.data.bg_image_height})})),setTimeout(completeExport,250)}else exportToSVG(),instance.publishState(\"svg_value\",cleanedSVG);function triggerSVGcomplete(){instance.triggerEvent(\"svg_generated\",(function(err){}))}setTimeout(triggerSVGcomplete,250)}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Techblocks Canvas';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '15px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){function getObjectsByUniqueID(uniqueID){var matchedObjects=[];return instance.data.fabricCanvas.forEachObject((function(obj){obj.uniqueID&&obj.uniqueID===uniqueID&&matchedObjects.push(obj)})),matchedObjects}function updateSelectedAdvancedLine(line){instance.publishState(\"selected_advanced_line_width\",line.width),instance.publishState(\"selected_advanced_line_height\",line.he
182ight),instance.publishState(\"selected_advanced_line_x\",line.aCoords.tl.x),instance.publishState(\"selected_advanced_line_y\",line.aCoords.tl.y)}function updateSelectedElementsAdvancedLine(line){instance.data.fabricCanvas.discardActiveObject().renderAll();let selectedObjects=line,selected_ids=[],selected_widths=[],selected_heights=[],selected_x_locations=[],selected_y_locations=[];selected_ids.push(selectedObjects.bubble_id),selected_widths.push(selectedObjects.width*selectedObjects.scaleX),selected_heights.push(selectedObjects.height*selectedObjects.scaleY),selected_x_locations.push(selectedObjects.aCoords.tl.x),selected_y_locations.push(selectedObjects.aCoords.tl.y),instance.publishState(\"selected_elements_list\",selected_ids),instance.publishState(\"selected_elements_width_list\",selected_widths),instance.publishState(\"selected_elements_height_list\",selected_heights),instance.publishState(\"selected_elements_x_locations\",selected_x_locations),instance.publishState(\"selected_elements_y_locations\",selected_y_locations),instance.data.selectedObject=line,instance.publishState(\"selected_element_type\",\"advancedline\")}function makeCircle(left,top,line1,line2,c_radius,c_fill,c_color,selectable){null==selectable&&(selectable=!1);var c=new fabric.Circle({left:left,top:top,strokeWidth:5,radius:c_radius,fill:c_fill,stroke:c_color,hoverCursor:\"default\",uniqueID:\"cornerCircle\",selectable:selectable});return selectable&&c.set({hoverCursor:\"grab\"}),c.hasControls=c.hasBorders=!1,c.line1=line1,c.line2=line2,c}function makeLine(coords,l_color,l_thickness){let line=new fabric.Line(coords,{stroke:l_color,strokeWidth:l_thickness,selectable:!1,hasBorders:!1,hasControls:!1,hoverCursor:\"grab\",uniqueID:\"advancedLine\"});return line.on(\"mousedown\",(function(){line.set({stroke:\"green\"}),updateSelectedElementsAdvancedLine(line),instance.data.fabricCanvas.renderAll()})),line}function resetUndoRedoArrays(){instance.data.undoArray=[],instance.data.redoArray=[],instance.publishState(\"num_undo_available\",0),instance.publishState(\"num_redo_available\",0)}function updateUndoRedoArray(){{let serializedCanvas=JSON.stringify(instance.data.fabricCanvas.toJSON([\"bubble_id\",\"selectable\"]));serializedCanvas!=instance.data.undoArray[0]&&instance.data.undoArray.unshift(serializedCanvas),instance.data.redoArray=[]}let numUndos;instance.data.updateSelectedObject(),instance.triggerEvent(\"canvas_modified\",(function(err){})),numUndos=0==instance.data.undoArray.length?0:instance.data.undoArray.length-1,instance.publishState(\"num_undo_available\",numUndos),instance.publishState(\"num_redo_available\",instance.data.redoArray.length)}function undo(){{if(instance.data.undoArray.length>1){if(2==instance.data.undoArray.length&&instance.data.background_image)return;let newRedoElement=instance.data.undoArray.shift();instance.data.redoArray.unshift(newRedoElement),instance.data.fabricCanvas.loadFromJSON(instance.data.undoArray[0])}let numUndos;instance.triggerEvent(\"canvas_modified\",(function(err){})),numUndos=0==instance.data.undoArray.length?0:instance.data.undoArray.length-1,instance.publishState(\"num_undo_available\",numUndos),instance.publishState(\"num_redo_available\",instance.data.redoArray.length)}}function redo(){if(instance.data.redoArray.length>0){let newUndoElement=instance.data.redoArray.shift();instance.data.undoArray.unshift(newUndoElement),instance.data.fabricCanvas.loadFromJSON(newUndoElement)}instance.publishState(\"num_undo_available\",instance.data.undoArray.length-1),instance.publishState(\"num_redo_available\",instance.data.redoArray.length)}function setHeightWidth(node,heightDelta,widthDelta){node.style.height=heightDelta+\"px\",node.style.width=widthDelta+\"px\",null!=node.parentNode&&setHeightWidth(node.parentNode,node.parentNode.offsetHeight+200,node.parentNode.style.width)}function setCanvasDimensions(width,height,maintainAspectRatio){instance.data.fabricCanvas.setDimensions({width:width,height:height});let myCanvas=document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId);myCanvas.parentNode.parentNode.style.height=height+\"px\",myCanvas.parentNode.parentNode.style.width=width+\"px\",maintainAspectRatio&&(instance.data.fixedAspectRatio=!0),instance.data.aspectRatio=height/width,instance.data.updateBubbleElement(width,height,instance.data.fabricCanvas.backgroundColor)}function uploadContentCallback(err,url){url?(instance.publishState(\"drawing\",url),instance.triggerEvent(\"saved_image_URL_is_generated\",(function(err){}))):console.error(\"Drawing plugin\",\"Error on uploadContent:\",err)}function uploadContentCallback2(err,url){url?(instance.publishState(\"svg_url\",url),instance.triggerEvent(\"saved_image_SVG_is_generated\",(function(err){}))):console.error(\"Drawing plugin\",\"Error on uploadContent:\",err)}function saveImage(){let imageData=instance.data.fabricCanvas.toDataURL({format:\"png\",multiplier:5}),imageDataPng=imageData.substring(imageData.indexOf(\",\")+1),pngFileName=instance.data.savedPngName+\".png\";context.uploadContent(pngFileName,imageDataPng,instance.data.uploadContentCallback)}function clearImageURL(){instance.publishState(\"drawing\",\"\")}function serializeCanvas(){console.log(\"serializing\");let serializedCanvas=JSON.stringify(instance.data.fabricCanvas.toJSON([\"bubble_id\",\"selectable\"]));instance.publishState(\"serialized_canvas\",serializedCanvas),instance.triggerEvent(\"saved_image_serialization_is_generated\",(function(err){}
182)),instance.data.serializedCanvasForUndoReset=serializedCanvas}function GetCanvasAtResoution(newWidth){if(instance.data.fabricCanvas.width!=newWidth){var scaleMultiplier=newWidth/instance.data.fabricCanvas.width,objects=instance.data.fabricCanvas.getObjects();for(var i in objects)objects[i].scaleX=objects[i].scaleX*scaleMultiplier,objects[i].scaleY=objects[i].scaleY*scaleMultiplier,objects[i].left=objects[i].left*scaleMultiplier,objects[i].top=objects[i].top*scaleMultiplier,objects[i].setCoords();var obj=instance.data.fabricCanvas.backgroundImage;obj&&(obj.scaleX=obj.scaleX*scaleMultiplier,obj.scaleY=obj.scaleY*scaleMultiplier),instance.data.fabricCanvas.discardActiveObject(),instance.data.fabricCanvas.renderAll(),instance.data.fabricCanvas.calcOffset()}}function updateBubbleElement(bubbleWidth,bubbleHeight){if(instance.data.widthRatio=bubbleWidth/instance.data.oldBubbleWidth,instance.data.fabricCanvas.backgroundColor=instance.data.backgroundColor,instance.data.background_image&&(instance.data.fabricCanvas.backgroundColor=\"rgba(255, 255, 255, 0)\"),instance.data.fixedAspectRatio){let myCanvas=document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId);myCanvas.parentNode.parentNode.style.height=instance.data.aspectRatio*bubbleWidth+\"px\",myCanvas.parentNode.parentNode.parentNode.style.height=instance.data.aspectRatio*bubbleWidth+\"px\",myCanvas.parentNode.parentNode.parentNode.parentNode.style.height=instance.data.aspectRatio*bubbleWidth+\"px\",myCanvas.parentNode.parentNode.style.width=bubbleWidth+\"px\",instance.data.fabricCanvas.setDimensions({width:bubbleWidth,height:instance.data.aspectRatio*bubbleWidth}),instance.data.GetCanvasAtResoution(bubbleWidth*instance.data.widthRatio)}else instance.data.fabricCanvas.setDimensions({width:bubbleWidth,height:bubbleHeight});instance.data.fabricCanvas.renderAll(),instance.data.oldBubbleWidth=bubbleWidth,instance.publishState(\"current_canvas_height\",instance.data.fabricCanvas.height),instance.publishState(\"current_canvas_width\",instance.data.fabricCanvas.width)}instance.data.updateFuncFirstTime=!0,instance.data.uniqueCanvasId=\"fabric\"+Math.floor(1e5*Math.random()).toString(),instance.data.myCanvas='<canvas id=\"thiscanvas'+instance.data.uniqueCanvasId+'\" width=\"400\" height=\"400\"></canvas>',instance.canvas.append(instance.data.myCanvas),instance.publishState(\"fabric_canvas_html_element_id\",\"thiscanvas\"+instance.data.uniqueCanvasId),instance.data.fabricCanvas=new fabric.Canvas(\"thiscanvas\"+instance.data.uniqueCanvasId,{fireRightClick:!0,stopContextMenu:!0,freeDrawingCursor:\"none\"}),instance.data.fabricCanvas.preserveObjectStacking=!0,instance.data.updateSelectedElementsAdvancedLine=updateSelectedElementsAdvancedLine,instance.data.makeCircle=makeCircle,instance.data.makeLine=makeLine,instance.data.undoArray=[],instance.data.redoArray=[],instance.data.resetUndoRedoArrays=resetUndoRedoArrays,instance.data.updateUndoRedoArray=updateUndoRedoArray,instance.data.undo=undo,instance.data.redo=redo,instance.data.setCanvasDimensions=setCanvasDimensions,instance.data.uploadContentCallback=uploadContentCallback,instance.data.uploadContentCallback2=uploadContentCallback2,instance.data.saveImage=saveImage,instance.data.clearImageURL=clearImageURL,instance.data.serializeCanvas=serializeCanvas,instance.data.GetCanvasAtResoution=GetCanvasAtResoution,instance.data.updateBubbleElement=updateBubbleElement;var selectObject=function(ObjectName){instance.data.fabricCanvas.getObjects().forEach((function(o){o.id===ObjectName&&instance.data.fabricCanvas.setActiveObject(o)}))};function updateSelectedElementStates(selectedObjects){if(selectedObjects){if(\"rect\"!=selectedObjects.get(\"type\")&&\"triangle\"!=selectedObjects.get(\"type\")&&\"ellipse\"!=selectedObjects.get(\"type\")&&\"line\"!=selectedObjects.get(\"type\")||(instance.publishState(\"selected_shape_type\",selectedObjects.get(\"type\")),instance.publishState(\"selected_shape_fill_color\",selectedObjects.get(\"fill\")),instance.publishState(\"selected_shape_outline_color\",selectedObjects.get(\"stroke\")),instance.publishState(\"selected_shape_outline_width\",selectedObjects.get(\"strokeWidth\")),instance.publishState(\"selected_text_font_family\",null),instance.publishState(\"selected_text_font_color\",null),instance.publishState(\"selected_text_font_size\",null),instance.publishState(\"selected_text_text_value\",null),instance.publishState(\"selected_text_bold\",null),instance.publishState(\"selected_text_italic\",null),instance.publishState(\"selected_text_underline\",null),instance.publishState(\"selected_text_alignment\",null),instance.publishState(\"selected_drawing_color\",null),instance.publishState(\"selected_drawing_stroke_width\",null),instance.publishState(\"selected_element_type\",\"shape\")),\"path\"==selectedObjects.get(\"type\")&&(instance.publishState(\"selected_drawing_color\",selectedObjects.get(\"stroke\")),instance.publishState(\"selected_drawing_stroke_width\",selectedObjects.get(\"strokeWidth\")),instance.publishState(\"selected_text_font_family\",null),instance.publishState(\"selected_text_font_color\",null),instance.publishState(\"selected_text_font_size\",null),instance.publishState(\"selected_text_text_value\",null),instance.publishState(\"selected_text_bold\",null),instance.publishState(\"selected_text_italic\",null),instance.publishState(\"selected_text_underline\",null),instance.publishState(\"selected_text_alignment\",null),instance.publishState(\"selected_shape_t
182ype\",null),instance.publishState(\"selected_shape_fill_color\",null),instance.publishState(\"selected_shape_outline_color\",null),instance.publishState(\"selected_shape_outline_width\",null),instance.publishState(\"selected_element_type\",\"drawing\")),\"textbox\"==selectedObjects.get(\"type\")||\"i-text\"==selectedObjects.get(\"type\")){instance.publishState(\"selected_text_font_family\",selectedObjects.get(\"fontFamily\")),instance.publishState(\"selected_text_font_color\",selectedObjects.get(\"fill\")),instance.publishState(\"selected_text_font_size\",selectedObjects.get(\"fontSize\")),instance.publishState(\"selected_text_text_value\",selectedObjects.get(\"text\")),instance.publishState(\"selected_text_bold\",selectedObjects.get(\"fontWeight\")),instance.publishState(\"selected_text_italic\",selectedObjects.get(\"fontStyle\")),instance.publishState(\"selected_text_underline\",selectedObjects.get(\"underline\")),instance.publishState(\"selected_text_alignment\",selectedObjects.get(\"textAlign\"));const shadow=selectedObjects.get(\"shadow\");shadow?(instance.publishState(\"selected_text_shadow_color\",shadow.color),instance.publishState(\"selected_text_shadow_radius\",shadow.blur),instance.publishState(\"selected_text_shadow_x_offset\",shadow.offsetX),instance.publishState(\"selected_text_shadow_y_offset\",shadow.offsetY)):(instance.publishState(\"selected_text_shadow_color\",null),instance.publishState(\"selected_text_shadow_radius\",null),instance.publishState(\"selected_text_shadow_x_offset\",null),instance.publishState(\"selected_text_shadow_y_offset\",null)),instance.publishState(\"selected_text_outline_color\",selectedObjects.get(\"stroke\")),instance.publishState(\"selected_text_outline_width\",selectedObjects.get(\"strokeWidth\")),instance.publishState(\"selected_drawing_color\",null),instance.publishState(\"selected_drawing_stroke_width\",null),instance.publishState(\"selected_shape_type\",null),instance.publishState(\"selected_shape_fill_color\",null),instance.publishState(\"selected_shape_outline_color\",null),instance.publishState(\"selected_shape_outline_width\",null),instance.publishState(\"selected_element_type\",\"text\")}\"image\"==selectedObjects.get(\"type\")&&instance.publishState(\"selected_element_type\",\"image\"),null==selectedObjects._objects&&instance.publishState(\"selected_element_rotation\",selectedObjects.angle)}}function clearControlMenu(){$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"none\",left:-200,top:-200})}function updateSelectedObject(selectingShapeViaWorkflow){let objectIsSelected;if(instance.data.selectedObject){if(objectIsSelected=!0,document.getElementById(instance.data.controlMenuHTMLid)){var controlMenu=document.getElementById(instance.data.controlMenuHTMLid);let mainCanvasElement;controlMenu.style.display=\"none\",document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId).parentNode.appendChild(controlMenu)}}else objectIsSelected=!1,instance.publishState(\"selected_element_type\",\"\"),instance.publishState(\"selected_drawing_color\",null),instance.publishState(\"selected_drawing_stroke_width\",null),instance.publishState(\"selected_shape_type\",null),instance.publishState(\"selected_shape_fill_color\",null),instance.publishState(\"selected_shape_outline_color\",null),instance.publishState(\"selected_shape_outline_width\",null),instance.publishState(\"selected_text_font_family\",null),instance.publishState(\"selected_text_font_color\",null),instance.publishState(\"selected_text_font_size\",null),instance.publishState(\"selected_text_text_value\",null),instance.publishState(\"selected_text_bold\",null),instance.publishState(\"selected_text_italic\",null),instance.publishState(\"selected_text_underline\",null),instance.publishState(\"selected_text_alignment\",null),instance.publishState(\"selected_shape_type\",null),instance.publishState(\"selected_shape_fill_color\",null),instance.publishState(\"selected_shape_outline_color\",null),instance.publishState(\"selected_shape_outline_width\",null),instance.publishState(\"selected_elements_list\",null),instance.publishState(\"selected_elements_x_locations\",null),instance.publishState(\"selected_elements_y_locations\",null),setTimeout(clearControlMenu,120);instance.publishState(\"objectIsSelected\",objectIsSelected);let selectedObjects=instance.data.fabricCanvas.getActiveObject(),selected_ids=[],selected_widths=[],selected_heights=[],selected_x_locations=[],selected_y_locations=[];if(null!=selectedObjects){if(!selectedObjects.aCoords)return;if(null==selectedObjects._objects||selectingShapeViaWorkflow)selected_ids.push(selectedObjects.bubble_id),selected_widths.push(selectedObjects.width*selectedObjects.scaleX),selected_heights.push(selectedObjects.height*selectedObjects.scaleY),selected_x_locations.push(selectedObjects.aCoords.tl.x),selected_y_locations.push(selectedObjects.aCoords.tl.y),instance.publishState(\"selected_elements_list\",selected_ids),instance.publishState(\"selected_elements_width_list\",selected_widths),instance.publishState(\"selected_elements_he
182ight_list\",selected_heights),instance.publishState(\"selected_elements_x_locations\",selected_x_locations),instance.publishState(\"selected_elements_y_locations\",selected_y_locations),$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"block\",position:\"absolute\",left:selectedObjects.aCoords.tr.x+instance.data.controlMenuXOffset,top:selectedObjects.aCoords.tr.y+instance.data.controlMenuYOffset,zIndex:1e16}),instance.data.updateSelectedElementStates(selectedObjects);else{let xTopRightLocations=[];for(let i=0;i<selectedObjects._objects.length;i++)selected_ids.push(selectedObjects._objects[i].bubble_id),selected_widths.push(selectedObjects._objects[i].width*selectedObjects._objects[i].scaleX),selected_heights.push(selectedObjects._objects[i].height*selectedObjects._objects[i].scaleY),selected_x_locations.push(selectedObjects._objects[i].aCoords.tl.x+selectedObjects.translateX),selected_y_locations.push(selectedObjects._objects[i].aCoords.tl.y+selectedObjects.translateY),xTopRightLocations.push(selectedObjects._objects[i].aCoords.tl.x+selectedObjects.translateX);instance.publishState(\"selected_elements_list\",selected_ids),instance.publishState(\"selected_elements_width_list\",selected_widths),instance.publishState(\"selected_elements_height_list\",selected_heights),instance.publishState(\"selected_elements_x_locations\",selected_x_locations),instance.publishState(\"selected_elements_y_locations\",selected_y_locations),xTopRightLocations[0]?$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"block\",position:\"absolute\",left:Math.max(xTopRightLocations)+instance.data.controlMenuXOffset,top:Math.max(selected_y_locations)+instance.data.controlMenuYOffset,zIndex:1e16}
182):$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"block\",position:\"absolute\",left:selectedObjects.aCoords.tr.x+instance.data.controlMenuXOffset,top:selectedObjects.aCoords.tr.y+instance.data.controlMenuYOffset,zIndex:1e16}),instance.data.updateSelectedElementStates(selectedObjects)}}}function createShape(x,y,shapeHeight,shapeWidth,color,shape,stroke,stroke_width,corner_roundness,shape_unique_id){let shapeId=Math.floor(1e5*Math.random()).toString();if(\"Rectangle\"==shape){let rect=new fabric.Rect({id:shapeId,width:shapeWidth,height:shapeHeight,fill:color,left:x,top:y,stroke:stroke,strokeWidth:stroke_width,rx:corner_roundness,ry:corner_roundness,strokeUniform:!0});rect.bubble_id=shape_unique_id||\"shape_unique_id_\"+Math.floor(1e6*Math.random()).toString(),instance.data.fabricCanvas.add(rect)}else if(\"Ellipse\"==shape){let ellipse=new fabric.Ellipse({id:shapeId,rx:shapeWidth,ry:shapeHeight,fill:color,left:x,top:y,stroke:stroke,strokeWidth:stroke_width,strokeUniform:!0});ellipse.bubble_id=shape_unique_id||\"shape_unique_id_\"+Math.floor(1e6*Math.random()).toString(),instance.data.fabricCanvas.add(ellipse)}else if(\"Triangle\"==shape){let triangle=new fabric.Triangle({id:shapeId,width:shapeWidth,height:shapeHeight,fill:color,left:x,top:y,stroke:stroke,strokeWidth:stroke_width,strokeUniform:!0});triangle.bubble_id=shape_unique_id||\"shape_unique_id_\"+Math.floor(1e6*Math.random()).toString(),instance.data.fabricCanvas.add(triangle)}else if(\"Line\"==shape){instance.data.mouseRightToLeft&&!instance.data.bottomToTop&&(shapeWidth*=-1),instance.data.mouseBottomToTop&&!instance.data.mouseRightToLeft&&(shapeWidth*=-1),instance.data.mouseBottomToTop&&instance.data.mouseRightToLeft&&(shapeWidth*=-1);let line=new fabric.Line([0,0,shapeWidth,shapeHeight],{id:shapeId,left:x,top:y,stroke:color,strokeWidth:stroke_width,strokeUniform:!0});line.bubble_id=shape_unique_id||\"shape_unique_id_\"+Math.floor(1e6*Math.random()).toString(),instance.data.fabricCanvas.add(line)}instance.data.fabricCanvas.forEachObject((function(o){o.selectable=instance.data.selectorIsOn})),instance.data.selectorIsOn?instance.data.fabricCanvas.hoverCursor=\"move\":instance.data.fabricCanvas.hoverCursor=\"default\",selectObject(shapeId)}instance.data.selectObject=selectObject,fabric.Canvas.prototype.getItem=function(id){for(var object=null,objects=this.getObjects(),i=0,len=this.size();i<len;i++)if(objects[i].id&&objects[i].id===id){object=objects[i];break}return object},instance.data.updateSelectedElementStates=updateSelectedElementStates,instance.data.fabricCanvas.on(\"text:changed\",(function(e){instance.publishState(\"selected_text_text_value\",e.target.text)})),instance.data.updateSelectedObject=updateSelectedObject,instance.data.createShape=createShape;var originalRender=fabric.Textbox.prototype._render;fabric.Textbox.prototype._render=function(ctx){if(originalRender.call(this,ctx),!this.active&&this.showTextBoxBorder){var w=this.width+2*instance.data.text_padding,h=this.height+2*instance.data.text_padding,x=-(this.width+2*instance.data.text_padding)/2,y=-(this.height+2*instance.data.text_padding)/2;ctx.beginPath(),ctx.moveTo(x,y),ctx.lineTo(x+w,y),ctx.lineTo(x+w,y+h),ctx.lineTo(x,y+h),ctx.lineTo(x,y),ctx.closePath();var stroke=ctx.strokeStyle;ctx.strokeStyle=this.textboxBorderColor,ctx.stroke(),ctx.strokeStyle=stroke}},fabric.Textbox.prototype.cacheProperties=fabric.Textbox.prototype.cacheProperties.concat(\"active\");var originalRender=fabric.IText.prototype._render;function createText(text,x,y,size,color,height,width,enterEditMode,highlightText,wrappable,borderColor,borderPadding,text_unique_id,selectable,bold,italic,underline,horizontalAlign,text_shadow_color,text_shadow_radius,text_shadow_y_offset,text_shadow_x_offset,text_outline_color,text_outline_width){let textId=Math.floor(1e5*Math.random()).toString(),fontStyle=\"normal\",textObject;\"italic\"==italic&&(fontStyle=\"italic\"),textObject=wrappable?new fabric.Textbox(text,{id:textId,left:x,top:y,fontSize:size,fill:color,fontFamily:instance.data.myFont,width:width,height:height,showTextBoxBorder:!0,textboxBorderColor:borderColor,shadow:{color:text_shadow_color,blur:text_shadow_radius,offsetX:text_shadow_x_offset,offsetY:text_shadow_y_offset},stroke:text_outline_color,strokeWidth:text_outline_width,padding:borderPadding,hasControls:!0,strokeUniform:!0,selectable:selectable,fontWeight:bold,fontStyle:fontStyle,underline:underline,textAlign:horizontalAlign,editable:selectable}):new fabric.IText(text,{id:textId,left:x,top:y,fontSize:size,shadow:{color:text_shadow_color,blur:text_shadow_radius,offsetX:text_shadow_x_offset,offsetY:text_shadow_y_offset},stroke:text_outline_color,strokeWidth:text_outline_width,fill:color,fontFamily:instance.data.myFont,width:width,height:height,textboxBorderColor:borderColor,padding:borderPadding,strokeUniform:!0,selectable:selectable,fontWeight:bold,fontStyle:fontStyle,underline:underline,textAlign:horizontalAlign}),textObject.bubble_id=text_unique_id||\"text_unique_id_\"+Math.floor(1e6*Math.random()).toString(),instance.data.fabricCanvas.add(textOb
182ject),selectable&&(instance.data.fabricCanvas.forEachObject((function(o){o.selectable=instance.data.selectorIsOn})),instance.data.selectorIsOn?instance.data.fabricCanvas.hoverCursor=\"move\":instance.data.fabricCanvas.hoverCursor=\"default\",selectObject(textId)),enterEditMode&&(textObject.enterEditing(),textObject.setSelectionStart(textObject.text.length),textObject.setSelectionEnd(textObject.text.length)),highlightText&&textObject.selectAll()}function captureMouseDownCoordinates(){instance.data.mouseDownX=instance.data.fabricCanvas.getPointer().x,instance.data.mouseDownY=instance.data.fabricCanvas.getPointer().y}function createShapeOnMouseUp(){instance.data.mouseUpX=instance.data.fabricCanvas.getPointer().x,instance.data.mouseUpY=instance.data.fabricCanvas.getPointer().y;let width=Math.round(Math.abs(instance.data.mouseUpX-instance.data.mouseDownX)),height=Math.round(Math.abs(instance.data.mouseUpY-instance.data.mouseDownY)),xCoord,yCoord;width<=1&&height<=1?selectObject():(instance.data.mouseRightToLeft=!1,instance.data.mouseBottomToTop=!1,instance.data.mouseDownX<instance.data.mouseUpX?xCoord=instance.data.mouseDownX:(xCoord=instance.data.mouseUpX,instance.data.mouseRightToLeft=!0),instance.data.mouseDownY<instance.data.mouseUpY?yCoord=instance.data.mouseDownY:(yCoord=instance.data.mouseUpY,instance.data.mouseBottomToTop=!0),\"Ellipse\"==instance.data.drawShapeType&&(height/=2,width/=2),(width>1||height>1)&&(instance.data.createShape(xCoord,yCoord,height,width,instance.data.drawShapeColor,instance.data.drawShapeType,instance.data.drawShapeColorOutline,instance.data.drawShapeOutlineWidth,instance.data.shapeCornerRoundness),instance.triggerEvent(\"shape_added\",(function(err){}))))}function createTextOnMouseUp(defaultText,textSize,textColor,horizontalAlign){instance.data.mouseUpX=instance.data.fabricCanvas.getPointer().x,instance.data.mouseUpY=instance.data.fabricCanvas.getPointer().y;let width=Math.round(Math.abs(instance.data.mouseUpX-instance.data.mouseDownX)),height=Math.round(Math.abs(instance.data.mouseUpY-instance.data.mouseDownY)),xCoord,yCoord;instance.data.mouseRightToLeft=!1,instance.data.mouseBottomToTop=!1,instance.data.mouseDownX<instance.data.mouseUpX?xCoord=instance.data.mouseDownX:(xCoord=instance.data.mouseUpX,instance.data.mouseRightToLeft=!0),instance.data.mouseDownY<instance.data.mouseUpY?yCoord=instance.data.mouseDownY:(yCoord=instance.data.mouseUpY,instance.data.mouseBottomToTop=!0),(height>1||width>1)&&(instance.data.createText(instance.data.defaultText,xCoord,yCoord,instance.data.textSize,instance.data.textColor,height,width,instance.data.enter_editing_mode,instance.data.highlight_text,instance.data.wrappable_text,instance.data.textbox_border_color,instance.data.text_padding,null,!0,instance.data.bold,instance.data.italic,instance.data.underline,horizontalAlign),instance.triggerEvent(\"text_added\",(function(err){})))}function snapToLocation(bufferDistance,shapeToSnap,allCornersList,pointer){if(allCornersList)for(let i=0;i<allCornersList.length;i++){let distance=Math.sqrt(Math.abs(allCornersList[i].left-pointer.x)*Math.abs(allCornersList[i].left-pointer.x)+Math.abs(allCornersList[i].top-pointer.y)*Math.abs(allCornersList[i].top-pointer.y));if(shapeToSnap!==allCornersList[i]){if(distance<35){if(null==shapeToSnap){let coords;return{x:allCornersList[i].left,y:allCornersList[i].top}}shapeToSnap.set({left:allCornersList[i].left,top:allCornersList[i].top});break}shapeToSnap.set({left:pointer.x,top:pointer.y})}}else shapeToSnap.set({left:pointer.x,top:pointer.y})}function setCursorMode(){if(\"Free Draw/Paint\"==instance.data.cursorMode)instance.data.fabricCanvas.isDrawingMode=!0,instance.data.drawShapeModeOn=!1,instance.data.fabricCanvas.freeDrawingBrush.color=instance.data.strokeColor,instance.data.fabricCanvas.freeDrawingBrush.width=instance.data.strokeWidth,instance.data.fabricCanvas.selection=instance.data.selectorIsOn,instance.data.addTextMode=!1,instance.data.isEraserMode=!1;else if(\"Draw Shape\"==instance.data.cursorMode)instance.data.fabricCanvas.isDrawingMode=!1,instance.data.drawShapeModeOn=!0,instance.data.addTextMode=!1,instance.data.fabricCanvas.selection=instance.data.selectorIsOn,instance.data.isEraserMode=!1;else if(\"Select Elements\"==instance.data.cursorMode){if(instance.data.drawShapeModeOn=!1,instance.data.fabricCanvas.isDrawingMode=!1,instance.data.addTextMode=!1,instance.data.isEraserMode=!1,instance.data.fabricCanvas.selection=instance.data.selectorIsOn,instance.data.fabricCanvas.forEachObject((function(o){o.selectable=instance.data.selectorIsOn,instance.data.selectorIsOn?instance.data.fabricCanvas.hoverCurs
182or=\"move\":instance.data.fabricCanvas.hoverCursor=\"default\"})),instance.data.cornerCircleList)for(let i=0;i<instance.data.cornerCircleList.length;i++)instance.data.cornerCircleList[i].selectable=!0,instance.data.cornerCircleList[i].hoverCursor=\"grab\";var advancedLineObjects=instance.data.fabricCanvas.getObjects().filter((function(obj){return\"advancedLine\"===obj.uniqueID}));for(let i=0;i<advancedLineObjects.length;i++)advancedLineObjects[i].selectable=!1;if(advancedLineObjects.length>0){var activeSelection=new fabric.ActiveSelection(advancedLineObjects,{canvas:instance.data.fabricCanvas});instance.data.fabricCanvas.setActiveObject(activeSelection)}instance.data.fabricCanvas.discardActiveObject().renderAll(),instance.data.fabricCanvas.off(\"mouse:move\"),instance.data.fabricCanvas.renderAll()}else if(\"Add Text\"==instance.data.cursorMode)instance.data.addTextMode=!0,instance.data.drawShapeModeOn=!1,instance.data.fabricCanvas.isDrawingMode=!1,instance.data.fabricCanvas.selection=instance.data.selectorIsOn,instance.data.isEraserMode=!1;else if(\"Eraser\"==instance.data.cursorMode)instance.data.addTextMode=!1,instance.data.drawShapeModeOn=!1,instance.data.fabricCanvas.isDrawingMode=!1,instance.data.fabricCanvas.selection=!1,instance.data.isEraserMode=!0;else if(\"Advanced Line\"==instance.data.cursorMode){if(fabric.Object.prototype.originX=fabric.Object.prototype.originY=\"center\",null!=instance.data.cornerCircleList)for(let i=0;i<instance.data.cornerCircleList.length;i++);instance.data.fabricCanvas.renderAll(),instance.data.fabricCanvas.isDrawingMode=!1,instance.data.drawShapeModeOn=!1,instance.data.addTextMode=!1,instance.data.fabricCanvas.selection=!1,instance.data.isEraserMode=!1,instance.data.advancedLineMode=!0,instance.data.lineCursorCircle=new fabric.Circle({radius:10,fill:\"gray\",left:0,top:0,uniqueID:\"lineCursorCircle\",selectable:!1,hoverCursor:\"default\"}),instance.data.fabricCanvas.upperCanvasEl.addEventListener(\"mouseenter\",(function(){const lineCursorCircles=undefined;instance.data.fabricCanvas.getObjects().filter((obj=>\"lineCursorCircle\"===obj.uniqueID)).forEach((obj=>{instance.data.fabricCanvas.remove(obj)})),instance.data.currentlyDrawingLine||\"Advanced Line\"!=instance.data.cursorMode||instance.data.fabricCanvas._objects.includes(instance.data.lineCursorCircle)||(instance.data.cursorCircleAdded=!0,instance.data.fabricCanvas.add(instance.data.lineCursorCircle))})),instance.data.fabricCanvas.upperCanvasEl.addEventListener(\"mouseleave\",(function(){const lineCursorCircles=undefined;instance.data.fabricCanvas.getObjects().filter((obj=>\"lineCursorCircle\"===obj.uniqueID)).forEach((obj=>{instance.data.fabricCanvas.remove(obj)})),instance.data.fabricCanvas.renderAll(),instance.data.cursorCircleAdded=!1})),instance.data.fabricCanvas.on(\"mouse:move\",(function(event){const pointer=instance.data.fabricCanvas.getPointer(event.e);snapToLocation(35,instance.data.lineCursorCircle,instance.data.cornerCircleList,pointer),instance.data.currentlyDrawingLine&&instance.data.tempLine.set({x2:instance.data.lineCursorCircle.left,y2:instance.data.lineCursorCircle.top}),instance.data.fabricCanvas.renderAll()})),instance.data.fabricCanvas.on(\"object:moving\",(function(e){var p=e.target;console.log(instance.data.cornerCircleList),snapToLocation(35,e.target,instance.data.cornerCircleList,e.pointer),p.line1&&p.line1.set({x2:p.left,y2:p.top}),p.line2&&p.line2.set({x1:p.left,y1:p.top}),p.line1&&p.line1.set({stroke:\"red\",hoverCursor:\"grab\"}),p.line2&&p.line2.set({stroke:\"red\",hoverCursor:\"grab\"}),p.line1?instance.data.selectedLine=p.line1:p.line2&&(instance.data.selectedLine=p.line2),updateSelectedAdvancedLine(instance.data.selectedLine);var advancedLineObjects=instance.data.fabricCanvas.getObjects().filter((function(obj){return\"advancedLine\"===obj.uniqueID}));for(let i=0;i<advancedLineObjects.length;i++)advancedLineObjects[i].selectable=!1;if(advancedLineObjects.length>0){var activeSelection=new fabric.ActiveSelection(advancedLineObjects,{canvas:instance.data.fabricCanvas});instance.data.fabricCanvas.setActiveObject(activeSelection)}instance.data.fabricCanvas.discardActiveObject().renderAll(),instance.data.fabricCanvas.renderAll()}))}}function deleteElements(){let selectedObjects=instance.data.fabricCanvas.getActiveObjects();for(;selectedObjects.length>0;)instance.data.fabricCanvas.remove(selectedObjects[0]),selectedObjects.shift();instance.data.fabricCanvas.discardActiveObject(),instance.data.updateUndoRedoArray(),instance.triggerEvent(\"element_deleted\",(function(err){}))}fabric.IText.prototype._render=function(ctx){if(originalRender.call(this,ctx),!this.active&&this.showTextBoxBorder){var w=this.width+2*instance.data.text_padding,h=this.height+2*instance.data.text_padding,x=-(this.width+2*instance.data.text_padding)/2,y=-(this.height+2*instance.data.text_padding)/2;ctx.beginPath(),ctx.moveTo(x,y),ctx.lineTo(x+w,y),ctx.lineTo(x+w,y+h),ctx.lineTo(x,y+h),ctx.lineTo(x,y),ctx.closePath();var stroke=ctx.strokeStyle;ctx.strokeStyle=this.textboxBorderColor,ctx.stroke(),ctx.strokeStyle=stroke}},fabric.IText.prototype.cacheProperties=fabric.IText.prototype.cacheProperties.concat(\"active\"),instance.data.createText=createText,instance.data.captureMouseDownCoordinates=captureMouseDownCoordinates,instance.data.createShapeOnMouseUp=createShapeOnMouseUp,instance.data.fabricCanvas.on(\"mouse:down\",(function(options){options.target&&instance.triggerEvent(\"element_clicked\",(function(err){}))})),instance.data.createTextOnMouseUp=createTextOnMouseUp,instance.data.setCursorMode=setCursorMode,instance.data.deleteElements=deleteElements;let _clipboard=null;const hiddenInput=document.createElement(\"textarea\");function copy(){const activeObject=instance.data.fabricCanvas.getActiveObject();activeObject&&(activeObject.clone((function(cloned){_clipboard=cloned,instance.data.lastFabricCopyTime=Date.now()})),\"image\"===activeObject.type?(async()=>{try{const dataURL=activeObject.toDataURL(),response=await fetch(dataURL),blob=await response.blob(),clipboardItem=new ClipboardItem({\"image/png\":blob});await navigator.clipboard.write([clipboardItem]),console.log(\"Image copied to clipboard successfully!\")}catch(err){console.error(\"Failed to copy image to clipboard:\",err)}})():\"i-text\"===activeObject.type||\"textbox\"===activeObject.type?(async()=>{try{await navigator.clipboard.writeText(activeObject.text),console.log(\"Text copied to clipboard:\",activeObject.text)}catch(err){console.error(\"Failed to copy text to clipboard:\",err)}})():(async()=>{try{const objectData=JSON.stringify(activeObject.toObject());await navigator.clipboard.writeText(objectData),console.log(\"Fabric.js object c
182opied as JSON:\",objectData),instance.data.lastCopiedFabricJson=objectData}catch(err){console.error(\"Failed to copy Fabric.js object to clipboard:\",err)}})())}function pasteFabricObject(){console.log(\"PASTING FABRIC OBJECT\"),console.log(instance.data.justPasted),instance.data.justPasted?console.log(\"EXITING\"):(_clipboard?_clipboard.clone((function(clonedObj){clonedObj.set({left:clonedObj.left+10,top:clonedObj.top+10,evented:!0}),\"activeSelection\"===clonedObj.type?(clonedObj.canvas=instance.data.fabricCanvas,clonedObj.forEachObject((function(obj){instance.data.fabricCanvas.add(obj)})),clonedObj.setCoords()):instance.data.fabricCanvas.add(clonedObj),_clipboard=clonedObj,instance.data.fabricCanvas.setActiveObject(clonedObj),instance.data.fabricCanvas.requestRenderAll()})):console.warn(\"No Fabric.js object to paste.\"),instance.data.justPasted=!0,console.log(instance.data.justPasted),setTimeout((()=>{instance.data.justPasted=!1}),250))}async function paste(){try{const now=Date.now(),fabricCopyIsRecent=(instance.data.lastFabricCopyTime||0)>now-1500,clipboardCopyIsRecent=!0;if(console.log(\"FabricRecent?\",fabricCopyIsRecent),console.log(\"ClipboardRecent?\",clipboardCopyIsRecent),clipboardCopyIsRecent&&(!fabricCopyIsRecent||instance.data.lastClipboardCopyTime>instance.data.lastFabricCopyTime)){console.log(\"Pasting from clipboard.\");try{const clipboardItems=await navigator.clipboard.read();let clipboardPasted=!1;for(const item of clipboardItems)if(console.log(\"PASTING IMAGE......\"),item.types.includes(\"image/png\")||item.types.includes(\"image/jpeg\")){if(console.log(\"SHOULD I EXIT?\",instance.data.justPasted),instance.data.justPasted)break;instance.data.justPasted=!0,setTimeout((()=>{instance.data.justPasted=!1}),500);const imageBlob=await item.getType(item.types.includes(\"image/png\")?\"image/png\":\"image/jpeg\"),imageUrl=URL.createObjectURL(imageBlob);fabric.Image.fromURL(imageUrl,(function(img){img.set({left:50,top:50,selectable:!0}),instance.data.fabricCanvas.add(img),instance.data.fabricCanvas.setActiveObject(img),instance.data.fabricCanvas.requestRenderAll()})),console.log(\"Pasted IMAGE from clipboard.\"),clipboardPasted=!0;break}if(!clipboardPasted){const clipboardText=await navigator.clipboard.readText();if(fabricCopyIsRecent){if(instance.data.justPasted)return;return instance.data.pasteFabricObject(),!0}try{const parsedObject=JSON.parse(clipboardText);if(parsedObject.type){if(instance.data.justPasted)return;console.log(\"Detected Fabric.js JSON object, recreating...\"),fabric.util.enlivenObjects([parsedObject],(function(objects){objects.forEach((obj=>{obj.set({left:50,top:50,selectable:!0}),instance.data.fabricCanvas.add(obj),instance.data.fabricCanvas.setActiveObject(obj)})),instance.data.fabricCanvas.renderAll()})),clipboardPasted=!0}}catch(err){if(instance.data.justPasted)return;console.log(\"Pasting plain text:\",clipboardText);const textObj=new fabric.IText(clipboardText,{left:50,top:50,fontSize:instance.data.textSize||16,fill:instance.data.textColor||\"#000000\",fontFamily:instance.data.myFont||\"Arial\",selectable:!0,editable:instance.data.enter_editing_mode||!1,width:200,padding:instance.data.text_padding||5,textAlign:instance.data.horizontalAlign||\"left\",fontWeight:instance.data.bold||\"normal\",fontStyle:instance.data.italic||\"normal\",underline:instance.data.underline||!1,stroke:instance.data.text_outline_color||null,strokeWidth:instance.data.text_outline_width||0,showTextBoxBorder:instance.data.wrappable_text||!1,textboxBorderColor:instance.data.textbox_border_color||\"#000000\"});instance.data.fabricCanvas.add(textObj),instance.data.fabricCanvas.setActiveObject(textObj),instance.data.fabricCanvas.requestRenderAll(),clipboardPasted=!0}}console.log(\"GOT DOWN HERE\"),instance.data.justPasted=!0,console.log(instance.data.justPasted),setTimeout((()=>{instance.data.justPasted=!1}),250),!clipboardPasted&&_clipboard&&(console.log(\"Clipboard empty, pasting Fabric.js object.\"),instance.data.pasteFabricObject())}catch(err){console.error(\"Clipboard access failed, using Fabric.js backup.\"),_clipboard&&instance.data.pasteFabricObject()}return}console.log(\"Pasting Fabric.js object (recent copy).\"),instance.data.pasteFabricObject()}catch(err){console.error(\"Paste failed:\",err)}}function moveElement(direction){let movementMagnitude=instance.data.numPixelsMovement,leftDelta=0,topDelta=0;37==direction&&(leftDelta=-1*movementMagnitude),38==direction&&(topDelta=-1*movementMagnitude),39==direction&&(leftDelta=movementMagnitude),40==direction&&(topDelta=movementMagnitude);let selectedObjects=instance.data.fabricCanvas.getActiveObjects();for(;selectedObjects.length>0;)selectedObjects[0].set({left:selectedObjects[0].left+leftDelta,top:selectedObjects[0].top+topDelta}),selectedObjects.shift();instance.data.fabricCanvas.renderAll(),instance.data.updateUndoRedoArray()}function getAllCorners(){}function loadSerializedCanvas(){instance.data.checkToLoadSerializedCanvas=setInterval((function(){$(\"#thiscanvas\"+instance.data.uniqueCanvasId).length&&(instance.data.fabricCanvas.loadFromJSON(instance.data.seri
182alizedCanvas),clearInterval(instance.data.checkToLoadSerializedCanvas),instance.data.fabricCanvas.add(instance.data.erasercursor),instance.data.fabricCanvas.add(instance.data.mousecursor))}),500)}function forceUpdate(){document.getElementById(instance.data.context_menu_html_id)&&(document.getElementById(instance.data.context_menu_html_id).style.display=\"none\")}hiddenInput.style.position=\"absolute\",hiddenInput.style.left=\"-9999px\",hiddenInput.style.top=\"0\",hiddenInput.style.opacity=\"0\",document.body.appendChild(hiddenInput),instance.data.copy=copy,document.addEventListener(\"copy\",(async function(event){const scrollX=window.scrollX,scrollY=window.scrollY;hiddenInput.setAttribute(\"readonly\",!0),hiddenInput.setAttribute(\"tabindex\",\"-1\"),hiddenInput.focus({preventScroll:!0}),hiddenInput.select(),window.scrollTo(scrollX,scrollY),setTimeout((async()=>{try{const clipboardText=await navigator.clipboard.readText();instance.data.lastClipboardCopyTime=Date.now(),instance.data.lastClipboardText=clipboardText,console.log(\"Clipboard text copied:\",clipboardText)}catch(err){console.error(\"Clipboard access denied:\",err)}}),100)})),instance.data.pasteFabricObject=pasteFabricObject,instance.data.paste=paste,instance.data.moveElement=moveElement,instance.data.fabricCanvas.on(\"mouse:over\",(function(e){instance.data.mouseIsDown&&instance.data.isEraserMode&&(instance.data.fabricCanvas.remove(e.target),instance.data.fabricCanvas.renderAll(),instance.data.updateUndoRedoArray(),instance.triggerEvent(\"element_deleted\",(function(err){})))})),instance.data.allCorners=[],instance.data.fabricCanvas.on(\"mouse:down\",(function(options){if(\"Advanced Line\"==instance.data.cursorMode){const pointer=instance.data.fabricCanvas.getPointer(event.e);if(instance.data.placeholder=new fabric.Circle({left:pointer.x,top:pointer.y,radius:1}),snapToLocation(35,instance.data.placeholder,instance.data.cornerCircleList,pointer),instance.data.currentlyDrawingLine){let circle2=makeCircle(instance.data.placeholder.left,instance.data.placeholder.top,instance.data.tempLine,null,10,\"white\",\"gray\");instance.data.fabricCanvas.add(circle2),instance.data.currentlyDrawingLine=!1,instance.data.currentlyDrawingLine=!1,instance.data.fabricCanvas.add(instance.data.lineCursorCircle)}else{instance.data.tempLine=makeLine([instance.data.placeholder.left,instance.data.placeholder.top,instance.data.placeholder.left,instance.data.placeholder.top],\"black\",5),instance.data.fabricCanvas.add(instance.data.tempLine);let circle1=makeCircle(instance.data.placeholder.left,instance.data.placeholder.top,null,instance.data.tempLine,10,\"white\",\"gray\");instance.data.fabricCanvas.add(circle1),instance.data.currentlyDrawingLine=!0}instance.data.cornerCircleList=getObjectsByUniqueID(\"cornerCircle\"),instance.data.fabricCanvas.renderAll()}instance.data.controlMenuHTMLid&&$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"none\"}),instance.data.mouseIsDown=!0,instance.data.captureMouseDownCoordinates(),instance.data.fabricCanvas.getActiveObject()?instance.data.clickedAShape=!0:instance.data.clickedAShape=!1,document.onkeydown=function(e){8==e.keyCode&&(\"i-text\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&\"textbox\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")||0!=instance.data.fabricCanvas.getActiveObject().isEditing||1!=instance.data.deleteKeyOn?\"i-text\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&\"textbox\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&1==instance.data.deleteKeyOn&&instance.data.deleteElements():instance.data.deleteElements()),37!=e.keyCode&&38!=e.keyCode&&39!=e.keyCode&&40!=e.keyCode||instance.data.moveElement(e.keyCode)}})),instance.data.fabricCanvas.on(\"mouse:up\",(function(options){instance.data.mouseIsDown=!1,!instance.data.clickedAShape&&instance.data.drawShapeModeOn&&instance.data.createShapeOnMouseUp(),!instance.data.clickedAShape&&instance.data.addTextMode&&instance.data.createTextOnMouseUp(instance.data.defaultText,instance.data.textSize,instance.data.textColor,instance.data.horizontalTextAlign),instance.data.advancedLineMode&&console.log(\"Advanced Line Mode is on\"),instance.data.updateUndoRedoArray(),null!=instance.data.selectedObject&&(instance.data.fabricCanvas.selection||$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"block\",position:\"absolute\",left:instance.data.selectedObject.aCoords.tr.x+instance.data.controlMenuXOffset,top:instance.data.selectedObject.aCoords.tr.y+instance.data.controlMenuYOffset,zIndex:1e16}
182))})),instance.data.fabricCanvas.on(\"object:modified\",(function(e){if(!e.target._objects&&e.target.bubble_id&&e.target.bubble_id.includes(\"shape\")&&instance.triggerEvent(\"shape_modified\",(function(err){})),e.target._objects)for(let i=0;i<e.target._objects.length;i++)e.target.bubble_id&&e.target._objects[i].bubble_id.includes(\"shape\")&&instance.triggerEvent(\"shape_modified\",(function(err){}))})),instance.data.fabricCanvas.on(\"selection:created\",(function(e){})),instance.data.loadSerializedCanvas=loadSerializedCanvas,setTimeout(forceUpdate,500)}"},"update":{"fn":"function(instance,properties,context){instance.data.horizontalTextAlign=properties.horizontal_align_text,instance.data.selectedObject||instance.publishState(\"objectIsSelected\",!1),fabric.Object.prototype.set({borderColor:properties.controls_border_color,cornerColor:properties.controls_corner_color,cornerStyle:properties.controls_corner_style}),fabric.Object.prototype.transparentCorners=properties.controls_transparent_corners,$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"none\"}),instance.data.controlMenuXOffset=properties.control_menu_x_offset,instance.data.controlMenuYOffset=properties.control_menu_y_offset,instance.data.controlMenuHTMLid=properties.control_menu_html_id,instance.data.drawCursorColor=properties.cursor_mode_color,instance.data.drawCursorWidth=properties.paint_stroke_width;let shadow=new fabric.Shadow({color:\"rgba(0,0,0,0.2)\",blur:5});if(instance.data.mousecursor=new fabric.Circle({left:0,top:0,radius:instance.data.drawCursorWidth/2,fill:instance.data.drawCursorColor,originX:\"right\",originY:\"bottom\",shadow:shadow}),instance.data.fabricCanvas.add(instance.data.mousecursor),instance.data.fabricCanvas.bringToFront(instance.data.mousecursor),instance.data.erasercursor=new fabric.Rect({left:0,top:0,height:14,width:14,stroke:\"#808080\",strokeWidth:1,fill:\"#FFFFFF\",originX:\"right\",originY:\"bottom\"}),instance.data.fabricCanvas.add(instance.data.erasercursor),(!document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId)||document.getElementById(\"thiscanvas\"+instance.data.uniqueCanvasId).parentNode.childElementCount<2)&&(instance.data.fabricCanvas=new fabric.Canvas(\"thiscanvas\"+instance.data.uniqueCanvasId,{fireRightClick:!0,stopContextMenu:!0}),instance.data.fabricCanvas.on(\"mouse:down\",(function(options){instance.data.captureMouseDownCoordinates(),instance.data.fabricCanvas.getActiveObject()?instance.data.clickedAShape=!0:instance.data.clickedAShape=!1,document.onkeydown=function(e){8==e.keyCode&&(\"i-text\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&\"textbox\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")||0!=instance.data.fabricCanvas.getActiveObject().isEditing||1!=instance.data.deleteKeyOn?\"i-text\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&\"textbox\"!=instance.data.fabricCanvas.getActiveObject().get(\"type\")&&1==instance.data.deleteKeyOn&&instance.data.deleteElements():instance.data.deleteElements()),37!=e.keyCode&&38!=e.keyCode&&39!=e.keyCode&&40!=e.keyCode||instance.data.moveElement(e.keyCode)}})),instance.data.fabricCanvas.on(\"mouse:up\",(function(options){!instance.data.clickedAShape&&instance.data.drawShapeModeOn&&instance.data.createShapeOnMouseUp(),!instance.data.fabricCanvas.getActiveObject()&&instance.data.addTextMode&&instance.data.createTextOnMouseUp(instance.data.defaultText,instance.data.textSize,instance.data.textColor,properties.horizontal_align_text),instance.data.updateUndoRedoArray()}))),instance.data.fabricCanvas.preserveObjectStacking=!0,instance.data.fabricCanvas.on(\"selection:updated\",(function(){null!=instance.data.fabricCanvas.getActiveObject()?(instance.data.selectedObject=instance.data.fabricCanvas.getActiveObject(),instance.data.updateSelectedObject(),$(\"#\"+instance.data.controlMenuHTMLid).css({display:\"block\",position:\"absolute\",left:instance.data.selectedObject.aCoords.tr.x+instance.data.controlMenuXOffset,top:instance.data.selectedObject.aCoords.tr.y+instance.data.controlMenuYOffset,zIndex:1e16}
182)):console.log(\"TEST5\")})),instance.data.fabricCanvas.on(\"selection:created\",(function(){instance.data.selectedObject=instance.data.fabricCanvas.getActiveObject(),instance.data.updateSelectedObject()})),instance.data.fabricCanvas.on(\"selection:cleared\",(function(){instance.data.selectedObject=!1,instance.data.updateSelectedObject()})),instance.data.cursorMode=properties.cursor_mode,\"Draw Shape\"!=properties.cursor_mode_2&&\"Add Text\"!=properties.cursor_mode_2&&\"Select Elements\"!=properties.cursor_mode_2&&\"Free Draw/Paint\"!=properties.cursor_mode_2&&\"Advanced Line\"!=properties.cursor_mode_2||(instance.data.cursorMode=properties.cursor_mode_2),instance.data.drawShapeType=properties.draw_shape_type,instance.data.drawShapeColor=properties.shape_color,instance.data.drawShapeOutlineWidth=properties.shape_outline_width,instance.data.drawShapeColorOutline=properties.shape_color_stroke,instance.data.strokeColor=properties.cursor_mode_color,instance.data.strokeWidth=properties.paint_stroke_width,instance.data.selectorIsOn=properties.selector_on,instance.data.shapeCornerRoundness=properties.corner_roundness,instance.data.textColor=properties.text_color,instance.data.textSize=properties.text_size,instance.data.defaultText=properties.default_text,instance.data.highlight_text=properties.highlight_text,instance.data.enter_editing_mode=properties.enter_editing_mode,instance.data.wrappable_text=properties.wrappable,instance.data.textbox_border_color=properties.textbox_border_color,instance.data.text_padding=properties.text_padding,properties.bold?instance.data.bold=\"bold\":instance.data.bold=\"normal\",properties.italic?instance.data.fontStyle=\"italic\":instance.data.fontStyle=\"normal\",instance.data.underline=properties.underline,instance.data.setCursorMode(),instance.data.updateFuncFirstTime&&(instance.data.savedWidth=properties.bubble.width(),instance.data.updateFuncFirstTime=!1),instance.data.fixedAspectRatio=properties.fixed_aspect_ratio,instance.data.backgroundColor=properties.background_color,instance.data.fixedAspectRatio?instance.data.setCanvasDimensions(instance.data.savedWidth,instance.data.savedWidth*(1/instance.data.fixedAspectRatio),properties.fixed_aspect_ratio):instance.data.updateBubbleElement(properties.bubble.width(),properties.bubble.height()),instance.data.height=properties.bubble.height(),instance.data.myFont=properties.bubble.font_face().split(\":\")[0],null==instance.data.loaded_first_undo_JSON){let initialCanvas=JSON.stringify(instance.data.fabricCanvas);instance.data.undoArray.unshift(initialCanvas),instance.data.loaded_first_undo_JSON=!0}function addBGImage(url,img2){let xScale,yScale;xScale=properties.canvas_width_multiplier?properties.canvas_width_multiplier:1,properties.canvas_height_multiplier&&(yScale=properties.canvas_height_multiplier);let parentElement=instance.canvas;var originalWidth=parentElement.width(),originalHeight=parentElement.height();let newWidth=originalWidth*xScale,newHeight=originalHeight*yScale;parentElement.css({\"background-image\":'url(\"'+url+'\")',\"background-size\":newWidth+\"px auto\",\"background-repeat\":\"no-repeat\"}),instance.data.parentId=\"parent\"+instance.data.uniqueCanvasId,instance.canvas.attr(\"id\",instance.data.parentId),document.getElementById(instance.data.parentId)||instance.canvas.parent().attr(\"id\",instance.data.parentId);var img=new Image;img.onload=function(){var width=img.width,height=img.height;let ratio;instance.publishState(\"background_image_width\",newWidth),properties.canvas_width_multiplier?(ratio=newWidth/width,instance.data.bg_image_width=originalWidth/width*properties.canvas_width_multiplier):properties.canvas_height_multiplier&&(ratio=newHeight/height,instance.data.bg_image_height=originalHeight/height*properties.canvas_height_multiplier),null==ratio&&(ratio=1,instance.data.bg_image_width=originalWidth/width,instance.data.bg_image_height=originalWidth/width),instance.data.bg_image_ratio=ratio,instance.publishState(\"background_image_height\",height*ratio)},img.src=url}function setBackgroundImage(){if(properties.background_image){const img=new Image;img.crossOrigin=\"Anonymous\",img.onload=function(){const canvasWidth=instance.data.fabricCanvas.getWidth(),canvasHeight=instance.data.fabricCanvas.getHeight(),widthMultiplier=properties.canvas_width_multiplier||1,heightMultiplier=properties.canvas_height_multiplier,newWidth=canvasWidth*widthMultiplier;let newHeight=newWidth*(img.height/img.width);heightMultiplier&&(newHeight=canvasHeight*heightMultiplier);const widthRatio=newWidth/img.width,heightRatio=newHeight/img.height,finalRatio=heightMultiplier?heightRatio:widthRatio;instance.publishState(\"background_image_width\",newWidth),instance.publishState(\"background_image_height\",newHeight),instance.data.bg_image_width=finalRatio*(canvasWidth/img.width),instance.data.bg_image_height=finalRatio*(canvasHeight/img.height),instance.data.bg_image_ratio=finalRatio;const offCanvas=document.createElement(\"canvas\"),ctx=offCanvas.getContext(\"2d\");offCanvas.width=newWidth,offCanvas.height=newHeight,ctx.drawImage(img,0,0,newWidth,newHeight);const dataURI=offCanvas.toDataURL(\"image/png\");console.log(\"WIDTH AND HEIGHT\"),console.log(img.width),console.log(img.height),console.log(newWidth),console.log(newHeight),instance.data.fabricCanvas.setBackgroun
182dImage(dataURI,instance.data.fabricCanvas.renderAll.bind(instance.data.fabricCanvas),{originX:\"left\",originY:\"top\",scaleX:1}),instance.data.fabricCanvas.backgroundColor=\"rgba(255, 255, 255, 0)\",instance.data.updateUndoRedoArray&&instance.data.updateUndoRedoArray()},img.src=properties.background_image}}instance.data.numPixelsMovement=properties.arrow_key_movement,instance.data.fabricCanvas.on(\"mouse:down\",(event=>{if(document.getElementById(instance.data.context_menu_html_id)){if(3===event.button){if(1==instance.data.selectorIsOn){let coords=instance.canvas[0].parentNode.getBoundingClientRect();$(\"#\"+properties.context_menu_html_id).css({display:\"block\",position:\"fixed\",left:coords.left+instance.data.mouseDownX+65,top:coords.top+instance.data.mouseDownY,zIndex:1e14});let intersectsObect=!1,pointer=instance.data.fabricCanvas.getPointer(event),objects=instance.data.fabricCanvas.getObjects();for(var i=objects.length-1;i>=0;i--)objects[i].containsPoint(pointer)&&(intersectsObect=!0,instance.data.fabricCanvas.setActiveObject(objects[i]));0==intersectsObect&&(instance.data.fabricCanvas.discardActiveObject(),instance.data.fabricCanvas.renderAll())}instance.data.fabricCanvas.renderAll()}1===event.button&&(document.getElementById(properties.context_menu_html_id).style.display=\"none\")}})),instance.data.deleteKeyOn=properties.delete_key_on,instance.data.context_menu_html_id=properties.context_menu_html_id,instance.data.background_image=properties.background_image,setBackgroundImage(),instance.data.setBackgroundImage=setBackgroundImage;let unique_id=\"uniqueid\"+Math.floor(1e5*Math.random()).toString();function setElementControls(){var controlShow=[],controlName=[\"tl\",\"bl\",\"tr\",\"br\",\"ml\",\"mb\",\"mr\",\"mt\",\"mtr\"];let controlsList;controlsList=properties.controls_visibility?properties.controls_visibility:\" \",controlsList.includes(\"topLeft\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"topRight\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"bottomLeft\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"bottomRight\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"middleLeft\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"middleBottom\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"middleRight\")?controlShow.push(!0):controlShow.push(!1);let exactMatch=!1;for(let control of controlsList)if(\"middleTop\"===control){exactMatch=!0;break}exactMatch?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"middleTopRotation\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"topLeft\")?controlShow.push(!0):controlShow.push(!1),controlsList.includes(\"topLeft\")?controlShow.push(!0):controlShow.push(!1);for(var i=0,len=controlName.length;i<len;i++)instance.data.fabricCanvas.item(0).setControlVisible(controlName[i],controlShow[i]),instance.data.fabricCanvas.renderAll()}instance.publishState(\"unique_id\",properties.unique_id),instance.data.customCursor=properties.custom_cursor,fabric.Canvas.prototype.setCursor=function(value){\"Eraser\"!=instance.data.cursorMode||properties.custom_cursor||(value=\"none\"),properties.custom_cursor&&(value=properties.custom_cursor),this.upperCanvasEl.style.cursor=value},setElementControls(),instance.data.fabricCanvas.on(\"mouse:move\",(function(obj){\"Free Draw/Paint\"!=instance.data.cursorMode||instance.data.customCursor||(instance.data.mousecursor.top=obj.absolutePointer.y+instance.data.mousecursor.radius,instance.data.mousecursor.left=obj.absolutePointer.x+instance.data.mousecursor.radius,instance.data.fabricCanvas.bringToFront(instance.data.mousecursor),instance.data.fabricCanvas.renderAll()),\"Eraser\"!=instance.data.cursorMode||instance.data.customCursor||(instance.data.fabricCanvas.bringToFront(instance.data.erasercursor),instance.data.erasercursor.top=obj.absolutePointer.y+7,instance.data.erasercursor.left=obj.absolutePointer.x+7,instance.data.fabricCanvas.renderAll())})),instance.data.fabricCanvas.on(\"mouse:out\",(function(obj){instance.data.mousecursor.top=-1e3,instance.data.mousecursor.left=-1e3,instance.data.erasercursor.top=-1e3,instance.data.erasercursor.left=-1e3,instance.data.fabricCanvas.renderAll()})),instance.data.fabricCanvas.forEachObject((function(obj){obj.notSelectableOverride&&obj.set(\"selectable\",!1)})),document.addEventListener(\"keydown\",(function(event){(event.ctrlKey||event.metaKey)&&\"c\"===event.key&&properties.keyboard_shortcuts_copy_paste&&instance.data.copy(),(event.ctrlKey||event.metaKey)&&\"v\"===event.key&&properties.keyboard_shortcuts_copy_paste&&instance.data.paste()}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ACP":{"display":"Canvas - Color Picker","property_applications":{"resizable":true,"MinWidth":true,"Font":false},"add_is_visible":true,"fields":{"ACU":{"caption":"Color Picker (Circular)","name":"order_color_wheel","rank":0,"editor":"Dropdown","optional":false,"default_val":"Do Not Show"},"ACV":{"caption":"Saturation & Value","name":"order_saturation_and_value","rank":1,"editor":"Dropdown","default_val":"1","optional":false},"ACW":{"caption":"Color/Hue (Bar)","name":"order_hue","rank":2,"editor":"Dropdown","default_val":"2","optional":false}
182,"ACX":{"caption":"Transparency","name":"order_alpha","rank":3,"editor":"Dropdown","default_val":"3","optional":false},"ACY":{"caption":"Layout Direction","name":"layout_direction","rank":7,"editor":"Dropdown","default_val":"Horizontal"},"ACZ":{"caption":"Saturation","name":"order_saturation","rank":4,"editor":"Dropdown","default_val":"Do Not Show"},"ACa":{"caption":"Lightness/Darkness","name":"order_value","rank":5,"editor":"Dropdown","default_val":"Do Not Show"},"ACb":{"caption":"Temperature","name":"order_kelvin","rank":6,"editor":"Dropdown","default_val":"Do Not Show"},"ACc":{"caption":"Default Color","name":"default_color","rank":8,"editor":"Color","value":"text","default_val":"rgba(255, 255, 255, 1)"},"ACd":{"caption":"Handle Radius (px)","name":"handle_radius","rank":9,"editor":"DynamicValue","value":"number","default_val":5},"ACf":{"caption":"Slider Width (px)","name":"slider_size","rank":10,"editor":"DynamicValue","value":"number","default_val":20},"ACg":{"caption":"Element Spacing (px)","name":"element_spacing","rank":11,"editor":"DynamicValue","value":"number","default_val":4}},"states":{"ACk":{"caption":"value","name":"value","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ACx":{"caption":"Changed Color Picker Value","name":"changed_color_picker_value"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n\tlet width;\n if(properties.layout_direction==\"Vertical\"){\n \twidth=properties.bubble.width;\n }else{\n \twidth=properties.bubble.height;\n };\n \n let sliderRotation;\n \n if(properties.layout_direction==\"Horizontal\"){\n sliderRotation=0;\n }else{\n sliderRotation=0;\n };\n \n let floatOrientation;\n if(properties.layout_direction==\"Horizontal\"){\n floatOrientation=\"left\";\n }else{\n floatOrientation=\"none\";\n };\n \n let hueSliderImage;\n let kelvinSliderImage;\n let valueSliderImage;\n let saturationSliderImage;\n let alphaSliderImage;\n let sliderWidth;\n let sliderHeight;\n\n\n \n if(properties.layout_direction==\"Horizontal\"){\n hueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526028752x650886282555201900/Screen%20Shot%202020-03-06%20at%2012.20.03%20PM.png\";\n alphaSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583527030604x413939551286972800/Screen%20Shot%202020-03-06%20at%2012.36.49%20PM.png\";\n saturationSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526591900x515451627198557000/Screen%20Shot%202020-03-06%20at%2012.26.31%20PM.png\";\n valueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526552852x209007741437390300/Screen%20Shot%202020-03-06%20at%2012.26.39%20PM.png\";\n kelvinSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526496984x995007218827470000/Screen%20Shot%202020-03-06%20at%2012.26.49%20PM.png\";\n\t\tsliderWidth=properties.slider_size;\n\t\tsliderHeight=width;\n }else{\n hueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535397316x725423297035973800/Screen%20Shot%202020-03-06%20at%202.56.12%20PM.png\";\n alphaSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535452224x224947733836026400/Screen%20Shot%202020-03-06%20at%202.57.09%20PM.png\";\n saturationSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583536298572x802271065217276900/Screen%20Shot%202020-03-06%20at%203.11.13%20PM.png\";\n valueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535523244x197941623483908200/Screen%20Shot%202020-03-06%20at%202.58.25%20PM.png\";\n kelvinSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583536355992x535695635167514800/Screen%20Shot%202020-03-06%20at%203.12.14%20PM.png\";\n sliderWidth=width;\n sliderHeight=properties.slider_size;\n };\n \n \n\n \n \n \n function setOrder(num){\n let order;\n if(num==\"Do Not Show\"){\n order = 0;\n }
182else{\n order = parseInt(num);\n }\n return order;\n };\n \n let colorWheel = {\n order: setOrder(properties.order_color_wheel),\n container: \"<img src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583521525918x786521080204338000/Screen%20Shot%202020-03-06%20at%2011.04.56%20AM.png' id='colorwheel' style='float: \"+floatOrientation+\"; background-color: gray; width: \"+width+\"px; height: \"+ width+\"px'>\",\n }\n \n let colorBoxSaturationValue = {\n order: setOrder(properties.order_saturation_and_value),\n container: \"<img src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583521652368x707717803883901200/Screen%20Shot%202020-03-06%20at%2011.07.09%20AM.png' style='float: \"+floatOrientation+\"; background-color: orange; width: \"+width+\"px; height: \"+ width+\"px'>\"\n }\n \n let hueSlider = {\n order: setOrder(properties.order_hue),\n container: \"<img src='\"+hueSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n \n let alphaSlider = {\n order: setOrder(properties.order_alpha),\n container: \"<img src='\"+alphaSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let kelvinSlider = {\n order: setOrder(properties.order_kelvin),\n container: \"<img src='\"+kelvinSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let valueSlider = {\n order: setOrder(properties.order_value),\n container: \"<img src='\"+valueSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let saturationSlider = {\n order: setOrder(properties.order_saturation),\n container: \"<img src='\"+saturationSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let allContainers = [colorWheel, colorBoxSaturationValue, hueSlider, alphaSlider, kelvinSlider, valueSlider, saturationSlider];\n allContainers = allContainers.filter(container => container.order>0);\n allContainers.sort((firstContainer, lastContainer)=>
182 firstContainer.order - lastContainer.order);\n \n let sortedContainers = allContainers.map(a => a.container);\n \n for(i=0; i<sortedContainers.length; i++){\n \tinstance.canvas.append(sortedContainers[i]); \n };\n \n \n \n \n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueColorPickerID=\"colorpicker\"+Math.floor(1e5*Math.random()).toString();let myDiv=\"<div id=\"+instance.data.uniqueColorPickerID+\"></div>\";instance.canvas.append(myDiv)}"},"update":{"fn":"function(instance,properties,context){let selectedColor=properties.default_color,width;width=\"Vertical\"==properties.layout_direction?properties.bubble.width():properties.bubble.height();let colorPickerUniqueID=\"#\"+instance.data.uniqueColorPickerID,colorPicker=new iro.ColorPicker(colorPickerUniqueID,{width:width,color:selectedColor,borderWidth:5,borderColor:\"000000\",padding:1,handleRadius:properties.handle_radius,sliderSize:properties.slider_size,sliderMargin:properties.element_spacing,layoutDirection:properties.layout_direction.toLowerCase(),wheelLightness:!1,layout:[]});function colorChanged(){instance.data.savedColor=colorPicker.color.rgbaString,instance.publishState(\"value\",instance.data.savedColor),instance.triggerEvent(\"changed_color_picker_value\",(function(err){}))}function setOrder(num){let order;return order=\"Do Not Show\"==num?0:parseInt(num),order}instance.data.colorPicker=colorPicker,colorPicker.on(\"color:change\",colorChanged),instance.publishState(\"value\",colorPicker.color.rgbaString);let colorWheel={order:setOrder(properties.order_color_wheel),iroObject:{component:iro.ui.Wheel,options:{wheelAngle:180}}},colorBoxSaturationValue,hueSlider,alphaSlider,kelvinSlider,valueSlider,saturationSlider,allIroComponents=[{order:setOrder(properties.order_saturation_and_value),iroObject:{component:iro.ui.Box,options:{}}},{order:setOrder(properties.order_hue),iroObject:{component:iro.ui.Slider,options:{sliderType:\"hue\"}}},colorWheel,{order:setOrder(properties.order_alpha),iroObject:{component:iro.ui.Slider,options:{sliderType:\"alpha\"}}},{order:setOrder(properties.order_kelvin),iroObject:{component:iro.ui.Slider,options:{sliderType:\"kelvin\"}}},{order:setOrder(properties.order_value),iroObject:{component:iro.ui.Slider,options:{sliderType:\"value\"}}},{order:setOrder(properties.order_saturation),iroObject:{component:iro.ui.Slider,options:{sliderType:\"saturation\"}}}];allIroComponents=allIroComponents.filter((component=>component.order>0)),allIroComponents.sort(((firstComponent,lastComponent)=>firstComponent.order-lastComponent.order));let sortedComponents=allIroComponents.map((a=>a.iroObject));colorPicker.props.layout.push.apply(colorPicker.props.layout,sortedComponents),colorPicker.forceUpdate(),colorPicker.on(\"color:change\",(function(color){instance.publishState(\"value\",instance.data.savedColor)}));let mystyle=document.getElementsByTagName(\"STYLE\");instance.data.colorPicker.forceUpdate()}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ACi":{"display":"Canvas - Menu Icons","property_applications":{"resizable":true,"MinWidth":true},"add_hover_pressed":true,"add_is_visible":true,"fields":{"ACk":{"caption":"Menu Icon","name":"menu_icon","rank":0,"editor":"Dropdown","default_val":"Select"},"ACl":{"caption":"Icon Color","name":"color","rank":1,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"}},"events":{"ACm":{"caption":"Icon Clicked","name":"icon_clicked"}},"code":{"preview":{"fn":"function(instance, properties) {\n\n\n\n}"},"initialize":{"fn":"function(instance,context){instance.data.iconsID=Math.floor(1e5*Math.random()).toString();let myDiv='<i id=\"'+instance.data.iconsID+'\" data-feather=\"circle\"></i>';instance.canvas.append(myDiv)}"},"update":{"fn":"function(instance,properties,context){let height;height=properties.bubble.height()>properties.bubble.width()?properties.bubble.width():properties.bubble.height();let iconType=\"circle\";\"Draw\"==properties.menu_icon?iconType=\"edit-2\":\"Select\"==properties.menu_icon?iconType=\"mouse-pointer\":\"Text\"==properties.menu_icon?iconType=\"type\":\"Shapes\"==properties.menu_icon?iconType=\"square\":\"Image\"==properties.menu_icon?iconType=\"image\":\"Undo\"==properties.menu_icon?iconType=\"corner-up-left\":\"Redo\"==properties.menu_icon&&(iconType=\"corner-up-right\");let icon=document.getElementById(instance.data.iconsID);icon.setAttribute(\"stroke\",properties.color),icon.setAttribute(\"data-feather\",iconType),icon.setAttribute(\"height\",height),icon.setAttribute(\"width\",height),feather.replace(),document.getElementById(instance.data.iconsID).onclick=function(evt){instance.triggerEvent(\"icon_clicked\",(function(err){}))}}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}}}; 183window._bubble_page_load_data.plugins_size['1565920055521x927769972289306600'] = 142590; 184window.preloaded['plugin/third_party:1565920055521x927769972289306600:1.56.37'] = true; 185window.plugins["1578535742499x577397265006067700"] = {"human":"PDF Generator - Page & Group to PDF","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAE":{"display":"Screenshot Outputter","property_applications":{"Border":false,"resizable":true},"add_hover_pressed":false,"add_is_visible":true,"states":{"AAH":{"caption":"Screenshot URL","name":"imageurl","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AAX":{"caption":"Screenshot URL has been generated","name":"screenshotURL_is_generated"}},"actions":{"AAG":{"caption":"Generate Screenshot URL from","code":{"fn":"function(instance,properties,context){function convertImagesToDataURIs(element){const images=element.getElementsByTagName(\"img\"),promises=Array.from(images).map((img=>new Promise((resolve=>{img.crossOrigin&&\"anonymous\"===img.crossOrigin||(img.crossOrigin=\"anonymous\");const canvas=document.createElement(\"canvas\");canvas.width=img.width,canvas.height=img.height;const ctx=canvas.getContext(\"2d\");img.onload=()=>{ctx.drawImage(img,0,0,img.width,img.height),img.src=canvas.toDataURL(\"image/png\"),resolve()},img.onerror=()=>resolve()}))));return Promise.all(promises)}let html2canvasOptions,screenshotElement,scale=properties.scale<0?1:properties.scale;if(instance.data.format=properties.file_format||\".png\",\"Current Screen\"===properties.screenshottargetelement)screenshotElement=document.body,html2canvasOptions={x:window.scrollX,y:window.scrollY,width:window.innerWidth,height:window.innerHeight,useCORS:!0,allowTaint:!1,scale:scale};else if(\"Entire Page\"===properties.screenshottargetelement){screenshotElement=document.body;const fullWidth=document.documentElement.scrollWidth,fullHeight=document.documentElement.scrollHeight;html2canvasOptions={width:fullWidth,height:fullHeight,useCORS:!0,allowTaint:!1,scale:scale}}else if(\"Specific Element\"===properties.screenshottargetelement){screenshotElement=document.getElementById(properties.element_html_id);const elementRect=screenshotElement.getBoundingClientRect();html2canvasOptions={x:elementRect.left+window.scrollX,y:elementRect.top+window.scrollY,width:elementRect.width,height:elementRect.height,useCORS:!0,allowTaint:!1,scale:scale}}convertImagesToDataURIs(screenshotElement).then((()=>{html2canvas(screenshotElement,html2canvasOptions).then((function(canvas){instance.data.canvasScreenshot=canvas,instance.data.saveImage(properties.filename)}))}
185))}"},"fields":{"AAZ":{"caption":"File Name","name":"filename","rank":0,"editor":"DynamicValue","value":"text","default_val":"myscreenshot"},"AAa":{"caption":"Screenshot Mode","name":"screenshottargetelement","rank":1,"editor":"Dropdown","default_val":"Current Screen"},"AAc":{"caption":"Element ID Attribute (if \"Specific Element\" selected)","name":"element_html_id","rank":2,"editor":"DynamicValue","value":"text","optional":true},"AAg":{"caption":"File Format","name":"file_format","rank":3,"editor":"Dropdown","default_val":".png"},"AAi":{"caption":"Scale/Resolution","name":"scale","rank":4,"editor":"DynamicValue","value":"number","default_val":1}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Image Generator - Make this element 1px tall & 1px wide to hide it';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"},"initialize":{"fn":"function(instance,context){function uploadContentCallback(err,url){url?(instance.publishState(\"imageurl\",url),instance.triggerEvent(\"screenshotURL_is_generated\",(function(err){}))):console.error(\"Screenshot Plugin\",\"Error on uploadContent:\",err)}function saveImage(fileName){let imageData=instance.data.canvasScreenshot.toDataURL(),imageDataPng=imageData.substring(imageData.indexOf(\",\")+1);context.uploadContent(fileName+instance.data.format,imageDataPng,instance.data.uploadContentCallback)}instance.data.uploadContentCallback=uploadContentCallback,instance.data.saveImage=saveImage}"},"update":{"fn":"function(instance,properties,context){instance.data.captureEntirePage=properties.capture_entire_page}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AAn":{"display":"PDF Generator","property_applications":{"resizable":true},"add_is_visible":true,"states":{"AAu":{"caption":"PDF URL","name":"pdf_url","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ABG":{"caption":"PDF Ready (has been generated)","name":"pdf_ready"}},"actions":{"AAo":{"caption":"Download PDF","code":{"fn":"function(instance,properties,context){const element=document.getElementById(properties.html_id);function convertImagesToDataURIs(element){const images=element.querySelectorAll(\"img\"),promises=[];
185return images.forEach((img=>{const src=img.src;if(src){const promise=new Promise((resolve=>{const xhr=new XMLHttpRequest;xhr.onload=function(){const reader=new FileReader;reader.onloadend=function(){img.src=reader.result,resolve()},reader.readAsDataURL(xhr.response)},xhr.open(\"GET\",src),xhr.responseType=\"blob\",xhr.send()}));promises.push(promise)}})),Promise.all(promises)}convertImagesToDataURIs(element).then((()=>{html2pdf().from(element).set({margin:properties.margin,filename:properties.document_name+\".pdf\",html2canvas:{scale:3,scrollX:0,scrollY:0,windowWidth:document.documentElement.clientWidth,windowHeight:document.documentElement.clientHeight},jsPDF:{unit:\"in\",format:\"letter\",orientation:\"portrait\"},pagebreak:{before:\"#pagebreak\"}}).save()}))}"},"fields":{"AAp":{"caption":"HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text"},"AAq":{"caption":"Document name","name":"document_name","rank":1,"editor":"DynamicValue","value":"text","default_val":"pdf_name"},"AAr":{"caption":"Margin","name":"margin","rank":2,"editor":"DynamicValue","value":"number","default_val":0}}},"AAt":{"caption":"Generate PDF URL","code":{"fn":"function(instance,properties,context){console.log(\"GENERATING\");const element=document.getElementById(properties.html_id);function uploadContentCallback(err,url){url?(instance.publishState(\"pdf_url\",url),instance.triggerEvent(\"pdf_ready\",(function(err){}))):console.error(\"PDF Plugin\",\"Error on uploadContent:\",err)}function convertImagesToDataURIs(element){const images=element.querySelectorAll(\"img\"),promises=[];return images.forEach((img=>{const src=img.src;if(src){const promise=new Promise((resolve=>{const xhr=new XMLHttpRequest;xhr.onload=function(){const reader=new FileReader;reader.onloadend=function(){img.src=reader.result,resolve()},reader.readAsDataURL(xhr.response)},xhr.open(\"GET\",src),xhr.responseType=\"blob\",xhr.send()}));promises.push(promise)}})),Promise.all(promises)}instance.data.uploadContentCallback=uploadContentCallback,convertImagesToDataURIs(element).then((()=>{html2pdf().from(element).set({margin:properties.margin,html2canvas:{scale:3},jsPDF:{unit:\"in\",format:\"letter\",orientation:\"portrait\"},pagebreak:{before:\"#pagebreakhere\"}}).outputPdf(\"blob\").then((pdfBlob=>{const reader=new FileReader;reader.onloadend=function(){const pdfDataURL=undefined,base64Data=reader.result.split(\",\")[1],fileBlob=new Blob([atob(base64Data)],{type:\"application/pdf\"});context.uploadContent(properties.document_name+\".pdf\"||\"pdf_name.pdf\",base64Data,uploadContentCallback)},reader.readAsDataURL(pdfBlob)}))}))}"},"fields":{"AAv":{"caption":"HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text"},"AAw":{"caption":"Margin","name":"margin","rank":2,"editor":"DynamicValue","value":"number","default_val":0},"AAx":{"caption":"Document Name","name":"document_name","rank":1,"editor":"DynamicValue","value":"text","default_val":"pdf_name"}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'PDF Generator - Make this element 1px tall & 1px wide to hide it';
185\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AAs":{"display":"PDF - Page Break","property_applications":{"resizable":true},"add_is_visible":true,"code":{"preview":{"fn":"function(instance, properties) {\n\n\n\n}"},"initialize":{"fn":"function(instance,context){instance.canvas[0].id=\"page-break-element-id\",instance.canvas[0].style.width=\"1px\",instance.canvas[0].style.height=\"1px\",instance.canvas[0].style.visibility=\"hidden\"}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}}}; 186window._bubble_page_load_data.plugins_size['1578535742499x577397265006067700'] = 12743; 187window.preloaded['plugin/third_party:1578535742499x577397265006067700:1.4.39'] = true; 188window.plugins["1583096521531x455947381906866200"] = {"human":"Bundle: PDF, Video Player, and More","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"ACN":{"display":"Color Picker","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"fields":{"ACU":{"caption":"Color Picker (Circular)","name":"order_color_wheel","rank":0,"editor":"Dropdown","optional":false,"default_val":"1"},"ACV":{"caption":"Saturation & Value","name":"order_saturation_and_value","rank":1,"editor":"Dropdown","default_val":"2","optional":false},"ACW":{"caption":"Color/Hue (Bar)","name":"order_hue","rank":2,"editor":"Dropdown","default_val":"3","optional":false},"ACX":{"caption":"Transparency","name":"order_alpha","rank":3,"editor":"Dropdown","default_val":"4","optional":false},"ACY":{"caption":"Layout Direction","name":"layout_direction","rank":7,"editor":"Dropdown","default_val":"Vertical"},"ACZ":{"caption":"Saturation","name":"order_saturation","rank":4,"editor":"Dropdown","default_val":"5"},"ACa":{"caption":"Lightness/Darkness","name":"order_value","rank":5,"editor":"Dropdown","default_val":"6"},"ACb":{"caption":"Temperature","name":"order_kelvin","rank":6,"editor":"Dropdown","default_val":"7"},"ACc":{"caption":"Default Color","name":"default_color","rank":8,"editor":"Color","value":"text","default_val":"rgba(255, 255, 255, 1)"},"ACd":{"caption":"Handle Radius (px)","name":"handle_radius","rank":9,"editor":"DynamicValue","value":"number","default_val":5},"ACf":{"caption":"Slider Width (px)","name":"slider_size","rank":10,"editor":"DynamicValue","value":"number","default_val":20},"ACg":{"caption":"Element Spacing (px)","name":"element_spacing","rank":11,"editor":"DynamicValue","value":"number","default_val":12}},"states":{"ACk":{"caption":"value (rgba)","name":"value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ACz":{"caption":"value (hex)","name":"value_hex","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ACx":{"caption":"Changed Color Picker Value","name":"changed_color_picker_value"}},"actions":{"ADA":{"caption":"Set Selected Color on ","code":{"fn":"function(instance,properties,context){instance.data.colorPicker.color.set(properties.color)}"},"fields":{"ADB":{"caption":"Color","name":"color","rank":0,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n\tlet width;\n if(properties.layout_direction==\"Vertical\"){\n \twidth=properties.bubble.width;\n }
188else{\n \twidth=properties.bubble.height;\n };\n \n let sliderRotation;\n \n if(properties.layout_direction==\"Horizontal\"){\n sliderRotation=0;\n }else{\n sliderRotation=0;\n };\n \n let floatOrientation;\n if(properties.layout_direction==\"Horizontal\"){\n floatOrientation=\"left\";\n }else{\n floatOrientation=\"none\";\n };\n \n let hueSliderImage;\n let kelvinSliderImage;\n let valueSliderImage;\n let saturationSliderImage;\n let alphaSliderImage;\n let sliderWidth;\n let sliderHeight;\n\n\n \n if(properties.layout_direction==\"Horizontal\"){\n hueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526028752x650886282555201900/Screen%20Shot%202020-03-06%20at%2012.20.03%20PM.png\";\n alphaSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583527030604x413939551286972800/Screen%20Shot%202020-03-06%20at%2012.36.49%20PM.png\";\n saturationSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526591900x515451627198557000/Screen%20Shot%202020-03-06%20at%2012.26.31%20PM.png\";\n valueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526552852x209007741437390300/Screen%20Shot%202020-03-06%20at%2012.26.39%20PM.png\";\n kelvinSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583526496984x995007218827470000/Screen%20Shot%202020-03-06%20at%2012.26.49%20PM.png\";\n\t\tsliderWidth=properties.slider_size;\n\t\tsliderHeight=width;\n }else{\n hueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535397316x725423297035973800/Screen%20Shot%202020-03-06%20at%202.56.12%20PM.png\";\n alphaSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535452224x224947733836026400/Screen%20Shot%202020-03-06%20at%202.57.09%20PM.png\";\n saturationSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583536298572x802271065217276900/Screen%20Shot%202020-03-06%20at%203.11.13%20PM.png\";\n valueSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583535523244x197941623483908200/Screen%20Shot%202020-03-06%20at%202.58.25%20PM.png\";\n kelvinSliderImage=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583536355992x535695635167514800/Screen%20Shot%202020-03-06%20at%203.12.14%20PM.png\";\n sliderWidth=width;\n sliderHeight=properties.slider_size;\n };\n \n \n\n \n \n \n function setOrder(num){\n let order;\n if(num==\"Do Not Show\"){\n order = 0;\n }
188else{\n order = parseInt(num);\n }\n return order;\n };\n \n let colorWheel = {\n order: setOrder(properties.order_color_wheel),\n container: \"<img src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583521525918x786521080204338000/Screen%20Shot%202020-03-06%20at%2011.04.56%20AM.png' id='colorwheel' style='float: \"+floatOrientation+\"; background-color: gray; width: \"+width+\"px; height: \"+ width+\"px'>\",\n }\n \n let colorBoxSaturationValue = {\n order: setOrder(properties.order_saturation_and_value),\n container: \"<img src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1583521652368x707717803883901200/Screen%20Shot%202020-03-06%20at%2011.07.09%20AM.png' style='float: \"+floatOrientation+\"; background-color: orange; width: \"+width+\"px; height: \"+ width+\"px'>\"\n }\n \n let hueSlider = {\n order: setOrder(properties.order_hue),\n container: \"<img src='\"+hueSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n \n let alphaSlider = {\n order: setOrder(properties.order_alpha),\n container: \"<img src='\"+alphaSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let kelvinSlider = {\n order: setOrder(properties.order_kelvin),\n container: \"<img src='\"+kelvinSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let valueSlider = {\n order: setOrder(properties.order_value),\n container: \"<img src='\"+valueSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let saturationSlider = {\n order: setOrder(properties.order_saturation),\n container: \"<img src='\"+saturationSliderImage+\"' style='float: \"+floatOrientation+\"; transform: rotate(\"+sliderRotation+\"deg); background-color: orange; width: \"+sliderWidth+\"px; height: \"+ sliderHeight+\"px'>\"\n }\n \n let allContainers = [colorWheel, colorBoxSaturationValue, hueSlider, alphaSlider, kelvinSlider, valueSlider, saturationSlider];\n allContainers = allContainers.filter(container => container.order>0);\n allContainers.sort((firstContainer, lastContainer)=>
188 firstContainer.order - lastContainer.order);\n \n let sortedContainers = allContainers.map(a => a.container);\n \n for(i=0; i<sortedContainers.length; i++){\n \tinstance.canvas.append(sortedContainers[i]); \n };\n \n \n \n \n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueColorPickerID=\"colorpicker\"+Math.floor(1e5*Math.random()).toString();let myDiv=\"<div id=\"+instance.data.uniqueColorPickerID+\"></div>\";instance.canvas.append(myDiv)}"},"update":{"fn":"function(instance,properties,context){let selectedColor=properties.default_color,width;width=\"Vertical\"==properties.layout_direction?properties.bubble.width():properties.bubble.height();let colorPickerUniqueID=\"#\"+instance.data.uniqueColorPickerID;if(!instance.data.colorPicker){let colorPicker=new iro.ColorPicker(colorPickerUniqueID,{width:width,color:selectedColor,borderWidth:5,borderColor:\"000000\",padding:1,handleRadius:properties.handle_radius,sliderSize:properties.slider_size,sliderMargin:properties.element_spacing,layoutDirection:properties.layout_direction.toLowerCase(),wheelLightness:!1,layout:[]});instance.data.colorPicker=colorPicker}function colorChanged(){instance.publishState(\"value\",instance.data.colorPicker.color.rgbaString),instance.triggerEvent(\"changed_color_picker_value\",(function(err){}))}function setOrder(num){let order;return order=\"Do Not Show\"==num?0:parseInt(num),order}instance.data.colorPicker.on(\"color:change\",colorChanged),instance.publishState(\"value\",instance.data.colorPicker.color.rgbaString),instance.publishState(\"value_hex\",instance.data.colorPicker.color.hexString);let colorWheel={order:setOrder(properties.order_color_wheel),iroObject:{component:iro.ui.Wheel,options:{wheelAngle:180}}},colorBoxSaturationValue,hueSlider,alphaSlider,kelvinSlider,valueSlider,saturationSlider,allIroComponents=[{order:setOrder(properties.order_saturation_and_value),iroObject:{component:iro.ui.Box,options:{}}},{order:setOrder(properties.order_hue),iroObject:{component:iro.ui.Slider,options:{sliderType:\"hue\"}}},colorWheel,{order:setOrder(properties.order_alpha),iroObject:{component:iro.ui.Slider,options:{sliderType:\"alpha\"}}},{order:setOrder(properties.order_kelvin),iroObject:{component:iro.ui.Slider,options:{sliderType:\"kelvin\"}}},{order:setOrder(properties.order_value),iroObject:{component:iro.ui.Slider,options:{sliderType:\"value\"}}},{order:setOrder(properties.order_saturation),iroObject:{component:iro.ui.Slider,options:{sliderType:\"saturation\"}}}];allIroComponents=allIroComponents.filter((component=>component.order>0)),allIroComponents.sort(((firstComponent,lastComponent)=>firstComponent.order-lastComponent.order));let sortedComponents=allIroComponents.map((a=>a.iroObject));instance.data.colorPicker.props.layout.push.apply(instance.data.colorPicker.props.layout,sortedComponents),instance.data.colorPicker.on(\"color:change\",(function(color){instance.publishState(\"value\",color.rgbaString),instance.publishState(\"value_hex\",color.hexString)}));let mystyle=document.getElementsByTagName(\"STYLE\");instance.data.colorPicker.color.set(properties.default_color),instance.data.colorPicker.forceUpdate()}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ADD":{"display":"Text Editor - Beta","add_is_visible":true,"code":{"preview":{"fn":"function(instance, properties) {\n\n\n\n}"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ADQ":{"display":"PDF Generator","property_applications":{"resizable":true},"add_is_visible":true,"states":{"ADP":{"caption":"PDF URL","name":"pdf_url","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ADO":{"caption":"PDF Ready (has been generated)","name":"pdf_ready"}},"actions":{"ADG":{"caption":"Download PDF","code":{"fn":"function(instance,properties,context){const element=document.getElementById(properties.html_id);function convertImagesToDataURIs(element){const images=element.querySelectorAll(\"img\"),promises=[];
188return images.forEach((img=>{const src=img.src;if(src){const promise=new Promise((resolve=>{const xhr=new XMLHttpRequest;xhr.onload=function(){const reader=new FileReader;reader.onloadend=function(){img.src=reader.result,resolve()},reader.readAsDataURL(xhr.response)},xhr.open(\"GET\",src),xhr.responseType=\"blob\",xhr.send()}));promises.push(promise)}})),Promise.all(promises)}convertImagesToDataURIs(element).then((()=>{html2pdf().from(element).set({margin:properties.margin,filename:properties.document_name+\".pdf\",html2canvas:{scale:3,scrollX:0,scrollY:0,windowWidth:document.documentElement.clientWidth,windowHeight:document.documentElement.clientHeight},jsPDF:{unit:\"in\",format:\"letter\",orientation:\"portrait\"},pagebreak:{before:\"#pagebreak\"}}).save()}))}"},"fields":{"ADH":{"caption":"HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text"},"ADI":{"caption":"Document name","name":"document_name","rank":1,"editor":"DynamicValue","value":"text","default_val":"pdf_name"},"ADJ":{"caption":"Margin","name":"margin","rank":2,"editor":"DynamicValue","value":"number","default_val":0}}},"ADK":{"caption":"Generate PDF URL","code":{"fn":"function(instance,properties,context){console.log(\"GENERATING\");const element=document.getElementById(properties.html_id);function uploadContentCallback(err,url){url?(instance.publishState(\"pdf_url\",url),instance.triggerEvent(\"pdf_ready\",(function(err){}))):console.error(\"PDF Plugin\",\"Error on uploadContent:\",err)}function convertImagesToDataURIs(element){const images=element.querySelectorAll(\"img\"),promises=[];return images.forEach((img=>{const src=img.src;if(src){const promise=new Promise((resolve=>{const xhr=new XMLHttpRequest;xhr.onload=function(){const reader=new FileReader;reader.onloadend=function(){img.src=reader.result,resolve()},reader.readAsDataURL(xhr.response)},xhr.open(\"GET\",src),xhr.responseType=\"blob\",xhr.send()}));promises.push(promise)}})),Promise.all(promises)}instance.data.uploadContentCallback=uploadContentCallback,convertImagesToDataURIs(element).then((()=>{html2pdf().from(element).set({margin:properties.margin,html2canvas:{scale:3},jsPDF:{unit:\"in\",format:\"letter\",orientation:\"portrait\"},pagebreak:{before:\"#pagebreakhere\"}}).outputPdf(\"blob\").then((pdfBlob=>{const reader=new FileReader;reader.onloadend=function(){const pdfDataURL=undefined,base64Data=reader.result.split(\",\")[1],fileBlob=new Blob([atob(base64Data)],{type:\"application/pdf\"});context.uploadContent(properties.document_name+\".pdf\"||\"pdf_name.pdf\",base64Data,uploadContentCallback)},reader.readAsDataURL(pdfBlob)}))}))}"},"fields":{"ADL":{"caption":"HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text"},"ADM":{"caption":"Margin","name":"margin","rank":2,"editor":"DynamicValue","value":"number","default_val":0},"ADN":{"caption":"Document Name","name":"document_name","rank":1,"editor":"DynamicValue","value":"text","default_val":"pdf_name"}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'PDF Generator - Make this element 1px tall & 1px wide to hide it';
188\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AEw":{"display":"Video Player","property_applications":{"resizable":true,"MinWidth":true,"Background":true,"Border":true,"Padding":true,"BoxShadow":true,"Font":true},"add_is_visible":true,"add_large_file_upload_properties":false,"can_fit_width":true,"can_fit_height":true,"fields":{"AEG":{"caption":"Video URL","name":"video_url","rank":1,"editor":"DynamicValue","value":"file","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734116151820x132671698403852280/sample_960x400_ocean_with_audio.mp4"},"AEH":{"caption":"Play Automatically?","name":"play_automatically","rank":10,"editor":"DynamicValue","value":"boolean","default_val":false},"AEI":{"caption":"Thumbnail Image","name":"video_poster","rank":8,"editor":"DynamicValue","value":"image","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734129624872x833500003703271800/Screenshot%202024-12-13%20at%202.35.21%E2%80%AFPM.png"},"AEJ":{"caption":"Video Speed","name":"video_speed","rank":12,"editor":"DynamicValue","value":"number","default_val":1},"AEK":{"caption":"Show FullScreen Btn?","name":"show_full_screen_button","rank":16,"editor":"DynamicValue","value":"boolean","default_val":true},"AEL":{"caption":"Loop Video?","name":"replay_video_when_over","rank":13,"editor":"DynamicValue","value":"boolean","default_val":false},"AEM":{"caption":"Playing - Scrub Bar Color","name":"playing_scrubber_bar_color","rank":4,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"AEN":{"caption":"Play Button Color","name":"play_button_color","rank":5,"editor":"Color","default_val":"rgba(255,255,255,1)"},"AEO":{"caption":"Progress Bar Color","name":"progress_bar_color","rank":6,"editor":"Color","default_val":"rgba(255,255,255,0.3)"},"AEP":{"caption":"Disable Control Bar?","name":"disable_control_bar","rank":17,"editor":"DynamicValue","value":"boolean","default_val":false},"AEQ":{"caption":"Start Time","name":"start_time","rank":11,"editor":"DynamicValue","value":"number","optional":true},"AER":{"caption":"--------------------------------- Colors ---------------------------------","name":"-------------_colors_-------------","rank":3,"editor":"Label"},"AES":{"caption":"-------------------------- Control Options ---------------------------","name":"-------------_buttons_-------------","rank":15,"editor":"Label"},"AET":{"caption":"----------------------- Default Play Options -----------------------","name":"--------------------------_play_options_---------------------------","rank":9,"editor":"Label"},"AEU":{"caption":"--------------------- Video Thumbnail/Poster --------------------Video Thumbnail/Poster Image that is shown before the video starts while is it not playing","name":"--------------------------_video_thumbnail_---------------------------","rank":7,"editor":"Label"},"AEV":{"caption":"Show Play Button?","name":"play","rank":18,"editor":"DynamicValue","value":"boolean","default_val":true},"AEW":{"caption":"Show Progress Slider?","name":"progress","rank":19,"editor":"DynamicValue","value":"boolean","default_val":true},"AEX":{"caption":"Show Current Time?","name":"current_time","rank":20,"editor":"DynamicValue","value":"boolean","default_val":true},"AEY":{"caption":"Show Mute Button?","name":"mute","rank":21,"editor":"DynamicValue","value":"boolean","default_val":true},"AEZ":{"caption":"Show Volume Slider?","name":"volume","rank":22,"editor":"DynamicValue","value":"boolean","default_val":true},"AEa":{"caption":"Show Captions?","name":"captions","rank":23,"editor":"DynamicValue","value":"boolean","default_val":true},"AEb":{"caption":"Show Settings Menu?","name":"settings","rank":27,"editor":"DynamicValue","value":"boolean","default_val":true},"AEc":{"caption":"Show PIP Button?","name":"pip","rank":24,"editor":"DynamicValue","value":"boolean","default_val":true},"AEd":{"caption":"Show Airplay Btn?","name":"airplay","rank":25,"editor":"DynamicValue","value":"boolean","default_val":true},"AEe":{"caption":"Quality","name":"quality","rank":28,"editor":"DynamicValue","value":"boolean","default_val":true},"AEf":{"caption":"Speed","name":"speed","rank":29,"editor":"DynamicValue","value":"boolean","default_val":true},"AEg":{"caption":"Loop","name":"loop","rank":30,"editor":"DynamicValue","value":"boolean","default_val":true},"AEh":{"caption":"--------------------------- Settings Menu ----------------------------","name":"----------------------------_settings_menu_-----------------------------","rank":26,"editor":"Label"},"AEi":{"caption":"Muted by default?","name":"muted_default","rank":14,"editor":"DynamicValue","value":"boolean","default_val":false},"AEj":{"caption":"â ï¸ Bubble doesn't allow you to upload files larger than 25MB, so for videos >25MB, you will need to store those outside of Bubble (on AWS, Google Cloud, etc)","name":"â ï¸_you_will_need_to_store_your_video_outside_of_bubble.io","rank":2,"editor":"Label"},"AEk":{"caption":"In the input below, upload a video or insert a dynamic link that points to a video in your Bubble database:","name":"you_can_upload_a_video_or_insert_a_dynamic_link_that_points_to_a_video_in_your_bubble_database._","rank":0,"editor":"Label"}},"states":{"AEl":{"caption":"Player Current Time","name":"player_current_time","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEm":{"caption":"playing?","name":"playing","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AEn":{"caption":"paused?","name":"paused","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AEo":{"caption":"ended?","name":"ended","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AEp":{"caption":"Buffered (0 = not buffered, 1 = completely buffered)","name":"buffered","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEq":{"caption":"seeking?","name":"seeking","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AEr":{"caption":"Duration","name":"duration","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEs":{"caption":"Volume","name":"volume","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEt":{"caption":"Muted","name":"muted","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"AEu":{"caption":"Speed","name":"speed","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AEv":{"caption":"Ratio","name":"ratio","initialization_code":{"fn":"function(properties,context){}"},"value":"text"}},"actions":{"ADu":{"caption":"Play Video","code":{"fn":"function(instance,properties,context){instance.data.player.play()}"}},"ADv":{"caption":"Pause Video","code":{"fn":"function(instance,properties,context){instance.data.player.pause()}"}},"ADw":{"caption":"Restart Video","code":{"fn":"function(instance,properties,context){instance.data.player.restart()}"}},"ADx":{"caption":"Rewind","code":{"fn":"function(instance,properties,context){instance.data.player.rewind(properties.num_seconds)}"},"fields":{"ADy":{"caption":"Num seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"ADz":{"caption":"Forward","code":{"fn":"function(instance,properties,context){instance.data.player.forward(properties.num_seconds)}"},"fields":{"AEA":{"caption":"Num Seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"AEB":{"caption":"Decrease Volume","code":{"fn":"function(instance,properties,context){instance.data.player.decreaseVolume()}"}},"AEC":{"caption":"Increase Volume","code":{"fn":"function(instance,properties,context){instance.data.player.increaseVolume()}"}},"AED":{"caption":"Enter Fullscreen","code":{"fn":"function(instance,properties,context){instance.data.player.fullscreen.enter()}"}},"AEE":{"caption":"Mute or Unmute","code":{"fn":"function(instance,properties,context){properties.mute?instance.data.player.muted=!0:instance.data.player.muted=!1}"},"fields":{"AEF":{"caption":"Mute?","name":"mute","rank":0,"editor":"DynamicValue","value":"boolean","default_val":true}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Video Player';
188\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '15px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){instance.data.uniqueVideoId=\"plyrVideo\"+Math.floor(1e5*Math.random()).toString(),instance.canvas.empty(),instance.data.videoContainer=`<video id=\"${instance.data.uniqueVideoId}\" controls></video>`,instance.canvas.append(instance.data.videoContainer);const videoElement=document.getElementById(instance.data.uniqueVideoId),controls=[];properties.show_full_screen_button&&controls.push(\"fullscreen\"),properties.play_large&&controls.push(\"play-large\"),properties.play&&controls.push(\"play\"),properties.progress&&controls.push(\"progress\"),properties.current_time&&controls.push(\"current-time\"),properties.mute&&controls.push(\"mute\"),properties.volume&&controls.push(\"volume\"),properties.captions&&controls.push(\"captions\"),properties.settings&&controls.push(\"settings\"),properties.pip&&controls.push(\"pip\"),properties.airplay&&controls.push(\"airplay\"),properties.disable_control_bar&&(controls.length=0);const settings=[];if(properties.quality&&settings.push(\"quality\"),properties.speed&&settings.push(\"speed\"),properties.loop&&settings.push(\"loop\"),properties.captions&&settings.push(\"captions\"),instance.data.player=new Plyr(videoElement,{controls:controls,autoplay:properties.play_automatically||!1,loop:{active:properties.replay_video_when_over||!1},settings:settings.length>0?settings:[\"quality\",\"speed\",\"loop\",\"captions\"]}),properties.video_url){const videoSource=properties.video_url;videoSource.includes(\"youtube.com\")||videoSource.includes(\"youtu.be\")?instance.data.player.source={type:\"video\",sources:[{src:videoSource,provider:\"youtube\"}]}:videoSource.includes(\"vimeo.com\")?instance.data.player.source={type:\"video\",sources:[{src:videoSource,provider:\"vimeo\"}]}:instance.data.player.source={type:\"video\",sources:[{src:videoSource,type:\"video/mp4\"}]}}else console.warn(\"No video URL provided\");const root=document.documentElement;properties.playing_scrubber_bar_color&&root.style.setProperty(\"--plyr-color-main\",properties.playing_scrubber_bar_color),properties.play_button_color&&(root.style.setProperty(\"--plyr-video-control-color\",properties.play_button_color),root.style.setProperty(\"--plyr-video-control-color-hover\",properties.play_button_color)),properties.progress_bar_color&&root.style.setProperty(\"--plyr-video-progress-buffered-background\",properties.progress_bar_color),properties.play_automatically&&instance.data.player.play(),properties.video_poster&&(instance.data.player.poster=properties.video_poster),properties.start_time&&(instance.data.player.currentTime=properties.start_time),properties.end_time&&instance.data.player.on(\"timeupdate\",(function(){instance.data.player.currentTime>=properties.end_time&&instance.data.player.pause()})),properties.replay_video_when_over&&instance.data.player.on(\"ended\",(function(){instance.data.player.restart()})),instance.data.player.muted=properties.muted_default,instance.data.player.currentTime=5,instance.data.player.speed=properties.video_speed,instance.data.player.on(\"timeupdate\",(function(event){const currentTime=instance.data.player.currentTime;instance.publishState(\"player_current_time\",currentTime)})),instance.publishState(\"playing\",instance.data.player.playing),instance.data.player.on(\"playing\",(function(){instance.publishState(\"playing\",!0),instance.publishState(\"paused\",!1)})),instance.publishState(\"paused\",instance.data.player.paused),instance.data.player.on(\"pause\",(function(){instance.publishState(\"paused\",!0),instance.publishState(\"playing\",!1)})),instance.publishState(\"ended\",!1),instance.data.player.on(\"ended\",(function(){instance.publishState(\"ended\",!0)}));const bufferInterval=setInterval((function(){const buffered=instance.data.player.buffered;instance.publishState(\"buffered\",buffered),1===buffered&&(instance.publishState(\"buffered\",1),clearInterval(bufferInterval))}),500);instance.data.player.on(\"canplaythrough\",(function(){instance.publishState(\"buffered\",1),clearInterval(bufferInterval)})),instance.publishState(\"seeking\",!1),instance.data.player.on(\"seeking\",(function(){instance.publishState(\"seeking\",!0)})),instance.data.player.on(\"seeked\",(function(){instance.publishState(\"seeking\",!1)})),instance.data.player.on(\"loadedmetadata\",(function(){const duration=instance.data.player.duration;instance.publishState(\"duration\",duration)})),instance.publishState(\"volume\",instance.data.player.volume),instance.data.player.on(\"volumechange\",(function(){const volume=instance.data.player.volume;instance.publishState(\"volume\",volume)})),instance.publishState(\"muted\",instance.data.player.muted),instance.data.player.on(\"volumechange\",(function(){const muted=instance.data.player.muted;instance.publishState(\"muted\",muted)})),instance.data.player.on(\"ratechange\",(function(){const speed=instance.data.player.speed;instance.publishState(\"speed\",speed)})),instance.data.player.on(\"loadedmetadata\",(function(){const ratio=instance.data.player.ratio;console.log(\"Video ratio:\",ratio),instance.publishState(\"ratio\",ratio)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AFC":{"display":"List Calculator - Basic","add_is_visible":true,"fields":{"AEx":{"caption":"List A","editor":"DynamicValue","name":"listA","rank":0,"value":"text"},"AEy":{"caption":"Operation","default_val":"Multiply","editor":"Dropdown","name":"operation1","rank":1},"AEz":{"caption":"Number or List B","editor":"DynamicValue","name":"numberOrListB","rank":2,"value":"text","optional":true}},"states":{"AFA":{"caption":"Output List (number)","initialization_code":{"fn":"function(properties,context){let result;if(\"Concatenate\"==properties.operation1)result=concatenate(properties.listA,properties.numberOrListB);else if(\"Multiply\"==properties.operation1||\"Divide\"==properties.operation1)result=multiply(
188properties.listA,properties.numberOrListB);else if(\"Add\"==properties.operation1)result=add(properties.listA,properties.numberOrListB);else{let array1=properties.listA.split(\", \").map((x=>+x));const cumulativeSum=(sum=0,value=>sum+=value);result=array1.map(cumulativeSum)}var sum;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\", \");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}function add(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Subtract\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return addTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),addArrayAndNumber(array1,multiple,array1.length)}}function addTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(array2[i]);resultingArray.push(product)}return resultingArray}function addArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(number);resultingArray.push(product)}return resultingArray}return result}"},"is_list":true,"name":"outputList","value":"number"},"AFB":{"caption":"Output List (text)","name":"outputliststring","value":"text","initialization_code":{"fn":"function(properties,context){let result;if(\"Concatenate\"==properties.operation1)result=concatenate(properties.listA,properties.numberOrListB);else if(\"Multiply\"==properties.operation1||\"Divide\"==properties.operation1)result=multiply(properties.listA,properties.numberOrListB);else if(\"Add\"==properties.operation1)result=add(properties.listA,properties.numberOrListB);else{let array1=properties.listA.split(\", \").map((x=>+x));const cumulativeSum=(sum=0,value=>sum+=value);result=array1.map(cumulativeSum)}var sum;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\", \");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}function add(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Subtract\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return addTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),addArrayAndNumber(array1,multiple,array1.length)}}function addTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(array2[i]);resultingArray.push(product)}return resultingArray}function addArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=Number(array1[i])+Number(number);resultingArray.push(product)}return resultingArray}return result}"},"is_list":true}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n\n\n}"}},"platform_type":"web"},"AFY":{"display":"List Calculator - Advanced","add_is_visible":true,"fields":{"AFF":{"caption":"List 1 - Input HTML id","name":"list_1_html_id","rank":3,"editor":"DynamicValue","value":"text","default_val":"List_1"},"AFG":{"caption":"List 2 - Input HTML id","name":"list_2_html_id","rank":4,"editor":"DynamicValue","value":"text","default_val":"List_2"},"AFH":{"caption":"List 3 - Input HTML id","name":"list_3_html_id","rank":5,"editor":"DynamicValue","value":"text","default_val":"List_3"},"AFI":{"caption":"List 4 - Input HTML id","name":"list_4_html_id","rank":6,"editor":"DynamicValue","value":"text","default_val":"List_4"},"AFJ":{"caption":"List 5 - Input HTML id","name":"list_5_html_id","rank":7,"editor":"DynamicValue","value":"text","default_val":"List_5"},"AFK":{"caption":"List 6 - Input HTML id","name":"list_6_html_id","rank":8,"editor":"DynamicValue","value":"text","default_val":"List_6"},"AFL":{"caption":"List 7 - Input HTML id","name":"list_7_html_id","rank":9,"editor":"DynamicValue","value":"text","default_val":"List_7"},"AFM":{"caption":"This element helps extract input values from repeating groups to populate the data in your charts!","name":"this_element_helps_extract_input_values_from_repeating_groups._to_use_it,_add_a_repeating_group_to_the_page","rank":0,"editor":"Label"},"AFN":{"caption":"The following HTML ids should be added to the HTML id property for inputs in repeating groups on your page","name":"the_following_html_ids_should_be_added_to_the_html_id_property_for_inputs","rank":1,"editor":"Label"},"AFO":{"caption":"For full documentation on how to use this element, visit the following URL: https://techblocksco.bubbleapps.io/advanced-list-calculators","name":"for_full_documentation_on_how_to_use_this_element,_visit_the_following_url:_https://techblocksco.bubbleapps.io/advanced-list-calculators","rank":2,"editor":"Label"}
188,"AFP":{"caption":"List 8 - Input HTML id","name":"list_8_html_id","rank":10,"editor":"DynamicValue","value":"text"}},"states":{"AFQ":{"caption":"Output List 1","name":"output_list_1","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFR":{"caption":"Output List 2","name":"output_list_2","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFS":{"caption":"Output List 3","name":"output_list_3","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFT":{"caption":"Output List 4","name":"output_list_4","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFU":{"caption":"Output List 5","name":"output_list_5","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFV":{"caption":"Output List 6","name":"output_list_6","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFW":{"caption":"Output List 7","name":"output_list_7","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AFX":{"caption":"Output List 8","name":"output_list_8","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"actions":{"AFE":{"caption":"Get Input Values","code":{"fn":"function(instance,properties,context){instance.data.getValues()}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n\n\n}"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){var props={},ctr=1;$.each(properties,(function(k,v){var id=\"List\"+ctr+\"_id\";k.includes(\"list\")&&(props[id]=v,ctr++)}));let list=props;function getValues(){if(document.getElementById(properties.list_1_html_id)||document.getElementById(properties.list_2_html_id)||document.getElementById(properties.list_3_html_id)||document.getElementById(properties.list_4_html_id)||document.getElementById(properties.list_5_html_id)||document.getElementById(properties.list_6_html_id)||document.getElementById(properties.list_7_html_id)||document.getElementById(properties.list_8_html_id)){var lists=[],ctr=1;let arryOfListItems=document.querySelectorAll(\"#\"+properties.list_1_html_id),maxNumListItems=0;for(var i=0;i<arryOfListItems.length;i++)\"none\"!=arryOfListItems[i].parentNode.style.display&&(console.log(arryOfListItems[i]),maxNumListItems++);$.each(list,(function(k,v){var values=[],display=0;$(\"[id='\"+v+\"']\").each((function(){display<maxNumListItems&&(values.push($(this).val()),display++)})),lists.push(values.join(\", \"))})),$.each(lists,(function(k,v){var output=\"output_list_\"+ctr;ctr<9&&instance.publishState(output,v),ctr++}))}else{if(!(instance.data.startTime<instance.data.timeLimit))return console.log(\"Could not find the input element in the repeating group. Make sure it is loaded on the page (set to visible)\"),null;instance.data.startTime+=50,setTimeout(getValues,50)}}instance.data.timeLimit=15e3,instance.data.startTime=0,instance.data.getValues=getValues,getValues(),$(document).on(\"change\",\".bubble-element.Input\",(function(){getValues()}));const observerFunction=undefined,observer=new MutationObserver((mutations=>{mutations.forEach((mutation=>{\"attributes\"===mutation.type&&\"style\"===mutation.attributeName&&getValues()}))})),config={childList:!0,attributes:!0,attributeFilter:[\"style\"],subtree:!0},targetElement=document.body;observer.observe(targetElement,config)}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AFv":{"display":"Screenshot Generator","property_applications":{"Border":false,"resizable":true},"add_hover_pressed":false,"add_is_visible":true,"states":{"AFu":{"caption":"Screenshot URL","name":"imageurl","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AFt":{"caption":"Screenshot URL has been generated","name":"screenshotURL_is_generated"}},"actions":{"AFn":{"caption":"Generate Screenshot URL from","code":{"fn":"function(instance,properties,context){function convertImagesToDataURIs(element){const images=element.getElementsByTagName(\"img\"),promises=Array.from(images).map((img=>new Promise((resolve=>{img.crossOrigin&&\"anonymous\"===img.crossOrigin||(img.crossOrigin=\"anonymous\");const canvas=document.createElement(\"canvas\");canvas.width=img.width,canvas.height=img.height;const ctx=canvas.getContext(\"2d\");img.onload=()=>{ctx.drawImage(img,0,0,img.width,img.height),img.src=canvas.toDataURL(\"image/png\"),resolve()},img.onerror=()=>resolve()}))));return Promise.all(promises)}let html2canvasOptions,screenshotElement,scale=properties.scale<0?1:properties.scale;if(instance.data.format=properties.file_format||\".png\",\"Current Screen\"===properties.screenshottargetelement)screenshotElement=document.body,html2canvasOptions={x:window.scrollX,y:window.scrollY,width:window.innerWidth,height:window.innerHeight,useCORS:!0,allowTaint:!1,scale:scale};else if(\"Entire Page\"===properties.screenshottargetelement){screenshotElement=document.body;const fullWidth=document.documentElement.scrollWidth,fullHeight=document.documentElement.scrollHeight;html2canvasOptions={width:fullWidth,height:fullHeight,useCORS:!0,allowTaint:!1,scale:scale}}else if(\"Specific Element\"===properties.screenshottargetelement){screenshotElement=document.getElementById(properties.element_html_id);const elementRect=screenshotElement.getBoundingClientRect();html2canvasOptions={x:elementRect.left+window.scrollX,y:elementRect.top+window.scrollY,width:elementRect.width,height:elementRect.height,useCORS:!0,allowTaint:!1,scale:scale}}convertImagesToDataURIs(screenshotElement).then((()=>{html2canvas(screenshotElement,html2canvasOptions).then((function(canvas){instance.data.canvasScreenshot=canvas,instance.data.saveImage(properties.filename)}))}
188))}"},"fields":{"AFo":{"caption":"File Name","name":"filename","rank":0,"editor":"DynamicValue","value":"text","default_val":"myscreenshot"},"AFp":{"caption":"Screenshot Mode","name":"screenshottargetelement","rank":1,"editor":"Dropdown","default_val":"Current Screen"},"AFq":{"caption":"Element ID Attribute (if \"Specific Element\" selected)","name":"element_html_id","rank":2,"editor":"DynamicValue","value":"text","optional":true},"AFr":{"caption":"File Format","name":"file_format","rank":3,"editor":"Dropdown","default_val":".png"},"AFs":{"caption":"Scale/Resolution","name":"scale","rank":4,"editor":"DynamicValue","value":"number","default_val":1}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Image Generator - Make this element 1px tall & 1px wide to hide it';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"},"initialize":{"fn":"function(instance,context){function uploadContentCallback(err,url){url?(instance.publishState(\"imageurl\",url),instance.triggerEvent(\"screenshotURL_is_generated\",(function(err){}))):console.error(\"Screenshot Plugin\",\"Error on uploadContent:\",err)}function saveImage(fileName){let imageData=instance.data.canvasScreenshot.toDataURL(),imageDataPng=imageData.substring(imageData.indexOf(\",\")+1);context.uploadContent(fileName+instance.data.format,imageDataPng,instance.data.uploadContentCallback)}instance.data.uploadContentCallback=uploadContentCallback,instance.data.saveImage=saveImage}"},"update":{"fn":"function(instance,properties,context){instance.data.captureEntirePage=properties.capture_entire_page}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AGT":{"display":"Beautiful Toggle","property_applications":{"resizable":true},"add_is_visible":true,"support_autobinding":false,"autobinding_value":"boolean","has_reset_fn":true,"fields":{"AGA":{"caption":"Transition Time","name":"toggle_transition_time","rank":3,"editor":"DynamicValue","value":"number","default_val":0.4},"AGB":{"caption":"Color (\"Yes\")","name":"toggle_background_color_yes","rank":6,"editor":"Color","default_val":"rgba(51, 212, 118, 1)"},"AGC":{"caption":"Color (\"No\")","name":"toggle_background_color_no","rank":5,"editor":"Color","default_val":"rgba(235, 235, 235, 1)"},"AGD":{"caption":"Preset Status","name":"preset_status","rank":1,"editor":"DynamicValue","value":"boolean","default_val":false},"AGE":{"caption":"Handle Color (\"No\")","name":"handle_color","rank":11,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","in_style":false},"AGF":{"caption":"Roundness","name":"toggle_roundness","rank":7,"editor":"DynamicValue","value":"number","default_val":500},"AGG":{"caption":"Handle Roundness","name":"handle_roundness","rank":10,"editor":"DynamicValue","value":"number","default_val":500},"AGH":{"caption":"Width (Custom)","name":"toggle_width_custom","rank":8,"editor":"DynamicValue","value":"number","optional":true},"AGI":{"caption":"Width (Optional)","name":"handle_width","rank":13,"editor":"DynamicValue","value":"number","optional":true},"AGJ":{"caption":"Shadow Color","name":"handle_shadow_color","rank":14,"editor":"Color","default_val":"rgba(0, 0, 0, 0.41)","in_style":false},"AGK":{"caption":"-------------------------- Handle Options --------------------------","name":"----------_handle_options_----------","rank":9,"editor":"Label"},"AGL":{"caption":"------------------- Toggle Container Options -------------------","name":"----------_outer_toggle_options_----------","rank":4,"editor":"Label"},"AGM":{"caption":"------------------------ General Options ------------------------","name":"---------------_general_options_options_---------------","rank":0,"editor":"Label"},"AGN":{"caption":"Shadow V Offset","name":"handle_shadow_y_offset","rank":15,"editor":"DynamicValue","value":"number","default_val":0},"AGO":{"caption":"Shadow Blur Radius","name":"handle_shadow_blur_radius","rank":17,"editor":"DynamicValue","value":"number","default_val":6},"AGP":{"caption":"Shadow H Offset","name":"handle_shadow_x_offset","rank":16,"editor":"DynamicValue","value":"number","default_val":0},"AGQ":{"caption":"Handle Color (\"Yes\")","name":"handle_color_yes","rank":12,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AGR":{"caption":"Disabled?","name":"disabled","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false}},"states":{"AGS":{"caption":"value","name":"value","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AFz":{"caption":"value is changed","name":"value_is_changed"}},"actions":{"AFx":{"caption":"Change Toggle Value","code":{"fn":"function(instance,properties,context){instance.triggerEvent(\"value_is_changed\",(function(err){})),properties.value_to_change_to?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=properties.handle_color_yes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",instance.data.latestToggleValue=!0,instance.publishState(\"value\",!0)):properties.value_to_change_to||(instance.data.handleElement.style.backgroundColor=properties.handle_color,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.transform=\"translate(0px)\",instance.data.latestToggleValue=!1,instance.publishState(\"value\",!1))}"},"fields":{"AFy":{"caption":"Value to Change To","name":"value_to_change_to","rank":0,"editor":"DynamicValue","value":"boolean"}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n //add the items to the page\
188n let uniqueSwitchID = \"switch\" + Math.floor(Math.random()*1000000).toString();\n let uniqueCheckboxID = \"checkbox\" + Math.floor(Math.random()*100000).toString();\n\tlet uniqueToggleID = \"toggle\" + Math.floor(Math.random()*100000).toString();\n \tlet uniqueHandleID = \"handle\" + Math.floor(Math.random()*100000).toString();\n \n let myDiv = '<div id=\"'+ uniqueSwitchID +'\"><input id=' + uniqueCheckboxID + ' type=\"checkbox\"><span id=\"' + uniqueToggleID + '\"><div id=\"' + uniqueHandleID + '\"></div></span></label>';\n instance.canvas.append(myDiv);\n \n \n\n let switchContainer = document.getElementById(uniqueSwitchID);\n let checkboxElement = document.getElementById(uniqueCheckboxID);\n let toggleElement = document.getElementById(uniqueToggleID);\n let handleElement = document.getElementById(uniqueHandleID);\n \n \t//instance.canvas.style.overflow = \"hidden\";\n //instance.canvas.isResponsive = false;\n \n \n /**************** TOGGLE (container for handle): set styles ****************/\n toggleElement.style.borderRadius=properties.toggle_roundness + \"px\";\n\tlet toggleWidth = properties.bubble.height()*1.76;\n if(properties.toggle_width_custom){\n \ttoggleWidth = properties.toggle_width_custom; \n };\n toggleElement.style.position = \"absolute\";\n toggleElement.style.cursor = \"pointer\";\n toggleElement.style.top = 0;\n toggleElement.style.left = 0;\n toggleElement.style.right = 0;\n toggleElement.style.bottom = 0;\n toggleElement.style.transition = \".4s\"; \n \n\n \n /**************** HANDLE: set styles ****************/\n let handleLength = properties.bubble.height() * 0.8;\n let handleBuffer = (properties.bubble.height() - handleLength)/2;\n \n handleElement.style.left = handleBuffer + \"px\";\n handleElement.style.bottom = handleBuffer + \"px\";\n handleElement.style.height = handleLength + \"px\";\n handleElement.style.width = handleLength + \"px\";\n if(properties.handle_width){\n \thandleElement.style.width = properties.handle_width + \"px\";\n };\n handleElement.style.backgroundColor = properties.handle_color;\n handleElement.style.borderRadius = properties.handle_roundness + \"px\";\n handleElement.style.boxShadow = properties.handle_shadow_x_offset+\"px \"+ properties.handle_shadow_y_offset+\"px \"+properties.handle_shadow_blur_radius+\"px \"+properties.handle_shadow_color;//\"0px 0px 6px \" + properties.handle_shadow_color;//rgba(0,0,0,0.5)\";\n let handleTranslateDistance = (toggleWidth - (2*handleBuffer) - handleLength);\n if(properties.handle_width){\n \thandleTranslateDistance = (toggleWidth - (2*handleBuffer) - properties.handle_width);\n };\n handleElement.style.position = \"absolute\";\n handleElement.style.transition = \"0.4s\";\n \n /**************** SWITCH: set styles (this is outermost element) ****************/\n switchContainer.style.height = properties.bubble.height()+\"px\";\n switchContainer.style.width = toggleWidth + \"px\";\n switchContainer.style.position = \"relative\";\n switchContainer.style.display = \"inline-block\";\n \n \n /**************** CHECKBOX: set styles (this is checkbox element) ****************/\n checkboxElement.style.opacity = 0;\n checkboxElement.style.width = 0;\n checkboxElement.style.height = 0;\n \n \n \n \n \n \tif(properties.preset_status) { //Set default toggle color based on preset status\n toggleElement.style.backgroundColor=properties.toggle_background_color_yes;\n handleElement.style.backgroundColor = properties.handle_color_yes;\n\t\thandleElement.style.transform=\"translate(\" + handleTranslateDistance + \"px)\";\n } else {\n toggleElement.style.backgroundColor=properties.toggle_background_color_no;\n handleElement.style.backgroundColor = properties.handle_color;\n handleElement.style.transform=\"translate(0px)\";\n };\n \n instance.data.toggleElement = toggleElement;\n instance.data.handleElement = handleElement;\n instance.data.preset_status = properties.preset_status;\n\n\t\n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueSwitchID=\"switch\"+Math.floor(1e6*Math.random()).toString(),instance.data.uniqueCheckboxID=\"checkbox\"+Math.floor(1e5*Math.random()).toString(),instance.data.uniqueToggleID=\"toggle\"+Math.floor(1e5*Math.random()).toString(),instance.data.uniqueHandleID=\"handle\"+Math.floor(1e5*Math.random()).toString();let myDiv='<label onclick=\"event.stopPropagation()\" class=\"togglecheckbox\" id=\"'+instance.data.uniqueSwitchID+'\"><input id='+instance.data.uniqueCheckboxID+' type=\"checkbox\"><span id=\"'+instance.data.uniqueToggleID+'\"><div id=\"'+instance.data.uniqueHandleID+'\"></div></span></label>';instance.canvas.append(myDiv)}"},"update":{"fn":"function(instance,properties,context){$(document).ready((function(){instance.data.switchContainer=document.getElementById(instance.data.uniqueSwitchID),instance.data.checkboxElement=document.getElementById(instance.data.uniqueCheckboxID),instance.data.toggleElement=document.getElementById(instance.data.uniqueToggleID),instance.data.handleElement=document.getElementById(instance.data.uniqueHandleID),instance.data.listenerAdded||(instance.data.checkboxElement.addEventListener(\"change\",(function(event){properties.disabled||(document.getElementById(instance.data.uniqueCheckboxID).checked?(instance.data.latestToggleValue=!0,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=properties.handle_color_yes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",instance.publishState(\"value\",!0)):(instance.data.latestToggleValue=!1,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.backgroundColor=properties.handle_color,instance.data.handleElement.style.transform=\"translate(0px)\",instance.publishState(\"value\",!1)),instance.triggerEvent(\"value_is_changed\",(function(err){})))})),instance.data.listenerAdded=!0),instance.data.toggleElement.style.borderRadius=properties.toggle_roundness+\"px\",instance.data.backgroundColorNo=properties.toggle_background_color_no,instance.data.backgroundColorYes=properties.toggle_background_color_yes,instance.data.toggleWidth=1.76*properties.bubble.height(),instance.data.handleColorYes=properties.handle_color_yes,instance.data.handleColorNo=properties.handle_color,properties.toggle_width_custom&&(instance.data.toggleWidth=properties.toggle_width_custom),instance.data.toggleElement.style.position=\"absolute\",instance.data.toggleElement.style.cursor=\"pointer\",instance.data.toggleElement.style.top=0,instance.data.toggleElement.style.left=0,instance.data.toggleElement.style.right=0,instance.data.toggleElement.style.bottom=0,instance.data.toggleElement.style.transition=properties.toggle_transition_time+\"s\",instance.data.handleLength=.8*properties.bubble.height(),instance.data.handleBuffer=(properties.bubble.height()-instance.data.handleLength)/2,instance.data.handleElement.style.left=instance.data.handleBuffer+\"px\",instance.data.handleElement.style.bottom=instance.data.handleBuffer+\"px\",instance.data.handleElement.style.height=instance.data.handleLength+\"px\",instance.data.handleElement.style.width=instance.data.handleLength+\"px\",properties.handle_width&&(instance.data.handleElement.style.width=properties.handle_width+\"px\"),instance.data.handleElement.style.backgroundColor=properties.handle_color,1==properties.preset_status&&(instance.data.handleElement.style.backgroundColor=properties.handle_color_yes),instance.data.handleElement.style.borderRadius=properties.handle_roundness+\"px\",instance.data.handleElement.style.boxShadow=properties.handle_shadow_x_offset+\"px \"+properties.handle_shadow_y_offset+\"px \"+properties.handle_shadow_blur_radius+\"px \"+properties.handle_shadow_color,instance.data.handleTranslateDistance=instance.data.toggleWidth-2*instance.data.handleBuffer-instance.data.handleLength,properties.handle_width&&(instance.data.handleTranslateDistance=instance.data.toggleWidth-2*instance.data.handleBuffer-properties.handle_width),instance.data.handleElement.style.position=\"absolute\",instance.data.handleElement.style.transition=properties.toggle_transition_time+\"s\",instance.data.switchContainer.style.height=properties.bubble.height()+\"px\",instance.data.switchContainer.style.width=instance.data.toggleWidth+\"px\",instance.data.switchContainer.style.position=\"relative\",instance.data.switchContainer.style.display=\"inline-block\",instance.data.checkboxElement.style.opacity=0,instance.data.checkboxElement.style.width=0,instance.data.checkboxElement.style.height=0,1==instance.data.latestToggleValueSet?instance.data.latestToggleValue?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",document.getElementById(instance.data.uniqueCheckboxID).checked=!0):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,document.getElementById(instance.data.uniqueCheckboxID).checked=!1,instance.data.handleElement.style.transform=\"translate(0px)\"):properties.preset_status?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",document.getElementById(instance.data.uniqueCheckboxID).checked=!0,instance.data.latestToggleValue=!0):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,document.getElementById(instance.data.uniqueCheckboxID).checked=!1,instance.data.handleElement.style.transform=\"translate(0px)\",instance.data.latestToggleValue=!1),instance.publishState(\"value\",document.getElementById(instance.data.uniqueCheckboxID).checked)}))}"},"reset":{"fn":"function(instance,context){function runReset(){instance.data.preset_status?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=instance.data.handleColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\"):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.backgroundColor=instance.data.handleColorNo,instance.data.handleElement.style.transform=\"translate(0px)\")}instance.data.toggleElement&&instance.data.handleElement&&runReset()}"}},"platform_type":"web"}
188,"AGd":{"display":"Background Colorer","property_applications":{"resizable":false},"add_is_visible":true,"fields":{"AGW":{"caption":"Background Color","name":"color","rank":0,"editor":"Color","default_val":"rgba(168, 168, 168, 1)"},"AGX":{"caption":"Documentation Link (for your convenience)","name":"documentation_link","rank":2,"editor":"StaticText","default_val":"https://docs.techblocksco.com/?tab=Set-Page-Background-Color&instructions=yes"},"AGY":{"caption":"---------------------------------------------------------------------------","name":"-----------------------------------","rank":1,"editor":"Label"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n}"},"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){let bodyElement;document.getElementsByTagName(\"BODY\")[0].style.backgroundColor=properties.color}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}},"plugin_actions":{"AGV":{"display":"Set Context Menu Group","type":"client_side","fields":{"AGU":{"caption":"Context Menu HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text","default_val":""}},"code":{"client":{"fn":"function(properties,context){let htmlId=\"#\"+properties.html_id;$(document).ready((function($){$(htmlId).css({display:\"none\",\"z-index\":\"1000000000001\"}),document.addEventListener(\"contextmenu\",(function(e){e.preventDefault();var scroll=$(window).scrollTop(),relX=e.pageX-$(this).offset().left+15,relY=e.pageY-$(this).offset().top+5-scroll;$(htmlId).fadeIn(200).css({position:\"fixed\",top:relY,left:relX})}),!1),document.addEventListener(\"scroll\",(function(e){$(htmlId).fadeOut(200)}),!1),$(window).on(\"click\",(function(){$(htmlId).fadeOut(200)})),$(htmlId).on(\"click\",(function(e){e.stopPropagation()}))}))}"}}}}}; 189window._bubble_page_load_data.plugins_size['1583096521531x455947381906866200'] = 67456; 190window.preloaded['plugin/third_party:1583096521531x455947381906866200:1.1.38'] = true; 191window.plugins["1585773166741x344001413254479900"] = {"human":"Premium Video Player","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"ACR":{"display":"Feedback Widget","property_applications":{"Border":false,"resizable":false,"MinWidth":false,"Font":true},"add_is_visible":true,"fields":{"ACV":{"caption":"Default Button Color","name":"main_button_color","rank":1,"editor":"Color","default_val":"rgba(2, 132, 254, 1)"},"ACg":{"caption":"Show Default Buttons?","name":"show_default_feedback_tab","rank":0,"editor":"DynamicValue","value":"boolean","default_val":true},"ACj":{"caption":"Open Feedback Text","name":"button_text_open_feedback","rank":2,"editor":"DynamicValue","value":"text","default_val":"Feedback"},"ACk":{"caption":"Close Feedback Text","name":"button_text_close_feedback","rank":3,"editor":"DynamicValue","value":"text","default_val":"Close"},"ACl":{"caption":"Submit Feedback Text","name":"button_text_submit_feedback","rank":4,"editor":"DynamicValue","value":"text","default_val":"SUBMIT"},"ACm":{"caption":"Placeholder Text - Feedback Input","name":"feedback_input_placeholder","rank":5,"editor":"DynamicValue","value":"text","default_val":"Enter your comment here..."},"ACq":{"caption":"Custom Button HTML id","name":"custom_button_html_id","rank":6,"editor":"DynamicValue","value":"text","optional":true},"ACv":{"caption":"File Format","name":"file_format","rank":7,"editor":"Dropdown","default_val":".png"}},"states":{"ACU":{"caption":"Feedback Screenshot URL","name":"imageurl","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ACY":{"caption":"Feedback Text","name":"textfeedback","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ACZ":{"caption":"Browser & Operating System","name":"browserAndOS","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"ACc":{"caption":"Screen Width","name":"screenWidth","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ACd":{"caption":"Screen Height","name":"screenHeight","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ACo":{"caption":"Feedback Mode On?","name":"feedback_mode_on","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ACT":{"caption":"Generated a Feedback Screenshot","name":"screenshotURL_is_generated"}},"actions":{"ACS":{"caption":"Open Feedback Screenshot View","code":{"fn":"function(instance,properties,context){instance.data.fabricCanvas.add(instance.data.mainbackground),instance.data.fabricCanvas.hoverCurs
191or=\"crosshair\",instance.data.openBugshot(),instance.data.feedbackButton.style.display=\"none\",document.getElementById(\"annotationInput\")&&instance.data.removeElement(\"annotationInput\")}"}},"ACn":{"caption":"Close Feedback Screenshot View","code":{"fn":"function(instance,properties,context){instance.data.closeBugshot()}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n\n let icon = '<img id=\"cancelIcon\" class=\"buttonShadows\" src=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1586642877986x171178841879218620/Screen%20Shot%202020-04-11%20at%2012.46.37%20PM.png\" style=\"cursor: pointer; position: absolute; left: 0px; left: 0px; background-color: rgb(255,255,255,0.65); z-index: 1; height: 35px; width: 35px\">';\n instance.canvas.append(icon);\n\n}"},"initialize":{"fn":"function(instance,context){function removeElement(elementId){var element=document.getElementById(elementId);element.parentNode.removeChild(element)}instance.data.removeElement=removeElement;let mybackground='<div id=\"bugShotBackground\" class=\"bugshotbackground\"><div style=\"position: fixed; height: 100%; width: 100%;\"></div></div>';instance.canvas.append(mybackground),instance.data.mainContainer=document.getElementById(\"bugShotBackground\"),instance.data.mainContainer.style.display=\"none\";let fabricCanvasParentHTML='<canvas id=\"fabricCanvasParent\"\"></canvas>';instance.canvas.append(fabricCanvasParentHTML),instance.data.fabricCanvasParent=document.getElementById(\"fabricCanvasParent\"),instance.data.mainContainer.appendChild(instance.data.fabricCanvasParent),document.body.appendChild(instance.data.mainContainer),instance.data.fabricCanvas=new fabric.Canvas(\"fabricCanvasParent\");let mainbackground=new fabric.Rect({width:1e4,height:1e4,fill:\"rgb(0,0,0,0)\",left:-10,top:-10,selectable:!1});function noScroll(){\"block\"==instance.data.mainContainer.style.display&&window.scrollTo(0,instance.data.scrollY)}function openBugshot(){document.getElementById(\"annotationInput\")&&document.getElementById(\"annotationInput\").remove(),instance.data.mainContainer.style.display=\"block\",instance.data.scrollY=document.documentElement.scrollTop,window.addEventListener(\"scroll\",noScroll),instance.data.feedbackButton.style.display=\"none\",document.getElementById(instance.data.customButtonId)&&(instance.data.floater=document.getElementById(instance.data.customButtonId),instance.data.originalFloaterParent=instance.data.floater.parentElement,instance.data.floater.style.zIndex=1e23,instance.data.mainContainer.appendChild(instance.data.floater)),instance.publishState(\"feedback_mode_on\",!0)}function closeBugshot(){instance.data.mainContainer.style.display=\"none\",instance.data.feedbackButton.style.display=\"flex\",instance.data.fabricCanvas.clear(),instance.data.createdBug=!1,window.removeEventListener(\"scroll\",noScroll),document.getElementById(instance.data.customButtonId)&&instance.data.originalFloaterParent.appendChild(instance.data.floater),instance.publishState(\"feedback_mode_on\",!1)}instance.data.mainbackground=mainbackground,window.addEventListener(\"resize\",(function(){\"block\"==instance.data.mainContainer.style.display&&instance.data.fabricCanvas.setDimensions({width:instance.data.mainContainer.offsetWidth,height:instance.data.mainContainer.offsetHeight})})),instance.data.openBugshot=openBugshot,instance.data.closeBugshot=closeBugshot;let feedbackButton='<div class=\"buttonShadows\" id=\"feedbackbuttoncontainer\"></div>';instance.canvas.append(feedbackButton),instance.data.feedbackButton=document.getElementById(\"feedbackbuttoncontainer\"),document.body.appendChild(instance.data.feedbackButton),instance.data.feedbackButton.onclick=function(){instance.data.fabricCanvas.add(mainbackground),instance.data.fabricCanvas.hoverCursor=\"crosshair\",instance.data.openBugshot()};let closeButton='<div class=\"buttonShadows\" id=\"closeicon\"\"><p id=\"closeicontext\" style=\"position: absolute; top: 45%; left: -15%; color: white; transform: rotate(270deg)\"></p></div>',html2canvasOptions,screenshotElement;function uploadContentCallback(err,url){url?(instance.publishState(\"imageurl\",url),instance.triggerEvent(\"screenshotURL_is_generated\",(function(err){}))):console.error(\"Screenshot Plugin\",\"Error on uploadContent:\",err)}function saveImage(fileName){let imageData=instance.data.canvasScreenshot.toDataURL(),imageDataPng=imageData.substring(imageData.indexOf(\",\")+1);context.uploadContent(fileName+instance.data.file_format,imageDataPng,instance.data.uploadContentCallback)}function captureScreenshot(){instance.data.scrollPositionTop=document.documentElement.scrollTop,instance.data.scrollPositionLeft=0,document.documentElement.scrollLeft&&(instance.data.scrollPositionLeft=document.documentElement.scrollLeft),html2canvasOptions={x:instance.data.scrollPositionLeft,y:instance.data.scrollPositionTop,width:instance.data.mainContainer.offsetWidth,height:instance.data.mainContainer.offsetHeight,useCORS:!1,allowTaint:!0,proxy:\"https://www.techblocksproxy.com:80\",ignoreElements:function(element){let bubbleImage;if(element==screenshotElement.querySelectorAll(\"img[src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1585607370503x914556455591480200/banner-icon.svg']\")[0])return!0}},screenshotElement=document.body,instance.data.deleteAndSendContainer=document.getElementById(\"deleteAndSendContainer\"),instance.data.deleteAndSendContainer.remove();let replacementAnnotationText=document.createElement(\"p\");replacementAnnotationText.class=\"buttonShadows\",replacementAnnotationText.style.backgroundColor=\"white\",replacementAnnotationText.style.width=\"90%\",replacementAnnotationText.style.height=\"64%\",replacementAnnotationText.style.fontSize=\"14px\",replacementAnnotationText.style.color=\"rgb(0,0,0,0.8)\",replacementAnnotationText.style.border=\"1px solid rgb(0,0,0,0.3)\",replacementAnnotationText.style.borderRadius=\"4px\",replacementAnnotationText.style.wordWrap=\"break-word\",replacementAnnotationText.style.position=\"absolute\",replacementAnnotationText.style.top=\"0px\",replacementAnnotationText.style.right=\"0px\",replacementAnnotationText.style.padding=\"8px 8px\",replacementAnnotationText.innerHTML=instance.data.feedbackTextInput.value,instance.data.annotationInput.appendChild(replacementAnnotationText),instance.data.feedbackTextInput.remove(),html2canvas(screenshotElement,html2canvasOptions).then((function(canvas){instance.data.canvasScreenshot=canvas,instance.data.saveImage(\"myscreenshot\")})),instance.data.annotationInput.remove()}function captureFeedbackText(text){instance.publishState(\"textfeedback\",text)}function captureBrowserInfo(){instance.publishState(\"browserAndOS\",platform.toString()),instance.publishState(\"screenWidth\",screen.width),instance.publishState(\"screenHeight\",screen.height)}function captureMouseDownCoordinates(){instance.data.mouseDownX=instance.data.fabricCanvas.getPointer().x,instance.data.mouseDownY=instance.data.fabricCanvas.getPointer().y,console.log(\"mouse down at: \"+instance.data.mouseDownX+\", \"+instance.data.mouseDownY)}
191function createText(text,x,y,inputWidth,inputHeight){let annotationInput='<div id=\"annotationInput\" style=\"position: absolute; width:'+inputWidth+\"px; height: \"+inputHeight+'px\"><textarea id= \"feedbackTextInput\" class=\"buttonShadows\" placeholder=\"Enter your comment here...\" style=\"font-size: 16px; color: rgb(0,0,0,0.8); border: 0px solid rgb(0,0,0,0.5); width: 90%; height: 64%\"></textarea><div id=\"deleteAndSendContainer\" style=\"position: absolute; bottom: 0%; right: 0%; background-color: rgb(0,0,0,0.0); height: 40px; width: '+inputWidth+'px\"><div id=\"submitButtonContainer\" class=\"buttonShadows\" style=\"background-color:'+instance.data.buttonColors+'\";><p id=\"submitButtonText\" style=\"position:relative; top: 30%; text-align: center; color: white; display: flex; justify-content: center; align-items: center;\"> SUBMIT </p></div><img id=\"cancelIcon\" class=\"buttonShadows\" src=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1586378106755x750024867936166300/delete.svg\" style=\"cursor: pointer; position: absolute; right: 0px; top: 0%; background-color: rgb(255,255,255,0.65); border-radius: 3px; padding: 4px 4px; z-index: 1; height: 35px; width: 35px\"></div></div>';instance.canvas.append(annotationInput),instance.data.submitButtonText=document.getElementById(\"submitButtonText\"),instance.data.submitButtonText.innerHTML=instance.data.submitButtonTextString,instance.data.feedbackTextInput=document.getElementById(\"feedbackTextInput\"),instance.data.feedbackTextInput.placeholder=instance.data.placeholderTextInput,instance.data.annotationInput=document.getElementById(\"annotationInput\"),instance.data.mainContainer.appendChild(instance.data.annotationInput),instance.data.submitButtonContainer=document.getElementById(\"submitButtonContainer\"),instance.data.cancelIcon=document.getElementById(\"cancelIcon\"),instance.data.submitButtonContainer.onclick=function(){captureScreenshot(),captureBrowserInfo(),captureFeedbackText(instance.data.feedbackTextInput.value),instance.data.closeBugshot()},instance.data.cancelIcon.onclick=function(){removeElement(\"annotationInput\"),instance.data.fabricCanvas.clear(),instance.data.createdBug=!1,instance.data.fabricCanvas.add(mainbackground),instance.data.fabricCanvas.hoverCursor=\"crosshair\"},instance.data.annotationInput.style.left=x+\"px\",instance.data.annotationInput.style.top=y+\"px\"}function createShape(x,y,shapeHeight,shapeWidth){let rect=new fabric.Rect({width:shapeWidth,height:shapeHeight,fill:\"rgba(0,0,0,0)\",left:x,top:y,stroke:\"#FFFFFF\",strokeWidth:4,selectable:!1});instance.data.fabricCanvas.add(rect);let inputWidth=300,inputHeight=175,defaultX=x+shapeWidth+10,defaultY=y+.3*shapeHeight-20;defaultX+300>instance.data.mainContainer.offsetWidth&&(defaultX=x-300-25),defaultY+175>instance.data.mainContainer.offsetHeight&&(defaultY=y-175),defaultY<0&&(defaultY=15),x-300-25<0&&(defaultX=10,defaultY=y+shapeHeight+10,defaultY+175>instance.data.mainContainer.offsetHeight&&(defaultY=y-175-30)),instance.data.createText(\"Enter your bug details here...\",defaultX,defaultY,300,175),instance.data.createdBug=!0}function createShapeOnMouseUp(){instance.data.mouseUpX=instance.data.fabricCanvas.getPointer().x,instance.data.mouseUpY=instance.data.fabricCanvas.getPointer().y;let width=Math.round(Math.abs(instance.data.mouseUpX-instance.data.mouseDownX)),height=Math.round(Math.abs(instance.data.mouseUpY-instance.data.mouseDownY)),xCoord,yCoord;xCoord=instance.data.mouseDownX<instance.data.mouseUpX?instance.data.mouseDownX:instance.data.mouseUpX,yCoord=instance.data.mouseDownY<instance.data.mouseUpY?instance.data.mouseDownY:instance.data.mouseUpY,instance.data.createShape(xCoord,yCoord,height,width)}instance.canvas.append(closeButton),instance.data.closeIcon=document.getElementById(\"closeicon\"),instance.data.closeIconText=document.getElementById(\"closeicontext\"),instance.data.mainContainer.appendChild(instance.data.closeIcon),instance.data.closeIcon.onclick=function(){instance.data.closeBugshot()},instance.data.uploadContentCallback=uploadContentCallback,instance.data.saveImage=saveImage,instance.data.captureMouseDownCoordinates=captureMouseDownCoordinates,instance.data.createText=createText,instance.data.createShape=createShape,instance.data.createShapeOnMouseUp=createShapeOnMouseUp,instance.data.fabricCanvas.on(\"mouse:down\",(function(options){instance.data.captureMouseDownCoordinates()})),instance.data.fabricCanvas.on(\"mouse:up\",(function(options){instance.data.createdBug||(instance.data.createShapeOnMouseUp(),instance.data.fabricCanvas.hoverCurs
191or=\"auto\")}))}","add_debugger":false},"update":{"fn":"function(instance,properties,context){instance.data.feedbackButton.style.backgroundColor=properties.main_button_color,instance.data.closeIcon.style.color=properties.main_button_color,instance.data.customButtonId=properties.custom_button_html_id,instance.data.feedbackButton.innerHTML=properties.button_text_open_feedback,instance.data.closeIcon.innerHTML=properties.button_text_close_feedback,instance.data.submitButtonTextString=properties.button_text_submit_feedback,instance.data.placeholderTextInput=properties.feedback_input_placeholder,instance.data.buttonColors=properties.main_button_color,instance.data.file_format=properties.file_format,properties.show_default_feedback_tab?(document.body.appendChild(instance.data.feedbackButton),instance.data.mainContainer.appendChild(instance.data.closeIcon)):(instance.data.feedbackButton.remove(),instance.data.closeIcon.remove()),instance.data.fabricCanvas.setHeight(window.innerHeight),instance.data.fabricCanvas.setWidth(window.innerWidth)}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"ACw":{"display":"Video Player","property_applications":{"resizable":true,"MinWidth":true,"Background":true,"Border":true,"Padding":true,"BoxShadow":true,"Font":true},"add_is_visible":true,"add_large_file_upload_properties":false,"can_fit_width":true,"can_fit_height":true,"fields":{"ACx":{"caption":"Video URL","name":"video_url","rank":1,"editor":"DynamicValue","value":"file","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734116151820x132671698403852280/sample_960x400_ocean_with_audio.mp4"},"ACy":{"caption":"Play Automatically?","name":"play_automatically","rank":10,"editor":"DynamicValue","value":"boolean","default_val":false},"ACz":{"caption":"Thumbnail Image","name":"video_poster","rank":8,"editor":"DynamicValue","value":"image","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734129624872x833500003703271800/Screenshot%202024-12-13%20at%202.35.21%E2%80%AFPM.png"},"ADA":{"caption":"Video Speed","name":"video_speed","rank":13,"editor":"DynamicValue","value":"number","default_val":1},"ADC":{"caption":"Show FullScreen Btn?","name":"show_full_screen_button","rank":17,"editor":"DynamicValue","value":"boolean","default_val":true},"ADD":{"caption":"Loop Video?","name":"replay_video_when_over","rank":14,"editor":"DynamicValue","value":"boolean","default_val":false},"ADE":{"caption":"Playing - Scrub Bar Color","name":"playing_scrubber_bar_color","rank":4,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"ADF":{"caption":"Play Button Color","name":"play_button_color","rank":5,"editor":"Color","default_val":"rgba(255,255,255,1)"},"ADG":{"caption":"Progress Bar Color","name":"progress_bar_color","rank":6,"editor":"Color","default_val":"rgba(255,255,255,0.3)"},"ADH":{"caption":"Disable Control Bar?","name":"disable_control_bar","rank":18,"editor":"DynamicValue","value":"boolean","default_val":false},"ADI":{"caption":"Start Time","name":"start_time","rank":12,"editor":"DynamicValue","value":"number","optional":true},"ADK":{"caption":"--------------------------------- Colors ---------------------------------","name":"-------------_colors_-------------","rank":3,"editor":"Label"},"ADL":{"caption":"-------------------------- Control Options ---------------------------","name":"-------------_buttons_-------------","rank":16,"editor":"Label"},"ADM":{"caption":"----------------------- Default Play Options -----------------------","name":"--------------------------_play_options_---------------------------","rank":9,"editor":"Label"},"ADN":{"caption":"--------------------- Video Thumbnail/Poster --------------------Video Thumbnail/Poster Image that is shown before the video starts while is it not playing","name":"--------------------------_video_thumbnail_---------------------------","rank":7,"editor":"Label"},"ADP":{"caption":"Show Play Button?","name":"play","rank":19,"editor":"DynamicValue","value":"boolean","default_val":true},"ADQ":{"caption":"Show Progress Slider?","name":"progress","rank":20,"editor":"DynamicValue","value":"boolean","default_val":true},"ADR":{"caption":"Show Current Time?","name":"current_time","rank":21,"editor":"DynamicValue","value":"boolean","default_val":true},"ADS":{"caption":"Show Mute Button?","name":"mute","rank":22,"editor":"DynamicValue","value":"boolean","default_val":true}
191,"ADT":{"caption":"Show Volume Slider?","name":"volume","rank":23,"editor":"DynamicValue","value":"boolean","default_val":true},"ADU":{"caption":"Show Captions?","name":"captions","rank":24,"editor":"DynamicValue","value":"boolean","default_val":true},"ADV":{"caption":"Show Settings Menu?","name":"settings","rank":28,"editor":"DynamicValue","value":"boolean","default_val":true},"ADW":{"caption":"Show PIP Button?","name":"pip","rank":25,"editor":"DynamicValue","value":"boolean","default_val":true},"ADX":{"caption":"Show Airplay Btn?","name":"airplay","rank":26,"editor":"DynamicValue","value":"boolean","default_val":true},"ADY":{"caption":"Quality","name":"quality","rank":29,"editor":"DynamicValue","value":"boolean","default_val":true},"ADZ":{"caption":"Speed","name":"speed","rank":30,"editor":"DynamicValue","value":"boolean","default_val":true},"ADa":{"caption":"Loop","name":"loop","rank":31,"editor":"DynamicValue","value":"boolean","default_val":true},"ADb":{"caption":"--------------------------- Settings Menu ----------------------------","name":"----------------------------_settings_menu_-----------------------------","rank":27,"editor":"Label"},"ADc":{"caption":"Muted by default?","name":"muted_default","rank":15,"editor":"DynamicValue","value":"boolean","default_val":false},"AFI":{"caption":"â ï¸ Bubble doesn't allow you to upload files larger than 25MB, so for videos >25MB, you will need to store those outside of Bubble (on AWS, Google Cloud, etc)","name":"â ï¸_you_will_need_to_store_your_video_outside_of_bubble.io","rank":2,"editor":"Label"},"AFJ":{"caption":"In the input below, upload a video or insert a dynamic link that points to a video in your Bubble database:","name":"you_can_upload_a_video_or_insert_a_dynamic_link_that_points_to_a_video_in_your_bubble_database._","rank":0,"editor":"Label"},"AFP":{"caption":"â ï¸ Some browsers will not allow auto-play if the video is not muted. If auto-play isn't working, try changing the default to mute the video","name":"â ï¸_some_browser_will_not_allow_auto-play_if_the_video_is_not_muted._if_auto-play_isn't_working,_try_changing_the_default_to_mute_the_video","rank":11,"editor":"Label"}},"states":{"ADm":{"caption":"Player Current Time","name":"player_current_time","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADn":{"caption":"playing?","name":"playing","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ADo":{"caption":"paused?","name":"paused","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ADp":{"caption":"ended?","name":"ended","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ADq":{"caption":"Buffered (0 = not buffered, 1 = completely buffered)","name":"buffered","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADr":{"caption":"seeking?","name":"seeking","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ADs":{"caption":"Duration","name":"duration","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADt":{"caption":"Volume","name":"volume","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADu":{"caption":"Muted","name":"muted","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}},"ADv":{"caption":"Speed","name":"speed","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ADw":{"caption":"Ratio","name":"ratio","initialization_code":{"fn":"function(properties,context){}"},"value":"text"}},"actions":{"ADf":{"caption":"Play Video","code":{"fn":"function(instance,properties,context){instance.data.player.play()}"}},"ADg":{"caption":"Pause Video","code":{"fn":"function(instance,properties,context){instance.data.player.pause()}"}},"ADh":{"caption":"Restart Video","code":{"fn":"function(instance,properties,context){instance.data.player.restart()}"}},"ADi":{"caption":"Rewind","code":{"fn":"function(instance,properties,context){instance.data.player.rewind(properties.num_seconds)}"},"fields":{"ADj":{"caption":"Num seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"ADk":{"caption":"Forward","code":{"fn":"function(instance,properties,context){instance.data.player.forward(properties.num_seconds)}"},"fields":{"ADl":{"caption":"Num Seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"ADx":{"caption":"Decrease Volume","code":{"fn":"function(instance,properties,context){instance.data.player.decreaseVolume()}"}},"ADz":{"caption":"Increase Volume","code":{"fn":"function(instance,properties,context){instance.data.player.increaseVolume()}"}},"AEA":{"caption":"Enter Fullscreen","code":{"fn":"function(instance,properties,context){instance.data.player.fullscreen.enter()}"}},"AFK":{"caption":"Mute or Unmute","code":{"fn":"function(instance,properties,context){properties.mute?instance.data.player.muted=!0:instance.data.player.muted=!1}"},"fields":{"AFL":{"caption":"Mute?","name":"mute","rank":0,"editor":"DynamicValue","value":"boolean","default_val":true}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Video Player';
191\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '15px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance,context){instance.data.uniqueVideoId=\"plyrVideo\"+Math.floor(1e5*Math.random()).toString(),instance.data.videoContainer=`<video id=\"${instance.data.uniqueVideoId}\" controls></video>`,instance.canvas.append(instance.data.videoContainer)}"},"update":{"fn":"function(instance,properties,context){function enforceStableMobileVideoLayout(video){const container=video.parentElement,aspectRatio=video.videoWidth/video.videoHeight||16/9,width=undefined,calculatedHeight=container.clientWidth/aspectRatio;container.style.height=calculatedHeight+\"px\",container.style.overflow=\"hidden\",video.style.width=\"100%\",video.style.height=\"100%\",video.style.display=\"block\",video.style.objectFit=\"cover\",video.setAttribute(\"playsinline\",\"\")}const videoElement=document.getElementById(instance.data.uniqueVideoId),controls=[];properties.show_full_screen_button&&controls.push(\"fullscreen\"),properties.play_large&&controls.push(\"play-large\"),properties.play&&controls.push(\"play\"),properties.progress&&controls.push(\"progress\"),properties.current_time&&controls.push(\"current-time\"),properties.mute&&controls.push(\"mute\"),properties.volume&&controls.push(\"volume\"),properties.captions&&controls.push(\"captions\"),properties.settings&&controls.push(\"settings\"),properties.pip&&controls.push(\"pip\"),properties.airplay&&controls.push(\"airplay\"),properties.disable_control_bar&&(controls.length=0);const settings=[];if(properties.quality&&settings.push(\"quality\"),properties.speed&&settings.push(\"speed\"),properties.loop&&settings.push(\"loop\"),properties.captions&&settings.push(\"captions\"),instance.data.alreadyInitialized||(instance.data.player=new Plyr(videoElement,{controls:controls,autoplay:properties.play_automatically||!1,loop:{active:properties.replay_video_when_over||!1},muted:properties.muted_default||!1,settings:settings.length>0?settings:[\"quality\",\"speed\",\"loop\",\"captions\"]}),instance.data.alreadyInitialized=!0),properties.video_url){const videoSource=properties.video_url;videoSource.includes(\"youtube.com\")||videoSource.includes(\"youtu.be\")?(instance.data.player.source={type:\"video\",sources:[{src:videoSource,provider:\"youtube\"}]},instance.data.player.on(\"loadedmetadata\",(function(){const video=instance.data.player.elements.video;video&&enforceStableMobileVideoLayout(video)}))):videoSource.includes(\"vimeo.com\")?(instance.data.player.source={type:\"video\",sources:[{src:videoSource,provider:\"vimeo\"}]},instance.data.player.on(\"loadedmetadata\",(function(){const video=instance.data.player.elements.video;video&&enforceStableMobileVideoLayout(video)}))):(instance.data.player.source={type:\"video\",sources:[{src:videoSource,type:\"video/mp4\"}]},instance.data.player.on(\"loadedmetadata\",(function(){const video=instance.data.player.elements.video;video&&enforceStableMobileVideoLayout(video)})))}else console.warn(\"No video URL provided\");const root=document.documentElement;properties.playing_scrubber_bar_color&&root.style.setProperty(\"--plyr-color-main\",properties.playing_scrubber_bar_color),properties.play_button_color&&(root.style.setProperty(\"--plyr-video-control-color\",properties.play_button_color),root.style.setProperty(\"--plyr-video-control-color-hover\",properties.play_button_color)),properties.progress_bar_color&&root.style.setProperty(\"--plyr-video-progress-buffered-background\",properties.progress_bar_color),properties.video_poster&&(instance.data.player.poster=properties.video_poster),properties.end_time&&instance.data.player.on(\"timeupdate\",(function(){instance.data.player.currentTime>=properties.end_time&&instance.data.player.pause()})),properties.replay_video_when_over&&instance.data.player.on(\"ended\",(function(){instance.data.player.restart()})),properties.start_time&&(instance.data.player.currentTime=properties.start_time),properties.play_automatically&&instance.data.player.play(),instance.data.player.muted=properties.muted_default||!1,instance.data.player.speed=properties.video_speed,setTimeout((()=>{instance.data.player&&(instance.data.player.muted=properties.muted_default||!1,instance.data.player.speed=properties.video_speed,properties.play_automatically&&instance.data.player.play().catch((error=>{console.warn(\"Autoplay blocked by browser\",error)})))}),1e3),instance.data.player.on(\"timeupdate\",(function(event){const currentTime=instance.data.player.currentTime;instance.publishState(\"player_current_time\",currentTime)})),instance.publishState(\"playing\",instance.data.player.playing),instance.data.player.on(\"playing\",(function(){instance.publishState(\"playing\",!0),instance.publishState(\"paused\",!1)})),instance.publishState(\"paused\",instance.data.player.paused),instance.data.player.on(\"pause\",(function(){instance.publishState(\"paused\",!0),instance.publishState(\"playing\",!1)})),instance.publishState(\"ended\",!1),instance.data.player.on(\"ended\",(function(){instance.publishState(\"ended\",!0)}));const bufferInterval=setInterval((function(){const buffered=instance.data.player.buffered;instance.publishState(\"buffered\",buffered),1===buffered&&(instance.publishState(\"buffered\",1),clearInterval(bufferInterval))}),500);instance.data.player.on(\"canplaythrough\",(function(){instance.publishState(\"buffered\",1),clearInterval(bufferInterval)})),instance.publishState(\"seeking\",!1),instance.data.player.on(\"seeking\",(function(){instance.publishState(\"seeking\",!0)})),instance.data.player.on(\"seeked\",(function(){instance.publishState(\"seeking\",!1)})),instance.data.player.on(\"loadedmetadata\",(function(){let duration=instance.data.player.duration;instance.publishState(\"duration\",duration),(0===duration||isNaN(duration))&&setTimeout((()=>{const durationAfter2s=instance.data.player.duration;durationAfter2s&&0!==durationAfter2s&&!isNaN(durationAfter2s)?instance.publishState(\"duration\",durationAfter2s):setTimeout((()=>{const durationAfter5s=instance.data.player.duration;durationAfter5s&&0!==durationAfter5s&&!isNaN(durationAfter5s)&&instance.publishState(\"duration\",durationAfter5s)}),3500)}),2e3)})),instance.publishState(\"volume\",instance.data.player.volume),instance.data.player.on(\"volumechange\",(function(){const volume=instance.data.player.volume;instance.publishState(\"volume\",volume)})),instance.publishState(\"muted\",instance.data.player.muted),instance.data.player.on(\"volumechange\",(function(){const muted=instance.data.player.muted;instance.publishState(\"muted\",muted)})),instance.data.player.on(\"ratechange\",(function(){const speed=instance.data.player.speed;instance.publishState(\"speed\",speed)})),instance.data.player.on(\"loadedmetadata\",(function(){const ratio=instance.data.player.ratio;console.log(\"Video ratio:\",ratio),instance.publishState(\"ratio\",ratio)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}}}; 192window._bubble_page_load_data.plugins_size['1585773166741x344001413254479900'] = 32919; 193window.preloaded['plugin/third_party:1585773166741x344001413254479900:1.7.17'] = true; 194window.plugins["1592859247043x537131931860729860"] = {"human":"Toggles - Custom Toggle","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"Beautiful Toggle","property_applications":{"resizable":true},"add_is_visible":true,"support_autobinding":false,"autobinding_value":"boolean","has_reset_fn":true,"fields":{"AAG":{"caption":"Transition Time","name":"toggle_transition_time","rank":3,"editor":"DynamicValue","value":"number","default_val":0.4},"AAH":{"caption":"Color (\"Yes\")","name":"toggle_background_color_yes","rank":6,"editor":"Color","default_val":"rgba(51, 212, 118, 1)"},"AAI":{"caption":"Color (\"No\")","name":"toggle_background_color_no","rank":5,"editor":"Color","default_val":"rgba(235, 235, 235, 1)"},"AAJ":{"caption":"Preset Status","name":"preset_status","rank":1,"editor":"DynamicValue","value":"boolean","default_val":false},"AAL":{"caption":"Handle Color (\"No\")","name":"handle_color","rank":11,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","in_style":false},"AAM":{"caption":"Roundness","name":"toggle_roundness","rank":7,"editor":"DynamicValue","value":"number","default_val":500},"AAN":{"caption":"Handle Roundness","name":"handle_roundness","rank":10,"editor":"DynamicValue","value":"number","default_val":500}
194,"AAO":{"caption":"Width (Custom)","name":"toggle_width_custom","rank":8,"editor":"DynamicValue","value":"number","optional":true},"AAR":{"caption":"Width (Optional)","name":"handle_width","rank":13,"editor":"DynamicValue","value":"number","optional":true},"AAU":{"caption":"Shadow Color","name":"handle_shadow_color","rank":14,"editor":"Color","default_val":"rgba(0, 0, 0, 0.41)","in_style":false},"AAV":{"caption":"-------------------------- Handle Options --------------------------","name":"----------_handle_options_----------","rank":9,"editor":"Label"},"AAW":{"caption":"------------------- Toggle Container Options -------------------","name":"----------_outer_toggle_options_----------","rank":4,"editor":"Label"},"AAX":{"caption":"------------------------ General Options ------------------------","name":"---------------_general_options_options_---------------","rank":0,"editor":"Label"},"AAZ":{"caption":"Shadow V Offset","name":"handle_shadow_y_offset","rank":15,"editor":"DynamicValue","value":"number","default_val":0},"AAa":{"caption":"Shadow Blur Radius","name":"handle_shadow_blur_radius","rank":17,"editor":"DynamicValue","value":"number","default_val":6},"AAb":{"caption":"Shadow H Offset","name":"handle_shadow_x_offset","rank":16,"editor":"DynamicValue","value":"number","default_val":0},"AAc":{"caption":"Handle Color (\"Yes\")","name":"handle_color_yes","rank":12,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AAd":{"caption":"Disabled?","name":"disabled","rank":2,"editor":"DynamicValue","value":"boolean","default_val":false}},"states":{"AAK":{"caption":"value","name":"value","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AAQ":{"caption":"value is changed","name":"value_is_changed"}},"actions":{"AAS":{"caption":"Change Toggle Value","code":{"fn":"function(instance,properties,context){instance.triggerEvent(\"value_is_changed\",(function(err){})),properties.value_to_change_to?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=properties.handle_color_yes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",instance.data.latestToggleValue=!0,instance.publishState(\"value\",!0)):properties.value_to_change_to||(instance.data.handleElement.style.backgroundColor=properties.handle_color,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.transform=\"translate(0px)\",instance.data.latestToggleValue=!1,instance.publishState(\"value\",!1))}"},"fields":{"AAT":{"caption":"Value to Change To","name":"value_to_change_to","rank":0,"editor":"DynamicValue","value":"boolean"}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n //add the items to the page\n let uniqueSwitchID = \"switch\" + Math.floor(Math.random()*1000000).toString();\n let uniqueCheckboxID = \"checkbox\" + Math.floor(Math.random()*100000).toString();\n\tlet uniqueToggleID = \"toggle\" + Math.floor(Math.random()*100000).toString();\n \tlet uniqueHandleID = \"handle\" + Math.floor(Math.random()*100000).toString();\n \n let myDiv = '<div id=\"'+ uniqueSwitchID +'\"><input id=' + uniqueCheckboxID + ' type=\"checkbox\"><span id=\"' + uniqueToggleID + '\"><div id=\"' + uniqueHandleID + '\"></div></span></label>';\n instance.canvas.append(myDiv);\n \n \n\n let switchContainer = document.getElementById(uniqueSwitchID);
194\n let checkboxElement = document.getElementById(uniqueCheckboxID);\n let toggleElement = document.getElementById(uniqueToggleID);\n let handleElement = document.getElementById(uniqueHandleID);\n \n \t//instance.canvas.style.overflow = \"hidden\";\n //instance.canvas.isResponsive = false;\n \n \n /**************** TOGGLE (container for handle): set styles ****************/\n toggleElement.style.borderRadius=properties.toggle_roundness + \"px\";\n\tlet toggleWidth = properties.bubble.height()*1.76;\n if(properties.toggle_width_custom){\n \ttoggleWidth = properties.toggle_width_custom; \n };\n toggleElement.style.position = \"absolute\";\n toggleElement.style.cursor = \"pointer\";\n toggleElement.style.top = 0;\n toggleElement.style.left = 0;\n toggleElement.style.right = 0;\n toggleElement.style.bottom = 0;\n toggleElement.style.transition = \".4s\"; \n \n\n \n /**************** HANDLE: set styles ****************/\n let handleLength = properties.bubble.height() * 0.8;\n let handleBuffer = (properties.bubble.height() - handleLength)/2;\n \n handleElement.style.left = handleBuffer + \"px\";\n handleElement.style.bottom = handleBuffer + \"px\";\n handleElement.style.height = handleLength + \"px\";\n handleElement.style.width = handleLength + \"px\";\n if(properties.handle_width){\n \thandleElement.style.width = properties.handle_width + \"px\";\n };\n handleElement.style.backgroundColor = properties.handle_color;\n handleElement.style.borderRadius = properties.handle_roundness + \"px\";\n handleElement.style.boxShadow = properties.handle_shadow_x_offset+\"px \"+ properties.handle_shadow_y_offset+\"px \"+properties.handle_shadow_blur_radius+\"px \"+properties.handle_shadow_color;//\"0px 0px 6px \" + properties.handle_shadow_color;//rgba(0,0,0,0.5)\";\n let handleTranslateDistance = (toggleWidth - (2*handleBuffer) - handleLength);\n if(properties.handle_width){\n \thandleTranslateDistance = (toggleWidth - (2*handleBuffer) - properties.handle_width);\n };\n handleElement.style.position = \"absolute\";\n handleElement.style.transition = \"0.4s\";\n \n /**************** SWITCH: set styles (this is outermost element) ****************/\n switchContainer.style.height = properties.bubble.height()+\"px\";\n switchContainer.style.width = toggleWidth + \"px\";\n switchContainer.style.position = \"relative\";\n switchContainer.style.display = \"inline-block\";\n \n \n /**************** CHECKBOX: set styles (this is checkbox element) ****************/\n checkboxElement.style.opacity = 0;\n checkboxElement.style.width = 0;\n checkboxElement.style.height = 0;\n \n \n \n \n \n \tif(properties.preset_status) { //Set default toggle color based on preset status\n toggleElement.style.backgroundColor=properties.toggle_background_color_yes;\n handleElement.style.backgroundColor = properties.handle_color_yes;\n\t\thandleElement.style.transform=\"translate(\" + handleTranslateDistance + \"px)\";\n } else {\n toggleElement.style.backgroundColor=properties.toggle_background_color_no;\n handleElement.style.backgroundColor = properties.handle_color;\n handleElement.style.transform=\"translate(0px)\";\n };\n \n instance.data.toggleElement = toggleElement;\n instance.data.handleElement = handleElement;\n instance.data.preset_status = properties.preset_status;\n\n\t\n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueSwitchID=\"switch\"+Math.floor(1e6*Math.random()).toString(),instance.data.uniqueCheckboxID=\"checkbox\"+Math.floor(1e5*Math.random()).toString(),instance.data.uniqueToggleID=\"toggle\"+Math.floor(1e5*Math.random()).toString(),instance.data.uniqueHandleID=\"handle\"+Math.floor(1e5*Math.random()).toString();let myDiv='<label onclick=\"event.stopPropagation()\" class=\"togglecheckbox\" id=\"'+instance.data.uniqueSwitchID+'\"><input id='+instance.data.uniqueCheckboxID+' type=\"checkbox\"><span id=\"'+instance.data.uniqueToggleID+'\"><div id=\"'+instance.data.uniqueHandleID+'\"></div></span></label>';instance.canvas.append(myDiv)}"},"update":{"fn":"function(instance,properties,context){$(document).ready((function(){instance.data.switchContainer=document.getElementById(instance.data.uniqueSwitchID),instance.data.checkboxElement=document.getElementById(instance.data.uniqueCheckboxID),instance.data.toggleElement=document.getElementById(instance.data.uniqueToggleID),instance.data.handleElement=document.getElementById(instance.data.uniqueHandleID),instance.data.listenerAdded||(instance.data.checkboxElement.addEventListener(\"change\",(function(event){properties.disabled||(document.getElementById(instance.data.uniqueCheckboxID).checked?(instance.data.latestToggleValue=!0,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=properties.handle_color_yes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",instance.publishState(\"value\",!0)):(instance.data.latestToggleValue=!1,instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.backgroundColor=properties.handle_color,instance.data.handleElement.style.transform=\"translate(0px)\",instance.publishState(\"value\",!1)),instance.triggerEvent(\"value_is_changed\",(function(err){})))})),instance.data.listenerAdded=!0),instance.data.toggleElement.style.borderRadius=properties.toggle_roundness+\"px\",instance.data.backgroundColorNo=properties.toggle_background_color_no,instance.data.backgroundColorYes=properties.toggle_background_color_yes,instance.data.toggleWidth=1.76*properties.bubble.height(),instance.data.handleColorYes=properties.handle_color_yes,instance.data.handleColorNo=properties.handle_color,properties.toggle_width_custom&&(instance.data.toggleWidth=properties.toggle_width_custom),instance.data.toggleElement.style.position=\"absolute\",instance.data.toggleElement.style.cursor=\"pointer\",instance.data.toggleElement.style.top=0,instance.data.toggleElement.style.left=0,instance.data.toggleElement.style.right=0,instance.data.toggleElement.style.bottom=0,instance.data.toggleElement.style.transition=properties.toggle_transition_time+\"s\",instance.data.handleLength=.8*properties.bubble.height(),instance.data.handleBuffer=(properties.bubble.height()-instance.data.handleLength)/2,instance.data.handleElement.style.left=instance.data.handleBuffer+\"px\",instance.data.handleElement.style.bottom=instance.data.handleBuffer+\"px\",instance.data.handleElement.style.height=instance.data.handleLength+\"px\",instance.data.handleElement.style.width=instance.data.handleLength+\"px\",properties.handle_width&&(instance.data.handleElement.style.width=properties.handle_width+\"px\"),instance.data.handleElement.style.backgroundColor=properties.handle_color,1==properties.preset_status&&(instance.data.handleElement.style.backgroundColor=properties.handle_color_yes),instance.data.handleElement.style.borderRadius=properties.handle_roundness+\"px\",instance.data.handleElement.style.boxShadow=properties.handle_shadow_x_offset+\"px \"+properties.handle_shadow_y_offset+\"px \"+properties.handle_shadow_blur_radius+\"px \"+properties.handle_shadow_color,instance.data.handleTranslateDistance=instance.data.toggleWidth-2*instance.data.handleBuffer-instance.data.handleLength,properties.handle_width&&(instance.data.handleTranslateDistance=instance.data.toggleWidth-2*instance.data.handleBuffer-properties.handle_width),instance.data.handleElement.style.position=\"absolute\",instance.data.handleElement.style.transition=properties.toggle_transition_time+\"s\",instance.data.switchContainer.style.height=properties.bubble.height()+\"px\",instance.data.switchContainer.style.width=instance.data.toggleWidth+\"px\",instance.data.switchContainer.style.position=\"relative\",instance.data.switchContainer.style.display=\"inline-block\",instance.data.checkboxElement.style.opacity=0,instance.data.checkboxElement.style.width=0,instance.data.checkboxElement.style.height=0,1==instance.data.latestToggleValueSet?instance.data.latestToggleValue?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",document.getElementById(instance.data.uniqueCheckboxID).checked=!0):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,document.getElementById(instance.data.uniqueCheckboxID).checked=!1,instance.data.handleElement.style.transform=\"translate(0px)\"):properties.preset_status?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\",document.getElementById(instance.data.uniqueCheckboxID).checked=!0,instance.data.latestToggleValue=!0):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,document.getElementById(instance.data.uniqueCheckboxID).checked=!1,instance.data.handleElement.style.transform=\"translate(0px)\",instance.data.latestToggleValue=!1),instance.publishState(\"value\",document.getElementById(instance.data.uniqueCheckboxID).checked)}))}"},"reset":{"fn":"function(instance,context){function runReset(){instance.data.preset_status?(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorYes,instance.data.handleElement.style.backgroundColor=instance.data.handleColorYes,instance.data.handleElement.style.transform=\"translate(\"+instance.data.handleTranslateDistance+\"px)\"):(instance.data.toggleElement.style.backgroundColor=instance.data.backgroundColorNo,instance.data.handleElement.style.backgroundColor=instance.data.handleColorNo,instance.data.handleElement.style.transform=\"translate(0px)\")}instance.data.toggleElement&&instance.data.handleElement&&runReset()}"}},"platform_type":"web"},"AAt":{"display":"Chart - Geo Map Demo","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"fields":{"AAm":{"caption":"Region","name":"region","rank":1,"editor":"DynamicValue","value":"text"},"AAn":{"caption":"Resolution","name":"resolution","rank":2,"editor":"Dropdown","value":"text","default_val":"provinces"},"AAo":{"caption":"Labels List","name":"labels_list","rank":3,"editor":"DynamicValue","value":"text","default_val":"State, California, Texas, New York, Florida"},"AAp":{"caption":"Values List","name":"values_list","rank":4,"editor":"DynamicValue","value":"text","default_val":"Population, 39538223, 29145505, 20201249, 21538187"},"AAq":{"caption":"Color Starting Value","name":"color_starting_value","rank":5,"editor":"Color","default_val":"rgba(189,225,245,1)"},"AAr":{"caption":"Color Ending Value","name":"color_ending_value","rank":6,"editor":"Color","default_val":"rgba(26,154,223,1)"},"AAs":{"caption":"Google API Key","name":"google_api_key","rank":0,"editor":"StaticText"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'BETA: Geography / Maps Chart';
194\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n\n // Append the container to the body\n document.body.appendChild(container);\n \n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueGeoChartId=\"geoChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.geoChartCanvas=\"<div id='\"+instance.data.uniqueGeoChartId+\"' style='width: 100%; height: 500px;'></div>\",instance.canvas.append(instance.data.geoChartCanvas)}"},"update":{"fn":"function(instance,properties){function createDataTable(labelsString,dataString){const labels=labelsString.split(\",\").map((label=>label.trim())),dataValues=dataString.split(\",\").map((value=>value.trim())),dataArray=[];dataArray.push([labels[0],dataValues[0]]);for(let i=1;i<labels.length;i++)dataArray.push([labels[i],parseFloat(dataValues[i])]);return dataArray}function rgbaToHex(rgba){const matches=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+),?\\s*([\\d\\.]+)?\\)/);if(!matches)throw new Error(\"Invalid RGBA color format\");let r=parseInt(matches[1],10),g=parseInt(matches[2],10),b=parseInt(matches[3],10),hexR,hexG,hexB;return`#${r.toString(16).padStart(2,\"0\")}${g.toString(16).padStart(2,\"0\")}${b.toString(16).padStart(2,\"0\")}`}google.charts.load(\"current\",{packages:[\"geochart\"],mapsApiKey:properties.google_api_key});const labelsString=properties.labels_list,dataString=properties.values_list;console.log(createDataTable(labelsString,dataString)),google.charts.setOnLoadCallback((function(){var data=google.visualization.arrayToDataTable(createDataTable(labelsString,dataString)),options={region:properties.region,backgroundColor:\"transparent\",resolution:properties.resolution,colorAxis:{colors:[rgbaToHex(properties.color_starting_value),rgbaToHex(properties.color_ending_value)]}},chart;new google.visualization.GeoChart(document.getElementById(instance.data.uniqueGeoChartId)).draw(data,options)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}}}; 195window._bubble_page_load_data.plugins_size['1592859247043x537131931860729860'] = 19368; 196window.preloaded['plugin/third_party:1592859247043x537131931860729860:1.8.20'] = true; 197window.plugins["1600733261948x484432582163300350"] = {"human":"ð Essential Charts Bundle Chart JS","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAC":{"display":"Chart - Funnel (classic)","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AAJ":{"caption":"Label Values (comma-separated strings or #s)","default_val":"Red, Yellow, Blue","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":2,"value":"text"},"AAN":{"caption":"Color - 1st Entry","default_val":"rgba(51, 181, 229, 1)","editor":"Color","name":"series1color","rank":30},"AAR":{"caption":"Color - 2nd Entry","editor":"Color","name":"series2color","rank":31,"default_val":"rgba(54, 209, 132, 1)"},"AAZ":{"caption":"Color - 3rd Entry","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":32},"AAf":{"caption":"Show Y Axis Ticks?","default_val":true,"editor":"DynamicValue","name":"showYAxis","optional":true,"rank":11,"value":"boolean"},"AAj":{"caption":"Show Legend","editor":"Dropdown","name":"showLegend","rank":1,"value":"text","default_val":"Don't Show Legend"},"ABD":{"caption":"Color - 4th Entry","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":33},"ABG":{"caption":"Color - 5th Entry","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":34},"ABI":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":19,"value":"boolean"},"ACE":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":10,"editor":"Label"},"ACF":{"caption":"------------------------- Section Colors ---------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":29,"editor":"Label"},"ACG":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":0,"editor":"Label"},"ACg":{"caption":"Data Label Unit Before","name":"data_labels_unit_before","rank":23,"editor":"DynamicValue","value":"text","optional":true},"ACh":{"caption":"Data Labels Unit After","name":"data_labels_unit_after","rank":24,"editor":"DynamicValue","value":"text","optional":true},"ACj":{"caption":"Thousands Separator","name":"thousands_separator","rank":5,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"ADC":{"caption":"--------------------------- Data Labels ---------------------------","name":"---------------------------_data_labels_---------------------------","rank":18,"editor":"Label"},"ADD":{"caption":"Vertical Offset","name":"datalabel_offset","rank":22,"editor":"DynamicValue","value":"number","default_val":3}
197,"ADE":{"caption":"Data Label Background Color","name":"datalabel_background_color","rank":25,"editor":"Color","default_val":"rgba(255, 255, 255, 0.32)","optional":false},"ADF":{"caption":"Font Color (Optional)","name":"datalabel_font_color","rank":27,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"ADG":{"caption":"Font Color Setting","name":"font_color_setting","rank":26,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"ADH":{"caption":"Anchor","name":"datalabel_anchor","rank":20,"editor":"Dropdown","default_val":"left"},"ADT":{"caption":"Section Spacing","name":"section_spacing","rank":4,"editor":"DynamicValue","value":"number","default_val":5},"ADU":{"caption":"Color - 6th Entry","name":"series6color","rank":35,"editor":"Color","default_val":"rgba(255, 115, 0, 1)"},"ADV":{"caption":"Additional Colors (Comma-Separated List)","name":"additional_colors","rank":36,"editor":"DynamicValue","value":"text","default_val":"#33B5E5, #36D184, #F7B733, #AA66CC, #636363, #FF7300"},"ADW":{"caption":"Values","name":"values","rank":3,"editor":"DynamicValue","value":"text","default_val":"100, 50, 20"},"ADX":{"caption":"Funnel Alignment","name":"side","rank":6,"editor":"Dropdown","default_val":"auto"},"ADY":{"caption":"Left Padding","name":"left_padding","rank":7,"editor":"DynamicValue","value":"number","default_val":10},"ADZ":{"caption":"Right Padding","name":"right_padding","rank":8,"editor":"DynamicValue","value":"number","default_val":10},"ADa":{"caption":"Horizontal Offset","name":"datalabel_horizontal_offset","rank":21,"editor":"DynamicValue","value":"number","default_val":0},"ADb":{"caption":"Y Ticks Horiz. Offset","name":"y_axis_horizontal_offset","rank":13,"editor":"DynamicValue","value":"number","default_val":0},"ADc":{"caption":"Y Ticks Vert. Offset","name":"y_axis_vertical_offset","rank":14,"editor":"DynamicValue","value":"number","default_val":0},"ADd":{"caption":"Y Ticks Color (Optional)","name":"y_axis_font_color","rank":17,"editor":"Color","default_val":"rgba(156, 156, 156, 1)"},"ADe":{"caption":"Y Ticks Font Size","name":"y_ticks_size","rank":15,"editor":"DynamicValue","value":"number","default_val":10},"ADf":{"caption":"Label Font Size","name":"label_font_size","rank":28,"editor":"DynamicValue","value":"number","default_val":10},"ADh":{"caption":"Tick Anchor","name":"tick_anchor","rank":12,"editor":"Dropdown","default_val":"center"},"ADi":{"caption":"Tick Font Color Setting","name":"tick_font_color_setting","rank":16,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"ADq":{"caption":"Show Hover Tooltips?","name":"show_hover_tooltips","rank":9,"editor":"DynamicValue","value":"boolean","default_val":false}},"states":{"AAv":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"ABU":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"ABV":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"ACn":{"caption":"chart_value_clicked","name":"chart_value_clicked"}},"actions":{"ABr":{"caption":"Add a Data Series","code":{"fn":"function(instance,properties,context){let customChartType;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}properties.chart_type&&(customChartType=properties.chart_type.toLowerCase()),addSeries()}"},"fields":{"ABu":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"ABv":{"caption":"Series Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"ABw":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"ACP":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true}}},"ABs":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.chart.data.datasets.splice(instance.data.chart.data.datasets.indexOf(foundSeries),1),instance.data.chart.update(
197))}"},"fields":{"ABt":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[]}"},"update":{"fn":"function(instance,properties,context){if(instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId);instance.data.mainChartCanvas=chartcanvas;var ctxchart=chartcanvas.getContext(\"2d\");let legendState,showLegend;function createDataArray(xString){let outputArray,xArray;return null!=xString&&(xArray=xString.split(\", \")),xArray}\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),series1string=properties.series1,valuesArray=createDataArray(properties.values),arrayofcolors=[];arrayofcolors.push(properties.series1color),arrayofcolors.push(properties.series2color),arrayofcolors.push(properties.series3color),arrayofcolors.push(properties.series4color),arrayofcolors.push(properties.series5color),arrayofcolors.push(properties.series6color);let additionalColors=properties.additional_colors,additionalColorsArray;null!=additionalColors&&(additionalColorsArray=additionalColors.split(\", \"));let fullColorArray,finalColorArray=arrayofcolors.concat(additionalColorsArray).slice(0,arrayofxvalues.length);if(properties.showYAxis){let num,anchor=0;for(num=0;num<arrayofxvalues.length;num++){let customLabels=\"<div id='\"+instance.data.uniqueChartId.toString()+num+\"' style='position: absolute'>\"+arrayofxvalues[num]+\"</div>\";document.getElementById(instance.data.uniqueChartId.toString()+num)||instance.canvas.append(customLabels);let labelNode=document.getElementById(instance.data.uniqueChartId.toString()+num),labelNodeWidth=$(\"#\"+instance.data.uniqueChartId.toString()+num).width();\"center\"==properties.tick_anchor&&(anchor=properties.bubble.width()/2-labelNodeWidth/2),\"right\"==properties.tick_anchor&&(anchor=properties.bubble.width()-labelNodeWidth);let sectionHeight=properties.bubble.height()/arrayofxvalues.length,labelNodeHeight,yLocation=sectionHeight*num+sectionHeight/2-$(\"#\"+instance.data.uniqueChartId.toString()+num).height()/2+properties.y_axis_vertical_offset,chartNode;labelNode.style.top=yLocation.toString()+\"px\",labelNode.style.fontSize=properties.y_ticks_size+\"px\",labelNode.style.color=properties.datalabel_font_color,labelNode.style.left=properties.y_axis_horizontal_offset+anchor+\"px\",\"Default (Same as Series Color)\"==properties.tick_font_color_setting?labelNode.style.color=finalColorArray[num]:labelNode.style.color=properties.y_axis_font_color,document.getElementById(instance.data.uniqueChartId).parentNode.prepend(labelNode)}}if(properties.show_data_labels){let num,anchor=0;for(num=0;num<valuesArray.length;num++){let unitBefore=\"\",unitAfter=\"\";null!=properties.data_labels_unit_before&&(unitBefore=properties.data_labels_unit_before),null!=properties.data_labels_unit_after&&(unitAfter=properties.data_labels_unit_after);let thousandsSeparatedValue=valuesArray[num];thousandsSeparatedValue=thousandsSeparatedValue.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator);let customLabels=\"<div id='\"+instance.data.uniqueChartId+valuesArray[num]+\"' style='position: absolute'>\"+unitBefore+thousandsSeparatedValue+unitAfter+\"</div>\";document.getElementById(instance.data.uniqueChartId+valuesArray[num])||instance.canvas.append(cu
197stomLabels);let labelNode=document.getElementById(instance.data.uniqueChartId.toString()+valuesArray[num]),labelNodeWidth=$(\"#\"+instance.data.uniqueChartId.toString()+valuesArray[num]).width();\"center\"==properties.datalabel_anchor&&(anchor=properties.bubble.width()/2-labelNodeWidth/2),\"right\"==properties.datalabel_anchor&&(anchor=properties.bubble.width()-labelNodeWidth);let sectionHeight=properties.bubble.height()/arrayofxvalues.length,labelNodeHeight,yLocation=sectionHeight*num+sectionHeight/2-$(\"#\"+instance.data.uniqueChartId.toString()+valuesArray[num]).height()/2+properties.datalabel_offset,chartNode;labelNode.style.top=yLocation.toString()+\"px\",labelNode.style.fontSize=properties.label_font_size+\"px\",labelNode.style.left=properties.datalabel_horizontal_offset+anchor+\"px\",\"Default (Same as Series Color)\"==properties.font_color_setting?labelNode.style.color=finalColorArray[num]:labelNode.style.color=properties.datalabel_font_color,document.getElementById(instance.data.uniqueChartId).parentNode.prepend(labelNode)}}let topW=.55*properties.bubble.width()*(valuesArray[valuesArray.length-1]/valuesArray[0]),bottomW=.55*properties.bubble.width();topW/bottomW<.2&&topW/bottomW>.15?(topW*=.45,bottomW*=.45):topW/bottomW<=.15&&topW/bottomW>.095?(topW*=.3,bottomW*=.3):topW/bottomW<=.095&&(topW*=.07,bottomW*=.07);var chart=new Chartfunnel(instance.data.ctxChartState,{type:\"funnel\",data:{labels:arrayofxvalues,datasets:[{data:valuesArray,backgroundColor:finalColorArray,hoverBackgroundColor:finalColorArray}]},options:{plugins:{datalabels:{display:!1},stacked100:{enable:!1},crosshair:!1},topWidth:topW,bottomWidth:bottomW,sort:\"desc\",keep:properties.side,gap:properties.section_spacing,legend:{onClick:e=>e.stopPropagation(),display:showLegend,position:legendState,labels:{fontColor:properties.bubble.font_color(),fontSize:properties.bubble.font_size(),fontFamily:properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:properties.right_padding,left:properties.left_padding,top:10,bottom:10}},maintainAspectRatio:!1,tooltips:{enabled:properties.show_hover_tooltips}}}),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.mainChartCanvas.style.borderRadius=properties.bubble.border_roundness(),instance.data.chart=chart,chart.update()}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Funnel Chart - Classic';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';
197\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"}},"platform_type":"web"},"AAn":{"display":"Complex List Calculations","add_is_visible":true,"fields":{"AAo":{"caption":"List A","editor":"DynamicValue","name":"listA","rank":0,"value":"text"},"AAp":{"caption":"Operation","default_val":"Multiply","editor":"Dropdown","name":"operation1","rank":1},"AAq":{"caption":"Number or List B","editor":"DynamicValue","name":"numberOrListB","rank":2,"value":"text"}},"states":{"AAr":{"caption":"Output List (number)","initialization_code":{"fn":"function(properties,context){let result;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}return result=\"Concatenate\"==properties.operation1?concatenate(properties.listA,properties.numberOrListB):multiply(properties.listA,properties.numberOrListB),result}"},"is_list":true,"name":"outputList","value":"number"},"ABP":{"caption":"Output List (text)","name":"outputliststring","value":"text","initialization_code":{"fn":"function(properties,context){let result;function concatenate(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\",\");for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2[i]);return array1}if(!array2orlist2.includes(\",\")){for(let i=0;i<array1.length;i++)array1[i]=array1[i].concat(array2orlist2);return array1}}function multiply(originalArray,array2orlist2){if(!originalArray)return null;let array1=originalArray.split(\", \");if(array2orlist2.includes(\",\")){let array2=array2orlist2.split(\", \");if(\"Divide\"==properties.operation1)for(let i=0;i<array1.length;i++)array2[i]=Math.pow(array2[i],-1);return multiplyTwoArrays(array1,array2,array1.length)}if(!array2orlist2.includes(\",\")){let multiple=array2orlist2;return\"Divide\"==properties.operation1&&(multiple=Math.pow(array2orlist2,-1)),multiplyArrayAndNumber(array1,multiple,array1.length)}}function multiplyTwoArrays(array1,array2,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*array2[i];resultingArray.push(product)}return resultingArray}function multiplyArrayAndNumber(array1,number,arrayLength){let resultingArray=[];for(let i=0;i<arrayLength;i++){let product=array1[i]*number;resultingArray.push(product)}return resultingArray}return result=\"Concatenate\"==properties.operation1?concatenate(properties.listA,properties.numberOrListB):multiply(
197properties.listA,properties.numberOrListB),result}"},"is_list":true}},"code":{"initialize":{"fn":"function(instance,context){}"},"update":{"fn":"function(instance,properties,context){}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"},"AFz":{"display":"Chart - Funnel (modern)","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AFL":{"caption":"Funnel Section Labels","default_val":"Red, Yellow, Blue","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":1,"value":"text"},"AFM":{"caption":"Series 1 Color Start","default_val":"rgba(51, 181, 229, 1)","editor":"Color","name":"series1color","rank":4},"AFN":{"caption":"Series 1 Color End","editor":"Color","name":"series2color","rank":5,"default_val":"rgba(54, 209, 132, 1)"},"AFO":{"caption":"Series 2 Color Start","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":8},"AFR":{"caption":"Series 2 Color End","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":9},"AFS":{"caption":"Series 3 Color Start","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":12},"AFT":{"caption":"Show Value Labels?","default_val":true,"editor":"DynamicValue","name":"show_data_labels_value","rank":21,"value":"boolean"},"AFV":{"caption":"------------------------- Section Colors ---------------------------","name":"-------------------_series_values_(can_also_add_infinite_series_via_action)_-------------------","rank":35,"editor":"Label"},"AFW":{"caption":"------------------------- General Settings -------------------------","name":"-------------------_main_fields_-------------------","rank":0,"editor":"Label"},"AFX":{"caption":"Data Label Unit Before","name":"data_labels_unit_before","rank":27,"editor":"DynamicValue","value":"text","optional":true},"AFY":{"caption":"Data Labels Unit After","name":"data_labels_unit_after","rank":28,"editor":"DynamicValue","value":"text","optional":true},"AFZ":{"caption":"Thousands Separator","name":"thousands_separator","rank":14,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AFa":{"caption":"--------------------------- Data Labels ---------------------------","name":"---------------------------_data_labels_---------------------------","rank":20,"editor":"Label"},"AFb":{"caption":"Vertical Offset","name":"datalabel_offset","rank":26,"editor":"DynamicValue","value":"number","default_val":3},"AFd":{"caption":"Percent - Font Color","name":"datalabel_font_color_percent","rank":31,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AFf":{"caption":"Anchor","name":"datalabel_anchor","rank":24,"editor":"Dropdown","default_val":"left"},"AFh":{"caption":"Series 3 Color End","name":"series6color","rank":13,"editor":"Color","default_val":"rgba(255, 115, 0, 1)","optional":true},"AFi":{"caption":"Additional Colors (Comma-Separated List)","name":"additional_colors","rank":36,"editor":"DynamicValue","value":"text","default_val":"#33B5E5, #36D184, #F7B733, #AA66CC, #636363, #FF7300"},"AFj":{"caption":"Series 1 Values","name":"values","rank":3,"editor":"DynamicValue","value":"text","default_val":"100, 50, 20"},"AFk":{"caption":"Funnel Alignment","name":"side","rank":16,"editor":"Dropdown","default_val":"vertical"},"AFl":{"caption":"Left Padding","name":"left_padding","rank":17,"editor":"DynamicValue","value":"number","default_val":10},"AFm":{"caption":"Right Padding","name":"right_padding","rank":18,"editor":"DynamicValue","value":"number","default_val":10},"AFn":{"caption":"Horizontal Offset","name":"datalabel_horizontal_offset","rank":25,"editor":"DynamicValue","value":"number","default_val":0},"AFv":{"caption":"Show Hover Tooltips?","name":"show_hover_tooltips","rank":19,"editor":"DynamicValue","value":"boolean","default_val":false},"AGB":{"caption":"Title - Font Color","name":"datalabel_font_color_title","rank":30,"editor":"Color","default_val":"rgba(255,255,255,1)"},"AGC":{"caption":"Value - Font Color","name":"datalabel_font_color_value","rank":29,"editor":"Color","default_val":"rgba(54, 209, 132, 1)"},"AGD":{"caption":"Value - Font Size","name":"datalabel_font_size_value","rank":32,"editor":"DynamicValue","value":"number","default_val":15},"AGE":{"caption":"Title - Font Size","name":"datalabel_font_size_title","rank":33,"editor":"DynamicValue","value":"number","default_val":21},"AGF":{"caption":"Percent - Font Size","name":"datalabel_font_size_percent","rank":34,"editor":"DynamicValue","value":"number","default_val":10},"AGG":{"caption":"Show Percent Labels?","name":"show_data_labels_percent","rank":23,"editor":"DynamicValue","value":"boolean","default_val":true},"AGH":{"caption":"Show Title Labels?","name":"show_data_labels_title","rank":22,"editor":"DynamicValue","value":"boolean","default_val":true},"AGI":{"caption":"Separator Color","name":"separator_color","rank":15,"editor":"Color","value":"_any_thing","default_val":"rgba(181,181,181,1
197)"},"AGJ":{"caption":"Series 1 Name","name":"series_1_name","rank":2,"editor":"DynamicValue","value":"text","default_val":"Series 1"},"AGK":{"caption":"Series 2 Name","name":"series_2_name","rank":6,"editor":"DynamicValue","value":"text","default_val":"Series 2","optional":true},"AGL":{"caption":"Series 2 Values","name":"series_2_values","rank":7,"editor":"DynamicValue","value":"text","optional":true},"AGM":{"caption":"Series 3 Name","name":"series_3_name","rank":10,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 3"},"AGN":{"caption":"Series 3 Values","name":"series_3_values","rank":11,"editor":"DynamicValue","value":"text","optional":true}},"states":{"AFw":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"AFx":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AFy":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AFK":{"caption":"chart_value_clicked","name":"chart_value_clicked"}},"actions":{"AFD":{"caption":"Add a Data Series","code":{"fn":"function(instance,properties,context){let customChartType;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}properties.chart_type&&(customChartType=properties.chart_type.toLowerCase()),addSeries()}"},"fields":{"AFE":{"caption":"Series Name","name":"series_name","rank":0,"editor":"DynamicValue","value":"text"},"AFF":{"caption":"Series Color","name":"series_color","rank":1,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AFG":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"AFH":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true}}},"AFI":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.chart.data.datasets.splice(instance.data.chart.data.datasets.indexOf(foundSeries),1),instance.data.chart.update())}"},"fields":{"AFJ":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id=\"+instance.data.uniqueChartId+\"></div>\",instance.canvas.append(instance.data.chartCanvasCopy)}"},"update":{"fn":"function(instance,properties,context){let labels=properties.xvalues.split(\",\"),values=properties.values.split(\",\").map(Number),sublabelsArray=[];sublabelsArray.push(properties.series_1_name);let arrayOfArrayValues=[];if(properties.series_2_values){let values2=properties.series_2_values.split(\",\").map(Number);for(let i=0;i<values.length;i++){let newArray=[values[i],values2[i]];arrayOfArrayValues.push(newArray)}console.log(arrayOfArrayValues),values=arrayOfArrayValues,sublabelsArray.push(properties.series_2_name),console.log(sublabelsArray)}if(properties.series_3_values){let values3=properties.series_3_values.split(\",\").map(Number);for(let i=0;i<arrayOfArrayValues.length;i++)arrayOfArrayValues[i].push(values3[i]);values=arrayOfArrayValues,sublabelsArray.push(properties.series_3_name)}let colors=[],colors2=[],colors3=[];colors.push(properties.series1color),colors.push(properties.series2color),colors2.push(properties.series3color),colors2.push(properties.series4color),colors3.push(properties.series5color),colors3.push(properties.series6color);let colorsArray=[];colorsArray.push(colors),colorsArray.push(colors2),colorsArray.push(colors3),colorsArray=colorsArray.slice(0,values.length),console.log(\"HERE\"),console.log(colorsArray);let additionalColors=properties.additional_colors,additionalColorsArray;null!=additionalColors&&(additionalColorsArray=additionalColors.split(\", \"));let fullColorArray,finalColorArray=colors.concat(additionalColorsArray).slice(0,labels.length);colors=colors.slice(0,labels.length);let direction=properties.side,borderColor=properties.separator_color;var data={labels:labels,subLabels:sublabelsArray,colors:colorsArray,values:values};if(instance.data.funnel?instance.data.funnel.update({data:data}):(instance.data.funnel=new FunnelGraph({container:\"#\"+instance.data.uniqueChartId,gradientDirection:direction,data:data,displayPercent:properties.display_percent,direction:direction,width:0,height:0,subLabelValue:\"raw\"}),instance.data.funnel.draw()),\"horizontal\"==direction){let labelNodes;instance.data.funnel.updateHeight(properties.bubble.height()-130),instance.data.funnel.updateWidth(properties.bubble.width()),$(instance.canvas[0]).find(\".svg-funnel-js__labels .svg-funnel-js__label\").each((function(i){0!==i&&$($(this)).css({borderLeft:`1px solid ${borderColor}`})}))}else{let labelNodes;instance.data.funnel.updateHeight(properties.bubble.height()),instance.data.funnel.updateWidth(properties.bubble.width()-130),$(instance.canvas[0]).find(\".svg-funnel-js__labels .svg-funnel-js__label\").each((function(i){0!==i&&$($(this)).css({borderTop:`1px solid ${borderColor}`})}))}instance.data.funnel.update({displayPercent:properties.show_data_labels_percent,direction:direction,gradientDirection:direction}),$(instance.canvas[0]).find(\".svg-funnel-js__subLabel--title\").each((function(i){$(this).css({color:\"gray\"}),instance.data.labelPercentElement=this.cloneNode(!0)})),$(instance.canvas[0]).find(\".label__title\").each((function(i){properties.show_data_labels_title||$(this).text(\"\"),$(this).css({color:properties.datalabel_font_color_title,fontSize:properties.datalabel_font_size_title})})),$(instance.canvas[0]).find(\".label__percentage\").each((function(i){properties.show_data_labels_percent||$(this).text(\"\"),-1==i&&$(this).text(\"100%\"),$(this).css({color:properties.datalabel_font_color_percent,fontSize:properties.datalabel_font_size_percent}),instance.data.labelPercentElement=this.cloneNode(!0)})),$(instance.canvas[0]).find(\".label__value\").each((function(i){0==i&&($(instance.data.labelPercentElement).text(\"100%\"),this.parentNode.appendChild(instance.data.labelPercentElement));let rawCommaValue=$(this).text(),newCommaSeparatedValue;rawCommaValue=rawCommaValue.replace(/,/g,\"\"),newCommaSeparatedValue=rawCommaValue.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator),properties.data_labels_unit_before&&(newCommaSeparatedValue=properties.data_labels_unit_before+newCommaSeparatedValue),properties.data_labels_unit_after&&(newCommaSeparatedValue+=properties.data_labels_unit_after),$(this).text(newCommaSeparatedValue),properties.show_data_labels_value||$(this).text(\"\"),$(this).css({color:properties.datalabel_font_color_value,fontSize:properties.datalabel_font_size_value})}))}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Funnel Chart - Modern';
197\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"}},"platform_type":"web"},"AJA":{"display":"Chart - Bar/Line/Area","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"AGv":{"caption":"X-Axis Values","default_val":"Mon, Tue, Wed, Thu, Fri","editor":"DynamicValue","is_list":false,"name":"xvalues","rank":3,"value":"text"},"AGw":{"caption":"Series 1 - y-values","default_val":"120, 260, 240, 310, 330","editor":"DynamicValue","name":"series1","rank":7,"value":"text","optional":false},"AGx":{"caption":"Series 2 - y-values","editor":"DynamicValue","is_list":false,"name":"series2","optional":true,"rank":10,"value":"text","default_val":"200, 210, 190, 240, 230"},"AGy":{"caption":"Series 3 - y-values","editor":"DynamicValue","name":"series3","optional":true,"rank":13,"value":"text","default_val":""},"AGz":{"caption":"Series 1 - color","default_val":"rgba(0, 162, 255, 1)","editor":"Color","name":"series1color","rank":6},"AHA":{"caption":"Series 1 - name","default_val":"Series 1","editor":"DynamicValue","name":"series1name","rank":5,"value":"text","optional":true},"AHB":{"caption":"Chart Type","default_val":"Bar","editor":"Dropdown","name":"chartType","rank":0},"AHC":{"caption":"Series 2 - name","default_val":"Series 2","editor":"DynamicValue","name":"series2name","rank":8,"value":"text","optional":true},"AHD":{"caption":"Series 2 - color","default_val":"rgba(235, 235, 235, 1)","editor":"Color","name":"series2color","rank":9},"AHE":{"caption":"Series 3 - name","default_val":"Series 3","editor":"DynamicValue","name":"series3name","rank":11,"value":"text","optional":true},"AHF":{"caption":"Series 3 color","default_val":"rgba(247, 183, 51, 1)","editor":"Color","name":"series3color","rank":12},"AHG":{"caption":"Y Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":37,"value":"text"},"AHH":{"caption":"Y Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":38,"value":"text"},"AHI":{"caption":"Y Axis - Max (Optional)","editor":"DynamicValue","name":"yMaxNum","optional":true,"rank":36,"value":"number"},"AHJ":{"caption":"Y Axis - Min (Optional)","editor":"DynamicValue","name":"yMinNum","optional":true,"rank":35,"value":"number"},"AHK":{"caption":"Show/Hide Legend","editor":"Dropdown","name":"showLegend","rank":25,"value":"text","default_val":"Top"},"AHL":{"caption":"Series 4 - name","default_val":"Series 4","editor":"DynamicValue","name":"series4name","optional":true,"rank":14,"value":"text"},"AHM":{"caption":"Series 4 color","default_val":"rgba(170, 102, 204, 1)","editor":"Color","name":"series4color","optional":true,"rank":15},"AHN":{"caption":"Series 4 - y-values","editor":"DynamicValue","name":"series4","optional":true,"rank":16,"value":"text"},"AHO":{"caption":"Series 5 - name","default_val":"Series 5","editor":"DynamicValue","name":"series5name","optional":true,"rank":17,"value":"text"},"AHP":{"caption":"Series 5 - color","default_val":"rgba(99, 99, 99, 1)","editor":"Color","name":"series5color","optional":true,"rank":18},"AHQ":{"caption":"Series 5 - y-values","editor":"DynamicValue","name":"series5","optional":true,"rank":19,"value":"text"},"AHR":{"caption":"Show Data Labels?","default_val":false,"editor":"DynamicValue","name":"show_data_labels","rank":58,"value":"boolean"},"AHS":{"caption":"Show Y Tick Labels?","name":"show_y_tick_labels","rank":40,"editor":"DynamicValue","value":"boolean","default_val":true},"AHT":{"caption":"Show X Tick Labels?","name":"show_x_tick_labels","rank":39,"editor":"DynamicValue","value":"boolean","default_val":true},"AHU":{"caption":"------------------- Axis and Gridline Settings -------------------","name":"axis_and_gridline_settings","rank":34,"editor":"Label"},"AHV":{"caption":"----------------------------- Chart Data -----------------------------","name":"-------------------_main_fields_-------------------","rank":1,"editor":"Label"},"AHW":{"caption":"X = Zero Line Width","name":"x_zero_line_width","rank":52,"editor":"DynamicValue","value":"number","default_val":1},"AHX":{"caption":"Y = Zero Line Width","name":"y_zero_line_width","rank":53,"editor":"DynamicValue","value":"number","default_val":1},"AHY":{"caption":"X = Zero Line Color","name":"x_zero_line_color","rank":54,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AHZ":{"caption":"Y = Zero Line Color","name":"y_zero_line_color","rank":55,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AHa":{"caption":"Vert. Gridlines Color","name":"vert_gridlines_color","rank":49,"editor":"Color","default_val":"rgba(255, 255, 255, 0)"},"AHb":{"caption":"Horiz. Gridlines Color","name":"horiz_gridlines_color","rank":48,"editor":"Color","default_val":"rgba(224, 224, 224, 1)"},"AHc":{"caption":"Line Width","name":"border_width","rank":72,"editor":"DynamicValue","value":"number","default_val":3},"AHd":{"caption":"Line Curve","name":"curve_line_charts","rank":74,"editor":"DynamicValue","value":"number","default_val":0.3},"AHe":{"caption":"Unit Before the Label","name":"data_labels_unit_before","rank":63,"editor":"DynamicValue","value":"text","optional":true},"AHf":{"caption":"Unit After the Label","name":"data_labels_unit_after","rank":64,"editor":"DynamicValue","value":"text","optional":true},"AHg":{"caption":"Point Radius","name":"line_point_radius","rank":73,"editor":"DynamicValue","value":"number","default_val":5},"AHh":{"caption":"Thousands Separator","name":"thousands_separator","rank":30,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"AHi":{"caption":"Horiz. Dash Gridlines","name":"horizontal_dashed_gridlines","rank":50,"editor":"DynamicValue","value":"boolean","default_val":true},"AHj":{"caption":"Vert. Dash Gridlines","name":"vertical_dashed_gridlines","rank":51,"editor":"DynamicValue","value":"boolean","default_val":false},"AHk":{"caption":"------------------------------ Data Labels ----------------------------","name":"---------------------------_data_labels_---------------------------","rank":57,"editor":"Label"},"AHl":{"caption":"Vertical Offset","name":"datalabel_offset","rank":62,"editor":"DynamicValue","value":"number","default_val":3},"AHm":{"caption":"Label Backgrnd Color","name":"datalabel_background_color","rank":65,"editor":"Color","default_val":"rgba(255, 255, 255, 0.32)","optional":false},"AHn":{"caption":"Font Color (Optional)","name":"datalabel_font_color","rank":68,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AHo":{"caption":"Font Color Setting","name":"font_color_setting","rank":67,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"AHp":{"caption":"Anchor","name":"datalabel_anchor","rank":59,"editor":"Dropdown","default_val":"end"},"AHq":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":27,"editor":"DynamicValue","value":"text","optional":true},"AHr":{"caption":"Font Size","name":"datalabel_size","rank":69,"editor":"DynamicValue","value":"number","default_val":12},"AHs":{"caption":"Series 6 - name","name":"series6name","rank":20,"editor":"DynamicValue","value":"text","optional":true,"default_val":"Series 6"},"AHt":{"caption":"Series 6 - color","name":"series6color","rank":21,"editor":"Color","default_val":"rgba(59, 227, 129, 1)","optional":true},"AHu":{"caption":"Series 6 - y-values","name":"series6","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AHv":{"caption":"-------------------- Line/Area Chart Settings ---------------------","name":"---------------------------Line---------------------------","rank":71,"editor":"Label"},"AHz":{"caption":"------------------------- Bar Chart Settings ------------------------","name":"-------------------------_barchart_settings_-------------------------","rank":77,"editor":"Label"},"AIA":{"caption":"Bar Width (Bar)","name":"bar_width","rank":78,"editor":"DynamicValue","value":"number","default_val":0.5},"AIB":{"caption":"Category Width (Bar)","name":"category_width","rank":81,"editor":"DynamicValue","value":"number","default_val":0.5},"AIC":{"caption":"Max Y Ticks","name":"max_y_ticks","rank":43,"editor":"DynamicValue","value":"number","default_val":11},"AID":{"caption":"Max X Ticks","name":"max_x_ticks","rank":42,"editor":"DynamicValue","value":"number","default_val":11},"AIE":{"caption":"Bar Width (px)","name":"bar_width_pixels","rank":79,"editor":"DynamicValue","value":"text","optional":true},"AIF":{"caption":"Chart Padding (px)","name":"chart_padding","rank":29,"editor":"DynamicValue","value":"number","default_val":10},"AIG":{"caption":"Bar Corner Radius","name":"bar_corner_radius","rank":80,"editor":"DynamicValue","value":"number","default_val":0},"AIH":{"caption":"Y Axis - Tick Length","name":"tick_mark_length_y","rank":41,"editor":"DynamicValue","value":"number","default_val":"0"},"AII":{"caption":"Label Border Color","name":"label_border_color","rank":66,"editor":"Color","default_val":"rgba(240, 240, 240, 0)"},"AIJ":{"caption":"â¹ï¸ To customize Tick Label Font Family, scroll down to the bottom of this properties menu and change the standard Bubble font properties. Please avoid using âApp Fontsâ (in other words, please select the exact font you want to use from the font menu)","name":"to_customize_the_axis_tick_label_font_style,_color,_and_size,_edit_this_element's_font_style,_color,_size_as_you_would_for_a_text_element_(by_scrolling_down_to_the_bottom_of_this_menu_and_editing_the_standard_bubble_properties)","rank":47,"editor":"Label"},"AIK":{"caption":"Draggable Values?","name":"draggable_values","rank":32,"editor":"DynamicValue","value":"boolean","default_val":false},"AIL":{"caption":"Drag Data Rounded","name":"drag_data_round","rank":33,"editor":"DynamicValue","value":"number","default_val":2},"AIM":{"caption":"â¹ï¸ Add more series to the chart using the workflow action called \"Add/update a data series\"","name":"-----_(you_can_also_add_infinite_series_via_w
197orkflows)_-----","rank":23,"editor":"Label"},"AIN":{"caption":"Tick Label Color","name":"tick_label_color","rank":45,"editor":"Color","default_val":"rgba(174, 185, 194, 1)","in_style":true},"AIO":{"caption":"Tick Label Font Size","name":"tick_label_font_size","rank":46,"editor":"DynamicValue","value":"number","default_val":12},"AIP":{"caption":"Span Gaps?","name":"span_gaps","rank":75,"editor":"DynamicValue","value":"boolean","default_val":false},"AIQ":{"caption":"X Tick Label Rotation","name":"x_ticks_rotation","rank":44,"editor":"DynamicValue","value":"number","optional":true},"AIR":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":60,"editor":"DynamicValue","value":"boolean","default_val":false},"AIS":{"caption":"Hide if Less Than","name":"hide_if_less_than","rank":61,"editor":"DynamicValue","value":"number","optional":true},"AIT":{"caption":"Decimal Place Char.","name":"decimal_place_character","rank":31,"editor":"DynamicValue","value":"text","default_val":"."},"AIU":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":24,"editor":"Label"},"AIV":{"caption":"â¹ï¸ Add series names, colors, and data values below. Each data point should be separated by comma and space and can be dynamic (e.g. \"Do a Search for\")","name":"----------------------------_series_colors_----------------------------","rank":4,"editor":"Label"},"AIW":{"caption":"â¹ï¸ Enter you chart's X-Axis values (the X-Axis labels that will go from left to right) separated by comma and space (\", \"). Can be a dynamic expression.","name":"â¹ï¸_add_series_data_values_below.__each_data_point_should_be_separated_by_comma_and_space_(\",_\")._you_can_dynamically_search_your_bubble_database_to_get_these_comma-separated_lists_(\"do_a_search_for...\")","rank":2,"editor":"Label"},"AIX":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"if_your_data_points_are_getting_cut_off_near_the_edges_of_the_chart_element,_increase_this_number","rank":28,"editor":"Label"},"AIY":{"caption":"â¹ï¸ For extra styling options (Area gradient, point border color, point images), add the data series using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_for_extra_styling_options_(area_gradient,_point_border_color,_point_images)_add_the_data_series_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":76,"editor":"Label"},"AIZ":{"caption":"â¹ï¸ For extra styling options (Bar gradient, different color bars in a single series), add the data series using the workflow action called \"Add/update a data series\"","name":"â¹ï¸_for_extra_styling_options_(area_gradient,_point_border_color,_point_images),_add_the_data_series_using_the_workflow_action_called_\"add/update_a_data_series\"","rank":82,"editor":"Label"},"AIa":{"caption":"yLabels Decimal Places","name":"y_labels_decimal_places","rank":56,"editor":"DynamicValue","value":"number","optional":true},"AIb":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":70,"editor":"Dropdown","default_val":" 400"},"AIc":{"caption":"Legend Color Style","name":"legend_color_style","rank":26,"editor":"Dropdown","default_val":"Circle"}},"states":{"AId":{"caption":"Clicked Item X Value","initialization_code":{"fn":"function(properties,context){}"},"name":"clicked_item_x_value","value":"text"},"AIe":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIf":{"caption":"Clicked Item Series Name","name":"clicked_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIg":{"caption":"Hovered Item X Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIh":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIi":{"caption":"Hovered Item Series Name","name":"hovered_item_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIj":{"caption":"Hovered Item Series Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIk":{"caption":"Clicked Item Series Color","name":"clicked_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIl":{"caption":"Clicked Item All Series Values","name":"click_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIm":{"caption":"Clicked Item All Series Colors","name":"clicked_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIn":{"caption":"Clicked Item All Series Names","name":"clicked_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIo":{"caption":"Hovered Item All Series Values","name":"hovered_item_other_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIp":{"caption":"Hovered Item All Series Colors","name":"hovered_item_other_series_colors","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIq":{"caption":"Hovered Item All Series Names","name":"hovered_item_other_series_names","value":"text","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIr":{"caption":"Chart Loaded?","name":"chart_loaded","value":"boolean","initialization_code":{"fn":"function(properties,context){return!1}"}}
197,"AIs":{"caption":"Hovered Item X Index","name":"hovered_item_x_index","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIt":{"caption":"Dragged Item Data Series Name","name":"dragged_item_data_series_name","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIu":{"caption":"Dragged Item Index Number","name":"dragged_item_index_number","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIv":{"caption":"Dragged Item - X Value","name":"dragged_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AIw":{"caption":"Dragged Value - Starting Value","name":"dragged_item_starting_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIx":{"caption":"Dragged Value - Ending Value","name":"dragged_item_ending_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AIy":{"caption":"Dragged Item - All of this Series' Y Values","name":"dragged_item_all_series_values","value":"number","initialization_code":{"fn":"function(properties,context){}"},"is_list":true},"AIz":{"caption":"Currently Dragging Bar/Value","name":"currently_dragging","value":"boolean","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"AGs":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"AGt":{"caption":"Chart Value Hovered","name":"chart_value_hovered"},"AGu":{"caption":"Chart Value Dragged","name":"chart_value_dragged"}},"actions":{"AGR":{"caption":"Add/Update a Data Series","code":{"fn":"function(instance,properties,context){instance.publishState(\"chart_loaded\",!1);let numAttempts=0;function mainAddSeries(){if(numAttempts>15)return void console.log(\"The Chart you are trying to update is not visible on the page\");if(!instance.data.chart)return numAttempts++,void setTimeout(mainAddSeries,750);let customChartType=instance.data.chartType,backgroundColors,pointImage;function addSeries(){if(instance.data.createDataArray){let newSeries=instance.data.createDataArray(properties.yValues);instance.data.pushDataset(properties.series_name,newSeries,properties.series_color,customChartType,properties.point_color_line,properties.point_border_color_line,backgroundColors,pointImage,properties.chart_type,properties.bar_outline_color),instance.data.updateChartDatasets(),instance.data.chart.update()}else setTimeout(addSeries,1500)}if(properties.background_colors&&(backgroundColors=instance.data.createDataArray(properties.background_colors)),null!=properties.chart_type&&(properties.chart_type.toLowerCase()!=instance.data.chartType&&(customChartType=properties.chart_type.toLowerCase()),\"area\"==customChartType&&(customChartType=\"line\")),pointImage=properties.point_style,properties.use_image_as_point&&(pointImage=new Image(1,1),pointImage.src=properties.use_image_as_point,pointImage.onload=function(){var width=pointImage.naturalWidth,height=pointImage.naturalHeight;pointImage.width=width*properties.image_scale,pointImage.height=height*properties.image_scale}),addSeries(),\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain||\"Bar\"==properties.chart_type||\"Bar\"==instance.data.originalChartTypeMain){let mycanvas;var chart_gradient=document.getElementById(instance.data.uniqueChartId).getContext(\"2d\").createLinearGradient(0,0,0,instance.data.height);(\"Area\"==properties.chart_type||\"Area\"==instance.data.originalChartTypeMain&&\"Bar\"!=properties.chart_type)&&(chart_gradient.addColorStop(0,properties.area_chart_start_color),chart_gradient.addColorStop(.5,properties.area_chart_middle_color),chart_gradient.addColorStop(1,properties.area_chart_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),(\"Bar\"==properties.chart_type&&!properties.background_colors||\"Bar\"==instance.data.originalChartTypeMain&&\"Area\"!=properties.chart_type&&!properties.background_colors)&&properties.bar_gradient&&(chart_gradient.addColorStop(0,properties.bar_gradient_start_color),chart_gradient.addColorStop(.6,properties.bar_gradient_middle_color),chart_gradient.addColorStop(1,properties.bar_gradient_end_color),instance.data.chart.data.datasets[instance.data.chart.data.datasets.length-1].backgroundColor=chart_gradient),instance.data.chart.update(
197)}}mainAddSeries(),instance.publishState(\"chart_loaded\",!0)}"},"fields":{"AGS":{"caption":"Series Name","name":"series_name","rank":1,"editor":"DynamicValue","value":"text"},"AGT":{"caption":"Series Color","name":"series_color","rank":4,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AGU":{"caption":"Series Y Values","name":"yValues","rank":2,"editor":"DynamicValue","value":"text"},"AGV":{"caption":"Chart Type","name":"chart_type","rank":3,"editor":"Dropdown","optional":true},"AGW":{"caption":"Point Color","name":"point_color_line","rank":6,"editor":"Color","default_val":"rgba(255, 255, 255, 1)","optional":true},"AGX":{"caption":"Point Border Color","name":"point_border_color_line","rank":7,"editor":"Color","default_val":"rgba(51, 181, 229, 1)","optional":true},"AGY":{"caption":"------------------------- General Settings -------------------------","name":"-------------------------_general_settings_-------------------------","rank":0,"editor":"Label"},"AGZ":{"caption":"-------------------- Line/Area Series Settings --------------------","name":"-------------------------_line_chart_settings_------------------------","rank":5,"editor":"Label"},"AGa":{"caption":"Multi-Colored Series (comma-separated hex codes)","name":"background_colors","rank":22,"editor":"DynamicValue","value":"text","optional":true},"AGb":{"caption":"-------------------------- Bar Series Settings -----------------------","name":"--------------------------_bar_chart_settings_-----------------------","rank":16,"editor":"Label"},"AGc":{"caption":" ","name":"use_image_as_point","rank":13,"editor":"DynamicValue","value":"image","optional":true},"AGd":{"caption":"Image Point Scale","name":"image_scale","rank":14,"editor":"DynamicValue","value":"number","optional":false,"default_val":1},"AGe":{"caption":"Gradient Start Color","name":"area_chart_start_color","rank":8,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AGf":{"caption":"Gradient End Color","name":"area_chart_end_color","rank":10,"editor":"Color","default_val":"rgba(51, 181, 229, 0)"},"AGg":{"caption":"Use Image as Point. Below you can upload an image (or use dynamic one) to set the image instead of having a circle for line chart points","name":"use_image_as_point.__below_you_can_upload_an_image_(or_use_dynamic_one)_to_set_the_","rank":12,"editor":"Label"},"AGh":{"caption":" ","name":"_","rank":15,"editor":"Label"},"AGi":{"caption":"Gradient Middle Color","name":"area_chart_middle_color","rank":9,"editor":"Color","default_val":"rgba(51, 179, 230, 0.58)"},"AGj":{"caption":"The field below is optional: for multi-colored series (overrides colors set above)","name":"info","rank":21,"editor":"Label"},"AGk":{"caption":"Gradient Start Color","name":"bar_gradient_start_color","rank":18,"editor":"Color","default_val":"rgba(51, 181, 229, 1)"},"AGl":{"caption":"Gradient End Color","name":"bar_gradient_end_color","rank":20,"editor":"Color","default_val":"rgba(51,181,229,0.1)"},"AGm":{"caption":"Bar Gradient Middle Color","name":"bar_gradient_middle_color","rank":19,"editor":"Color","default_val":"rgba(51,179,230,0.5)"},"AGn":{"caption":"Bar Gradient?","name":"bar_gradient","rank":17,"editor":"Checkbox","default_val":false},"AGo":{"caption":"Point Style","name":"point_style","rank":11,"editor":"Dropdown","default_val":"circle"}}},"AGp":{"caption":"Remove a Data Series","code":{"fn":"function(instance,properties,context){if(instance.data.chart){let foundSeries=instance.data.chart.data.datasets.find((element=>element.label==properties.data_series_name));null!=foundSeries&&(instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1),instance.data.updateChartDatasets()),instance.data.chart.update()}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"},"fields":{"AGq":{"caption":"Data Series Name","name":"data_series_name","rank":0,"editor":"DynamicValue","value":"text"}}},"AGr":{"caption":"Remove all Data Series (Clear Chart)","code":{"fn":"function(instance,properties,context){if(instance.data.chart){for(;instance.data.datasets.length>0;)instance.data.datasets.pop();for(;instance.data.chart.data.datasets.length>0;)instance.data.chart.data.datasets.pop(),instance.data.chart.update(
197)}else console.log(\"The Chart you are trying to clear is not visible on the page\")}"}}},"code":{"initialize":{"fn":"function(instance,context){instance.publishState(\"chart_loaded\",!1),instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function reduceOpacity(originalRGBAColor,scale){if(6==originalRGBAColor.length||7==originalRGBAColor.length){function hexToRgb(hex){var result=/^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);originalRGBAColor=\"rgba(\"+parseInt(result[1],16)+\", \"+parseInt(result[2],16)+\", \"+parseInt(result[3],16)+\", 1)\"}hexToRgb(originalRGBAColor)}let stringlength=originalRGBAColor.length-1,colorArray=(originalRGBAColor=originalRGBAColor.substring(5,stringlength)).split(\", \"),newOpacity=scale*colorArray[3],result;return\"rgba(\"+colorArray[0]+\", \"+colorArray[1]+\", \"+colorArray[2]+\", \"+newOpacity+\")\"}function updateChartDatasets(){let i;for(instance.data.chart.data.datasets=[],i=0;i<instance.data.datasets.length;i++)instance.data.chart.data.datasets.push(instance.data.datasets[i]),instance.data.chartType.includes(\"Area\")&&(instance.data.datasets[i].backgroundColor=instance.data.reduceOpacity(instance.data.datasets[i].borderColor,.5),instance.data.datasets[i].fill=\"origin\"),instance.data.chartType.includes(\"Line\")&&(instance.data.datasets[i].fill=!1)}function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),instance.data.datasets=[],instance.data.reduceOpacity=reduceOpacity,instance.data.updateChartDatasets=updateChartDatasets,setTimeout(forceUpdate,200)}","add_debugger":false},"update":{"fn":"function(instance,properties,context){if(Chart.plugins.unregister(ChartDataLabels),instance.data.justDragged)return void(instance.data.justDAragged=!1);if(null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),$(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height(),divWidth=$(\"#\"+properties.custom_tooltip_id).width(),xOffset=15,yOffset=divHeight/2;e.clientX+xOffset+divWidth>screen.width&&(xOffset=-1*(25+divWidth),0>e.clientX-(divWidth+25)&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=-15),screen.height<divHeight+e.clientY&&e.clientY-divHeight/2>0&&(xOffset=divWidth/2*-1,yOffset=divHeight+15)),e.clientY-divHeight/2<0&&(yOffset=0),$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+xOffset,top:e.clientY-yOffset,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId);instance.data.mainChartCanvas=chartcanvas;var ctxchart=chartcanvas.getContext(\"2d\");let chartType,legendState,showLegend;function createDataArray(xString){if(!xString)return null;const spanGaps=properties.span_gaps,chartType=properties.chartType,isLineChart=[\"Area\",\"Line\",\"Stepped Line (Step Before)\",\"Stepped Line (Step After)\"].includes(chartType),xArray=undefined;return xString.split(\",\").map((item=>{const trimmedItem=item.trim();return spanGaps&&isLineChart&&!trimmedItem?null:trimmedItem}))}instance.data.originalChartTypeMain=properties.chartType,chartType=properties.chartType.toLowerCase(),\"Horizontal Bar\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"100% Stacked Bar (Horizontal)\"==properties.chartType&&(chartType=\"horizontalBar\"),\"Area\"==properties.chartType&&(chartType=\"line\"),\"Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"100% Stacked Bar\"==properties.chartType&&(chartType=\"bar\"),\"Stacked Area\"==properties.chartType&&(chartType=\"line\"),\"Stepped Line (Step Before)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"before\"),\"Stepped Line (Step After)\"==properties.chartType&&(chartType=\"line\",instance.data.steppedLine=\"after\"),\"Don't Show Legend\"==properties.showLegend?showLegend=!1:(legendState=properties.showLegend.toLowerCase(),showLegend=!0),instance.data.createDataArray=createDataArray;let listofxvalues,arrayofxvalues=createDataArray(properties.xvalues),series1string=properties.series1,series1array,series2array,series3array,series4array,series5array,series6array,yMin,yMax;series1array=createDataArray(properties.series1),series2array=createDataArray(properties.series2),series3array=createDataArray(properties.series3),series4array=createDataArray(properties.series4),series5array=createDataArray(properties.series5),series6array=createDataArray(properties.series6);let allYValuesArray=series1array,chartLabelsOn;properties.show_data_labels&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]),instance.data.horizontalGridlineColor=properties.horiz_gridlines_color,
197instance.data.verticalGridlineColor=properties.vert_gridlines_color;let horizDashed=[],vertDashed=[];properties.horizontal_dashed_gridlines&&(horizDashed=[8,4]),properties.vertical_dashed_gridlines&&(vertDashed=[8,4]);let hundredPercentStacked=!1;\"100% Stacked Bar (Horizontal)\"!=properties.chartType&&\"100% Stacked Bar\"!=properties.chartType||(hundredPercentStacked=!0);let customTooltip=!1,chartTooltipMode;null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),chartTooltipMode=\"horizontalBar\"!=chartType?\"interpolate\":\"nearest\";var chart=new Chart(instance.data.ctxChartState,{plugins:chartLabelsOn,type:chartType,data:{labels:arrayofxvalues},options:{annotation:{annotations:[{drawTime:\"afterDatasetsDraw\",type:\"line\",mode:\"horizontal\",scaleID:\"y\",value:200,endValue:205,borderWidth:5,borderColor:\"red\",label:{content:\"TODAY\",enabled:!0,position:\"top\"}}]},spanGaps:properties.span_gaps,dragData:properties.draggable_values,onDrag:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data;for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i]&&\" \"!=draggedItemAllSeriesValues[i]||(draggedItemAllSeriesValues[i]=0);instance.publishState(\"dragged_item_data_series_name\",instance.data.datasets[datasetIndex].label),instance.publishState(\"dragged_item_index_number\",index+1),instance.publishState(\"dragged_item_x_value\",arrayofxvalues[index]),instance.publishState(\"dragged_item_ending_value\",value),instance.publishState(\"dragged_item_all_series_values\",draggedItemAllSeriesValues),instance.triggerEvent(\"chart_value_dragged\",(function(err){})),instance.publishState(\"currently_dragging\",!0)},onDragEnd:function(e,datasetIndex,index,value){let draggedItemAllSeriesValues=instance.data.datasets[datasetIndex].data;for(i=0;i<draggedItemAllSeriesValues.length;i++)\"\"!=draggedItemAllSeriesValues[i]&&\" \"!=draggedItemAllSeriesValues[i]||(draggedItemAllSeriesValues[i]=0);instance.publishState(\"dragged_item_starting_value\",instance.data.datasets[datasetIndex].data[index]),instance.publishState(\"currently_dragging\",!1),instance.data.justDragged=!0},dragDataRound:properties.drag_data_round,cornerRadius:properties.bar_corner_radius,animation:{duration:properties.animation_duration},onHover:function(event,elements){if(properties.draggable_values?$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"grab\":\"default\"):customTooltip&&null==document.getElementById(properties.custom_tooltip_id)?$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",(elements[0],\"default\")):$(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex];\"\"!=value&&\" \"!=value||(value=0);var series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.borderColor;null!=activePoint[0].$previousStyle&&(series_color=activePoint[0].$previousStyle.backgroundColor);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"!=remainingSeriesValues[i]&&\" \"!=remainingSeriesValues[i]||(remainingSeriesValues[i]=0);instance.publishState(\"hovered_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"hovered_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"hovered_item_other_series_names\",remainingSeriesNames),instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_name\",series_name),instance.publishState(\"hovered_item_series_color\",series_color),instance.publishState(\"hovered_item_x_index\",clickedElementindex+1),customTooltip&&null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+properties.custom_tooltip_id).fadeIn(250),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\")}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))}
197,legend:{display:showLegend,position:legendState,labels:{usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},layout:{padding:{right:properties.chart_padding,left:properties.chart_padding,top:properties.chart_padding,bottom:properties.chart_padding}},maintainAspectRatio:!1,scales:{yAxes:[{yAxixID:\"y\",stacked:\"Stacked Bar\"==properties.chartType||\"Stacked Area\"==properties.chartType||\"Stacked Bar (Horizontal)\"==properties.chartType||\"100% Stacked Bar\"==properties.chartType||\"100% Stacked Bar (Horizontal)\"==properties.chartType,gridLines:{borderDash:horizDashed,drawBorder:!1,color:\"rgba(0,0,0,0)\",zeroLineColor:\"rgba(0,0,0,0)\",zeroLineWidth:properties.y_zero_line_width,tickMarkLength:properties.tick_mark_length_y},ticks:{maxTicksLimit:properties.max_y_ticks,padding:7,display:!1,fontColor:properties.tick_label_color,fontSize:properties.tick_label_font_size,fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callback:function(value,index,values){let yLabel=value,originalYLabel=value;return value<1&&value>-1&&0!=value&&(yLabel=value.toPrecision(1)),value>1&&value<2&&(yLabel=value.toPrecision(2)),null!=properties.y_labels_decimal_places&&(yLabel=parseFloat(yLabel).toFixed(properties.y_labels_decimal_places)),yLabel=yLabel.toString(),null!=properties.thousands_separator&&(yLabel=yLabel.includes(\".\")?yLabel.substring(0,yLabel.indexOf(\".\")).replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)+properties.decimal_place_character+yLabel.substring(yLabel.indexOf(\".\")+1):yLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(yLabel=properties.yAxisUnitBeforeNumber+yLabel),properties.yAxisUnitAfterNumber&&(yLabel+=properties.yAxisUnitAfterNumber),\"horizontalBar\"==chartType?originalYLabel:yLabel}}}],xAxes:[{stacked:\"Stacked Bar\"==properties.chartType||\"Stacked Area\"==properties.chartType||\"Stacked Bar (Horizontal)\"==properties.chartType||\"100% Stacked Bar\"==properties.chartType||\"100% Stacked Bar (Horizontal)\"==properties.chartType,gridLines:{borderDash:vertDashed,drawBorder:!1,color:instance.data.verticalGridlineColor,zeroLineColor:properties.x_zero_line_color,tickMarkLength:0,zeroLineWidth:properties.x_zero_line_width},ticks:{maxTicksLimit:properties.max_x_ticks,padding:7,display:properties.show_x_tick_labels,fontColor:properties.tick_label_color,fontFamily:properties.bubble.font_face().split(\":\")[0],fontSize:properties.tick_label_font_size,callback:function(value,index,values){let originalXLabel=value,xLabel=value;if(null!=xLabel)return value<1&&value>-1&&0!=value&&(xLabel=value.toPrecision(1)),value>1&&value<2&&(xLabel=value.toPrecision(2)),xLabel=xLabel.toString(),null!=properties.thousands_separator&&(xLabel=xLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(xLabel=properties.yAxisUnitBeforeNumber+xLabel),properties.yAxisUnitAfterNumber&&(xLabel+=properties.yAxisUnitAfterNumber),\"horizontalBar\"==chartType?xLabel:originalXLabel}}}]},plugins:{stacked100:{enable:hundredPercentStacked},crosshair:!1},tooltips:{intersect:!1,enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let beforeDecimal=Math.floor(parseFloat(tooltipItem.value));parseFloat(tooltipItem.value)<0&&(beforeDecimal=Math.ceil(parseFloat(tooltipItem.value)));let afterDecimalCalc=parseFloat(tooltipItem.value)-parseFloat(beforeDecimal),numDecimalPlaces,afterDecimal,commaValue,finalLabel;return numDecimalPlaces=-1!=tooltipItem.value.indexOf(\".\")?tooltipItem.value.substring(tooltipItem.value.indexOf(\".\")+1).length:0,numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before&&(beforeDecimal=properties.data_labels_unit_before+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),properties.data_labels_unit_after&&(finalLabel+=properties.data_labels_unit_after),finalLabel}}}}});instance.data.chartType=chartType,\"horizontalBar\"!=chartType?(null!=properties.yMaxNum&&(chart.options.scales.yAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.yAxes[0].ticks.min=properties.yMinNum)):(null!=properties.yMaxNum&&(chart.options.scales.xAxes[0].ticks.max=properties.yMaxNum),null!=properties.yMinNum&&(chart.options.scales.xAxes[0].ticks.min=properties.yMinNum));var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);let showDataLabelsOverlap;function pushDataset(dataLabel,newData,newColor,customChartType,pointBackgroun
197dColor,pointBorderColor,backgroundColorArray,pointImage,actionChartType,barBorderColor){let chart_type,customType;chart_type=chartType?customChartType:properties.chart_type,customChartType&&(customType=!0);let myDataset={data:newData,customType:customType,type:customChartType,label:dataLabel,steppedLine:instance.data.steppedLine,backgroundColor:function(value){return value=properties.chartType.includes(\"Area\")?instance.data.reduceOpacity(newColor,.5):!backgroundColorArray||\"Bar\"!=properties.chartType&&\"Horizontal Bar\"!=properties.chartType?newColor:backgroundColorArray},fill:function(value){return value=!(!properties.chartType.includes(\"Area\")&&\"Area\"!=actionChartType)&&\"origin\"},borderWidth:function(value){return value=chartType.includes(\"area\")||chartType.includes(\"line\")?properties.border_width:0},lineTension:properties.curve_line_charts,borderColor:newColor,pointBorderColor:function(value){return value=pointBorderColor||\"#FFFFFF\"},pointBackgroundColor:function(value){return value=null!=pointBackgroun
197dColor?pointBackgroundColor:newColor},pointStyle:pointImage,pointBorderWidth:properties.point_border_width,pointRadius:properties.line_point_radius,pointHitRadius:20,pointHoverRadius:properties.point_hover_radius,barPercentage:properties.bar_width,categoryPercentage:properties.category_width,barThickness:properties.bar_width_pixels,datalabels:{display:showDataLabelsOverlap,color:function(value){return value=\"Default (Same as Series Color)\"!=properties.font_color_setting?properties.datalabel_font_color:newColor},align:function(value){return\"end\"},font:{size:properties.datalabel_size,family:properties.bubble.font_face().split(\":\")[0],weight:properties.datalabel_fontweight},anchor:function(context){return properties.chartType.includes(\"horizontal\"),context.dataset.data[context.dataIndex]<0?\"end\"==properties.datalabel_anchor?\"start\":\"start\"==properties.datalabel_anchor?\"end\":properties.datalabel_anchor:properties.datalabel_anchor},formatter:function(value){if(instance.data.data_label_value=value,Math.abs(value)<properties.hide_if_less_than)return\"\";if(\"\"==value||\" \"==value)return\"\";let beforeDecimal=Math.floor(parseFloat(value));parseFloat(value)<0&&(beforeDecimal=Math.ceil(parseFloat(value)));let afterDecimalCalc=parseFloat(value)-parseFloat(beforeDecimal),numDecimalPlaces,valueString,afterDecimal,commaValue,finalLabel;return valueString=value.toString(),numDecimalPlaces=-1!=valueString.indexOf(\".\")?valueString.substring(valueString.indexOf(\".\")+1).length:0,numDecimalPlaces>0?(afterDecimal=afterDecimalCalc.toFixed(numDecimalPlaces),afterDecimal=afterDecimal.split(\".\")[1]):afterDecimal=afterDecimalCalc=\"\",null!=properties.thousands_separator&&(beforeDecimal=beforeDecimal.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.data_labels_unit_before?parseFloat(value)<0?(beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+properties.data_labels_unit_before+beforeDecimal):beforeDecimal=properties.data_labels_unit_before+beforeDecimal:parseFloat(value)<0&&(parseFloat(value)>-1&&(beforeDecimal=\"0\"+beforeDecimal),beforeDecimal=beforeDecimal.substring(1),beforeDecimal=\"-\"+beforeDecimal),beforeDecimal&&(finalLabel=beforeDecimal),\"\"!=afterDecimal&&(finalLabel=finalLabel+properties.decimal_place_character+afterDecimal),properties.data_labels_unit_after&&(finalLabel+=properties.data_labels_unit_after),finalLabel},offset:function(context){return context.dataset.data[context.dataIndex]<0?-1*(properties.datalabel_offset+1.25*properties.datalabel_size):properties.datalabel_offset},borderWidth:\"1\",borderRadius:\"3\",borderColor:function(value){return instance.data.data_label_value>properties.hide_if_less_than?properties.label_border_color:\"rgba(0, 0, 0, 0)\"},backgroundColor:function(value){return Math.abs(instance.data.data_label_value)>properties.hide_if_less_than?(instance.data.mycolor=properties.datalabel_background_color,instance.data.mycolor):\"rgba(0, 0, 0, 0)\"},padding:\"1\"}};if(instance.data.datasets.find((element=>element.label==dataLabel))){let foundSeries=instance.data.datasets.find((element=>element.label==dataLabel));null!=foundSeries&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries),1)}instance.data.datasets.push(myDataset)}function removeOldSeriesProperty(seriesName){let foundSeries_originalproperty=instance.data.datasets.find((element=>element.label==seriesName));null!=foundSeries_originalproperty&&instance.data.datasets.splice(instance.data.datasets.indexOf(foundSeries_originalproperty),1)}function updateStyle(chart){chart.options.scales.yAxes[0].gridLines.zeroLineColor=properties.y_zero_line_color,chart.options.scales.yAxes[0].ticks.display=properties.show_y_tick_labels,chart.options.scales.yAxes[0].gridLines.color=instance.data.horizontalGridlineColor}function animate1(){instance.data.updateChartDatasets(),updateStyle(instance.data.chart),instance.data.chart.update()}chartContainer.parentNode.removeChild(chartContainer),(chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId)).style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",instance.data.height=properties.bubble.height(),instance.data.mainCh
197artCanvas.style.borderRadius=properties.bubble.border_roundness(),instance.data.lineWidth=properties.border_width,null!=properties.x_ticks_rotation&&(chart.options.scales.xAxes[0].ticks.minRotation=properties.x_ticks_rotation,chart.options.scales.xAxes[0].ticks.maxRotation=properties.x_ticks_rotation),showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\",instance.data.pushDataset=pushDataset,removeOldSeriesProperty(instance.data.series1_oldname),removeOldSeriesProperty(instance.data.series2_oldname),removeOldSeriesProperty(instance.data.series3_oldname),removeOldSeriesProperty(instance.data.series4_oldname),removeOldSeriesProperty(instance.data.series5_oldname),removeOldSeriesProperty(instance.data.series6_oldname),properties.series1&&(properties.series1name?(pushDataset(properties.series1name,series1array,properties.series1color),instance.data.series1_oldname=properties.series1name):(instance.data.series1_oldname=\"Series 1\",pushDataset(instance.data.series1_oldname,series1array,properties.series1color))),properties.series2&&(properties.series2name?(pushDataset(properties.series2name,series2array,properties.series2color),instance.data.series2_oldname=properties.series2name):(instance.data.series2_oldname=\"Series 2\",pushDataset(instance.data.series2_oldname,series2array,properties.series2color))),properties.series3&&(properties.series3name?(pushDataset(properties.series3name,series3array,properties.series3color),instance.data.series3_oldname=properties.series3name):(instance.data.series3_oldname=\"Series 3\",pushDataset(instance.data.series3_oldname,series3array,properties.series3color))),properties.series4&&(properties.series4name?(pushDataset(properties.series4name,series4array,properties.series4color),instance.data.series4_oldname=properties.series4name):(instance.data.series4_oldname=\"Series 4\",pushDataset(instance.data.series4_oldname,series4array,properties.series4color))),properties.series5&&(properties.series5name?(pushDataset(properties.series5name,series5array,properties.series5color),instance.data.series5_oldname=properties.series5name):(instance.data.series5_oldname=\"Series 5\",pushDataset(instance.data.series5_oldname,series5array,properties.series5color))),properties.series6&&(properties.series6name?(pushDataset(properties.series6name,series6array,properties.series6color),instance.data.series6_oldname=properties.series6name):(instance.data.series6_oldname=\"Series 6\",pushDataset(instance.data.series6_oldname,series6array,properties.series6color))),document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(evt);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex];\"\"!=value&&\" \"!=value||(value=0);var series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._model.backgroundColor;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value),instance.publishState(\"clicked_item_series_name\",series_name),instance.publishState(\"clicked_item_series_color\",series_color);let remainingSeriesObjects=chart.data.datasets.slice(),remainingSeriesValues=remainingSeriesObjects.map((a=>a.data[clickedElementindex])),i;for(i=0;i<remainingSeriesValues.length;i++)\"\"!=remainingSeriesValues[i]&&\" \"!=remainingSeriesValues[i]||(remainingSeriesValues[i]=0);instance.publishState(\"click_item_other_series_values\",remainingSeriesValues);let remainingSeriesColors=remainingSeriesObjects.map((a=>a.borderColor));instance.publishState(\"clicked_item_other_series_colors\",remainingSeriesColors);let remainingSeriesNames=remainingSeriesObjects.map((a=>a.label));instance.publishState(\"clicked_item_other_series_names\",remainingSeriesNames)}else null!=document.getElementById(properties.custom_tooltip_id)&&$(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&series_name&&instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},instance.data.chart=chart,setTimeout(animate1,300),setTimeout(animate1,1e3),setTimeout(animate1,5e3),instance.publishState(\"chart_loaded\",!0)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Bar/Line/Area Chart';
197\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"}},"platform_type":"web"},"AQf":{"display":"Chart - Pie/Donut","property_applications":{"MinWidth":true,"resizable":true,"Font":true,"Border":true},"add_hover_pressed":false,"add_is_visible":true,"support_autobinding":false,"has_reset_fn":false,"fields":{"APj":{"caption":"Series Labels","default_val":"Category A, Category B, Category C, Category D","editor":"DynamicValue","is_list":false,"name":"chartlabels","rank":2,"value":"text"},"APk":{"caption":"Series Values","default_val":"2525, 743, 431, 1540","editor":"DynamicValue","name":"series1","rank":3,"value":"text"},"APl":{"caption":"Value's Colors","default_val":"#00A2FF, #24E082, #FF8961, #BC61E6","editor":"DynamicValue","is_list":false,"name":"series1color","rank":4,"value":"text"},"APm":{"caption":"Tooltip Unit - Before","editor":"DynamicValue","name":"yAxisUnitBeforeNumber","optional":true,"rank":38,"value":"text"},"APn":{"caption":"Tooltip Unit - After","editor":"DynamicValue","is_list":false,"name":"yAxisUnitAfterNumber","optional":true,"rank":39,"value":"text"},"APo":{"caption":"labelValue: Unit Before","default_val":"$","editor":"DynamicValue","name":"data_label_unit_before","rank":26,"value":"text"},"APp":{"caption":"labelValue: Unit After","default_val":" USD","editor":"DynamicValue","name":"data_label_unit_after","rank":27,"value":"text"},"APq":{"caption":"Show/Hide Legend","name":"showLegend2","rank":6,"editor":"Dropdown","default_val":"Top"},"APr":{"caption":"Section Border Width","name":"section_border_width","rank":18,"editor":"DynamicValue","value":"number","default_val":5},"APs":{"caption":"Section Border Color","name":"section_border_color","rank":19,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"APt":{"caption":"Cutout Percentage","name":"cutout_percentage","rank":17,"editor":"DynamicValue","value":"number","default_val":82},"APu":{"caption":"-------------------------- General Settings --------------------------","name":"-------------------------_general_settings_-------------------------","rank":5,"editor":"Label"},"APv":{"caption":"---------------------------- Chart Styling ----------------------------","name":"-------------------------_chart_styling_-------------------------","rank":16,"editor":"Label"},"APw":{"caption":"-------------------------- Tooltip Settings ---------------------------","name":"-------------------------_tooltip_settings_-------------------------","rank":37,"editor":"Label"},"APx":{"caption":"Thousands Separator","name":"thousands_separator","rank":12,"editor":"DynamicValue","value":"text","default_val":",","optional":true},"APy":{"caption":"Hover Border Width","name":"hover_border_width","rank":21,"editor":"DynamicValue","value":"number","optional":false,"default_val":3},"APz":{"caption":"----------------------------- Data Labels ------------------------------","name":"--------------------------_data_labels_---------------------------","rank":23,"editor":"Label"},"AQA":{"caption":"Font Color","name":"datalabel_font_color","rank":34,"editor":"Color","default_val":"rgba(255, 255, 255, 1)"},"AQB":{"caption":"Anchor","name":"anchor","rank":31,"editor":"Dropdown","default_val":"end"},"AQC":{"caption":"Font Color Setting","name":"font_color_setting","rank":33,"editor":"Dropdown","default_val":"Default (Same as Series Color)"},"AQD":{"caption":"Offset","name":"offset","rank":32,"editor":"DynamicValue","value":"number","default_val":3},"AQE":{"caption":"Custom Tooltip ID","name":"custom_tooltip_id","rank":11,"editor":"DynamicValue","value":"text","optional":true},"AQF":{"caption":"Font Size","name":"datalabel_size","rank":35,"editor":"DynamicValue","value":"number","default_val":12},"AQG":{"caption":"Section Corner Roundness","name":"section_corner_roundness","rank":41,"editor":"Dropdown","default_val":"Square Corners"},"AQH":{"caption":"Round Corner Section#","name":"rounded_corner_section_number","rank":42,"editor":"DynamicValue","value":"number","default_val":0},"AQI":{"caption":"------------------ Section Corner Roundness -------------------","name":"---------------------_section_corner_roundness_----------------------","rank":40,"editor":"Label"},"AQJ":{"caption":"Chart Padding","name":"padding","rank":14,"editor":"DynamicValue","value":"number","default_val":15},"AQK":{"caption":"Rotation","name":"rotation","rank":22,"editor":"DynamicValue","value":"number","default_val":0},"AQL":{"caption":"Total Circumference","name":"total_circumference","rank":20,"editor":"DynamicValue","value":"number","default_val":360},"AQM":{"caption":"Hide Overlap'd Labels","name":"hide_datalabels_overlap","rank":29,"editor":"DynamicValue","value":"boolean","default_val":false},"AQN":{"caption":"Legend Padding","name":"legend_padding","rank":10,"editor":"DynamicValue","value":"number","default_val":0},"AQO":{"caption":"Hide Labels Less Than #","name":"hide_if_less_than","rank":30,"editor":"DynamicValue","value":"number","optional":true},"AQP":{"caption":"Animation Duration","name":"animation_duration","rank":15,"editor":"DynamicValue","value":"number","default_val":1500},"AQQ":{"caption":"Legend Font Color","name":"legend_font_color","rank":8,"editor":"Color","default_val":"rgba(174, 185, 194, 1)"},"AQR":{"caption":"Hide from Legend if <","name":"hide_from_legend_if_less_than","rank":9,"editor":"DynamicValue","value":"number","optional":true},"AQS":{"caption":"----------------------------- Chart Data -----------------------------","name":"-----------------------------_chart_data_-----------------------------","rank":0,"editor":"Label"}
197,"AQT":{"caption":"â¹ï¸ Enter your chart's labels, values, and colors. Values in each list should be comma-separated (with comma and space \", \"). The 1st item in the \"Series Labels\" list matches with the 1st item in \"Series Values\" and \"Value's Colors\" lists; the 2nd items all match with each other, and so on","name":"â¹ï¸_enter_you_chart's_x-axis_values_(the_x-axis_labels_that_will_go_from_left_to_right)_separated_by_comma_and_space_(\",_\").__can_be_a_dynamic_expression.","rank":1,"editor":"Label"},"AQU":{"caption":"â ï¸ If data points get cut off near edges of the chart element, increase the Chart Padding below:","name":"â ï¸_if_data_points_get_cut_off_near_edges_of_the_chart_element,_increase_the_chart_padding_below:","rank":13,"editor":"Label"},"AQV":{"caption":"Data Label Text","name":"data_label_text","rank":25,"editor":"DynamicValue","value":"text","optional":true,"default_val":"labelPercent, labelValue, labelName"},"AQW":{"caption":"Show Data Label?","name":"show_label","rank":24,"editor":"DynamicValue","value":"boolean","default_val":false},"AQX":{"caption":"Percent Decimal Places","name":"labelpercent_decimal","rank":28,"editor":"DynamicValue","value":"number","default_val":2},"AQY":{"caption":"Label Font Weight","name":"datalabel_fontweight","rank":36,"editor":"Dropdown","default_val":" 400","in_style":false},"AQZ":{"caption":"Legend Color Style","name":"legend_color_style","rank":7,"editor":"Dropdown","default_val":"Circle"}},"states":{"AQa":{"caption":"Clicked Item Label Value","name":"clicked_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQb":{"caption":"Clicked Item Y Value","name":"clicked_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AQc":{"caption":"Hovered Item Label Value","name":"hovered_item_x_value","value":"text","initialization_code":{"fn":"function(properties,context){}"}},"AQd":{"caption":"Hovered Item Y Value","name":"hovered_item_y_value","value":"number","initialization_code":{"fn":"function(properties,context){}"}},"AQe":{"caption":"Hovered Item Color","name":"hovered_item_series_color","value":"text","initialization_code":{"fn":"function(properties,context){}"}}},"events":{"APh":{"caption":"Chart Value Clicked","name":"chart_value_clicked"},"APi":{"caption":"Chart Value Hovered","name":"chart_value_hovered"}},"code":{"initialize":{"fn":"function(instance,context){instance.data.uniqueChartId=\"chartcanvas\"+Math.floor(1e5*Math.random()).toString(),instance.data.chartCanvasCopy=\"<div id='chartContainer\"+instance.data.uniqueChartId+\"' class='chart-container' style='position: relative; height: 1px; width: 1px'><canvas id='\"+instance.data.uniqueChartId+\"'></canvas></div>\",instance.canvas.append(instance.data.chartCanvasCopy);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);function forceUpdate(){document.getElementById(instance.data.custom_tooltip_id)&&(document.getElementById(instance.data.custom_tooltip_id).style.display=\"none\")}instance.data.ctxChartState=chartcanvas2.getContext(\"2d\"),setTimeout(forceUpdate,200)}"},"update":{"fn":"function(instance,properties,context){if(!/[0-9]/.test(properties.series1))return void console.log(\"No numbers in series1.\");if(Chart.plugins.unregister(ChartDataLabels),Chart.Legend.prototype.afterFit=function(){this.height=this.height+properties.legend_padding,this.width=this.width+properties.legend_padding},null!=properties.custom_tooltip_id&&(instance.data.custom_tooltip_id=properties.custom_tooltip_id),null==properties.chartlabels||null==properties.series1)return;if($(document).on(\"mousemove\",(function(e){let divHeight=$(\"#\"+properties.custom_tooltip_id).height();$(\"#\"+properties.custom_tooltip_id).css({position:\"fixed\",left:e.clientX+12,top:e.clientY-divHeight/2,zIndex:1e21})})),instance.data.ctxChartState){$(\"#\"+instance.data.uniqueChartId).remove();var canvas3=instance.data.chartCanvasCopy;instance.canvas.append(canvas3);var chartcanvas2=document.getElementById(instance.data.uniqueChartId);instance.data.ctxChartState=chartcanvas2.getContext(\"2d\")}var chartcanvas=document.getElementById(instance.data.uniqueChartId),ctxchart=chartcanvas.getContext(\"2d\");let legendState,showLegend;\"Don't Show Legend\"==properties.showLegend2?showLegend=!1:(legendState=properties.showLegend2.toLowerCase(),showLegend=!0);let listofchartlabels=properties.chartlabels,arrayoflabels=[];null!=properties.chartlabels&&(properties.chartlabels.includes(\",\")?arrayoflabels=listofchartlabels.split(\",\"):arrayoflabels.push(properties.chartlabels));let series1array=[];if(!properties.series1)return void series1array.push(5);if(properties.series1.includes(\",\")){let series1string=properties.series1;series1array=series1string.split(\",\")}else series1array.push(properties.series1);let pieChartColorsArray=[];if(properties.series1color.includes(\",\")){pieChartColorsArray=properties.series1color.split(\",\");for(let i=0;i<pieChartColorsArray.length;i++)pieChartColorsArray[i]=pieChartColorsArray[i].replace(/\\s/g,\"\")}else pieChartColorsArray.push(properties.series1color);let allYValuesArray=series1array,chartLabelsOn;1==properties.show_label&&[ChartDataLabels]&&(chartLabelsOn=[ChartDataLabels]);let customTooltip=!1;
197null!=properties.custom_tooltip_id&&(customTooltip=!0,$(\"#\"+properties.custom_tooltip_id).fadeOut(1)),Chart.defaults.RoundedDoughnut=Chart.helpers.clone(Chart.defaults.doughnut),Chart.controllers.RoundedDoughnut=Chart.controllers.doughnut.extend({draw:function(ease){var ctx=this.chart.ctx,easingDecimal=ease||1,arcs=this.getMeta().data;Chart.helpers.each(arcs,(function(arc,i){arc.transition(easingDecimal).draw();var pArc,pColor=arcs[0===i?arcs.length-1:i-1]._view.backgroundColor,vm=arc._view,radius=(vm.outerRadius+vm.innerRadius)/2,thickness=(vm.outerRadius-vm.innerRadius)/2,startAngle=Math.PI-vm.startAngle-Math.PI/2,angle=Math.PI-vm.endAngle-Math.PI/2;ctx.save(),ctx.translate(vm.x,vm.y),ctx.fillStyle=0===i?vm.backgroundColor:pColor,ctx.beginPath(),ctx.arc(radius*Math.sin(startAngle),radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.fill(),ctx.fillStyle=vm.backgroundColor,ctx.beginPath(),ctx.arc(radius*Math.sin(angle),radius*Math.cos(angle),thickness,0,2*Math.PI),ctx.fill(),ctx.restore()}))}}),Chart.pluginService.register({afterUpdate:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor];arc.round={x:(chart.chartArea.left+chart.chartArea.right)/2,y:(chart.chartArea.top+chart.chartArea.bottom)/2,radius:(chart.outerRadius+chart.innerRadius)/2,thickness:(chart.outerRadius-chart.innerRadius)/2-1,backgroundColor:arc._model.backgroundColor}}},afterDraw:function(chart){if(void 0!==chart.config.options.elements.arc.roundedCornersFor){var ctx=chart.chart.ctx,arc=chart.getDatasetMeta(0).data[chart.config.options.elements.arc.roundedCornersFor],startAngle=Math.PI/2-arc._view.startAngle,endAngle=Math.PI/2-arc._view.endAngle;let vm=arc._view,thickness=(vm.outerRadius-vm.innerRadius)/2;ctx.save(),ctx.translate(arc.round.x,arc.round.y),ctx.fillStyle=arc.round.backgroundColor,ctx.beginPath(),ctx.arc(arc.round.radius*Math.sin(startAngle),arc.round.radius*Math.cos(startAngle),thickness,0,2*Math.PI),ctx.arc(arc.round.radius*Math.sin(endAngle),arc.round.radius*Math.cos(endAngle),thickness,0,2*Math.PI),ctx.closePath(),ctx.fill(),ctx.restore()}}});let chartType=\"pie\",showDataLabelsOverlap;\"Rounded Corners (All Sections)\"==properties.section_corner_roundness&&(chartType=\"RoundedDoughnut\"),showDataLabelsOverlap=!properties.hide_datalabels_overlap||\"auto\";let config={plugins:chartLabelsOn,type:chartType,data:{labels:arrayoflabels,datasets:[{fill:!1,borderWidth:properties.section_border_width,borderColor:properties.section_border_color,hoverBorderWidth:properties.hover_border_width,hoverBorderColor:properties.section_border_color,label:properties.series1name,backgroundColor:pieChartColorsArray,data:series1array,datalabels:{display:showDataLabelsOverlap,anchor:properties.anchor,align:function(value){return value=0==properties.offset?\"center\":\"end\"},offset:properties.offset,color:function(value){return value=\"Custom (Define Color Below)\"==properties.font_color_setting?properties.datalabel_font_color:pieChartColorsArray},formatter:function(value,context){let completeLabel=\"\",percent,labelValue,labelName;if(value<properties.hide_if_less_than)return\"\";let total=eval(series1array.join(\"+\")),labelArray;if(percent=String((value/total*100).toFixed(properties.labelpercent_decimal))+\"%\",labelName=arrayoflabels[context.dataIndex],labelValue=value.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator),properties.data_label_unit_before&&(labelValue=(properties.data_label_unit_before+labelValue).replace(/\\s/g,\"\")),properties.data_label_unit_after&&(labelValue+=properties.data_label_unit_after),properties.data_label_text&&(labelArray=properties.data_label_text.split(\", \")),properties.data_label_text)for(;labelArray.length>0;)completeLabel&&(completeLabel+=\" \"),\"labelPercent\"==labelArray[0]&&(completeLabel+=percent),\"labelValue\"==labelArray[0]&&(completeLabel+=labelValue),\"labelName\"==labelArray[0]&&(completeLabel+=labelName),\"placeholder\"==labelArray[0]&&(completeLabel+=\"placeholder\"),labelArray.shift();return completeLabel},font:{family:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],size:properties.datalabel_size,weight:properties.datalabel_fontweight}}}]},options:{plugins:{crosshair:!1},animation:{duration:properties.animation_duration},onHover:function(event,elements){if(elements[0]){var activePoint=chart.getElementAtEvent(event),clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label,series_color=activePoint[0]._view.backgroundColor;customTooltip&&(instance.publishState(\"hovered_item_x_value\",label),instance.publishState(\"hovered_item_y_value\",value),instance.publishState(\"hovered_item_series_color\",series_color),$(\"#\"+properties.custom_tooltip_id).fadeIn(250),null!=document.getElementById(properties.custom_tooltip_id)&&($(\"#\"+instance.data.uniqueChartId).css(\"cursor\",elements[0]?\"pointer\":\"default\"),document.getElementById(properties.custom_tooltip_id).style.zIndex=\"1000000000000000000000\"))}else $(\"#\"+properties.custom_tooltip_id).fadeOut(100);label&&value&&instance.triggerEvent(\"chart_value_hovered\",(function(err){}))},cutoutPercentage:properties.cutout_percentage,rotation:-.5*Math.PI+properties.rotation*(Math.PI/180),circumference:properties.total_circumference*(Math.PI/180),legend:{align:\"left\",dis
197play:showLegend,position:legendState,labels:{filter:function(legendItem,data){return null==properties.hide_from_legend_if_less_than||data.datasets[0].data[legendItem.index]>properties.hide_from_legend_if_less_than},usePointStyle:\"Circle\"==properties.legend_color_style,fontColor:properties.legend_font_color,fontSize:properties.bubble.font_size(),fontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0]}},maintainAspectRatio:!1,layout:{padding:{right:properties.padding,left:properties.padding,top:properties.padding,bottom:properties.padding}},tooltips:{enabled:!customTooltip,titleFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],bodyFontFamily:properties.bubble.font_face().includes(\"font_default\")?\"Poppins\":properties.bubble.font_face().split(\":\")[0],callbacks:{label:function(tooltipItem,data){let label=\"\";label+=data.labels[tooltipItem.index],label+=\": \";let commaYLabel=data.datasets[0].data[tooltipItem.index];return null!=properties.thousands_separator&&(commaYLabel=commaYLabel.replace(/\\B(?=(\\d{3})+(?!\\d))/g,properties.thousands_separator)),properties.yAxisUnitBeforeNumber&&(commaYLabel=properties.yAxisUnitBeforeNumber+commaYLabel),label+=commaYLabel,properties.yAxisUnitAfterNumber&&(label+=properties.yAxisUnitAfterNumber),label}}}}},chart=new Chart(instance.data.ctxChartState,config);instance.data.chart=chart,chart.update();var chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId);function updateData(dataLabel,newData,newColor){chart.data.datasets.push({label:dataLabel,backgroundColor:newColor,data:newData,fill:!1,borderColor:newColor}),chart.update()}chartContainer.parentNode.removeChild(chartContainer),chartContainer=document.getElementById(\"chartContainer\"+instance.data.uniqueChartId),chartContainer.style.height=properties.bubble.height().toString()+\"px\",chartContainer.style.width=properties.bubble.width().toString()+\"px\",document.getElementById(instance.data.uniqueChartId).onclick=function(evt){var activePoint=chart.getElementAtEvent(event);if(activePoint.length>0){var clickedDatasetIndex=activePoint[0]._datasetIndex,clickedElementindex=activePoint[0]._index,label=chart.data.labels[clickedElementindex],value=chart.data.datasets[clickedDatasetIndex].data[clickedElementindex],series_name=chart.data.datasets[clickedDatasetIndex].label;instance.publishState(\"clicked_item_x_value\",label),instance.publishState(\"clicked_item_y_value\",value)}instance.triggerEvent(\"chart_value_clicked\",(function(err){}))},\"Rounded Corners (Single Section)\"==properties.section_corner_roundness&&(chart.options.elements.arc.roundedCornersFor=properties.rounded_corner_section_number),chart.destroy(),chart=new Chart(instance.data.ctxChartState,config)}"},"reset":{"fn":"function(instance,context){}"},"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Pie/Donut Chart';
197\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}"}},"platform_type":"web"}}}; 198window._bubble_page_load_data.plugins_size['1600733261948x484432582163300350'] = 108368; 199window.preloaded['plugin/third_party:1600733261948x484432582163300350:1.11.33'] = true; 200window.plugins["1604603255820x812929547345854500"] = {"human":"Prevent Right Click","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"AAU":{"display":"Chart - Geo Map Beta","property_applications":{"resizable":true,"MinWidth":true},"add_is_visible":true,"fields":{"AAN":{"caption":"Region","name":"region","rank":1,"editor":"DynamicValue","value":"text"},"AAO":{"caption":"Resolution","name":"resolution","rank":2,"editor":"Dropdown","value":"text","default_val":"provinces"},"AAP":{"caption":"Labels List","name":"labels_list","rank":3,"editor":"DynamicValue","value":"text","default_val":"State, California, Texas, New York, Florida"},"AAQ":{"caption":"Values List","name":"values_list","rank":4,"editor":"DynamicValue","value":"text","default_val":"Population, 39538223, 29145505, 20201249, 21538187"},"AAR":{"caption":"Color Starting Value","name":"color_starting_value","rank":5,"editor":"Color","default_val":"rgba(189,225,245,1)"},"AAS":{"caption":"Color Ending Value","name":"color_ending_value","rank":6,"editor":"Color","default_val":"rgba(26,154,223,1)"},"AAT":{"caption":"Google API Key","name":"google_api_key","rank":0,"editor":"StaticText"}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'BETA: Geography / Maps Chart';\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '12px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n\n // Append the container to the body\n document.body.appendChild(container);\n \n\n}"},"initialize":{"fn":"function(instance,context){instance.data.uniqueGeoChartId=\"geoChart\"+Math.floor(1e5*Math.random()).toString(),instance.data.geoChartCanvas=\"<div id='\"+instance.data.uniqueGeoChartId+\"' style='width: 100%; height: 500px;'></div>\",instance.canvas.append(instance.data.geoChartCanvas)}"},"update":{"fn":"function(instance,properties){function createDataTable(labelsString,dataString){const labels=labelsString.split(\",\").map((label=>label.trim())),dataValues=dataString.split(\",\").map((value=>value.trim())),dataArray=[];dataArray.push([labels[0],dataValues[0]]);for(let i=1;i<labels.length;i++)dataArray.push([labels[i],parseFloat(dataValues[i])]);return dataArray}function rgbaToHex(rgba){const matches=rgba.match(/rgba?\\((\\d+),\\s*(\\d+),\\s*(\\d+),?\\s*([\\d\\.]+)?\\)/);if(!matches)throw new Error(\"Invalid RGBA color format\");let r=parseInt(matches[1],10),g=parseInt(matches[2],10),b=parseInt(matches[3],10),hexR,hexG,hexB;return`#${r.toString(16).padStart(2,\"0\")}${g.toString(16).padStart(2,\"0\")}${b.toString(16).padStart(2,\"0\")}`}google.charts.load(\"current\",{packages:[\"geochart\"],mapsApiKey:properties.google_api_key});const labelsString=properties.labels_list,dataString=properties.values_list;console.log(createDataTable(labelsString,dataString)),google.charts.setOnLoadCallback((function(){var data=google.visualization.arrayToDataTable(createDataTable(labelsString,dataString)),options={region:properties.region,backgroundColor:\"transparent\",resolution:properties.resolution,colorAxis:{colors:[rgbaToHex(properties.color_starting_value),rgbaToHex(properties.color_ending_value)]}},chart;new google.visualization.GeoChart(document.getElementById(instance.data.uniqueGeoChartId)).draw(data,options)}))}"},"reset":{"fn":"function(instance,context){}"}},"platform_type":"web"}},"plugin_actions":{"AAC":{"display":"Prevent Right Click Context Menu","type":"client_side","fields":{"AAD":{"caption":"Optional: Exception Element HTML id","name":"exception_element","rank":0,"editor":"DynamicValue","value":"text","optional":true},"AAF":{"caption":"--------- Other Plugins You Might be Interested In --------","name":"-------------------------_other_plugins_----------------------------","rank":1,"editor":"Label"},"AAG":{"caption":"ð Charts and Graphs Plugin Link:","name":"ð_charts_and_graphs_plugin_link:","rank":2,"editor":"StaticText","default_val":"https://bubble.io/plugin/chart-js---26-charts-and-graphs-1553183744528x903111989944909800"},"AAH":{"caption":"ð¨ Drawing, Painting, Graphics Plugin Link:","name":"ð¨_drawing,_painting,_graphics_plugin_link:","rank":3,"editor":"StaticText","default_val":"https://bubble.io/plugin/fabricjs-drawing--painting-canvas-1565920055521x927769972289306600"},"AAI":{"caption":"â Beautiful and Customizable Toggles Plugin:","name":"â _beautiful_and_customizable_toggles_plugin:","rank":4,"editor":"StaticText","default_val":"https://bubble.io/plugin/toggles---beautiful--custom-toggle-1592859247043x537131931860729860"}},"code":{"client":{"fn":"function(properties,context){window.oncontextmenu=function(e){let clickedWhitelistedElement=!1,contextGroup=document.getElementById(properties.exception_element),i;if(null!=contextGroup)for(i=0;i<contextGroup.children.length;i++)contextGroup.children[i].contains(e.target)&&(clickedWhitelistedElement=!0);return 1==clickedWhitelistedElement}}"}}},"AAE":{"display":"Allow Right Click Context Menu","type":"client_side","fields":{"AAJ":{"caption":"--------- Other Plugins You Might be Interested In --------","name":"-------------------------_other_plugins_----------------------------","rank":0,"editor":"Label"},"AAK":{"caption":"ð Charts and Graphs Plugin Link:","name":"ð_charts_and_graphs_plugin_link:","rank":1,"editor":"StaticText","default_val":"https://bubble.io/plugin/chart-js---26-charts-and-graphs-1553183744528x903111989944909800"},"AAL":{"caption":"ð¨ Drawing, Painting, Graphics Plugin Link:","name":"ð¨_drawing,_painting,_graphics_plugin_link:","rank":2,"editor":"StaticText","default_val":"https://bubble.io/plugin/fabricjs-drawing--painting-canvas-1565920055521x927769972289306600"},"AAM":{"caption":"â Beautiful and Customizable Toggles Plugin:","name":"â _beautiful_and_customizable_toggles_plugin:","rank":3,"editor":"StaticText","default_val":"https://bubble.io/plugin/toggles---beautiful--custom-toggle-1592859247043x537131931860729860"}},"code":{"client":{"fn":"function(properties,context){window.oncontextmenu=function(e){return!0}}"}}}}}; 201window._bubble_page_load_data.plugins_size['1604603255820x812929547345854500'] = 7256; 202window.preloaded['plugin/third_party:1604603255820x812929547345854500:1.1.19'] = true; 203window.plugins["1585773166741x344001413254479900_current"] = {"human":"Premium Video Player","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"ACR":{"display":"Feedback Widget","property_applications":{"Border":false,"resizable":false,"MinWidth":false,"Font":true},"add_is_visible":true,"fields":{"ACV":{"caption":"Default Button Color","name":"main_button_color","rank":1,"editor":"Color","default_val":"rgba(2, 132, 254, 1)"},"ACg":{"caption":"Show Default Buttons?","name":"show_default_feedback_tab","rank":0,"editor":"DynamicValue","value":"boolean","default_val":true},"ACj":{"caption":"Open Feedback Text","name":"button_text_open_feedback","rank":2,"editor":"DynamicValue","value":"text","default_val":"Feedback"},"ACk":{"caption":"Close Feedback Text","name":"button_text_close_feedback","rank":3,"editor":"DynamicValue","value":"text","default_val":"Close"},"ACl":{"caption":"Submit Feedback Text","name":"button_text_submit_feedback","rank":4,"editor":"DynamicValue","value":"text","default_val":"SUBMIT"},"ACm":{"caption":"Placeholder Text - Feedback Input","name":"feedback_input_placeholder","rank":5,"editor":"DynamicValue","value":"text","default_val":"Enter your comment here..."},"ACq":{"caption":"Custom Button HTML id","name":"custom_button_html_id","rank":6,"editor":"DynamicValue","value":"text","optional":true},"ACv":{"caption":"File Format","name":"file_format","rank":7,"editor":"Dropdown","default_val":".png"}},"states":{"ACU":{"caption":"Feedback Screenshot URL","name":"imageurl","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ACY":{"caption":"Feedback Text","name":"textfeedback","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ACZ":{"caption":"Browser & Operating System","name":"browserAndOS","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ACc":{"caption":"Screen Width","name":"screenWidth","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ACd":{"caption":"Screen Height","name":"screenHeight","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ACo":{"caption":"Feedback Mode On?","name":"feedback_mode_on","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}}},"events":{"ACT":{"caption":"Generated a Feedback Screenshot","name":"screenshotURL_is_generated"}},"actions":{"ACS":{"caption":"Open Feedback Screenshot View","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n instance.data.fabricCanvas.add(instance.data.mainbackground);
203\n instance.data.fabricCanvas.hoverCursor = 'crosshair';\n instance.data.openBugshot(); // this ONE!!!!\n instance.data.feedbackButton.style.display=\"none\";\n if(document.getElementById(\"annotationInput\")){\n \tinstance.data.removeElement(\"annotationInput\");\n };\n\n\n\n //Do the operation\n\n\n\n}"}},"ACn":{"caption":"Close Feedback Screenshot View","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.closeBugshot();\n\n //Do the operation\n\n\n\n}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n\n let icon = '<img id=\"cancelIcon\" class=\"buttonShadows\" src=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1586642877986x171178841879218620/Screen%20Shot%202020-04-11%20at%2012.46.37%20PM.png\" style=\"cursor: pointer; position: absolute; left: 0px; left: 0px; background-color: rgb(255,255,255,0.65); z-index: 1; height: 35px; width: 35px\">';\n instance.canvas.append(icon);\n\n}"},"initialize":{"fn":"function(instance, context) {\n \n function removeElement(elementId) {\n // Removes an element from the document\n var element = document.getElementById(elementId);\n element.parentNode.removeChild(element);\n }\n instance.data.removeElement = removeElement;\n \n /**********INITIALIZE FABRIC CANVAS************/\n \n //creating a container that spans the page width/height, sets dark background\n let mybackground='<div id=\"bugShotBackground\" class=\"bugshotbackground\"><div style=\"position: fixed; height: 100%; width: 100%;\"></div></div>';\n instance.canvas.append(mybackground);\n instance.data.mainContainer = document.getElementById(\"bugShotBackground\");\n instance.data.mainContainer.style.display = \"none\";\n \n //creating the element for the canvas and adding it to the bubble plugin element\n\tlet fabricCanvasParentHTML ='<canvas id=\"fabricCanvasParent\"\"></canvas>';\n\tinstance.canvas.append(fabricCanvasParentHTML);\n \n //switching the element for the canvas to be the child node of the container element created in step 1\n instance.data.fabricCanvasParent = document.getElementById('fabricCanvasParent');\n instance.data.mainContainer.appendChild(instance.data.fabricCanvasParent);\n \n \n //switch the container element to be the child element of the page instead of the bubble plugin element\n //let page = document.getElementsByClassName(\"main-page bubble-element Page\")[0];\n\tdocument.body.appendChild(instance.data.mainContainer); \n \n //creating the Fabric Element itself\n instance.data.fabricCanvas = new fabric.Canvas('fabricCanvasParent');\n\n let mainbackground = new fabric.Rect({ //this is the big rectangle to achieve the crosshair cursor. to be added every time the bugshot it opened\n width: 10000,\n height: 10000,\n fill: \"rgb(0,0,0,0)\",\n left: -10,\n top: -10,\n selectable: false,\n });\n instance.data.mainbackground = mainbackground;\n\n\n /********** UPDATE CANVAS DIMENSIONS ************/\n window.addEventListener(\"resize\", function(){\n if(instance.data.mainContainer.style.display==\"block\"){\n \tinstance.data.fabricCanvas.setDimensions({width: instance.data.mainContainer.offsetWidth, height: instance.data.mainContainer.offsetHeight});\n };\n });\n \n \n /********** FOR OPENING BUGSHOT ************/\n\n //disable scroll function\n function noScroll(){\n if(instance.data.mainContainer.style.display==\"block\"){\n window.scrollTo(0,instance.data.scrollY);\n };\n };\n \n function openBugshot(){\n if(document.getElementById(\"annotationInput\")){\n\t\t\tdocument.getElementById(\"annotationInput\").remove();\n };\n \tinstance.data.mainContainer.style.display=\"block\";\n \tinstance.data.scrollY = document.documentElement.scrollTop;\n\t\twindow.addEventListener('scroll', noScroll);\n \tinstance.data.feedbackButton.style.display=\"none\";\n\n //put floater in main plugin group\n if(document.getElementById(instance.data.customButtonId)){\n\n instance.data.floater=document.getElementById(instance.data.customButtonId);\n instance.data.originalFloaterParent=instance.data.floater.parentElement;\n \n instance.data.floater.style.zIndex=100000000000000000000000;\n \n \tinstance.data.mainContainer.appendChild(instance.data.floater);\n };\n instance.publishState('feedback_mode_on', true);\n };\n instance.data.openBugshot = openBugshot;\n \n function closeBugshot(){\n \tinstance.data.mainContainer.style.display=\"none\";\n instance.data.feedbackButton.style.display=\"flex\";\n //removeElement(\"annotationInput\");\n\t\tinstance.data.fabricCanvas.clear();\n instance.data.createdBug = false;\n\t\twindow.removeEventListener('scroll', noScroll);\n \n //put floater back in original group\n if(document.getElementById(instance.data.customButtonId)){\n \tinstance.data.originalFloaterParent.appendChild(instance.data.floater); \n };\n instance.publishState('feedback_mode_on', false);\n\n };\n instance.data.closeBugshot = closeBugshot;\n \n /********** FOR DISPLAYING FLOATING GROUP (IF ANY) ABOVE THE ANNOTATION SCREEN ************/\n\n \n \n \n /********** FOR ADDING A WIDGET TO OPEN/CLOSE THE PAGE ************/\n \n //add feedback button (to show feedback inputter)\n let feedbackButton = '<div class=\"buttonShadows\" id=\"feedbackbuttoncontainer\"></div>';\n instance.canvas.append(feedbackButton);\n instance.data.feedbackButton= document.getElementById(\"feedbackbuttoncontainer\");\n document.body.appendChild(instance.data.feedbackButton);\n \n instance.data.feedbackButton.onclick = function(){\n \tinstance.data.fabricCanvas.add(mainbackground);
203\n \tinstance.data.fabricCanvas.hoverCursor = 'crosshair'; // this is for custom cursor when hovering elements. use auto for nothing\n instance.data.openBugshot();\n\t\t//instance.data.feedbackButton.style.display=\"none\";\n //removeElement(\"annotationInput\");\n };\n \n //add close icon\n let closeButton = '<div class=\"buttonShadows\" id=\"closeicon\"\"><p id=\"closeicontext\" style=\"position: absolute; top: 45%; left: -15%; color: white; transform: rotate(270deg)\"></p></div>';\n instance.canvas.append(closeButton);\n instance.data.closeIcon=document.getElementById(\"closeicon\");\n instance.data.closeIconText=document.getElementById(\"closeicontext\");\n \tinstance.data.mainContainer.appendChild(instance.data.closeIcon); \n instance.data.closeIcon.onclick = function(){\n\t\tinstance.data.closeBugshot();\n };\n \n \n /********** FOR CAPTURING A SCREENSHOT ************/\n \n function uploadContentCallback(err, url){\n\t\tif(url){\n\t\t\tinstance.publishState('imageurl', url);\n instance.triggerEvent('screenshotURL_is_generated', function(err) {});\n\t\t}else{\n\t\t\tconsole.error(\"Screenshot Plugin\", \"Error on uploadContent:\", err); \n\t\t} \n\t}\n\tinstance.data.uploadContentCallback = uploadContentCallback;\n \n\tfunction saveImage(fileName){\n\t\tlet imageData = instance.data.canvasScreenshot.toDataURL();\n\t\tlet imageDataPng = imageData.substring(imageData.indexOf(',')+1);\n\t\tcontext.uploadContent(fileName + instance.data.file_format, imageDataPng, instance.data.uploadContentCallback);\n\t};\n\tinstance.data.saveImage = saveImage;\n \n //html2canvas options for parameters to send to that service\n let html2canvasOptions;\n let screenshotElement;\n \n function captureScreenshot(){\n \n instance.data.scrollPositionTop = document.documentElement.scrollTop;\n instance.data.scrollPositionLeft = 0;\n if(document.documentElement.scrollLeft){\n instance.data.scrollPositionLeft = document.documentElement.scrollLeft; \n };\n html2canvasOptions = {\n x: instance.data.scrollPositionLeft,\n y: instance.data.scrollPositionTop,\n width: instance.data.mainContainer.offsetWidth,\n height: instance.data.mainContainer.offsetHeight,\n useCORS: false,\n allowTaint: true,\n \tproxy: \"https://www.techblocksproxy.com:80\",\n ignoreElements: function(element){\n\t\t\t\tlet bubbleImage = screenshotElement.querySelectorAll(\"img[src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1585607370503x914556455591480200/banner-icon.svg']\");\n if(element == bubbleImage[0]){\n \treturn true;\n }\n },\n //foreignObjectRendering: true,\n //proxy: \"https://html2canvas.bubbleapps.io/version-test/api/1.1/wf/test1\",\n };\n screenshotElement = document.body;\n //console.log(screenshotElement);\n\t\t//let bubbleImage = screenshotElement.querySelectorAll(\"img[src='https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1585607370503x914556455591480200/banner-icon.svg']\");\n\t\t//bubbleImage[0].setAttribute(\"data-html2canvas-ignore\", true);\n \n\t\t//remove submit and trash buttons before screenshot\n\t\tinstance.data.deleteAndSendContainer = document.getElementById(\"deleteAndSendContainer\");\n instance.data.deleteAndSendContainer.remove();//deleteAndSendContainer\n \n \n //add text element and remove multiline annotation element\n let replacementAnnotationText = document.createElement(\"p\");\n replacementAnnotationText.class=\"buttonShadows\";\n replacementAnnotationText.style.backgroundColor=\"white\";\n replacementAnnotationText.style.width=\"90%\";\n replacementAnnotationText.style.height=\"64%\";\n replacementAnnotationText.style.fontSize=\"14px\";\n replacementAnnotationText.style.color=\"rgb(0,0,0,0.8)\";\n replacementAnnotationText.style.border=\"1px solid rgb(0,0,0,0.3)\";\n replacementAnnotationText.style.borderRadius=\"4px\";\n replacementAnnotationText.style.wordWrap=\"break-word\";\n replacementAnnotationText.style.position=\"absolute\";\n replacementAnnotationText.style.top=\"0px\";\n replacementAnnotationText.style.right=\"0px\";\n replacementAnnotationText.style.padding=\"8px 8px\";\n\n replacementAnnotationText.innerHTML = instance.data.feedbackTextInput.value;\n\n instance.data.annotationInput.appendChild(replacementAnnotationText);\n instance.data.feedbackTextInput.remove();\n \n //html2canvas official screenshot call call\n html2canvas(screenshotElement, html2canvasOptions).then(function (canvas) {\n instance.data.canvasScreenshot = canvas;\n instance.data.saveImage(\"myscreenshot\");\n }); \n \n instance.data.annotationInput.remove();\n };\n \n \n /********** FOR RETURNING OTHER DATA, LIKE BROWSER, PAGE WIDTH, ETC ************/\n \tfunction captureFeedbackText(text){\n instance.publishState('textfeedback', text);\n }\n \n \tfunction captureBrowserInfo(){\n instance.publishState('browserAndOS', platform.toString());\n instance.publishState('screenWidth', screen.width);\n instance.publishState('screenHeight', screen.height);\n }\n \n /********** FOR MAIN DRAWING BUG MARKINGS AND ANNOTATIONS ************/\n\n \n function captureMouseDownCoordinates(){ \n\t\tinstance.data.mouseDownX = instance.data.fabricCanvas.getPointer().x;\n\t\tinstance.data.mouseDownY = instance.data.fabricCanvas.getPointer().y;\n console.log(\"mouse down at: \" + instance.data.mouseDownX + \", \" + instance.data.mouseDownY);\n };\n instance.data.captureMouseDownCoordinates = captureMouseDownCoordinates; \n \n \n //add text input to the snapshot\n function createText(text, x, y, inputWi
203dth, inputHeight){\n\n let annotationInput = '<div id=\"annotationInput\" style=\"position: absolute; width:' + inputWidth + 'px; height: '+ inputHeight + 'px\"><textarea id= \"feedbackTextInput\" class=\"buttonShadows\" placeholder=\"Enter your comment here...\" style=\"font-size: 16px; color: rgb(0,0,0,0.8); border: 0px solid rgb(0,0,0,0.5); width: 90%; height: 64%\"></textarea><div id=\"deleteAndSendContainer\" style=\"position: absolute; bottom: 0%; right: 0%; background-color: rgb(0,0,0,0.0); height: 40px; width: ' + inputWidth + 'px\"><div id=\"submitButtonContainer\" class=\"buttonShadows\" style=\"background-color:'+ instance.data.buttonColors +'\";><p id=\"submitButtonText\" style=\"position:relative; top: 30%; text-align: center; color: white; display: flex; justify-content: center; align-items: center;\"> SUBMIT </p></div><img id=\"cancelIcon\" class=\"buttonShadows\" src=\"https://37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1586378106755x750024867936166300/delete.svg\" style=\"cursor: pointer; position: absolute; right: 0px; top: 0%; background-color: rgb(255,255,255,0.65); border-radius: 3px; padding: 4px 4px; z-index: 1; height: 35px; width: 35px\"></div></div>';\n instance.canvas.append(annotationInput);\n\n //set text of submit button\n \tinstance.data.submitButtonText=document.getElementById(\"submitButtonText\");\n\t\tinstance.data.submitButtonText.innerHTML=instance.data.submitButtonTextString; \n \n //set text of input placeholder\n instance.data.feedbackTextInput = document.getElementById(\"feedbackTextInput\");\n instance.data.feedbackTextInput.placeholder=instance.data.placeholderTextInput;\n \n //create variable for new annotationInput container & assign to mainContainer\n instance.data.annotationInput = document.getElementById(\"annotationInput\");\n instance.data.mainContainer.appendChild(instance.data.annotationInput);\n \n //create variables for delete icon, submit button and what happens when clicked\n instance.data.submitButtonContainer = document.getElementById(\"submitButtonContainer\");\n instance.data.cancelIcon = document.getElementById(\"cancelIcon\");\n \n instance.data.submitButtonContainer.onclick = function(){\n captureScreenshot();\n captureBrowserInfo();\n captureFeedbackText(instance.data.feedbackTextInput.value);\n //instance.data.mainContainer.style.display=\"none\";\n //instance.data.feedbackButton.style.display=\"flex\";\n //instance.data.fabricCanvas.clear();\n //instance.data.createdBug = false;\n //window.removeEventListener('scroll', noScroll);\n\t\t\tinstance.data.closeBugshot();\n \n };\n\n instance.data.cancelIcon.onclick = function(){\n \n\t\t\tremoveElement(\"annotationInput\");\n\t\t\tinstance.data.fabricCanvas.clear();\n instance.data.createdBug = false;\n \t\tinstance.data.fabricCanvas.add(mainbackground);\n instance.data.fabricCanvas.hoverCursor = 'crosshair';\n \n };\n \n //can't remember what this does but I think it's important\n instance.data.annotationInput.style.left=x+\"px\";\n instance.data.annotationInput.style.top=y+\"px\";\n };\n instance.data.createText = createText;\n \n function createShape(x, y, shapeHeight, shapeWidth){\n let rect = new fabric.Rect({\n width: shapeWidth, \n height: shapeHeight, \n fill: \"rgba(0,0,0,0)\",\n left: x, \n top: y,\n stroke: \"#FFFFFF\",\n strokeWidth: 4,\n selectable: false,\n });\n instance.data.fabricCanvas.add(rect);
203\n \n let inputWidth = 300;\n let inputHeight = 175;\n \n \n //Adjusting the location of the input based on where it is on the screen\n let defaultX = x+shapeWidth+10;\n let defaultY = y+(shapeHeight*0.3)-20;\n \n if((defaultX+inputWidth)>instance.data.mainContainer.offsetWidth){\n \t\tdefaultX = x-inputWidth-25;\n };\n \n if((defaultY+inputHeight)>instance.data.mainContainer.offsetHeight){\n defaultY = y-inputHeight;\n };\n \n if((defaultY)<0){\n defaultY = 15;\n //console.log(\"default y was less than zero\");\n };\n \n //final case is for small screen like cell phone\n if((x-inputWidth-25)<0){\n //console.log(\"cell phone case\");\n \tdefaultX = 10;\n defaultY = y+shapeHeight+10;\n if((defaultY+inputHeight)>instance.data.mainContainer.offsetHeight){\n \t\tdefaultY = y-inputHeight-30; \n };\n };\n \n instance.data.createText(\"Enter your bug details here...\", defaultX, defaultY, inputWidth, inputHeight);\n instance.data.createdBug = true;\n\t}\n\tinstance.data.createShape=createShape;\n \n \n function createShapeOnMouseUp(){\n \n\t\tinstance.data.mouseUpX = instance.data.fabricCanvas.getPointer().x;\n\t\tinstance.data.mouseUpY = instance.data.fabricCanvas.getPointer().y;\n \n\t\t\tlet width = Math.round(Math.abs(instance.data.mouseUpX - instance.data.mouseDownX));\n\t\t\tlet height = Math.round(Math.abs(instance.data.mouseUpY - instance.data.mouseDownY));\n\n\t\t\t//set x, y coords based on shape drag direction\n\t\t\tlet xCoord;\n\t\t\tlet yCoord;\n\n\t\t\tif(instance.data.mouseDownX < instance.data.mouseUpX){//Left to Right\n\t\t\t\txCoord = instance.data.mouseDownX;\n\t\t\t}else{\n\t\t\t\txCoord = instance.data.mouseUpX;\n\t\t\t}\n\n\t\t\tif(instance.data.mouseDownY < instance.data.mouseUpY){//top to bottom\n\t\t\t\tyCoord = instance.data.mouseDownY;\n\t\t\t}else{\n\t\t\t\tyCoord = instance.data.mouseUpY;\n\t\t\t}\n \t\t\tinstance.data.createShape(xCoord,yCoord,height,width);\n };\n instance.data.createShapeOnMouseUp = createShapeOnMouseUp;\n \n \n //MOUSE DOWN: Capture pointer coordinates\n\tinstance.data.fabricCanvas.on('mouse:down', function(options){\n instance.data.captureMouseDownCoordinates();\n\t});\n \n \n\t//MOUSE UP: Fire Events based on what mode it's in\n\tinstance.data.fabricCanvas.on('mouse:up', function(options){\n //Only fire the following if it's in draw shape mode\n if(!instance.data.createdBug){\n \t\tinstance.data.createShapeOnMouseUp();\n \t\t\tinstance.data.fabricCanvas.hoverCursor = 'auto'; \n };\n\t});\n \n\n\n\n\n}","add_debugger":false},"update":{"fn":"function(instance, properties, context) {\n \n //Element properties\n instance.data.feedbackButton.style.backgroundColor=properties.main_button_color;\n\tinstance.data.closeIcon.style.color=properties.main_button_color;\n instance.data.customButtonId = properties.custom_button_html_id;\n \n //Feedback Button Text\n instance.data.feedbackButton.innerHTML=properties.button_text_open_feedback;\n instance.data.closeIcon.innerHTML=properties.button_text_close_feedback;\n instance.data.submitButtonTextString=properties.button_text_submit_feedback;\n instance.data.placeholderTextInput=properties.feedback_input_placeholder;\n \n //to give the color to the submit button\n instance.data.buttonColors = properties.main_button_color;\n\tinstance.data.file_format = properties.file_format;\n\n //show/hide default feedback button\n if(!properties.show_default_feedback_tab){\n \tinstance.data.feedbackButton.remove();\n instance.data.closeIcon.remove();\n }else{\n \tdocument.body.appendChild(instance.data.feedbackButton);\n \t\tinstance.data.mainContainer.appendChild(instance.data.closeIcon); \n };\n \n instance.data.fabricCanvas.setHeight(window.innerHeight);\n instance.data.fabricCanvas.setWidth(window.innerWidth);\n \n //try changing the non style width and height properties so as not to skew the proportions of what's drawn on the canvas\n}"},"reset":{"fn":"function(instance, context) {\n\n\n\n}"}},"platform_type":"web"},"ACw":{"display":"Video Player","property_applications":{"resizable":true,"MinWidth":true,"Backgroun
203d":true,"Border":true,"Padding":true,"BoxShadow":true,"Font":true},"add_is_visible":true,"add_large_file_upload_properties":false,"can_fit_width":true,"can_fit_height":true,"fields":{"ACx":{"caption":"Video URL","name":"video_url","rank":1,"editor":"DynamicValue","value":"file","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734116151820x132671698403852280/sample_960x400_ocean_with_audio.mp4"},"ACy":{"caption":"Play Automatically?","name":"play_automatically","rank":10,"editor":"DynamicValue","value":"boolean","default_val":false},"ACz":{"caption":"Thumbnail Image","name":"video_poster","rank":8,"editor":"DynamicValue","value":"image","default_val":"//37356e14dd30f324cd525d8513a08038.cdn.bubble.io/f1734129624872x833500003703271800/Screenshot%202024-12-13%20at%202.35.21%E2%80%AFPM.png"},"ADA":{"caption":"Video Speed","name":"video_speed","rank":13,"editor":"DynamicValue","value":"number","default_val":1},"ADC":{"caption":"Show FullScreen Btn?","name":"show_full_screen_button","rank":17,"editor":"DynamicValue","value":"boolean","default_val":true},"ADD":{"caption":"Loop Video?","name":"replay_video_when_over","rank":14,"editor":"DynamicValue","value":"boolean","default_val":false},"ADE":{"caption":"Playing - Scrub Bar Color","name":"playing_scrubber_bar_color","rank":4,"editor":"Color","default_val":"rgba(0, 162, 255, 1)"},"ADF":{"caption":"Play Button Color","name":"play_button_color","rank":5,"editor":"Color","default_val":"rgba(255,255,255,1)"},"ADG":{"caption":"Progress Bar Color","name":"progress_bar_color","rank":6,"editor":"Color","default_val":"rgba(255,255,255,0.3)"},"ADH":{"caption":"Disable Control Bar?","name":"disable_control_bar","rank":18,"editor":"DynamicValue","value":"boolean","default_val":false},"ADI":{"caption":"Start Time","name":"start_time","rank":12,"editor":"DynamicValue","value":"number","optional":true},"ADK":{"caption":"--------------------------------- Colors ---------------------------------","name":"-------------_colors_-------------","rank":3,"editor":"Label"},"ADL":{"caption":"-------------------------- Control Options ---------------------------","name":"-------------_buttons_-------------","rank":16,"editor":"Label"},"ADM":{"caption":"----------------------- Default Play Options -----------------------","name":"--------------------------_play_options_---------------------------","rank":9,"editor":"Label"},"ADN":{"caption":"--------------------- Video Thumbnail/Poster --------------------Video Thumbnail/Poster Image that is shown before the video starts while is it not playing","name":"--------------------------_video_thumbnail_---------------------------","rank":7,"editor":"Label"},"ADP":{"caption":"Show Play Button?","name":"play","rank":19,"editor":"DynamicValue","value":"boolean","default_val":true},"ADQ":{"caption":"Show Progress Slider?","name":"progress","rank":20,"editor":"DynamicValue","value":"boolean","default_val":true},"ADR":{"caption":"Show Current Time?","name":"current_time","rank":21,"editor":"DynamicValue","value":"boolean","default_val":true},"ADS":{"caption":"Show Mute Button?","name":"mute","rank":22,"editor":"DynamicValue","value":"boolean","default_val":true},"ADT":{"caption":"Show Volume Slider?","name":"volume","rank":23,"editor":"DynamicValue","value":"boolean","default_val":true},"ADU":{"caption":"Show Captions?","name":"captions","rank":24,"editor":"DynamicValue","value":"boolean","default_val":true},"ADV":{"caption":"Show Settings Menu?","name":"settings","rank":28,"editor":"DynamicValue","value":"boolean","default_val":true},"ADW":{"caption":"Show PIP Button?","name":"pip","rank":25,"editor":"DynamicValue","value":"boolean","default_val":true},"ADX":{"caption":"Show Airplay Btn?","name":"airplay","rank":26,"editor":"DynamicValue","value":"boolean","default_val":true},"ADY":{"caption":"Quality","name":"quality","rank":29,"editor":"DynamicValue","value":"boolean","default_val":true},"ADZ":{"caption":"Speed","name":"speed","rank":30,"editor":"DynamicValue","value":"boolean","default_val":true},"ADa":{"caption":"Loop","name":"loop","rank":31,"editor":"DynamicValue","value":"boolean","default_val":true},"ADb":{"caption":"--------------------------- Settings Menu ----------------------------","name":"----------------------------_settings_menu_-----------------------------","rank":27,"editor":"Label"},"ADc":{"caption":"Muted by default?","name":"muted_default","rank":15,"editor":"DynamicValue","value":"boolean","default_val":false},"AFI":{"caption":"â ï¸ Bubble doesn't allow you to upload files larger than 25MB, so for videos >25MB, you will need to store those outside of Bubble (on AWS, Google Cloud, etc)","name":"â ï¸_you_will_need_to_store_your_video_outside_of_bubble.io","rank":2,"editor":"Label"},"AFJ":{"caption":"In the input below, upload a video or insert a dynamic link that points to a video in your Bubble database:","name":"you_can_upload_a_video_or_insert_a_dynamic_link_that_points_to_a_video_in_your_bubble_database._","rank":0,"editor":"Label"},"AFP":{"caption":"â ï¸ Some browsers will not allow auto-play if the video is not muted. If auto-play isn't working, try changing the default to mute the video","name":"â ï¸_some_browser_will_not_allow_auto-play_if_the_video_is_not_muted._if_auto-play_isn't_working,_try_changing_the_default_to_mute_the_video","rank":11,"editor":"Label"}},"states":{"ADm":{"caption":"Player Current Time","name":"player_current_time","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADn":{"caption":"playing?","name":"playing","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADo":{"caption":"paused?","name":"paused","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADp":{"caption":"ended?","name":"ended","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADq":{"caption":"Buffered (0 = not buffered, 1 = completely buffered)","name":"buffered","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADr":{"caption":"seeking?","name":"seeking","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADs":{"caption":"Duration","name":"duration","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADt":{"caption":"Volume","name":"volume","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADu":{"caption":"Muted","name":"muted","value":"boolean","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADv":{"caption":"Speed","name":"speed","value":"number","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADw":{"caption":"Ratio","name":"ratio","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"},"value":"text"}},"actions":{"ADf":{"caption":"Play Video","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\tinstance.data.player.play();\n\n\n //Do the operation\n\n\n\n}"}},"ADg":{"caption":"Pause Video","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.player.pause();\n\n //Do the operation\n\n\n\n}"}},"ADh":{"caption":"Restart Video","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\n\tinstance.data.player.restart();\n\n //Do the operation\n\n\n\n}"}},"ADi":{"caption":"Rewind","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.player.rewind(properties.num_seconds);\n\n\n //Do the operation\n\n\n\n}"},"fields":{"ADj":{"caption":"Num seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"ADk":{"caption":"Forward","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\n\tinstance.data.player.forward(properties.num_seconds);\n\n //Do the operation\n\n\n\n}"},"fields":{"ADl":{"caption":"Num Seconds","name":"num_seconds","rank":0,"editor":"DynamicValue","value":"number","default_val":5}}},"ADx":{"caption":"Decrease Volume","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.player.decreaseVolume();\n\n\n //Do the operation\n\n\n\n}"}},"ADz":{"caption":"Increase Volume","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.player.increaseVolume();\n\n\n //Do the operation\n\n\n\n}"}},"AEA":{"caption":"Enter Fullscreen","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n\tinstance.data.player.fullscreen.enter();\n\n\n //Do the operation\n\n\n\n}"}},"AFK":{"caption":"Mute or Unmute","code":{"fn":"function(instance, properties, context) {\n\n // Check the mute property and mute/unmute the video accordingly\n if (properties.mute) {\n instance.data.player.muted = true; // Mute the video\n } else {\n instance.data.player.muted = false; // Unmute the video\n }\n\n}\n"},"fields":{"AFL":{"caption":"Mute?","name":"mute","rank":0,"editor":"DynamicValue","value":"boolean","default_val":true}}}},"code":{"preview":{"fn":"function(instance, properties) {\n \n // Create a wrapper div and set its style\n var wrapper = document.createElement('div');\n wrapper.style.position = 'fixed';\n wrapper.style.top = '0';\n wrapper.style.left = '0';\n wrapper.style.width = '100%';\n wrapper.style.height = '100%';\n wrapper.style.backgroundColor = '#EAEAEE';\n wrapper.style.border = '1px solid #BEBEC3'; // Add a border with color #BEBEC3\n wrapper.style.boxSizing = 'border-box'; // Include the border in the width and height calculation\n \n // Append the wrapper to the body\n document.body.appendChild(wrapper);\n \n // Create a container div and set its style\n var container = document.createElement('div');\n container.style.position = 'absolute';\n container.style.top = '0';\n container.style.left = '0';\n container.style.width = '100%';\n container.style.height = '100%';\n container.style.display = 'flex';\n container.style.flexDirection = 'column'; // Stack items vertically\n container.style.justifyContent = 'center';\n container.style.alignItems = 'center';\n\n // Create a text element and set its style\n var textElement = document.createElement('p');\n textElement.innerText = 'Video Player';
203\n textElement.style.fontFamily = 'Poppins, sans-serif';\n textElement.style.fontSize = '15px';\n textElement.style.textAlign = 'center';\n textElement.style.color = '#294C61';\n\n // Append the text element to the container\n container.appendChild(textElement);\n \n // Create a text element for the support message\n var supportText = document.createElement('p');\n supportText.innerHTML = 'Email <strong>[email protected]</strong> to report any issues';\n supportText.style.fontFamily = 'Poppins, sans-serif';\n supportText.style.fontSize = '12px';\n supportText.style.textAlign = 'center';\n supportText.style.color = '#294C61';\n supportText.style.marginTop = '10px'; // Add some spacing between the two text elements\n\n // Append the support message to the container\n container.appendChild(supportText);\n \n // Append the container to the body\n document.body.appendChild(container);\n}\n"},"initialize":{"fn":"function(instance, context) {\n // Create a unique ID for the video element\n instance.data.uniqueVideoId = \"plyrVideo\" + Math.floor(Math.random() * 100000).toString();\n \n // Append the video element to the canvas\n instance.data.videoContainer = `<video id=\"${instance.data.uniqueVideoId}\" controls></video>`;\n instance.canvas.append(instance.data.videoContainer); \n \n // Function to initialize Plyr video player\n /*function initializePlyr() {\n // Create a unique ID for the video element\n instance.data.uniqueVideoId = \"plyrVideo\" + Math.floor(Math.random() * 100000).toString();\n instance.data.videoContainer = `<video id=\"${instance.data.uniqueVideoId}\" controls></video>`;\n \n // Append the video element to the canvas\n instance.canvas.append(instance.data.videoContainer);\n\n // Initialize Plyr\n const videoElement = document.getElementById(instance.data.uniqueVideoId);\n instance.data.videoElement = videoElement;\n const player = new Plyr(videoElement, {\n controls: ['play', 'progress', 'volume', 'settings', 'captions', 'airplay', 'mute'],\n autoplay: false,\n muted: false,\n loop: { active: false },\n });\n \n // Store the Plyr instance in the plugin instance data\n instance.data.player = player;\n }\n\n // Call the function to initialize Plyr\n initializePlyr();*/\n}"},"update":{"fn":"function(instance, properties, context) {\n \n\n \n // Remove existing video container if present\n //instance.canvas.empty();\n\n\nfunction enforceStableMobileVideoLayout(video) {\n const container = video.parentElement;\n const aspectRatio = video.videoWidth / video.videoHeight || (16 / 9);\n const width = container.clientWidth;\n\n const calculatedHeight = width / aspectRatio;\n\n // Set stable layout\n container.style.height = calculatedHeight + 'px';\n container.style.overflow = 'hidden';\n\n video.style.width = '100%';\n video.style.height = '100%';\n video.style.display = 'block';\n video.style.objectFit = 'cover'; // or 'contain' if you prefer letterbox\n video.setAttribute('playsinline', ''); // prevent fullscreen jump on iOS\n}\n\n // Reinitialize the Plyr player\n const videoElement = document.getElementById(instance.data.uniqueVideoId);\n\n const controls = [];\n\n // Conditionally include fullscreen button\n if (properties.show_full_screen_button) {\n controls.push('fullscreen');\n }\n\n // Add other controls based on properties\n if (properties.play_large) controls.push('play-large');\n if (properties.play) controls.push('play');\n if (properties.progress) controls.push('progress');\n if (properties.current_time) controls.push('current-time');\n if (properties.mute) controls.push('mute');\n if (properties.volume) controls.push('volume');\n if (properties.captions) controls.push('captions');\n if (properties.settings) controls.push('settings');\n if (properties.pip) controls.push('pip');\n if (properties.airplay) controls.push('airplay');\n\n // Disable control bar if set to true\n if (properties.disable_control_bar) {\n controls.length = 0;
203 // Clear all controls if control bar is disabled\n }\n\n // Create the settings array for the settings menu based on the user input\n const settings = [];\n if (properties.quality) settings.push('quality');\n if (properties.speed) settings.push('speed');\n if (properties.loop) settings.push('loop');\n if (properties.captions) settings.push('captions'); // Keep captions in the settings\n \n\n /* // Initialize Plyr player with updated controls and settings\n instance.data.player = new Plyr(videoElement, {\n controls: controls,\n autoplay: properties.play_automatically || false,\n loop: { active: properties.replay_video_when_over || false },\n settings: settings.length > 0 ? settings : ['quality', 'speed', 'loop', 'captions'], // Default settings if none provided\n });\n */\n \n // Initialize Plyr player with updated controls and settings\n if(!instance.data.alreadyInitialized){\n \n instance.data.player = new Plyr(videoElement, {\n controls: controls,\n autoplay: properties.play_automatically || false,\n loop: { active: properties.replay_video_when_over || false },\n muted: properties.muted_default || false, // Ensure muted is applied on initialization\n settings: settings.length > 0 ? settings : ['quality', 'speed', 'loop', 'captions'], // Default settings if none provided\n });\n \n instance.data.alreadyInitialized = true;\n };\n \n\n\n\n\n \n \n \n // Ensure the muted property is applied correctly\n //instance.data.player.muted = properties.muted_default;\n //instance.data.player.volume = properties.muted_default ? 0 : instance.data.player.volume;\n\n // Check if video_url is available\n if (properties.video_url) {\n const videoSource = properties.video_url;\n\n // Check if it's a YouTube video\n if (videoSource.includes(\"youtube.com\") || videoSource.includes(\"youtu.be\")) {\n instance.data.player.source = {\n type: 'video',\n sources: [{\n src: videoSource,\n provider: 'youtube'\n }]\n };\n// Paste this right after setting the source:\ninstance.data.player.on('loadedmetadata', function () {\n const video = instance.data.player.elements.video;\n if (video) {\n enforceStableMobileVideoLayout(video);\n }\n}); \n // Check if it's a Vimeo video\n } else if (videoSource.includes(\"vimeo.com\")) {\n instance.data.player.source = {\n type: 'video',\n sources: [{\n src: videoSource,\n provider: 'vimeo'\n }]\n };\n \n // Paste this right after setting the source:\ninstance.data.player.on('loadedmetadata', function () {\n const video = instance.data.player.elements.video;\n if (video) {\n enforceStableMobileVideoLayout(video);\n }\n});\n \n // Assume it's an MP4 or self-hosted video\n } else {\n instance.data.player.source = {\n type: 'video',\n sources: [{\n src: videoSource,\n type: 'video/mp4'\n }]\n };\n \n // Paste this right after setting the source:\ninstance.data.player.on('loadedmetadata', function () {\n const video = instance.data.player.elements.video;\n if (video) {\n enforceStableMobileVideoLayout(video);\n }\n});\n }\n } else {\n console.warn(\"No video URL provided\");\n }\n \n \n\n // Dynamically set global Plyr CSS properties using JavaScript\n const root = document.documentElement;\n\n // Apply custom playing scrubber bar color globally\n if (properties.playing_scrubber_bar_color) {\n root.style.setProperty('--plyr-color-main', properties.playing_scrubber_bar_color);\n }\n\n // Apply custom play button color globally\n if (properties.play_button_color) {\n root.style.setProperty('--plyr-video-control-color', properties.play_button_color);\n root.style.setProperty('--plyr-video-control-color-hover', properties.play_button_color);\n }
203\n\n // Apply custom progress bar color globally\n if (properties.progress_bar_color) {\n root.style.setProperty('--plyr-video-progress-buffered-background', properties.progress_bar_color);\n }\n\n\n\n // Set video poster\n if (properties.video_poster) {\n instance.data.player.poster = properties.video_poster;\n }\n\n\n\n // End video at a specific time (in seconds)\n if (properties.end_time) {\n instance.data.player.on('timeupdate', function() {\n if (instance.data.player.currentTime >= properties.end_time) {\n instance.data.player.pause();\n }\n });\n }\n\n // Replay video when it ends\n if (properties.replay_video_when_over) {\n instance.data.player.on('ended', function() {\n instance.data.player.restart();\n });\n }\n \n //instance.data.player.currentTime = 5;//properties.start_time;\n // Start video at a specific time (in seconds)\n if (properties.start_time) {\n instance.data.player.currentTime = properties.start_time;\n };\n \n // Auto-play the video\n //instance.data.player.on('canplaythrough', function() {\n\t\tif (properties.play_automatically) {\n \tinstance.data.player.play();\n \t};\n //});\n \n instance.data.player.muted = properties.muted_default || false;\n instance.data.player.speed = properties.video_speed;\n \n setTimeout(() => {\n if (instance.data.player) {\n instance.data.player.muted = properties.muted_default || false;\n \t\tinstance.data.player.speed = properties.video_speed;\n if (properties.play_automatically) {\n instance.data.player.play().catch(error => {\n console.warn(\"Autoplay blocked by browser\", error);\n });\n }\n }\n }, 1000); // Delay ensures properties are applied after Plyr is initialized\n \n //setting timeout because it doesn't work when the player hasn't loaded\n /*setTimeout(function() {\n \tinstance.data.player.muted = properties.muted_default;\n }, 1000);*/\n\n \n \n \n \n \n /******************************************* PUBLISH STATES ***************************************/\n \n \n\n // Add a timeupdate listener to track the current time of the video and publish the state\n instance.data.player.on('timeupdate', function(event) {\n const currentTime = instance.data.player.currentTime; // Get the current time\n instance.publishState('player_current_time', currentTime); // Publish the current time to player_current_time state\n });\n \n // Playing state\n instance.publishState('playing', instance.data.player.playing);\n instance.data.player.on('playing', function() {\n instance.publishState('playing', true);\n instance.publishState('paused', false);\n });\n\n // Paused state\n instance.publishState('paused', instance.data.player.paused);\n instance.data.player.on('pause', function() {\n instance.publishState('paused', true);\n instance.publishState('playing', false);\n });\n\n // Ended state\n instance.publishState('ended', false);\n instance.data.player.on('ended', function() {\n instance.publishState('ended', true);\n });\n\n // Update the buffer value every 0.5 seconds until it equals 1\n const bufferInterval = setInterval(function() {\n const buffered = instance.data.player.buffered;\n instance.publishState('buffered', buffered);\n\n // Check if the buffer has reached 1 or if the video is fully buffered\n if (buffered === 1) {\n instance.publishState('buffered', 1); // Ensure it's set to 1\n clearInterval(bufferInterval);\n }\n }, 500);\n\n // Add an event listener for the 'canplaythrough' event to ensure it's fully buffered\n instance.data.player.on('canplaythrough', function() {\n instance.publishState('buffered', 1); // Ensure it's set to 1 when fully buffered\n clearInterval(bufferInterval); // Clear the interval when the video is fully buffered\n });\n\n\n // Seeking state\n\tinstance.publishState('seeking', false); // Default seeking state is false\n \n instance.data.player.on('seeking', function() {\
203n instance.publishState('seeking', true);\n });\n instance.data.player.on('seeked', function() {\n instance.publishState('seeking', false);\n });\n\n // Duration\n instance.data.player.on('loadedmetadata', function () {\n let duration = instance.data.player.duration;\n instance.publishState('duration', duration);\n\n if (duration === 0 || isNaN(duration)) {\n // Retry after 2.0 seconds\n setTimeout(() => {\n const durationAfter2s = instance.data.player.duration;\n if (durationAfter2s && durationAfter2s !== 0 && !isNaN(durationAfter2s)) {\n instance.publishState('duration', durationAfter2s);\n } else {\n // Retry again after 5.5 seconds\n setTimeout(() => {\n const durationAfter5s = instance.data.player.duration;\n if (durationAfter5s && durationAfter5s !== 0 && !isNaN(durationAfter5s)) {\n instance.publishState('duration', durationAfter5s);\n }\n }, 3500); // 5s total (2s + 3s)\n }\n }, 2000);\n }\n });\n\n // Volume\n instance.publishState('volume', instance.data.player.volume);\n instance.data.player.on('volumechange', function() {\n const volume = instance.data.player.volume;\n instance.publishState('volume', volume);\n });\n\n // Muted state\n instance.publishState('muted', instance.data.player.muted);\n instance.data.player.on('volumechange', function() {\n const muted = instance.data.player.muted;\n instance.publishState('muted', muted);\n });\n\n // Speed\n instance.data.player.on('ratechange', function() {\n const speed = instance.data.player.speed;\n instance.publishState('speed', speed);\n });\n\n // Ratio\n \t// Wait for the metadata to be loaded before accessing the ratio\n instance.data.player.on('loadedmetadata', function() {\n const ratio = instance.data.player.ratio;\n console.log('Video ratio:', ratio); // This will now log the correct ratio\n instance.publishState('ratio', ratio); // You can publish the ratio state here\n });\n\n\n\n\n \n\n}\n"},"reset":{"fn":"function(instance, context) {\n\n\n\n}"}},"platform_type":"web"}}}; 204window._bubble_page_load_data.plugins_size['1585773166741x344001413254479900_current'] = 48924; 205window.preloaded['plugin/third_party:1585773166741x344001413254479900_current:current'] = true; 206window.plugins["1615157512164x213665268513636350_current"] = {"human":"Custom Context Menu + RG","dependencies":{"use_jquery":true,"plugin_api_version":"4"},"plugin_elements":{"ADw":{"display":"List Calculator - Advanced","add_is_visible":true,"fields":{"ADd":{"caption":"List 1 - Input HTML id","name":"list_1_html_id","rank":3,"editor":"DynamicValue","value":"text","default_val":"List_1"},"ADe":{"caption":"List 2 - Input HTML id","name":"list_2_html_id","rank":4,"editor":"DynamicValue","value":"text","default_val":"List_2"},"ADf":{"caption":"List 3 - Input HTML id","name":"list_3_html_id","rank":5,"editor":"DynamicValue","value":"text","default_val":"List_3"},"ADg":{"caption":"List 4 - Input HTML id","name":"list_4_html_id","rank":6,"editor":"DynamicValue","value":"text","default_val":"List_4"},"ADh":{"caption":"List 5 - Input HTML id","name":"list_5_html_id","rank":7,"editor":"DynamicValue","value":"text","default_val":"List_5"},"ADi":{"caption":"List 6 - Input HTML id","name":"list_6_html_id","rank":8,"editor":"DynamicValue","value":"text","default_val":"List_6"},"ADj":{"caption":"List 7 - Input HTML id","name":"list_7_html_id","rank":9,"editor":"DynamicValue","value":"text","default_val":"List_7"},"ADk":{"caption":"This element helps extract input values from repeating groups to populate the data in your charts!","name":"this_element_helps_extract_input_values_from_repeating_groups._to_use_it,_add_a_repeating_group_to_the_page","rank":0,"editor":"Label"},"ADl":{"caption":"The following HTML ids should be added to the HTML id property for inputs in repeating groups on your page","name":"the_following_html_ids_should_be_added_to_the_html_id_property_for_inputs","rank":1,"editor":"Label"},"ADm":{"caption":"For full documentation on how to use this element, visit the following URL: https://techblocksco.bubbleapps.io/advanced-list-calculators","name":"for_full_documentation_on_how_to_use_this_element,_visit_the_following_url:_https://techblocksco.bubbleapps.io/advanced-list-calculators","rank":2,"editor":"Label"}
206,"ADn":{"caption":"List 8 - Input HTML id","name":"list_8_html_id","rank":10,"editor":"DynamicValue","value":"text"}},"states":{"ADo":{"caption":"Output List 1","name":"output_list_1","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADp":{"caption":"Output List 2","name":"output_list_2","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADq":{"caption":"Output List 3","name":"output_list_3","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADr":{"caption":"Output List 4","name":"output_list_4","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADs":{"caption":"Output List 5","name":"output_list_5","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADt":{"caption":"Output List 6","name":"output_list_6","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADu":{"caption":"Output List 7","name":"output_list_7","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}},"ADv":{"caption":"Output List 8","name":"output_list_8","value":"text","initialization_code":{"fn":"function(properties, context) {\n\n\n\n}"}}},"actions":{"ADc":{"caption":"Get Input Values","code":{"fn":"function(instance, properties, context) {\n\n\n //Load any data \n\n instance.data.getValues();\n\n //Do the operation\n\n\n\n}"}}},"code":{"preview":{"fn":"function(instance, properties) {\n\n\n}"},"initialize":{"fn":"function(instance, context) {\n\n\n\n}"},"update":{"fn":"function(instance, properties, context) {\n \n \n //setting up objects to loop through?\n var props = {}, \n \tctr = 1; \n \n $.each(properties, function(k, v){\n var id = \"List\"+ ctr + \"_id\";\n \n if( k.includes(\"list\") ){\n props[id] = v;\n ctr++;\n }\n });\n \n let list = props;\n \n \n \n //get values in elements by looping through (after waiting for it to load on the page)\n instance.data.timeLimit = 15000;\n instance.data.startTime = 0;\n \n function getValues(){\n if(document.getElementById(properties.list_1_html_id) || document.getElementById(properties.list_2_html_id) || document.getElementById(properties.list_3_html_id) || document.getElementById(properties.list_4_html_id) || document.getElementById(properties.list_5_html_id) || document.getElementById(properties.list_6_html_id) || document.getElementById(properties.list_7_html_id) || document.getElementById(properties.list_8_html_id)){\n var lists = [],\n ctr = 1;\n \n let arryOfListItems = document.querySelectorAll(\"#\"+properties.list_1_html_id);//.length;\n //console.log(\"MaxValues: \");\n //console.log(arryOfListItems);\n let maxNumListItems = 0;\n\t\t\tfor (var i = 0; i < arryOfListItems.length; i++) {\n //console.log(arryOfListItems[i].parentNode.parentNode.parentNode.style.display);\n if(arryOfListItems[i].parentNode.style.display != \"none\"){\n console.log(arryOfListItems[i]);\n maxNumListItems++;\n }\n };\n //console.log(maxNumListItems);\n \n $.each(list, function(k, v){\n var values = [],\n display = 0;\n\n $( \"[id='\"+ v +\"']\" ).each(function(){\n if(display < maxNumListItems){ // get only the values based on max items\n \tvalues.push( $(this).val() );\n display++;\n }\n });\n\n lists.push(values.join(\", \"));\n });\n\n $.each(lists, function(k, v){\n var output = \"output_list_\"+ ctr;\n if(ctr<9){ //for error showing up weird that goes one extra beyond 8 output lists\n \tinstance.publishState(output, v);\n };\n ctr++;\n });\n }
206else{\n if(instance.data.startTime<instance.data.timeLimit){\n instance.data.startTime+=50;\n setTimeout(getValues, 50);\n }else{\n console.log(\"Could not find the input element in the repeating group. Make sure it is loaded on the page (set to visible)\");\n return null;\n }\n }\n };\n instance.data.getValues = getValues;\n getValues();\n \n //on change functions?\n $(document).on(\"change\", '.bubble-element.Input', function(){\n getValues();\n });\n \n //on change of any DOM structure change (to capture changes to the number of rows on the rg)\n const observerFunction = mutations => {\n mutations.forEach(mutation => {\n if (mutation.type === 'attributes' && mutation.attributeName === 'style') {\n getValues();\n\n }\n });\n };\n \n\tconst observer = new MutationObserver(observerFunction);\n\n\n const config = {\n childList: true,\n attributes: true, // To observe attribute changes\n attributeFilter: ['style'], // To specifically observe changes to the 'style' attribute\n subtree: true // To observe changes in all descendant elements\n };\n\n \n const targetElement = document.body; // or any specific container element\n observer.observe(targetElement, config);\n\n \n}"},"reset":{"fn":"function(instance, context) {\n\n\n\n}"}},"platform_type":"web"}},"plugin_actions":{"AAC":{"display":"Set Context Menu Group","type":"client_side","fields":{"AAD":{"caption":"Context Menu HTML ID","name":"html_id","rank":0,"editor":"DynamicValue","value":"text","default_val":""}},"code":{"client":{"fn":"function(properties, context) {\n \n let htmlId = \"#\"+properties.html_id;\n \n $(document).ready(function($){\n $(htmlId).css({\"display\":\"none\", \"z-index\":\"1000000000001\"});\n\n // right click function\n document.addEventListener('contextmenu', function (e) {\n \te.preventDefault();\n\n var scroll = $(window).scrollTop();\n var relX = ( e.pageX - $(this).offset().left ) + 15;\n var relY = ( e.pageY - $(this).offset().top ) + 5 - scroll;\n \n \n $(htmlId).fadeIn(200).css({\"position\":\"fixed\", \"top\":relY, \"left\":relX});\n }, false);\n \n // scroll function\n document.addEventListener(\"scroll\", function (e) {\n $(htmlId).fadeOut(200);\n }, false);\n\n $(window).on('click', function(){\n $(htmlId).fadeOut(200);\n });\n\n $(htmlId).on('click', function(e){\n e.stopPropagation();\n });\n });\n}"}}}}}; 207window._bubble_page_load_data.plugins_size['1615157512164x213665268513636350_current'] = 8945; 208window.preloaded['plugin/third_party:1615157512164x213665268513636350_current:current'] = true; 209window['bubble_run_derived']['{"function_name":"PageByName","args":[]}'] = {"404":{"id":"AAU","_path":"%p3.AAX"},"reset_pw":{"id":"AAL","_path":"%p3.AAW"},"index":{"id":"bTGao","_path":"%p3.bTGba"},"bug-feedback-screenshot":{"id":"bTHlv","_path":"%p3.bTHmx"},"context-menu":{"id":"cmNem","_path":"%p3.cmNly"},"chartsdemo-old":{"id":"cmNnQ","_path":"%p3.cmNvj"},"canvasdemo":{"id":"cmOaS","_path":"%p3.cmOiG"},"radar-charts":{"id":"cmPsn","_path":"%p3.cmPtg"},"area-charts":{"id":"cmPtx","_path":"%p3.cmPuf"},"pie-charts":{"id":"cmPvA","_path":"%p3.cmPvt"},"scatter-charts":{"id":"cmPwV","_path":"%p3.cmPxO"},"boxplot-charts":{"id":"cmPxc","_path":"%p3.cmPyV"},"candlestick-charts":{"id":"cmPzA","_path":"%p3.cmPzi"},"mixed-charts":{"id":"cmPzq","_path":"%p3.cmQAF"},"basic-list-calculator":{"id":"cmQTH","_path":"%p3.cmQVk"},"canvas-actions-demo":{"id":"cmRJo","_path":"%p3.cmRKV"},"cumulative-charts":{"id":"cmVGA","_path":"%p3.cmVGd"},"color-picker":{"id":"bTHhj2","_path":"%p3.bTHii2"},"toggle":{"id":"bTIWe0","_path":"%p3.bTIXh0"},"moodboard_demo":{"id":"cmMra3","_path":"%p3.cmMrb3"},"prevent-right-click-context-menu":{"id":"cmNHV1","_path":"%p3.cmNKw1"},"chartsdemo-h1-2021":{"id":"cmOPV0","_path":"%p3.cmOXK0"},"line-charts":{"id":"cmPWy2","_path":"%p3.cmPet2"},"bubble-charts":{"id":"cmPoS4","_path":"%p3.cmPrm4"},"draggable-data-charts":{"id":"cmQJr3","_path":"%p3.cmQKX3"},"advanced-list-calculators":{"id":"cmQLY7","_path":"%p3.cmQMP7"},"custom-tooltips-charts":{"id":"cmQPe0","_path":"%p3.cmQSH0"},"chartsdemo-old-responsive":{"id":"cmQXJ6","_path":"%p3.cmQfy6"},"canvas-image-annotation":{"id":"cmRcc8","_path":"%p3.cmRku8"},"chartsdemos-2024":{"id":"cmUcx5","_path":"%p3.cmUcy5"},"2-by-2-matrix":{"id":"cmVGe1","_path":"%p3.cmVHq1"},"group-by-data-demo":{"id":"cmVJG7","_path":"%p3.cmVJj7"},"chart-datalabels-colors":{"id":"cmVVI1","_path":"%p3.cmVVr1"},"line-charts-copy":{"id":"cmZKl4","_path":"%p3.cmZOs4"},"line-charts-time":{"id":"cmZOt4","_path":"%p3.cmZOu4"},"2min-charts-video":{"id":"cmbRM6","_path":"%p3.cmbRN6"},"3-minute-charts-overview":{"id":"cmbSa6","_path":"%p3.cmbUx6"},"3-minute-overview-charts":{"id":"cmbUy6","_path":"%p3.cmbXY6"},"chart-annotations":{"id":"cmbwC4","_path":"%p3.cmcBm4"},"treemap-charts":{"id":"cmcDi0","_path":"%p3.cmcEH0"},"heatmap-charts":{"id":"cmcEa0","_path":"%p3.cmcFJ0"},"bar-charts":{"id":"cmeVa8","_path":"%p3.cmebK8"},"bar-charts_copy":{"id":"cmejk8","_path":"%p3.cmepU8"},"line-charts_copy":{"id":"cmeta1","_path":"%p3.cmexi1"},"pie-charts_copy":{"id":"cmfBG1","_path":"%p3.cmfCa1"},"radar-charts_copy":{"id":"cmfDW1","_path":"%p3.cmfEr1"},"multi-axes-charts":{"id":"cmcrG14","_path":"%p3.cmfOU9"},"gantt-charts":{"id":"cmfQS0","_path":"%p3.cmfQy0"},"range-bar-charts":{"id":"cmfRI9","_path":"%p3.cmfRo9"},"waterfall-charts":{"id":"cmfjI6","_path":"%p3.cmfjy6"},"geography-maps-charts":{"id":"cmfoe7","_path":"%p3.cmfpD7"},"chartsdemo":{"id":"cmgOc6","_path":"%p3.cmgTP6"},"bubbletest":{"id":"cmggk6","_path":"%p3.cmggo6"},"advanced-list-calculator-plugin":{"id":"cmgvQ6","_path":"%p3.cmgwm6"},"essential-charts-demo":{"id":"cmhDU1","_path":"%p3.cmhKj1"},"video-player":{"id":"cmiDW1","_path":"%p3.cmiJW1"},"image-pdf-generator":{"id":"cmipc3","_path":"%p3.cmivc3"},"chartsdemo-tim-responsive":{"id":"cmjgW3","_path":"%p3.cmjgX3"},"tick-label-line-breaks":{"id":"cmkPP2","_path":"%p3.cmkVP2"}
209,"video-testing":{"id":"cmkZW4","_path":"%p3.cmkZX4"},"canva-for-json":{"id":"cmkwy6","_path":"%p3.cmlGe6"},"basic-list-calculator-bundle":{"id":"cmlXC3","_path":"%p3.cmlYG3"},"advanced-list-calculator-bundle":{"id":"cmlYK3","_path":"%p3.cmlZZ3"},"video-player-bundle":{"id":"cmlZa3","_path":"%p3.cmlgK3"},"image-pdf-generator-bundle":{"id":"cmlgO3","_path":"%p3.cmlkS3"},"toggle-bundle":{"id":"cmloS1","_path":"%p3.cmlqe1"},"chartsdemos":{"id":"cmlqo1","_path":"%p3.cmmCj1"},"context-menu-bundle":{"id":"cmmFE6","_path":"%p3.cmmGO6"},"page-background-colorer":{"id":"cmmGY6","_path":"%p3.cmmHo6"},"clicked-hovered-events":{"id":"cmmuV4","_path":"%p3.cmnAV4"},"background-example":{"id":"cmQti15","_path":"%p3.cmQtj15"},"canvas-saving-demo":{"id":"cmRHT14","_path":"%p3.cmRIM14"},"bar_chart_decimals":{"id":"cmUfu11","_path":"%p3.cmUiX11"},"chartsdemo-responsive":{"id":"cmVbJ10","_path":"%p3.cmVfb10"},"radial-gauage-charts":{"id":"cmXzM12","_path":"%p3.cmYAg12"},"funnel-charts":{"id":"cmYCe15","_path":"%p3.cmYEA15"},"core-charts-demo":{"id":"cmYsM16","_path":"%p3.cmZDo16"},"polar-area":{"id":"cmZIO16","_path":"%p3.cmZJi16"},"agency-coaching":{"id":"cmbAy13","_path":"%p3.cmbCO13"},"skipping-empty-values":{"id":"cmcSE15","_path":"%p3.cmcSi15"},"video1":{"id":"cmhmB12","_path":"%p3.cmhrQ12"},"canva-app":{"id":"cmiZM13","_path":"%p3.cmiZN13"},"test":{"id":"cmkWv12","_path":"%p3.cmkWw12"},"video-test":{"id":"cmmEO15","_path":"%p3.cmmEP15"},"video-test_copy":{"id":"cmmEW15","_path":"%p3.cmmEc15"},"bug-screenshot-demo":{"id":"bTHsh0","_path":"%p3.bTHsi0"}} 210window.preloaded['app/derived:{"function_name":"PageByName","args":[]}'] = true; 211window['bubble_run_derived']['{"function_name":"CustomByNameV2","args":[]}'] = {"menutoggles":{"id":"bTGaR","_path":"%ed.bTGaS","custom_element_platform":"web"},"plugin_info":{"id":"cmMqk","_path":"%ed.cmMql","custom_element_platform":"web"},"mix":{"id":"cmMsn","_path":"%ed.cmMsr","custom_element_platform":"web"},"draw_and_paint_menu_backu":{"id":"cmMzB","_path":"%ed.cmMzZ","custom_element_platform":"web"},"Color Picker - Text":{"id":"cmNFq","_path":"%ed.cmNGA","custom_element_platform":"web"},"Draw & Paint Canvas Menu Vertical":{"id":"cmOiI","_path":"%ed.cmOin","custom_element_platform":"web"},"Header1":{"id":"bTGVZ0","_path":"%ed.bTGVa0","custom_element_platform":"web"},"Draw & Paint Canvas Menu Horizontal":{"id":"bTINZ2","_path":"%ed.bTINx2","custom_element_platform":"web"},"Color Picker 2":{"id":"bTIRY1","_path":"%ed.bTIRZ1","custom_element_platform":"web"},"toggles-feedback":{"id":"bTIVp0","_path":"%ed.bTIWF0","custom_element_platform":"web"},"feedbackwidget":{"id":"cmNMe3","_path":"%ed.cmNMf3","custom_element_platform":"web"},"Learn More - Charts":{"id":"cmQnh5","_path":"%ed.cmQni5","custom_element_platform":"web"},"Charts - Documentation":{"id":"cmQpJ5","_path":"%ed.cmQpK5","custom_element_platform":"web"},"Dashboard - Resv":{"id":"cmUuC2","_path":"%ed.cmUuD2","custom_element_platform":"web"},"Reusable Chart Demo Links":{"id":"cmUux11","_path":"%ed.cmUuy11","custom_element_platform":"web"},"Signup / Login Popup":{"id":"ACq","_path":"%ed.ACr","custom_element_platform":"web"},"Footer":{"id":"AFm","_path":"%ed.AFn","custom_element_platform":"web"},"bubble link":{"id":"bTHAc","_path":"%ed.bTHAd","custom_element_platform":"web"}} 212window.preloaded['app/derived:{"function_name":"CustomByNameV2","args":[]}'] = true; 213window['bubble_run_derived']['{"function_name":"UserCalls","args":[]}'] = [] 214window.preloaded['app/derived:{"function_name":"UserCalls","args":[]}'] = true; 215window['bubble_run_derived']['{"function_name":"OAuthProviders","args":[]}'] = [] 216window.preloaded['app/derived:{"function_name":"OAuthProviders","args":[]}'] = true; 217window['bubble_run_derived']['{"function_name":"DefaultValues","args":[]}'] = {"bar_chart_example__revenue_by_year":[{"name":"product_name_text","value":"text","display":"Product Name","deleted":null},{"name":"revenue_number","value":"number","display":"Revenue","deleted":null},{"name":"video__boolean","value":"boolean","display":"Video? - deleted","deleted":true},{"name":"video_link_text","value":"text","display":"Video Link - deleted","deleted":true},{"name":"year_number","value":"number","display":"Year","deleted":null}],"bubble_chart_example__tech_a_vs_tech_b":[{"name":"cost_number","value":"number","display":"Cost","deleted":null},{"name":"product_text","value":"text","display":"Product","deleted":null},{"name":"range_number","value":"number","display":"Range","deleted":null},{"name":"weight_number","value":"number","display":"Weight","deleted":null}],"bug_screenshot_example":[{"name":"browser_text","value":"text","display":"Browser & Operating System","deleted":null},{"name":"feedback_text_text","value":"text","display":"Feedback Text","deleted":null},{"name":"screen_height_number","value":"number","display":"Screen Height","deleted":null},{"name":"screen_width_number","value":"number","display":"Screen Width","deleted":null},{"name":"screenshot_image","value":"image","display":"Screenshot","deleted":null}],"canvas___saved_image_documentation":[{"name":"image_image","value":"image","display":"Image","deleted":null},{"name":"serialization_text","value":"text","display":"Serialization","deleted":null}],"canvas_test":[{"name":"serialization_text","value":"text","display":"serialization","deleted":null},{"name":"width_number","value":"number","display":"width","deleted":null}],"category":[{"name":"name_text","value":"text","display":"Category","deleted":null}],"chart_types":[{"name":"core__boolean","value":"boolean","display":"Core?","deleted":null},{"name":"description_text","value":"text","display":"Description","deleted":null},{"name":"inactive__boolean","value":"boolean","display":"Inactive?","deleted":null},{"name":"link_text","value":"text","display":"Link","deleted":null},{"name":"order_number","value":"number","display":"Order","deleted":null},{"name":"section_text","value":"text","display":"Section","deleted":null},{"name":"type_text","value":"text","display":"Name","deleted":null},{"name":"video_link_text","value":"text","display":"Video link","deleted":null}],"connected_scatter_chart_example__purchases_by_day":[{"name":"day_date","value":"date","display":"Day","deleted":null},{"name":"purchases_number","value":"number","display":"Purchases","deleted":null},{"name":"visits_number","value":"number","display":"Visits","deleted":null}],"date":[{"name":"date_date","value":"date","display":"Date","deleted":null}],"draggable_chart___example_data":[{"name":"2019_number","value":"number","display":"Year","deleted":null},{"name":"amount_number","value":"number","display":"Amount","deleted":null},{"name":"category_text","value":"text","display":"Category","deleted":null}],"drawing_painting_canvas":[{"name":"saved_png_image","value":"image","display":"Saved PNG","deleted":null},{"name":"saved_svg_image","value":"image","display":"Saved SVG","deleted":null},{"name":"saved_svg_text_text","value":"text","display":"Saved SVG Text","deleted":null},{"name":"serialized_canvas_text","value":"text","display":"Serialized Canvas","deleted":null}],"example_data___line_chart__inches_of_snow":[{"name":"accidents_number","value":"number","display":"Accidents","deleted":null},{"name":"city_geographic_address","value":"geographic_address","display":"City - deleted - deleted","deleted":true},{"name":"region_text","value":"text","display":"Region","deleted":null},{"name":"year_number","value":"number","display":"Year","deleted":null}],"group_to_image_example":[{"name":"group_to_image_image","value":"image","display":"Group to Image","deleted":null},{"name":"saved_pdf_text","value":"text","display":"Saved PDF","deleted":null}],"line_chart_examples__student_enrollment":[{"name":"enrollment_number","value":"number","display":"Enrollment","deleted":null},{"name":"school_year_date","value":"date","display":"School Year","deleted":null}],"link_example":[{"name":"link_url_text","value":"text","display":"Link URL","deleted":null}],"moodboard_demo":[{"name":"image_custom_moodboard_demo","value":"custom.moodboard_demo","display":"Image - deleted","deleted":true},{"name":"image_image","value":"image","display":"Image","deleted":null}],"number":[{"name":"category_text","value":"text","display":"Category","deleted":null},{"name":"payment_number","value":"number","display":"Realized","deleted":null},{"name":"target_number","value":"number","display":"Target","deleted":null}],"pdf_generated":[{"name":"link_to_pdf_text","value":"text","display":"Link to PDF","deleted":null}],"pie_chart_example__investments":[{"name":"amount_number","value":"number","display":"Amount","deleted":null},{"name":"category_text","value":"text","display":"Category","deleted":null}],"pie_chart_example__sales_by_cateogry":[{"name":"category_text","value":"text","display":"Category","deleted":null},{"name":"sale_value_number","value":"number","display":"Sale value","deleted":null}],"plugin":[{"name":"active__boolean","value":"boolean","display":"Inactive?","deleted":null},{"name":"image_image","value":"image","display":"Image","deleted":null},{"name":"link_text","value":"text","display":"Link","deleted":null},{"name":"link_to_bubble_plugin_text","value":"text","display":"Link to Bubble Plugin","deleted":null},{"name":"name_text","value":"text","display":"Name","deleted":null},{"name":"order_number","value":"number","display":"Order","deleted":null},{"name":"price_number","value":"number","display":"Price","deleted":null}],"profit_by_month":[{"name":"month_text","value":"text","display":"Month","deleted":null},{"name":"profit_number","value":"number","display":"Profit","deleted":null}],"radar_chart_example__budget_vs_spend":[{"name":"category_text","value":"text","display":"Category","deleted":null},{"name":"type_text","value":"text","display":"Type","deleted":null},{"name":"value_number","value":"number","display":"Value","deleted":null}],"sample_image":[{"name":"pic_image","value":"image","display":"Pic","deleted":null}],"saved_canvas":[],"screenshot":[{"name":"screenshot_image_image","value":"image","display":"Screenshot Image","deleted":null}],"screenshot_url":[{"name":"url_text","value":"text","display":"Screenshot URL","deleted":null}],"simple_charts___line_chart_example_data":[{"name":"city_text","value":"text","display":"City","deleted":null},{"name":"inches_of_snow_number","value":"number","display":"Inches of Snow","deleted":null},{"name":"year_number","value":"number","display":"Year","deleted":null}],"test_data":[{"name":"birthday_date","value":"date","display":"birthday","deleted":null},{"name":"color_text","value":"text","display":"Color","deleted":null},{"name":"number_number","value":"number","display":"Number","deleted":null},{"name":"yes_or_no_boolean","value":"boolean","display":"Yes or No","deleted":null}],"test_user":[{"name":"name_text","value":"text","display":"Name","deleted":null},{"name":"solutions_list_custom_category","value":"list.custom.category","display":"Solutions","deleted":null},{"name":"solutions_text_text","value":"text","display":"Solutions text - deleted","deleted":true},{"name":"solutions_texts_list_text","value":"list.text","display":"Solutions texts","deleted":null},{"name":"solutions_texts_text","value":"text","display":"Solutions texts - deleted","deleted":true}],"whiteboard":[{"name":"recent_change__boolean","value":"boolean","display":"Recent change?","deleted":null},{"name":"serialized_canvas_text","value":"text","display":"Serialized Canvas","deleted":null}],"user":[],"device":[{"display":"Type","value":"text","name":"device_type"},{"display":"Push notification token","value":"text","name":"push_notification_token"}
217,{"display":"Current user","value":"user","name":"current_user"}],"iap_subscription_purchase":[{"display":"Original Purchase Identifier","value":"text","name":"original_purchase_identifier"},{"display":"Status","value":"text","name":"status"},{"display":"Is Active","value":"boolean","name":"is_active"},{"display":"User","value":"user","name":"user"},{"display":"Environment","value":"text","name":"environment"},{"display":"Store","value":"text","name":"store"},{"display":"Bubble Billing Variant","value":"iap_item.billing_variant","name":"bubble_variant_id"},{"display":"Store Product Identifier","value":"text","name":"store_subscription_id"},{"display":"Google Base Plan ID","value":"text","name":"google_base_plan_id"},{"display":"Google Latest Order ID","value":"text","name":"google_latest_order_id"},{"display":"Expiry or Renewal Date","value":"date","name":"expiry_or_renewal_date"},{"display":"Purchase Identifier","value":"text","name":"purchase_identifier"}]} 218window.preloaded['app/derived:{"function_name":"DefaultValues","args":[]}'] = true; 219 220 window._bubble_page_load_data.js_execution_timings.static_js_end_execution = Date.now(); 221 222jQuery.migrateEnablePatches('self-closed-tags');
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.