>>=1,n<<=1,0<--e;);return n>>>1}function V(t,e,n){var r,i,s=new Array(f+1),o=0;for(r=1;r<=f;r++)s[r]=o=o+n[r-1]<<1;for(i=0;i<=e;i++){var a=t[2*i+1];0!==a&&(t[2*i]=z(s[a]++,a))}}function G(t){var e;for(e=0;e>1;1<=n;n--)W(t,s,n);for(i=c;n=t.heap[1],t.heap[1]=t.heap[t.heap_len--],W(t,s,1),r=t.heap[1],t.heap[--t.heap_max]=n,t.heap[--t.heap_max]=r,s[2*i]=s[2*n]+s[2*r],t.depth[i]=(t.depth[n]>=t.depth[r]?t.depth[n]:t.depth[r])+1,s[2*n+1]=s[2*r+1]=i,t.heap[1]=i++,W(t,s,1),2<=t.heap_len;);t.heap[--t.heap_max]=t.heap[1],function(t,e){var n,r,i,s,o,a,c=e.dyn_tree,u=e.max_code,l=e.stat_desc.static_tree,h=e.stat_desc.has_stree,d=e.stat_desc.extra_bits,m=e.stat_desc.extra_base,g=e.stat_desc.max_length,b=0;for(s=0;s<=f;s++)t.bl_count[s]=0;for(c[2*t.heap[t.heap_max]+1]=0,n=t.heap_max+1;n>=7;r>>=1)if(1&n&&0!==t.dyn_ltree[2*e])return i;if(0!==t.dyn_ltree[18]||0!==t.dyn_ltree[20]||0!==t.dyn_ltree[26])return s;for(e=32;e>>3,(a=t.static_len+3+7>>>3)<=o&&(o=a)):o=a=n+5,n+4<=o&&-1!==e?J(t,e,n,r):4===t.strategy||a===o?(j(t,2+(r?1:0),3),K(t,I,S)):(j(t,4+(r?1:0),3),function(t,e,n,r){var i;for(j(t,e-257,5),j(t,n-1,5),j(t,r-4,4),i=0;i>>8&255,t.pending_buf[t.d_buf+2*t.last_lit+1]=255&e,t.pending_buf[t.l_buf+t.last_lit]=255&n,t.last_lit++,0===e?t.dyn_ltree[2*n]++:(t.matches++,e--,t.dyn_ltree[2*(O[n]+u+1)]++,t.dyn_dtree[2*B(e)]++),t.last_lit===t.lit_bufsize-1},n._tr_align=function(t){j(t,2,3),F(t,b,I),function(t){16===t.bi_valid?(U(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):8<=t.bi_valid&&(t.pending_buf[t.pending++]=255&t.bi_buf,t.bi_buf>>=8,t.bi_valid-=8)}(t)}},{"../utils/common":41}],53:[function(t,e,n){"use strict";e.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(t,e,n){(function(t){!function(t,e){"use strict";if(!t.setImmediate){var n,r,s,o,a=1,c={},u=!1,l=t.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(t);h=h&&h.setTimeout?h:t,n="[object process]"==={}.toString.call(t.process)?function(t){i.nextTick((function(){p(t)}))}:function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?(o="setImmediate$"+Math.random()+"$",t.addEventListener?t.addEventListener("message",f,!1):t.attachEvent("onmessage",f),function(e){t.postMessage(o+e,"*")}):t.MessageChannel?((s=new MessageChannel).port1.onmessage=function(t){p(t.data)},function(t){s.port2.postMessage(t)}):l&&"onreadystatechange"in l.createElement("script")?(r=l.documentElement,function(t){var e=l.createElement("script");e.onreadystatechange=function(){p(t),e.onreadystatechange=null,r.removeChild(e),e=null},r.appendChild(e)}):function(t){setTimeout(p,0,t)},h.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),r=0;r>24&255;return{r:t>>16&255,g:t>>8&255,b:255&t,a:e>0?e:255}}static hexToRgb(t){t.startsWith("#")&&(t=t.substring(1));const e=parseInt(t,16);if(isNaN(e))return null;if(6===t.length)return{r:e>>16&255,g:e>>8&255,b:255&e};if(3===t.length){const t=e>>8&15,n=e>>4&15,r=15&e;return{r:t<<4|t,g:n<<4|n,b:r<<4|r}}return null}static rgbToHex(t){return n.decimalToHex(n.rgbToDecimal(t))}static rgbToDecimal(t){return(t.r<<16)+(t.g<<8)+t.b}static hexToDecimal(t){return n.rgbToDecimal(n.hexToRgb(t))}static hsvToRgb(t){let e=t.h%360;e<0&&(e+=360);const n=Math.max(0,Math.min(t.s,1)),r=Math.max(0,Math.min(t.v,1)),i=Math.floor(e/60),s=e/60-i,o=r*(1-n),a=r*(1-n*s),c=r*(1-n*(1-s));let u,l,h;switch(i){default:case 0:u=r,l=c,h=o;break;case 1:u=a,l=r,h=o;break;case 2:u=o,l=r,h=c;break;case 3:u=o,l=a,h=r;break;case 4:u=c,l=o,h=r;break;case 5:u=r,l=o,h=a}return{r:Math.floor(255*u),g:Math.floor(255*l),b:Math.floor(255*h)}}static rgbToHsv(t){const e=t.r/255,n=t.g/255,r=t.b/255,i=Math.min(Math.min(e,n),r),s=Math.max(Math.max(e,n),r);let o=0,a=0;if(i!==s){o=60*((e===i?3:n===i?5:1)-(e===i?n-r:n===i?r-e:e-n)/(s-i))%360,a=(s-i)/s}return{h:o,s:a,v:s}}static mixRgb(t,e,n){if(n<=0)return t;if(n>=1)return e;const r=1-n;return{r:r*t.r+n*e.r,g:r*t.g+n*e.g,b:r*t.b+n*e.b}}}t.exports=n},function(t,e,n){t.exports=function(){"use strict";var t=Array.prototype.slice;function e(t,e){e&&(t.prototype=Object.create(e.prototype)),t.prototype.constructor=t}function n(t){return o(t)?t:q(t)}function r(t){return a(t)?t:Q(t)}function i(t){return c(t)?t:X(t)}function s(t){return o(t)&&!u(t)?t:Z(t)}function o(t){return!(!t||!t[h])}function a(t){return!(!t||!t[d])}function c(t){return!(!t||!t[p])}function u(t){return a(t)||c(t)}function l(t){return!(!t||!t[f])}e(r,n),e(i,n),e(s,n),n.isIterable=o,n.isKeyed=a,n.isIndexed=c,n.isAssociative=u,n.isOrdered=l,n.Keyed=r,n.Indexed=i,n.Set=s;var h="@@__IMMUTABLE_ITERABLE__@@",d="@@__IMMUTABLE_KEYED__@@",p="@@__IMMUTABLE_INDEXED__@@",f="@@__IMMUTABLE_ORDERED__@@",m="delete",g=5,b=1<>>0;if(""+n!==e||4294967295===n)return NaN;e=n}return e<0?S(t)+e:e}function O(){return!0}function M(t,e,n){return(0===t||void 0!==n&&t<=-n)&&(void 0===e||void 0!==n&&e>=n)}function N(t,e){return R(t,e,0)}function C(t,e){return R(t,e,e)}function R(t,e,n){return void 0===t?n:t<0?Math.max(0,e+t):void 0===e?t:Math.min(e,t)}var D=0,P=1,L=2,B="function"==typeof Symbol&&Symbol.iterator,U="@@iterator",j=B||U;function F(t){this.next=t}function z(t,e,n,r){var i=0===t?e:1===t?n:[e,n];return r?r.value=i:r={value:i,done:!1},r}function V(){return{value:void 0,done:!0}}function G(t){return!!W(t)}function Y(t){return t&&"function"==typeof t.next}function H(t){var e=W(t);return e&&e.call(t)}function W(t){var e=t&&(B&&t[B]||t[U]);if("function"==typeof e)return e}function K(t){return t&&"number"==typeof t.length}function q(t){return null==t?ot():o(t)?t.toSeq():ut(t)}function Q(t){return null==t?ot().toKeyedSeq():o(t)?a(t)?t.toSeq():t.fromEntrySeq():at(t)}function X(t){return null==t?ot():o(t)?a(t)?t.entrySeq():t.toIndexedSeq():ct(t)}function Z(t){return(null==t?ot():o(t)?a(t)?t.entrySeq():t:ct(t)).toSetSeq()}F.prototype.toString=function(){return"[Iterator]"},F.KEYS=D,F.VALUES=P,F.ENTRIES=L,F.prototype.inspect=F.prototype.toSource=function(){return this.toString()},F.prototype[j]=function(){return this},e(q,n),q.of=function(){return q(arguments)},q.prototype.toSeq=function(){return this},q.prototype.toString=function(){return this.__toString("Seq {","}")},q.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},q.prototype.__iterate=function(t,e){return ht(this,t,e,!0)},q.prototype.__iterator=function(t,e){return dt(this,t,e,!0)},e(Q,q),Q.prototype.toKeyedSeq=function(){return this},e(X,q),X.of=function(){return X(arguments)},X.prototype.toIndexedSeq=function(){return this},X.prototype.toString=function(){return this.__toString("Seq [","]")},X.prototype.__iterate=function(t,e){return ht(this,t,e,!1)},X.prototype.__iterator=function(t,e){return dt(this,t,e,!1)},e(Z,q),Z.of=function(){return Z(arguments)},Z.prototype.toSetSeq=function(){return this},q.isSeq=st,q.Keyed=Q,q.Set=Z,q.Indexed=X;var J,_,$,tt="@@__IMMUTABLE_SEQ__@@";function et(t){this._array=t,this.size=t.length}function nt(t){var e=Object.keys(t);this._object=t,this._keys=e,this.size=e.length}function rt(t){this._iterable=t,this.size=t.length||t.size}function it(t){this._iterator=t,this._iteratorCache=[]}function st(t){return!(!t||!t[tt])}function ot(){return J||(J=new et([]))}function at(t){var e=Array.isArray(t)?new et(t).fromEntrySeq():Y(t)?new it(t).fromEntrySeq():G(t)?new rt(t).fromEntrySeq():"object"==typeof t?new nt(t):void 0;if(!e)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+t);return e}function ct(t){var e=lt(t);if(!e)throw new TypeError("Expected Array or iterable object of values: "+t);return e}function ut(t){var e=lt(t)||"object"==typeof t&&new nt(t);if(!e)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+t);return e}function lt(t){return K(t)?new et(t):Y(t)?new it(t):G(t)?new rt(t):void 0}function ht(t,e,n,r){var i=t._cache;if(i){for(var s=i.length-1,o=0;o<=s;o++){var a=i[n?s-o:o];if(!1===e(a[1],r?a[0]:o,t))return o+1}return o}return t.__iterateUncached(e,n)}function dt(t,e,n,r){var i=t._cache;if(i){var s=i.length-1,o=0;return new F((function(){var t=i[n?s-o:o];return o++>s?V():z(e,r?t[0]:o-1,t[1])}))}return t.__iteratorUncached(e,n)}function pt(t,e){return e?ft(e,t,"",{"":t}):mt(t)}function ft(t,e,n,r){return Array.isArray(e)?t.call(r,n,X(e).map((function(n,r){return ft(t,n,r,e)}))):gt(e)?t.call(r,n,Q(e).map((function(n,r){return ft(t,n,r,e)}))):e}function mt(t){return Array.isArray(t)?X(t).map(mt).toList():gt(t)?Q(t).map(mt).toMap():t}function gt(t){return t&&(t.constructor===Object||void 0===t.constructor)}function bt(t,e){if(t===e||t!=t&&e!=e)return!0;if(!t||!e)return!1;if("function"==typeof t.valueOf&&"function"==typeof e.valueOf){if((t=t.valueOf())===(e=e.valueOf())||t!=t&&e!=e)return!0;if(!t||!e)return!1}return!("function"!=typeof t.equals||"function"!=typeof e.equals||!t.equals(e))}function yt(t,e){if(t===e)return!0;if(!o(e)||void 0!==t.size&&void 0!==e.size&&t.size!==e.size||void 0!==t.__hash&&void 0!==e.__hash&&t.__hash!==e.__hash||a(t)!==a(e)||c(t)!==c(e)||l(t)!==l(e))return!1;if(0===t.size&&0===e.size)return!0;var n=!u(t);if(l(t)){var r=t.entries();return e.every((function(t,e){var i=r.next().value;return i&&bt(i[1],t)&&(n||bt(i[0],e))}))&&r.next().done}var i=!1;if(void 0===t.size)if(void 0===e.size)"function"==typeof t.cacheResult&&t.cacheResult();else{i=!0;var s=t;t=e,e=s}var h=!0,d=e.__iterate((function(e,r){if(n?!t.has(e):i?!bt(e,t.get(r,v)):!bt(t.get(r,v),e))return h=!1,!1}));return h&&t.size===d}function vt(t,e){if(!(this instanceof vt))return new vt(t,e);if(this._value=t,this.size=void 0===e?1/0:Math.max(0,e),0===this.size){if(_)return _;_=this}}function wt(t,e){if(!t)throw new Error(e)}function Tt(t,e,n){if(!(this instanceof Tt))return new Tt(t,e,n);if(wt(0!==n,"Cannot step a Range by 0"),t=t||0,void 0===e&&(e=1/0),n=void 0===n?1:Math.abs(n),er?V():z(t,i,n[e?r-i++:i++])}))},e(nt,Q),nt.prototype.get=function(t,e){return void 0===e||this.has(t)?this._object[t]:e},nt.prototype.has=function(t){return this._object.hasOwnProperty(t)},nt.prototype.__iterate=function(t,e){for(var n=this._object,r=this._keys,i=r.length-1,s=0;s<=i;s++){var o=r[e?i-s:s];if(!1===t(n[o],o,this))return s+1}return s},nt.prototype.__iterator=function(t,e){var n=this._object,r=this._keys,i=r.length-1,s=0;return new F((function(){var o=r[e?i-s:s];return s++>i?V():z(t,o,n[o])}))},nt.prototype[f]=!0,e(rt,X),rt.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);var n=H(this._iterable),r=0;if(Y(n))for(var i;!(i=n.next()).done&&!1!==t(i.value,r++,this););return r},rt.prototype.__iteratorUncached=function(t,e){if(e)return this.cacheResult().__iterator(t,e);var n=H(this._iterable);if(!Y(n))return new F(V);var r=0;return new F((function(){var e=n.next();return e.done?e:z(t,r++,e.value)}))},e(it,X),it.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);for(var n,r=this._iterator,i=this._iteratorCache,s=0;s=r.length){var e=n.next();if(e.done)return e;r[i]=e.value}return z(t,i,r[i++])}))},e(vt,X),vt.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},vt.prototype.get=function(t,e){return this.has(t)?this._value:e},vt.prototype.includes=function(t){return bt(this._value,t)},vt.prototype.slice=function(t,e){var n=this.size;return M(t,e,n)?this:new vt(this._value,C(e,n)-N(t,n))},vt.prototype.reverse=function(){return this},vt.prototype.indexOf=function(t){return bt(this._value,t)?0:-1},vt.prototype.lastIndexOf=function(t){return bt(this._value,t)?this.size:-1},vt.prototype.__iterate=function(t,e){for(var n=0;n=0&&e=0&&nn?V():z(t,s++,o)}))},Tt.prototype.equals=function(t){return t instanceof Tt?this._start===t._start&&this._end===t._end&&this._step===t._step:yt(this,t)},e(Et,n),e(At,Et),e(kt,Et),e(It,Et),Et.Keyed=At,Et.Indexed=kt,Et.Set=It;var St="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(t,e){var n=65535&(t|=0),r=65535&(e|=0);return n*r+((t>>>16)*r+n*(e>>>16)<<16>>>0)|0};function xt(t){return t>>>1&1073741824|3221225471&t}function Ot(t){if(!1===t||null==t)return 0;if("function"==typeof t.valueOf&&(!1===(t=t.valueOf())||null==t))return 0;if(!0===t)return 1;var e=typeof t;if("number"===e){if(t!=t||t===1/0)return 0;var n=0|t;for(n!==t&&(n^=4294967295*t);t>4294967295;)n^=t/=4294967295;return xt(n)}if("string"===e)return t.length>Ft?Mt(t):Nt(t);if("function"==typeof t.hashCode)return t.hashCode();if("object"===e)return Ct(t);if("function"==typeof t.toString)return Nt(t.toString());throw new Error("Value type "+e+" cannot be hashed.")}function Mt(t){var e=Gt[t];return void 0===e&&(e=Nt(t),Vt===zt&&(Vt=0,Gt={}),Vt++,Gt[t]=e),e}function Nt(t){for(var e=0,n=0;n0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}var Lt,Bt="function"==typeof WeakMap;Bt&&(Lt=new WeakMap);var Ut=0,jt="__immutablehash__";"function"==typeof Symbol&&(jt=Symbol(jt));var Ft=16,zt=255,Vt=0,Gt={};function Yt(t){wt(t!==1/0,"Cannot perform this action with an infinite size.")}function Ht(t){return null==t?ie():Wt(t)&&!l(t)?t:ie().withMutations((function(e){var n=r(t);Yt(n.size),n.forEach((function(t,n){return e.set(n,t)}))}))}function Wt(t){return!(!t||!t[qt])}e(Ht,At),Ht.of=function(){var e=t.call(arguments,0);return ie().withMutations((function(t){for(var n=0;n=e.length)throw new Error("Missing value for key: "+e[n]);t.set(e[n],e[n+1])}}))},Ht.prototype.toString=function(){return this.__toString("Map {","}")},Ht.prototype.get=function(t,e){return this._root?this._root.get(0,void 0,t,e):e},Ht.prototype.set=function(t,e){return se(this,t,e)},Ht.prototype.setIn=function(t,e){return this.updateIn(t,v,(function(){return e}))},Ht.prototype.remove=function(t){return se(this,t,v)},Ht.prototype.deleteIn=function(t){return this.updateIn(t,(function(){return v}))},Ht.prototype.update=function(t,e,n){return 1===arguments.length?t(this):this.updateIn([t],e,n)},Ht.prototype.updateIn=function(t,e,n){n||(n=e,e=void 0);var r=ge(this,En(t),e,n);return r===v?void 0:r},Ht.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):ie()},Ht.prototype.merge=function(){return de(this,void 0,arguments)},Ht.prototype.mergeWith=function(e){return de(this,e,t.call(arguments,1))},Ht.prototype.mergeIn=function(e){var n=t.call(arguments,1);return this.updateIn(e,ie(),(function(t){return"function"==typeof t.merge?t.merge.apply(t,n):n[n.length-1]}))},Ht.prototype.mergeDeep=function(){return de(this,pe,arguments)},Ht.prototype.mergeDeepWith=function(e){var n=t.call(arguments,1);return de(this,fe(e),n)},Ht.prototype.mergeDeepIn=function(e){var n=t.call(arguments,1);return this.updateIn(e,ie(),(function(t){return"function"==typeof t.mergeDeep?t.mergeDeep.apply(t,n):n[n.length-1]}))},Ht.prototype.sort=function(t){return Ge(hn(this,t))},Ht.prototype.sortBy=function(t,e){return Ge(hn(this,e,t))},Ht.prototype.withMutations=function(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this},Ht.prototype.asMutable=function(){return this.__ownerID?this:this.__ensureOwner(new k)},Ht.prototype.asImmutable=function(){return this.__ensureOwner()},Ht.prototype.wasAltered=function(){return this.__altered},Ht.prototype.__iterator=function(t,e){return new te(this,t,e)},Ht.prototype.__iterate=function(t,e){var n=this,r=0;return this._root&&this._root.iterate((function(e){return r++,t(e[1],e[0],n)}),e),r},Ht.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?re(this.size,this._root,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},Ht.isMap=Wt;var Kt,qt="@@__IMMUTABLE_MAP__@@",Qt=Ht.prototype;function Xt(t,e){this.ownerID=t,this.entries=e}function Zt(t,e,n){this.ownerID=t,this.bitmap=e,this.nodes=n}function Jt(t,e,n){this.ownerID=t,this.count=e,this.nodes=n}function _t(t,e,n){this.ownerID=t,this.keyHash=e,this.entries=n}function $t(t,e,n){this.ownerID=t,this.keyHash=e,this.entry=n}function te(t,e,n){this._type=e,this._reverse=n,this._stack=t._root&&ne(t._root)}function ee(t,e){return z(t,e[0],e[1])}function ne(t,e){return{node:t,index:0,__prev:e}}function re(t,e,n,r){var i=Object.create(Qt);return i.size=t,i._root=e,i.__ownerID=n,i.__hash=r,i.__altered=!1,i}function ie(){return Kt||(Kt=re(0))}function se(t,e,n){var r,i;if(t._root){var s=E(w),o=E(T);if(r=oe(t._root,t.__ownerID,0,void 0,e,n,s,o),!o.value)return t;i=t.size+(s.value?n===v?-1:1:0)}else{if(n===v)return t;i=1,r=new Xt(t.__ownerID,[[e,n]])}return t.__ownerID?(t.size=i,t._root=r,t.__hash=void 0,t.__altered=!0,t):r?re(i,r):ie()}function oe(t,e,n,r,i,s,o,a){return t?t.update(e,n,r,i,s,o,a):s===v?t:(A(a),A(o),new $t(e,r,[i,s]))}function ae(t){return t.constructor===$t||t.constructor===_t}function ce(t,e,n,r,i){if(t.keyHash===r)return new _t(e,r,[t.entry,i]);var s,o=(0===n?t.keyHash:t.keyHash>>>n)&y,a=(0===n?r:r>>>n)&y;return new Zt(e,1<>>=1)o[a]=1&n?e[s++]:void 0;return o[r]=i,new Jt(t,s+1,o)}function de(t,e,n){for(var i=[],s=0;s>1&1431655765))+(t>>2&858993459))+(t>>4)&252645135,t+=t>>8,127&(t+=t>>16)}function ye(t,e,n,r){var i=r?t:I(t);return i[e]=n,i}function ve(t,e,n,r){var i=t.length+1;if(r&&e+1===i)return t[e]=n,t;for(var s=new Array(i),o=0,a=0;a=Te)return ue(t,c,r,i);var d=t&&t===this.ownerID,p=d?c:I(c);return h?a?u===l-1?p.pop():p[u]=p.pop():p[u]=[r,i]:p.push([r,i]),d?(this.entries=p,this):new Xt(t,p)}},Zt.prototype.get=function(t,e,n,r){void 0===e&&(e=Ot(n));var i=1<<((0===t?e:e>>>t)&y),s=this.bitmap;return s&i?this.nodes[be(s&i-1)].get(t+g,e,n,r):r},Zt.prototype.update=function(t,e,n,r,i,s,o){void 0===n&&(n=Ot(r));var a=(0===e?n:n>>>e)&y,c=1<=Ee)return he(t,d,u,a,f);if(l&&!f&&2===d.length&&ae(d[1^h]))return d[1^h];if(l&&f&&1===d.length&&ae(f))return f;var m=t&&t===this.ownerID,b=l?f?u:u^c:u|c,w=l?f?ye(d,h,f,m):we(d,h,m):ve(d,h,f,m);return m?(this.bitmap=b,this.nodes=w,this):new Zt(t,b,w)},Jt.prototype.get=function(t,e,n,r){void 0===e&&(e=Ot(n));var i=(0===t?e:e>>>t)&y,s=this.nodes[i];return s?s.get(t+g,e,n,r):r},Jt.prototype.update=function(t,e,n,r,i,s,o){void 0===n&&(n=Ot(r));var a=(0===e?n:n>>>e)&y,c=i===v,u=this.nodes,l=u[a];if(c&&!l)return this;var h=oe(l,t,e+g,n,r,i,s,o);if(h===l)return this;var d=this.count;if(l){if(!h&&--d0&&r=0&&t>>e&y;if(r>=this.array.length)return new Oe([],t);var i,s=0===r;if(e>0){var o=this.array[r];if((i=o&&o.removeBefore(t,e-g,n))===o&&s)return this}if(s&&!i)return this;var a=Ue(this,t);if(!s)for(var c=0;c>>e&y;if(i>=this.array.length)return this;if(e>0){var s=this.array[i];if((r=s&&s.removeAfter(t,e-g,n))===s&&i===this.array.length-1)return this}var o=Ue(this,t);return o.array.splice(i+1),r&&(o.array[i]=r),o};var Me,Ne,Ce={};function Re(t,e){var n=t._origin,r=t._capacity,i=Ve(r),s=t._tail;return o(t._root,t._level,0);function o(t,e,n){return 0===e?a(t,n):c(t,e,n)}function a(t,o){var a=o===i?s&&s.array:t&&t.array,c=o>n?0:n-o,u=r-o;return u>b&&(u=b),function(){if(c===u)return Ce;var t=e?--u:c++;return a&&a[t]}}function c(t,i,s){var a,c=t&&t.array,u=s>n?0:n-s>>i,l=1+(r-s>>i);return l>b&&(l=b),function(){for(;;){if(a){var t=a();if(t!==Ce)return t;a=null}if(u===l)return Ce;var n=e?--l:u++;a=o(c&&c[n],i-g,s+(n<=t.size||e<0)return t.withMutations((function(t){e<0?Fe(t,e).set(0,n):Fe(t,0,e+1).set(e,n)}));e+=t._origin;var r=t._tail,i=t._root,s=E(T);return e>=Ve(t._capacity)?r=Be(r,t.__ownerID,0,e,n,s):i=Be(i,t.__ownerID,t._level,e,n,s),s.value?t.__ownerID?(t._root=i,t._tail=r,t.__hash=void 0,t.__altered=!0,t):De(t._origin,t._capacity,t._level,i,r):t}function Be(t,e,n,r,i,s){var o,a=r>>>n&y,c=t&&a0){var u=t&&t.array[a],l=Be(u,e,n-g,r,i,s);return l===u?t:((o=Ue(t,e)).array[a]=l,o)}return c&&t.array[a]===i?t:(A(s),o=Ue(t,e),void 0===i&&a===o.array.length-1?o.array.pop():o.array[a]=i,o)}function Ue(t,e){return e&&t&&e===t.ownerID?t:new Oe(t?t.array.slice():[],e)}function je(t,e){if(e>=Ve(t._capacity))return t._tail;if(e<1<0;)n=n.array[e>>>r&y],r-=g;return n}}function Fe(t,e,n){void 0!==e&&(e|=0),void 0!==n&&(n|=0);var r=t.__ownerID||new k,i=t._origin,s=t._capacity,o=i+e,a=void 0===n?s:n<0?s+n:i+n;if(o===i&&a===s)return t;if(o>=a)return t.clear();for(var c=t._level,u=t._root,l=0;o+l<0;)u=new Oe(u&&u.array.length?[void 0,u]:[],r),l+=1<<(c+=g);l&&(o+=l,i+=l,a+=l,s+=l);for(var h=Ve(s),d=Ve(a);d>=1<h?new Oe([],r):p;if(p&&d>h&&og;b-=g){var v=h>>>b&y;m=m.array[v]=Ue(m.array[v],r)}m.array[h>>>g&y]=p}if(a=d)o-=d,a-=d,c=g,u=null,f=f&&f.removeBefore(r,0,o);else if(o>i||d>>c&y;if(w!==d>>>c&y)break;w&&(l+=(1<i&&(u=u.removeBefore(r,c,o-l)),u&&ds&&(s=u.size),o(c)||(u=u.map((function(t){return pt(t)}))),r.push(u)}return s>t.size&&(t=t.setSize(s)),me(t,e,r)}function Ve(t){return t>>g<=b&&o.size>=2*s.size?(r=(i=o.filter((function(t,e){return void 0!==t&&a!==e}))).toKeyedSeq().map((function(t){return t[0]})).flip().toMap(),t.__ownerID&&(r.__ownerID=i.__ownerID=t.__ownerID)):(r=s.remove(e),i=a===o.size-1?o.pop():o.set(a,void 0))}else if(c){if(n===o.get(a)[1])return t;r=s,i=o.set(a,[e,n])}else r=s.set(e,o.size),i=o.set(o.size,[e,n]);return t.__ownerID?(t.size=r.size,t._map=r,t._list=i,t.__hash=void 0,t):He(r,i)}function qe(t,e){this._iter=t,this._useKeys=e,this.size=t.size}function Qe(t){this._iter=t,this.size=t.size}function Xe(t){this._iter=t,this.size=t.size}function Ze(t){this._iter=t,this.size=t.size}function Je(t){var e=vn(t);return e._iter=t,e.size=t.size,e.flip=function(){return t},e.reverse=function(){var e=t.reverse.apply(this);return e.flip=function(){return t.reverse()},e},e.has=function(e){return t.includes(e)},e.includes=function(e){return t.has(e)},e.cacheResult=wn,e.__iterateUncached=function(e,n){var r=this;return t.__iterate((function(t,n){return!1!==e(n,t,r)}),n)},e.__iteratorUncached=function(e,n){if(e===L){var r=t.__iterator(e,n);return new F((function(){var t=r.next();if(!t.done){var e=t.value[0];t.value[0]=t.value[1],t.value[1]=e}return t}))}return t.__iterator(e===P?D:P,n)},e}function _e(t,e,n){var r=vn(t);return r.size=t.size,r.has=function(e){return t.has(e)},r.get=function(r,i){var s=t.get(r,v);return s===v?i:e.call(n,s,r,t)},r.__iterateUncached=function(r,i){var s=this;return t.__iterate((function(t,i,o){return!1!==r(e.call(n,t,i,o),i,s)}),i)},r.__iteratorUncached=function(r,i){var s=t.__iterator(L,i);return new F((function(){var i=s.next();if(i.done)return i;var o=i.value,a=o[0];return z(r,a,e.call(n,o[1],a,t),i)}))},r}function $e(t,e){var n=vn(t);return n._iter=t,n.size=t.size,n.reverse=function(){return t},t.flip&&(n.flip=function(){var e=Je(t);return e.reverse=function(){return t.flip()},e}),n.get=function(n,r){return t.get(e?n:-1-n,r)},n.has=function(n){return t.has(e?n:-1-n)},n.includes=function(e){return t.includes(e)},n.cacheResult=wn,n.__iterate=function(e,n){var r=this;return t.__iterate((function(t,n){return e(t,n,r)}),!n)},n.__iterator=function(e,n){return t.__iterator(e,!n)},n}function tn(t,e,n,r){var i=vn(t);return r&&(i.has=function(r){var i=t.get(r,v);return i!==v&&!!e.call(n,i,r,t)},i.get=function(r,i){var s=t.get(r,v);return s!==v&&e.call(n,s,r,t)?s:i}),i.__iterateUncached=function(i,s){var o=this,a=0;return t.__iterate((function(t,s,c){if(e.call(n,t,s,c))return a++,i(t,r?s:a-1,o)}),s),a},i.__iteratorUncached=function(i,s){var o=t.__iterator(L,s),a=0;return new F((function(){for(;;){var s=o.next();if(s.done)return s;var c=s.value,u=c[0],l=c[1];if(e.call(n,l,u,t))return z(i,r?u:a++,l,s)}}))},i}function en(t,e,n){var r=Ht().asMutable();return t.__iterate((function(i,s){r.update(e.call(n,i,s,t),0,(function(t){return t+1}))})),r.asImmutable()}function nn(t,e,n){var r=a(t),i=(l(t)?Ge():Ht()).asMutable();t.__iterate((function(s,o){i.update(e.call(n,s,o,t),(function(t){return(t=t||[]).push(r?[o,s]:s),t}))}));var s=yn(t);return i.map((function(e){return mn(t,s(e))}))}function rn(t,e,n,r){var i=t.size;if(void 0!==e&&(e|=0),void 0!==n&&(n===1/0?n=i:n|=0),M(e,n,i))return t;var s=N(e,i),o=C(n,i);if(s!=s||o!=o)return rn(t.toSeq().cacheResult(),e,n,r);var a,c=o-s;c==c&&(a=c<0?0:c);var u=vn(t);return u.size=0===a?a:t.size&&a||void 0,!r&&st(t)&&a>=0&&(u.get=function(e,n){return(e=x(this,e))>=0&&ea)return V();var t=i.next();return r||e===P?t:z(e,c-1,e===D?void 0:t.value[1],t)}))},u}function sn(t,e,n){var r=vn(t);return r.__iterateUncached=function(r,i){var s=this;if(i)return this.cacheResult().__iterate(r,i);var o=0;return t.__iterate((function(t,i,a){return e.call(n,t,i,a)&&++o&&r(t,i,s)})),o},r.__iteratorUncached=function(r,i){var s=this;if(i)return this.cacheResult().__iterator(r,i);var o=t.__iterator(L,i),a=!0;return new F((function(){if(!a)return V();var t=o.next();if(t.done)return t;var i=t.value,c=i[0],u=i[1];return e.call(n,u,c,s)?r===L?t:z(r,c,u,t):(a=!1,V())}))},r}function on(t,e,n,r){var i=vn(t);return i.__iterateUncached=function(i,s){var o=this;if(s)return this.cacheResult().__iterate(i,s);var a=!0,c=0;return t.__iterate((function(t,s,u){if(!a||!(a=e.call(n,t,s,u)))return c++,i(t,r?s:c-1,o)})),c},i.__iteratorUncached=function(i,s){var o=this;if(s)return this.cacheResult().__iterator(i,s);var a=t.__iterator(L,s),c=!0,u=0;return new F((function(){var t,s,l;do{if((t=a.next()).done)return r||i===P?t:z(i,u++,i===D?void 0:t.value[1],t);var h=t.value;s=h[0],l=h[1],c&&(c=e.call(n,l,s,o))}while(c);return i===L?t:z(i,s,l,t)}))},i}function an(t,e){var n=a(t),i=[t].concat(e).map((function(t){return o(t)?n&&(t=r(t)):t=n?at(t):ct(Array.isArray(t)?t:[t]),t})).filter((function(t){return 0!==t.size}));if(0===i.length)return t;if(1===i.length){var s=i[0];if(s===t||n&&a(s)||c(t)&&c(s))return s}var u=new et(i);return n?u=u.toKeyedSeq():c(t)||(u=u.toSetSeq()),(u=u.flatten(!0)).size=i.reduce((function(t,e){if(void 0!==t){var n=e.size;if(void 0!==n)return t+n}}),0),u}function cn(t,e,n){var r=vn(t);return r.__iterateUncached=function(r,i){var s=0,a=!1;function c(t,u){var l=this;t.__iterate((function(t,i){return(!e||u0}function fn(t,e,r){var i=vn(t);return i.size=new et(r).map((function(t){return t.size})).min(),i.__iterate=function(t,e){for(var n,r=this.__iterator(P,e),i=0;!(n=r.next()).done&&!1!==t(n.value,i++,this););return i},i.__iteratorUncached=function(t,i){var s=r.map((function(t){return t=n(t),H(i?t.reverse():t)})),o=0,a=!1;return new F((function(){var n;return a||(n=s.map((function(t){return t.next()})),a=n.some((function(t){return t.done}))),a?V():z(t,o++,e.apply(null,n.map((function(t){return t.value}))))}))},i}function mn(t,e){return st(t)?e:t.constructor(e)}function gn(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function bn(t){return Yt(t.size),S(t)}function yn(t){return a(t)?r:c(t)?i:s}function vn(t){return Object.create((a(t)?Q:c(t)?X:Z).prototype)}function wn(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):q.prototype.cacheResult.call(this)}function Tn(t,e){return t>e?1:t=0;n--)e={value:arguments[n],next:e};return this.__ownerID?(this.size=t,this._head=e,this.__hash=void 0,this.__altered=!0,this):Qn(t,e)},Yn.prototype.pushAll=function(t){if(0===(t=i(t)).size)return this;Yt(t.size);var e=this.size,n=this._head;return t.reverse().forEach((function(t){e++,n={value:t,next:n}})),this.__ownerID?(this.size=e,this._head=n,this.__hash=void 0,this.__altered=!0,this):Qn(e,n)},Yn.prototype.pop=function(){return this.slice(1)},Yn.prototype.unshift=function(){return this.push.apply(this,arguments)},Yn.prototype.unshiftAll=function(t){return this.pushAll(t)},Yn.prototype.shift=function(){return this.pop.apply(this,arguments)},Yn.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Xn()},Yn.prototype.slice=function(t,e){if(M(t,e,this.size))return this;var n=N(t,this.size);if(C(e,this.size)!==this.size)return kt.prototype.slice.call(this,t,e);for(var r=this.size-n,i=this._head;n--;)i=i.next;return this.__ownerID?(this.size=r,this._head=i,this.__hash=void 0,this.__altered=!0,this):Qn(r,i)},Yn.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?Qn(this.size,this._head,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},Yn.prototype.__iterate=function(t,e){if(e)return this.reverse().__iterate(t);for(var n=0,r=this._head;r&&!1!==t(r.value,n++,this);)r=r.next;return n},Yn.prototype.__iterator=function(t,e){if(e)return this.reverse().__iterator(t);var n=0,r=this._head;return new F((function(){if(r){var e=r.value;return r=r.next,z(t,n++,e)}return V()}))},Yn.isStack=Hn;var Wn,Kn="@@__IMMUTABLE_STACK__@@",qn=Yn.prototype;function Qn(t,e,n,r){var i=Object.create(qn);return i.size=t,i._head=e,i.__ownerID=n,i.__hash=r,i.__altered=!1,i}function Xn(){return Wn||(Wn=Qn(0))}function Zn(t,e){var n=function(n){t.prototype[n]=e[n]};return Object.keys(e).forEach(n),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(e).forEach(n),t}qn[Kn]=!0,qn.withMutations=Qt.withMutations,qn.asMutable=Qt.asMutable,qn.asImmutable=Qt.asImmutable,qn.wasAltered=Qt.wasAltered,n.Iterator=F,Zn(n,{toArray:function(){Yt(this.size);var t=new Array(this.size||0);return this.valueSeq().__iterate((function(e,n){t[n]=e})),t},toIndexedSeq:function(){return new Qe(this)},toJS:function(){return this.toSeq().map((function(t){return t&&"function"==typeof t.toJS?t.toJS():t})).__toJS()},toJSON:function(){return this.toSeq().map((function(t){return t&&"function"==typeof t.toJSON?t.toJSON():t})).__toJS()},toKeyedSeq:function(){return new qe(this,!0)},toMap:function(){return Ht(this.toKeyedSeq())},toObject:function(){Yt(this.size);var t={};return this.__iterate((function(e,n){t[n]=e})),t},toOrderedMap:function(){return Ge(this.toKeyedSeq())},toOrderedSet:function(){return Un(a(this)?this.valueSeq():this)},toSet:function(){return Mn(a(this)?this.valueSeq():this)},toSetSeq:function(){return new Xe(this)},toSeq:function(){return c(this)?this.toIndexedSeq():a(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return Yn(a(this)?this.valueSeq():this)},toList:function(){return ke(a(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(t,e){return 0===this.size?t+e:t+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+e},concat:function(){return mn(this,an(this,t.call(arguments,0)))},includes:function(t){return this.some((function(e){return bt(e,t)}))},entries:function(){return this.__iterator(L)},every:function(t,e){Yt(this.size);var n=!0;return this.__iterate((function(r,i,s){if(!t.call(e,r,i,s))return n=!1,!1})),n},filter:function(t,e){return mn(this,tn(this,t,e,!0))},find:function(t,e,n){var r=this.findEntry(t,e);return r?r[1]:n},forEach:function(t,e){return Yt(this.size),this.__iterate(e?t.bind(e):t)},join:function(t){Yt(this.size),t=void 0!==t?""+t:",";var e="",n=!0;return this.__iterate((function(r){n?n=!1:e+=t,e+=null!=r?r.toString():""})),e},keys:function(){return this.__iterator(D)},map:function(t,e){return mn(this,_e(this,t,e))},reduce:function(t,e,n){var r,i;return Yt(this.size),arguments.length<2?i=!0:r=e,this.__iterate((function(e,s,o){i?(i=!1,r=e):r=t.call(n,r,e,s,o)})),r},reduceRight:function(t,e,n){var r=this.toKeyedSeq().reverse();return r.reduce.apply(r,arguments)},reverse:function(){return mn(this,$e(this,!0))},slice:function(t,e){return mn(this,rn(this,t,e,!0))},some:function(t,e){return!this.every(er(t),e)},sort:function(t){return mn(this,hn(this,t))},values:function(){return this.__iterator(P)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some((function(){return!0}))},count:function(t,e){return S(t?this.toSeq().filter(t,e):this)},countBy:function(t,e){return en(this,t,e)},equals:function(t){return yt(this,t)},entrySeq:function(){var t=this;if(t._cache)return new et(t._cache);var e=t.toSeq().map(tr).toIndexedSeq();return e.fromEntrySeq=function(){return t.toSeq()},e},filterNot:function(t,e){return this.filter(er(t),e)},findEntry:function(t,e,n){var r=n;return this.__iterate((function(n,i,s){if(t.call(e,n,i,s))return r=[i,n],!1})),r},findKey:function(t,e){var n=this.findEntry(t,e);return n&&n[0]},findLast:function(t,e,n){return this.toKeyedSeq().reverse().find(t,e,n)},findLastEntry:function(t,e,n){return this.toKeyedSeq().reverse().findEntry(t,e,n)},findLastKey:function(t,e){return this.toKeyedSeq().reverse().findKey(t,e)},first:function(){return this.find(O)},flatMap:function(t,e){return mn(this,un(this,t,e))},flatten:function(t){return mn(this,cn(this,t,!0))},fromEntrySeq:function(){return new Ze(this)},get:function(t,e){return this.find((function(e,n){return bt(n,t)}),void 0,e)},getIn:function(t,e){for(var n,r=this,i=En(t);!(n=i.next()).done;){var s=n.value;if((r=r&&r.get?r.get(s,v):v)===v)return e}return r},groupBy:function(t,e){return nn(this,t,e)},has:function(t){return this.get(t,v)!==v},hasIn:function(t){return this.getIn(t,v)!==v},isSubset:function(t){return t="function"==typeof t.includes?t:n(t),this.every((function(e){return t.includes(e)}))},isSuperset:function(t){return(t="function"==typeof t.isSubset?t:n(t)).isSubset(this)},keyOf:function(t){return this.findKey((function(e){return bt(e,t)}))},keySeq:function(){return this.toSeq().map($n).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},lastKeyOf:function(t){return this.toKeyedSeq().reverse().keyOf(t)},max:function(t){return dn(this,t)},maxBy:function(t,e){return dn(this,e,t)},min:function(t){return dn(this,t?nr(t):sr)},minBy:function(t,e){return dn(this,e?nr(e):sr,t)},rest:function(){return this.slice(1)},skip:function(t){return this.slice(Math.max(0,t))},skipLast:function(t){return mn(this,this.toSeq().reverse().skip(t).reverse())},skipWhile:function(t,e){return mn(this,on(this,t,e,!0))},skipUntil:function(t,e){return this.skipWhile(er(t),e)},sortBy:function(t,e){return mn(this,hn(this,e,t))},take:function(t){return this.slice(0,Math.max(0,t))},takeLast:function(t){return mn(this,this.toSeq().reverse().take(t).reverse())},takeWhile:function(t,e){return mn(this,sn(this,t,e))},takeUntil:function(t,e){return this.takeWhile(er(t),e)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=or(this))}});var Jn=n.prototype;Jn[h]=!0,Jn[j]=Jn.values,Jn.__toJS=Jn.toArray,Jn.__toStringMapper=rr,Jn.inspect=Jn.toSource=function(){return this.toString()},Jn.chain=Jn.flatMap,Jn.contains=Jn.includes,Zn(r,{flip:function(){return mn(this,Je(this))},mapEntries:function(t,e){var n=this,r=0;return mn(this,this.toSeq().map((function(i,s){return t.call(e,[s,i],r++,n)})).fromEntrySeq())},mapKeys:function(t,e){var n=this;return mn(this,this.toSeq().flip().map((function(r,i){return t.call(e,r,i,n)})).flip())}});var _n=r.prototype;function $n(t,e){return e}function tr(t,e){return[e,t]}function er(t){return function(){return!t.apply(this,arguments)}}function nr(t){return function(){return-t.apply(this,arguments)}}function rr(t){return"string"==typeof t?JSON.stringify(t):String(t)}function ir(){return I(arguments)}function sr(t,e){return te?-1:0}function or(t){if(t.size===1/0)return 0;var e=l(t),n=a(t),r=e?1:0;return ar(t.__iterate(n?e?function(t,e){r=31*r+cr(Ot(t),Ot(e))|0}:function(t,e){r=r+cr(Ot(t),Ot(e))|0}:e?function(t){r=31*r+Ot(t)|0}:function(t){r=r+Ot(t)|0}),r)}function ar(t,e){return e=St(e,3432918353),e=St(e<<15|e>>>-15,461845907),e=St(e<<13|e>>>-13,5),e=St((e=e+3864292196^t)^e>>>16,2246822507),e=xt((e=St(e^e>>>13,3266489909))^e>>>16)}function cr(t,e){return t^e+2654435769+(t<<6)+(t>>2)}return _n[d]=!0,_n[j]=Jn.entries,_n.__toJS=Jn.toObject,_n.__toStringMapper=function(t,e){return JSON.stringify(e)+": "+rr(t)},Zn(i,{toKeyedSeq:function(){return new qe(this,!1)},filter:function(t,e){return mn(this,tn(this,t,e,!1))},findIndex:function(t,e){var n=this.findEntry(t,e);return n?n[0]:-1},indexOf:function(t){var e=this.keyOf(t);return void 0===e?-1:e},lastIndexOf:function(t){var e=this.lastKeyOf(t);return void 0===e?-1:e},reverse:function(){return mn(this,$e(this,!1))},slice:function(t,e){return mn(this,rn(this,t,e,!1))},splice:function(t,e){var n=arguments.length;if(e=Math.max(0|e,0),0===n||2===n&&!e)return this;t=N(t,t<0?this.count():this.size);var r=this.slice(0,t);return mn(this,1===n?r:r.concat(I(arguments,2),this.slice(t+e)))},findLastIndex:function(t,e){var n=this.findLastEntry(t,e);return n?n[0]:-1},first:function(){return this.get(0)},flatten:function(t){return mn(this,cn(this,t,!1))},get:function(t,e){return(t=x(this,t))<0||this.size===1/0||void 0!==this.size&&t>this.size?e:this.find((function(e,n){return n===t}),void 0,e)},has:function(t){return(t=x(this,t))>=0&&(void 0!==this.size?this.size===1/0||t0&&void 0!==arguments[0]?arguments[0]:this.warpMode;return this.reset(),this.warpMode=Boolean(t),this}static create(t){const e=i.pop();return void 0!==e?(e.warpMode=Boolean(t),e):new s(t)}static release(t){void 0!==t&&i.push(t.reset())}}class o{constructor(t){this.topBlock=t,this.stack=[],this.stackFrames=[],this.status=0,this.isKilled=!1,this.target=null,this.blockContainer=null,this.requestScriptGlowInFrame=!1,this.blockGlowInFrame=null,this.warpTimer=null,this.justReported=null,this.triedToCompile=!1,this.isCompiled=!1,this.timer=null,this.generator=null,this.procedures=null,this.executableHat=!1,this.compatibilityStackFrame=null}static get STATUS_RUNNING(){return 0}static get STATUS_PROMISE_WAIT(){return 1}static get STATUS_YIELD(){return 2}static get STATUS_YIELD_TICK(){return 3}static get STATUS_DONE(){return 4}static getIdFromTargetAndBlock(t,e){return"".concat(t.id,"&").concat(e)}getId(){return o.getIdFromTargetAndBlock(this.target,this.topBlock)}pushStack(t){if(this.stack.push(t),this.stack.length>this.stackFrames.length){const t=this.stackFrames[this.stackFrames.length-1];this.stackFrames.push(s.create(void 0!==t&&t.warpMode))}}reuseStackForNextBlock(t){this.stack[this.stack.length-1]=t,this.stackFrames[this.stackFrames.length-1].reuse()}popStack(){return s.release(this.stackFrames.pop()),this.stack.pop()}stopThisScript(){let t=this.peekStack();for(;null!==t;){const e=this.target.blocks.getBlock(t);if(this.peekStackFrame().waitingReporter)break;if(void 0!==e&&"procedures_call"===e.opcode){this.goToNextBlock();break}this.popStack(),t=this.peekStack()}0===this.stack.length&&(this.requestScriptGlowInFrame=!1,this.status=o.STATUS_DONE)}peekStack(){return this.stack.length>0?this.stack[this.stack.length-1]:null}peekStackFrame(){return this.stackFrames.length>0?this.stackFrames[this.stackFrames.length-1]:null}peekParentStackFrame(){return this.stackFrames.length>1?this.stackFrames[this.stackFrames.length-2]:null}pushReportedValue(t){this.justReported=void 0===t?null:t}initParams(){const t=this.peekStackFrame();null===t.params&&(t.params={})}pushParam(t,e){this.peekStackFrame().params[t]=e}getParam(t){for(let e=this.stackFrames.length-1;e>=0;e--){const n=this.stackFrames[e];if(null!==n.params)return Object.prototype.hasOwnProperty.call(n.params,t)?n.params[t]:null}return null}getAllparams(){return this.peekStackFrame().params}atStackTop(){return this.peekStack()===this.topBlock}goToNextBlock(){const t=this.target.blocks.getNextBlock(this.peekStack());this.reuseStackForNextBlock(t)}isRecursiveCall(t){let e=5;for(let n=this.stackFrames.length-1-1;n>=0;n--){const r=this.target.blocks.getBlock(this.stackFrames[n].op.id)||this.target.runtime.flyoutBlocks.getBlock(this.stackFrames[n].op.id);if("procedures_call"===r.opcode&&r.mutation.proccode===t)return!0;if(--e<0)return!1}return!1}tryCompile(){if(!this.blockContainer)return;const t=n(186);this.triedToCompile=!0;const e=!this.stackClick,i=this.topBlock,s=this.blockContainer.getBlock(i)?this.blockContainer:this.target.runtime.flyoutBlocks,o=e&&s.getCachedCompileResult(i);if(o&&!o.success)return;let a;if(o)a=o.value;else try{a=t(this),e&&s.cacheCompileResult(i,a)}catch(t){return r.error("cannot compile script",this.target.getName(),t),e&&s.cacheCompileError(i,t),void this.target.runtime.emitCompileError(this.target,t)}this.procedures={};for(const t of Object.keys(a.procedures))this.procedures[t]=a.procedures[t](this);this.generator=a.startingFunction(this)(),this.executableHat=a.executableHat,this.blockContainer.forceNoGlow||(this.blockGlowInFrame=this.topBlock,this.requestScriptGlowInFrame=!0),this.isCompiled=!0}}o._StackFrame=s,t.exports=o},function(t,e,n){const r=n(231),i=n(244),s=n(77),o=n(73),a=n(246),c=n(76),u=n(49),l=n(74),h=n(247),d=n(48);t.exports={BitmapAdapter:i,convertFonts:l,inlineSvgFonts:s,loadSvgString:o,sanitizeSvg:a,serializeSvgToString:c,SvgElement:u,SVGRenderer:r,fixForVanilla:h,DOMPurify:d}},function(t,e,n){const r=n(39),i=n(15),s=n(47),o=n(9),a=n(46),c=n(40),u=n(12),l=n(0),h=n(7),d=n(4),p=n(6),f=n(72),m=n(255),{loadCostume:g}=n(31),{loadSound:b}=n(30),{deserializeCostume:y,deserializeSound:v}=n(81),w=Object.prototype.hasOwnProperty,T=["argument","colour","control","data","event","looks","math","motion","operator","procedures","sensing","sound"],E=12,A=13,k={math_number:[4,"NUM"],math_positive_number:[5,"NUM"],math_whole_number:[6,"NUM"],math_integer:[7,"NUM"],math_angle:[8,"NUM"],colour_picker:[9,"COLOUR"],text:[10,"TEXT"],event_broadcast_menu:[11,"BROADCAST_OPTION"],data_variable:[E,"VARIABLE"],data_listcontents:[A,"LIST"]},I=8e3,S=function(t){const e=function(t){if(w.call(k,t.opcode)){const e=k[t.opcode],n=e[0],r=e[1],i=t.fields[r],s=[n,i.value];return"event_broadcast_menu"===t.opcode?s.push(i.id):"data_variable"!==t.opcode&&"data_listcontents"!==t.opcode||(s.push(i.id),t.topLevel&&(s.push(t.x?Math.round(t.x):0),s.push(t.y?Math.round(t.y):0))),s}return null}(t);if(e)return e;const n=Object.create(null);return n.opcode=t.opcode,n.next=t.next,n.parent=t.parent,n.inputs=function(t){const e=Object.create(null);for(const n in t)w.call(t,n)&&(t[n].block===t[n].shadow?e[n]=[1,t[n].block]:null===t[n].shadow?e[n]=[2,t[n].block]:e[n]=[3,t[n].block,t[n].shadow]);return e}(t.inputs),n.fields=function(t){const e=Object.create(null);for(const n in t)w.call(t,n)&&(e[n]=[t[n].value],Object.prototype.hasOwnProperty.call(t[n],"id")&&e[n].push(t[n].id));return e}(t.fields),n.shadow=t.shadow,t.topLevel?(n.topLevel=!0,n.x=t.x?Math.round(t.x):0,n.y=t.y?Math.round(t.y):0):n.topLevel=!1,t.mutation&&(n.mutation=t.mutation),t.comment&&(n.comment=t.comment),n},x=function(t,e){const n=t.inputs;for(const t in n){const r=n[t];for(let t=1;t{if(!e.extensionManager)return null;const n=e.extensionManager.getExtensionURLs(),r={};for(const e of t){const t=n[e];"string"==typeof t&&(r[e]=t)}return 0===Object.keys(r).length?null:r},N=function(t){const e=Object.create(null),n=new Set;for(const r in t){if(!Object.prototype.hasOwnProperty.call(t,r))continue;e[r]=S(t[r]);const i=O(t[r].opcode);i&&n.add(i)}for(const t in e){const n=e[t];e[t]=x(n,e)}for(const t in e){const n=e[t];Array.isArray(n)&&[E,A].indexOf(n[0])<0&&(l.warn("Found an unexpected top level primitive with block ID: ".concat(t,"; deleting it from serialized blocks.")),delete e[t])}return[e,Array.from(n)]},C=function(t){const e=Object.create(null);e.name=t.name;const n=t.broken||t;return e.bitmapResolution=n.bitmapResolution,e.dataFormat=n.dataFormat.toLowerCase(),e.assetId=n.assetId,e.md5ext=n.md5,e.rotationCenterX=n.rotationCenterX,e.rotationCenterY=n.rotationCenterY,e},R=function(t){const e=Object.create(null);e.name=t.name;const n=t.broken||t;return e.assetId=n.assetId,e.dataFormat=n.dataFormat.toLowerCase(),e.format=n.format,e.rate=n.rate,e.sampleCount=n.sampleCount,e.md5ext=n.md5,e},D=t=>"number"==typeof t||"string"==typeof t||"boolean"==typeof t,P=t=>{if(Array.isArray(t)){let e=null;for(let n=0;nI?(i.text=r.text.substring(0,I),i.extraText=r.text.substring(I)):i.text=r.text,e[n]=i}return e}(t.comments),(t.currentCostume<0||t.currentCostume>=t.costumes.length)&&(l.warn("currentCostume property for target ".concat(t.name," is out of range")),t.currentCostume=d.clamp(t.currentCostume,0,t.costumes.length-1)),n.currentCostume=t.currentCostume,n.costumes=t.costumes.map(C),n.sounds=t.sounds.map(R),Object.prototype.hasOwnProperty.call(t,"volume")&&(n.volume=t.volume),Object.prototype.hasOwnProperty.call(t,"layerOrder")&&(n.layerOrder=t.layerOrder),n.isStage?(Object.prototype.hasOwnProperty.call(t,"tempo")&&(n.tempo=t.tempo),Object.prototype.hasOwnProperty.call(t,"videoTransparency")&&(n.videoTransparency=t.videoTransparency),Object.prototype.hasOwnProperty.call(t,"videoState")&&(n.videoState=t.videoState),Object.prototype.hasOwnProperty.call(t,"textToSpeechLanguage")&&(n.textToSpeechLanguage=t.textToSpeechLanguage)):(n.visible=t.visible,n.x=t.x,n.y=t.y,n.size=t.size,n.direction=t.direction,n.draggable=t.draggable,n.rotationStyle=t.rotationStyle),r.forEach((t=>{e.add(t)})),n},B=(t,e)=>{const n={};let r=!0;for(const[i,s]of Object.entries(t))e.has(i)&&null!=s&&(r=!1,n[i]=t[i]);return r?null:n},U=function(t,e,n,r){if(!Array.isArray(t))return t;const i=Object.create(null),s=h();switch(i.id=s,i.next=null,i.parent=e,i.shadow=n,i.inputs=Object.create(null),t[0]){case 4:i.opcode="math_number",i.fields={NUM:{name:"NUM",value:t[1]}},i.topLevel=!1;break;case 5:i.opcode="math_positive_number",i.fields={NUM:{name:"NUM",value:t[1]}},i.topLevel=!1;break;case 6:i.opcode="math_whole_number",i.fields={NUM:{name:"NUM",value:t[1]}},i.topLevel=!1;break;case 7:i.opcode="math_integer",i.fields={NUM:{name:"NUM",value:t[1]}},i.topLevel=!1;break;case 8:i.opcode="math_angle",i.fields={NUM:{name:"NUM",value:t[1]}},i.topLevel=!1;break;case 9:i.opcode="colour_picker",i.fields={COLOUR:{name:"COLOUR",value:t[1]}},i.topLevel=!1;break;case 10:i.opcode="text",i.fields={TEXT:{name:"TEXT",value:t[1]}},i.topLevel=!1;break;case 11:i.opcode="event_broadcast_menu",i.fields={BROADCAST_OPTION:{name:"BROADCAST_OPTION",value:t[1],id:t[2],variableType:o.BROADCAST_MESSAGE_TYPE}},i.topLevel=!1;break;case E:i.opcode="data_variable",i.fields={VARIABLE:{name:"VARIABLE",value:t[1],id:t[2],variableType:o.SCALAR_TYPE}},t.length>3&&(i.topLevel=!0,i.x=t[3],i.y=t[4]);break;case A:i.opcode="data_listcontents",i.fields={LIST:{name:"LIST",value:t[1],id:t[2],variableType:o.LIST_TYPE}},t.length>3&&(i.topLevel=!0,i.x=t[3],i.y=t[4]);break;default:return l.error("Found unknown primitive type during deserialization: ".concat(JSON.stringify(t))),null}return r[s]=i,s},j=function(t,e,n){const r={};for(const i in t){if(!w.call(t,i))continue;const s=t[i];if(!Array.isArray(s))continue;let o=null,a=null;const c=s[0];1===c?o=a=U(s[1],e,!0,n):2===c?o=U(s[1],e,!1,n):(o=U(s[1],e,!1,n),a=U(s[2],e,!0,n)),r[i]={name:i,block:o,shadow:a}}return r},F=function(t){const e={};for(const n in t){if(!w.call(t,n))continue;const r=t[n];Array.isArray(r)&&(e[n]={name:n,value:r[0]},r.length>1&&(e[n].id=r[1]),"BROADCAST_OPTION"===n?e[n].variableType=o.BROADCAST_MESSAGE_TYPE:"VARIABLE"===n?e[n].variableType=o.SCALAR_TYPE:"LIST"===n&&(e[n].variableType=o.LIST_TYPE))}return e},z=function(t){for(const e in t){if(!Object.prototype.hasOwnProperty.call(t,e))continue;const n=t[e];Array.isArray(n)?(delete t[e],U(n,null,!1,t)):(n.id=e,n.inputs=j(n.inputs,e,t),n.fields=F(n.fields))}return t};t.exports={serialize:function(t,e){let{allowOptimization:n=!0}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=Object.create(null),i=new Set,s=e?[t.getTargetById(e)]:t.targets.filter((t=>t.isOriginal)),o=function(t){const e=t.map((t=>t.getLayerOrder()));return d.reducedSortOrdering(e)}(s),a=s.map((t=>t.toJSON()));t.renderer&&!e&&a.forEach(((t,e)=>{t.layerOrder=o[e]}));const c=a.map((t=>L(t,i))).map(((t,e)=>{const n=s[e],r=B(n.extensionStorage,i);return r&&(t.extensionStorage=r),t})),u=t.fontManager.serializeJSON();if(e){const e=c[0];i.size&&(e.extensions=Array.from(i));const n=M(i,t);return n&&(e.extensionURLs=n),u&&(e.customFonts=u),c[0]}const l=B(t.extensionStorage,i);l&&(r.extensionStorage=l),r.targets=c,r.monitors=function(t,e,n){const r=(e.stageWidth-480)/2,i=(e.stageHeight-360)/2;return t.valueSeq().filter((t=>{const e=O(t.opcode);return!e||!!t.visible&&(n.add(e),!0)})).map((t=>{const e={id:t.id,mode:t.mode,opcode:t.opcode,params:t.params,spriteName:t.spriteName,value:Array.isArray(t.value)?[]:0,width:t.width,height:t.height,x:t.x-r,y:t.y-i,visible:t.visible};return"list"!==t.mode&&(e.sliderMin=t.sliderMin,e.sliderMax=t.sliderMax,e.isDiscrete=t.isDiscrete),e})).toArray()}(t.getMonitorState(),t,i),r.extensions=Array.from(i);const h=M(i,t);h&&(r.extensionURLs=h),u&&(r.customFonts=u);const p=Object.create(null);return p.semver="3.0.0",p.vm="0.2.0",t.origin&&(p.origin=t.origin),p.agent="",p.platform=Object.assign({},t.platform),r.meta=p,n&&m(r),r},deserialize:async function(t,e,n,h){await((t,e)=>{if(!t.meta||!t.meta.platform)return;if(t.meta.platform.name===e.platform.name)return;let n=e.listenerCount(r.PLATFORM_MISMATCH);return 0!==n?new Promise((i=>{e.emit(r.PLATFORM_MISMATCH,t.meta.platform,(()=>{n--,0===n&&i()}))})):void 0})(t,e);const m={extensionIDs:new Set,extensionURLs:new Map};if(t.meta&&t.meta.origin?e.origin=t.meta.origin:e.origin=null,t.extensionURLs)for(const[e,n]of Object.entries(t.extensionURLs))m.extensionURLs.set(e,n);let w;w=t.customFonts?e.fontManager.deserialize(t.customFonts,n,h):Promise.resolve();const T=((h?[t]:t.targets)||[]).map(((t,e)=>Object.assign(t,{targetPaneOrder:e}))).sort(((t,e)=>t.layerOrder-e.layerOrder)),E=t.monitors||[];return w.then((()=>T.map((t=>function(t,e,n){if(!Object.prototype.hasOwnProperty.call(t,"name"))return Promise.resolve(null);const r={costumePromises:null,soundPromises:null,soundBank:e.audioEngine&&e.audioEngine.createBank()};return r.costumePromises=(t.costumes||[]).map((t=>{const r={asset:t.asset,assetId:t.assetId,skinId:null,name:t.name,bitmapResolution:t.bitmapResolution,rotationCenterX:t.rotationCenterX,rotationCenterY:t.rotationCenterY},i=t.dataFormat||t.assetType&&t.assetType.runtimeFormat||"png",s=Object.prototype.hasOwnProperty.call(t,"md5ext")?t.md5ext:"".concat(t.assetId,".").concat(i);return r.md5=s,r.dataFormat=i,e.wrapAssetRequest((()=>y(r,e,n).then((()=>g(s,r,e)))))})),r.soundPromises=(t.sounds||[]).map((t=>{const i={assetId:t.assetId,format:t.format,rate:t.rate,sampleCount:t.sampleCount,name:t.name,md5:t.md5ext,dataFormat:t.dataFormat,data:null};return e.wrapAssetRequest((()=>v(i,e,n).then((()=>b(i,e,r.soundBank)))))})),r}(t,e,n))))).then((t=>Promise.resolve(t))).then((t=>Promise.all(T.map(((n,r)=>function(t,e,n,r,c){if(!Object.prototype.hasOwnProperty.call(t,"name"))return Promise.resolve(null);const l=new i(e),h=new s(l,e);if(Object.prototype.hasOwnProperty.call(t,"name")&&(h.name=t.name),Object.prototype.hasOwnProperty.call(t,"blocks")){z(t.blocks);for(const e in t.blocks){if(!Object.prototype.hasOwnProperty.call(t.blocks,e))continue;const r=t.blocks[e];l.createBlock(r);const i=O(r.opcode);i&&n.extensionIDs.add(i)}}const{costumePromises:p}=c,{soundBank:f,soundPromises:m}=c,g=h.createClone(t.isStage?u.BACKGROUND_LAYER:u.SPRITE_LAYER);if(Object.prototype.hasOwnProperty.call(t,"tempo")&&(g.tempo=t.tempo),Object.prototype.hasOwnProperty.call(t,"volume")&&(g.volume=t.volume),Object.prototype.hasOwnProperty.call(t,"videoTransparency")&&(g.videoTransparency=t.videoTransparency),Object.prototype.hasOwnProperty.call(t,"videoState")&&(g.videoState=t.videoState),Object.prototype.hasOwnProperty.call(t,"textToSpeechLanguage")&&(g.textToSpeechLanguage=t.textToSpeechLanguage),Object.prototype.hasOwnProperty.call(t,"variables"))for(const n in t.variables){const r=t.variables[n],i=3===r.length&&r[2]&&t.isStage&&e.canAddCloudVariable(),s=new o(n,r[0],o.SCALAR_TYPE,i);i&&e.addCloudVariable(),s.value=r[1],g.variables[s.id]=s}if(Object.prototype.hasOwnProperty.call(t,"lists"))for(const e in t.lists){const n=t.lists[e],r=new o(e,n[0],o.LIST_TYPE,!1);r.value=n[1],g.variables[r.id]=r}if(Object.prototype.hasOwnProperty.call(t,"broadcasts"))for(const e in t.broadcasts){const n=t.broadcasts[e],r=new o(e,n,o.BROADCAST_MESSAGE_TYPE,!1);g.variables[r.id]=r}if(Object.prototype.hasOwnProperty.call(t,"comments"))for(const e in t.comments){const n=t.comments[e],r=new a(e,n.text+("string"==typeof n.extraText?n.extraText:""),n.x,n.y,n.width,n.height,n.minimized);n.blockId&&(r.blockId=n.blockId),g.comments[r.id]=r}return Object.prototype.hasOwnProperty.call(t,"x")&&(g.x=t.x),Object.prototype.hasOwnProperty.call(t,"y")&&(g.y=t.y),Object.prototype.hasOwnProperty.call(t,"direction")&&(g.direction=d.wrapClamp(t.direction,-179,180)),Object.prototype.hasOwnProperty.call(t,"size")&&(g.size=t.size),Object.prototype.hasOwnProperty.call(t,"visible")&&(g.visible=t.visible),Object.prototype.hasOwnProperty.call(t,"currentCostume")&&(g.currentCostume=d.clamp(t.currentCostume,0,t.costumes.length-1)),Object.prototype.hasOwnProperty.call(t,"rotationStyle")&&(g.rotationStyle=t.rotationStyle),Object.prototype.hasOwnProperty.call(t,"isStage")&&(g.isStage=t.isStage),Object.prototype.hasOwnProperty.call(t,"targetPaneOrder")&&(g.targetPaneOrder=t.targetPaneOrder),Object.prototype.hasOwnProperty.call(t,"draggable")&&(g.draggable=t.draggable),Object.prototype.hasOwnProperty.call(t,"extensionStorage")&&(g.extensionStorage=t.extensionStorage),Promise.all(p).then((t=>{h.costumes=t})),Promise.all(m).then((t=>{h.sounds=t,h.soundBank=f||null})),Promise.all(p.concat(m)).then((()=>g))}(n,e,m,0,t[r])))))).then((t=>t.map(((t,e)=>(t.layerOrder=e,t))).sort(((t,e)=>t.targetPaneOrder-e.targetPaneOrder)).map((t=>(delete t.targetPaneOrder,t))))).then((t=>function(t){const e=f.getAllVarRefsForTargets(t,!0);t.forEach((t=>{Object.keys(t.variables).forEach((e=>{const n=p.replaceUnsafeChars(e);n!==e&&(t.variables[e].id=n,t.variables[n]=t.variables[e],delete t.variables[e])}))}));for(const t in e){const n=p.replaceUnsafeChars(t);t!==n&&f.updateVariableIdentifiers(e[t],n)}return t}(t))).then((n=>(E.map((t=>function(t,e,n,r){const i=(e.stageWidth-480)/2,s=(e.stageHeight-360)/2;if(t.x+=i,t.y+=s,t.x=d.clamp(t.x,0,e.stageWidth),t.y=d.clamp(t.y,0,e.stageHeight),t.spriteName){const e=n.filter((e=>e.sprite.name===t.spriteName));e&&e.length>0?t.targetId=e[0].id:l.warn("Tried to deserialize sprite specific monitor ".concat(t.opcode," but could not find sprite ").concat(t.spriteName,"."))}const a=e.monitorBlockInfo[t.opcode];if("data_listcontents"===t.opcode){const e=t.targetId?n.find((e=>e.id===t.targetId)):n.find((t=>t.isStage));e&&Object.prototype.hasOwnProperty.call(e.variables,t.id)&&(t.params.LIST=e.variables[t.id].name)}const u={};for(const e in t.params){const n={name:e,value:t.params[e]};u[e]=n}"data_variable"!==t.opcode&&"data_listcontents"!==t.opcode&&a&&a.isSpriteSpecific?t.id=a.getId(t.targetId,u):t.id=p.replaceUnsafeChars(t.id);const h=e.monitorBlocks._blocks[t.id];if(h)h.isMonitored=t.visible,h.targetId=t.targetId;else{const n={id:t.id,opcode:t.opcode,inputs:{},fields:u,topLevel:!0,next:null,parent:null,shadow:!1,x:0,y:0,isMonitored:t.visible,targetId:t.targetId};if("data_variable"===t.opcode){const e=n.fields.VARIABLE;e.id=t.id,e.variableType=o.SCALAR_TYPE}else if("data_listcontents"===t.opcode){const e=n.fields.LIST;e.id=t.id,e.variableType=o.LIST_TYPE}e.monitorBlocks.createBlock(n);const i=O(n.opcode);i&&r.extensionIDs.add(i)}e.requestAddMonitor(c(t))}(t,e,n,m))),Object.prototype.hasOwnProperty.call(t,"extensionStorage")&&(e.extensionStorage=t.extensionStorage),n))).then((t=>({targets:t,extensions:m})))},deserializeBlocks:z,serializeBlocks:N,deserializeStandaloneBlocks:t=>{if((t=JSON.parse(JSON.stringify(t))).extensionURLs){const e=new Map;for(const[n,r]of Object.entries(t.extensionURLs))e.set(n,r);return{blocks:t.blocks,extensionURLs:e}}return{blocks:t,extensionURLs:new Map}},serializeStandaloneBlocks:(t,e)=>{const n=new Set;for(const e of t){const t=O(e.opcode);t&&n.add(t)}const r=M(n,e);return r?{blocks:t,extensionURLs:r}:t},getExtensionIdForOpcode:O}},function(t,e,n){const r=n(10),i=n(32),s=n(264);t.exports=class{constructor(t,e){this._renderer=e,this._id=t,this._rotationCenter=r.v3.create(0,0),this._texture=null,this._uniforms={u_skinSize:[0,0],u_skin:null},this._silhouette=new s,this.private=!1}dispose(){this._id=i.ID_NONE}get id(){return this._id}get rotationCenter(){return this._rotationCenter}get size(){return[0,0]}useNearest(t,e){return!0}calculateRotationCenter(){return[this.size[0]/2,this.size[1]/2]}getTexture(t){return this._emptyImageTexture}getFenceBounds(t,e){return t.getAABB(e)}getUniforms(t){return this._uniforms.u_skin=this.getTexture(t),this._uniforms.u_skinSize=this.size,this._uniforms}emitWasAltered(){this._renderer.skinWasAltered(this)}updateSilhouette(){this._silhouette.unlazy()}_setTexture(t){const e=this._renderer.gl;e.bindTexture(e.TEXTURE_2D,this._texture),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!1),this._silhouette.update(t)}setEmptyImageData(){if(this._texture=null,!this._emptyImageData){this._emptyImageData=new ImageData(1,1);const t=this._renderer.gl,e={auto:!0,wrap:t.CLAMP_TO_EDGE,src:this._emptyImageData};this._emptyImageTexture=r.createTexture(t,e)}this._rotationCenter[0]=0,this._rotationCenter[1]=0,this._silhouette.update(this._emptyImageData),this.emitWasAltered()}isTouchingNearest(t){return this._silhouette.isTouchingNearest(t)}isTouchingLinear(t){return this._silhouette.isTouchingLinear(t)}}},function(t,e,n){const r=n(10);class i{constructor(t){this._gl=t,this._shaderCache={};for(const t in i.DRAW_MODE)Object.prototype.hasOwnProperty.call(i.DRAW_MODE,t)&&(this._shaderCache[t]=[])}getShader(t,e){const n=this._shaderCache[t];t===i.DRAW_MODE.silhouette&&(e&=~(i.EFFECT_INFO.color.mask|i.EFFECT_INFO.brightness.mask));let r=n[e];return r||(r=n[e]=this._buildShader(t,e)),r}_buildShader(t,e){const s=i.EFFECTS.length,o=["#define DRAW_MODE_".concat(t)];for(let t=0;t{console.error(t);const e=t.match(/\*\*\* Error compiling shader: ([\s\S]+)/);l=e?e[1].trim():t}));if(!h)throw new Error("Failed to compile shader (mode ".concat(t,", effects ").concat(e,"): ").concat(l));return h}}i.EFFECT_INFO={color:{uniformName:"u_color",mask:1,converter:t=>t/200%1,shapeChanges:!1},fisheye:{uniformName:"u_fisheye",mask:2,converter:t=>Math.max(0,(t+100)/100),shapeChanges:!0},whirl:{uniformName:"u_whirl",mask:4,converter:t=>-t*Math.PI/180,shapeChanges:!0},pixelate:{uniformName:"u_pixelate",mask:8,converter:t=>Math.abs(t)/10,shapeChanges:!0},mosaic:{uniformName:"u_mosaic",mask:16,converter:t=>(t=Math.round((Math.abs(t)+10)/10),Math.max(1,Math.min(t,512))),shapeChanges:!0},brightness:{uniformName:"u_brightness",mask:32,converter:t=>Math.max(-100,Math.min(t,100))/100,shapeChanges:!1},ghost:{uniformName:"u_ghost",mask:64,converter:t=>1-Math.max(0,Math.min(t,100))/100,shapeChanges:!1}},i.EFFECTS=Object.keys(i.EFFECT_INFO),i.DRAW_MODE={default:"default",straightAlpha:"straightAlpha",silhouette:"silhouette",colorMask:"colorMask",line:"line",background:"background"},t.exports=i},function(t,e){const n="undefined"==typeof document,r=n?"[0m":"",i=n?"[90m":"",s=`${n?"[34m":""}debug${r}`,o=`${n?"[36m":""}info${r}`,a=`${n?"[33m":""}warn${r}`,c=`${n?"[31m":""}error${r}`,u=(t="")=>{const e=e=>u(t?`${t} ${e}`:e),n=t?[`${i}${t}${r}`]:[];return e.debug=e.log=console.debug.bind(console,...n,s),e.info=console.log.bind(console,...n,o),e.warn=e.warning=console.warn.bind(console,...n,a),e.error=console.error.bind(console,...n,c),e};u.enable=u.disable=()=>{},t.exports=u},function(t,e,n){const r=n(58);t.exports=class extends r{constructor(t,e,n,r){let i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;super(),this._socket=t.getScratchLinkSocket("BLE"),this._socket.setOnOpen(this.requestPeripheral.bind(this)),this._socket.setOnClose(this.handleDisconnectError.bind(this)),this._socket.setOnError(this._handleRequestError.bind(this)),this._socket.setHandleMessage(this._handleMessage.bind(this)),this._sendMessage=this._socket.sendMessage.bind(this._socket),this._availablePeripherals={},this._connectCallback=r,this._connected=!1,this._characteristicDidChangeCallback=null,this._resetCallback=i,this._discoverTimeoutID=null,this._extensionId=e,this._peripheralOptions=n,this._runtime=t,this._socket.open()}requestPeripheral(){this._availablePeripherals={},this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID),this._discoverTimeoutID=window.setTimeout(this._handleDiscoverTimeout.bind(this),15e3),this.sendRemoteRequest("discover",this._peripheralOptions).catch((t=>{this._handleRequestError(t)}))}connectPeripheral(t){this.sendRemoteRequest("connect",{peripheralId:t}).then((()=>{this._connected=!0,this._runtime.emit(this._runtime.constructor.PERIPHERAL_CONNECTED),this._connectCallback()})).catch((t=>{this._handleRequestError(t)}))}disconnect(){this._connected&&(this._connected=!1),this._socket.isOpen()&&this._socket.close(),this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID),this._runtime.emit(this._runtime.constructor.PERIPHERAL_DISCONNECTED)}isConnected(){return this._connected}startNotifications(t,e){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;const r={serviceId:t,characteristicId:e};return this._characteristicDidChangeCallback=n,this.sendRemoteRequest("startNotifications",r).catch((t=>{this.handleDisconnectError(t)}))}read(t,e){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;const r={serviceId:t,characteristicId:e};return arguments.length>2&&void 0!==arguments[2]&&arguments[2]&&(r.startNotifications=!0),n&&(this._characteristicDidChangeCallback=n),this.sendRemoteRequest("read",r).catch((t=>{this.handleDisconnectError(t)}))}write(t,e,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;const s={serviceId:t,characteristicId:e,message:n};return r&&(s.encoding=r),null!==i&&(s.withResponse=i),this.sendRemoteRequest("write",s).catch((t=>{this.handleDisconnectError(t)}))}didReceiveCall(t,e){switch(t){case"didDiscoverPeripheral":this._availablePeripherals[e.peripheralId]=e,this._runtime.emit(this._runtime.constructor.PERIPHERAL_LIST_UPDATE,this._availablePeripherals),this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID);break;case"userDidPickPeripheral":this._availablePeripherals[e.peripheralId]=e,this._runtime.emit(this._runtime.constructor.USER_PICKED_PERIPHERAL,this._availablePeripherals),this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID);break;case"userDidNotPickPeripheral":this._runtime.emit(this._runtime.constructor.PERIPHERAL_SCAN_TIMEOUT),this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID);break;case"characteristicDidChange":this._characteristicDidChangeCallback&&this._characteristicDidChangeCallback(e.message);break;case"ping":return 42}}handleDisconnectError(){this._connected&&(this.disconnect(),this._resetCallback&&this._resetCallback(),this._runtime.emit(this._runtime.constructor.PERIPHERAL_CONNECTION_LOST_ERROR,{message:"Scratch lost connection to",extensionId:this._extensionId}))}_handleRequestError(){this._runtime.emit(this._runtime.constructor.PERIPHERAL_REQUEST_ERROR,{message:"Scratch lost connection to",extensionId:this._extensionId})}_handleDiscoverTimeout(){this._discoverTimeoutID&&window.clearTimeout(this._discoverTimeoutID),this._runtime.emit(this._runtime.constructor.PERIPHERAL_SCAN_TIMEOUT)}}},function(t,e,n){const r=n(0);t.exports=function(t){if("string"!=typeof t){if(!Array.isArray(t))return r.error("Unexpected input recieved in replaceUnsafeChars"),t;t=String(t)}return t.replace(/[<>&'"]/g,(t=>{switch(t){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case'"':return"""}}))}},function(t,e,n){const r=n(6),i=n(0),s=function(t,e,n,r){return t.assetId=e.assetId,n.audioEngine?n.audioEngine.decodeSoundPlayer(Object.assign({},t,{data:e.data})).then((e=>{t.soundId=e.id;const i=e.buffer;return t.rate=i.sampleRate,t.sampleCount=i.length,null!==r&&r.addSoundPlayer(e),n.isPackaged&&(t.asset=null),t})):(i.warn("No audio engine present; cannot load sound asset: ",t.md5),Promise.resolve(t))},o=function(t,e,n){const r=t.asset,i=t.assetId,o=t.sampleCount,a=t.rate,c=t.format,u=t.dataFormat;return t.assetId=e.storage.defaultAssetId.Sound,t.asset=e.storage.get(t.assetId),t.md5="".concat(t.assetId,".").concat(t.asset.dataFormat),s(t,t.asset,e,n).then((t=>(t.broken={},t.broken.assetId=i,t.broken.md5="".concat(i,".").concat(u),t.broken.asset=r,t.broken.sampleCount=o,t.broken.rate=a,t.broken.format=c,t.broken.dataFormat=u,t)))};t.exports={loadSound:function(t,e,n){if(!e.storage)return i.warn("No storage module present; cannot load sound asset: ",t.md5),Promise.resolve(t);const a=r.splitFirst(t.md5,"."),c=a[0],u=a[1].toLowerCase();return t.dataFormat=u,(t.asset&&Promise.resolve(t.asset)||e.storage.load(e.storage.AssetType.Sound,c,u)).then((r=>(t.asset=r,r?s(t,r,e,n):(i.warn("Failed to find sound data: ",t.md5),o(t,e,n))))).catch((r=>(i.warn("Failed to load sound: ".concat(t.md5," with error: ").concat(r)),o(t,e,n))))},loadSoundFromAsset:s}},function(t,e,n){const r=n(6),i=n(0),s=n(71),{loadSvgString:o,serializeSvgToString:a}=n(23),{parseVectorMetadata:c}=n(78),u=function(t,e,n,r){return new Promise((i=>{let s=t.asset.decodeText();if(void 0===n){const e=c(s);e&&(n=e,t.rotationCenterX=n[0],t.rotationCenterY=n[1])}if(r&&2===r){const n=a(o(s,!0));if(s!==n){s=n;const r=e.storage;t.asset.encodeTextData(n,r.DataFormat.SVG,!0),t.assetId=t.asset.assetId,t.md5="".concat(t.assetId,".").concat(t.dataFormat)}}t.skinId=e.renderer.createSVGSkin(s,n),t.size=e.renderer.getSkinSize(t.skinId),n||(n=e.renderer.getSkinRotationCenter(t.skinId),t.rotationCenterX=n[0],t.rotationCenterY=n[1],t.bitmapResolution=1),e.isPackaged&&(t.asset=null),i(t)}))},l=new class{constructor(){this.pool=[],this.clearSoon=null}clear(){this.clearSoon||(this.clearSoon=new Promise((t=>setTimeout(t,1e3))).then((()=>{this.pool.length=0,this.clearSoon=null})))}create(){return this.pool.pop()||document.createElement("canvas")}release(t){this.clear(),this.pool.push(t)}},h=t=>new Promise(((e,n)=>{const r=new Image;r.onload=function(){e(r),r.onload=null,r.onerror=null},r.onerror=function(){n(new Error("Costume load failed. Asset could not be read.")),r.onload=null,r.onerror=null},r.src=t})),d=new s((async t=>{let e;for(let n=0;n<3;n++)try{if("function"==typeof createImageBitmap){const e=await createImageBitmap(new Blob([t.data.buffer],{type:t.assetType.contentType}));if(!e)throw new Error("createImageBitmap resolved with ".concat(e));return e}return await h(t.encodeDataURI())}catch(t){e||(e=t),i.warn(t),await new Promise((t=>setTimeout(t,2e3*Math.random())))}throw e}),25),p=function(t,e,n){return function(t,e,n){return t&&t.asset?e.v2BitmapAdapter?Promise.all([t.asset,t.textLayerAsset].map((t=>t?d.do(t):null))).then((r=>{let[i,s]=r;if(!i)throw new Error("Loading bitmap costume base failed.");const o=1===t.bitmapResolution?2:1;let a,c;if(s){c=l.create(),c.width=i.width,c.height=i.height;const t=c.getContext("2d");t.drawImage(i,0,0),t.drawImage(s,0,0),a=c}else a=i;return 1!==o&&(a=e.v2BitmapAdapter.resize(a,a.width*o,a.height*o),c&&l.release(c)),a.reusable=!1,n&&(n[0]=n[0]*o,n[1]=n[1]*o,t.rotationCenterX=n[0],t.rotationCenterY=n[1]),t.bitmapResolution=2,delete t.textLayerMD5,delete t.textLayerAsset,{image:a,rotationCenter:n,assetMatchesBase:1===o&&!s}})).finally((()=>{delete t.textLayerMD5,delete t.textLayerAsset})):Promise.reject("No V2 Bitmap adapter present."):Promise.reject("Costume load failed. Assets were missing.")}(t,e,n).then((n=>(n.assetMatchesBase||function(n){if(!e.v2BitmapAdapter)return Promise.reject("No V2 Bitmap adapter present.");const r=e.storage;t.asset=r.createAsset(r.AssetType.ImageBitmap,r.DataFormat.PNG,e.v2BitmapAdapter.convertDataURIToBinary(n),null,!0),t.dataFormat=r.DataFormat.PNG,t.assetId=t.asset.assetId,t.md5="".concat(t.assetId,".").concat(t.dataFormat)}((t=>{if(t instanceof HTMLCanvasElement)return t.toDataURL();const e=l.create();e.width=t.width,e.height=t.height,e.getContext("2d").drawImage(t,0,0);const n=e.toDataURL();return l.release(e),n})(n.image)),n))).then((n=>{let r,{image:i,rotationCenter:s}=n;s&&(r=[s[0]/2,s[1]/2]),t.skinId=e.renderer.createBitmapSkin(i,t.bitmapResolution,r);const o=e.renderer.getSkinSize(t.skinId);return t.size=[2*o[0],2*o[1]],s||(s=e.renderer.getSkinRotationCenter(t.skinId),t.rotationCenterX=2*s[0],t.rotationCenterY=2*s[1],t.bitmapResolution=2),e.isPackaged&&(t.asset=null),t}))},f=function(t,e){const n=t.asset,r=t.assetId,i=t.rotationCenterX,s=t.rotationCenterY,o=t.bitmapResolution,a=t.dataFormat,c=e.storage.AssetType,l=t.dataFormat===c.ImageVector.runtimeFormat;t.assetId=l?e.storage.defaultAssetId.ImageVector:e.storage.defaultAssetId.ImageBitmap,t.asset=e.storage.get(t.assetId),t.md5="".concat(t.assetId,".").concat(t.asset.dataFormat);return(l?u(t,e):p(t,e)).then((t=>(t.broken={},t.broken.assetId=r,t.broken.md5="".concat(r,".").concat(a),t.broken.asset=n,t.broken.dataFormat=a,t.broken.rotationCenterX=i,t.broken.rotationCenterY=s,t.broken.bitmapResolution=o,t)))},m=function(t,e,n){t.assetId=t.asset.assetId;if(!e.renderer)return i.warn("No rendering module present; cannot load costume: ",t.name),Promise.resolve(t);const r=e.storage.AssetType;let s;return"number"!=typeof t.rotationCenterX||isNaN(t.rotationCenterX)||"number"!=typeof t.rotationCenterY||isNaN(t.rotationCenterY)||(s=[t.rotationCenterX,t.rotationCenterY]),t.asset.assetType.runtimeFormat===r.ImageVector.runtimeFormat?u(t,e,s,n).catch((n=>(i.warn("Error loading vector image: ".concat(n)),f(t,e)))):p(t,e,s).catch((n=>(i.warn("Error loading bitmap image: ".concat(n)),f(t,e))))};t.exports={loadCostume:function(t,e,n,s){const o=r.splitFirst(t,"."),a=o[0],c=o[1].toLowerCase();if(e.dataFormat=c,e.asset)return m(e,n,s);if(!n.storage)return i.warn("No storage module present; cannot load costume asset: ",t),Promise.resolve(e);if(!n.storage.defaultAssetId)return i.warn("No default assets found"),Promise.resolve(e);const u=n.storage.AssetType,l="svg"===c?u.ImageVector:u.ImageBitmap,h=n.storage.load(l,a,c);let d;return d=e.textLayerMD5?n.storage.load(u.ImageBitmap,e.textLayerMD5,"png"):Promise.resolve(null),Promise.all([h,d]).then((t=>t[0]?(e.asset=t[0],t[1]&&(e.textLayerAsset=t[1]),m(e,n,s)):f(e,n))).catch((t=>(i.warn("Error loading costume: ",t),f(e,n))))},loadCostumeFromAsset:m}},function(t,e){t.exports={ID_NONE:-1,Events:{UseHighQualityRenderChanged:"UseHighQualityRenderChanged",AllowPrivateSkinAccessChanged:"AllowPrivateSkinAccessChanged",NativeSizeChanged:"NativeSizeChanged"}}},function(t,e,n){const r=n(27);r.enable(),t.exports=r("scratch-audioengine")},function(module,exports,__webpack_require__){(function(process,global){var __WEBPACK_AMD_DEFINE_RESULT__;(function(){"use strict";var ERROR="input is invalid type",WINDOW="object"==typeof window,root=WINDOW?window:{};root.JS_MD5_NO_WINDOW&&(WINDOW=!1);var WEB_WORKER=!WINDOW&&"object"==typeof self,NODE_JS=!root.JS_MD5_NO_NODE_JS&&"object"==typeof process&&process.versions&&process.versions.node;NODE_JS?root=global:WEB_WORKER&&(root=self);var COMMON_JS=!root.JS_MD5_NO_COMMON_JS&&"object"==typeof module&&module.exports,AMD=__webpack_require__(254),ARRAY_BUFFER=!root.JS_MD5_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,HEX_CHARS="0123456789abcdef".split(""),EXTRA=[128,32768,8388608,-2147483648],SHIFT=[0,8,16,24],OUTPUT_TYPES=["hex","array","digest","buffer","arrayBuffer","base64"],BASE64_ENCODE_CHAR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),blocks=[],buffer8;if(ARRAY_BUFFER){var buffer=new ArrayBuffer(68);buffer8=new Uint8Array(buffer),blocks=new Uint32Array(buffer)}!root.JS_MD5_NO_NODE_JS&&Array.isArray||(Array.isArray=function(t){return"[object Array]"===Object.prototype.toString.call(t)}),!ARRAY_BUFFER||!root.JS_MD5_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(t){return"object"==typeof t&&t.buffer&&t.buffer.constructor===ArrayBuffer});var createOutputMethod=function(t){return function(e){return new Md5(!0).update(e)[t]()}},createMethod=function(){var t=createOutputMethod("hex");NODE_JS&&(t=nodeWrap(t)),t.create=function(){return new Md5},t.update=function(e){return t.create().update(e)};for(var e=0;e>2]|=t[s]<>6,c[i++]=128|63&r):r<55296||r>=57344?(c[i++]=224|r>>12,c[i++]=128|r>>6&63,c[i++]=128|63&r):(r=65536+((1023&r)<<10|1023&t.charCodeAt(++s)),c[i++]=240|r>>18,c[i++]=128|r>>12&63,c[i++]=128|r>>6&63,c[i++]=128|63&r);else for(i=this.start;s>2]|=r<>2]|=(192|r>>6)<>2]|=(128|63&r)<=57344?(a[i>>2]|=(224|r>>12)<>2]|=(128|r>>6&63)<>2]|=(128|63&r)<>2]|=(240|r>>18)<>2]|=(128|r>>12&63)<>2]|=(128|r>>6&63)<>2]|=(128|63&r)<=64?(this.start=i-64,this.hash(),this.hashed=!0):this.start=i}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296|0,this.bytes=this.bytes%4294967296),this}},Md5.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var t=this.blocks,e=this.lastByteIndex;t[e>>2]|=EXTRA[3&e],e>=56&&(this.hashed||this.hash(),t[0]=t[16],t[16]=t[1]=t[2]=t[3]=t[4]=t[5]=t[6]=t[7]=t[8]=t[9]=t[10]=t[11]=t[12]=t[13]=t[14]=t[15]=0),t[14]=this.bytes<<3,t[15]=this.hBytes<<3|this.bytes>>>29,this.hash()}},Md5.prototype.hash=function(){var t,e,n,r,i,s,o=this.blocks;this.first?e=((e=((t=((t=o[0]-680876937)<<7|t>>>25)-271733879|0)^(n=((n=(-271733879^(r=((r=(-1732584194^2004318071&t)+o[1]-117830708)<<12|r>>>20)+t|0)&(-271733879^t))+o[2]-1126478375)<<17|n>>>15)+r|0)&(r^t))+o[3]-1316259209)<<22|e>>>10)+n|0:(t=this.h0,e=this.h1,n=this.h2,e=((e+=((t=((t+=((r=this.h3)^e&(n^r))+o[0]-680876936)<<7|t>>>25)+e|0)^(n=((n+=(e^(r=((r+=(n^t&(e^n))+o[1]-389564586)<<12|r>>>20)+t|0)&(t^e))+o[2]+606105819)<<17|n>>>15)+r|0)&(r^t))+o[3]-1044525330)<<22|e>>>10)+n|0),e=((e+=((t=((t+=(r^e&(n^r))+o[4]-176418897)<<7|t>>>25)+e|0)^(n=((n+=(e^(r=((r+=(n^t&(e^n))+o[5]+1200080426)<<12|r>>>20)+t|0)&(t^e))+o[6]-1473231341)<<17|n>>>15)+r|0)&(r^t))+o[7]-45705983)<<22|e>>>10)+n|0,e=((e+=((t=((t+=(r^e&(n^r))+o[8]+1770035416)<<7|t>>>25)+e|0)^(n=((n+=(e^(r=((r+=(n^t&(e^n))+o[9]-1958414417)<<12|r>>>20)+t|0)&(t^e))+o[10]-42063)<<17|n>>>15)+r|0)&(r^t))+o[11]-1990404162)<<22|e>>>10)+n|0,e=((e+=((t=((t+=(r^e&(n^r))+o[12]+1804603682)<<7|t>>>25)+e|0)^(n=((n+=(e^(r=((r+=(n^t&(e^n))+o[13]-40341101)<<12|r>>>20)+t|0)&(t^e))+o[14]-1502002290)<<17|n>>>15)+r|0)&(r^t))+o[15]+1236535329)<<22|e>>>10)+n|0,e=((e+=((r=((r+=(e^n&((t=((t+=(n^r&(e^n))+o[1]-165796510)<<5|t>>>27)+e|0)^e))+o[6]-1069501632)<<9|r>>>23)+t|0)^t&((n=((n+=(t^e&(r^t))+o[11]+643717713)<<14|n>>>18)+r|0)^r))+o[0]-373897302)<<20|e>>>12)+n|0,e=((e+=((r=((r+=(e^n&((t=((t+=(n^r&(e^n))+o[5]-701558691)<<5|t>>>27)+e|0)^e))+o[10]+38016083)<<9|r>>>23)+t|0)^t&((n=((n+=(t^e&(r^t))+o[15]-660478335)<<14|n>>>18)+r|0)^r))+o[4]-405537848)<<20|e>>>12)+n|0,e=((e+=((r=((r+=(e^n&((t=((t+=(n^r&(e^n))+o[9]+568446438)<<5|t>>>27)+e|0)^e))+o[14]-1019803690)<<9|r>>>23)+t|0)^t&((n=((n+=(t^e&(r^t))+o[3]-187363961)<<14|n>>>18)+r|0)^r))+o[8]+1163531501)<<20|e>>>12)+n|0,e=((e+=((r=((r+=(e^n&((t=((t+=(n^r&(e^n))+o[13]-1444681467)<<5|t>>>27)+e|0)^e))+o[2]-51403784)<<9|r>>>23)+t|0)^t&((n=((n+=(t^e&(r^t))+o[7]+1735328473)<<14|n>>>18)+r|0)^r))+o[12]-1926607734)<<20|e>>>12)+n|0,e=((e+=((s=(r=((r+=((i=e^n)^(t=((t+=(i^r)+o[5]-378558)<<4|t>>>28)+e|0))+o[8]-2022574463)<<11|r>>>21)+t|0)^t)^(n=((n+=(s^e)+o[11]+1839030562)<<16|n>>>16)+r|0))+o[14]-35309556)<<23|e>>>9)+n|0,e=((e+=((s=(r=((r+=((i=e^n)^(t=((t+=(i^r)+o[1]-1530992060)<<4|t>>>28)+e|0))+o[4]+1272893353)<<11|r>>>21)+t|0)^t)^(n=((n+=(s^e)+o[7]-155497632)<<16|n>>>16)+r|0))+o[10]-1094730640)<<23|e>>>9)+n|0,e=((e+=((s=(r=((r+=((i=e^n)^(t=((t+=(i^r)+o[13]+681279174)<<4|t>>>28)+e|0))+o[0]-358537222)<<11|r>>>21)+t|0)^t)^(n=((n+=(s^e)+o[3]-722521979)<<16|n>>>16)+r|0))+o[6]+76029189)<<23|e>>>9)+n|0,e=((e+=((s=(r=((r+=((i=e^n)^(t=((t+=(i^r)+o[9]-640364487)<<4|t>>>28)+e|0))+o[12]-421815835)<<11|r>>>21)+t|0)^t)^(n=((n+=(s^e)+o[15]+530742520)<<16|n>>>16)+r|0))+o[2]-995338651)<<23|e>>>9)+n|0,e=((e+=((r=((r+=(e^((t=((t+=(n^(e|~r))+o[0]-198630844)<<6|t>>>26)+e|0)|~n))+o[7]+1126891415)<<10|r>>>22)+t|0)^((n=((n+=(t^(r|~e))+o[14]-1416354905)<<15|n>>>17)+r|0)|~t))+o[5]-57434055)<<21|e>>>11)+n|0,e=((e+=((r=((r+=(e^((t=((t+=(n^(e|~r))+o[12]+1700485571)<<6|t>>>26)+e|0)|~n))+o[3]-1894986606)<<10|r>>>22)+t|0)^((n=((n+=(t^(r|~e))+o[10]-1051523)<<15|n>>>17)+r|0)|~t))+o[1]-2054922799)<<21|e>>>11)+n|0,e=((e+=((r=((r+=(e^((t=((t+=(n^(e|~r))+o[8]+1873313359)<<6|t>>>26)+e|0)|~n))+o[15]-30611744)<<10|r>>>22)+t|0)^((n=((n+=(t^(r|~e))+o[6]-1560198380)<<15|n>>>17)+r|0)|~t))+o[13]+1309151649)<<21|e>>>11)+n|0,e=((e+=((r=((r+=(e^((t=((t+=(n^(e|~r))+o[4]-145523070)<<6|t>>>26)+e|0)|~n))+o[11]-1120210379)<<10|r>>>22)+t|0)^((n=((n+=(t^(r|~e))+o[2]+718787259)<<15|n>>>17)+r|0)|~t))+o[9]-343485551)<<21|e>>>11)+n|0,this.first?(this.h0=t+1732584193|0,this.h1=e-271733879|0,this.h2=n-1732584194|0,this.h3=r+271733878|0,this.first=!1):(this.h0=this.h0+t|0,this.h1=this.h1+e|0,this.h2=this.h2+n|0,this.h3=this.h3+r|0)},Md5.prototype.hex=function(){this.finalize();var t=this.h0,e=this.h1,n=this.h2,r=this.h3;return HEX_CHARS[t>>4&15]+HEX_CHARS[15&t]+HEX_CHARS[t>>12&15]+HEX_CHARS[t>>8&15]+HEX_CHARS[t>>20&15]+HEX_CHARS[t>>16&15]+HEX_CHARS[t>>28&15]+HEX_CHARS[t>>24&15]+HEX_CHARS[e>>4&15]+HEX_CHARS[15&e]+HEX_CHARS[e>>12&15]+HEX_CHARS[e>>8&15]+HEX_CHARS[e>>20&15]+HEX_CHARS[e>>16&15]+HEX_CHARS[e>>28&15]+HEX_CHARS[e>>24&15]+HEX_CHARS[n>>4&15]+HEX_CHARS[15&n]+HEX_CHARS[n>>12&15]+HEX_CHARS[n>>8&15]+HEX_CHARS[n>>20&15]+HEX_CHARS[n>>16&15]+HEX_CHARS[n>>28&15]+HEX_CHARS[n>>24&15]+HEX_CHARS[r>>4&15]+HEX_CHARS[15&r]+HEX_CHARS[r>>12&15]+HEX_CHARS[r>>8&15]+HEX_CHARS[r>>20&15]+HEX_CHARS[r>>16&15]+HEX_CHARS[r>>28&15]+HEX_CHARS[r>>24&15]},Md5.prototype.toString=Md5.prototype.hex,Md5.prototype.digest=function(){this.finalize();var t=this.h0,e=this.h1,n=this.h2,r=this.h3;return[255&t,t>>8&255,t>>16&255,t>>24&255,255&e,e>>8&255,e>>16&255,e>>24&255,255&n,n>>8&255,n>>16&255,n>>24&255,255&r,r>>8&255,r>>16&255,r>>24&255]},Md5.prototype.array=Md5.prototype.digest,Md5.prototype.arrayBuffer=function(){this.finalize();var t=new ArrayBuffer(16),e=new Uint32Array(t);return e[0]=this.h0,e[1]=this.h1,e[2]=this.h2,e[3]=this.h3,t},Md5.prototype.buffer=Md5.prototype.arrayBuffer,Md5.prototype.base64=function(){for(var t,e,n,r="",i=this.array(),s=0;s<15;)t=i[s++],e=i[s++],n=i[s++],r+=BASE64_ENCODE_CHAR[t>>>2]+BASE64_ENCODE_CHAR[63&(t<<4|e>>>4)]+BASE64_ENCODE_CHAR[63&(e<<2|n>>>6)]+BASE64_ENCODE_CHAR[63&n];return t=i[s],r+=BASE64_ENCODE_CHAR[t>>>2]+BASE64_ENCODE_CHAR[t<<4&63]+"=="};var exports=createMethod();COMMON_JS?module.exports=exports:(root.md5=exports,AMD&&(__WEBPACK_AMD_DEFINE_RESULT__=function(){return exports}.call(exports,__webpack_require__,exports,module),void 0===__WEBPACK_AMD_DEFINE_RESULT__||(module.exports=__WEBPACK_AMD_DEFINE_RESULT__)))})()}).call(this,__webpack_require__(35),__webpack_require__(8))},function(t,e){var n,r,i=t.exports={};function s(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(t){if(n===setTimeout)return setTimeout(t,0);if((n===s||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:s}catch(t){n=s}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(t){r=o}}();var c,u=[],l=!1,h=-1;function d(){l&&c&&(l=!1,c.length?u=c.concat(u):h=-1,u.length&&p())}function p(){if(!l){var t=a(d);l=!0;for(var e=u.length;e;){for(c=u,u=[];++h1)for(var n=1;n0&&(this._lastUpdateTime=t),this._count=Math.min(this._maxTokens,this._count+n),this._count>0&&(this._count--,!0)}}},function(t,e,n){(function(e){let n=e.fetch;t.exports={fetchWithTimeout:(t,e,r)=>{let i=null;const s=window.AbortController?new window.AbortController:null,o=s?s.signal:null;return Promise.race([n(t,Object.assign({signal:o},e)).then((t=>(clearTimeout(i),t)),(t=>{throw clearTimeout(i),t})),new Promise(((t,e)=>{i=setTimeout((()=>{s&&s.abort(),e(new Error("Fetch timed out after ".concat(r," ms")))}),r)}))])},setFetch:t=>{n=t}}}).call(this,n(8))},function(t,e,n){function r(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t,e,n){return(e=function(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}const s=n(17),{OrderedMap:o}=n(21),a=n(60),c=n(296),u=n(3),l=n(15),h=n(64),d=n(2),p=n(184),f=n(185),m=n(44),g=n(43),b=n(68),y=n(36),v=n(22),w=n(0),T=n(54),E=n(12),A=n(9),k=n(29),I=n(191),S=n(192),x=n(38),O=n(194),M=n(195),N=n(196),C=n(197),R=n(198),D=n(199),P=n(200),L=n(69),B=n(6),U=n(7),j={scratch3_control:n(201),scratch3_event:n(202),scratch3_looks:n(203),scratch3_motion:n(204),scratch3_operators:n(205),scratch3_sound:n(206),scratch3_sensing:n(207),scratch3_data:n(208),scratch3_procedures:n(209)},F=n(210),z=n(211),V=["#0FBD8C","#0DA57A","#0B8E69"],G=" // _twconfig_",Y=(()=>{const t={};return t[u.ANGLE]={shadow:{type:"math_angle",fieldName:"NUM"}},t[u.COLOR]={shadow:{type:"colour_picker",fieldName:"COLOUR"}},t[u.NUMBER]={shadow:{type:"math_number",fieldName:"NUM"}},t[u.STRING]={shadow:{type:"text",fieldName:"TEXT"}},t[u.BOOLEAN]={check:"Boolean"},t[u.MATRIX]={shadow:{type:"matrix",fieldName:"MATRIX"}},t[u.NOTE]={shadow:{type:"note",fieldName:"NOTE"}},t[u.IMAGE]={fieldType:"field_image"},t[u.COSTUME]={shadow:{type:"looks_costume",fieldName:"COSTUME"}},t[u.SOUND]={shadow:{type:"sound_sounds_menu",fieldName:"SOUND_MENU"}},t})(),H=t=>{let e=0;return{canAddCloudVariable:()=>e{e++},removeCloudVariable:()=>{e--},hasCloudVariables:()=>e>0,getNumberOfCloudVariables:()=>e}};let W=-1,K=-1,q=-1;class Q extends s{constructor(){super(),this.targets=[],this.executableTargets=[],this.threads=[],this.threadMap=new Map,this.sequencer=new f(this),this.flyoutBlocks=new l(this,!0),this.monitorBlocks=new l(this,!0),this._editingTarget=null,this._primitives={},this._blockInfo=[],this._hats={},this._flowing={},this._scriptGlowsPreviousFrame=[],this._nonMonitorThreadCount=0,this._lastStepDoneThreads=null,this._cloneCounter=0,this._refreshTargets=!1,this.monitorBlockInfo={},this._monitorState=o({}),this._prevMonitorState=o({}),this.turboMode=!1,this.frameLoop=new z(this),this.currentStepTime=1e3/30,this.updateCurrentMSecs(),this.redrawRequested=!1,this._registerBlockPackages(),this.ioDevices={clock:new M(this),cloud:new N(this),keyboard:new C(this),mouse:new R(this),mouseWheel:new D(this),userData:new P,video:new L(this)},this.peripheralExtensions={},this.profiler=null,this.cloudOptions={limit:10};const t=H(this.cloudOptions);this.hasCloudData=t.hasCloudVariables,this.canAddCloudVariable=t.canAddCloudVariable,this.getNumberOfCloudVariables=t.getNumberOfCloudVariables,this.addCloudVariable=this._initializeAddCloudVariable(t),this.removeCloudVariable=this._initializeRemoveCloudVariable(t),this.origin=null,this.platform=Object.assign({},O),this._initScratchLink(),this.resetRunId(),this._stageTarget=null,this.addonBlocks={},this.stageWidth=Q.STAGE_WIDTH,this.stageHeight=Q.STAGE_HEIGHT,this.runtimeOptions={maxClones:Q.MAX_CLONES,miscLimits:!0,fencing:!0},this.compilerOptions={enabled:!0,warpTimer:!1},this.debug=!1,this._lastStepTime=Date.now(),this.interpolationEnabled=!1,this._defaultStoredSettings=this._generateAllProjectOptions(),this.isPackaged=!1,this.externalCommunicationMethods={cloudVariables:!1,customExtensions:!1},this.on(Q.HAS_CLOUD_DATA_UPDATE,(t=>{this.setExternalCommunicationMethod("cloudVariables",t)})),this.enforcePrivacy=!0,this.extensionButtons=new Map,this.fontManager=new S(this),this.extensionStorage={},this.totalAssetRequests=0,this.finishedAssetRequests=0}static get STAGE_WIDTH(){return 480}static get STAGE_HEIGHT(){return 360}static get SCRIPT_GLOW_ON(){return"SCRIPT_GLOW_ON"}static get SCRIPT_GLOW_OFF(){return"SCRIPT_GLOW_OFF"}static get BLOCK_GLOW_ON(){return"BLOCK_GLOW_ON"}static get BLOCK_GLOW_OFF(){return"BLOCK_GLOW_OFF"}static get HAS_CLOUD_DATA_UPDATE(){return"HAS_CLOUD_DATA_UPDATE"}static get TURBO_MODE_ON(){return"TURBO_MODE_ON"}static get TURBO_MODE_OFF(){return"TURBO_MODE_OFF"}static get RUNTIME_OPTIONS_CHANGED(){return"RUNTIME_OPTIONS_CHANGED"}static get COMPILER_OPTIONS_CHANGED(){return"COMPILER_OPTIONS_CHANGED"}static get FRAMERATE_CHANGED(){return"FRAMERATE_CHANGED"}static get INTERPOLATION_CHANGED(){return"INTERPOLATION_CHANGED"}static get STAGE_SIZE_CHANGED(){return"STAGE_SIZE_CHANGED"}static get COMPILE_ERROR(){return"COMPILE_ERROR"}static get BEFORE_EXECUTE(){return"BEFORE_EXECUTE"}static get AFTER_EXECUTE(){return"AFTER_EXECUTE"}static get ASSET_PROGRESS(){return"ASSET_PROGRESS"}static get PROJECT_START(){return"PROJECT_START"}static get PROJECT_RUN_START(){return"PROJECT_RUN_START"}static get PROJECT_RUN_STOP(){return"PROJECT_RUN_STOP"}static get PROJECT_STOP_ALL(){return"PROJECT_STOP_ALL"}static get STOP_FOR_TARGET(){return"STOP_FOR_TARGET"}static get VISUAL_REPORT(){return"VISUAL_REPORT"}static get PROJECT_LOADED(){return"PROJECT_LOADED"}static get PROJECT_CHANGED(){return"PROJECT_CHANGED"}static get TOOLBOX_EXTENSIONS_NEED_UPDATE(){return"TOOLBOX_EXTENSIONS_NEED_UPDATE"}static get TARGETS_UPDATE(){return"TARGETS_UPDATE"}static get MONITORS_UPDATE(){return"MONITORS_UPDATE"}static get BLOCK_DRAG_UPDATE(){return"BLOCK_DRAG_UPDATE"}static get BLOCK_DRAG_END(){return"BLOCK_DRAG_END"}static get EXTENSION_ADDED(){return"EXTENSION_ADDED"}static get EXTENSION_FIELD_ADDED(){return"EXTENSION_FIELD_ADDED"}static get PERIPHERAL_LIST_UPDATE(){return"PERIPHERAL_LIST_UPDATE"}static get USER_PICKED_PERIPHERAL(){return"USER_PICKED_PERIPHERAL"}static get PERIPHERAL_CONNECTED(){return"PERIPHERAL_CONNECTED"}static get PERIPHERAL_DISCONNECTED(){return"PERIPHERAL_DISCONNECTED"}static get PERIPHERAL_REQUEST_ERROR(){return"PERIPHERAL_REQUEST_ERROR"}static get PERIPHERAL_CONNECTION_LOST_ERROR(){return"PERIPHERAL_CONNECTION_LOST_ERROR"}static get PERIPHERAL_SCAN_TIMEOUT(){return"PERIPHERAL_SCAN_TIMEOUT"}static get MIC_LISTENING(){return"MIC_LISTENING"}static get BLOCKSINFO_UPDATE(){return"BLOCKSINFO_UPDATE"}static get RUNTIME_STARTED(){return"RUNTIME_STARTED"}static get RUNTIME_STOPPED(){return"RUNTIME_STOPPED"}static get RUNTIME_DISPOSED(){return"RUNTIME_DISPOSED"}static get BLOCKS_NEED_UPDATE(){return"BLOCKS_NEED_UPDATE"}static get PLATFORM_MISMATCH(){return"PLATFORM_MISMATCH"}static get THREAD_STEP_INTERVAL(){return 1e3/60}static get THREAD_STEP_INTERVAL_COMPATIBILITY(){return 1e3/30}static get MAX_CLONES(){return 300}_initializeAddCloudVariable(t){return()=>{const e=this.hasCloudData();t.addCloudVariable(),!e&&this.hasCloudData()&&this.emit(Q.HAS_CLOUD_DATA_UPDATE,!0)}}_initializeRemoveCloudVariable(t){return()=>{const e=this.hasCloudData();t.removeCloudVariable(),e&&!this.hasCloudData()&&this.emit(Q.HAS_CLOUD_DATA_UPDATE,!1)}}_registerBlockPackages(){for(const t in j)if(Object.prototype.hasOwnProperty.call(j,t)){const e=new j[t](this);if(e.getPrimitives){const t=e.getPrimitives();for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(this._primitives[n]=t[n].bind(e))}if(e.getHats){const t=e.getHats();for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(this._hats[e]=t[e])}e.getMonitored&&(this.monitorBlockInfo=Object.assign({},this.monitorBlockInfo,e.getMonitored())),this.compilerRegisterExtension(t,e)}}compilerRegisterExtension(t,e){this["ext_".concat(t)]=e}getMonitorState(){return this._monitorState}_makeExtensionMenuId(t,e){return"".concat(e,"_menu_").concat(t)}makeMessageContextForTarget(t){const e={};(t=t||this.getEditingTarget()||this.getTargetForStage())&&(e.targetType=t.isStage?y.STAGE:y.SPRITE)}_registerExtensionPrimitives(t){const e={id:t.id,name:T(t.name),showStatusButton:t.showStatusButton,blockIconURI:t.blockIconURI,menuIconURI:t.menuIconURI};t.color1?(e.color1=t.color1,e.color2=t.color2,e.color3=t.color3):(e.color1=V[0],e.color2=V[1],e.color3=V[2]),this._blockInfo.push(e),this._fillExtensionCategory(e,t);for(const n in e.customFieldTypes)if(Object.prototype.hasOwnProperty.call(t.customFieldTypes,n)){const t=e.customFieldTypes[n];this.emit(Q.EXTENSION_FIELD_ADDED,{name:"field_".concat(t.extendedName),implementation:t.fieldImplementation})}this.emit(Q.EXTENSION_ADDED,e)}_refreshExtensionPrimitives(t){const e=this._blockInfo.find((e=>e.id===t.id));e&&(e.name=T(t.name),this._fillExtensionCategory(e,t),this.emit(Q.BLOCKSINFO_UPDATE,e))}_fillExtensionCategory(t,e){t.blocks=[],t.customFieldTypes={},t.menus=[],t.menuInfo={};for(const n in e.menus)if(Object.prototype.hasOwnProperty.call(e.menus,n)){const r=e.menus[n],i=this._buildMenuForScratchBlocks(n,r,t);t.menus.push(i),t.menuInfo[n]=r}for(const n in e.customFieldTypes)if(Object.prototype.hasOwnProperty.call(e.customFieldTypes,n)){const r=e.customFieldTypes[n],i=this._buildCustomFieldInfo(n,r,e.id,t);t.customFieldTypes[n]=i}if(e.docsURI){const n={info:{},xml:" ')};t.blocks.push(n)}for(const n of e.blocks)try{const e=this._convertForScratchBlocks(n,t);if(t.blocks.push(e),e.json){const t=e.json.type;n.blockType!==d.EVENT&&(this._primitives[t]=e.info.func),n.blockType===d.EVENT||n.blockType===d.HAT?this._hats[t]={edgeActivated:n.isEdgeActivated,restartExistingThreads:n.shouldRestartExistingThreads}:n.blockType===d.CONDITIONAL?this._flowing[t]={conditional:!0,loop:!1}:n.blockType===d.LOOP&&(this._flowing[t]={conditional:!1,loop:!0})}}catch(t){w.error("Error parsing block: ",{block:n,error:t})}}_convertMenuItems(t){if("function"!=typeof t){const e=this.makeMessageContextForTarget();return t.map((t=>{const n=T(t,e);switch(typeof n){case"string":return[n,n];case"object":return[T(t.text,e),t.value];default:throw new Error("Can't interpret menu item: ".concat(JSON.stringify(t)))}}))}return t}_buildMenuForScratchBlocks(t,e,n){const r=this._makeExtensionMenuId(t,n.id),i=this._convertMenuItems(e.items);return{json:{message0:"%1",type:r,inputsInline:!0,output:"String",colour:n.color1,colourSecondary:n.color2,colourTertiary:n.color3,outputShape:e.acceptReporters?b.OUTPUT_SHAPE_ROUND:b.OUTPUT_SHAPE_SQUARE,args0:[{type:"field_dropdown",name:t,options:i}]}}}_buildCustomFieldInfo(t,e,n,r){const i="".concat(n,"_").concat(t);return{fieldName:t,extendedName:i,argumentTypeInfo:{shadow:{type:i,fieldName:"field_".concat(i)}},scratchBlocksDefinition:this._buildCustomFieldTypeForScratchBlocks(i,e.output,e.outputShape,r),fieldImplementation:e.implementation}}_buildCustomFieldTypeForScratchBlocks(t,e,n,r){return{json:{type:t,message0:"%1",inputsInline:!0,output:e,colour:r.color1,colourSecondary:r.color2,colourTertiary:r.color3,outputShape:n,args0:[{name:"field_".concat(t),type:"field_".concat(t)}]}}}_convertForScratchBlocks(t,e){return"---"===t?this._convertSeparatorForScratchBlocks(t):t.blockType===d.LABEL?this._convertLabelForScratchBlocks(t):t.blockType===d.BUTTON?this._convertButtonForScratchBlocks(t,e):t.blockType===d.XML?this._convertXmlForScratchBlocks(t):this._convertBlockForScratchBlocks(t,e)}_convertBlockForScratchBlocks(t,e){var n,r,i;const s="".concat(e.id,"_").concat(t.opcode),o={type:s,inputsInline:!0,category:e.name,extensions:[],colour:null!==(n=t.color1)&&void 0!==n?n:e.color1,colourSecondary:null!==(r=t.color2)&&void 0!==r?r:e.color2,colourTertiary:null!==(i=t.color3)&&void 0!==i?i:e.color3},a={argsMap:{},blockJSON:o,categoryInfo:e,blockInfo:t,inputList:[]},c=t.blockIconURI||e.blockIconURI;if(o.extensions.push("from_extension"),o.colour===V[0]&&o.colourSecondary===V[1]&&o.colourTertiary===V[2]&&o.extensions.push("default_extension_colors"),c){o.extensions.push("scratch_extension"),o.message0="%1 %2";const t={type:"field_image",src:c,width:40,height:40},e={type:"field_vertical_separator"};o.args0=[t,e]}switch(t.blockType){case d.COMMAND:o.outputShape=b.OUTPUT_SHAPE_SQUARE,o.previousStatement=null,t.isTerminal||(o.nextStatement=null);break;case d.REPORTER:o.output=t.allowDropAnywhere?null:"String",o.outputShape=b.OUTPUT_SHAPE_ROUND;break;case d.BOOLEAN:o.output="Boolean",o.outputShape=b.OUTPUT_SHAPE_HEXAGONAL;break;case d.HAT:case d.EVENT:Object.prototype.hasOwnProperty.call(t,"isEdgeActivated")||(t.isEdgeActivated=!0),o.outputShape=b.OUTPUT_SHAPE_SQUARE,o.nextStatement=null;break;case d.CONDITIONAL:case d.LOOP:t.branchCount=t.branchCount||1,o.outputShape=b.OUTPUT_SHAPE_SQUARE,o.previousStatement=null,t.isTerminal||(o.nextStatement=null)}t.blockShape&&(o.outputShape=t.blockShape);const u=Array.isArray(t.text)?t.text:[t.text];let l=0,h=0,p=0;const f=this._convertPlaceholders.bind(this,a),m=this.makeMessageContextForTarget();for(;l0?h+1:"")}],++h,++p)}if(t.blockType===d.REPORTER||t.blockType===d.BOOLEAN)t.disableMonitor||0!==a.inputList.length||(o.checkboxInFlyout=!0);else if(t.branchIconURI||t.blockType===d.LOOP&&!Object.prototype.hasOwnProperty.call(t,"branchIconURI")){var g;o["lastDummyAlign".concat(p)]="RIGHT",o["message".concat(p)]="%1",o["args".concat(p)]=[{type:"field_image",src:null!==(g=t.branchIconURI)&&void 0!==g?g:"media://repeat.svg",width:24,height:24,alt:"*",flip_rtl:!0}],++p}const y=t.isDynamic?' '):"",v=a.inputList.join(""),w='').concat(y).concat(v," ");if(t.extensions)for(const e of t.extensions)o.extensions.includes(e)||o.extensions.push(e);return{info:a.blockInfo,json:a.blockJSON,xml:w}}_convertSeparatorForScratchBlocks(t){return{info:t,xml:' '}}_convertLabelForScratchBlocks(t){return{info:t,xml:' ')}}_convertButtonForScratchBlocks(t,e){const n=this.makeMessageContextForTarget(),r=T(t.text,n);if(["MAKE_A_LIST","MAKE_A_PROCEDURE","MAKE_A_VARIABLE"].includes(t.func))return{info:t,xml:' ')};const i="".concat(e.id,"_").concat(t.func);return this.extensionButtons.set(i,t.callFunc),{info:t,xml:' ')}}_convertXmlForScratchBlocks(t){return{info:t,xml:t.xml}}handleExtensionButtonPress(t){this.extensionButtons.get(t)()}_constructInlineImageJson(t){return t.dataURI||w.warn("Missing data URI in extension block with argument type IMAGE"),{type:"field_image",src:t.dataURI||"",width:24,height:24,flip_rtl:t.flipRTL||!1}}_convertPlaceholders(t,e,n){const r=t.blockInfo.arguments[n]||{};let i,s=Y[r.type]||{};if(!Y[r.type]&&t.categoryInfo.customFieldTypes[r.type]&&(s=t.categoryInfo.customFieldTypes[r.type].argumentTypeInfo),"field_image"===s.fieldType)i=this._constructInlineImageJson(r);else{i={type:"input_value",name:n};const e=void 0===r.defaultValue?null:T(r.defaultValue,this.makeMessageContextForTarget()).toString();let o,a,c;if(s.check&&(i.check=s.check),r.menu){const e=t.categoryInfo.menuInfo[r.menu];e.acceptReporters?(o=n,a=this._makeExtensionMenuId(r.menu,t.categoryInfo.id),c=r.menu):(i.type="field_dropdown",i.options=this._convertMenuItems(e.items),o=null,a=null,c=n)}else o=n,a=s.shadow&&s.shadow.type||null,c=s.shadow&&s.shadow.fieldName||null;o&&t.inputList.push('')),a&&t.inputList.push('')),null!==e&&c&&t.inputList.push('').concat(k(e)," ")),a&&t.inputList.push(" "),o&&t.inputList.push(" ")}const o="args".concat(t.outLineNum),a=t.blockJSON[o]=t.blockJSON[o]||[];i&&a.push(i);const c=a.length;return t.argsMap[n]=c,"%".concat(c)}getBlocksXML(t){return this._blockInfo.map((e=>{const{name:n,color1:r,color2:i}=e,s=e.blocks.filter((e=>{let n=!0;return t&&e.info.filter&&(n=e.info.filter.includes(t.isStage?y.STAGE:y.SPRITE)),n&&!e.info.hideFromPalette})),o='colour="'.concat(k(r),'" secondaryColour="').concat(k(i),'"');let a="";e.menuIconURI?a=e.menuIconURI:e.blockIconURI&&(a=e.blockIconURI);const c=a?'iconURI="'.concat(k(a),'"'):"";let u="";e.showStatusButton&&(u='showStatusButton="true"');let l='"),l+=s.map((t=>t.xml)).join(""),l+=" ",{id:e.id,xml:l}}))}getBlocksJSON(){return this._blockInfo.reduce(((t,e)=>t.concat(e.blocks.map((t=>t.json)))),[])}_initScratchLink(){if("undefined"!=typeof self&&"undefined"!=typeof document&&document.getElementById&&self.origin&&"null"!==self.origin&&self.navigator&&self.navigator.userAgent&&!self.navigator.userAgent.includes("Node.js")&&!self.navigator.userAgent.includes("jsdom")){if(!document.getElementById("scratch-link-extension-script")){const t=document.createElement("script");t.id="scratch-link-extension-script",document.body.appendChild(t),self.postMessage("inject-scratch-link-script",self.origin)}}}getScratchLinkSocket(t){return(this._linkSocketFactory||this._defaultScratchLinkSocketFactory)(t)}configureScratchLinkSocketFactory(t){this._linkSocketFactory=t}_defaultScratchLinkSocketFactory(t){const e=self.Scratch,n=e&&e.ScratchLinkSafariSocket;return n&&n.isSafariHelperCompatible()?new n(t):new I(t)}registerPeripheralExtension(t,e){this.peripheralExtensions[t]=e}scanForPeripheral(t){this.peripheralExtensions[t]&&this.peripheralExtensions[t].scan()}connectPeripheral(t,e){this.peripheralExtensions[t]&&this.peripheralExtensions[t].connect(e)}disconnectPeripheral(t){this.peripheralExtensions[t]&&this.peripheralExtensions[t].disconnect()}getPeripheralIsConnected(t){let e=!1;return this.peripheralExtensions[t]&&(e=this.peripheralExtensions[t].isConnected()),e}emitMicListening(t){this.emit(Q.MIC_LISTENING,t)}getOpcodeFunction(t){return this._primitives[t]}getIsHat(t){return Object.prototype.hasOwnProperty.call(this._hats,t)}getIsEdgeActivatedHat(t){return Object.prototype.hasOwnProperty.call(this._hats,t)&&this._hats[t].edgeActivated}attachAudioEngine(t){this.audioEngine=t}attachRenderer(t){this.renderer=t,this.renderer.setLayerGroupOrdering(E.LAYER_GROUPS),this.renderer.offscreenTouching=!this.runtimeOptions.fencing,this.updatePrivacy()}attachV2BitmapAdapter(t){this.v2BitmapAdapter=t}attachStorage(t){if(this.storage=t,this.isPackaged){const e=t.createAsset;let n=0;t.createAsset=function(t,r,i,s,o){return s||(s=(++n).toString()),e.call(this,t,r,i,s,!1)}}x.setFetch(t.scratchFetch.scratchFetch),this.resetRunId()}_pushThread(t,e,n){const r=new v(t);return r.target=e,r.stackClick=Boolean(n&&n.stackClick),r.updateMonitor=Boolean(n&&n.updateMonitor),r.blockContainer=r.updateMonitor?this.monitorBlocks:e.blocks,r.pushStack(t),this.threads.push(r),r.stackClick||r.updateMonitor||this.threadMap.set(r.getId(),r),n&&n.updateMonitor||!this.compilerOptions.enabled||r.tryCompile(),r}_stopThread(t){t.isKilled=!0,this.sequencer.retireThread(t)}_restartThread(t){const e=new v(t.topBlock);e.target=t.target,e.stackClick=t.stackClick,e.updateMonitor=t.updateMonitor,e.blockContainer=t.blockContainer,e.pushStack(t.topBlock),t.triedToCompile&&this.compilerOptions.enabled&&e.tryCompile(),e.stackClick||e.updateMonitor||this.threadMap.set(e.getId(),e);const n=this.threads.indexOf(t);return n>-1?(this.threads[n]=e,e):(this.threads.push(t),t)}emitCompileError(t,e){this.emit(Q.COMPILE_ERROR,t,e)}isActiveThread(t){return t.stack.length>0&&t.status!==v.STATUS_DONE&&this.threads.indexOf(t)>-1}isWaitingThread(t){return t.status===v.STATUS_PROMISE_WAIT||t.status===v.STATUS_YIELD_TICK||!this.isActiveThread(t)}toggleScript(t,e){e=Object.assign({target:this._editingTarget,stackClick:!1},e);for(let n=0;n=0;e--){const r=n[e],i=r.blocks.getScripts();for(let e=0;e=0;n--){const i=r[n],s=h.getScripts(i.blocks,t);for(let t=0;t{const{blockId:o,fieldsOfInputs:a}=t;for(const t in e)if(a[t].value!==e[t])return;if(i.restartExistingThreads){const t=this.threadMap.get(v.getIdFromTargetAndBlock(n,o));if(t)return void r.push(this._restartThread(t))}else for(let t=0;t{t.isCompiled?t.executableHat&&(g.saveGlobalState(),g(t),g.restoreGlobalState()):(m(this.sequencer,t),t.goToNextBlock())})),r}dispose(){this.stopAll(),this.targets.forEach((t=>{t.isOriginal&&t.deleteMonitors()})),this.targets.map(this.disposeTarget,this),this.extensionStorage={};const t=o({});t.equals(this._monitorState)||(this._monitorState=t,this.emit(Q.MONITORS_UPDATE,this._monitorState)),this.emit(Q.RUNTIME_DISPOSED),this.ioDevices.clock.resetProjectTimer(),this.fontManager.clear(),this.hasCloudData()&&this.emit(Q.HAS_CLOUD_DATA_UPDATE,!1),this.ioDevices.cloud.clear();const e=H(this.cloudOptions);this.hasCloudData=e.hasCloudVariables,this.canAddCloudVariable=e.canAddCloudVariable,this.getNumberOfCloudVariables=e.getNumberOfCloudVariables,this.addCloudVariable=this._initializeAddCloudVariable(e),this.removeCloudVariable=this._initializeRemoveCloudVariable(e),this.resetProgress()}addTarget(t){this.targets.push(t),this.executableTargets.push(t),t.isStage&&!this._stageTarget&&(this._stageTarget=t)}moveExecutable(t,e){const n=this.executableTargets.indexOf(t);this.executableTargets.splice(n,1);let r=n+e;return r>this.executableTargets.length&&(r=this.executableTargets.length),r<=0&&(r=this.executableTargets.length>0&&this.executableTargets[0].isStage?1:0),this.executableTargets.splice(r,0,t),r}setExecutablePosition(t,e){const n=this.executableTargets.indexOf(t);return this.moveExecutable(t,e-n)}removeExecutable(t){const e=this.executableTargets.indexOf(t);e>-1&&this.executableTargets.splice(e,1)}disposeTarget(t){this.targets=this.targets.filter((e=>t!==e||(e.dispose(),!1))),this._stageTarget===t&&(this._stageTarget=null)}stopForTarget(t,e){this.emit(Q.STOP_FOR_TARGET,t,e);for(let n=0;nt.clearEdgeActivatedValues()));for(let t=0;t!t.isKilled)),this.updateThreadMap();for(const t in this._hats){if(!Object.prototype.hasOwnProperty.call(this._hats,t))continue;this._hats[t].edgeActivated&&this.startHats(t)}this.redrawRequested=!1,this._pushMonitors(),null!==this.profiler&&(-1===K&&(K=this.profiler.idByName("Sequencer.stepThreads")),this.profiler.start(K)),this.emit(Q.BEFORE_EXECUTE);const t=this.sequencer.stepThreads();null!==this.profiler&&this.profiler.stop(),this.emit(Q.AFTER_EXECUTE),this._updateGlows(t),this._emitProjectRunStatus(this.threads.length+t.length-this._getMonitorThreadCount([...this.threads,...t])),this._lastStepDoneThreads=t,this.renderer&&(null!==this.profiler&&(-1===q&&(q=this.profiler.idByName("RenderWebGL.draw")),this.profiler.start(q)),document.hidden||this.frameLoop._interpolationAnimation||this.renderer.draw(),null!==this.profiler&&this.profiler.stop()),this._refreshTargets&&(this.emit(Q.TARGETS_UPDATE,!1),this._refreshTargets=!1),this._prevMonitorState.equals(this._monitorState)||(this.emit(Q.MONITORS_UPDATE,this._monitorState),this._prevMonitorState=this._monitorState),null!==this.profiler&&(this.profiler.stop(),this.profiler.reportFrames()),this.interpolationEnabled&&(this._lastStepTime=Date.now())}_getMonitorThreadCount(t){let e=0;return t.forEach((t=>{t.updateMonitor&&e++})),e}_pushMonitors(){this.monitorBlocks.runAllMonitored(this)}setEditingTarget(t){const e=this._editingTarget;this._editingTarget=t,this._scriptGlowsPreviousFrame=[],this._updateGlows(),e!==this._editingTarget&&this.requestToolboxExtensionsUpdate()}setCompatibilityMode(t){t?this.setFramerate(30):this.setFramerate(60)}setFramerate(t){t>250&&(t=250),t<0&&(t=1),this.frameLoop.setFramerate(t),this.emit(Q.FRAMERATE_CHANGED,t)}setInterpolation(t){this.interpolationEnabled=t,this.frameLoop.setInterpolation(this.interpolationEnabled),this.emit(Q.INTERPOLATION_CHANGED,t)}setRuntimeOptions(t){this.runtimeOptions=Object.assign({},this.runtimeOptions,t),this.emit(Q.RUNTIME_OPTIONS_CHANGED,this.runtimeOptions),this.renderer&&(this.renderer.offscreenTouching=!this.runtimeOptions.fencing)}setCompilerOptions(t){this.compilerOptions=Object.assign({},this.compilerOptions,t),this.resetAllCaches(),this.emit(Q.COMPILER_OPTIONS_CHANGED,this.compilerOptions)}setStageSize(t,e){if(t=Math.round(Math.max(1,t)),e=Math.round(Math.max(1,e)),this.stageWidth!==t||this.stageHeight!==e){const n=t-this.stageWidth,r=e-this.stageHeight;if(this._monitorState.size>0){const t=n/2,e=r/2;for(const n of this._monitorState.valueSeq()){const r=n.set("x",n.get("x")+t).set("y",n.get("y")+e);this.requestUpdateMonitor(r)}this.emit(Q.MONITORS_UPDATE,this._monitorState)}this.stageWidth=t,this.stageHeight=e,this.renderer&&this.renderer.setStageSize(-t/2,t/2,-e/2,e/2),this.emit(Q.STAGE_SIZE_CHANGED,t,e)}}setInEditor(t){}convertToPackagedRuntime(){if(this.storage)throw new Error("convertToPackagedRuntime must be called before attachStorage");this.isPackaged=!0}resetAllCaches(){for(const t of this.targets)t.isOriginal&&t.blocks.resetCache();this.flyoutBlocks.resetCache(),this.monitorBlocks.resetCache()}addAddonBlock(t){const e=t.procedureCode,n=t.arguments||[],s=n,o=n.map(((t,e)=>"arg".concat(e))),a=n.map((()=>""));if(this.addonBlocks[e]=function(t){for(var e=1;et.id===n));if(!r){const t=' ';r={id:n,name:T({id:"tw.blocks.addons",default:"Addons",description:"Name of the addon block category in the extension list"}),color1:"#29beb8",color2:"#3aa8a4",color3:"#3aa8a4",menuIconURI:"data:image/svg+xml;,".concat(encodeURIComponent(t)),blocks:[],customFieldTypes:{},menus:[]},this._blockInfo.unshift(r)}r.blocks.push({info:{},xml:' "})}this.resetAllCaches()}getAddonBlock(t){return Object.prototype.hasOwnProperty.call(this.addonBlocks,t)?this.addonBlocks[t]:null}findProjectOptionsComment(){const t=this.getTargetForStage().comments;for(const e of Object.values(t))if(e.text.includes(G))return e;return null}parseProjectOptions(){const t=this.findProjectOptionsComment();if(!t)return;const e=t.text.split("\n").find((t=>t.endsWith(G)));if(!e)return void w.warn("Config comment does not contain valid line");const n=e.substr(0,e.length-14);let r;try{if(r=a.parse(n),!r||"object"!=typeof r)throw new Error("Invalid object")}catch(t){return void w.warn("Config comment has invalid JSON",t)}"number"==typeof r.framerate&&this.setFramerate(r.framerate),r.turbo&&(this.turboMode=!0,this.emit(Q.TURBO_MODE_ON)),r.interpolation&&this.setInterpolation(!0),r.runtimeOptions&&this.setRuntimeOptions(r.runtimeOptions),r.hq&&this.renderer&&this.renderer.setUseHighQualityRender(!0);const i=+r.width||this.stageWidth,s=+r.height||this.stageHeight;i===this.stageWidth&&s===this.stageHeight||this.setStageSize(i,s)}_generateAllProjectOptions(){return{framerate:this.frameLoop.framerate,runtimeOptions:this.runtimeOptions,interpolation:this.interpolationEnabled,turbo:this.turboMode,hq:!!this.renderer&&this.renderer.useHighQualityRender,width:this.stageWidth,height:this.stageHeight}}generateDifferingProjectOptions(){const t=(e,n)=>{const r={};for(const i of Object.keys(n)){const s=n[i],o=e[i];if("object"==typeof s&&s){const e=t(o,s);Object.keys(e).length>0&&(r[i]=e)}else s!==o&&(r[i]=s)}return r};return t(this._defaultStoredSettings,this._generateAllProjectOptions())}storeProjectOptions(){const t=this.generateDifferingProjectOptions(),e="Configuration for https://turbowarp.org/\nYou can move, resize, and minimize this comment, but don't edit it by hand. This comment can be deleted to remove the stored settings.\n".concat(a.stringify(t)).concat(G),n=this.findProjectOptionsComment();if(n)n.text=e;else{this.getTargetForStage().createComment(U(),null,e,50,50,350,170,!1)}this.emitProjectChanged()}precompile(){this.allScriptsDo(((t,e)=>{const n=e.blocks.getBlock(t);if(this.getIsHat(n.opcode)){const n=new v(t);n.target=e,n.blockContainer=e.blocks,n.tryCompile()}}))}enableDebug(){this.resetAllCaches(),this.debug=!0}_updateGlows(t){const e=[];e.push(...this.threads),t&&e.push(...t);const n=[],r=[];for(let t=0;t0&&this.emit(Q.PROJECT_RUN_START),this._nonMonitorThreadCount>0&&0===t&&this.emit(Q.PROJECT_RUN_STOP),this._nonMonitorThreadCount=t}quietGlow(t){const e=this._scriptGlowsPreviousFrame.indexOf(t);e>-1&&this._scriptGlowsPreviousFrame.splice(e,1)}glowBlock(t,e){e?this.emit(Q.BLOCK_GLOW_ON,{id:t}):this.emit(Q.BLOCK_GLOW_OFF,{id:t})}glowScript(t,e){e?this.emit(Q.SCRIPT_GLOW_ON,{id:t}):this.emit(Q.SCRIPT_GLOW_OFF,{id:t})}emitBlockDragUpdate(t){this.emit(Q.BLOCK_DRAG_UPDATE,t)}emitBlockEndDrag(t,e){this.emit(Q.BLOCK_DRAG_END,t,e)}visualReport(t,e,n){t===this.getEditingTarget()&&this.emit(Q.VISUAL_REPORT,{id:e,value:String(n)})}requestAddMonitor(t){const e=t.get("id");this.requestUpdateMonitor(t)||(this._monitorState=this._monitorState.set(e,t))}requestUpdateMonitor(t){const e=t.get("id");return!!this._monitorState.has(e)&&(this._monitorState=this._monitorState.set(e,this._monitorState.get(e).mergeWith(((t,e)=>null==e?t:e),t)),!0)}requestRemoveMonitor(t){this._monitorState=this._monitorState.delete(t)}requestHideMonitor(t){return this.requestUpdateMonitor(new Map([["id",t],["visible",!1]]))}requestShowMonitor(t){return this.requestUpdateMonitor(new Map([["id",t],["visible",!0]]))}requestRemoveMonitorByTargetId(t){this._monitorState=this._monitorState.filterNot((e=>e.targetId===t))}getTargetById(t){for(let e=0;et.id===e));if(!r)return;const i=r.blocks.find((t=>t.info.opcode===n));return i?{category:"extension",label:"".concat(r.name,": ").concat(i.info.text)}:void 0}createNewGlobalVariable(t,e,n){const r="string"==typeof n?n:A.SCALAR_TYPE,i=this.getAllVarNamesOfType(r),s=B.unusedName(t,i),o=new A(e||U(),s,r);return this.getTargetForStage().variables[o.id]=o,o}requestRedraw(){this.redrawRequested=!0}requestTargetsUpdate(t){t.isOriginal&&(this._refreshTargets=!0)}requestBlocksUpdate(){this.emit(Q.BLOCKS_NEED_UPDATE)}requestToolboxExtensionsUpdate(){this.emit(Q.TOOLBOX_EXTENSIONS_NEED_UPDATE)}start(){this.frameLoop.running||(this.frameLoop.start(),this.emit(Q.RUNTIME_STARTED))}stop(){this.quit()}quit(){this.frameLoop.running&&(this.frameLoop.stop(),this.emit(Q.RUNTIME_STOPPED))}enableProfiling(t){p.available()&&(this.profiler=new p(t))}disableProfiling(){this.profiler=null}updateCurrentMSecs(){this.currentMSecs=Date.now()}updatePrivacy(){const t=this.enforcePrivacy&&Object.values(this.externalCommunicationMethods).some((t=>t));this.renderer&&this.renderer.setPrivateSkinAccess&&this.renderer.setPrivateSkinAccess(!t)}setEnforcePrivacy(t){this.enforcePrivacy=t,this.updatePrivacy()}setExternalCommunicationMethod(t,e){if(!Object.prototype.hasOwnProperty.call(this.externalCommunicationMethods,t))throw new Error("Unknown method: ".concat(t));this.externalCommunicationMethods[t]=e,this.updatePrivacy()}emitAssetProgress(){this.emit(Q.ASSET_PROGRESS,this.finishedAssetRequests,this.totalAssetRequests)}resetProgress(){this.finishedAssetRequests=0,this.totalAssetRequests=0,this.emitAssetProgress()}wrapAssetRequest(t){this.totalAssetRequests++,this.emitAssetProgress();return t().then((t=>(this.finishedAssetRequests++,this.emitAssetProgress(),t)),(t=>{throw this.finishedAssetRequests++,this.emitAssetProgress(),t}))}}t.exports=Q},function(t,e,n){const{Record:r}=n(21),i=r({id:null,spriteName:null,targetId:null,opcode:null,value:null,params:null,mode:"default",sliderMin:0,sliderMax:100,isDiscrete:!0,x:null,y:null,width:0,height:0,visible:!0});t.exports=i},function(t,e){t.exports=function(t,e){let n="";for(const t in e){let r=e[t].value;"CURRENTMENU"===t&&(r=r.toLowerCase()),n+="_".concat(r)}return"".concat(t).concat(n)}},function(t,e,n){const r=n(1),i=n(6),s=n(2),o=n(9),a=n(0),{IntermediateScript:c,IntermediateRepresentation:u}=n(65),l=n(187),h="",d="list",p=t=>t.substring(1);class f{constructor(t){this.thread=t,this.target=t.target,this.blocks=t.blockContainer,this.runtime=this.target.runtime,this.stage=this.runtime.getTargetForStage(),this.script=new c,this.script.warpTimer=this.target.runtime.compilerOptions.warpTimer,this.variableCache={},this.usesTimer=!1}setProcedureVariant(t){const e=p(t);this.script.procedureVariant=t,this.script.procedureCode=e,this.script.isProcedure=!0,this.script.yields=!1;const n=this.blocks.getProcedureParamNamesIdsAndDefaults(e);if(null===n)throw new Error("IR: cannot find procedure: ".concat(t));const[r,i,s]=n;this.script.arguments=r}enableWarp(){this.script.isWarp=!0}getBlockById(t){return this.blocks.getBlock(t)||this.blocks.runtime.flyoutBlocks.getBlock(t)}getBlockInfo(t){const[e,n]=i.splitFirst(t,"_");if(!e||!n)return null;const r=this.runtime._blockInfo.find((t=>t.id===e));if(!r)return null;const s=r.blocks.find((t=>t.info.opcode===n));return s||null}descendInputOfBlock(t,e){const n=t.inputs[e];if(!n)return a.warn("IR: ".concat(t.opcode,": missing input ").concat(e),t),{kind:"constant",value:0};const r=n.block,i=this.getBlockById(r);return i?this.descendInput(i):(a.warn("IR: ".concat(t.opcode,": could not find input ").concat(e," with ID ").concat(r)),{kind:"constant",value:0})}descendInput(t){switch(t.opcode){case"colour_picker":return{kind:"constant",value:t.fields.COLOUR.value};case"math_angle":case"math_integer":case"math_number":case"math_positive_number":case"math_whole_number":return{kind:"constant",value:t.fields.NUM.value};case"text":return{kind:"constant",value:t.fields.TEXT.value};case"argument_reporter_string_number":{const e=t.fields.VALUE.value,n=this.script.arguments.lastIndexOf(e);return-1===n&&"last key pressed"===e.toLowerCase()?{kind:"tw.lastKeyPressed"}:-1===n?{kind:"constant",value:0}:{kind:"procedures.argument",index:n}}case"argument_reporter_boolean":{const e=t.fields.VALUE.value,n=this.script.arguments.lastIndexOf(e);return-1===n?"is compiled?"===e.toLowerCase()||"is turbowarp?"===e.toLowerCase()?{kind:"constant",value:!0}:{kind:"constant",value:0}:{kind:"procedures.argument",index:n}}case"control_get_counter":return{kind:"counter.get"};case"data_variable":return{kind:"var.get",variable:this.descendVariable(t,"VARIABLE",h)};case"data_itemoflist":return{kind:"list.get",list:this.descendVariable(t,"LIST",d),index:this.descendInputOfBlock(t,"INDEX")};case"data_lengthoflist":return{kind:"list.length",list:this.descendVariable(t,"LIST",d)};case"data_listcontainsitem":return{kind:"list.contains",list:this.descendVariable(t,"LIST",d),item:this.descendInputOfBlock(t,"ITEM")};case"data_itemnumoflist":return{kind:"list.indexOf",list:this.descendVariable(t,"LIST",d),item:this.descendInputOfBlock(t,"ITEM")};case"data_listcontents":return{kind:"list.contents",list:this.descendVariable(t,"LIST",d)};case"event_broadcast_menu":{const e=t.fields.BROADCAST_OPTION,n=this.target.lookupBroadcastMsg(e.id,e.value);return{kind:"constant",value:n?n.name:""}}case"looks_backdropnumbername":return"number"===t.fields.NUMBER_NAME.value?{kind:"looks.backdropNumber"}:{kind:"looks.backdropName"};case"looks_costumenumbername":return"number"===t.fields.NUMBER_NAME.value?{kind:"looks.costumeNumber"}:{kind:"looks.costumeName"};case"looks_size":return{kind:"looks.size"};case"motion_direction":return{kind:"motion.direction"};case"motion_xposition":return{kind:"motion.x"};case"motion_yposition":return{kind:"motion.y"};case"operator_add":return{kind:"op.add",left:this.descendInputOfBlock(t,"NUM1"),right:this.descendInputOfBlock(t,"NUM2")};case"operator_and":return{kind:"op.and",left:this.descendInputOfBlock(t,"OPERAND1"),right:this.descendInputOfBlock(t,"OPERAND2")};case"operator_contains":return{kind:"op.contains",string:this.descendInputOfBlock(t,"STRING1"),contains:this.descendInputOfBlock(t,"STRING2")};case"operator_divide":return{kind:"op.divide",left:this.descendInputOfBlock(t,"NUM1"),right:this.descendInputOfBlock(t,"NUM2")};case"operator_equals":return{kind:"op.equals",left:this.descendInputOfBlock(t,"OPERAND1"),right:this.descendInputOfBlock(t,"OPERAND2")};case"operator_gt":return{kind:"op.greater",left:this.descendInputOfBlock(t,"OPERAND1"),right:this.descendInputOfBlock(t,"OPERAND2")};case"operator_join":return{kind:"op.join",left:this.descendInputOfBlock(t,"STRING1"),right:this.descendInputOfBlock(t,"STRING2")};case"operator_length":return{kind:"op.length",string:this.descendInputOfBlock(t,"STRING")};case"operator_letter_of":return{kind:"op.letterOf",letter:this.descendInputOfBlock(t,"LETTER"),string:this.descendInputOfBlock(t,"STRING")};case"operator_lt":return{kind:"op.less",left:this.descendInputOfBlock(t,"OPERAND1"),right:this.descendInputOfBlock(t,"OPERAND2")};case"operator_mathop":{const e=this.descendInputOfBlock(t,"NUM");switch(t.fields.OPERATOR.value.toLowerCase()){case"abs":return{kind:"op.abs",value:e};case"floor":return{kind:"op.floor",value:e};case"ceiling":return{kind:"op.ceiling",value:e};case"sqrt":return{kind:"op.sqrt",value:e};case"sin":return{kind:"op.sin",value:e};case"cos":return{kind:"op.cos",value:e};case"tan":return{kind:"op.tan",value:e};case"asin":return{kind:"op.asin",value:e};case"acos":return{kind:"op.acos",value:e};case"atan":return{kind:"op.atan",value:e};case"ln":return{kind:"op.ln",value:e};case"log":return{kind:"op.log",value:e};case"e ^":return{kind:"op.e^",value:e};case"10 ^":return{kind:"op.10^",value:e};default:return{kind:"constant",value:0}}}case"operator_mod":return{kind:"op.mod",left:this.descendInputOfBlock(t,"NUM1"),right:this.descendInputOfBlock(t,"NUM2")};case"operator_multiply":return{kind:"op.multiply",left:this.descendInputOfBlock(t,"NUM1"),right:this.descendInputOfBlock(t,"NUM2")};case"operator_not":return{kind:"op.not",operand:this.descendInputOfBlock(t,"OPERAND")};case"operator_or":return{kind:"op.or",left:this.descendInputOfBlock(t,"OPERAND1"),right:this.descendInputOfBlock(t,"OPERAND2")};case"operator_random":{const e=this.descendInputOfBlock(t,"FROM"),n=this.descendInputOfBlock(t,"TO");if("constant"===e.kind&&"constant"===n.kind){const t=e.value,i=n.value,s=r.toNumber(t),o=r.toNumber(i);return s===o?{kind:"constant",value:s}:r.isInt(t)&&r.isInt(i)?{kind:"op.random",low:s<=o?e:n,high:s<=o?n:e,useInts:!0,useFloats:!1}:{kind:"op.random",low:s<=o?e:n,high:s<=o?n:e,useInts:!1,useFloats:!0}}if("constant"===e.kind){if(!r.isInt(r.toNumber(e.value)))return{kind:"op.random",low:e,high:n,useInts:!1,useFloats:!0}}else if("constant"===n.kind&&!r.isInt(r.toNumber(n.value)))return{kind:"op.random",low:e,high:n,useInts:!1,useFloats:!0};return{kind:"op.random",low:e,high:n,useInts:!1,useFloats:!1}}case"operator_round":return{kind:"op.round",value:this.descendInputOfBlock(t,"NUM")};case"operator_subtract":return{kind:"op.subtract",left:this.descendInputOfBlock(t,"NUM1"),right:this.descendInputOfBlock(t,"NUM2")};case"procedures_call":return this.descendProcedure(t);case"sensing_answer":return{kind:"sensing.answer"};case"sensing_coloristouchingcolor":return{kind:"sensing.colorTouchingColor",target:this.descendInputOfBlock(t,"COLOR2"),mask:this.descendInputOfBlock(t,"COLOR")};case"sensing_current":switch(t.fields.CURRENTMENU.value.toLowerCase()){case"year":return{kind:"sensing.year"};case"month":return{kind:"sensing.month"};case"date":return{kind:"sensing.date"};case"dayofweek":return{kind:"sensing.dayofweek"};case"hour":return{kind:"sensing.hour"};case"minute":return{kind:"sensing.minute"};case"second":return{kind:"sensing.second"}}return{kind:"constant",value:0};case"sensing_dayssince2000":return{kind:"sensing.daysSince2000"};case"sensing_distanceto":return{kind:"sensing.distance",target:this.descendInputOfBlock(t,"DISTANCETOMENU")};case"sensing_keypressed":return{kind:"keyboard.pressed",key:this.descendInputOfBlock(t,"KEY_OPTION")};case"sensing_mousedown":return{kind:"mouse.down"};case"sensing_mousex":return{kind:"mouse.x"};case"sensing_mousey":return{kind:"mouse.y"};case"sensing_of":return{kind:"sensing.of",property:t.fields.PROPERTY.value,object:this.descendInputOfBlock(t,"OBJECT")};case"sensing_timer":return this.usesTimer=!0,{kind:"timer.get"};case"sensing_touchingcolor":return{kind:"sensing.touchingColor",color:this.descendInputOfBlock(t,"COLOR")};case"sensing_touchingobject":return{kind:"sensing.touching",object:this.descendInputOfBlock(t,"TOUCHINGOBJECTMENU")};case"sensing_username":return{kind:"sensing.username"};case"sound_sounds_menu":return{kind:"constant",value:t.fields.SOUND_MENU.value};case"tw_getLastKeyPressed":return{kind:"tw.lastKeyPressed"};default:{if(this.runtime.getOpcodeFunction(t.opcode)){if(l.inputs.includes(t.opcode))return this.descendCompatLayer(t);const e=this.getBlockInfo(t.opcode);if(e){const n=e.info.blockType;if(n===s.REPORTER||n===s.BOOLEAN)return this.descendCompatLayer(t)}}const e=Object.keys(t.inputs),n=Object.keys(t.fields);if(0===e.length&&1===n.length)return{kind:"constant",value:t.fields[n[0]].value};throw a.warn("IR: Unknown input: ".concat(t.opcode),t),new Error("IR: Unknown input: ".concat(t.opcode))}}}descendStackedBlock(t){switch(t.opcode){case"control_all_at_once":return{kind:"control.if",condition:{kind:"constant",value:!0},whenTrue:this.descendSubstack(t,"SUBSTACK"),whenFalse:[]};case"control_clear_counter":return{kind:"counter.clear"};case"control_create_clone_of":return{kind:"control.createClone",target:this.descendInputOfBlock(t,"CLONE_OPTION")};case"control_delete_this_clone":return this.script.yields=!0,{kind:"control.deleteClone"};case"control_forever":return this.analyzeLoop(),{kind:"control.while",condition:{kind:"constant",value:!0},do:this.descendSubstack(t,"SUBSTACK")};case"control_for_each":return this.analyzeLoop(),{kind:"control.for",variable:this.descendVariable(t,"VARIABLE",h),count:this.descendInputOfBlock(t,"VALUE"),do:this.descendSubstack(t,"SUBSTACK")};case"control_if":return{kind:"control.if",condition:this.descendInputOfBlock(t,"CONDITION"),whenTrue:this.descendSubstack(t,"SUBSTACK"),whenFalse:[]};case"control_if_else":return{kind:"control.if",condition:this.descendInputOfBlock(t,"CONDITION"),whenTrue:this.descendSubstack(t,"SUBSTACK"),whenFalse:this.descendSubstack(t,"SUBSTACK2")};case"control_incr_counter":return{kind:"counter.increment"};case"control_repeat":return this.analyzeLoop(),{kind:"control.repeat",times:this.descendInputOfBlock(t,"TIMES"),do:this.descendSubstack(t,"SUBSTACK")};case"control_repeat_until":{this.analyzeLoop(),this.usesTimer=!1;const e=this.descendInputOfBlock(t,"CONDITION"),n=this.usesTimer;return n&&(this.script.yields=!0),{kind:"control.while",condition:{kind:"op.not",operand:e},do:this.descendSubstack(t,"SUBSTACK"),warpTimer:n}}case"control_stop":{const e=t.fields.STOP_OPTION.value;return"all"===e?(this.script.yields=!0,{kind:"control.stopAll"}):"other scripts in sprite"===e||"other scripts in stage"===e?{kind:"control.stopOthers"}:"this script"===e?{kind:"control.stopScript"}:{kind:"noop"}}case"control_wait":return this.script.yields=!0,{kind:"control.wait",seconds:this.descendInputOfBlock(t,"DURATION")};case"control_wait_until":return this.script.yields=!0,{kind:"control.waitUntil",condition:this.descendInputOfBlock(t,"CONDITION")};case"control_while":return this.analyzeLoop(),{kind:"control.while",condition:this.descendInputOfBlock(t,"CONDITION"),do:this.descendSubstack(t,"SUBSTACK"),warpTimer:!1};case"data_addtolist":return{kind:"list.add",list:this.descendVariable(t,"LIST",d),item:this.descendInputOfBlock(t,"ITEM")};case"data_changevariableby":{const e=this.descendVariable(t,"VARIABLE",h);return{kind:"var.set",variable:e,value:{kind:"op.add",left:{kind:"var.get",variable:e},right:this.descendInputOfBlock(t,"VALUE")}}}case"data_deletealloflist":return{kind:"list.deleteAll",list:this.descendVariable(t,"LIST",d)};case"data_deleteoflist":{const e=this.descendInputOfBlock(t,"INDEX");return"constant"===e.kind&&"all"===e.value?{kind:"list.deleteAll",list:this.descendVariable(t,"LIST",d)}:{kind:"list.delete",list:this.descendVariable(t,"LIST",d),index:e}}case"data_hidelist":return{kind:"list.hide",list:this.descendVariable(t,"LIST",d)};case"data_hidevariable":return{kind:"var.hide",variable:this.descendVariable(t,"VARIABLE",h)};case"data_insertatlist":return{kind:"list.insert",list:this.descendVariable(t,"LIST",d),index:this.descendInputOfBlock(t,"INDEX"),item:this.descendInputOfBlock(t,"ITEM")};case"data_replaceitemoflist":return{kind:"list.replace",list:this.descendVariable(t,"LIST",d),index:this.descendInputOfBlock(t,"INDEX"),item:this.descendInputOfBlock(t,"ITEM")};case"data_setvariableto":return{kind:"var.set",variable:this.descendVariable(t,"VARIABLE",h),value:this.descendInputOfBlock(t,"VALUE")};case"data_showlist":return{kind:"list.show",list:this.descendVariable(t,"LIST",d)};case"data_showvariable":return{kind:"var.show",variable:this.descendVariable(t,"VARIABLE",h)};case"event_broadcast":return{kind:"event.broadcast",broadcast:this.descendInputOfBlock(t,"BROADCAST_INPUT")};case"event_broadcastandwait":return this.script.yields=!0,{kind:"event.broadcastAndWait",broadcast:this.descendInputOfBlock(t,"BROADCAST_INPUT")};case"looks_changeeffectby":return{kind:"looks.changeEffect",effect:t.fields.EFFECT.value.toLowerCase(),value:this.descendInputOfBlock(t,"CHANGE")};case"looks_changesizeby":return{kind:"looks.changeSize",size:this.descendInputOfBlock(t,"CHANGE")};case"looks_cleargraphiceffects":return{kind:"looks.clearEffects"};case"looks_goforwardbackwardlayers":return"forward"===t.fields.FORWARD_BACKWARD.value?{kind:"looks.forwardLayers",layers:this.descendInputOfBlock(t,"NUM")}:{kind:"looks.backwardLayers",layers:this.descendInputOfBlock(t,"NUM")};case"looks_gotofrontback":return"front"===t.fields.FRONT_BACK.value?{kind:"looks.goToFront"}:{kind:"looks.goToBack"};case"looks_hide":return{kind:"looks.hide"};case"looks_nextbackdrop":return{kind:"looks.nextBackdrop"};case"looks_nextcostume":return{kind:"looks.nextCostume"};case"looks_seteffectto":return{kind:"looks.setEffect",effect:t.fields.EFFECT.value.toLowerCase(),value:this.descendInputOfBlock(t,"VALUE")};case"looks_setsizeto":return{kind:"looks.setSize",size:this.descendInputOfBlock(t,"SIZE")};case"looks_show":return{kind:"looks.show"};case"looks_switchbackdropto":return{kind:"looks.switchBackdrop",backdrop:this.descendInputOfBlock(t,"BACKDROP")};case"looks_switchcostumeto":return{kind:"looks.switchCostume",costume:this.descendInputOfBlock(t,"COSTUME")};case"motion_changexby":return{kind:"motion.changeX",dx:this.descendInputOfBlock(t,"DX")};case"motion_changeyby":return{kind:"motion.changeY",dy:this.descendInputOfBlock(t,"DY")};case"motion_gotoxy":return{kind:"motion.setXY",x:this.descendInputOfBlock(t,"X"),y:this.descendInputOfBlock(t,"Y")};case"motion_ifonedgebounce":return{kind:"motion.ifOnEdgeBounce"};case"motion_movesteps":return{kind:"motion.step",steps:this.descendInputOfBlock(t,"STEPS")};case"motion_pointindirection":return{kind:"motion.setDirection",direction:this.descendInputOfBlock(t,"DIRECTION")};case"motion_setrotationstyle":return{kind:"motion.setRotationStyle",style:t.fields.STYLE.value};case"motion_setx":return{kind:"motion.setX",x:this.descendInputOfBlock(t,"X")};case"motion_sety":return{kind:"motion.setY",y:this.descendInputOfBlock(t,"Y")};case"motion_turnleft":return{kind:"motion.setDirection",direction:{kind:"op.subtract",left:{kind:"motion.direction"},right:this.descendInputOfBlock(t,"DEGREES")}};case"motion_turnright":return{kind:"motion.setDirection",direction:{kind:"op.add",left:{kind:"motion.direction"},right:this.descendInputOfBlock(t,"DEGREES")}};case"pen_clear":return{kind:"pen.clear"};case"pen_changePenColorParamBy":return{kind:"pen.changeParam",param:this.descendInputOfBlock(t,"COLOR_PARAM"),value:this.descendInputOfBlock(t,"VALUE")};case"pen_changePenHueBy":return{kind:"pen.legacyChangeHue",hue:this.descendInputOfBlock(t,"HUE")};case"pen_changePenShadeBy":return{kind:"pen.legacyChangeShade",shade:this.descendInputOfBlock(t,"SHADE")};case"pen_penDown":return{kind:"pen.down"};case"pen_penUp":return{kind:"pen.up"};case"pen_setPenColorParamTo":return{kind:"pen.setParam",param:this.descendInputOfBlock(t,"COLOR_PARAM"),value:this.descendInputOfBlock(t,"VALUE")};case"pen_setPenColorToColor":return{kind:"pen.setColor",color:this.descendInputOfBlock(t,"COLOR")};case"pen_setPenHueToNumber":return{kind:"pen.legacySetHue",hue:this.descendInputOfBlock(t,"HUE")};case"pen_setPenShadeToNumber":return{kind:"pen.legacySetShade",shade:this.descendInputOfBlock(t,"SHADE")};case"pen_setPenSizeTo":return{kind:"pen.setSize",size:this.descendInputOfBlock(t,"SIZE")};case"pen_changePenSizeBy":return{kind:"pen.changeSize",size:this.descendInputOfBlock(t,"SIZE")};case"pen_stamp":return{kind:"pen.stamp"};case"procedures_call":{const e=t.mutation.proccode;if(t.mutation.return){const e=this.descendVisualReport(t);if(e)return e}return"tw:debugger;"===e?{kind:"tw.debugger"}:this.descendProcedure(t)}case"procedures_return":return{kind:"procedures.return",value:this.descendInputOfBlock(t,"VALUE")};case"sensing_resettimer":return{kind:"timer.reset"};default:{if(this.runtime.getOpcodeFunction(t.opcode)){if(l.stacked.includes(t.opcode))return this.descendCompatLayer(t);const e=this.getBlockInfo(t.opcode);if(e){const n=e.info.blockType;if(n===s.COMMAND||n===s.CONDITIONAL||n===s.LOOP)return this.descendCompatLayer(t)}}const e=this.descendVisualReport(t);if(e)return e;throw a.warn("IR: Unknown stacked block: ".concat(t.opcode),t),new Error("IR: Unknown stacked block: ".concat(t.opcode))}}}descendSubstack(t,e){const n=t.inputs[e];if(!n)return[];const r=n.block;return this.walkStack(r)}walkStack(t){const e=[];let n=t;for(;null!==n;){const t=this.getBlockById(n);if(!t)break;const r=this.descendStackedBlock(t);e.push(r),n=t.next}return e}descendVariable(t,e,n){const r=t.fields[e],i=r.id;if(i&&Object.prototype.hasOwnProperty.call(this.variableCache,i))return this.variableCache[i];const s=this._descendVariable(i,r.value,n);return this.variableCache[s.id]=s,s}_descendVariable(t,e,n){const r=this.target,i=this.stage;if(Object.prototype.hasOwnProperty.call(r.variables,t)){const e=r.variables[t];return{scope:"target",id:e.id,name:e.name,isCloud:e.isCloud}}if(!r.isStage&&i&&Object.prototype.hasOwnProperty.call(i.variables,t)){const e=i.variables[t];return{scope:"stage",id:e.id,name:e.name,isCloud:e.isCloud}}for(const t in r.variables)if(Object.prototype.hasOwnProperty.call(r.variables,t)){const i=r.variables[t];if(i.name===e&&i.type===n)return{scope:"target",id:i.id,name:i.name,isCloud:i.isCloud}}if(!r.isStage&&i)for(const t in i.variables)if(Object.prototype.hasOwnProperty.call(i.variables,t)){const r=i.variables[t];if(r.name===e&&r.type===n)return{scope:"stage",id:r.id,name:r.name,isCloud:r.isCloud}}const s=new o(t,e,n,!1);if(r.variables[t]=s,r.sprite)for(const i of r.sprite.clones)Object.prototype.hasOwnProperty.call(i.variables,t)||(i.variables[t]=new o(t,e,n,!1));return{scope:"target",id:t,name:s.name,isCloud:s.isCloud}}descendProcedure(t){const e=t.mutation.proccode,n=this.blocks.getProcedureParamNamesIdsAndDefaults(e);if(null===n)return{kind:"noop"};const[r,i,s]=n;if(this.runtime.getAddonBlock(e)){this.script.yields=!0;const n={};for(let e=0;e0;){this.compilingProcedures=this.proceduresToCompile,this.proceduresToCompile=new Map;for(const[t,n]of this.compilingProcedures.entries())if(e[t]){const n=e[t];this.procedures[t]=n,this.addProcedureDependencies(n.dependedProcedures)}else{const r="W"===t.charAt(0),i=new f(this.thread);i.setProcedureVariant(t),r&&i.enableWarp();const s=this.generateScriptTree(i,n);this.procedures[t]=s,e[t]=s}}for(;this.analyzeScript(t););const n=new u;return n.entry=t,n.procedures=this.procedures,n}}}},function(t,e,n){const r={Timer:n(13),Cast:n(1),log:n(0),blockUtility:n(189),thread:null};let i="";const s={};i+="let stuckCounter = 0;\nconst isStuck = () => {\n // The real time is not checked on every call for performance.\n stuckCounter++;\n if (stuckCounter === 100) {\n stuckCounter = 0;\n return globalState.thread.target.runtime.sequencer.timer.timeElapsed() > 500;\n }\n return false;\n};",s.startHats="const startHats = (requestedHat, optMatchFields) => {\n const thread = globalState.thread;\n const threads = thread.target.runtime.startHats(requestedHat, optMatchFields);\n return threads;\n}",s.waitThreads="const waitThreads = function*(threads) {\n const thread = globalState.thread;\n const runtime = thread.target.runtime;\n\n while (true) {\n // determine whether any threads are running\n let anyRunning = false;\n for (let i = 0; i < threads.length; i++) {\n if (runtime.threads.indexOf(threads[i]) !== -1) {\n anyRunning = true;\n break;\n }\n }\n if (!anyRunning) {\n // all threads are finished, can resume\n return;\n }\n\n let allWaiting = true;\n for (let i = 0; i < threads.length; i++) {\n if (!runtime.isWaitingThread(threads[i])) {\n allWaiting = false;\n break;\n }\n }\n if (allWaiting) {\n thread.status = 3; // STATUS_YIELD_TICK\n }\n\n yield;\n }\n}",s.executeInCompatibilityLayer="let hasResumedFromPromise = false;\nconst waitPromise = function*(promise) {\n const thread = globalState.thread;\n let returnValue;\n\n // enter STATUS_PROMISE_WAIT and yield\n // this will stop script execution until the promise handlers reset the thread status\n // because promise handlers might execute immediately, configure thread.status here\n thread.status = 1; // STATUS_PROMISE_WAIT\n\n promise\n .then(value => {\n returnValue = value;\n thread.status = 0; // STATUS_RUNNING\n }, error => {\n globalState.log.warn('Promise rejected in compiled script:', error);\n returnValue = '' + error;\n thread.status = 0; // STATUS_RUNNING\n });\n\n yield;\n\n return returnValue;\n};\nconst isPromise = value => (\n // see engine/execute.js\n value !== null &&\n typeof value === 'object' &&\n typeof value.then === 'function'\n);\nconst executeInCompatibilityLayer = function*(inputs, blockFunction, isWarp, useFlags, blockId, branchInfo) {\n const thread = globalState.thread;\n const blockUtility = globalState.blockUtility;\n const stackFrame = branchInfo ? branchInfo.stackFrame : {};\n\n const finish = (returnValue) => {\n if (branchInfo) {\n if (typeof returnValue === 'undefined' && blockUtility._startedBranch) {\n branchInfo.isLoop = blockUtility._startedBranch[1];\n return blockUtility._startedBranch[0];\n }\n branchInfo.isLoop = branchInfo.defaultIsLoop;\n return returnValue;\n }\n return returnValue;\n };\n\n const executeBlock = () => {\n blockUtility.init(thread, blockId, stackFrame);\n return blockFunction(inputs, blockUtility);\n };\n\n let returnValue = executeBlock();\n if (isPromise(returnValue)) {\n returnValue = finish(yield* waitPromise(returnValue));\n if (useFlags) hasResumedFromPromise = true;\n return returnValue;\n }\n\n if (thread.status === 1 /* STATUS_PROMISE_WAIT */ || thread.status === 4 /* STATUS_DONE */) {\n // Something external is forcing us to stop\n yield;\n // Make up a return value because whatever is forcing us to stop can't specify one\n return '';\n }\n\n while (thread.status === 2 /* STATUS_YIELD */ || thread.status === 3 /* STATUS_YIELD_TICK */) {\n // Yielded threads will run next iteration.\n if (thread.status === 2 /* STATUS_YIELD */) {\n thread.status = 0; // STATUS_RUNNING\n // Yield back to the event loop when stuck or not in warp mode.\n if (!isWarp || isStuck()) {\n yield;\n }\n } else {\n // status is STATUS_YIELD_TICK, always yield to the event loop\n yield;\n }\n\n returnValue = executeBlock();\n if (isPromise(returnValue)) {\n returnValue = finish(yield* waitPromise(returnValue));\n if (useFlags) hasResumedFromPromise = true;\n return returnValue;\n }\n\n if (thread.status === 1 /* STATUS_PROMISE_WAIT */ || thread.status === 4 /* STATUS_DONE */) {\n yield;\n return finish('');\n }\n }\n\n return finish(returnValue);\n}",s.createBranchInfo="const createBranchInfo = (isLoop) => ({\n defaultIsLoop: isLoop,\n isLoop: false,\n branch: 0,\n stackFrame: {}\n});",s.retire="const retire = () => {\n const thread = globalState.thread;\n thread.target.runtime.sequencer.retireThread(thread);\n}",s.toBoolean="const toBoolean = value => {\n if (typeof value === 'boolean') {\n return value;\n }\n if (typeof value === 'string') {\n if (value === '' || value === '0' || value.toLowerCase() === 'false') {\n return false;\n }\n return true;\n }\n return !!value;\n}",s.limitPrecision="const limitPrecision = value => {\n const rounded = Math.round(value);\n const delta = value - rounded;\n return (Math.abs(delta) < 1e-9) ? rounded : value;\n}",i+="const isNotActuallyZero = val => {\n if (typeof val !== 'string') return false;\n for (let i = 0; i < val.length; i++) {\n const code = val.charCodeAt(i);\n if (code === 48 || code === 9) {\n return false;\n }\n }\n return true;\n};",i+="const compareEqualSlow = (v1, v2) => {\n const n1 = +v1;\n if (isNaN(n1) || (n1 === 0 && isNotActuallyZero(v1))) return ('' + v1).toLowerCase() === ('' + v2).toLowerCase();\n const n2 = +v2;\n if (isNaN(n2) || (n2 === 0 && isNotActuallyZero(v2))) return ('' + v1).toLowerCase() === ('' + v2).toLowerCase();\n return n1 === n2;\n};\nconst compareEqual = (v1, v2) => (typeof v1 === 'number' && typeof v2 === 'number' && !isNaN(v1) && !isNaN(v2) || v1 === v2) ? v1 === v2 : compareEqualSlow(v1, v2);",s.compareGreaterThan="const compareGreaterThanSlow = (v1, v2) => {\n let n1 = +v1;\n let n2 = +v2;\n if (n1 === 0 && isNotActuallyZero(v1)) {\n n1 = NaN;\n } else if (n2 === 0 && isNotActuallyZero(v2)) {\n n2 = NaN;\n }\n if (isNaN(n1) || isNaN(n2)) {\n const s1 = ('' + v1).toLowerCase();\n const s2 = ('' + v2).toLowerCase();\n return s1 > s2;\n }\n return n1 > n2;\n};\nconst compareGreaterThan = (v1, v2) => typeof v1 === 'number' && typeof v2 === 'number' && !isNaN(v1) ? v1 > v2 : compareGreaterThanSlow(v1, v2)",s.compareLessThan="const compareLessThanSlow = (v1, v2) => {\n let n1 = +v1;\n let n2 = +v2;\n if (n1 === 0 && isNotActuallyZero(v1)) {\n n1 = NaN;\n } else if (n2 === 0 && isNotActuallyZero(v2)) {\n n2 = NaN;\n }\n if (isNaN(n1) || isNaN(n2)) {\n const s1 = ('' + v1).toLowerCase();\n const s2 = ('' + v2).toLowerCase();\n return s1 < s2;\n }\n return n1 < n2;\n};\nconst compareLessThan = (v1, v2) => typeof v1 === 'number' && typeof v2 === 'number' && !isNaN(v2) ? v1 < v2 : compareLessThanSlow(v1, v2)",s.randomInt="const randomInt = (low, high) => low + Math.floor(Math.random() * ((high + 1) - low))",s.randomFloat="const randomFloat = (low, high) => (Math.random() * (high - low)) + low",s.timer="const timer = () => {\n const t = new globalState.Timer({\n now: () => globalState.thread.target.runtime.currentMSecs\n });\n t.start();\n return t;\n}",s.daysSince2000="const daysSince2000 = () => (Date.now() - 946684800000) / (24 * 60 * 60 * 1000)",s.distance="const distance = menu => {\n const thread = globalState.thread;\n if (thread.target.isStage) return 10000;\n\n let targetX = 0;\n let targetY = 0;\n if (menu === '_mouse_') {\n targetX = thread.target.runtime.ioDevices.mouse.getScratchX();\n targetY = thread.target.runtime.ioDevices.mouse.getScratchY();\n } else {\n const distTarget = thread.target.runtime.getSpriteTargetByName(menu);\n if (!distTarget) return 10000;\n targetX = distTarget.x;\n targetY = distTarget.y;\n }\n\n const dx = thread.target.x - targetX;\n const dy = thread.target.y - targetY;\n return Math.sqrt((dx * dx) + (dy * dy));\n}",i+="const listIndexSlow = (index, length) => {\n if (index === 'last') {\n return length - 1;\n } else if (index === 'random' || index === 'any') {\n if (length > 0) {\n return (Math.random() * length) | 0;\n }\n return -1;\n }\n index = (+index || 0) | 0;\n if (index < 1 || index > length) {\n return -1;\n }\n return index - 1;\n};\nconst listIndex = (index, length) => {\n if (typeof index !== 'number') {\n return listIndexSlow(index, length);\n }\n index = index | 0;\n return index < 1 || index > length ? -1 : index - 1;\n};",s.listGet="const listGet = (list, idx) => {\n const index = listIndex(idx, list.length);\n if (index === -1) {\n return '';\n }\n return list[index];\n}",s.listReplace="const listReplace = (list, idx, value) => {\n const index = listIndex(idx, list.value.length);\n if (index === -1) {\n return;\n }\n list.value[index] = value;\n list._monitorUpToDate = false;\n}",s.listInsert="const listInsert = (list, idx, value) => {\n const index = listIndex(idx, list.value.length + 1);\n if (index === -1) {\n return;\n }\n list.value.splice(index, 0, value);\n list._monitorUpToDate = false;\n}",s.listDelete="const listDelete = (list, idx) => {\n if (idx === 'all') {\n list.value = [];\n return;\n }\n const index = listIndex(idx, list.value.length);\n if (index === -1) {\n return;\n }\n list.value.splice(index, 1);\n list._monitorUpToDate = false;\n}",s.listContains="const listContains = (list, item) => {\n // TODO: evaluate whether indexOf is worthwhile here\n if (list.value.indexOf(item) !== -1) {\n return true;\n }\n for (let i = 0; i < list.value.length; i++) {\n if (compareEqual(list.value[i], item)) {\n return true;\n }\n }\n return false;\n}",s.listIndexOf="const listIndexOf = (list, item) => {\n for (let i = 0; i < list.value.length; i++) {\n if (compareEqual(list.value[i], item)) {\n return i + 1;\n }\n }\n return 0;\n}",s.listContents="const listContents = list => {\n for (let i = 0; i < list.value.length; i++) {\n const listItem = list.value[i];\n // this is an intentional break from what scratch 3 does to address our automatic string -> number conversions\n // it fixes more than it breaks\n if ((listItem + '').length !== 1) {\n return list.value.join(' ');\n }\n }\n return list.value.join('');\n}",s.colorToList="const colorToList = color => globalState.Cast.toRgbColorList(color)",s.mod="const mod = (n, modulus) => {\n let result = n % modulus;\n if (result / modulus < 0) result += modulus;\n return result;\n}",s.tan="const tan = (angle) => {\n switch (angle % 360) {\n case -270: case 90: return Infinity;\n case -90: case 270: return -Infinity;\n }\n return Math.round(Math.tan((Math.PI * angle) / 180) * 1e10) / 1e10;\n}",s.yieldThenCall="const yieldThenCall = function* (callback, ...args) {\n yield;\n return callback(...args);\n}",s.yieldThenCallGenerator="const yieldThenCallGenerator = function* (callback, ...args) {\n yield;\n return yield* callback(...args);\n}";const o=t=>{r.thread=t,t.generator.next()},a=[];o.scopedEval=t=>{const e=(t=>{let e="let stuckCounter = 0;\nconst isStuck = () => {\n // The real time is not checked on every call for performance.\n stuckCounter++;\n if (stuckCounter === 100) {\n stuckCounter = 0;\n return globalState.thread.target.runtime.sequencer.timer.timeElapsed() > 500;\n }\n return false;\n};const isNotActuallyZero = val => {\n if (typeof val !== 'string') return false;\n for (let i = 0; i < val.length; i++) {\n const code = val.charCodeAt(i);\n if (code === 48 || code === 9) {\n return false;\n }\n }\n return true;\n};const compareEqualSlow = (v1, v2) => {\n const n1 = +v1;\n if (isNaN(n1) || (n1 === 0 && isNotActuallyZero(v1))) return ('' + v1).toLowerCase() === ('' + v2).toLowerCase();\n const n2 = +v2;\n if (isNaN(n2) || (n2 === 0 && isNotActuallyZero(v2))) return ('' + v1).toLowerCase() === ('' + v2).toLowerCase();\n return n1 === n2;\n};\nconst compareEqual = (v1, v2) => (typeof v1 === 'number' && typeof v2 === 'number' && !isNaN(v1) && !isNaN(v2) || v1 === v2) ? v1 === v2 : compareEqualSlow(v1, v2);const listIndexSlow = (index, length) => {\n if (index === 'last') {\n return length - 1;\n } else if (index === 'random' || index === 'any') {\n if (length > 0) {\n return (Math.random() * length) | 0;\n }\n return -1;\n }\n index = (+index || 0) | 0;\n if (index < 1 || index > length) {\n return -1;\n }\n return index - 1;\n};\nconst listIndex = (index, length) => {\n if (typeof index !== 'number') {\n return listIndexSlow(index, length);\n }\n index = index | 0;\n return index < 1 || index > length ? -1 : index - 1;\n};";for(const n of Object.keys(s))t.includes(n)&&(e+="".concat(s[n],";"));return e+="return ".concat(t),e})(t);try{return new Function("globalState",e)(r)}catch(t){throw r.log.error("was unable to compile script",e),t}},o.runtimeFunctions=s,o.saveGlobalState=()=>{a.push(r.thread)},o.restoreGlobalState=()=>{r.thread=a.pop()},t.exports=o},function(t,e,n){const r=n(67),i=n(63),s=n(0),o=n(22),{Map:a}=n(21),c=n(1),u=new r;let l=-1;const h=function(t,e,n,r,i){const s=r.id,u=r.opcode,l=r._isHat,h=r._isConditional,d=r._isLoop;if(n.pushReportedValue(t),l)if(n.stackClick)n.status=o.STATUS_RUNNING;else if(e.runtime.getIsEdgeActivatedHat(u)){const r=n.target.hasEdgeActivatedValue(s),i=n.target.updateEdgeActivatedValue(s,t);(r?!i&&t:t)?n.status=o.STATUS_RUNNING:e.retireThread(n)}else t?n.status=o.STATUS_RUNNING:e.retireThread(n);else if((h||d)&&void 0!==t)e.stepToBranch(n,c.toNumber(t),d);else{if(i&&void 0!==t&&n.atStackTop()&&(n.stackClick&&e.runtime.visualReport(n.target,s,t),n.updateMonitor)){const n=e.runtime.monitorBlocks.getBlock(s).targetId;if(n&&!e.runtime.getTargetById(n))return;e.runtime.requestUpdateMonitor(a({id:s,spriteName:n?e.runtime.getTargetById(n).getName():null,value:t}))}n.status=o.STATUS_RUNNING}},d=(t,e,n,r,i)=>{if(h(t,e,n,r,i),i&&(!r._isHat||n.stackClick)){let t,e;do{const r=n.popStack();if(null===r)return;if(e=n.target.blocks.getNextBlock(r),null!==e)break;t=n.peekStackFrame()}while(null!==t&&!t.isLoop);n.pushStack(e)}},p=(t,e,n,r,i)=>{n.status===o.STATUS_RUNNING&&(n.status=o.STATUS_PROMISE_WAIT),t.then((t=>{d(t,e,n,r,i)}),(t=>{s.warn("Primitive rejected promise: ",t),d("".concat(t),e,n,r,i)}))};class f{constructor(t,e){this.id=e.id,this.opcode=e.opcode,this.fields=e.fields,this.inputs=e.inputs,this.mutation=e.mutation,this._profiler=null,this._profilerFrame=null,this._isHat=!1,this._blockFunction=null,this._definedBlockFunction=!1,this._isShadowBlock=!1,this._shadowValue=null,this._fields=Object.assign({},this.fields),this._inputs=Object.assign({},this.inputs),this._argValues={mutation:this.mutation},this._parentKey=null,this._parentValues=null,this._ops=[];const{runtime:n}=u.sequencer,{opcode:r,fields:s,inputs:o}=this;this._isHat=n.getIsHat(r),this._blockFunction=n.getOpcodeFunction(r),this._definedBlockFunction=void 0!==this._blockFunction;const a=n._flowing[r];this._isConditional=!(!a||!a.conditional),this._isLoop=!(!a||!a.loop);const c=Object.keys(s);this._isShadowBlock=!this._definedBlockFunction&&1===c.length&&0===Object.keys(o).length,this._shadowValue=this._isShadowBlock&&s[c[0]].value;for(const t in s)this._argValues[t]="VARIABLE"===t||"LIST"===t||"BROADCAST_OPTION"===t?{id:s[t].id,name:s[t].value}:s[t].value;if(delete this._inputs.custom_block,"BROADCAST_INPUT"in this._inputs){this._argValues.BROADCAST_OPTION={id:null,name:null};const e=this._inputs.BROADCAST_INPUT;if(e.block===e.shadow){const n=t.getBlock(e.shadow).fields.BROADCAST_OPTION;this._argValues.BROADCAST_OPTION.id=n.id,this._argValues.BROADCAST_OPTION.name=n.value,delete this._inputs.BROADCAST_INPUT}}for(const e in this._inputs){const n=this._inputs[e];if(n.block){const r=i.getCached(t,n.block,f);if(r._isHat)continue;this._ops.push(...r._ops),r._parentKey=e,r._parentValues=this._argValues,r._isShadowBlock&&(this._argValues[e]=r._shadowValue)}}this._definedBlockFunction&&this._ops.push(this)}}t.exports=function(t,e){const n=t.runtime;u.sequencer=t,u.thread=e;const r=e.peekStack(),s=e.peekStackFrame();let a=e.blockContainer,d=i.getCached(a,r,f);if(null===d&&(a=n.flyoutBlocks,d=i.getCached(a,r,f),null===d))return void t.retireThread(e);const m=d._ops,g=m.length;let b=0;if(null!==s.reported){const t=s.reported;for(;bt.id===e));if(r){const t=r._parentKey,e=r._parentValues;"BROADCAST_INPUT"===t?(e.BROADCAST_OPTION.id=null,e.BROADCAST_OPTION.name=c.toString(n)):e[t]=n}}if(t.length>0){const e=t.reverse().find((t=>m.find((e=>e.id===t.opCached))));b=e?m.findIndex((t=>t.id===e.opCached))+1:0}if(null!==e.justReported&&m[b]&&m[b].id===s.reporting){const t=m[b],n=e.justReported;e.justReported=null;const r=t._parentKey,i=t._parentValues;"BROADCAST_INPUT"===r?(i.BROADCAST_OPTION.id=null,i.BROADCAST_OPTION.name=c.toString(n)):i[r]=n,b+=1}s.reporting=null,s.reported=null,s.waitingReporter=!1}const y=b;for(;b{const e=t._parentKey,n=t._parentValues;return"BROADCAST_INPUT"===e?{opCached:t.id,inputValue:n[e].BROADCAST_OPTION.name}:{opCached:t.id,inputValue:n[e]}}));break}if(e.status===o.STATUS_RUNNING)if(n)h(d,t,e,r,n);else{const t=r._parentKey,e=r._parentValues;"BROADCAST_INPUT"===t?(e.BROADCAST_OPTION.id=null,e.BROADCAST_OPTION.name=c.toString(d)):e[t]=d}else if(e.status===o.STATUS_DONE)break}var v;if(null!==n.profiler){d._profiler!==n.profiler&&function(t,e){e._profiler=t,-1===l&&(l=t.idByName("blockFunction"));const n=e._ops;for(let e=0;et.play(this,e)};return Object.defineProperty(this,"audioPlayer",{configurable:!1,enumerable:!0,writable:!1,value:e}),e}initAudio(){}static get ROTATION_STYLE_ALL_AROUND(){return"all around"}static get ROTATION_STYLE_LEFT_RIGHT(){return"left-right"}static get ROTATION_STYLE_NONE(){return"don't rotate"}static get VIDEO_STATE(){return{OFF:"off",ON:"on",ON_FLIPPED:"on-flipped"}}emitVisualChange(){this.onTargetVisualChange&&this.onTargetVisualChange(this)}setXY(t,e,n){if(this.isStage)return;if(this.dragging&&!n)return;const r=this.x,i=this.y;if(this.renderer){const n=this.runtime.runtimeOptions.fencing?this.renderer.getFencedPositionOfDrawable(this.drawableID,[t,e]):[t,e];this.x=n[0],this.y=n[1],this.renderer.updateDrawablePosition(this.drawableID,n),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}else this.x=t,this.y=e;this.onTargetMoved&&this.onTargetMoved(this,r,i,n),this.runtime.requestTargetsUpdate(this)}_getRenderedDirectionAndScale(){let t=this.direction,e=[this.size,this.size];if(this.rotationStyle===u.ROTATION_STYLE_NONE)t=90;else if(this.rotationStyle===u.ROTATION_STYLE_LEFT_RIGHT){t=90;e=[(this.direction<0?-1:1)*this.size,this.size]}return{direction:t,scale:e}}setDirection(t){if(!this.isStage&&isFinite(t)){if(this.direction=r.wrapClamp(t,-179,180),this.renderer){const{direction:t,scale:e}=this._getRenderedDirectionAndScale();this.renderer.updateDrawableDirectionScale(this.drawableID,t,e),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}this.runtime.requestTargetsUpdate(this)}}setDraggable(t){this.isStage||(this.draggable=!!t,this.runtime.requestTargetsUpdate(this))}setVisible(t){this.isStage||(this.visible=!!t,this.renderer&&(this.renderer.updateDrawableVisible(this.drawableID,this.visible),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())),this.runtime.requestTargetsUpdate(this))}setSize(t){if(!this.isStage){if(this.renderer){const e=this.renderer.getCurrentSkinSize(this.drawableID),n=e[0],i=e[1],s=this.runtime.runtimeOptions.fencing,o=s?Math.min(1,Math.max(5/n,5/i)):0,a=s?Math.min(1.5*this.runtime.stageWidth/n,1.5*this.runtime.stageHeight/i):1/0;this.size=100*r.clamp(t/100,o,a);const{direction:c,scale:u}=this._getRenderedDirectionAndScale();this.renderer.updateDrawableDirectionScale(this.drawableID,c,u),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}else this.size=t;this.runtime.requestTargetsUpdate(this)}}setEffect(t,e){Object.prototype.hasOwnProperty.call(this.effects,t)&&(this.effects[t]=e,this.renderer&&(this.renderer.updateDrawableEffect(this.drawableID,t,e),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())))}clearEffects(){for(const t in this.effects)Object.prototype.hasOwnProperty.call(this.effects,t)&&(this.effects[t]=0);if(this.renderer){for(const t in this.effects)Object.prototype.hasOwnProperty.call(this.effects,t)&&this.renderer.updateDrawableEffect(this.drawableID,t,0);this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}}setCostume(t){if((t=Math.round(t))!==1/0&&t!==-1/0&&t||(t=0),this.currentCostume=r.wrapClamp(t,0,this.sprite.costumes.length-1),this.renderer){const t=this.sprite.costumes[this.currentCostume];this.renderer.updateDrawableSkinId(this.drawableID,t.skinId),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}this.runtime.requestTargetsUpdate(this)}addCostume(t,e){"number"!=typeof e||isNaN(e)?this.sprite.addCostumeAt(t,this.sprite.costumes.length):this.sprite.addCostumeAt(t,e)}renameCostume(t,e){const n=this.sprite.costumes.filter(((e,n)=>t!==n)).map((t=>t.name)),r=this.getCostumes()[t].name,s=i.unusedName(e,n);if(this.getCostumes()[t].name=s,this.isStage){const t=this.runtime.targets;for(let e=0;e=e)return null;const n=this.sprite.deleteCostumeAt(t);return t===this.currentCostume&&t===e-1?this.setCostume(t-1):tt.name));t.name=i.unusedName(t.name,n),"number"!=typeof e||isNaN(e)?this.sprite.sounds.push(t):this.sprite.sounds.splice(e,0,t)}renameSound(t,e){const n=this.sprite.sounds.filter(((e,n)=>t!==n)).map((t=>t.name)),r=this.sprite.sounds[t].name,s=i.unusedName(e,n);this.sprite.sounds[t].name=s,this.blocks.updateAssetName(r,s,"sound")}deleteSound(t){if(t<0||t>=this.sprite.sounds.length)return null;const e=this.sprite.sounds.splice(t,1)[0];return this.runtime.requestTargetsUpdate(this),e}setRotationStyle(t){if(t===u.ROTATION_STYLE_NONE?this.rotationStyle=u.ROTATION_STYLE_NONE:t===u.ROTATION_STYLE_ALL_AROUND?this.rotationStyle=u.ROTATION_STYLE_ALL_AROUND:t===u.ROTATION_STYLE_LEFT_RIGHT&&(this.rotationStyle=u.ROTATION_STYLE_LEFT_RIGHT),this.renderer){const{direction:t,scale:e}=this._getRenderedDirectionAndScale();this.renderer.updateDrawableDirectionScale(this.drawableID,t,e),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw())}this.runtime.requestTargetsUpdate(this)}getCostumeIndexByName(t){const e=this.getCostumes();for(let n=0;nt/2||n.top>e/2||n.bottom<-e/2)return!0}return!1}isTouchingSprite(t){t=s.toString(t);const e=this.runtime.getSpriteTargetByName(t);if(!e||!this.renderer)return!1;const n=e.sprite.clones.filter((t=>!t.dragging)).map((t=>t.drawableID));return this.renderer.isTouchingDrawables(this.drawableID,n)}isTouchingColor(t){return!!this.renderer&&this.renderer.isTouchingColor(this.drawableID,t)}colorIsTouchingColor(t,e){return!!this.renderer&&this.renderer.isTouchingColor(this.drawableID,t,e)}getLayerOrder(){return this.renderer?this.renderer.getDrawableOrder(this.drawableID):null}goToFront(){this.renderer&&this.renderer.setDrawableOrder(this.drawableID,1/0,c.SPRITE_LAYER),this.runtime.setExecutablePosition(this,1/0)}goToBack(){this.renderer&&this.renderer.setDrawableOrder(this.drawableID,-1/0,c.SPRITE_LAYER,!1),this.runtime.setExecutablePosition(this,-1/0)}goForwardLayers(t){this.renderer&&this.renderer.setDrawableOrder(this.drawableID,t,c.SPRITE_LAYER,!0),this.runtime.moveExecutable(this,t)}goBackwardLayers(t){this.renderer&&this.renderer.setDrawableOrder(this.drawableID,-t,c.SPRITE_LAYER,!0),this.runtime.moveExecutable(this,-t)}goBehindOther(t){if(this.renderer){const e=this.renderer.setDrawableOrder(t.drawableID,0,c.SPRITE_LAYER,!0);this.renderer.setDrawableOrder(this.drawableID,e,c.SPRITE_LAYER)}const e=this.runtime.executableTargets.indexOf(t);this.runtime.setExecutablePosition(this,e)}keepInFence(t,e,n){let r=n;r||(r={left:-this.runtime.stageWidth/2,right:this.runtime.stageWidth/2,top:this.runtime.stageHeight/2,bottom:-this.runtime.stageHeight/2});const i=this.getBounds();if(!i)return;i.left+=t-this.x,i.right+=t-this.x,i.top+=e-this.y,i.bottom+=e-this.y;let s=0,o=0;return i.leftr.right&&(s+=r.right-i.right),i.top>r.top&&(o+=r.top-i.top),i.bottom{const e=t.createClone();return e.x=400*(Math.random()-.5)/2,e.y=300*(Math.random()-.5)/2,e.direction=this.direction,e.draggable=this.draggable,e.visible=this.visible,e.size=this.size,e.currentCostume=this.currentCostume,e.rotationStyle=this.rotationStyle,e.effects=JSON.parse(JSON.stringify(this.effects)),e.variables=this.duplicateVariables(e.blocks),e.updateAllDrawableProperties(),e}))}onGreenFlag(){this.clearEffects()}onStopAll(){this.clearEffects()}postSpriteInfo(t){const e=Object.prototype.hasOwnProperty.call(t,"force")?t.force:null,n=Object.prototype.hasOwnProperty.call(t,"x"),r=Object.prototype.hasOwnProperty.call(t,"y");(n||r)&&this.setXY(n?t.x:this.x,r?t.y:this.y,e),Object.prototype.hasOwnProperty.call(t,"direction")&&this.setDirection(t.direction),Object.prototype.hasOwnProperty.call(t,"draggable")&&this.setDraggable(t.draggable),Object.prototype.hasOwnProperty.call(t,"rotationStyle")&&this.setRotationStyle(t.rotationStyle),Object.prototype.hasOwnProperty.call(t,"visible")&&this.setVisible(t.visible),Object.prototype.hasOwnProperty.call(t,"size")&&this.setSize(t.size)}startDrag(){this.dragging=!0}stopDrag(){this.dragging=!1}toJSON(){const t=this.getCostumes();return{id:this.id,name:this.getName(),isStage:this.isStage,x:this.x,y:this.y,size:this.size,direction:this.direction,draggable:this.draggable,currentCostume:this.currentCostume,costume:t[this.currentCostume],costumeCount:t.length,visible:this.visible,rotationStyle:this.rotationStyle,comments:this.comments,blocks:this.blocks._blocks,variables:this.variables,costumes:t,sounds:this.getSounds(),textToSpeechLanguage:this.textToSpeechLanguage,tempo:this.tempo,volume:this.volume,videoTransparency:this.videoTransparency,videoState:this.videoState}}dispose(){this.isOriginal||this.runtime.changeCloneCounter(-1),this.runtime.stopForTarget(this),this.runtime.removeExecutable(this),this.sprite.removeClone(this),this.renderer&&null!==this.drawableID&&(this.renderer.destroyDrawable(this.drawableID,this.isStage?c.BACKGROUND_LAYER:c.SPRITE_LAYER),this.visible&&(this.emitVisualChange(),this.runtime.requestRedraw()))}}t.exports=u},function(t,e,n){const r=n(7),i=n(29);class s{constructor(t,e,n,i,o,a,c){this.id=t||r(),this.text=e,this.x=n,this.y=i,this.width=Math.max(Number(o),s.MIN_WIDTH),this.height=Math.max(Number(a),s.MIN_HEIGHT),this.minimized=c||!1,this.blockId=null}toXML(){return'').concat(i(this.text)," ")}static get MIN_WIDTH(){return 20}static get MIN_HEIGHT(){return 20}static get DEFAULT_WIDTH(){return 100}static get DEFAULT_HEIGHT(){return 100}}t.exports=s},function(t,e,n){const r=n(45),i=n(15),{loadSoundFromAsset:s}=n(30),{loadCostumeFromAsset:o}=n(31),a=n(79),c=n(6),u=n(12);class l{constructor(t,e){this.runtime=e,t||(t=new i(e)),this.blocks=t,this.name="",this.costumes_=[],this.sounds=[],this.clones=[],this.soundBank=null,this.runtime&&this.runtime.audioEngine&&(this.soundBank=this.runtime.audioEngine.createBank())}set costumes(t){this.costumes_=[];for(const e of t)this.addCostumeAt(e,this.costumes_.length)}get costumes(){return this.costumes_}addCostumeAt(t,e){t.name||(t.name="");const n=this.costumes_.map((t=>t.name));t.name=c.unusedName(t.name,n),this.costumes_.splice(e,0,t)}deleteCostumeAt(t){return this.costumes.splice(t,1)[0]}createClone(t){const e=new r(this,this.runtime);if(e.isOriginal=0===this.clones.length,this.clones.push(e),e.initAudio(),e.isOriginal){const n="string"==typeof t?t:u.SPRITE_LAYER;e.initDrawable(n),this.runtime.fireTargetWasCreated(e)}else this.runtime.fireTargetWasCreated(e,this.clones[0]);return e}removeClone(t){this.runtime.fireTargetWasRemoved(t);const e=this.clones.indexOf(t);e>=0&&this.clones.splice(e,1)}duplicate(){const t=new l(null,this.runtime),e=this.blocks._blocks,n=Object.keys(e).map((t=>e[t])),r=JSON.parse(JSON.stringify(n));a(r),r.forEach((e=>{t.blocks.createBlock(e)}));const i=this.runtime.targets.map((t=>t.sprite.name));t.name=c.unusedName(this.name,i);const u=[];return t.costumes=this.costumes_.map((t=>{const e=Object.assign({},t);return u.push(o(e,this.runtime)),e})),t.sounds=this.sounds.map((e=>{const n=Object.assign({},e),r=e.asset;return u.push(s(n,r,this.runtime,t.soundBank)),n})),Promise.all(u).then((()=>t))}dispose(){this.soundBank&&this.soundBank.dispose()}}t.exports=l},function(t,e,n){t.exports=function(){"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(t,n){return e=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},e(t,n)}function n(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function r(t,i,s){return r=n()?Reflect.construct:function(t,n,r){var i=[null];i.push.apply(i,n);var s=new(Function.bind.apply(t,i));return r&&e(s,r.prototype),s},r.apply(null,arguments)}function i(t){return s(t)||o(t)||a(t)||u()}function s(t){if(Array.isArray(t))return c(t)}function o(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function a(t,e){if(t){if("string"==typeof t)return c(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?c(t,e):void 0}}function c(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n1?n-1:0),i=1;i/gm),Z=g(/\${[\w\W]*}/gm),J=g(/^data-[\-\w.\u00B7-\uFFFF]+$/),_=g(/^aria-[\-\w]+$/),$=g(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),tt=g(/^(?:\w+script|data):/i),et=g(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),nt=g(/^html$/i),rt=g(/^[a-z][.\w]*(-[.\w]+)+$/i),it=function(){return"undefined"==typeof window?null:window},st=function(e,n){if("object"!==t(e)||"function"!=typeof e.createPolicy)return null;var r=null,i="data-tt-policy-suffix";n.currentScript&&n.currentScript.hasAttribute(i)&&(r=n.currentScript.getAttribute(i));var s="dompurify"+(r?"#"+r:"");try{return e.createPolicy(s,{createHTML:function(t){return t},createScriptURL:function(t){return t}})}catch(t){return console.warn("TrustedTypes policy "+s+" could not be created."),null}};function ot(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:it(),n=function(t){return ot(t)};if(n.version="2.5.8",n.removed=[],!e||!e.document||9!==e.document.nodeType)return n.isSupported=!1,n;var r=e.document,s=e.document,o=e.DocumentFragment,a=e.HTMLTemplateElement,c=e.Node,u=e.Element,l=e.NodeFilter,h=e.NamedNodeMap,d=void 0===h?e.NamedNodeMap||e.MozNamedAttrMap:h,p=e.HTMLFormElement,f=e.DOMParser,g=e.trustedTypes,b=u.prototype,y=B(b,"cloneNode"),v=B(b,"nextSibling"),w=B(b,"childNodes"),R=B(b,"parentNode");if("function"==typeof a){var D=s.createElement("template");D.content&&D.content.ownerDocument&&(s=D.content.ownerDocument)}var at=st(g,r),ct=at?at.createHTML(""):"",ut=s,lt=ut.implementation,ht=ut.createNodeIterator,dt=ut.createDocumentFragment,pt=ut.getElementsByTagName,ft=r.importNode,mt={};try{mt=L(s).documentMode?s.documentMode:{}}catch(t){}var gt={};n.isSupported="function"==typeof R&<&&void 0!==lt.createHTMLDocument&&9!==mt;var bt,yt,vt=Q,wt=X,Tt=Z,Et=J,At=_,kt=tt,It=et,St=rt,xt=$,Ot=null,Mt=P({},[].concat(i(U),i(j),i(F),i(V),i(Y))),Nt=null,Ct=P({},[].concat(i(H),i(W),i(K),i(q))),Rt=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Dt=null,Pt=null,Lt=!0,Bt=!0,Ut=!1,jt=!0,Ft=!1,zt=!0,Vt=!1,Gt=!1,Yt=!1,Ht=!1,Wt=!1,Kt=!1,qt=!0,Qt=!1,Xt="user-content-",Zt=!0,Jt=!1,_t={},$t=null,te=P({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),ee=null,ne=P({},["audio","video","img","source","image","track"]),re=null,ie=P({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),se="http://www.w3.org/1998/Math/MathML",oe="http://www.w3.org/2000/svg",ae="http://www.w3.org/1999/xhtml",ce=ae,ue=!1,le=null,he=P({},[se,oe,ae],I),de=["application/xhtml+xml","text/html"],pe="text/html",fe=null,me=s.createElement("form"),ge=function(t){return t instanceof RegExp||t instanceof Function},be=function(e){fe&&fe===e||(e&&"object"===t(e)||(e={}),e=L(e),bt=bt=-1===de.indexOf(e.PARSER_MEDIA_TYPE)?pe:e.PARSER_MEDIA_TYPE,yt="application/xhtml+xml"===bt?I:k,Ot="ALLOWED_TAGS"in e?P({},e.ALLOWED_TAGS,yt):Mt,Nt="ALLOWED_ATTR"in e?P({},e.ALLOWED_ATTR,yt):Ct,le="ALLOWED_NAMESPACES"in e?P({},e.ALLOWED_NAMESPACES,I):he,re="ADD_URI_SAFE_ATTR"in e?P(L(ie),e.ADD_URI_SAFE_ATTR,yt):ie,ee="ADD_DATA_URI_TAGS"in e?P(L(ne),e.ADD_DATA_URI_TAGS,yt):ne,$t="FORBID_CONTENTS"in e?P({},e.FORBID_CONTENTS,yt):te,Dt="FORBID_TAGS"in e?P({},e.FORBID_TAGS,yt):{},Pt="FORBID_ATTR"in e?P({},e.FORBID_ATTR,yt):{},_t="USE_PROFILES"in e&&e.USE_PROFILES,Lt=!1!==e.ALLOW_ARIA_ATTR,Bt=!1!==e.ALLOW_DATA_ATTR,Ut=e.ALLOW_UNKNOWN_PROTOCOLS||!1,jt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,Ft=e.SAFE_FOR_TEMPLATES||!1,zt=!1!==e.SAFE_FOR_XML,Vt=e.WHOLE_DOCUMENT||!1,Ht=e.RETURN_DOM||!1,Wt=e.RETURN_DOM_FRAGMENT||!1,Kt=e.RETURN_TRUSTED_TYPE||!1,Yt=e.FORCE_BODY||!1,qt=!1!==e.SANITIZE_DOM,Qt=e.SANITIZE_NAMED_PROPS||!1,Zt=!1!==e.KEEP_CONTENT,Jt=e.IN_PLACE||!1,xt=e.ALLOWED_URI_REGEXP||xt,ce=e.NAMESPACE||ae,Rt=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&ge(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Rt.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&ge(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Rt.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(Rt.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ft&&(Bt=!1),Wt&&(Ht=!0),_t&&(Ot=P({},i(Y)),Nt=[],!0===_t.html&&(P(Ot,U),P(Nt,H)),!0===_t.svg&&(P(Ot,j),P(Nt,W),P(Nt,q)),!0===_t.svgFilters&&(P(Ot,F),P(Nt,W),P(Nt,q)),!0===_t.mathMl&&(P(Ot,V),P(Nt,K),P(Nt,q))),e.ADD_TAGS&&(Ot===Mt&&(Ot=L(Ot)),P(Ot,e.ADD_TAGS,yt)),e.ADD_ATTR&&(Nt===Ct&&(Nt=L(Nt)),P(Nt,e.ADD_ATTR,yt)),e.ADD_URI_SAFE_ATTR&&P(re,e.ADD_URI_SAFE_ATTR,yt),e.FORBID_CONTENTS&&($t===te&&($t=L($t)),P($t,e.FORBID_CONTENTS,yt)),Zt&&(Ot["#text"]=!0),Vt&&P(Ot,["html","head","body"]),Ot.table&&(P(Ot,["tbody"]),delete Dt.tbody),m&&m(e),fe=e)},ye=P({},["mi","mo","mn","ms","mtext"]),ve=P({},["annotation-xml"]),we=P({},["title","style","font","a","script"]),Te=P({},j);P(Te,F),P(Te,z);var Ee=P({},V);P(Ee,G);var Ae=function(t){var e=R(t);e&&e.tagName||(e={namespaceURI:ce,tagName:"template"});var n=k(t.tagName),r=k(e.tagName);return!!le[t.namespaceURI]&&(t.namespaceURI===oe?e.namespaceURI===ae?"svg"===n:e.namespaceURI===se?"svg"===n&&("annotation-xml"===r||ye[r]):Boolean(Te[n]):t.namespaceURI===se?e.namespaceURI===ae?"math"===n:e.namespaceURI===oe?"math"===n&&ve[r]:Boolean(Ee[n]):t.namespaceURI===ae?!(e.namespaceURI===oe&&!ve[r])&&!(e.namespaceURI===se&&!ye[r])&&!Ee[n]&&(we[n]||!Te[n]):!("application/xhtml+xml"!==bt||!le[t.namespaceURI]))},ke=function(t){A(n.removed,{element:t});try{t.parentNode.removeChild(t)}catch(e){try{t.outerHTML=ct}catch(e){t.remove()}}},Ie=function(t,e){try{A(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(t){A(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t&&!Nt[t])if(Ht||Wt)try{ke(e)}catch(t){}else try{e.setAttribute(t,"")}catch(t){}},Se=function(t){var e,n;if(Yt)t=" "+t;else{var r=S(t,/^[\r\n\t ]+/);n=r&&r[0]}"application/xhtml+xml"===bt&&ce===ae&&(t=''+t+"");var i=at?at.createHTML(t):t;if(ce===ae)try{e=(new f).parseFromString(i,bt)}catch(t){}if(!e||!e.documentElement){e=lt.createDocument(ce,"template",null);try{e.documentElement.innerHTML=ue?ct:i}catch(t){}}var o=e.body||e.documentElement;return t&&n&&o.insertBefore(s.createTextNode(n),o.childNodes[0]||null),ce===ae?pt.call(e,Vt?"html":"body")[0]:Vt?e.documentElement:o},xe=function(t){return ht.call(t.ownerDocument||t,t,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT|l.SHOW_PROCESSING_INSTRUCTION|l.SHOW_CDATA_SECTION,null,!1)},Oe=function(t){return t instanceof p&&("string"!=typeof t.nodeName||"string"!=typeof t.textContent||"function"!=typeof t.removeChild||!(t.attributes instanceof d)||"function"!=typeof t.removeAttribute||"function"!=typeof t.setAttribute||"string"!=typeof t.namespaceURI||"function"!=typeof t.insertBefore||"function"!=typeof t.hasChildNodes)},Me=function(e){return"object"===t(c)?e instanceof c:e&&"object"===t(e)&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName},Ne=function(t,e,r){gt[t]&&T(gt[t],(function(t){t.call(n,e,r,fe)}))},Ce=function(t){var e;if(Ne("beforeSanitizeElements",t,null),Oe(t))return ke(t),!0;if(N(/[\u0080-\uFFFF]/,t.nodeName))return ke(t),!0;var r=yt(t.nodeName);if(Ne("uponSanitizeElement",t,{tagName:r,allowedTags:Ot}),t.hasChildNodes()&&!Me(t.firstElementChild)&&(!Me(t.content)||!Me(t.content.firstElementChild))&&N(/<[/\w]/g,t.innerHTML)&&N(/<[/\w]/g,t.textContent))return ke(t),!0;if("select"===r&&N(/=0;--o){var a=y(s[o],!0);a.__removalCount=(t.__removalCount||0)+1,i.insertBefore(a,v(t))}}return ke(t),!0}return t instanceof u&&!Ae(t)?(ke(t),!0):"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!N(/<\/no(script|embed|frames)/i,t.innerHTML)?(Ft&&3===t.nodeType&&(e=t.textContent,e=x(e,vt," "),e=x(e,wt," "),e=x(e,Tt," "),t.textContent!==e&&(A(n.removed,{element:t.cloneNode()}),t.textContent=e)),Ne("afterSanitizeElements",t,null),!1):(ke(t),!0)},Re=function(t,e,n){if(qt&&("id"===e||"name"===e)&&(n in s||n in me))return!1;if(Bt&&!Pt[e]&&N(Et,e));else if(Lt&&N(At,e));else if(!Nt[e]||Pt[e]){if(!(De(t)&&(Rt.tagNameCheck instanceof RegExp&&N(Rt.tagNameCheck,t)||Rt.tagNameCheck instanceof Function&&Rt.tagNameCheck(t))&&(Rt.attributeNameCheck instanceof RegExp&&N(Rt.attributeNameCheck,e)||Rt.attributeNameCheck instanceof Function&&Rt.attributeNameCheck(e))||"is"===e&&Rt.allowCustomizedBuiltInElements&&(Rt.tagNameCheck instanceof RegExp&&N(Rt.tagNameCheck,n)||Rt.tagNameCheck instanceof Function&&Rt.tagNameCheck(n))))return!1}else if(re[e]);else if(N(xt,x(n,It,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==O(n,"data:")||!ee[t])if(Ut&&!N(kt,x(n,It,"")));else if(n)return!1;return!0},De=function(t){return"annotation-xml"!==t&&S(t,St)},Pe=function(e){var r,i,s,o;Ne("beforeSanitizeAttributes",e,null);var a=e.attributes;if(a&&!Oe(e)){var c={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Nt};for(o=a.length;o--;){var u=r=a[o],l=u.name,h=u.namespaceURI;if(i="value"===l?r.value:M(r.value),s=yt(l),c.attrName=s,c.attrValue=i,c.keepAttr=!0,c.forceKeepAttr=void 0,Ne("uponSanitizeAttribute",e,c),i=c.attrValue,!c.forceKeepAttr&&(Ie(l,e),c.keepAttr))if(jt||!N(/\/>/i,i)){Ft&&(i=x(i,vt," "),i=x(i,wt," "),i=x(i,Tt," "));var d=yt(e.nodeName);if(Re(d,s,i))if(!Qt||"id"!==s&&"name"!==s||(Ie(l,e),i=Xt+i),zt&&N(/((--!?|])>)|<\/(style|title)/i,i))Ie(l,e);else{if(at&&"object"===t(g)&&"function"==typeof g.getAttributeType)if(h);else switch(g.getAttributeType(d,s)){case"TrustedHTML":i=at.createHTML(i);break;case"TrustedScriptURL":i=at.createScriptURL(i)}try{h?e.setAttributeNS(h,l,i):e.setAttribute(l,i),Oe(e)?ke(e):E(n.removed)}catch(t){}}}else Ie(l,e)}Ne("afterSanitizeAttributes",e,null)}},Le=function t(e){var n,r=xe(e);for(Ne("beforeSanitizeShadowDOM",e,null);n=r.nextNode();)Ne("uponSanitizeShadowNode",n,null),Ce(n),Pe(n),n.content instanceof o&&t(n.content);Ne("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(i){var s,a,u,l,h,d=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if((ue=!i)&&(i="\x3c!--\x3e"),"string"!=typeof i&&!Me(i)){if("function"!=typeof i.toString)throw C("toString is not a function");if("string"!=typeof(i=i.toString()))throw C("dirty is not a string, aborting")}if(!n.isSupported){if("object"===t(e.toStaticHTML)||"function"==typeof e.toStaticHTML){if("string"==typeof i)return e.toStaticHTML(i);if(Me(i))return e.toStaticHTML(i.outerHTML)}return i}if(Gt||be(d),n.removed=[],"string"==typeof i&&(Jt=!1),Jt){if(i.nodeName){var p=yt(i.nodeName);if(!Ot[p]||Dt[p])throw C("root node is forbidden and cannot be sanitized in-place")}}else if(i instanceof c)1===(a=(s=Se("\x3c!----\x3e")).ownerDocument.importNode(i,!0)).nodeType&&"BODY"===a.nodeName||"HTML"===a.nodeName?s=a:s.appendChild(a);else{if(!Ht&&!Ft&&!Vt&&-1===i.indexOf("<"))return at&&Kt?at.createHTML(i):i;if(!(s=Se(i)))return Ht?null:Kt?ct:""}s&&Yt&&ke(s.firstChild);for(var f=xe(Jt?i:s);u=f.nextNode();)3===u.nodeType&&u===l||(Ce(u),Pe(u),u.content instanceof o&&Le(u.content),l=u);if(l=null,Jt)return i;if(Ht){if(Wt)for(h=dt.call(s.ownerDocument);s.firstChild;)h.appendChild(s.firstChild);else h=s;return(Nt.shadowroot||Nt.shadowrootmod)&&(h=ft.call(r,h,!0)),h}var m=Vt?s.outerHTML:s.innerHTML;return Vt&&Ot["!doctype"]&&s.ownerDocument&&s.ownerDocument.doctype&&s.ownerDocument.doctype.name&&N(nt,s.ownerDocument.doctype.name)&&(m="\n"+m),Ft&&(m=x(m,vt," "),m=x(m,wt," "),m=x(m,Tt," ")),at&&Kt?at.createHTML(m):m},n.setConfig=function(t){be(t),Gt=!0},n.clearConfig=function(){fe=null,Gt=!1},n.isValidAttribute=function(t,e,n){fe||be({});var r=yt(t),i=yt(e);return Re(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&(gt[t]=gt[t]||[],A(gt[t],e))},n.removeHook=function(t){if(gt[t])return E(gt[t])},n.removeHooks=function(t){gt[t]&&(gt[t]=[])},n.removeAllHooks=function(){gt={}},n}return ot()}()},function(t,e){class n{static get svg(){return"http://www.w3.org/2000/svg"}static get xmlns(){return"http://www.w3.org/2000/xmlns"}static get xlink(){return"http://www.w3.org/1999/xlink"}static attributeNamespace(){return{href:n.xlink,xlink:n.xmlns,xmlns:`${n.xmlns}/`,"xmlns:xlink":`${n.xmlns}/`}}static create(t,e,r){return n.set(document.createElementNS(n.svg,t),e,r)}static get(t,e){const r=n.attributeNamespace[e],i=r?t.getAttributeNS(r,e):t.getAttribute(e);return"null"===i?null:i}static set(t,e,r){for(const i in e){let s=e[i];const o=n.attributeNamespace[i];"number"==typeof s&&r&&(s=r.number(s)),o?t.setAttributeNS(o,i,s):t.setAttribute(i,s)}return t}}t.exports=n},function(t,e){t.exports=class{constructor(t,e,n){this.audioEngine=t,this.audioPlayer=e,this.lastEffect=n,this.value=this.DEFAULT_VALUE,this.initialized=!1,this.inputNode=null,this.outputNode=null,this.target=null}get name(){throw new Error("".concat(this.constructor.name,".name is not implemented"))}get DEFAULT_VALUE(){return 0}get _isPatch(){return this.initialized&&(this.value!==this.DEFAULT_VALUE||null===this.audioPlayer)}getInputNode(){return this._isPatch?this.inputNode:this.target.getInputNode()}initialize(){throw new Error("".concat(this.constructor.name,".initialize is not implemented."))}_set(){throw new Error("".concat(this.constructor.name,"._set is not implemented."))}set(t){this.initialized||this.initialize();const e=this._isPatch;e&&(this._lastPatch=this.audioEngine.currentTime),t!==this.value&&this._set(t),this._isPatch!==e&&null!==this.target&&this.connect(this.target)}update(){}clear(){this.set(this.DEFAULT_VALUE)}connect(t){if(null===t)throw new Error("target may not be null");const e=t=>{if(t)return t===this||e(t.target)};if(e(t))throw new Error("Effect cannot connect to itself");this.target=t,null!==this.outputNode&&this.outputNode.disconnect(),(this._isPatch||this._lastPatch+this.audioEngine.DECAY_DURATION * {\n position: absolute;\n}\n.sc-scaled-overlays-outer {\n overflow: hidden;\n width: 100%;\n height: 100%;\n pointer-events: none;\n}\n.sc-scaled-overlays-inner {\n transform-origin: top left;\n}\n.sc-root * {\n box-sizing: border-box;\n}\n.sc-canvas {\n width: 100%;\n height: 100%;\n}\n\n.sc-question-root {\n bottom: 0;\n width: 100%;\n color: black;\n pointer-events: all;\n}\n.sc-question-inner {\n margin: 0.5rem;\n border: 1px solid hsla(0, 0%, 0%, 0.15);\n border-radius: 0.5rem;\n border-width: 2px;\n padding: 1rem;\n background: white;\n}\n.sc-question-text {\n font-size: 12px;\n padding-bottom: 8px;\n font-weight: bold;\n}\n.sc-question-input-outer {\n position: relative;\n}\n.sc-question-input {\n width: 100%;\n height: 2rem;\n padding: 0 12px;\n font-size: 10px;\n border-width: 1px;\n border-style: solid;\n border-color: hsla(0, 0%, 0%, 0.15);\n border-radius: 2rem;\n outline: none;\n transition: 0.25s ease-out;\n box-shadow: none;\n overflow: hidden;\n text-overflow: ellipsis;\n color: inherit;\n}\n.sc-question-input:focus {\n border-color: var(--sc-accent-color);\n box-shadow: 0px 0px 0px 3px var(--sc-accent-color-transparent);\n}\n.sc-question-input:hover {\n border-color: var(--sc-accent-color);\n}\n.sc-question-submit-button {\n top: 4px;\n right: 4px;\n width: 24px;\n height: 24px;\n position: absolute;\n outline: none;\n border: none;\n padding: 2px;\n margin: 0;\n border-radius: 100%;\n background: none;\n cursor: pointer;\n color: white;\n background-color: var(--sc-accent-color);\n background-image: url('+u+');\n overflow: hidden;\n}\n.sc-question-submit-button:focus {\n outline: 2px solid black;\n}\n.sc-question-submit-button-image {\n width: 100%;\n height: 100%;\n}\n\n.sc-monitor-overlay {\n\n}\n.sc-monitor-root {\n position: absolute;\n top: 0;\n left: 0;\n background: hsla(215, 100%, 95%, 1);\n color: #575e75;\n border: 1px solid hsla(0, 0%, 0%, 0.15);\n border-radius: 4px;\n font-size: 12px;\n overflow: hidden;\n user-select: none;\n -webkit-user-select: none;\n display: flex;\n flex-direction: column;\n pointer-events: all;\n}\n.sc-monitor-inner {\n display: flex;\n flex-direction: column;\n padding: 3px;\n}\n.sc-monitor-row {\n display: flex;\n flex-direction: row;\n}\n.sc-monitor-label {\n font-weight: bold;\n text-align: center;\n margin: 0 5px;\n white-space: nowrap;\n}\n.sc-monitor-slider {\n margin: 0;\n width: 100%;\n}\n.sc-monitor-value {\n min-width: 40px;\n display: flex;\n justify-content: center;\n align-items: center;\n text-align: center;\n color: white;\n margin: 0 5px;\n border-radius: 4px;\n padding: 0 2px;\n white-space: pre-wrap;\n background-color: #0fbd8c;\n}\n.sc-monitor-root[data-opcode^="motion_"] .sc-monitor-value-color {\n background-color: #4c97ff;\n}\n.sc-monitor-root[data-opcode^="sensing_"] .sc-monitor-value-color {\n background-color: #5cb1d6;\n}\n.sc-monitor-root[data-opcode^="data_"] .sc-monitor-value-color {\n background-color: #ff8c1a;\n}\n.sc-monitor-root[data-opcode^="looks_"] .sc-monitor-value-color {\n background-color: #9966ff;\n}\n.sc-monitor-root[data-opcode^="sound_"] .sc-monitor-value-color {\n background-color: #cf63cf;\n}\n.sc-monitor-large-value {\n min-height: 1.4rem;\n min-width: 3rem;\n padding: 0.1rem 0.25rem;\n text-align: center;\n color: white;\n font-size: 1rem;\n white-space: pre-wrap;\n}\n\n.sc-monitor-list-label {\n background-color: white;\n text-align: center;\n font-weight: bold;\n border-bottom: 1px solid hsla(0, 0%, 0%, 0.15);\n padding: 3px;\n}\n.sc-monitor-list-footer {\n display: flex;\n background-color: white;\n text-align: center;\n font-weight: bold;\n padding: 3px;\n}\n.sc-monitor-list-footer-text {\n text-align: center;\n flex-grow: 1;\n}\n.sc-monitor-row-delete, .sc-monitor-list-add {\n font-weight: bold;\n background: none;\n border: none;\n outline: none;\n font-family: inherit;\n color: inherit;\n cursor: pointer;\n margin: 0;\n padding: 0;\n}\n.sc-monitor-rows-outer {\n flex-grow: 1;\n}\n.sc-monitor-rows-inner {\n height: 100%;\n overflow-y: auto;\n overflow-x: hidden;\n position: relative;\n}\n.sc-monitor-rows-endpoint {\n position: absolute;\n top: 0;\n left: 0;\n width: 1px;\n height: 1px;\n pointer-events: none;\n}\n\n.sc-monitor-row-root {\n position: absolute;\n top: 0;\n left: 0;\n display: flex;\n justify-content: space-around;\n align-items: center;\n padding: 2px;\n width: 100%;\n}\n.sc-monitor-row-index {\n font-weight: bold;\n color: hsla(225, 15%, 40%, 1);\n margin: 0 3px;\n}\n.sc-monitor-row-value-outer {\n display: flex;\n align-items: center;\n min-width: 40px;\n height: 22px;\n border: 1px solid hsla(0, 0%, 0%, 0.15);\n background-color: #fc662c;\n color: white;\n margin: 0 3px;\n border-radius: calc(0.5rem / 2);\n flex-grow: 1;\n}\n.sc-monitor-row-value-editing .sc-monitor-row-value-outer {\n background-color: #e25c28;\n}\n.sc-monitor-row-value-inner {\n padding: 3px 5px;\n width: 100%;\n color: inherit;\n background: none;\n border: none;\n font: inherit;\n outline: none;\n overflow: hidden;\n text-overflow: ellipsis;\n user-select: text;\n -webkit-user-select: text;\n white-space: pre;\n}\n.sc-monitor-row-value-editing .sc-monitor-row-value-inner {\n padding-right: 0;\n}\n.sc-monitor-row-delete {\n display: none;\n font-size: 150%;\n padding: 0 2px;\n}\n.sc-monitor-row-value-editing .sc-monitor-row-delete {\n display: block;\n}\n.sc-monitor-empty {\n text-align: center;\n padding: 5px;\n}\n\n.sc-controls-bar {\n transform: translateY(-100%);\n display: flex;\n width: 100%;\n justify-content: space-between;\n flex-wrap: nowrap;\n}\n.sc-controls-bar > * {\n display: flex;\n align-items: center;\n flex-wrap: nowrap;\n}\n\n.sc-context-menu {\n position: absolute;\n color: black;\n box-shadow: 0px 0px 5px 1px hsla(0, 0%, 0%, 0.25);\n min-width: 130px;\n opacity: 0;\n transition: .2s opacity;\n}\n.sc-context-menu-item {\n display: block;\n width: 100%;\n background-color: white;\n border: none;\n border-radius: 0;\n cursor: pointer;\n text-align: left;\n font-family: inherit;\n font-size: 0.85em;\n padding: 8px 12px;\n margin: 0;\n transition: .1s background-color, .1s color;\n}\n.sc-context-menu-item:focus {\n outline: 2px solid black;\n}\n.sc-context-menu-item:hover,\n.sc-context-menu-item:active {\n color: white;\n background-color: var(--sc-accent-color);\n}\n.sc-context-menu-item:first-child {\n border-radius: 4px 4px 0 0;\n}\n.sc-context-menu-item:last-child {\n border-radius: 0 0 4px 4px;\n}\n\n.sc-dropping {\n background-color: var(--sc-accent-color-transparent);\n}\n',""]),c.locals={root:"sc-root",layers:"sc-layers","scaled-overlays-outer":"sc-scaled-overlays-outer",scaledOverlaysOuter:"sc-scaled-overlays-outer","scaled-overlays-inner":"sc-scaled-overlays-inner",scaledOverlaysInner:"sc-scaled-overlays-inner",canvas:"sc-canvas","question-root":"sc-question-root",questionRoot:"sc-question-root","question-inner":"sc-question-inner",questionInner:"sc-question-inner","question-text":"sc-question-text",questionText:"sc-question-text","question-input-outer":"sc-question-input-outer",questionInputOuter:"sc-question-input-outer","question-input":"sc-question-input",questionInput:"sc-question-input","question-submit-button":"sc-question-submit-button",questionSubmitButton:"sc-question-submit-button","question-submit-button-image":"sc-question-submit-button-image",questionSubmitButtonImage:"sc-question-submit-button-image","monitor-overlay":"sc-monitor-overlay",monitorOverlay:"sc-monitor-overlay","monitor-root":"sc-monitor-root",monitorRoot:"sc-monitor-root","monitor-inner":"sc-monitor-inner",monitorInner:"sc-monitor-inner","monitor-row":"sc-monitor-row",monitorRow:"sc-monitor-row","monitor-label":"sc-monitor-label",monitorLabel:"sc-monitor-label","monitor-slider":"sc-monitor-slider",monitorSlider:"sc-monitor-slider","monitor-value":"sc-monitor-value",monitorValue:"sc-monitor-value","monitor-value-color":"sc-monitor-value-color",monitorValueColor:"sc-monitor-value-color","monitor-large-value":"sc-monitor-large-value",monitorLargeValue:"sc-monitor-large-value","monitor-list-label":"sc-monitor-list-label",monitorListLabel:"sc-monitor-list-label","monitor-list-footer":"sc-monitor-list-footer",monitorListFooter:"sc-monitor-list-footer","monitor-list-footer-text":"sc-monitor-list-footer-text",monitorListFooterText:"sc-monitor-list-footer-text","monitor-row-delete":"sc-monitor-row-delete",monitorRowDelete:"sc-monitor-row-delete","monitor-list-add":"sc-monitor-list-add",monitorListAdd:"sc-monitor-list-add","monitor-rows-outer":"sc-monitor-rows-outer",monitorRowsOuter:"sc-monitor-rows-outer","monitor-rows-inner":"sc-monitor-rows-inner",monitorRowsInner:"sc-monitor-rows-inner","monitor-rows-endpoint":"sc-monitor-rows-endpoint",monitorRowsEndpoint:"sc-monitor-rows-endpoint","monitor-row-root":"sc-monitor-row-root",monitorRowRoot:"sc-monitor-row-root","monitor-row-index":"sc-monitor-row-index",monitorRowIndex:"sc-monitor-row-index","monitor-row-value-outer":"sc-monitor-row-value-outer",monitorRowValueOuter:"sc-monitor-row-value-outer","monitor-row-value-editing":"sc-monitor-row-value-editing",monitorRowValueEditing:"sc-monitor-row-value-editing","monitor-row-value-inner":"sc-monitor-row-value-inner",monitorRowValueInner:"sc-monitor-row-value-inner","monitor-empty":"sc-monitor-empty",monitorEmpty:"sc-monitor-empty","controls-bar":"sc-controls-bar",controlsBar:"sc-controls-bar","context-menu":"sc-context-menu",contextMenu:"sc-context-menu","context-menu-item":"sc-context-menu-item",contextMenuItem:"sc-context-menu-item",dropping:"sc-dropping"},e.a=c},function(t,e,n){const r=n(102);t.exports=r},function(t,e,n){const r=n(104),i=n(0);t.exports=new class extends r{constructor(){super(),this.services={},this.workerClass="undefined"==typeof Worker?null:Worker,this.workers=[]}callSync(t,e){const{provider:n,isRemote:r}=this._getServiceProvider(t);if(n){if(r)throw new Error("Cannot use 'callSync' on remote provider for service ".concat(t,"."));for(var i=arguments.length,s=new Array(i>2?i-2:0),o=2;o{i.error("Could not handshake with worker: ".concat(t))}))):i.warn("Central dispatch ignoring attempt to add duplicate worker")}_getServiceProvider(t){const e=this.services[t];return e&&{provider:e,isRemote:Boolean(this.workerClass&&e instanceof this.workerClass||e.isRemote)}}_onDispatchMessage(t,e){let n;if("setService"===e.method)n=this.setService(e.args[0],t);else i.error("Central dispatch received message for unknown method: ".concat(e.method));return n}}},function(t,e,n){const r=n(5);t.exports=function(t,e,n){return t&&t.id&&t.default?r(t,e,n):t}},function(t,e){var n="long",r="short",i="narrow",s="numeric",o="2-digit";t.exports={number:{decimal:{style:"decimal"},integer:{style:"decimal",maximumFractionDigits:0},currency:{style:"currency",currency:"USD"},percent:{style:"percent"},default:{style:"decimal"}},date:{short:{month:s,day:s,year:o},medium:{month:r,day:s,year:s},long:{month:n,day:s,year:s},full:{month:n,day:s,year:s,weekday:n},default:{month:r,day:s,year:s}},time:{short:{hour:s,minute:s},medium:{hour:s,minute:s,second:s},long:{hour:s,minute:s,second:s,timeZoneName:r},full:{hour:s,minute:s,second:s,timeZoneName:r},default:{hour:s,minute:s,second:s}},duration:{default:{hours:{minimumIntegerDigits:1,maximumFractionDigits:0},minutes:{minimumIntegerDigits:2,maximumFractionDigits:0},seconds:{minimumIntegerDigits:2,maximumFractionDigits:3}}},parseNumberPattern:function(t){if(t){var e={},n=t.match(/\b[A-Z]{3}\b/i),r=t.replace(/[^¤]/g,"").length;if(!r&&n&&(r=1),r?(e.style="currency",e.currencyDisplay=1===r?"symbol":2===r?"code":"name",e.currency=n?n[0].toUpperCase():"USD"):t.indexOf("%")>=0&&(e.style="percent"),!/[@#0]/.test(t))return e.style?e:void 0;if(e.useGrouping=t.indexOf(",")>=0,/E\+?[@#0]+/i.test(t)||t.indexOf("@")>=0){var i=t.replace(/E\+?[@#0]+|[^@#0]/gi,"");e.minimumSignificantDigits=Math.min(Math.max(i.replace(/[^@0]/g,"").length,1),21),e.maximumSignificantDigits=Math.min(Math.max(i.length,1),21)}else{for(var s=t.replace(/[^#0.]/g,"").split("."),o=s[0],a=o.length-1;"0"===o[a];)--a;e.minimumIntegerDigits=Math.min(Math.max(o.length-1-a,1),21);var c=s[1]||"";for(a=0;"0"===c[a];)++a;for(e.minimumFractionDigits=Math.min(Math.max(a,0),20);"#"===c[a];)++a;e.maximumFractionDigits=Math.min(Math.max(a,0),20)}return e}},parseDatePattern:function(t){if(t){for(var e={},a=0;a{this._openRequests[n]={resolve:t,reject:e}}));return this._sendRequest(t,e,n),r}sendRemoteNotification(t,e){this._sendRequest(t,e)}didReceiveCall(){throw new Error("Must override didReceiveCall")}_sendMessage(){throw new Error("Must override _sendMessage")}_sendRequest(t,e,n){const r={jsonrpc:"2.0",method:t,params:e};null!==n&&(r.id=n),this._sendMessage(r)}_handleMessage(t){if("2.0"!==t.jsonrpc)throw new Error("Bad or missing JSON-RPC version in message: ".concat(t));Object.prototype.hasOwnProperty.call(t,"method")?this._handleRequest(t):this._handleResponse(t)}_sendResponse(t,e,n){const r={jsonrpc:"2.0",id:t};n?r.error=n:r.result=e||null,this._sendMessage(r)}_handleResponse(t){const{result:e,error:n,id:r}=t,i=this._openRequests[r];delete this._openRequests[r],i&&(n?i.reject(n):i.resolve(e))}_handleRequest(t){const{method:e,params:n,id:r}=t,i=this.didReceiveCall(e,n);null!=r&&Promise.resolve(i).then((t=>{this._sendResponse(r,t)}),(t=>{this._sendResponse(r,null,t)}))}}},function(t){t.exports=JSON.parse('{"menuMap":{"cs":[{"code":"cs","name":"čeština"}],"da":[{"code":"da","name":"Dansk"}],"gl":[{"code":"gl","name":"galego"}],"sl":[{"code":"sl","name":"slovenščina"}],"fr":[{"code":"fr","name":"Français"}],"hu":[{"code":"hu","name":"magyar"}],"uk":[{"code":"uk","name":"українська"}],"zh-tw":[{"code":"zh-tw","name":"中文(繁體)"}],"pt":[{"code":"pt","name":"Portuguese"}],"pt-br":[{"code":"pt","name":"Português"}],"tr":[{"code":"tr","name":"Türkçe"}],"ga":[{"code":"ga","name":"Gaeilge"}],"th":[{"code":"th","name":"ภาษาไทย"}],"ja":[{"code":"ja","name":"日本語"}],"ja-hira":[{"code":"ja","name":"日本語"}],"nl":[{"code":"nl","name":"Nederlands"}],"gd":[{"code":"gd","name":"Gàidhlig"}],"nb":[{"code":"nb","name":"norsk"}],"de":[{"code":"de","name":"Deutsch"}],"he":[{"code":"he","name":"עברית"}],"sk":[{"code":"sk","name":"slovenčina"}],"zu":[{"code":"zu","name":"isiZulu"}],"ru":[{"code":"ru","name":"русский"}],"pl":[{"code":"pl","name":"polski"}],"am":[{"code":"am","name":"አማርኛ"}],"az":[{"code":"az","name":"Azərbaycan dili"}],"hr":[{"code":"hr","name":"hrvatski"}],"fa":[{"code":"fa","name":"فارسی"}],"mi":[{"code":"mi","name":"Māori"}],"el":[{"code":"el","name":"Ελληνικά"}],"is":[{"code":"is","name":"íslenska"}],"fi":[{"code":"fi","name":"suomi"}],"eu":[{"code":"eu","name":"euskara"}],"ca":[{"code":"ca","name":"català"}],"lv":[{"code":"lv","name":"latviešu"}],"id":[{"code":"id","name":"Indonesia"}],"es":[{"code":"es","name":"español"}],"es-419":[{"code":"es","name":"español"}],"et":[{"code":"et","name":"eesti"}],"cy":[{"code":"cy","name":"Cymraeg"}],"zh-cn":[{"code":"zh-cn","name":"中文(简体)"}],"bg":[{"code":"bg","name":"български"}],"ar":[{"code":"ar","name":"العربية"}],"en":[{"code":"en","name":"English"}],"sr":[{"code":"sr","name":"српски"}],"sv":[{"code":"sv","name":"svenska"}],"ro":[{"code":"ro","name":"Română"}],"lt":[{"code":"lt","name":"lietuvių"}],"ko":[{"code":"ko","name":"한국어"}],"it":[{"code":"it","name":"Italiano"}],"vi":[{"code":"vi","name":"Tiếng Việt"}]},"nameMap":{"albánština":"sq","amharština":"am","angličtina":"en","arabština":"ar","arménština":"hy","ázerbájdžánština":"az","barmština":"my","baskičtina":"eu","běloruština":"be","bulharština":"bg","čeština":"cs","čínština (tradiční)":"zh-tw","čínština (zjednodušená)":"zh-cn","dánština":"da","esperanto":"eo","estonština":"et","finština":"fi","francouzština":"fr","galicijština":"gl","haitská kreolština":"ht","hebrejština":"he","hindština":"hi","holandština":"nl","chorvatština":"hr","indonéština":"id","irština":"ga","islandština":"is","italština":"it","japonština":"ja","kannadština":"kn","katalánština":"ca","korejština":"ko","kurdština":"ku","latina":"la","litevština":"lt","lotyština":"lv","maďarština":"hu","makedonština":"mk","malajálamština":"ml","malajština":"ms","maltština":"mt","maorština":"mi","marátština":"mr","mongolština":"mn","němčina":"de","norština":"nb","perština":"fa","polština":"pl","portugalština":"pt","rumunština":"ro","ruština":"ru","řečtina":"el","skotská gaelština":"gd","slovenština":"sk","slovinština":"sl","srbština":"sr","španělština":"es","švédština":"sv","telužština":"te","thajština":"th","turečtina":"tr","ukrajinština":"uk","uzbečtina":"uz","velština":"cy","vietnamština":"vi","zulu":"zu","albansk":"sq","amharisk":"am","arabisk":"ar","armensk":"hy","aserbajdsjansk":"az","baskisk":"eu","bulgarsk":"bg","burmesisk":"my","dansk":"da","engelsk":"en","estisk":"et","finsk":"fi","fransk":"fr","galicisk":"gl","græsk":"el","haitisk kreolsk":"ht","hebraisk":"he","hindi":"hi","hollandsk":"nl","hviderussisk":"be","indonesisk":"id","irsk":"ga","islandsk":"is","italiensk":"it","japansk":"ja","kannada":"kn","katalansk":"ca","kinesisk (forenklet)":"zh-cn","kinesisk (traditionelt)":"zh-tw","koreansk":"ko","kroatisk":"hr","kurdisk":"ku","latin":"la","lettisk":"lv","litauisk":"lt","makedonsk":"mk","malajisk":"ms","malayalam":"ml","maltesisk":"mt","maori":"mi","marathi":"mr","mongolsk":"mn","norsk":"nb","persisk":"fa","polsk":"pl","portugisisk":"pt","rumænsk":"ro","russisk":"ru","serbisk":"sr","skotsk gælisk":"gd","slovakisk":"sk","slovensk":"sl","spansk":"es","svensk":"sv","telugu":"te","thailandsk":"th","tjekkisk":"cs","tyrkisk":"tr","tysk":"de","ukrainsk":"uk","ungarsk":"hu","usbekisk":"uz","vietnamesisk":"vi","walisisk":"cy","acerbaixano":"az","albanés":"sq","alemán":"de","amárico":"am","árabe":"ar","armenio":"hy","bielorruso":"be","birmano":"my","búlgaro":"bg","canarés":"kn","catalán":"ca","checo":"cs","chinés (simplificado)":"zh-cn","chinés (tradicional)":"zh-tw","coreano":"ko","crioulo haitiano":"ht","croata":"hr","curdo":"ku","dinamarqués":"da","eslovaco":"sk","esloveno":"sl","español":"es","estoniano":"et","éuscaro":"eu","finés":"fi","francés":"fr","gaélico escocés":"gd","galego":"gl","galés":"cy","grego":"el","hebreo":"he","húngaro":"hu","indonesio":"id","inglés":"en","irlandés":"ga","islandés":"is","italiano":"it","latín":"la","letón":"lv","lituano":"lt","macedonio":"mk","malabar":"ml","malaio":"ms","maltés":"mt","maorí":"mi","mongol":"mn","neerlandés":"nl","noruegués":"nb","persa":"fa","polaco":"pl","portugués":"pt","romanés":"ro","ruso":"ru","serbio":"sr","sueco":"sv","tailandés":"th","telugú":"te","turco":"tr","ucraíno":"uk","usbeco":"uz","vietnamita":"vi","xaponés":"ja","zulú":"zu","albanščina":"sq","amharščina":"am","angleščina":"en","arabščina":"ar","armenščina":"hy","azerbajdžanščina":"az","baskovščina":"eu","beloruščina":"be","bolgarščina":"bg","burmanščina":"my","češčina":"cs","danščina":"da","estonščina":"et","finščina":"fi","francoščina":"fr","galicijščina":"gl","grščina":"el","haitijska kreolščina":"ht","hebrejščina":"he","hindijščina":"hi","hrvaščina":"hr","indonezijščina":"id","irščina":"ga","islandščina":"is","italijanščina":"it","japonščina":"ja","kanareščina":"kn","katalonščina":"ca","kitajščina (poenostavljena)":"zh-cn","kitajščina (tradicionalna)":"zh-tw","korejščina":"ko","kurdščina":"ku","latinščina":"la","latvijščina":"lv","litovščina":"lt","madžarščina":"hu","makedonščina":"mk","malajalščina":"ml","malajščina":"ms","malteščina":"mt","maorščina":"mi","maratščina":"mr","mongolščina":"mn","nemščina":"de","nizozemščina":"nl","norveščina":"nb","perzijščina":"fa","poljščina":"pl","portugalščina":"pt","romunščina":"ro","ruščina":"ru","slovaščina":"sk","slovenščina":"sl","srbščina":"sr","škotska gelščina":"gd","španščina":"es","švedščina":"sv","tajščina":"th","teluščina":"te","turščina":"tr","ukrajinščina":"uk","uzbeščina":"uz","valižanščina":"cy","vietnamščina":"vi","zulujščina":"zu","albanais":"sq","allemand":"de","amharique":"am","anglais":"en","arabe":"ar","arménien":"hy","azéri":"az","basque":"eu","biélorusse":"be","birman":"my","bulgare":"bg","catalan":"ca","chinois (simplifié)":"zh-cn","chinois (traditionnel)":"zh-tw","coréen":"ko","créole haïtien":"ht","croate":"hr","danois":"da","espagnol":"es","espéranto":"eo","estonien":"et","finnois":"fi","français":"fr","gaélique (écosse)":"gd","galicien":"gl","gallois":"cy","grec":"el","hébreu":"he","hongrois":"hu","indonésien":"id","irlandais":"ga","islandais":"is","italien":"it","japonais":"ja","kurde":"ku","letton":"lv","lituanien":"lt","macédonien":"mk","malaisien":"ms","maltais":"mt","néerlandais":"nl","norvégien":"nb","ouzbek":"uz","persan":"fa","polonais":"pl","portugais":"pt","roumain":"ro","russe":"ru","serbe":"sr","slovaque":"sk","slovène":"sl","suédois":"sv","tchèque":"cs","thaï":"th","turc":"tr","ukrainien":"uk","vietnamien":"vi","zoulou":"zu","albán":"sq","amhara":"am","angol":"en","arab":"ar","azeri":"az","baszk":"eu","belorusz":"be","bolgár":"bg","burmai":"my","cseh":"cs","dán":"da","eszperantó":"eo","észt":"et","finn":"fi","francia":"fr","galíciai":"gl","görög":"el","haiti kreol":"ht","héber":"he","holland":"nl","horvát":"hr","indonéz":"id","ír":"ga","izlandi":"is","japán":"ja","katalán":"ca","kínai (egyszerűsített)":"zh-cn","kínai (hagyományos)":"zh-tw","koreai":"ko","kurd":"ku","lengyel":"pl","lett":"lv","litván":"lt","macedón":"mk","magyar":"hu","maláj":"ms","malajálam":"ml","máltai":"mt","maráthi":"mr","német":"de","norvég":"nb","olasz":"it","orosz":"ru","örmény":"hy","perzsa":"fa","portugál":"pt","román":"ro","skót-gael":"gd","spanyol":"es","svéd":"sv","szerb":"sr","szlovák":"sk","szlovén":"sl","thai":"th","török":"tr","ukrán":"uk","üzbég":"uz","vietnami":"vi","walesi":"cy","азербайджанська":"az","албанська":"sq","амхарська":"am","англійська":"en","арабська":"ar","баскська":"eu","білоруська":"be","бірманська":"my","болгарська":"bg","в’єтнамська":"vi","валлійська":"cy","вірменська":"hy","гаїтянська креольська":"ht","гінді":"hi","грецька":"el","ґалісійська":"gl","данська":"da","есперанто":"eo","естонська":"et","зулу":"zu","іврит":"he","індонезійська":"id","ірландська":"ga","ісландська":"is","іспанська":"es","італійська":"it","каннада":"kn","каталанська":"ca","китайська (спрощена)":"zh-cn","китайська (традиційна)":"zh-tw","корейська":"ko","курдська":"ku","латинська":"la","латиська":"lv","литовська":"lt","македонська":"mk","малайська":"ms","малаялам":"ml","мальтійська":"mt","маорі":"mi","маратхі":"mr","монгольська":"mn","нідерландська":"nl","німецька":"de","норвезька":"nb","перська":"fa","польська":"pl","португальська":"pt","російська":"ru","румунська":"ro","сербська":"sr","словацька":"sk","словенська":"sl","тайська":"th","телуґу":"te","турецька":"tr","угорська":"hu","узбецька":"uz","українська":"uk","фінська":"fi","французька":"fr","хорватська":"hr","чеська":"cs","шведська":"sv","шотландська (ґельська)":"gd","японська":"ja","土耳其文":"tr","中文(繁體)":"zh-tw","中文(簡體)":"zh-cn","丹麥文":"da","巴斯克文":"eu","日文":"ja","毛利文":"mi","世界語":"eo","加里西亞文":"gl","加泰羅尼亞文":"ca","卡納達文":"kn","白俄羅斯文":"be","立陶宛文":"lt","冰島文":"is","匈牙利文":"hu","印尼文":"id","印度文":"hi","西班牙文":"es","克羅埃西亞文":"hr","希伯來文":"he","希臘文":"el","亞美尼亞文":"hy","亞塞拜然文":"az","拉丁文":"la","拉脫維亞文":"lv","法文":"fr","波斯文":"fa","波蘭文":"pl","芬蘭文":"fi","阿姆哈拉文":"am","阿拉伯文":"ar","阿爾巴尼亞文":"sq","俄文":"ru","保加利亞文":"bg","南非祖魯文":"zu","威爾斯文":"cy","英文":"en","庫德文":"ku","挪威文":"nb","泰文":"th","泰盧固文":"te","海地克里奧文":"ht","烏克蘭文":"uk","烏茲別克文":"uz","馬耳他文":"mt","馬來文":"ms","馬其頓文":"mk","馬拉地文":"mr","馬拉雅拉姆文":"ml","捷克文":"cs","荷蘭文":"nl","斯洛伐克文":"sk","斯洛維尼亞文":"sl","越南文":"vi","塞爾維亞文":"sr","愛沙尼亞文":"et","愛爾蘭文":"ga","瑞典文":"sv","義大利文":"it","葡萄牙文":"pt","蒙古文":"mn","德文":"de","緬甸文":"my","韓文":"ko","羅馬尼亞文":"ro","蘇格蘭的蓋爾文":"gd","अझरबैजानी":"az","अम्हारिक":"am","अरबी":"ar","अर्मेनियन":"hy","अल्बानियन":"sq","आइसलँडिक":"is","आयरिश":"ga","इंग्रजी":"en","इंडोनेशियन":"id","इटालियन":"it","उझ्बेक":"uz","एस्टोनियन":"et","एस्परँटो":"eo","कन्नड":"kn","कुर्दिश (कुर्मांजी)":"ku","कॅटलान":"ca","कोरियन":"ko","क्रोएशियन":"hr","गॅलिशियन":"gl","ग्रीक":"el","चीनी (पारंपारिक)":"zh-tw","चीनी (सरलीकृत)":"zh-cn","जपानी":"ja","जर्मन":"de","झुलु":"zu","झेक":"cs","डच":"nl","डॅनिश":"da","तुर्की":"tr","तेलगू":"te","थाई":"th","नॉर्वेजियन":"nb","पोर्तुगीज":"pt","पोलिश":"pl","फारसी":"fa","फिन्निश":"fi","फ्रेंच":"fr","बल्गेरियन":"bg","बास्क":"eu","बेलारुशियन":"be","मंगोलियन":"mn","मराठी":"mr","मलय":"ms","मल्याळम":"ml","माओरी":"mi","माल्टीज":"mt","मॅसेडोनियन":"mk","म्यानमार (बर्मीज)":"my","युक्रेनियन":"uk","रशियन":"ru","रोमानियन":"ro","लाट्वियन":"lv","लिथुआनियन":"lt","लॅटिन":"la","वेल्श":"cy","व्हिएतनामी":"vi","सर्बियन":"sr","स्कॉट्स गेलिक":"gd","स्पॅनिश":"es","स्लोव्हाक":"sk","स्लोव्हेनियन":"sl","स्वीडिश":"sv","हंगेरियन":"hu","हिन्दी":"hi","हिब्रू":"he","हैतीयन क्रेओल":"ht","albanian":"sq","amharic":"am","arabic":"ar","armenian":"hy","azerbaijani":"az","belarusian":"be","bulgarian":"bg","chinese (simplified)":"zh-cn","chinese (traditional)":"zh-tw","croatian":"hr","czech":"cs","danish":"da","dutch":"nl","english":"en","estonian":"et","finnish":"fi","french":"fr","galician":"gl","german":"de","greek":"el","haitian creole":"ht","hebrew":"he","hungarian":"hu","icelandic":"is","indonesian":"id","irish":"ga","italian":"it","japanese":"ja","korean":"ko","kurdish (kurmanji)":"ku","latvian":"lv","lithuanian":"lt","macedonian":"mk","malay":"ms","maltese":"mt","mongolian":"mn","myanmar (burmese)":"my","norwegian":"nb","persian":"fa","polish":"pl","portuguese":"pt","romanian":"ro","russian":"ru","scots gaelic":"gd","serbian":"sr","slovak":"sk","slovenian":"sl","spanish":"es","swedish":"sv","turkish":"tr","ukrainian":"uk","uzbek":"uz","vietnamese":"vi","welsh":"cy","albanês":"sq","alemão":"de","armênio":"hy","azerbaijano":"az","basco":"eu","bielo-russo":"be","birmanês":"my","canarês":"kn","catalão":"ca","chinês (simplificado)":"zh-cn","chinês (tradicional)":"zh-tw","dinamarquês":"da","espanhol":"es","finlandês":"fi","francês":"fr","gaélico escocês":"gd","galês":"cy","hebraico":"he","holandês":"nl","indonésio":"id","inglês":"en","irlandês":"ga","islandês":"is","japonês":"ja","latim":"la","letão":"lv","macedônio":"mk","malaiala":"ml","maltês":"mt","marata":"mr","norueguês":"nb","polonês":"pl","português":"pt","romeno":"ro","russo":"ru","sérvio":"sr","tailandês":"th","tcheco":"cs","telugo":"te","ucraniano":"uk","uzbeque":"uz","almanca":"de","arapça":"ar","arnavutça":"sq","azerice":"az","baskça":"eu","belarusça":"be","bulgarca":"bg","burmaca":"my","çekçe":"cs","çince (basitleştirilmiş)":"zh-cn","çince (geleneksel)":"zh-tw","danca":"da","endonezya dili":"id","ermenice":"hy","esperantoca":"eo","estonyaca":"et","farsça":"fa","felemenkçe":"nl","fince":"fi","fransızca":"fr","galce":"cy","galiçyaca":"gl","habeşçe":"am","haiti creole dili":"ht","hırvatça":"hr","hintçe":"hi","i̇branice":"he","i̇ngilizce":"en","i̇rlandaca":"ga","i̇spanyolca":"es","i̇sveççe":"sv","i̇talyanca":"it","i̇zlandaca":"is","japonca":"ja","katalanca":"ca","korece":"ko","kuzey i̇skoç dili":"gd","kürtçe":"ku","latince":"la","lehçe":"pl","letonca":"lv","litvanca":"lt","macarca":"hu","makedonca":"mk","malezya dili":"ms","malta dili":"mt","maori dili":"mi","moğolca":"mn","norveççe":"nb","özbekçe":"uz","portekizce":"pt","romence":"ro","rusça":"ru","sırpça":"sr","slovakça":"sk","slovence":"sl","tay dili":"th","telugu dili":"te","türkçe":"tr","ukraynaca":"uk","vietnamca":"vi","yunanca":"el","airméinis":"hy","albáinis":"sq","amárais":"am","araibis":"ar","asarbaiseáinis":"az","bascais":"eu","bealarúisis":"be","béarla":"en","breatnais":"cy","bulgáiris":"bg","cannadais":"kn","catalóinis":"ca","coirdis (curmainsis)":"ku","cóiréis":"ko","criól háítí":"ht","cróitis":"hr","danmhairgis":"da","eabhrais":"he","eastóinis":"et","fionlainnis":"fi","fraincis":"fr","gaeilge":"ga","gaeilge na halban":"gd","gailísis":"gl","gearmáinis":"de","gréigis":"el","hiondúis":"hi","indinéisis":"id","iodáilis":"it","ioruais":"nb","íoslainnis":"is","laidin":"la","laitvis":"lv","liotuáinis":"lt","macadóinis":"mk","maenmar (burmais)":"my","mailéalaimis":"ml","malaeis":"ms","máltais":"mt","maorais":"mi","maraitis":"mr","mongóilis":"mn","ollainnis":"nl","peirsis":"fa","polainnis":"pl","portaingéilis":"pt","rómáinis":"ro","rúisis":"ru","seapáinis":"ja","seicis":"cs","seirbis":"sr","sínis (simplithe)":"zh-cn","sínis (traidisiúnta)":"zh-tw","slóivéinis":"sl","slóvaicis":"sk","spáinnis":"es","sualainnis":"sv","súlúis":"zu","téalainnis":"th","teileagúis":"te","tuircis":"tr","úcráinis":"uk","úisbéiceastáinis":"uz","ungáiris":"hu","vítneaimis":"vi","ภาษากรีก":"el","ภาษากันนาดา":"kn","ภาษากาลิเชียน":"gl","ภาษาเกลิกในสก็อต":"gd","ภาษาเกาหลี":"ko","ภาษาคาตาลัน":"ca","ภาษาเคิร์ด":"ku","ภาษาโครเอเชีย":"hr","ภาษาจีน (ดั้งเดิม)":"zh-tw","ภาษาจีน (แบบย่อ)":"zh-cn","ภาษาเช็ก":"cs","ภาษาซูลู":"zu","ภาษาเซอร์เบียน":"sr","ภาษาญี่ปุ่น":"ja","ภาษาดัตช์":"nl","ภาษาเดนมาร์ก":"da","ภาษาตุรกี":"tr","ภาษาเตลูกู":"te","ภาษาไทย":"th","ภาษานอร์เวย์":"nb","ภาษาบัลกาเรีย":"bg","ภาษาบาสก์":"eu","ภาษาเบลารูเชียน":"be","ภาษาเปอร์เซีย":"fa","ภาษาโปรตุเกส":"pt","ภาษาโปแลนด์":"pl","ภาษาฝรั่งเศส":"fr","ภาษาฟินแลนด์":"fi","ภาษามองโกเลีย":"mn","ภาษามัลทีส":"mt","ภาษามาซีโดเนีย":"mk","ภาษามาราฐี":"mr","ภาษามาลายาลัม":"ml","ภาษามาเลย์":"ms","ภาษาเมารี":"mi","ภาษาเมียนมา (พม่า)":"my","ภาษายูเครน":"uk","ภาษาเยอรมัน":"de","ภาษารัสเซีย":"ru","ภาษาโรมาเนีย":"ro","ภาษาละติน":"la","ภาษาลัทเวีย":"lv","ภาษาลิทัวเนีย":"lt","ภาษาเวลส์":"cy","ภาษาเวียดนาม":"vi","ภาษาสเปน":"es","ภาษาสโลวัก":"sk","ภาษาสโลเวเนีย":"sl","ภาษาสวีเดน":"sv","ภาษาอังกฤษ":"en","ภาษาอัมฮาริก":"am","ภาษาอัลบาเนีย":"sq","ภาษาอาร์เซอร์ไบจัน":"az","ภาษาอาร์เมเนีย":"hy","ภาษาอาหรับ":"ar","ภาษาอิตาลี":"it","ภาษาอินโดนีเซีย":"id","ภาษาอุสเบกิสถาน":"uz","ภาษาเอสโทเนีย":"et","ภาษาเอสเปอแรนโต":"eo","ภาษาไอซ์แลนดิก":"is","ภาษาไอริช":"ga","ภาษาฮังการี":"hu","ภาษาฮินดี":"hi","ภาษาฮิบรู":"he","ภาษาเฮติครีโอล":"ht","アイスランド語":"is","アイルランド語":"ga","アゼルバイジャン語":"az","アムハラ語":"am","アラビア語":"ar","アルバニア語":"sq","アルメニア語":"hy","イタリア語":"it","インドネシア語":"id","ウェールズ語":"cy","ウクライナ語":"uk","ウズベク語":"uz","エストニア語":"et","エスペラント語":"eo","オランダ語":"nl","カタルーニャ語":"ca","ガリシア語":"gl","カンナダ語":"kn","ギリシャ語":"el","クルド語":"ku","クロアチア語":"hr","スウェーデン語":"sv","ズールー語":"zu","スコットランド ゲール語":"gd","スペイン語":"es","スロバキア語":"sk","スロベニア語":"sl","セルビア語":"sr","タイ語":"th","チェコ語":"cs","テルグ語":"te","デンマーク語":"da","ドイツ語":"de","トルコ語":"tr","ノルウェー語":"nb","ハイチ語":"ht","バスク語":"eu","ハンガリー語":"hu","ヒンディー語":"hi","フィンランド語":"fi","フランス語":"fr","ブルガリア語":"bg","ベトナム語":"vi","ヘブライ語":"he","ベラルーシ語":"be","ペルシャ語":"fa","ポーランド語":"pl","ポルトガル語":"pt","マオリ語":"mi","マケドニア語":"mk","マラーティー語":"mr","マラヤーラム語":"ml","マルタ語":"mt","マレー語":"ms","ミャンマー語":"my","モンゴル語":"mn","ラテン語":"la","ラトビア語":"lv","リトアニア語":"lt","ルーマニア語":"ro","ロシア語":"ru","英語":"en","韓国語":"ko","中国語(簡体)":"zh-cn","中国語(繁体)":"zh-tw","日本語":"ja","albanees":"sq","amharisch":"am","arabisch":"ar","armeens":"hy","azerbeidzjaans":"az","baskisch":"eu","birmaans":"my","bulgaars":"bg","catalaans":"ca","chinees (traditioneel)":"zh-tw","chinees (vereenvoudigd)":"zh-cn","deens":"da","duits":"de","engels":"en","ests":"et","fins":"fi","frans":"fr","galicisch":"gl","grieks":"el","haïtiaans creools":"ht","hebreeuws":"he","hongaars":"hu","iers":"ga","ijslands":"is","indonesisch":"id","italiaans":"it","japans":"ja","koerdisch":"ku","koreaans":"ko","kroatisch":"hr","latijn":"la","lets":"lv","litouws":"lt","macedonisch":"mk","maleis":"ms","maltees":"mt","mongools":"mn","nederlands":"nl","noors":"nb","oekraïens":"uk","oezbeeks":"uz","perzisch":"fa","pools":"pl","portugees":"pt","roemeens":"ro","russisch":"ru","schots keltisch":"gd","servisch":"sr","slovaaks":"sk","sloveens":"sl","spaans":"es","tsjechisch":"cs","turks":"tr","vietnamees":"vi","wels":"cy","wit-russisch":"be","zoeloe":"zu","zweeds":"sv","airmeinis":"hy","albàinis":"sq","amtharais":"am","arabais":"ar","asarbaideànais":"az","basgais":"eu","bealaruisis":"be","beurla":"en","bhiet-namais":"vi","bulgarais":"bg","cànan nan tàidh":"th","catalanais":"ca","coirèanais":"ko","crìtheol haidhti":"ht","cròthaisis":"hr","cuimris":"cy","cùrdais (kurmanji)":"ku","duitsis":"nl","eabhra":"he","eadailtis":"it","eastoinis":"et","fionnlannais":"fi","fraingis":"fr","gàidhlig":"gd","gailìsis":"gl","gearmailtis":"de","grèigis":"el","hindis":"hi","innd-innsis":"id","innis-tìlis":"is","laideann":"la","laitbheis":"lv","liotuainis":"lt","malaidhis":"ms","māori":"mi","masadonais":"mk","miànmar (burmais)":"my","mongolais":"mn","nirribhis":"nb","pòlainnis":"pl","portagailis":"pt","romàinis":"ro","ruisis":"ru","seacais":"cs","seapanais":"ja","sèirbis":"sr","sìonais (seann-nòsach)":"zh-tw","sìonais (sìmplichte)":"zh-cn","slòbhacais":"sk","slòbhainis":"sl","spàinntis":"es","suainis":"sv","turcais":"tr","ucràinis":"uk","ungairis":"hu","usbagais":"uz","farsi":"fa","galisisk":"gl","gresk":"el","hviterussisk":"be","kinesisk (tradisjonell)":"zh-tw","kreol (haiti)":"ht","latvisk":"lv","malayisk":"ms","nederlandsk":"nl","rumensk":"ro","tsjekkisk":"cs","albanisch":"sq","armenisch":"hy","aserbaidschanisch":"az","birmanisch":"my","bulgarisch":"bg","chinesisch (traditionell)":"zh-tw","chinesisch (vereinfacht)":"zh-cn","dänisch":"da","deutsch":"de","englisch":"en","estnisch":"et","finnisch":"fi","französisch":"fr","galizisch":"gl","griechisch":"el","haitianisch":"ht","hebräisch":"he","irisch":"ga","isländisch":"is","italienisch":"it","japanisch":"ja","katalanisch":"ca","koreanisch":"ko","kurdisch (kurmandschi)":"ku","lateinisch":"la","lettisch":"lv","litauisch":"lt","malaysisch":"ms","maltesisch":"mt","mazedonisch":"mk","mongolisch":"mn","niederländisch":"nl","norwegisch":"nb","persisch":"fa","polnisch":"pl","portugiesisch":"pt","rumänisch":"ro","schottisch-gälisch":"gd","schwedisch":"sv","serbisch":"sr","slowakisch":"sk","slowenisch":"sl","spanisch":"es","thailändisch":"th","tschechisch":"cs","türkisch":"tr","ukrainisch":"uk","ungarisch":"hu","usbekisch":"uz","vietnamesisch":"vi","walisisch":"cy","weißrussisch":"be","ကနာဒါ":"kn","ကာ့ဒ် (ကာမန်ဂျီ)":"ku","ကိုရီးယား":"ko","ကက်တလန်":"ca","ခရိုအေးရှား":"hr","ချက်":"cs","ဂရိ":"el","ဂယ်လိရှ":"gl","ဂျပန်":"ja","ဂျာမန်":"de","စကော့ ဂေးလစ်":"gd","စပိန်":"es","ဆလိုဗေးနီးယား":"sl","ဆလိုဗက်":"sk","ဆားဘီးယား":"sr","ဆွီဒင်":"sv","ဇူးလူး":"zu","တရုတ် (ရိုးရာ)":"zh-tw","တရုတ် (အလွယ်)":"zh-cn","တူရကီ":"tr","တယ်လူဂူ":"te","ထိုင်း":"th","ဒတ်ချ်":"nl","ဒိန်းမတ်":"da","နော်ဝေ":"nb","ပါရှန်":"fa","ပေါ်တူဂီ":"pt","ပိုလန်":"pl","ပြင်သစ်":"fr","ဖင်လန်":"fi","ဗီယက်နမ်":"vi","ဘာ့စ်":"eu","ဘူဂေးရီးယား":"bg","ဘယ်လာရုစ်":"be","မလေယာလမ်":"ml","မလေး":"ms","မာရာသီ":"mr","မော်ရီ":"mi","မော်လတာ":"mt","မက်ဆီဒိုးနီးယား":"mk","မြန်မာ (မြန်မာ)":"my","မွန်ဂိုလီးယား":"mn","ယူကရိန်း":"uk","ရုရှား":"ru","ရိုမေးနီးယား":"ro","လက်တင်":"la","လစ်သူယေးနီးယား":"lt","လတ်ဗီယာ":"lv","ဝေလ":"cy","ဟီဘရူး":"he","ဟေတီ ခရီအိုး":"ht","ဟင်ဒီ":"hi","ဟန်ဂေရီ":"hu","အဇာဘိုင်ဂျန်":"az","အာမေးနီးယား":"hy","အာရေဗျ":"ar","အီတလီ":"it","ဥဇဘက်":"uz","အက်စတိုးနီးယား":"et","အက်စ်ပဲရန်တို":"eo","အိုက်စလန်":"is","အင်္ဂလိပ်":"en","အင်ဒိုနီးရှား":"id","အိုင်းရစ်ရှ်":"ga","အမ်ဟဲရစ်ခ်":"am","အယ်လ်ဘေးနီးယား":"sq","אוזבקית":"uz","אוקראינית":"uk","אזרית":"az","איטלקית":"it","אינדונזית":"id","איסלנדית":"is","אירית":"ga","אלבנית":"sq","אמהרית":"am","אנגלית":"en","אסטונית":"et","אספרנטו":"eo","ארמנית":"hy","באסקית":"eu","בולגרית":"bg","בורמזית":"my","בלארוסית":"be","גליציאנית":"gl","גרמנית":"de","דנית":"da","הולנדית":"nl","הונגרית":"hu","הינדי":"hi","וולשית":"cy","וייטנאמית":"vi","זולו":"zu","טורקית":"tr","טלוגו":"te","יוונית":"el","יפנית":"ja","כורדית":"ku","לטווית":"lv","לטינית":"la","ליטאית":"lt","מאורית":"mi","מאלאיאלם":"ml","מאלזית":"ms","מאראתי":"mr","מונגולית":"mn","מלטית":"mt","מקדונית":"mk","נורווגית":"nb","סינית (מסורתית)":"zh-tw","סינית (פשוטה)":"zh-cn","סלובנית":"sl","סלובקית":"sk","ספרדית":"es","סקוטית גאלית":"gd","סרבית":"sr","עברית":"he","ערבית":"ar","פולנית":"pl","פורטוגזית":"pt","פינית":"fi","פרסית":"fa","צ\'כית":"cs","צרפתית":"fr","קאנאדה":"kn","קוריאנית":"ko","קטלאנית":"ca","קרואטית":"hr","קריאולית האיטית":"ht","רומנית":"ro","רוסית":"ru","שוודית":"sv","תאילנדית":"th","азербејџански":"az","албански":"sq","амхарски":"am","англиски":"en","арапски":"ar","баскиски":"eu","белоруски":"be","бугарски":"bg","бурмански":"my","велшки":"cy","виетнамски":"vi","галициски":"gl","германски":"de","грчки":"el","дански":"da","ерменски":"hy","естонски":"et","индонезиски":"id","ирски":"ga","исландски":"is","италијански":"it","јапонски":"ja","канада":"kn","каталонски":"ca","кинески (поедноставен)":"zh-cn","кинески (традиционален)":"zh-tw","корејски":"ko","курдски":"ku","латвиски":"lv","латински":"la","литвански":"lt","македонски":"mk","малајалам":"ml","малајски":"ms","малтешки":"mt","маорски":"mi","маратхи":"mr","монголски":"mn","норвешки":"nb","персиски":"fa","полски":"pl","португалски":"pt","романски":"ro","руски":"ru","словачки":"sk","словенечки":"sl","српски":"sr","тајландски":"th","телугу":"te","турски":"tr","узбечки":"uz","украински":"uk","унгарски":"hu","фински":"fi","француски":"fr","хаитски креолски":"ht","хебрејски":"he","хиндиски":"hi","холандски":"nl","хрватски":"hr","чешки":"cs","шведски":"sv","шкотски галски":"gd","шпански":"es","ಅಜರ್ಬೈಜಾನಿ":"az","ಅಮಹಾರಿಕ್":"am","ಅರಬ್ಬಿ":"ar","ಆರ್ಮೇನಿಯನ್":"hy","ಆಲ್ಬೇನಿಯನ್":"sq","ಇಂಗ್ಲಿಷ್":"en","ಇಂಡೋನೇಷಿಯನ್":"id","ಇಟಾಲಿಯನ್":"it","ಉಜ್ಬೆಕ್":"uz","ಎಸ್ಟೋನಿಯನ್":"et","ಎಸ್ಪೆರಾಂಟೋ":"eo","ಐರಿಷ್":"ga","ಐಸ್ಲ್ಯಾಂಡಿಕ್":"is","ಕನ್ನಡ":"kn","ಕುರ್ದಿಶ್":"ku","ಕೊರಿಯನ್":"ko","ಕ್ಯಾಟಲನ್":"ca","ಕ್ರೊಯೇಷಿಯನ್":"hr","ಗ್ಯಾಲೀಷಿಯನ್":"gl","ಗ್ರೀಕ್":"el","ಚೀನಿ (ಸರಳೀಕೃತ)":"zh-cn","ಚೀನಿ (ಸಾಂಪ್ರದಾಯಿಕ)":"zh-tw","ಜಪಾನಿ":"ja","ಜರ್ಮನ್":"de","ಜುಲು":"zu","ಝೆಕ್":"cs","ಟರ್ಕಿಷ್":"tr","ಡಚ್":"nl","ಡ್ಯಾನಿಷ್":"da","ತೆಲುಗು":"te","ಥಾಯ್":"th","ನಾರ್ವೇಜಿಯನ್":"nb","ಪೋರ್ಚುಗೀಸ್":"pt","ಪೋಲಿಷ್":"pl","ಫಾರ್ಸಿ":"fa","ಫಿನ್ನಿಷ್":"fi","ಫ್ರೆಂಚ್":"fr","ಬರ್ಮೀಸ್":"my","ಬಲ್ಗೇರಿಯನ್":"bg","ಬಾಸ್ಕ್":"eu","ಬೆಲರೂಸಿಯನ್":"be","ಮಂಗೋಲಿಯನ್":"mn","ಮರಾಠಿ":"mr","ಮಲಯ":"ms","ಮಲಯಾಳಂ":"ml","ಮಾಲ್ಟೀಸ್":"mt","ಮಾವೋರಿ":"mi","ಮ್ಯಾಸೆಡೋನಿಯನ್":"mk","ಯುಕ್ರೇನಿಯನ್":"uk","ರಷಿಯನ್":"ru","ರೊಮೇನಿಯನ್":"ro","ಲಿಥುವೇನಿಯನ್":"lt","ಲ್ಯಾಟಿನ್":"la","ಲ್ಯಾಟ್ವಿಯನ್":"lv","ವಿಯೆಟ್ನಾಮಿ":"vi","ವೆಲ್ಶ್":"cy","ಸರ್ಬಿಯನ್":"sr","ಸ್ಕಾಟ್ಸ್ ಗ್ಯಾಲಿಕ್":"gd","ಸ್ಪ್ಯಾನಿಷ್":"es","ಸ್ಲೊವಾಕ್":"sk","ಸ್ಲೊವೆನಿಯನ್":"sl","ಸ್ವೀಡಿಷ್":"sv","ಹಂಗೇರಿಯನ್":"hu","ಹಯಥಿಯನ್ ಕ್ರಿಯೋಲ್":"ht","ಹಿಂದಿ":"hi","ಹೀಬ್ರೂ":"he","അമാറിക്":"am","അർമേനിയൻ":"hy","അൽബേനിയൻ":"sq","അസർബൈജാനി":"az","അറബിക്":"ar","ഇന്തോനേഷ്യൻ":"id","ഇംഗ്ലീഷ്":"en","ഇറ്റാലിയൻ":"it","ഉക്രേനിയൻ":"uk","ഉസ്ബെക്ക്":"uz","എസ്പെരന്തോ":"eo","എസ്റ്റോണിയൻ":"et","ഐസ്ലാൻഡിക്":"is","ഐറിഷ്":"ga","കന്നട":"kn","കാറ്റലൻ":"ca","കുർദ്ദിഷ്":"ku","കൊറിയൻ":"ko","ക്രൊയേഷ്യൻ":"hr","ഗലീഷ്യൻ":"gl","ഗ്രീക്ക്":"el","ചെക്ക്":"cs","ചൈനീസ് (പരമ്പരാഗതം)":"zh-tw","ചൈനീസ് (ലഘൂകരിച്ചത്)":"zh-cn","ജർമ്മൻ":"de","ജാപ്പനീസ്":"ja","ടർക്കിഷ്":"tr","ഡച്ച്":"nl","ഡാനിഷ്":"da","തായ്":"th","തെലുങ്ക്":"te","നോർവീജിയൻ":"nb","പേർഷ്യൻ":"fa","പോർച്ചുഗീസ്":"pt","പോളിഷ്":"pl","ഫിന്നിഷ്":"fi","ഫ്രെഞ്ച്":"fr","ബർമീസ്":"my","ബൾഗേറിയൻ":"bg","ബാസ്ക്":"eu","ബെലാറുഷ്യൻ":"be","മംഗോളിയൻ":"mn","മലയാളം":"ml","മലയ്":"ms","മറാഠി":"mr","മാസഡോണിയൻ":"mk","മാൾട്ടീസ്":"mt","മൗറി":"mi","ലാറ്റിൻ":"la","ലാറ്റ്വിയൻ":"lv","ലിത്വേനിയൻ":"lt","വിയറ്റ്നാമീസ്":"vi","വെൽഷ്":"cy","സുളു":"zu","സെർബിയൻ":"sr","സ്കോട്ട്സ് ഗ്യാലിക്":"gd","സ്പാനിഷ്":"es","സ്ലോവാക്":"sk","സ്ലോവേനിയൻ":"sl","സ്വീഡിഷ്":"sv","ഹംഗേറിയൻ":"hu","ഹിന്ദി":"hi","ഹീബ്രു":"he","ഹെയ്തിയൻ ക്രയോൾ":"ht","റഷ്യൻ":"ru","റൊമേനിയൻ":"ro","albánčina":"sq","amharčina":"am","arabčina":"ar","arménčina":"hy","azerbajdžančina":"az","barmčina":"my","bieloruština":"be","bulharčina":"bg","čínština (tradičná)":"zh-tw","dánčina":"da","estónčina":"et","fínčina":"fi","francúzština":"fr","galícijčina":"gl","gréčtina":"el","haitská kreolčina":"ht","hebrejčina":"he","hindčina":"hi","holandčina":"nl","chorvátčina":"hr","indonézština":"id","írčina":"ga","islandčina":"is","japončina":"ja","kannadčina":"kn","katalánčina":"ca","kórejčina":"ko","kurdčina":"ku","latinčina":"la","litovčina":"lt","macedónčina":"mk","maďarčina":"hu","malajámčina":"ml","malajčina":"ms","maltčina":"mt","maorijčina":"mi","maratčina":"mr","mongolčina":"mn","nemčina":"de","nórčina":"nb","perzština":"fa","poľština":"pl","portugalčina":"pt","rumunčina":"ro","slovenčina":"sk","slovinčina":"sl","srbčina":"sr","škótska gaelčina":"gd","španielčina":"es","švédčina":"sv","taliančina":"it","telugčina":"te","thajčina":"th","ukrajinčina":"uk","vietnamčina":"vi","waleština":"cy","zuluština":"zu","isi-albania":"sq","isi-amharic":"am","isi-arabic":"ar","isi-armenian":"hy","isi-azerbaijani":"az","isi-basque":"eu","isi-belarusian":"be","isi-bulgarian":"bg","isi-burmese":"my","isi-catalan":"ca","isi-chinese (simplified)":"zh-cn","isi-chinese (traditional)":"zh-tw","isi-croatian":"hr","isi-czech":"cs","isi-danish":"da","isi-dutch":"nl","isi-english":"en","isi-esperanto":"eo","isi-estonian":"et","isi-finnish":"fi","isi-french":"fr","isi-galician":"gl","isi-german":"de","isi-greek":"el","isi-haitian creole":"ht","isi-hangarian":"hu","isi-hebrew":"he","isi-hindi":"hi","isi-icelandic":"is","isi-indonesian":"id","isi-irish":"ga","isi-italian":"it","isi-japanese":"ja","isi-kannada":"kn","isi-korean":"ko","isi-kurdish":"ku","isi-latin":"la","isi-latvian":"lv","isi-lithuanian":"lt","isi-macedonian":"mk","isi-malay":"ms","isi-malayalam":"ml","isi-maltese":"mt","isi-maori":"mi","isi-marathi":"mr","isi-mongolian":"mn","isi-norwegian":"nb","isi-persian":"fa","isi-polish":"pl","isi-portuguese":"pt","isi-romanian":"ro","isi-russian":"ru","isi-scots gaelic":"gd","isi-serbian":"sr","isi-slovak":"sk","isi-slovenian":"sl","isi-spanish":"es","isi-swedish":"sv","isi-telugu":"te","isi-thai":"th","isi-turkish":"tr","isi-ukrainian":"uk","isi-uzbek":"uz","isi-vietnamese":"vi","isi-welsh":"cy","isizulu":"zu","albania":"sq","armenia":"hy","azerbaijan":"az","belanda":"nl","belarus":"be","bulgaria":"bg","cina (mudah)":"zh-cn","cina (tradisional)":"zh-tw","croatia":"hr","denmark":"da","estonia":"et","finland":"fi","gaelic scotland":"gd","galicia":"gl","hungary":"hu","ibrani":"he","iceland":"is","indonesia":"id","inggeris":"en","ireland":"ga","itali":"it","jepun":"ja","jerman":"de","korea":"ko","kreol haiti":"ht","kurdistan":"ku","latvia":"lv","lithuania":"lt","macedonia":"mk","malta":"mt","melayu":"ms","mongolia":"mn","myanmar":"my","norway":"nb","parsi":"fa","perancis":"fr","poland":"pl","portugis":"pt","romania":"ro","rusia":"ru","sepanyol":"es","serbia":"sr","slovenia":"sl","sweden":"sv","turki":"tr","ukraine":"uk","vietnam":"vi","wales":"cy","азербайджанский":"az","албанский":"sq","амхарский":"am","английский":"en","арабский":"ar","армянский":"hy","баскский":"eu","белорусский":"be","бирманский":"my","болгарский":"bg","валлийский":"cy","венгерский":"hu","вьетнамский":"vi","галисийский":"gl","греческий":"el","датский":"da","иврит":"he","индонезийский":"id","ирландский":"ga","исландский":"is","испанский":"es","итальянский":"it","каталанский":"ca","китайский (традиционный)":"zh-tw","китайский (упрощенный)":"zh-cn","корейский":"ko","креольский (гаити)":"ht","курманджи":"ku","латинский":"la","латышский":"lv","литовский":"lt","македонский":"mk","малайский":"ms","мальтийский":"mt","маори":"mi","монгольский":"mn","немецкий":"de","нидерландский":"nl","норвежский":"nb","персидский":"fa","польский":"pl","португальский":"pt","румынский":"ro","русский":"ru","сербский":"sr","словацкий":"sk","словенский":"sl","тайский":"th","турецкий":"tr","узбекский":"uz","украинский":"uk","финский":"fi","французский":"fr","хинди":"hi","хорватский":"hr","чешский":"cs","шведский":"sv","шотландский (гэльский)":"gd","эсперанто":"eo","эстонский":"et","японский":"ja","albański":"sq","amharski":"am","angielski":"en","arabski":"ar","azerski":"az","baskijski":"eu","białoruski":"be","birmański":"my","bułgarski":"bg","chiński (tradycyjny)":"zh-tw","chiński (uproszczony)":"zh-cn","chorwacki":"hr","czeski":"cs","duński":"da","estoński":"et","fiński":"fi","francuski":"fr","galicyjski":"gl","grecki":"el","hebrajski":"he","hiszpański":"es","indonezyjski":"id","irlandzki":"ga","islandzki":"is","japoński":"ja","kataloński":"ca","koreański":"ko","kreolski (haiti)":"ht","kurdyjski":"ku","litewski":"lt","łaciński":"la","łotewski":"lv","macedoński":"mk","malajalam":"ml","malajski":"ms","maltański":"mt","mongolski":"mn","niderlandzki":"nl","niemiecki":"de","norweski":"nb","ormiański":"hy","perski":"fa","polski":"pl","portugalski":"pt","rosyjski":"ru","rumuński":"ro","serbski":"sr","słowacki":"sk","słoweński":"sl","szkocki gaelicki":"gd","szwedzki":"sv","tajski":"th","turecki":"tr","ukraiński":"uk","uzbecki":"uz","walijski":"cy","węgierski":"hu","wietnamski":"vi","włoski":"it","азербайджанская":"az","албанская":"sq","амхарская":"am","англійская":"en","арабская":"ar","армянская":"hy","балгарская":"bg","баскская":"eu","беларуская":"be","в\'етнамская":"vi","валійская":"cy","венгерская":"hu","гаіцянская крэольская":"ht","галандская":"nl","галісійская":"gl","грэчаская":"el","дацкая":"da","інданезійская":"id","ірландская":"ga","ісландская":"is","іспанская":"es","італьянская":"it","іўрыт":"he","карэйская":"ko","каталонская":"ca","кітайская (спрошчаная)":"zh-cn","кітайская (традыцыйная)":"zh-tw","курдская (курманджы)":"ku","латышская":"lv","лацінская":"la","літоўская":"lt","м\'янманская (бірманская)":"my","маары":"mi","македонская":"mk","малайская":"ms","мальтыйская":"mt","мангольская":"mn","нарвежская":"nb","нямецкая":"de","партугальская":"pt","персідская":"fa","польская":"pl","румынская":"ro","руская":"ru","сербская":"sr","славацкая":"sk","славенская":"sl","тайская":"th","турэцкая":"tr","тэлугу":"te","узбекская":"uz","украінская":"uk","фінская":"fi","французская":"fr","харвацкая":"hr","хіндзі":"hi","чэшская":"cs","шатландская гэльская":"gd","шведская":"sv","эсперанта":"eo","эстонская":"et","японская":"ja","amarikisht":"am","anglisht":"en","arabisht":"ar","armenisht":"hy","azerisht":"az","baskisht":"eu","birmanisht":"my","bjellorusisht":"be","bullgarisht":"bg","çekisht":"cs","danisht":"da","estonisht":"et","finlandisht":"fi","frëngjisht":"fr","galicianisht":"gl","galishte skoceze":"gd","greqisht":"el","gjermanisht":"de","hebraisht":"he","hindisht":"hi","holandisht":"nl","hungarisht":"hu","indonezisht":"id","irlandisht":"ga","islandisht":"is","italisht":"it","japonisht":"ja","kanada":"kn","katalonisht":"ca","kinezisht (e thjeshtuar)":"zh-cn","kinezisht (tradicionale)":"zh-tw","koreanisht":"ko","kreolishte haitiane":"ht","kroatisht":"hr","latinisht":"la","letonisht":"lv","lituanisht":"lt","malajalamisht":"ml","malajzisht":"ms","malteze":"mt","maorisht":"mi","maqedonisht":"mk","maratisht":"mr","mongolisht":"mn","norvegjisht":"nb","persisht":"fa","polonisht":"pl","portugalisht":"pt","rumanisht":"ro","rusisht":"ru","serbisht":"sr","sllovakisht":"sk","sllovenisht":"sl","spanjisht":"es","suedisht":"sv","shqip":"sq","tajlandisht":"th","telugisht":"te","turqisht":"tr","uellsisht":"cy","ukrainisht":"uk","uzbekisht":"uz","vietnamisht":"vi","ሀንጋሪኛ":"hu","ህንድኛ":"hi","ሊትዌንኛ":"lt","ላቲንኛ":"la","ላትቪያኛ":"lv","ማላያላምኛ":"ml","ማላይኛ":"ms","ማልቲስኛ":"mt","ማራቲኛ":"mr","ማዮሪኛ":"mi","ሜቄዶኒያኛ":"mk","ሞንጎሊያኛ":"mn","ራሽያኛ":"ru","ሮማኒያንኛ":"ro","ሰርቢያኛ":"sr","ስሎቫክኛ":"sk","ስሎቬንያኛ":"sl","ስዊድንኛ":"sv","ስፓኒሽኛ":"es","በርማኛ":"my","ቡልጋሪያኛ":"bg","ባስክኛ":"eu","ቤላሩስኛ":"be","ቪትናምኛ":"vi","ቱርክኛ":"tr","ታይኛ":"th","ቴሉጉኛ":"te","ቻይንኛ (ቀላሉ)":"zh-cn","ቻይንኛ (ባሕላዊው)":"zh-tw","ቼክኛ":"cs","ኖርዌጅያንኛ":"nb","አልባንያኛ":"sq","አማርኛ":"am","አርመኒያኛ":"hy","አዜርባይጃንኛ":"az","አይሪሽ":"ga","አይስላንድኛ":"is","ኡዝቤክኛ":"uz","ኤስቶኒያኛ":"et","ኤስፐራንቶ":"eo","እንዶኔዢያኛ":"id","እንግሊዝኛ":"en","ኩርድሽኛ":"ku","ካታላንኛ":"ca","ካናዳኛ":"kn","ክሮኤሽያኛ":"hr","ኮሪያኛ":"ko","ዌልሽ":"cy","ዐረብኛ":"ar","ዕብራይስጥ":"he","ዙሉኛ":"zu","የሃይቲ ክረኦሌኛ":"ht","የስኮት ጌልክኛ":"gd","ዩክሬንኛ":"uk","ደችኛ":"nl","ዴንሽኛ":"da","ጀርመንኛ":"de","ጃፓንኛ":"ja","ጋሊሺያኛ":"gl","ግሪክኛ":"el","ጣሊያንኛ":"it","ፈረንሳይኛ":"fr","ፊኒሽኛ":"fi","ፐርሺያኛ":"fa","ፖሊሽኛ":"pl","ፖርቱጋሊኛ":"pt","alban":"sq","alman":"de","amarikcə":"am","azərbaycan dili":"az","bask":"eu","belarusca":"be","bolqar":"bg","çex":"cs","çin (ən\'ənəvi)":"zh-tw","çin (sadələşdirilmiş)":"zh-cn","danimarka":"da","erməni":"hy","eston":"et","ərəb":"ar","fars dili":"fa","fin":"fi","fransız":"fr","haiti kreol dili":"ht","hind":"hi","xorvat":"hr","ispan":"es","i̇ndoneziya":"id","i̇ngilis":"en","i̇rland":"ga","i̇sland":"is","i̇sveç":"sv","i̇talyan":"it","i̇vrit":"he","katalan":"ca","koreya":"ko","kürd dili (kurmanci)":"ku","qalisian":"gl","latın":"la","latış":"lv","litva":"lt","macar":"hu","makedoniya":"mk","maoricə":"mi","monqolca":"mn","myanma (birma) dili":"my","norveç":"nb","özbək":"uz","polyak":"pl","portuqal":"pt","rumın":"ro","rus":"ru","serb":"sr","sloven":"sl","şotland (kelt)":"gd","tayca":"th","teluqu":"te","türk":"tr","uels":"cy","ukrayna":"uk","vyetnam":"vi","yapon":"ja","yunan":"el","zulu dili":"zu","albaniż":"sq","amħari":"am","armen":"hy","ażerbajġani":"az","belarussu":"be","bulgaru":"bg","ċek":"cs","ċiniż (semplifikat)":"zh-cn","ċiniż (tradizzjonali)":"zh-tw","creole haiti":"ht","daniż":"da","ebrajk":"he","estonjan":"et","finlandiż":"fi","franċiż":"fr","ġappuniż":"ja","ġermaniż":"de","gaelic tal-iskoċċiżi":"gd","galizjan":"gl","grieg":"el","għarbi":"ar","ħindi":"hi","indoneżjan":"id","ingliż":"en","irlandiż":"ga","islandiż":"is","kroat":"hr","kurd (kurmanji)":"ku","latvjan":"lv","litwen":"lt","maċedonjan":"mk","malasjan":"ms","malti":"mt","marati":"mr","mjanmar (burma)":"my","mongoljan":"mn","norveġiż":"nb","olandiż":"nl","persjan":"fa","pollakk":"pl","portugiż":"pt","rumen":"ro","russu":"ru","slovakk":"sk","spanjol":"es","svediż":"sv","tajlandiż":"th","taljan":"it","tork":"tr","ukren":"uk","ungeriż":"hu","użbek":"uz","vjetnamiż":"vi","żulu":"zu","albanski":"sq","amharik":"am","arapski":"ar","armenijski":"hy","azerbajdžanski":"az","bjeloruski":"be","bugarski":"bg","burmanski":"my","češki":"cs","danski":"da","engleski":"en","estonski":"et","finski":"fi","galski":"gl","grčki":"el","haićansko-kreolski":"ht","hebrejski":"he","hindu":"hi","hrvatski":"hr","indonezijski":"id","irski":"ga","islandski":"is","japanski":"ja","katalonski":"ca","kineski (pojednost.)":"zh-cn","kineski (tradicionalni)":"zh-tw","korejski":"ko","kurdski":"ku","latinski":"la","latvijski/letonski":"lv","litvanski":"lt","mađarski":"hu","makedonski":"mk","malezijski":"ms","malteški":"mt","nizozemski":"nl","norveški":"nb","njemački":"de","perzijski":"fa","poljski":"pl","rumunjski":"ro","ruski":"ru","slovački":"sk","slovenski":"sl","srpski":"sr","škotski keltski":"gd","španjolski":"es","švedski":"sv","tajlandski":"th","talijanski":"it","turski":"tr","ukrajinski":"uk","uzbekistanski":"uz","velški":"cy","vijetnamski":"vi","آذرباﻳﺠﺎﻧﻰ":"az","آلبانیایی":"sq","آلمانی":"de","ارمنی":"hy","ازبکی":"uz","اسپانیایی":"es","اسپرانتو":"eo","استونيايی":"et","اسلواکی":"sk","اسلونیایی":"sl","اکراينی":"uk","امهری":"am","اندونزيايی":"id","انگلیسی":"en","ایتالیایی":"it","ایرلندی":"ga","ايسلندی":"is","باسکی":"eu","برمهای":"my","بلاروسی":"be","بلغاری":"bg","پرتغالی":"pt","تايلندی":"th","ترکی استانبولی":"tr","تلوگو":"te","چک":"cs","چینی (سادهشده)":"zh-cn","چینی (سنتی)":"zh-tw","دانمارکی":"da","روسی":"ru","رومانيايی":"ro","زولو":"zu","ژاپنی":"ja","سوئدی":"sv","صربی":"sr","عبری":"he","عربی":"ar","فارسی":"fa","فرانسوی":"fr","فنلاندی":"fi","کاتالان":"ca","کانارا":"kn","کرئول هائیتی":"ht","کردی":"ku","کرواتی":"hr","کرهای":"ko","گالیسی":"gl","گاليک اسکاتلندی":"gd","لاتين":"la","لتونيايی":"lv","لهستانی":"pl","ليتوانيايی":"lt","مائوری":"mi","مالایالمی":"ml","مالايی":"ms","مالتی":"mt","مجاری":"hu","مراتی":"mr","مغولی":"mn","مقدونيهای":"mk","نروژی":"nb","ولزی":"cy","ويتنامی":"vi","هلندی":"nl","هندی":"hi","يونانی":"el","ahepaitani":"az","airihi":"ga","amariki":"am","amēniana":"hy","arapeinia":"sq","arapi":"ar","eperānato":"eo","etōnia":"et","haina (onamata)":"zh-tw","hainamana (kua whakamāmātia)":"zh-cn","hanekeria":"hu","hapanihi":"ja","herepia":"sr","hinerangi":"fi","hīni":"hi","hiperu":"he","horowākia":"sk","horowinia":"sl","huitene":"sv","huru":"zu","ingarihi":"en","initonīhia":"id","itāriana":"it","kanata":"kn","karihia":"gl","katarāna":"ca","kereore haiti":"ht","kiriki":"el","kōreana":"ko","koroātiana":"hr","korukoru":"tr","kūrihi":"ku","makerōnia":"mk","māratihi":"mt","marei":"ms","mareiarama":"ml","mongōriana":"mn","nōwei":"nb","pākihi":"eu","pāniora":"es","pēma (purumīhi)":"my","peraruhia":"be","perēhia":"fa","pōrana":"pl","potukīhi":"pt","purukāriana":"bg","rātini":"la","rāwhiana":"lv","rituānia":"lt","romānia":"ro","rūhia":"ru","tai":"th","tati":"nl","tenemāka":"da","teruku":"te","tiamana":"de","tieke":"cs","tiorangi":"is","tuauri kotarangi":"gd","uhipeke":"uz","ūkareiana":"uk","wēra":"cy","whitināmu":"vi","wīwī":"fr","αγγλικά":"en","αζερμπαϊτζανικά":"az","αλβανικά":"sq","αμχαρικά":"am","αραβικά":"ar","αρμενικά":"hy","βασκικά":"eu","βιετναμεζικά":"vi","βιρμανικά":"my","βουλγαρικά":"bg","γαελικά σκοτίας":"gd","γαλικιακά":"gl","γαλλικά":"fr","γερμανικά":"de","δανικά":"da","εβραϊκά":"he","ελληνικά":"el","εσθονικά":"et","εσπεράντο":"eo","ζουλού":"zu","ιαπωνικά":"ja","ινδονησιακά":"id","ιρλανδικά":"ga","ισλανδικά":"is","ισπανικά":"es","ιταλικά":"it","κανάντα":"kn","καταλανικά":"ca","κινέζικα (απλοποιημένα)":"zh-cn","κινέζικα (παραδοσιακά)":"zh-tw","κορεατικά":"ko","κουρδικά":"ku","κρεόλ αϊτής":"ht","κροατικά":"hr","λατινικά":"la","λετονικά":"lv","λευκορωσικά":"be","λιθουανικά":"lt","μαλαγιάλαμ":"ml","μαλέι":"ms","μαλτεζικά":"mt","μαορί":"mi","μαραθικά":"mr","μογγολικά":"mn","νορβηγικά":"nb","ολλανδικά":"nl","ουαλικά":"cy","ουγγρικά":"hu","ουζμπεκικά":"uz","ουκρανικά":"uk","περσικά":"fa","πολωνικά":"pl","πορτογαλικά":"pt","ρουμανικά":"ro","ρωσικά":"ru","σερβικά":"sr","σλαβομακεδονικά":"mk","σλοβακικά":"sk","σλοβενικά":"sl","σουηδικά":"sv","ταϊλανδεζικά":"th","τελούγκου":"te","τούρκικα":"tr","τσεχικά":"cs","φινλανδικά":"fi","χίντι":"hi","amxar":"am","arman":"hy","bolgar":"bg","dat":"da","fors":"fa","fransuz":"fr","gaiti-kreol":"ht","galisiy":"gl","golland":"nl","grek":"el","ibroniy":"he","indonez":"id","ingliz":"en","irland":"ga","island":"is","italyan":"it","koreys":"ko","kurd (kurmonji)":"ku","latish":"lv","lotin":"la","makedon":"mk","maltiy":"mt","maratxi":"mr","mo‘g‘ul":"mn","nemis":"de","norveg":"nb","ozarbayjon":"az","portugal":"pt","rumin":"ro","tay":"th","turk":"tr","ukrain":"uk","valliy":"cy","venger":"hu","xitoy (an’anaviy)":"zh-tw","xitoy (soddalashgan)":"zh-cn","o‘zbek":"uz","shotland-gel":"gd","shved":"sv","chex":"cs","albanska":"sq","amharísku":"am","arabíska":"ar","armenska":"hy","aserska":"az","baskneska":"eu","búlgarska":"bg","búrmíska":"my","danska":"da","eistneska":"et","enska":"en","esperantó":"eo","finnska":"fi","franska":"fr","galisíska":"gl","gríska":"el","haítískt kreólamál":"ht","hebreska":"he","hindí":"hi","hollenska":"nl","hvítrússneska":"be","indónesíska":"id","írska":"ga","íslenska":"is","ítalska":"it","japanska":"ja","katalónska":"ca","kínverska (einfölduð)":"zh-cn","kínverska (hefðbundin)":"zh-tw","kóreska":"ko","króatíska":"hr","kúrdíska":"ku","latína":"la","lettneska":"lv","litháíska":"lt","makedónska":"mk","malajíska":"ms","maltneska":"mt","maoríska":"mi","maratí":"mr","mongólska":"mn","norska":"nb","persneska":"fa","portúgalska":"pt","pólska":"pl","rúmenska":"ro","rússneska":"ru","serbneska":"sr","skosk-gelíska":"gd","slóvakíska":"sk","slóvenska":"sl","spænska":"es","súlú":"zu","sænska":"sv","taílenska":"th","tékkneska":"cs","tyrkneska":"tr","ungverska":"hu","úkraínska":"uk","úsbekíska":"uz","velska":"cy","víetnamska":"vi","þýska":"de","ադրբեջաներեն":"az","ալբաներեն":"sq","ամհարերեն":"am","անգլերեն":"en","արաբերեն":"ar","բասկերեն":"eu","բելառուսերեն":"be","բիրմաներեն":"my","բուլղարերեն":"bg","գալիսերեն":"gl","գերմաներեն":"de","դանիերեն":"da","եբրայերեն":"he","զուլուսերեն":"zu","էսպերանտո":"eo","էստոներեն":"et","թայերեն":"th","թուրքերեն":"tr","ինդոնեզերեն":"id","իռլանդերեն":"ga","իսլանդերեն":"is","իսպաներեն":"es","իտալերեն":"it","լատիներեն":"la","լատվիերեն":"lv","լեհերեն":"pl","լիտվերեն":"lt","խորվաթերեն":"hr","կաննադա":"kn","կատալաներեն":"ca","կելտական շոտլանդերեն":"gd","կորեերեն":"ko","կրեոլերեն (հայիթի)":"ht","հայերեն":"hy","հինդի":"hi","հոլանդերեն":"nl","հունարեն":"el","հունգարերեն":"hu","ճապոներեն":"ja","մալայալամ":"ml","մալայերեն":"ms","մալթերեն":"mt","մակեդոներեն":"mk","մաորի":"mi","մարաթի":"mr","մոնղոլերեն":"mn","նորվեգերեն":"nb","շվեդերեն":"sv","ուզբեկերեն":"uz","ուկրաիներեն":"uk","չեխերեն":"cs","չինարեն (ավանդական)":"zh-tw","չինարեն (պարզեցված)":"zh-cn","պարսկերեն":"fa","պորտուգալերեն":"pt","ռումիներեն":"ro","ռուսերեն":"ru","սերբերեն":"sr","սլովակերեն":"sk","սլովեներեն":"sl","վալերեն":"cy","վիետնամերեն":"vi","տելուգու":"te","քրդերեն (քուրմանջի)":"ku","ֆիններեն":"fi","ֆրանսերեն":"fr","arabia":"ar","baski":"eu","burma":"my","englanti":"en","espanja":"es","haitinkreoli":"ht","heprea":"he","hollanti":"nl","iiri":"ga","islanti":"is","italia":"it","japani":"ja","katalaani":"ca","kiina (perinteinen)":"zh-tw","kiina (yksinkert.)":"zh-cn","kreikka":"el","kroatia":"hr","kurdi":"ku","kymri":"cy","liettua":"lt","makedonia":"mk","malaiji":"ms","norja":"nb","persia":"fa","portugali":"pt","puola":"pl","ranska":"fr","ruotsi":"sv","saksa":"de","skottigaeli":"gd","slovakia":"sk","suomi":"fi","tanska":"da","tsekki":"cs","turkki":"tr","ukraina":"uk","unkari":"hu","uzbekki":"uz","valkovenäjä":"be","venäjä":"ru","viro":"et","albaniera":"sq","alemana":"de","amharera":"am","arabiera":"ar","armeniera":"hy","azerbaijanera":"az","bielorrusiera":"be","birmaniera":"my","bulgariera":"bg","daniera":"da","errumaniera":"ro","errusiera":"ru","eskoziako gaelera":"gd","eslovakiera":"sk","esloveniera":"sl","esperantoa":"eo","estoniera":"et","euskara":"eu","frantsesa":"fr","gaelera":"cy","galiziera":"gl","gaztelania":"es","greziera":"el","hebreera":"he","hindia":"hi","hungariera":"hu","indonesiera":"id","ingelesa":"en","irlandera":"ga","islandiera":"is","italiera":"it","japoniera":"ja","katalana":"ca","koreera":"ko","kreolera (haiti)":"ht","kroaziera":"hr","kurduera":"ku","letoniera":"lv","lituaniera":"lt","malabarera":"ml","malaysiera":"ms","maltera":"mt","maoriera":"mi","marathera":"mr","mazedoniera":"mk","mongoliera":"mn","nederlandera":"nl","norvegiera":"nb","persiera":"fa","poloniera":"pl","portugesa":"pt","serbiera":"sr","suediera":"sv","suomiera":"fi","telugua":"te","thaiera":"th","turkiera":"tr","txekiera":"cs","txinera (soildua)":"zh-cn","txinera (tradizionala)":"zh-tw","ukrainera":"uk","uzbekera":"uz","vietnamera":"vi","zuluera":"zu","albanès":"sq","alemany":"de","amhàric":"am","anglès":"en","àrab":"ar","armeni":"hy","àzeri":"az","basc":"eu","bielorús":"be","birmà":"my","búlgar":"bg","castellà":"es","català":"ca","coreà":"ko","crioll d\'haití":"ht","croat":"hr","danès":"da","eslovac":"sk","eslovè":"sl","estonià":"et","finès":"fi","francès":"fr","gaèlic escocès":"gd","gallec":"gl","gal·lès":"cy","hebreu":"he","hongarès":"hu","indonesi":"id","irlandès":"ga","islandès":"is","italià":"it","japonès":"ja","letó":"lv","lituà":"lt","llatí":"la","macedònic":"mk","malai":"ms","malaiàlam":"ml","maltès":"mt","neerlandès":"nl","noruec":"nb","polonès":"pl","portuguès":"pt","romanès":"ro","serbi":"sr","suec":"sv","txec":"cs","ucraïnès":"uk","xinès (simplificat)":"zh-cn","xinès (tradicional)":"zh-tw","albāņu":"sq","amharu":"am","angļu":"en","arābu":"ar","armēņu":"hy","azerbaidžāņu":"az","baltkrievu":"be","basku":"eu","birmiešu":"my","bulgāru":"bg","čehu":"cs","dāņu":"da","ebreju (ivrits)":"he","franču":"fr","galisiešu":"gl","grieķu":"el","holandiešu":"nl","horvātu":"hr","igauņu":"et","indonēziešu":"id","īru":"ga","īslandiešu":"is","itāļu":"it","japāņu":"ja","katalāņu":"ca","korejiešu":"ko","kreolu (haiti)":"ht","krievu":"ru","kurdu":"ku","ķīniešu (tradicionālā)":"zh-tw","ķīniešu (vienkāršotā)":"zh-cn","latīņu":"la","latviešu":"lv","lietuviešu":"lt","maķedoniešu":"mk","malajalamiešu":"ml","malajiešu":"ms","maltiešu":"mt","maratu":"mr","mongoļu":"mn","norvēģu":"nb","persiešu":"fa","poļu":"pl","portugāļu":"pt","rumāņu":"ro","serbu":"sr","skotu gēlu":"gd","slovāku":"sk","slovēņu":"sl","somu":"fi","spāņu":"es","taju":"th","turku":"tr","ukraiņu":"uk","ungāru":"hu","uzbeku":"uz","vācu":"de","velsiešu":"cy","vjetnamiešu":"vi","zviedru":"sv","belarussia":"be","cek":"cs","china (aks. sederhana)":"zh-cn","china (aks. tradisional)":"zh-tw","finlandia":"fi","gaelig":"ga","gaelik skotlandia":"gd","galisia":"gl","inggris":"en","islan":"is","jepang":"ja","katala":"ca","lituania":"lt","polandia":"pl","prancis":"fr","rumania":"ro","swensk":"sv","yunani":"el","అజర్బైజాని":"az","అర్మేనియన్":"hy","అల్బేనియన్":"sq","ఆంగ్లము":"en","ఆమ్హారిక్":"am","ఆరబిక్":"ar","ఇండొనేసియన్":"id","ఇటాలియన్":"it","ఉజ్బెక్":"uz","ఎస్పెరాంటో":"eo","ఏస్టోనియన్":"et","ఐరిష్":"ga","ఐస్ లాండిక్":"is","కన్నడ":"kn","కర్డిష్":"ku","కొరియన్":"ko","క్యాటలాన్":"ca","క్రొయేషియన్":"hr","గాలిసియన్":"gl","గ్రీక్":"el","చెక్":"cs","చైనీస్ (సరళమైన)":"zh-cn","చైనీస్ (సామ్ప్రదాయమైన)":"zh-tw","జపనీస్":"ja","జర్మన్":"de","జులు":"zu","టర్కిష్":"tr","డచ్":"nl","డానిష్":"da","తెలుగు":"te","థాయ్":"th","నార్విజియన్":"nb","పర్షియన్":"fa","పోర్చుగీస్":"pt","పోలిష్":"pl","ఫిన్నిష్":"fi","ఫ్రెంచ్":"fr","బర్మీస్":"my","బల్గేరియన్":"bg","బాస్క్":"eu","బెలారుషియన్":"be","మంగోలియన్":"mn","మయోరి":"mi","మరాఠీ":"mr","మలయాళం":"ml","మాలై":"ms","మాల్టీస్":"mt","మాసిడోనియన్":"mk","యుక్రేనియన్":"uk","రష్యన్":"ru","రొమేనియన్":"ro","లాటిన్":"la","లాట్వియన్":"lv","లిథువేనియన్":"lt","వియత్నామీస్":"vi","వెల్ష్":"cy","సెర్బియన్":"sr","స్కాట్స్ గేలిక్":"gd","స్పానిష్":"es","స్లోవక్":"sk","స్లోవేనియన్":"sl","స్వీడిష్":"sv","హంగేరియన్":"hu","హిందీ":"hi","హీబ్రూ":"he","హైయేటియన్ క్రియోల్":"ht","amhárico":"am","azerí":"az","chino (simplificado)":"zh-cn","chino (tradicional)":"zh-tw","criollo haitiano":"ht","danés":"da","estonio":"et","euskera":"eu","finlandés":"fi","gallego":"gl","griego":"el","japonés":"ja","kurdo":"ku","malayo":"ms","noruego":"nb","rumano":"ro","uzbeco":"uz","albaania":"sq","amhaari":"am","araabia":"ar","armeenia":"hy","aserbaidžaani":"az","birma":"my","bulgaaria":"bg","eesti":"et","galeegi":"gl","haitikreooli":"ht","heebrea":"he","hispaania":"es","hollandi":"nl","horvaadi":"hr","indoneesia":"id","inglise":"en","islandi":"is","itaalia":"it","jaapani":"ja","kreeka":"el","ladina":"la","leedu":"lt","lihtsustatud hiina":"zh-cn","läti":"lv","makedoonia":"mk","malajalaami":"ml","maoori":"mi","mongoli":"mn","norra":"nb","poola":"pl","prantsuse":"fr","pärsia":"fa","rootsi":"sv","rumeenia":"ro","slovaki":"sk","sloveeni":"sl","soome":"fi","suulu":"zu","šoti":"gd","taani":"da","traditsiooniline hiina":"zh-tw","tšehhi":"cs","türgi":"tr","uelsi":"cy","ungari":"hu","usbeki":"uz","valgevene":"be","vene":"ru","albanyen":"sq","amenyen":"hy","anglè":"en","azèbajani":"az","belarisyen":"be","bilgaryen":"bg","chinwa (senp)":"zh-cn","chinwa (tradisyonèl)":"zh-tw","danwa":"da","ebre":"he","endonezyen":"id","endou":"hi","estonyen":"et","fenlandè":"fi","franse":"fr","gaelik ekosè":"gd","galisyen":"gl","grèk":"el","ikrenyen":"uk","ilandè":"ga","islandè":"is","italyen":"it","izbèk":"uz","japonè":"ja","koreyen":"ko","kreyòl ayisyen":"ht","kurde (kurmandji)":"ku","kwoasyen":"hr","laten":"la","letonyen":"lv","lityanyen":"lt","malè":"ms","malt":"mt","masedonyen":"mk","mongolyen":"mn","myanma (burmese)":"my","nòvejyen":"nb","olandè, neyèlandè":"nl","onngaryen":"hu","panyòl":"es","pèsyen":"fa","polonè":"pl","pòtigè":"pt","ris":"ru","romanyen":"ro","sèb":"sr","slovenyen":"sl","syedwa":"sv","tuk":"tr","tyèk":"cs","vyetnamyen":"vi","albaneg":"sq","almaeneg":"de","arabeg":"ar","armeneg":"hy","aserbaijaneg":"az","basgeg":"eu","belarwseg":"be","bwlgaraidd":"bg","catalaneg":"ca","creol haiti":"ht","croateg":"hr","cymraeg":"cy","cyrdeg (kurmandji)":"ku","daneg":"da","eidaleg":"it","estoneg":"et","fietnameg":"vi","ffineg":"fi","fflemeg":"nl","ffrangeg":"fr","gaeleg yr alban":"gd","galisaidd":"gl","groeg":"el","gwyddeleg":"ga","hebraeg":"he","hwngareg":"hu","iaith corea":"ko","indonesieg":"id","islandeg":"is","iwcraineg":"uk","japaneg":"ja","latfieg":"lv","lithwaneg":"lt","lladin":"la","macedoneg":"mk","malteseg":"mt","mongoleg":"mn","myanmar (byrma)":"my","norwyeg":"nb","perseg":"fa","portiwgaleg":"pt","pwyleg":"pl","rwmaneg":"ro","rwsieg":"ru","saesneg":"en","sbaeneg":"es","serbeg":"sr","slofac":"sk","slofenia":"sl","swedeg":"sv","swlw":"zu","tsieceg":"cs","tsieineeg (traddodiadol)":"zh-tw","tsieineeg (wedi symleiddio)":"zh-cn","twrceg":"tr","usbec":"uz","अंग्रेज़ी":"en","अज़रबैजानी":"az","अल्बेनियन":"sq","आइसलैंडिक":"is","आर्मेनियन":"hy","इटैलियन":"it","उज़्बेक":"uz","एस्तोनियन":"et","एस्पेरांटो":"eo","ऐम्हेरिक":"am","कन्नड़":"kn","कुर्दिश (करमंजी)":"ku","कैटेलन":"ca","गैलिशियन":"gl","चीनी (परंपरागत)":"zh-tw","चेक":"cs","जापानी":"ja","ज़ुलु":"zu","डैनिश":"da","तुर्क":"tr","तेलुगु":"te","पुर्तगाली":"pt","फ़िनिश":"fi","फ़्रेंच":"fr","बर्मी":"my","बुल्गारियन":"bg","बेलारूसीयन":"be","बैस्क":"eu","मलयालम":"ml","माऔरी":"mi","माल्टी":"mt","मेसीडोनियन":"mk","यूक्रेनियन":"uk","रूसी":"ru","रोमेनियन":"ro","लातवियन":"lv","लैटिन":"la","वियतनामी":"vi","सर्बियाई":"sr","स्पैनिश":"es","स्लोवाक":"sk","स्लोवेनियन":"sl","हंगरियन":"hu","हीब्रू":"he","हैतियन क्रिओल":"ht","阿尔巴尼亚语":"sq","阿拉伯语":"ar","阿姆哈拉语":"am","阿塞拜疆语":"az","爱尔兰语":"ga","爱沙尼亚语":"et","巴斯克语":"eu","白俄罗斯语":"be","保加利亚语":"bg","冰岛语":"is","波兰语":"pl","波斯语":"fa","丹麦语":"da","德语":"de","俄语":"ru","法语":"fr","芬兰语":"fi","海地克里奥尔语":"ht","韩语":"ko","荷兰语":"nl","加利西亚语":"gl","加泰罗尼亚语":"ca","捷克语":"cs","卡纳达语":"kn","克罗地亚语":"hr","库尔德语":"ku","拉丁语":"la","拉脱维亚语":"lv","立陶宛语":"lt","罗马尼亚语":"ro","马耳他语":"mt","马拉地语":"mr","马拉雅拉姆语":"ml","马来语":"ms","马其顿语":"mk","毛利语":"mi","蒙古语":"mn","缅甸语":"my","南非祖鲁语":"zu","挪威语":"nb","葡萄牙语":"pt","日语":"ja","瑞典语":"sv","塞尔维亚语":"sr","世界语":"eo","斯洛伐克语":"sk","斯洛文尼亚语":"sl","苏格兰盖尔语":"gd","泰卢固语":"te","泰语":"th","土耳其语":"tr","威尔士语":"cy","乌克兰语":"uk","乌兹别克语":"uz","西班牙语":"es","希伯来语":"he","希腊语":"el","匈牙利语":"hu","亚美尼亚语":"hy","意大利语":"it","印地语":"hi","印尼语":"id","英语":"en","越南语":"vi","中文(繁体)":"zh-tw","中文(简体)":"zh-cn","азербайджански":"az","английски":"en","арабски":"ar","арменски":"hy","баски":"eu","беларуски":"be","бирмански":"my","български":"bg","галисийски":"gl","гръцки":"el","датски":"da","индонезийски":"id","ирландски":"ga","испански":"es","италиански":"it","китайски (опростен)":"zh-cn","китайски (традиционен)":"zh-tw","корейски":"ko","кюрдски":"ku","латвийски":"lv","литовски":"lt","малайски":"ms","малтийски":"mt","немски":"de","нидерландски":"nl","норвежки":"nb","персийски":"fa","румънски":"ro","словашки":"sk","словенски":"sl","сръбски":"sr","тайландски":"th","уелски":"cy","узбекски":"uz","финландски":"fi","френски":"fr","хаитянски креолски":"ht","хърватски":"hr","шотландски келтски":"gd","японски":"ja","الآيسلندية":"is","الأذرية":"az","الارمنية":"hy","الإسبانية":"es","الاسبرانتو":"eo","الإستونية":"et","الاسكتلندية الغالية":"gd","الألبانية":"sq","الألمانية":"de","الأمهرية":"am","الإنجليزية":"en","الإندونيسية":"id","الأوزبكية":"uz","الأوكرانية":"uk","الأيرلندية":"ga","الإيطالية":"it","الباسكية":"eu","البرتغالية":"pt","البلغارية":"bg","البورمية":"my","البولندية":"pl","البيلاروسية":"be","التايلاندية":"th","التركية":"tr","التشيكية":"cs","التيلوجو":"te","الجاليكية":"gl","الدانماركية":"da","الروسية":"ru","الرومانية":"ro","الزولوية":"zu","السلوفاكية":"sk","السلوفينية":"sl","السويدية":"sv","الصربية":"sr","الصينية (التقليدية)":"zh-tw","الصينية (المبسطة)":"zh-cn","العبرية":"he","العربية":"ar","الفارسية":"fa","الفرنسية":"fr","الفنلندية":"fi","الفيتنامية":"vi","القطلونية":"ca","الكانادا":"kn","الكردية":"ku","الكرواتية":"hr","الكورية":"ko","اللاتفية":"lv","اللاتينية":"la","اللغة الكريولية الهايتية":"ht","الليتوانية":"lt","المالايالامية":"ml","المالطيّة":"mt","الماورية":"mi","المقدونية":"mk","الملايو":"ms","المنغولية":"mn","المهراتية":"mr","النرويجية":"nb","الهندية":"hi","الهنغارية":"hu","الهولندية":"nl","الويلزية":"cy","اليابانية":"ja","اليونانية":"el","баскијски":"eu","вијетнамски":"vi","галски":"gl","енглески":"en","индонежански":"id","јапански":"ja","јерменски":"hy","кинески (поједностављени)":"zh-cn","кинески (традиционални)":"zh-tw","креолски (хаити)":"ht","летонски":"lv","мађарски":"hu","марати":"mr","немачки":"de","персијски":"fa","пољски":"pl","румунски":"ro","словеначки":"sl","тајски":"th","украјински":"uk","азербайжан":"az","албани":"sq","амхарик":"am","англи":"en","араб":"ar","армени":"hy","баск":"eu","беларусь":"be","бирм":"my","болгар":"bg","вьетнам":"vi","гаити креол":"ht","галик":"gl","гаэл":"gd","герман":"de","голланд":"nl","грек":"el","дани":"da","индонези":"id","ирланд":"ga","исланд":"is","испани":"es","итали":"it","каталан":"ca","кипр":"he","курд":"ku","латви":"lv","латин":"la","литва":"lt","македон":"mk","малай":"ms","малайлам":"ml","малти":"mt","монгол":"mn","норвеги":"nb","орос":"ru","перс":"fa","польш":"pl","португаль":"pt","румын":"ro","серби":"sr","словак":"sk","словени":"sl","солонгос":"ko","тай":"th","турк":"tr","тэлүгү":"te","узбек":"uz","украин":"uk","унгар":"hu","уэльс":"cy","финлянд":"fi","франц":"fr","хорват":"hr","хятад (ердийн)":"zh-cn","хятад (уламжлалт)":"zh-tw","чех":"cs","швед":"sv","эстони":"et","япон":"ja","amhariska":"am","arabiska":"ar","armeniska":"hy","azerbajdzjanska":"az","baskiska":"eu","bulgariska":"bg","burmesiska":"my","engelska":"en","estniska":"et","finska":"fi","gaeliska":"gd","galiciska":"gl","grekiska":"el","haitiska":"ht","hebreiska":"he","indonesiska":"id","irländska":"ga","isländska":"is","italienska":"it","kanaresiska":"kn","katalanska":"ca","kinesiska (förenklad)":"zh-cn","kinesiska (traditionell)":"zh-tw","koreanska":"ko","kroatiska":"hr","kurdiska":"ku","lettiska":"lv","litauiska":"lt","makedonska":"mk","malaysiska":"ms","maltesiska":"mt","mongoliska":"mn","nederländska":"nl","persiska":"fa","polska":"pl","portugisiska":"pt","rumänska":"ro","ryska":"ru","serbiska":"sr","slovakiska":"sk","slovenska":"sl","spanska":"es","svenska":"sv","thailändska":"th","tjeckiska":"cs","turkiska":"tr","tyska":"de","ukrainska":"uk","ungerska":"hu","uzbekiska":"uz","vietnamesiska":"vi","vitryska":"be","walesiska":"cy","albaneză":"sq","amharică":"am","arabă":"ar","armeană":"hy","azerbaidjană":"az","bască":"eu","bielorusă":"be","birmană":"my","bulgară":"bg","catalană":"ca","cehă":"cs","chineză (simplificată)":"zh-cn","chineză (tradițională)":"zh-tw","coreeană":"ko","creolă haitiană":"ht","croată":"hr","daneză":"da","ebraică":"he","engleză":"en","estonă":"et","finlandeză":"fi","franceză":"fr","galeză":"cy","galica scoțiană":"gd","galiciană":"gl","germană":"de","greacă":"el","indoneziană":"id","irlandeză":"ga","islandeză":"is","italiană":"it","japoneză":"ja","kurdă":"ku","latină":"la","letonă":"lv","lituaniană":"lt","macedoneană":"mk","maghiară":"hu","malaeză":"ms","malteză":"mt","mongolă":"mn","neerlandeză":"nl","norvegiană":"nb","persană":"fa","poloneză":"pl","portugheză":"pt","română":"ro","rusă":"ru","sârbă":"sr","slovacă":"sk","slovenă":"sl","spaniolă":"es","suedeză":"sv","thailandeză":"th","turcă":"tr","ucraineană":"uk","uzbecă":"uz","vietnameză":"vi","airių":"ga","albanų":"sq","amharų":"am","anglų":"en","arabų":"ar","armėnų":"hy","azerbaidžaniečių":"az","baltarusių":"be","baskų":"eu","birmiečių":"my","bulgarų":"bg","čekų":"cs","danų":"da","estų":"et","galisų":"gl","graikų":"el","haičio kreolų":"ht","hebrajų":"he","indoneziečių":"id","islandų":"is","ispanų":"es","italų":"it","japonų":"ja","kanadų":"kn","kataloniečių":"ca","kinų (supaprastinta)":"zh-cn","kinų (tradicinė)":"zh-tw","korėjiečių":"ko","kroatų":"hr","kurdų":"ku","latvių":"lv","lenkų":"pl","lietuvių":"lt","lotynų":"la","makedoniečių":"mk","malajalių":"ml","malajiečių":"ms","maltiečių":"mt","maorių":"mi","maratų":"mr","mongolų":"mn","norvegų":"nb","olandų":"nl","persų":"fa","portugalų":"pt","prancūzų":"fr","rumunų":"ro","rusų":"ru","serbų":"sr","slovakų":"sk","slovėnų":"sl","suomių":"fi","škotų (gėlų)":"gd","švedų":"sv","tajų":"th","telugų":"te","turkų":"tr","ukrainiečių":"uk","uzbekų":"uz","valų":"cy","vengrų":"hu","vietnamiečių":"vi","vokiečių":"de","zulusų":"zu","갈리시아어":"gl","그리스어":"el","네덜란드어":"nl","노르웨이어":"nb","덴마크어":"da","독일어":"de","라트비아어":"lv","라틴어":"la","러시아어":"ru","루마니아어":"ro","리투아니아어":"lt","마라티어":"mr","마오리어":"mi","마케도니아어":"mk","말라얄람어":"ml","말레이어":"ms","몰타어":"mt","몽골어":"mn","미얀마어 (버마어)":"my","바스크어":"eu","베트남어":"vi","벨라루스어":"be","불가리아어":"bg","세르비아어":"sr","스웨덴어":"sv","스코틀랜드 게일어":"gd","스페인어":"es","슬로바키아어":"sk","슬로베니아어":"sl","아랍어":"ar","아르메니아어":"hy","아이슬란드어":"is","아이티 크리올어":"ht","아일랜드어":"ga","아제르바이잔어":"az","알바니아어":"sq","암하라어":"am","에스토니아어":"et","에스페란토어":"eo","영어":"en","우즈베크어":"uz","우크라이나어":"uk","웨일즈어":"cy","이탈리아어":"it","인도네시아어":"id","일본어":"ja","줄루어":"zu","중국어(간체)":"zh-cn","중국어(번체)":"zh-tw","체코어":"cs","카탈로니아어":"ca","칸나다어":"kn","쿠르드어":"ku","크로아티아어":"hr","태국어":"th","터키어":"tr","텔루구어":"te","페르시아어":"fa","포르투갈어":"pt","폴란드어":"pl","프랑스어":"fr","핀란드어":"fi","한국어":"ko","헝가리어":"hu","히브리어":"he","힌디어":"hi","albanese":"sq","amarico":"am","arabo":"ar","armeno":"hy","azero":"az","bielorusso":"be","bulgaro":"bg","catalano":"ca","ceco":"cs","cinese (semplificato)":"zh-cn","cinese (tradizionale)":"zh-tw","creolo haitiano":"ht","croato":"hr","curdo (kurmanji)":"ku","danese":"da","ebraico":"he","estone":"et","finlandese":"fi","francese":"fr","gaelico scozzese":"gd","galiziano":"gl","gallese":"cy","giapponese":"ja","greco":"el","indonesiano":"id","inglese":"en","irlandese":"ga","islandese":"is","latino":"la","lettone":"lv","macedone":"mk","malese":"ms","mongolo":"mn","norvegese":"nb","olandese":"nl","persiano":"fa","polacco":"pl","portoghese":"pt","rumeno":"ro","serbo":"sr","slovacco":"sk","sloveno":"sl","spagnolo":"es","svedese":"sv","tailandese":"th","tedesco":"de","ucraino":"uk","ungherese":"hu","quốc tế ngữ":"eo","tiếng ả rập":"ar","tiếng albania":"sq","tiếng amharic":"am","tiếng anh":"en","tiếng armenia":"hy","tiếng azerbaijan":"az","tiếng ba lan":"pl","tiếng ba tư":"fa","tiếng basque":"eu","tiếng belarus":"be","tiếng bồ đào nha":"pt","tiếng bulgaria":"bg","tiếng catalan":"ca","tiếng creole ở haiti":"ht","tiếng croatia":"hr","tiếng do thái":"he","tiếng đan mạch":"da","tiếng đức":"de","tiếng estonia":"et","tiếng gael scotland":"gd","tiếng galicia":"gl","tiếng hà lan":"nl","tiếng hàn":"ko","tiếng hindi":"hi","tiếng hungary":"hu","tiếng hy lạp":"el","tiếng iceland":"is","tiếng indonesia":"id","tiếng ireland":"ga","tiếng kannada":"kn","tiếng kurd":"ku","tiếng latinh":"la","tiếng latvia":"lv","tiếng litva":"lt","tiếng mã lai":"ms","tiếng macedonia":"mk","tiếng malayalam":"ml","tiếng malta":"mt","tiếng maori":"mi","tiếng marathi":"mr","tiếng mông cổ":"mn","tiếng myanmar":"my","tiếng na uy":"nb","tiếng nga":"ru","tiếng nhật":"ja","tiếng pháp":"fr","tiếng phần lan":"fi","tiếng rumani":"ro","tiếng séc":"cs","tiếng serbia":"sr","tiếng slovak":"sk","tiếng slovenia":"sl","tiếng tây ban nha":"es","tiếng telugu":"te","tiếng thái":"th","tiếng thổ nhĩ kỳ":"tr","tiếng thụy điển":"sv","tiếng trung (giản thể)":"zh-cn","tiếng trung (phồn thể)":"zh-tw","tiếng ukraina":"uk","tiếng uzbek":"uz","tiếng việt":"vi","tiếng xứ wales":"cy","tiếng ý":"it","tiếng zulu":"zu","にほんご":"ja"},"scratchToGoogleMap":{"zh-cn":"zh","nb":"no","he":"iw","es-419":"es","pt-br":"pt","ja-hira":"ja"},"previouslySupported":["ab","ms","be","eo","hy","hi","kn","ht","ku","la","mk","ml","mt","mr","mn","my","nn","sq","te","uz"]}')},function(t,e,n){"use strict";n.r(e),n.d(e,"_parse",(function(){return r})),n.d(e,"parse",(function(){return i})),n.d(e,"stringify",(function(){return s}));const r=t=>{let e=0;const n=n=>{const{line:r,column:i}=(()=>{let n=0,r=0;for(let i=0;i(e>=t.length&&n("Unexpected end of input"),t[e]),i=()=>r(e),s=()=>{e++},o=t=>{i()!==t&&n(`Expected '${t}' but found '${i()}'`),s()},a=(n=1,i=1)=>{if(e+i+n>t.length)return"";if(1===n)return r(e+i);let s="";for(let t=0;t{for(;;)if(/\s/.test(i()))s();else{const t=a(2,0);if("//"===t)for(s(),s();"\n"!==i();)s();else{if("/*"!==t)break;for(s(),s();"*/"!==a(2,0);)s();s(),s()}}},u=()=>{c();switch(i()){case'"':return d();case"{":return f();case"[":return p();case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"-":return h();default:return l()}},l=()=>{if("null"===a(4,0)){for(let t=0;t<4;t++)s();return null}if("true"===a(4,0)){for(let t=0;t<4;t++)s();return!0}if("false"===a(5,0)){for(let t=0;t<5;t++)s();return!1}if("Infinity"===a(8,0)){for(let t=0;t<8;t++)s();return 1/0}if("NaN"===a(3,0)){for(let t=0;t<3;t++)s();return NaN}n(`Unexpected character '${i()}'`)},h=()=>{if("-Infinity"===a(9,0)){for(let t=0;t<9;t++)s();return-1/0}let t="";for(;t+=i(),/[\d.e+-]/i.test(a());)s();s();const e=+t;return Number.isNaN(e)&&n(`Not a number: ${t}`),e},d=()=>{o('"');let t="";for(;;){const e=i();if('"'===e)break;if("\\"===e)switch(s(),i()){case'"':t+='"';break;case"/":t+="/";break;case"\\":t+="\\";break;case"b":t+="\b";break;case"f":t+="\f";break;case"n":t+="\n";break;case"r":t+="\r";break;case"t":t+="\t";break;case"u":{let e="";for(let t=0;t<4;t++){s();const t=i();/[0-9a-f]/i.test(t)||n(`Invalid hex code: ${t}`),e+=t}const r=Number.parseInt(e,16);t+=String.fromCharCode(r);break}default:n(`Invalid escape code: \\${i()}`)}else t+=e;s()}return o('"'),t},p=()=>{o("["),c();const t=[];for(;c(),"]"!==i();){const e=u();if(t.push(e),c(),","!==i())break;s()}return o("]"),t},f=()=>{o("{"),c();const t={};for(;c(),"}"!==i();){const e=d();c(),o(":");const n=u();if(t[e]=n,c(),","!==i())break;s()}return o("}"),t};return u()},i=t=>{try{return JSON.parse(t)}catch(e){try{return r(t)}catch(t){throw e}}},s=t=>{if("string"==typeof t)return JSON.stringify(t);if("number"==typeof t||"boolean"==typeof t)return t.toString();if(null==t||"symbol"==typeof t)return"null";if(Array.isArray(t))return`[${t.map((t=>s(t))).join(",")}]`;if("object"==typeof t){let e="{",n=!0;const r=Object.keys(t);for(let i=0;i("string"!=typeof t&&(r.warn("sanitize got unexpected type: ".concat(typeof t)),t=""+t),JSON.stringify(t).slice(1,-1)),d="runtime.ext_pen",p="".concat(d,"._getPenState(target)"),f=new o("factory"),m=new o("fun"),g=new o("gen");class b{constructor(t,e){if("number"!=typeof e)throw new Error("type is invalid");this.source=t,this.type=e}asNumber(){return 1===this.type?this.source:5===this.type?"(".concat(this.source," || 0)"):"(+".concat(this.source," || 0)")}asNumberOrNaN(){return 1===this.type||5===this.type?this.source:"(+".concat(this.source,")")}asString(){return 2===this.type?this.source:'("" + '.concat(this.source,")")}asBoolean(){return 3===this.type?this.source:"toBoolean(".concat(this.source,")")}asColor(){return this.asUnknown()}asUnknown(){return this.source}asSafe(){return this.asUnknown()}isAlwaysNumber(){return 1===this.type}isAlwaysNumberOrNaN(){return 1===this.type||5===this.type}isNeverNumber(){return!1}}class y{constructor(t,e){this.constantValue=t,this.safe=e}asNumber(){const t=+this.constantValue;return t?t.toString():Object.is(t,-0)?"-0":"0"}asNumberOrNaN(){return this.asNumber()}asString(){return'"'.concat(h(""+this.constantValue),'"')}asBoolean(){return i.toBoolean(this.constantValue).toString()}asColor(){if(/^#[0-9a-f]{6,8}$/i.test(this.constantValue)){const t=this.constantValue.substr(1);return Number.parseInt(t,16).toString()}return this.asUnknown()}asUnknown(){if("number"==typeof this.constantValue)return this.constantValue;return(+this.constantValue).toString()===this.constantValue?this.constantValue:this.asString()}asSafe(){return this.safe?this.asUnknown():this.asString()}isAlwaysNumber(){const t=+this.constantValue;return!Number.isNaN(t)&&(0!==t||""!==this.constantValue.toString().trim())}isAlwaysNumberOrNaN(){return this.isAlwaysNumber()}isNeverNumber(){return Number.isNaN(+this.constantValue)}}class v{constructor(t){this.source=t,this.type=4,this._value=null}setInput(t){if(t instanceof v){if(!t._value)return this.type=4,void(this._value=null);t=t._value}this._value=t,this.type=t instanceof b?t.type:4}asNumber(){return 1===this.type?this.source:5===this.type?"(".concat(this.source," || 0)"):"(+".concat(this.source," || 0)")}asNumberOrNaN(){return 1===this.type||5===this.type?this.source:"(+".concat(this.source,")")}asString(){return 2===this.type?this.source:'("" + '.concat(this.source,")")}asBoolean(){return 3===this.type?this.source:"toBoolean(".concat(this.source,")")}asColor(){return this.asUnknown()}asUnknown(){return this.source}asSafe(){return this.asUnknown()}isAlwaysNumber(){return!!this._value&&this._value.isAlwaysNumber()}isAlwaysNumberOrNaN(){return!!this._value&&this._value.isAlwaysNumberOrNaN()}isNeverNumber(){return!!this._value&&this._value.isNeverNumber()}}const w=t=>{const e=+t.constantValue;return!!e&&e.toString()===t.constantValue.toString()};class T{constructor(t){this.isLoop=t,this.isLastBlock=!1}}class E{constructor(t,e,n){this.script=t,this.ir=e,this.target=n,this.source="",this.variableInputs={},this.isWarp=t.isWarp,this.isProcedure=t.isProcedure,this.warpTimer=t.warpTimer,this.frames=[],this.currentFrame=null,this.namesOfCostumesAndSounds=(t=>{const e=new Set;for(const n of t.targets)if(n.isOriginal){const t=n.sprite;for(const n of t.costumes)e.add(n.name);for(const n of t.sounds)e.add(n.name)}return e})(n.runtime),this.localVariables=new o("a"),this._setupVariablesPool=new o("b"),this._setupVariables={},this.descendedIntoModulo=!1,this.isInHat=!1,this.debug=this.target.runtime.debug}pushFrame(t){this.frames.push(t),this.currentFrame=t}popFrame(){this.frames.pop(),this.currentFrame=this.frames[this.frames.length-1]}isLastBlockInLoop(){for(let t=this.frames.length-1;t>=0;t--){const e=this.frames[t];if(!e.isLastBlock)return!1;if(e.isLoop)return!0}return!1}descendInput(t){switch(t.kind){case"addons.call":return new b("(".concat(this.descendAddonCall(t),")"),4);case"compat":return new b("(".concat(this.generateCompatibilityLayerCall(t,!1),")"),4);case"constant":return this.safeConstantInput(t.value);case"counter.get":return new b("runtime.ext_scratch3_control._counter",1);case"keyboard.pressed":return new b("runtime.ioDevices.keyboard.getKeyIsDown(".concat(this.descendInput(t.key).asSafe(),")"),3);case"list.contains":return new b("listContains(".concat(this.referenceVariable(t.list),", ").concat(this.descendInput(t.item).asUnknown(),")"),3);case"list.contents":return new b("listContents(".concat(this.referenceVariable(t.list),")"),2);case"list.get":{const e=this.descendInput(t.index);if(c.supportsNullishCoalescing){if(e.isAlwaysNumberOrNaN())return new b("(".concat(this.referenceVariable(t.list),".value[(").concat(e.asNumber(),' | 0) - 1] ?? "")'),4);if(e instanceof y&&"last"===e.constantValue)return new b("(".concat(this.referenceVariable(t.list),".value[").concat(this.referenceVariable(t.list),'.value.length - 1] ?? "")'),4)}return new b("listGet(".concat(this.referenceVariable(t.list),".value, ").concat(e.asUnknown(),")"),4)}case"list.indexOf":return new b("listIndexOf(".concat(this.referenceVariable(t.list),", ").concat(this.descendInput(t.item).asUnknown(),")"),1);case"list.length":return new b("".concat(this.referenceVariable(t.list),".value.length"),1);case"looks.size":return new b("Math.round(target.size)",1);case"looks.backdropName":return new b("stage.getCostumes()[stage.currentCostume].name",2);case"looks.backdropNumber":return new b("(stage.currentCostume + 1)",1);case"looks.costumeName":return new b("target.getCostumes()[target.currentCostume].name",2);case"looks.costumeNumber":return new b("(target.currentCostume + 1)",1);case"motion.direction":return new b("target.direction",1);case"motion.x":return new b("limitPrecision(target.x)",1);case"motion.y":return new b("limitPrecision(target.y)",1);case"mouse.down":return new b("runtime.ioDevices.mouse.getIsDown()",3);case"mouse.x":return new b("runtime.ioDevices.mouse.getScratchX()",1);case"mouse.y":return new b("runtime.ioDevices.mouse.getScratchY()",1);case"noop":return new b('""',2);case"op.abs":return new b("Math.abs(".concat(this.descendInput(t.value).asNumber(),")"),1);case"op.acos":return new b("((Math.acos(".concat(this.descendInput(t.value).asNumber(),") * 180) / Math.PI)"),5);case"op.add":return new b("(".concat(this.descendInput(t.left).asNumber()," + ").concat(this.descendInput(t.right).asNumber(),")"),5);case"op.and":return new b("(".concat(this.descendInput(t.left).asBoolean()," && ").concat(this.descendInput(t.right).asBoolean(),")"),3);case"op.asin":return new b("((Math.asin(".concat(this.descendInput(t.value).asNumber(),") * 180) / Math.PI)"),5);case"op.atan":return new b("((Math.atan(".concat(this.descendInput(t.value).asNumber(),") * 180) / Math.PI)"),1);case"op.ceiling":return new b("Math.ceil(".concat(this.descendInput(t.value).asNumber(),")"),1);case"op.contains":return new b("(".concat(this.descendInput(t.string).asString(),".toLowerCase().indexOf(").concat(this.descendInput(t.contains).asString(),".toLowerCase()) !== -1)"),3);case"op.cos":return new b("(Math.round(Math.cos((Math.PI * ".concat(this.descendInput(t.value).asNumber(),") / 180) * 1e10) / 1e10)"),5);case"op.divide":return new b("(".concat(this.descendInput(t.left).asNumber()," / ").concat(this.descendInput(t.right).asNumber(),")"),5);case"op.equals":{const e=this.descendInput(t.left),n=this.descendInput(t.right);if(e.isNeverNumber()||n.isNeverNumber())return new b("(".concat(e.asString(),".toLowerCase() === ").concat(n.asString(),".toLowerCase())"),3);const r=e.isAlwaysNumber(),i=n.isAlwaysNumber();return r&&i||(r&&e instanceof y&&w(e)||i&&n instanceof y&&w(n))?new b("(".concat(e.asNumber()," === ").concat(n.asNumber(),")"),3):new b("compareEqual(".concat(e.asUnknown(),", ").concat(n.asUnknown(),")"),3)}case"op.e^":return new b("Math.exp(".concat(this.descendInput(t.value).asNumber(),")"),1);case"op.floor":return new b("Math.floor(".concat(this.descendInput(t.value).asNumber(),")"),1);case"op.greater":{const e=this.descendInput(t.left),n=this.descendInput(t.right);return e.isAlwaysNumber()&&n.isAlwaysNumberOrNaN()?new b("(".concat(e.asNumber()," > ").concat(n.asNumberOrNaN(),")"),3):e.isAlwaysNumberOrNaN()&&n.isAlwaysNumber()?new b("!(".concat(e.asNumberOrNaN()," <= ").concat(n.asNumber(),")"),3):e.isNeverNumber()||n.isNeverNumber()?new b("(".concat(e.asString(),".toLowerCase() > ").concat(n.asString(),".toLowerCase())"),3):new b("compareGreaterThan(".concat(e.asUnknown(),", ").concat(n.asUnknown(),")"),3)}case"op.join":return new b("(".concat(this.descendInput(t.left).asString()," + ").concat(this.descendInput(t.right).asString(),")"),2);case"op.length":return new b("".concat(this.descendInput(t.string).asString(),".length"),1);case"op.less":{const e=this.descendInput(t.left),n=this.descendInput(t.right);return e.isAlwaysNumberOrNaN()&&n.isAlwaysNumber()?new b("(".concat(e.asNumberOrNaN()," < ").concat(n.asNumber(),")"),3):e.isAlwaysNumber()&&n.isAlwaysNumberOrNaN()?new b("!(".concat(e.asNumber()," >= ").concat(n.asNumberOrNaN(),")"),3):e.isNeverNumber()||n.isNeverNumber()?new b("(".concat(e.asString(),".toLowerCase() < ").concat(n.asString(),".toLowerCase())"),3):new b("compareLessThan(".concat(e.asUnknown(),", ").concat(n.asUnknown(),")"),3)}case"op.letterOf":return new b("((".concat(this.descendInput(t.string).asString(),")[(").concat(this.descendInput(t.letter).asNumber(),' | 0) - 1] || "")'),2);case"op.ln":return new b("Math.log(".concat(this.descendInput(t.value).asNumber(),")"),5);case"op.log":return new b("(Math.log(".concat(this.descendInput(t.value).asNumber(),") / Math.LN10)"),5);case"op.mod":return this.descendedIntoModulo=!0,new b("mod(".concat(this.descendInput(t.left).asNumber(),", ").concat(this.descendInput(t.right).asNumber(),")"),5);case"op.multiply":return new b("(".concat(this.descendInput(t.left).asNumber()," * ").concat(this.descendInput(t.right).asNumber(),")"),5);case"op.not":return new b("!".concat(this.descendInput(t.operand).asBoolean()),3);case"op.or":return new b("(".concat(this.descendInput(t.left).asBoolean()," || ").concat(this.descendInput(t.right).asBoolean(),")"),3);case"op.random":return t.useInts?new b("randomInt(".concat(this.descendInput(t.low).asNumber(),", ").concat(this.descendInput(t.high).asNumber(),")"),1):t.useFloats?new b("randomFloat(".concat(this.descendInput(t.low).asNumber(),", ").concat(this.descendInput(t.high).asNumber(),")"),5):new b("runtime.ext_scratch3_operators._random(".concat(this.descendInput(t.low).asUnknown(),", ").concat(this.descendInput(t.high).asUnknown(),")"),5);case"op.round":return new b("Math.round(".concat(this.descendInput(t.value).asNumber(),")"),1);case"op.sin":return new b("(Math.round(Math.sin((Math.PI * ".concat(this.descendInput(t.value).asNumber(),") / 180) * 1e10) / 1e10)"),5);case"op.sqrt":return new b("Math.sqrt(".concat(this.descendInput(t.value).asNumber(),")"),5);case"op.subtract":return new b("(".concat(this.descendInput(t.left).asNumber()," - ").concat(this.descendInput(t.right).asNumber(),")"),5);case"op.tan":return new b("tan(".concat(this.descendInput(t.value).asNumber(),")"),5);case"op.10^":return new b("(10 ** ".concat(this.descendInput(t.value).asNumber(),")"),1);case"procedures.call":{const e=t.code,n=t.variant,r=this.ir.procedures[n];if(null===r.stack)return new b('""',2);const i='thread.procedures["'.concat(h(n),'"]'),s=[];for(const e of t.arguments)s.push(this.descendInput(e).asSafe());const o=s.join(","),a=!this.isWarp&&e===this.script.procedureCode,c=this.isInHat;if(a||c){const t=r.yields?"yieldThenCallGenerator":"yieldThenCall";return new b("(yield* ".concat(t,"(").concat(i,", ").concat(o,"))"),4)}return r.yields?new b("(yield* ".concat(i,"(").concat(o,"))"),4):new b("".concat(i,"(").concat(o,")"),4)}case"procedures.argument":return new b("p".concat(t.index),4);case"sensing.answer":return new b("runtime.ext_scratch3_sensing._answer",2);case"sensing.colorTouchingColor":return new b("target.colorIsTouchingColor(colorToList(".concat(this.descendInput(t.target).asColor(),"), colorToList(").concat(this.descendInput(t.mask).asColor(),"))"),3);case"sensing.date":return new b("(new Date().getDate())",1);case"sensing.dayofweek":return new b("(new Date().getDay() + 1)",1);case"sensing.daysSince2000":return new b("daysSince2000()",1);case"sensing.distance":return new b("distance(".concat(this.descendInput(t.target).asString(),")"),1);case"sensing.hour":return new b("(new Date().getHours())",1);case"sensing.minute":return new b("(new Date().getMinutes())",1);case"sensing.month":return new b("(new Date().getMonth() + 1)",1);case"sensing.of":{const e=this.descendInput(t.object).asString(),n=t.property;if("constant"===t.object.kind){const r="_stage_"===t.object.value,i=r?"stage":this.evaluateOnce("runtime.getSpriteTargetByName(".concat(e,")"));if("volume"===n)return new b("(".concat(i," ? ").concat(i,".volume : 0)"),1);if(r)switch(n){case"background #":case"backdrop #":return new b("(".concat(i,".currentCostume + 1)"),1);case"backdrop name":return new b("".concat(i,".getCostumes()[").concat(i,".currentCostume].name"),2)}else switch(n){case"x position":return new b("(".concat(i," ? ").concat(i,".x : 0)"),1);case"y position":return new b("(".concat(i," ? ").concat(i,".y : 0)"),1);case"direction":return new b("(".concat(i," ? ").concat(i,".direction : 0)"),1);case"costume #":return new b("(".concat(i," ? ").concat(i,".currentCostume + 1 : 0)"),1);case"costume name":return new b("(".concat(i," ? ").concat(i,".getCostumes()[").concat(i,".currentCostume].name : 0)"),4);case"size":return new b("(".concat(i," ? ").concat(i,".size : 0)"),1)}const s=this.evaluateOnce("".concat(i," && ").concat(i,'.lookupVariableByNameAndType("').concat(h(n),'", "", true)'));return new b("(".concat(s," ? ").concat(s,".value : 0)"),4)}return new b("runtime.ext_scratch3_sensing.getAttributeOf({OBJECT: ".concat(e,', PROPERTY: "').concat(h(n),'" })'),4)}case"sensing.second":return new b("(new Date().getSeconds())",1);case"sensing.touching":return new b("target.isTouchingObject(".concat(this.descendInput(t.object).asUnknown(),")"),3);case"sensing.touchingColor":return new b("target.isTouchingColor(colorToList(".concat(this.descendInput(t.color).asColor(),"))"),3);case"sensing.username":return new b("runtime.ioDevices.userData.getUsername()",2);case"sensing.year":return new b("(new Date().getFullYear())",1);case"timer.get":return new b("runtime.ioDevices.clock.projectTimer()",1);case"tw.lastKeyPressed":return new b("runtime.ioDevices.keyboard.getLastKeyPressed()",2);case"var.get":return this.descendVariable(t.variable);default:throw r.warn("JS: Unknown input: ".concat(t.kind),t),new Error("JS: Unknown input: ".concat(t.kind))}}descendStackedBlock(t){switch(t.kind){case"addons.call":this.source+="".concat(this.descendAddonCall(t),";\n");break;case"compat":{const e=this.isLastBlockInLoop(),n=t.blockType;if(n===s.COMMAND||n===s.HAT)this.source+="".concat(this.generateCompatibilityLayerCall(t,e),";\n");else{if(n!==s.CONDITIONAL&&n!==s.LOOP)throw new Error("Unknown block type: ".concat(n));{const e=this.localVariables.next();this.source+="const ".concat(e," = createBranchInfo(").concat(n===s.LOOP,");\n"),this.source+="while (".concat(e,".branch = +(").concat(this.generateCompatibilityLayerCall(t,!1,e),")) {\n"),this.source+="switch (".concat(e,".branch) {\n");for(const e in t.substacks)this.source+="case ".concat(+e,": {\n"),this.descendStack(t.substacks[e],new T(!1)),this.source+="break;\n",this.source+="}\n";this.source+="}\n",this.source+="if (!".concat(e,".isLoop) break;\n"),this.yieldLoop(),this.source+="}\n"}}e&&(this.source+="if (hasResumedFromPromise) {hasResumedFromPromise = false;continue;}\n");break}case"control.createClone":this.source+="runtime.ext_scratch3_control._createClone(".concat(this.descendInput(t.target).asString(),", target);\n");break;case"control.deleteClone":this.source+="if (!target.isOriginal) {\n",this.source+=" runtime.disposeTarget(target);\n",this.source+=" runtime.stopForTarget(target);\n",this.retire(),this.source+="}\n";break;case"control.for":{this.resetVariableInputs();const e=this.localVariables.next();this.source+="var ".concat(e," = 0; "),this.source+="while (".concat(e," < ").concat(this.descendInput(t.count).asNumber(),") { "),this.source+="".concat(e,"++; "),this.source+="".concat(this.referenceVariable(t.variable),".value = ").concat(e,";\n"),this.descendStack(t.do,new T(!0)),this.yieldLoop(),this.source+="}\n";break}case"control.if":this.source+="if (".concat(this.descendInput(t.condition).asBoolean(),") {\n"),this.descendStack(t.whenTrue,new T(!1)),t.whenFalse.length&&(this.source+="} else {\n",this.descendStack(t.whenFalse,new T(!1))),this.source+="}\n";break;case"control.repeat":{const e=this.localVariables.next();this.source+="for (var ".concat(e," = ").concat(this.descendInput(t.times).asNumber(),"; ").concat(e," >= 0.5; ").concat(e,"--) {\n"),this.descendStack(t.do,new T(!0)),this.yieldLoop(),this.source+="}\n";break}case"control.stopAll":this.source+="runtime.stopAll();\n",this.retire();break;case"control.stopOthers":this.source+="runtime.stopForTarget(target, thread);\n";break;case"control.stopScript":this.stopScript();break;case"control.wait":{const e=this.localVariables.next();this.source+="thread.timer = timer();\n",this.source+="var ".concat(e," = Math.max(0, 1000 * ").concat(this.descendInput(t.seconds).asNumber(),");\n"),this.requestRedraw(),this.yieldNotWarp(),this.source+="while (thread.timer.timeElapsed() < ".concat(e,") {\n"),this.yieldStuckOrNotWarp(),this.source+="}\n",this.source+="thread.timer = null;\n";break}case"control.waitUntil":this.resetVariableInputs(),this.source+="while (!".concat(this.descendInput(t.condition).asBoolean(),") {\n"),this.yieldStuckOrNotWarp(),this.source+="}\n";break;case"control.while":this.resetVariableInputs(),this.source+="while (".concat(this.descendInput(t.condition).asBoolean(),") {\n"),this.descendStack(t.do,new T(!0)),t.warpTimer?this.yieldStuckOrNotWarp():this.yieldLoop(),this.source+="}\n";break;case"counter.clear":this.source+="runtime.ext_scratch3_control._counter = 0;\n";break;case"counter.increment":this.source+="runtime.ext_scratch3_control._counter++;\n";break;case"hat.edge":this.isInHat=!0,this.source+="{\n",this.source+="const resolvedValue = ".concat(this.descendInput(t.condition).asBoolean(),";\n"),this.source+='const id = "'.concat(h(t.id),'";\n'),this.source+="const hasOldEdgeValue = target.hasEdgeActivatedValue(id);\n",this.source+="const oldEdgeValue = target.updateEdgeActivatedValue(id, resolvedValue);\n",this.source+="const edgeWasActivated = hasOldEdgeValue ? (!oldEdgeValue && resolvedValue) : resolvedValue;\n",this.source+="if (!edgeWasActivated) {\n",this.retire(),this.source+="}\n",this.source+="yield;\n",this.source+="}\n",this.isInHat=!1;break;case"hat.predicate":this.isInHat=!0,this.source+="if (!".concat(this.descendInput(t.condition).asBoolean(),") {\n"),this.retire(),this.source+="}\n",this.source+="yield;\n",this.isInHat=!1;break;case"event.broadcast":this.source+='startHats("event_whenbroadcastreceived", { BROADCAST_OPTION: '.concat(this.descendInput(t.broadcast).asString()," });\n"),this.resetVariableInputs();break;case"event.broadcastAndWait":this.source+='yield* waitThreads(startHats("event_whenbroadcastreceived", { BROADCAST_OPTION: '.concat(this.descendInput(t.broadcast).asString()," }));\n"),this.yielded();break;case"list.add":{const e=this.referenceVariable(t.list);this.source+="".concat(e,".value.push(").concat(this.descendInput(t.item).asSafe(),");\n"),this.source+="".concat(e,"._monitorUpToDate = false;\n");break}case"list.delete":{const e=this.referenceVariable(t.list),n=this.descendInput(t.index);if(n instanceof y){if("last"===n.constantValue){this.source+="".concat(e,".value.pop();\n"),this.source+="".concat(e,"._monitorUpToDate = false;\n");break}if(1==+n.constantValue){this.source+="".concat(e,".value.shift();\n"),this.source+="".concat(e,"._monitorUpToDate = false;\n");break}}this.source+="listDelete(".concat(e,", ").concat(n.asUnknown(),");\n");break}case"list.deleteAll":this.source+="".concat(this.referenceVariable(t.list),".value = [];\n");break;case"list.hide":this.source+='runtime.monitorBlocks.changeBlock({ id: "'.concat(h(t.list.id),'", element: "checkbox", value: false }, runtime);\n');break;case"list.insert":{const e=this.referenceVariable(t.list),n=this.descendInput(t.index),r=this.descendInput(t.item);if(n instanceof y&&1==+n.constantValue){this.source+="".concat(e,".value.unshift(").concat(r.asSafe(),");\n"),this.source+="".concat(e,"._monitorUpToDate = false;\n");break}this.source+="listInsert(".concat(e,", ").concat(n.asUnknown(),", ").concat(r.asSafe(),");\n");break}case"list.replace":this.source+="listReplace(".concat(this.referenceVariable(t.list),", ").concat(this.descendInput(t.index).asUnknown(),", ").concat(this.descendInput(t.item).asSafe(),");\n");break;case"list.show":this.source+='runtime.monitorBlocks.changeBlock({ id: "'.concat(h(t.list.id),'", element: "checkbox", value: true }, runtime);\n');break;case"looks.backwardLayers":this.target.isStage||(this.source+="target.goBackwardLayers(".concat(this.descendInput(t.layers).asNumber(),");\n"));break;case"looks.clearEffects":this.source+="target.clearEffects();\n";break;case"looks.changeEffect":Object.prototype.hasOwnProperty.call(this.target.effects,t.effect)&&(this.source+='target.setEffect("'.concat(h(t.effect),'", runtime.ext_scratch3_looks.clampEffect("').concat(h(t.effect),'", ').concat(this.descendInput(t.value).asNumber(),' + target.effects["').concat(h(t.effect),'"]));\n'));break;case"looks.changeSize":this.source+="target.setSize(target.size + ".concat(this.descendInput(t.size).asNumber(),");\n");break;case"looks.forwardLayers":this.target.isStage||(this.source+="target.goForwardLayers(".concat(this.descendInput(t.layers).asNumber(),");\n"));break;case"looks.goToBack":this.target.isStage||(this.source+="target.goToBack();\n");break;case"looks.goToFront":this.target.isStage||(this.source+="target.goToFront();\n");break;case"looks.hide":this.source+="target.setVisible(false);\n",this.source+="runtime.ext_scratch3_looks._renderBubble(target);\n";break;case"looks.nextBackdrop":this.source+="runtime.ext_scratch3_looks._setBackdrop(stage, stage.currentCostume + 1, true);\n";break;case"looks.nextCostume":this.source+="target.setCostume(target.currentCostume + 1);\n";break;case"looks.setEffect":Object.prototype.hasOwnProperty.call(this.target.effects,t.effect)&&(this.source+='target.setEffect("'.concat(h(t.effect),'", runtime.ext_scratch3_looks.clampEffect("').concat(h(t.effect),'", ').concat(this.descendInput(t.value).asNumber(),"));\n"));break;case"looks.setSize":this.source+="target.setSize(".concat(this.descendInput(t.size).asNumber(),");\n");break;case"looks.show":this.source+="target.setVisible(true);\n",this.source+="runtime.ext_scratch3_looks._renderBubble(target);\n";break;case"looks.switchBackdrop":this.source+="runtime.ext_scratch3_looks._setBackdrop(stage, ".concat(this.descendInput(t.backdrop).asSafe(),");\n");break;case"looks.switchCostume":this.source+="runtime.ext_scratch3_looks._setCostume(target, ".concat(this.descendInput(t.costume).asSafe(),");\n");break;case"motion.changeX":this.source+="target.setXY(target.x + ".concat(this.descendInput(t.dx).asNumber(),", target.y);\n");break;case"motion.changeY":this.source+="target.setXY(target.x, target.y + ".concat(this.descendInput(t.dy).asNumber(),");\n");break;case"motion.ifOnEdgeBounce":this.source+="runtime.ext_scratch3_motion._ifOnEdgeBounce(target);\n";break;case"motion.setDirection":this.source+="target.setDirection(".concat(this.descendInput(t.direction).asNumber(),");\n");break;case"motion.setRotationStyle":this.source+='target.setRotationStyle("'.concat(h(t.style),'");\n');break;case"motion.setX":case"motion.setY":case"motion.setXY":{this.descendedIntoModulo=!1;const e="x"in t?this.descendInput(t.x).asNumber():"target.x",n="y"in t?this.descendInput(t.y).asNumber():"target.y";this.source+="target.setXY(".concat(e,", ").concat(n,");\n"),this.descendedIntoModulo&&(this.source+="if (target.interpolationData) target.interpolationData = null;\n");break}case"motion.step":this.source+="runtime.ext_scratch3_motion._moveSteps(".concat(this.descendInput(t.steps).asNumber(),", target);\n");break;case"noop":break;case"pen.clear":this.source+="".concat(d,".clear();\n");break;case"pen.down":this.source+="".concat(d,"._penDown(target);\n");break;case"pen.changeParam":this.source+="".concat(d,"._setOrChangeColorParam(").concat(this.descendInput(t.param).asString(),", ").concat(this.descendInput(t.value).asNumber(),", ").concat(p,", true);\n");break;case"pen.changeSize":this.source+="".concat(d,"._changePenSizeBy(").concat(this.descendInput(t.size).asNumber(),", target);\n");break;case"pen.legacyChangeHue":this.source+="".concat(d,"._changePenHueBy(").concat(this.descendInput(t.hue).asNumber(),", target);\n");break;case"pen.legacyChangeShade":this.source+="".concat(d,"._changePenShadeBy(").concat(this.descendInput(t.shade).asNumber(),", target);\n");break;case"pen.legacySetHue":this.source+="".concat(d,"._setPenHueToNumber(").concat(this.descendInput(t.hue).asNumber(),", target);\n");break;case"pen.legacySetShade":this.source+="".concat(d,"._setPenShadeToNumber(").concat(this.descendInput(t.shade).asNumber(),", target);\n");break;case"pen.setColor":this.source+="".concat(d,"._setPenColorToColor(").concat(this.descendInput(t.color).asColor(),", target);\n");break;case"pen.setParam":this.source+="".concat(d,"._setOrChangeColorParam(").concat(this.descendInput(t.param).asString(),", ").concat(this.descendInput(t.value).asNumber(),", ").concat(p,", false);\n");break;case"pen.setSize":this.source+="".concat(d,"._setPenSizeTo(").concat(this.descendInput(t.size).asNumber(),", target);\n");break;case"pen.stamp":this.source+="".concat(d,"._stamp(target);\n");break;case"pen.up":this.source+="".concat(d,"._penUp(target);\n");break;case"procedures.call":{const e=t.code,n=t.variant,r=this.ir.procedures[n];if(null===r.stack)break;!this.isWarp&&e===this.script.procedureCode&&this.yieldNotWarp(),r.yields&&(this.source+="yield* "),this.source+='thread.procedures["'.concat(h(n),'"](');const i=[];for(const e of t.arguments)i.push(this.descendInput(e).asSafe());this.source+=i.join(","),this.source+=");\n",this.resetVariableInputs();break}case"procedures.return":this.stopScriptAndReturn(this.descendInput(t.value).asSafe());break;case"timer.reset":this.source+="runtime.ioDevices.clock.resetProjectTimer();\n";break;case"tw.debugger":this.source+="debugger;\n";break;case"var.hide":this.source+='runtime.monitorBlocks.changeBlock({ id: "'.concat(h(t.variable.id),'", element: "checkbox", value: false }, runtime);\n');break;case"var.set":{const e=this.descendVariable(t.variable),n=this.descendInput(t.value);e.setInput(n),this.source+="".concat(e.source," = ").concat(n.asSafe(),";\n"),t.variable.isCloud&&(this.source+='runtime.ioDevices.cloud.requestUpdateVariable("'.concat(h(t.variable.name),'", ').concat(e.source,");\n"));break}case"var.show":this.source+='runtime.monitorBlocks.changeBlock({ id: "'.concat(h(t.variable.id),'", element: "checkbox", value: true }, runtime);\n');break;case"visualReport":{const e=this.localVariables.next();this.source+="const ".concat(e," = ").concat(this.descendInput(t.input).asUnknown(),";"),this.source+="if (".concat(e,' !== undefined) runtime.visualReport(target, "').concat(h(this.script.topBlockId),'", ').concat(e,");\n");break}default:throw r.warn("JS: Unknown stacked block: ".concat(t.kind),t),new Error("JS: Unknown stacked block: ".concat(t.kind))}}descendInputRecord(t){let e="{";for(const n of Object.keys(t)){const r=t[n];e+='"'.concat(h(n),'":').concat(this.descendInput(r).asSafe(),",")}return e+="}",e}resetVariableInputs(){this.variableInputs={}}descendStack(t,e){this.resetVariableInputs(),this.pushFrame(e);for(let n=0;n2&&void 0!==arguments[2]?arguments[2]:null;const r=t.opcode;let i="yield* executeInCompatibilityLayer({";for(const e of Object.keys(t.inputs)){const n=t.inputs[e],r=this.descendInput(n).asSafe();i+='"'.concat(h(e),'":').concat(r,",")}for(const e of Object.keys(t.fields)){const n=t.fields[e];i+='"'.concat(h(e),'":"').concat(h(n),'",')}const s=this.evaluateOnce('runtime.getOpcodeFunction("'.concat(h(r),'")'));return i+="}, ".concat(s,", ").concat(this.isWarp,", ").concat(e,', "').concat(h(t.id),'", ').concat(n,")"),this.yielded(),i}getScriptFactoryName(){return f.next()}getScriptName(t){let e=t?g.next():m.next();if(this.isProcedure){const t=this.script.procedureCode.replace(/%[\w]/g,"").replace(/[^a-zA-Z0-9]/g,"_").substring(0,20);e+="_".concat(t)}return e}createScriptFactory(){let t="";t+="(function ".concat(this.getScriptFactoryName(),"(thread) { "),t+="const target = thread.target; ",t+="const runtime = target.runtime; ",t+="const stage = runtime.getTargetForStage();\n";for(const e of Object.keys(this._setupVariables)){const n=this._setupVariables[e];t+="const ".concat(n," = ").concat(e,";\n")}if(t+="return ",this.script.yields?t+="function* ":t+="function ",t+=this.getScriptName(this.script.yields),t+=" (",this.script.arguments.length){const e=[];for(let t=0;t0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.sequencer=t,this.thread=e,this._nowObj={now:()=>this.sequencer.runtime.currentMSecs}}get target(){return this.thread.target}get runtime(){return this.sequencer.runtime}get nowObj(){return this.runtime?this._nowObj:null}get stackFrame(){const t=this.thread.peekStackFrame();return null===t.executionContext&&(t.executionContext={}),t.executionContext}stackTimerFinished(){return!(this.stackFrame.timer.timeElapsed()this._setupPreview())):null}disableVideo(){if(this._disablePreview(),!this.provider)return null;this.provider.disableVideo()}getFrame(t){let{dimensions:e=i.DIMENSIONS,mirror:n=this.mirror,format:r=i.FORMAT_IMAGE_DATA,cacheTimeout:s=this._frameCacheTimeout}=t;return this.provider?this.provider.getFrame({dimensions:e,mirror:n,format:r,cacheTimeout:s}):null}setPreviewGhost(t){this._ghost=t,-1!==this._drawable&&this.runtime.renderer.updateDrawableEffect(this._drawable,"ghost",this._forceTransparentPreview?100:t)}_disablePreview(){-1!==this._skinId&&(this.runtime.renderer.updateBitmapSkin(this._skinId,new ImageData(...i.DIMENSIONS),1),this.runtime.renderer.updateDrawableVisible(this._drawable,!1)),this._renderPreviewFrame=null}_setupPreview(){const{renderer:t}=this.runtime;t&&(-1===this._skinId&&-1===this._drawable&&(this._skinId=t.createBitmapSkin(new ImageData(...i.DIMENSIONS),1),this._drawable=t.createDrawable(r.VIDEO_LAYER),t.updateDrawableSkinId(this._drawable,this._skinId),t.markSkinAsPrivate&&t.markSkinAsPrivate(this._skinId),t.markDrawableAsNoninteractive&&t.markDrawableAsNoninteractive(this._drawable)),this._renderPreviewFrame||(t.updateDrawableEffect(this._drawable,"ghost",this._forceTransparentPreview?100:this._ghost),t.updateDrawableVisible(this._drawable,!0),this._renderPreviewFrame=()=>{if(clearTimeout(this._renderPreviewTimeout),!this._renderPreviewFrame)return;this._renderPreviewTimeout=setTimeout(this._renderPreviewFrame,this.runtime.currentStepTime);const e=this.getFrame({format:i.FORMAT_IMAGE_DATA,cacheTimeout:this.runtime.currentStepTime});e?(t.updateBitmapSkin(this._skinId,e,1),this.runtime.requestRedraw()):t.updateBitmapSkin(this._skinId,new ImageData(...i.DIMENSIONS),1)},this._renderPreviewFrame()))}get videoReady(){return!!this.provider&&this.provider.videoReady}postData(t){let{forceTransparentPreview:e}=t;this._forceTransparentPreview=e,this.setPreviewGhost(this._ghost)}}t.exports=i},function(t,e){t.exports={generateExtensionId:t=>{const e=t.replace(/[^a-z0-9]/gi,"").toLowerCase();return"sbx".concat(e)},argumentIndexToId:t=>t.toString()}},function(t,e){t.exports=class{constructor(t,e){this.callback=t,this.maxConcurrent=e,this._current=0,this._queue=[]}do(){for(var t=arguments.length,e=new Array(t),n=0;n{this._queue.push([t,n,e]),this._startNext()}))}_startNext(){if(this._current>=this.maxConcurrent||0===this._queue.length)return;this._current++;const[t,e,n]=this._queue.shift();this.callback.apply(null,n).then((e=>{t(e),this._current--,this._startNext()})).catch((t=>{e(t),this._current--,this._startNext()}))}}},function(t,e){class n{static _mergeVarRefObjects(t,e){for(const n in e)t[n]?t[n]=t[n].concat(e[n]):t[n]=e[n];return t}static getAllVarRefsForTargets(t,e){return t.map((t=>t.blocks.getAllVariableAndListReferences(null,e))).reduce(n._mergeVarRefObjects,{})}static updateVariableIdentifiers(t,e,n){t.map((t=>(t.referencingField.id=e,n&&(t.referencingField.value=n),t)))}}t.exports=n},function(t,e,n){const r=n(48),i=n(49),s=n(74),o=n(75),a=n(232),c=n(235),u=(t,e)=>{const n=[],r=t=>{t.localName!==e&&void 0!==e||!t.getAttribute||n.push(t);for(let e=0;e{const e=c(),n=document.createElement("span"),i=t.outerHTML,s=r.sanitize(i,{USE_PROFILES:{svg:!0},FORBID_TAGS:["a","audio","canvas","video"],ADD_DATA_URI_TAGS:["image"]});let o,a;try{n.innerHTML=s,e.appendChild(n),o=n.children[0].getBBox()}finally{e.removeChild(n)}a=0===o.width||0===o.height?0:(t=>{let e=0;const n=t=>{t.getAttribute&&(t.getAttribute("stroke")&&(e=Math.max(e,1)),t.getAttribute("stroke-width")&&(e=Math.max(e,Number(t.getAttribute("stroke-width"))||0)));for(let e=0;e{e&&(t=>{const e=u(t,"linearGradient");for(const t of e)t.getAttribute("x2")||t.setAttribute("x2","0")})(t),a(t,window),(t=>{const e=u(t,"image"),n="image-rendering: optimizespeed; image-rendering: pixelated;";for(const t of e)t.getAttribute("style")?t.setAttribute("style",`${n} ${t.getAttribute("style")}`):t.setAttribute("style",n)})(t),e?((t=>{const e=[],n=t=>{"text"===t.localName&&e.push(t);for(let e=0;e{const e=u(t);for(const t of e){if(!t.style)continue;const e=t.style.stroke||t.getAttribute("stroke");e&&e.match(/^url\(#.*\)$/)&&(t.style["stroke-linejoin"]="round",t.style["stroke-linecap"]="round")}})(t)):t.getAttribute("viewBox")?t.getAttribute("width")&&t.getAttribute("height")||(t.setAttribute("width",t.viewBox.baseVal.width),t.setAttribute("height",t.viewBox.baseVal.height)):l(t)};t.exports=(t,e)=>{const n=new DOMParser;t=o(t);const r=n.parseFromString(t,"text/xml");if(r.childNodes.length<1||"svg"!==r.documentElement.localName)throw new Error("Document does not appear to be SVG.");const i=r.documentElement;return h(i,e),i}},function(t,e){t.exports=function(t){const e=[],n=t=>{"text"===t.localName&&e.push(t);for(let e=0;e]*>/);e&&-1===e[0].indexOf("xmlns=")&&(t=t.replace("]+?xlink:href=["'])data:img\/png/g,((t,e)=>`${e}data:image/png`)));const n=/(<[^>]+?xmlns:(?!xml=)[^ ]+=)"http:\/\/www.w3.org\/XML\/1998\/namespace"/g;return null!==t.match(n)&&(t=t.replace(n,((t,e)=>`${e}"http://dummy.namespace"`))),t=(t=(t=t.replace(/<(\/?)\s*svg:/g,"<$1")).replace(/[\s\S]*<\/metadata>/," ")).replace(/