@datagrok/sequence-translator 1.4.5 → 1.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/dist/package-test.js +1 -1
- package/dist/package-test.js.map +1 -1
- package/dist/package.js +1 -1
- package/dist/package.js.map +1 -1
- package/files/polytool-rules/rules_example.json +1 -1
- package/files/samples/HELM.csv +6 -0
- package/files/samples/cyclized.csv +3 -2
- package/files/samples/cyclized_MSA.csv +5 -0
- package/package.json +5 -5
- package/src/apps/common/model/oligo-toolkit-package.ts +11 -4
- package/src/consts.ts +12 -0
- package/src/global.d.ts +13 -0
- package/src/package-test.ts +1 -0
- package/src/package.ts +5 -4
- package/src/polytool/pt-conversion.ts +222 -70
- package/src/polytool/pt-dialog.ts +17 -11
- package/src/polytool/pt-enumeration-helm-dialog.ts +63 -25
- package/src/polytool/pt-enumeration-helm.ts +9 -6
- package/src/polytool/pt-placeholders-breadth-input.ts +4 -4
- package/src/polytool/pt-placeholders-input.ts +6 -6
- package/src/polytool/pt-unrule-dialog.ts +5 -1
- package/src/polytool/pt-unrule.ts +3 -2
- package/src/polytool/types.ts +4 -4
- package/src/tests/polytool-chain-from-notation-tests.ts +108 -18
- package/src/tests/polytool-chain-parse-notation-tests.ts +52 -11
- package/src/tests/polytool-convert-tests.ts +102 -25
- package/src/tests/polytool-detectors-custom-notation-test.ts +1 -1
- package/src/tests/polytool-enumerate-breadth-tests.ts +4 -4
- package/src/utils/context-menu.ts +2 -2
- package/src/utils/cyclized.ts +6 -8
package/dist/package-test.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/*! For license information please see package-test.js.LICENSE.txt */
|
|
2
|
-
var sequencetranslator_test;(()=>{var t={717:(t,e,n)=>{"use strict";n.d(e,{j:()=>o});var r=n(82);async function o(){const t=r.Func.find({package:"Chem",name:"getRdKitModule"});if(0===t.length)throw new Error('Package "Chem" must be installed for getRdKitModule.');return(await t[0].prepare().call()).getOutputParamValue()}},599:(t,e,n)=>{"use strict";n.d(e,{o:()=>r.o});var r=n(869)},124:(t,e,n)=>{"use strict";n.d(e,{b2:()=>i});var r=n(389),o=n(82);async function i(){const t="Helm",e=o.Func.find({package:t,name:"getHelmHelper"});if(0===e.length)throw new Error(`Package '${t}' must be installed for HelmHelper.`);return(await e[0].prepare().call()).getOutputParamValue()}o.JsInputBase,Error,r.input.helmAsync=async function(t,e){return(await i()).createHelmInput(t,e)}},890:(t,e,n)=>{"use strict";n.d(e,{pj:()=>p});var r,o,i,s,a,u,c,l=n(82);n(328);class f{constructor(t,e=!1){if(this._length=0,this._version=0,this._updateLevel=0,this._selectedCount=0,this._selectedCountVersion=-1,this._selectedIndexesVersion=-1,this._versionedName="",this._versionedNameVersion=-1,this.SHRINK_THRESHOLD=256,"number"==typeof t){const n=t,r=f._createBuffer(n);if(e)for(let t=0;t<r.length;t++)r[t]=-1;this._data=r,this._length=n}else{if(!(t instanceof Uint32Array))throw new Error("Invalid constructor");this._data=t,this._length=e}}getRawData(){return this._data}assureGoez(t,e){if(t<0)throw new Error(`${e} should be greater than zero`)}assureInRange(t,e,n,r){if(t<e||t>n)throw new Error(`Argument ${r} (${t}) out of range (${e}, ${n})`)}copy(t,e,n){for(let r=0;r<n;r++)e[r]=t[r]}copyFrom(t){if(this._length!=t._length)throw new Error(`Lengths differ (${this._length} != ${t._length})`);this.copy(t._data,this._data,this.lengthInInts),this._version++}get length(){return this._length}get buffer(){return this._data}set buffer(t){this._data=t,this._version++}get version(){return this._version}set version(t){this._version=t}incrementVersion(t=!0){this._version++}get lengthInInts(){return Math.floor((this._length+31)/32)}get versionedName(){return this._version==this._versionedNameVersion?this._versionedName:""}set versionedName(t){this._versionedName=t,this._versionedNameVersion=this._version}get self(){return this}setLength(t){if(t<0)throw new Error("should be >= 0");if(t==this._length)return;const e=Math.floor((t+31)/32);if(e>this._data.length||e+this.SHRINK_THRESHOLD<this._data.length){const t=new Uint32Array(e);this.copy(this._data,t,e>this._data.length?this._data.length:e),this._data=t}t>this._length&&(this._length%32>0&&(this._data[this.lengthInInts-1]&=(1<<(this._length%32&31))-1),this._data.fill(0,this.lengthInInts,e)),this._length=t,this._version++}static fromAnd(t,e){if(t._length!=e._length)throw new Error(`Lengths differ (${t._length} != ${e._length})`);const n=new f(t._length);n._length=t._length,n._data=f._createBuffer(n._length),n._version=0;const r=t.lengthInInts;for(let o=0;o<r;o++)n._data[o]=t._data[o]&e._data[o];return n}static _createBuffer(t){return new Uint32Array(Math.floor((t+31)/32))}static fromValues(t){const e=new f(t.length);e._version=0;for(let n=0;n<e._length;n++)t[n]&&(e._data[Math.floor(n/32)]|=1<<(n%32&31));return e}static fromSeq(t,e){const n=new f(t);for(let r=0;r<t;++r)n.setBit(r,e(r));return n._version=0,n}static fromString(t){return f.fromSeq(t.length,(e=>"1"==t.charAt(e)))}static fromUint32Array(t,e){const n=new f(t);return n._data=e,n}static fromBytes(t){const e=t.length,n=new f(8*e);n._data=new Uint32Array(Math.floor((e+3)/4)),n._length=8*e;let r=0,o=0;for(;e-o>=4;)n._data[r++]=255&t[o]|(255&t[o+1])<<8|(255&t[o+2])<<16|(255&t[o+3])<<24,o+=4;return e-o==3&&(n._data[r]=(255&t[o+2])<<16),e-o==2&&(n._data[r]|=(255&t[o+1])<<8),e-o==1&&(n._data[r]|=255&t[o]),n._version=0,n}toString(){return`${this._length} bits, ${this.countBits(!0)} set`}equals(t){if(this==t)return!0;if(null==t)return!1;if(this._length!=t._length)return!1;if(0==this._length)return!0;for(let e=0;e<this._data.length-1;e++)if(this._data[e]!=t._data[e])return!1;for(let e=8*(this._data.length-1);e<this._length;e++)if(this.getBit(e)!=t.getBit(e))return!1;return!0}clone(){const t=new f(0,!1);return t._data=Uint32Array.from(this._data),t._length=this._length,t._version=this._version,t}init(t,e){this.setAll(!1,!1);for(let e=0;e<this._length;e++)t(e)&&(this._data[Math.floor(e/32)]|=1<<(e%32&31));return this.incrementVersion(e),this}invert(t=!0){for(let t=0;t<this._data.length;t++)this._data[t]^=-1;this.incrementVersion(t)}setAll(t,e=!1){const n=t?-1:0,r=this.lengthInInts;for(let t=0;t<r;t++)this._data[t]=n;this.incrementVersion(e)}setIndexes(t,e=!0,n=!0,r=!0){n&&this.setAll(!e,!1);for(const n of t)this.setFast(n,e);this.incrementVersion(r)}everyIndex(t,e=!0){for(const n of t)if(this.getBit(n)!=e)return!1;return!0}anyIndex(t,e=!0){for(const n of t)if(this.getBit(n)==e)return!0;return!1}setWhere(t,e=!0,n=!0,r=!0,o=!0){if(n&&o&&this.setAll(!e,!1),o)for(let n=0;n<this._length;n++)t(n)&&this.setFast(n,e);else for(let n=0;n<this._length;n++)this.setFast(n,t(n)?e:!e);this.incrementVersion(r)}getRange(t,e){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length,"to");const n=[];for(let r=t;r<e;++r)n.push(this.getBit(r));return f.fromValues(n)}getRangeAsList(t,e){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length,"to");const n=[];for(let r=t;r<e;++r)n.push(this.getBit(r));return n}setRange(t,e,n,r=!0){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length-1,"to");const o=Math.min(t,e),i=Math.max(t,e);if(n)for(let t=o;t<=i;t++)this.setTrue(t);else for(let t=o;t<=i;t++)this.setFalse(t);return this.incrementVersion(r),this}setRandom(t,e,n=!0){if(t<0||t>this._length)throw new Error("n must be >= 0 && <= Count");t>this._length/2&&this.setRandom(this._length-t,!e),this.setAll(!e);for(let n=0;n<t;){const t=Math.floor(Math.random()*this._length);this.getBit(t)!=e&&(this.setFast(t,e),n++)}this.incrementVersion(n)}and(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]&=t._data[e];return this.incrementVersion(e),this}andNot(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");const n=this.lengthInInts;for(let e=0;e<n;e++)this._data[e]&=~t._data[e];return this.incrementVersion(e),this}notAnd(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]=~this._data[e]&t._data[e];return this.incrementVersion(e),this}not(t=!0){for(let t=0,e=this.lengthInInts;t<e;t++)this._data[t]=~this._data[t];return this.incrementVersion(t),this}or(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]|=t._data[e];return this.incrementVersion(e),this}xor(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]^=t._data[e];return this.incrementVersion(e),this}insertAt(t,e,n=!1){if(this.assureInRange(t,0,this._length,"pos"),0==e)return;const r=this._length;this.setLength(this._length+e);for(let n=r-1;n>=t;n--)this.setBit(n+e,this.getBit(n));for(let r=t;r<t+e;r++)this.setBit(r,n)}removeAt(t,e=1){if(e<0)throw new Error("n cannot be negative");if(this.assureInRange(t,0,this._length-e,"pos"),this.contains(!0))for(let n=t;n<this._length-e;n++)this.setBit(n,this.getBit(n+e));this.setLength(this._length-e)}removeByMask(t,e=!0){if(this._length!=t.length)throw new Error("length != mask.length");if(t==this)this.setLength(t.countBits(!e)),this.setAll(!e);else{let n=0;for(let r=-1;-1!=(r=t.findNext(r,!e));)this.setFast(n++,this.getBit(r));this._length=n,this._version++}return this}getBit(t){return!!(this._data[Math.floor(t/32)]&1<<(31&t))}setBit(t,e,n=!0){this.setFast(t,e),this._version++}setFast(t,e){e?this._data[Math.floor(t/32)]|=1<<(31&t):this._data[Math.floor(t/32)]&=~(1<<(31&t))}setTrue(t){this._data[Math.floor(t/32)]|=1<<(31&t)}setFalse(t){this._data[Math.floor(t/32)]&=~(1<<(31&t))}trueCount(){return this.countBits(!0)}falseCount(){return this.countBits(!1)}countBits(t){if(0==this._length)return 0;if(this._selectedCountVersion!=this._version){this._selectedCount=0;const t=this.lengthInInts;let e=0;for(;e<t-1;e++)for(let t=this._data[e];0!=t;t>>>=8)this._selectedCount+=f._onBitCount[255&t];let n=this._data[e];const r=31&this._length;for(0!=r&&(n&=~(4294967295<<r));0!=n;n>>>=8)this._selectedCount+=f._onBitCount[255&n];this._selectedCountVersion=this._version}return t?this._selectedCount:this._length-this._selectedCount}countWhere(t){let e=0;if(this.trueCount()==this._length)for(let n=0;n<this._length;n++)e+=t(n)?1:0;else for(let n=-1;-1!=(n=this.findNext(n,!0));)e+=t(n)?1:0;return e}andWithCountBits(t,e){if(0==this._length)return 0;let n=0;const r=this.lengthInInts;let o=0;for(;o<r-1;o++)for(let e=this._data[o]&t._data[o];0!=e;e>>>=8)n+=f._onBitCount[255&e];let i=this._data[o]&t._data[o];const s=31&this._length;for(0!=s&&(i&=~(4294967295<<s));0!=i;i>>>=8)n+=f._onBitCount[255&i];return e?n:this._length-n}clear(){this.setLength(0)}contains(t){return this.findNext(-1,t)>=0}get allTrue(){return this.countBits(!0)==this._length}get allFalse(){return this.countBits(!1)==this._length}get anyTrue(){return this.countBits(!0)>0}get anyFalse(){return this.countBits(!1)>0}findNext(t,e=!0){if(this.assureInRange(t,-1,this._length,"index"),t>=this._length-1)return-1;let n=31&(t=t<0?0:t+1);const r=this.lengthInInts;for(let o=Math.floor(t/32);o<r;o++){let r=e?this._data[o]:~this._data[o];if(0!=n)r&=4294967295<<n&4294967295,n=0;else if(!e&&-4294967296==r)continue;for(let e=0;0!=r;e+=8,r>>>=8){const n=f._firstOnBit[255&r];if(n>=0)return(t=n+32*o+e)>=this._length?-1:t}}return-1}findPrev(t,e=!0){if(0==t)return-1;this.assureInRange(t,-1,this._length,"index");let n=1+(t=t<0?this._length-1:t-1)&31;for(let r=Math.floor(t/32);r>=0;r--){let t=e?this._data[r]:~this._data[r];0!=n&&(t&=~(4294967295<<n),n=0);for(let e=24;0!=t;e-=8,t<<=8){const n=f._lastOnBit[t>>>24];if(n>=0)return n+32*r+e}}return-1}}f._onBitCount=Int8Array.from([0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,4,5,5,6,5,6,6,7,5,6,6,7,6,7,7,8]),f._firstOnBit=Int8Array.from([-1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0]),f._lastOnBit=Int8Array.from([-1,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7]),function(t){t.Levenshtein="Levenshtein",t.JaroWinkler="Jaro-Winkler",t.Manhattan="Manhattan",t.Onehot="One-Hot"}(r||(r={})),function(t){t.Euclidean="Euclidean"}(o||(o={})),function(t){t.Tanimoto="Tanimoto",t.Dice="Dice",t.Asymmetric="Asymmetric",t.BraunBlanquet="Braun-Blanquet",t.Cosine="Cosine",t.Kulczynski="Kulczynski",t.McConnaughey="Mc-Connaughey",t.RogotGoldberg="Rogot-Goldberg",t.Russel="Russel",t.Sokal="Sokal",t.Hamming="Hamming",t.Euclidean="Euclidean"}(i||(i={})),function(t){t.TanimotoIntArray="TanimotoIntArray"}(s||(s={})),function(t){t.Vector="Vector",t.String="String",t.BitArray="BitArray",t.MacroMolecule="MacroMolecule",t.Number="Number",t.IntArray="IntArray",t.NumberArray="NumberArray"}(a||(a={})),function(t){t.Difference="Difference"}(u||(u={})),function(t){t.CommonItems="Common Items"}(c||(c={}));new Uint32Array(65536);var h;async function p(){const t=l.Func.find({package:"Bio",name:"getMonomerLibHelper"});if(0===t.length)throw new Error('Package "Bio" must be installed for MonomerLibHelper.');return(await t[0].prepare().call()).getOutputParamValue()}!function(t){t.HAMMING="Hamming",t.LEVENSHTEIN="Levenshtein",t.NEEDLEMANN_WUNSCH="Needlemann-Wunsch",t.MONOMER_CHEMICAL_DISTANCE="Monomer chemical distance"}(h||(h={})),h.HAMMING,h.LEVENSHTEIN,h.NEEDLEMANN_WUNSCH,h.MONOMER_CHEMICAL_DISTANCE,i.Tanimoto,i.Dice,i.Asymmetric,i.BraunBlanquet,i.Cosine,i.Kulczynski,i.McConnaughey,i.RogotGoldberg,i.Russel,i.Sokal,i.Hamming,i.Euclidean,i.Tanimoto,i.Dice,i.Asymmetric,i.BraunBlanquet,i.Cosine,i.Kulczynski,i.McConnaughey,i.RogotGoldberg,i.Russel,i.Sokal,i.Hamming,i.Euclidean,i.Tanimoto,i.Dice,i.Cosine,i.Tanimoto,i.Asymmetric,i.Cosine,i.Sokal,h.HAMMING,h.LEVENSHTEIN,h.MONOMER_CHEMICAL_DISTANCE,h.NEEDLEMANN_WUNSCH,n(151),n(439)},151:(t,e,n)=>{"use strict";new RegExp("[rd]\\((\\w)\\)p?","g")},192:(t,e,n)=>{"use strict";function r(t){return"string"==typeof t||t instanceof String?t:"StateError"===t.constructor.name?t.message:"StateError"===t.constructor.name&&"$thrownJsError"in t?r(t.$thrownJsError):t instanceof Error?t.message:t.toString()}function o(t){return t instanceof Error?t.stack:"StateError"===t.constructor.name&&"$thrownJsError"in t?o(t.$thrownJsError):void 0}function i(t){return[r(t),o(t)]}n.d(e,{AP:()=>i})},439:(t,e,n)=>{"use strict";n.d(e,{Hi:()=>r,YI:()=>o,_S:()=>u,gp:()=>i});var r,o,i,s=n(738);!function(t){t.FASTA="fasta",t.SEPARATOR="separator",t.HELM="helm",t.CUSTOM="custom"}(r||(r={})),function(t){t.DNA="DNA",t.RNA="RNA",t.PT="PT",t.UN="UN"}(o||(o={})),function(t){t.aligned="aligned",t.alphabet="alphabet",t.alphabetSize=".alphabetSize",t.alphabetIsMultichar=".alphabetIsMultichar",t.separator="separator",t.isHelmCompatible=".isHelmCompatible",t.positionNames=".positionNames",t.positionLabels=".positionLabels",t.regions=".regions"}(i||(i={}));const a=new class{constructor(){this.fasta={peptide:new Set(["G","L","Y","S","E","Q","D","N","F","A","K","R","H","C","V","P","W","I","M","T"]),dna:new Set(["A","C","G","T"]),rna:new Set(["A","C","G","U"])}}},u=(new s.a(o.PT,a.fasta.peptide,.5),new s.a(o.DNA,a.fasta.dna,.55),new s.a(o.RNA,a.fasta.rna,.55),"");r.FASTA,r.SEPARATOR,r.HELM},3:(t,e,n)=>{"use strict";n.d(e,{Hi:()=>r.Hi,YI:()=>r.YI,gp:()=>r.gp});var r=n(439);n(291)},738:(t,e,n)=>{"use strict";n.d(e,{a:()=>r});class r{constructor(t,e,n){this.name=t,this.alphabet=e,this.cutoff=n}}},291:(t,e,n)=>{"use strict";n.d(e,{Mu:()=>d,zS:()=>m});var r=n(82),o=(n(991),n(738),n(439));class i{static makePalette(t,e=!1,n=i){const r={};return t.forEach((t=>{const n=t[0],o=t[1];n.forEach(((t,n)=>{r[t]=this.colourPalette[o][e?0:n]}))})),new n(r)}constructor(t){this._palette=t}get(t,e){return this._palette[t]}}i.undefinedColor="rgb(100,100,100)",i.colourPalette={orange:["rgb(255,187,120)","rgb(245,167,100)","rgb(235,137,70)","rgb(205, 111, 71)"],all_green:["rgb(44,160,44)","rgb(74,160,74)","rgb(23,103,57)","rgb(30,110,96)","rgb(60,131,95)","rgb(24,110,79)","rgb(152,223,138)","rgb(182, 223, 138)","rgb(152, 193, 138)"],all_blue:["rgb(31,119,180)","rgb(23,190,207)","rgb(122, 102, 189)","rgb(158,218,229)","rgb(141, 124, 217)","rgb(31, 120, 150)"],magenta:["rgb(162,106,192)","rgb(197,165,224)","rgb(208,113,218)"],red:["rgb(214,39,40)","rgb(255,152,150)"],st_blue:["rgb(23,190,207)","rgb(158,218,229)","rgb(31,119,180)"],dark_blue:["rgb(31,119,180)","rgb(31, 120, 150)"],light_blue:["rgb(23,190,207)","rgb(158,218,229)","rgb(108, 218, 229)","rgb(23,190,227)"],lilac_blue:["rgb(124,102,211)","rgb(149,134,217)","rgb(97, 81, 150)"],dark_green:["rgb(23,103,57)","rgb(30,110,96)","rgb(60,131,95)","rgb(24,110,79)"],green:["rgb(44,160,44)","rgb(74,160,74)"],light_green:["rgb(152,223,138)","rgb(182, 223, 138)","rgb(152, 193, 138)"],st_green:["rgb(44,160,44)","rgb(152,223,138)","rgb(39, 174, 96)","rgb(74,160,74)"],pink:["rgb(247,182,210)"],brown:["rgb(140,86,75)","rgb(102, 62, 54)"],gray:["rgb(127,127,127)","rgb(199,199,199)","rgb(196,156,148)","rgb(222, 222, 180)"],yellow:["rgb(188,189,34)"],white:["rgb(230,230,230)"]};class s extends i{static get Lesk(){return void 0===this.lesk&&(this.lesk=this.makePalette([[["G","A","S","T"],"orange"],[["C","V","I","L","P","F","Y","M","W"],"all_green"],[["N","Q","H"],"magenta"],[["D","E"],"red"],[["K","R"],"all_blue"]],!1,s)),this.lesk}static get GrokGroups(){return void 0===this.grokGroups&&(this.grokGroups=this.makePalette([[["C","U"],"yellow"],[["G","P"],"red"],[["A","V","I","L","M","F","Y","W"],"all_green"],[["R","H","K"],"light_blue"],[["D","E"],"dark_blue"],[["S","T","N","Q"],"orange"]],!1,s)),this.grokGroups}static get RasMol(){return void 0===this.rasMol&&(this.rasMol=new s({D:"#E60A0A",E:"#E60A0A",C:"#E6E600",M:"#E6E600",K:"#145AFF",R:"#145AFF",S:"#FA9600",T:"#FA9600",F:"#3232AA",Y:"#3232AA",N:"#00DCDC",Q:"#00DCDC",G:"#EBEBEB",L:"#0F820F",V:"#0F820F",I:"#0F820F",A:"#C8C8C8",W:"#B45AB4",H:"#8282D2",P:"#DC9682",others:"#BEA06E"})),this.rasMol}get(t){const e=t in s.aaSynonyms?s.aaSynonyms[t]:t;return super.get(e)}}s.aaSynonyms={MeNle:"L",MeA:"A",MeG:"G",MeF:"F"};class a{static getPalette(t="grok"){switch(t){case"grok":return s.GrokGroups;case"lesk":return s.Lesk;default:throw new Error(`ChemPalette: scheme \`${t}\` does not exist`)}}static getInnerOuter(t){let e=0,n="",r="";for(const o of t)"("==o?e++:")"==o?e--:e?n+=o:r+=o;return isNaN(parseInt(n))?[r,n]:[r,""]}static getColorAAPivot(t="",e="grok"){const n=this.getPalette(e);let[r,o]=this.getInnerOuter(t);if(r=r.length>6?`${r.slice(0,3)}...`:r,o=o.length>6?`${o.slice(0,3)}...`:o,1==t.length||"("==t[1]){const e=t[0]?.toUpperCase();return e in n?[n.get(e),e,o,1]:[this.undefinedColor,r,o,1]}if("d"==t[0]&&t[1]in n&&(2==t.length||"("==t[2])){const e=t[1]?.toUpperCase();return e in n?[n.get(e),e,o,2]:[this.undefinedColor,r,o,2]}if(t.substring(0,3)in this.AAFullNames&&(3==t.length||"("==t[3])){const e=this.AAFullNames[t.substring(0,3)];return e in n?[n.get(e),e,o,3]:[this.undefinedColor,r,o,3]}if(t[0]?.toLowerCase()==t[0]&&t.substring(1,3)in this.AAFullNames&&(4==t.length||"("==t[4])){const e=this.AAFullNames[t.substring(1,3)];return e in n?[n.get(e),e,o,4]:[this.undefinedColor,r,o,4]}return[this.undefinedColor,r,o,0]}}a.SemType="Aminoacids",a.SemTypeMultipleAlignment="AminoacidsMultipleAlignment",a.undefinedColor="rgb(100,100,100)",a.Names={G:"Glycine",L:"Leucine",Y:"Tyrosine",S:"Serine",E:"Glutamic acid",Q:"Glutamine",D:"Aspartic acid",N:"Asparagine",F:"Phenylalanine",A:"Alanine",K:"Lysine",R:"Arginine",H:"Histidine",C:"Cysteine",V:"Valine",P:"Proline",W:"Tryptophan",I:"Isoleucine",M:"Methionine",T:"Threonine"},a.AASmiles={G:"NCC(=O)O",L:"N[C@H](CC(C)C)C(=O)O",Y:"NC(CC1=CC=C(O)C=C1)C(=O)O",S:"NC(CO)C(=O)O",E:"N[C@@H](CCC(O)=O)C(=O)O",Q:"N[C@@H](CCC(N)=O)C(=O)O",D:"N[C@@H](CC(O)=O)C(=O)O",N:"N[C@@H](CC(N)=O)C(=O)O",F:"NC(CC1=CC=CC=C1)C(=O)O",A:"N[C@H](C)C(=O)O",K:"NC(CCCCN)C(=O)O",R:"N[C@H](CCCNC(=N)C)C(=O)O",H:"NC(CC1=CN=C[N]1)C(=O)O",C:"N[C@@H](CS)C(=O)O",V:"NC(C(C)C)C(=O)O",P:"N(CCC1)C1C(=O)O",W:"N[C@@H](Cc1c2ccccc2n([H])c1)C(=O)O",I:"N[C@H]([C@H](C)CC)C(=O)O",M:"NC(CCSC)C(=O)O",T:"NC(C(O)C)C(=O)O"},a.AASmilesTruncated={G:"*C*",L:"CC(C)C[C@H](*)*",Y:"C1=CC(=CC=C1CC(*)*)O",S:"OCC(*)C*",E:"*[C@@H](CCC(O)=O)*",Q:"*N[C@@H](CCC(N)=O)*",D:"*[C@@H](CC(O)=O)*",N:"*[C@@H](CC(N)=O)*",F:"C1=CC=C(C=C1)CC(*)*",A:"C[C@H](*)*",K:"C(CCN)CC(*)*",R:"*[C@H](CCCNC(=N)C)*",H:"C1=C(NC=N1)CC(*)*",C:"C([C@@H](*)*)S",V:"CC(C)C(*)*",P:"C1CCN(*)C1*",W:"*[C@@H](Cc1c2ccccc2n([H])c1)*",I:"CC[C@H](C)[C@H](*)*",M:"CSCCC(*)*",T:"CC(O)C(*)*"},a.AAFullNames={Ala:"A",Arg:"R",Asn:"N",Asp:"D",Cys:"C",Gln:"Q",Glu:"E",Gly:"G",His:"H",Ile:"I",Leu:"L",Lys:"K",Met:"M",Phe:"F",Pro:"P",Ser:"S",Thr:"T",Trp:"W",Tyr:"Y",Val:"V"};class u{}u.SemType="Nucleotides",u.SemTypeMultipleAlignment="NucleotidesMultipleAlignment",u.Names={A:"Adenine",C:"Cytosine",G:"Guanine",T:"Thymine",U:"Uracil"};var c=n(890);function l(t,e=!0){if(null==t)return"rgb(100,100,100)";const n=r.Color.fromHtml(t);if(e){const t=r.Color.g(n),e=r.Color.r(n),o=r.Color.b(n),i=Math.sqrt(Math.pow(0-e,2)+Math.pow(0-t,2)+Math.pow(0-o,2));if(i>210)return`rgb(${e/i*210},${t/i*210},${o/i*210})`}return r.Color.toRgb(n)}class f{static hashCode(t){let e=0;if(0===t.length)return e;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n),e|=0;return e}}class h{}class p extends h{static buildPalette(){return(0,c.pj)().then((t=>{t.awaitLoaded(1/0).then((()=>{const e=t.getMonomerLib();e.onChanged.subscribe((()=>{p.customMonomerColors={},p.polymerTypes=e.getPolymerTypes();for(const t of this.polymerTypes){const n=e.getMonomerSymbolsByType(t);for(const r of n){const n=e.getMonomer(t,r);n?.meta?.colors?.default?.background&&(this.customMonomerColors[r]||(this.customMonomerColors[r]={}),this.customMonomerColors[r][t]=l(n.meta.colors.default.background))}}}))}))})),[].concat(...Object.values(i.colourPalette))}get(t,e){const n=p.customMonomerColors[t],r=e??"PEPTIDE";if(n&&n[r])return n[r];const o=f.hashCode(t)%p.palette.length;return l(p.palette[o])}}p.palette=p.buildPalette(),p.customMonomerColors={},p.polymerTypes=[];class d{get length(){return this.mList.length}isGap(t){return this.getOriginal(t)===this.gapOriginalMonomer}getCanonical(t){if(this.length<=t)throw new Error("Index out of bounds");const e=this.mList[t];return e!==this.gapOriginalMonomer?e:o._S}getOriginal(t){if(this.length<=t)throw new Error("Index out of bounds");return this.mList[t]}constructor(t,e){this.mList=t,this.gapOriginalMonomer=e}}const g=/([^\W_]+)/g;function m(t,e){if(t.length<=e)return t;const n=t.match(g),r=t.length>e||(n?.length??0)>1,o=n?.[0]??" ";return r?o.substring(0,e-1)+"…":o}},312:(t,e,n)=>{"use strict";n.d(e,{Q:()=>o});var r=n(82);async function o(){const t=r.Func.find({package:"Bio",name:"getSeqHelper"});if(0===t.length)throw new Error("Package 'Bio' must be installed for SeqHelper.");return(await t[0].prepare().call()).getOutputParamValue()}},869:(t,e,n)=>{"use strict";var r;n.d(e,{o:()=>r}),function(t){t.BASE="HELM_BASE",t.SUGAR="HELM_SUGAR",t.LINKER="HELM_LINKER",t.AA="HELM_AA",t.CHEM="HELM_CHEM",t.BLOB="HELM_BLOB",t.NUCLEOTIDE="HELM_NUCLETIDE"}(r||(r={}))},70:(t,e,n)=>{"use strict";n.d(e,{Pl:()=>N,gM:()=>S,L1:()=>O,E3:()=>x,J6:()=>P,Xb:()=>M,N$:()=>$,t6:()=>E,PE:()=>C,CN:()=>p});var r=n(328),o=n(82);n(982);const i=o.DataFrame.fromCsv('countries,fasta,smiles,molregno,LON,Zip Code,Street Address Line 1,ImageUrl,user_id,error_message,xray,flag,magnitude,CS-id,pdb_id,accel_a,time_offset,chart,fit,Questions,empty_number,empty_string\nBelgium,MSNFHNEHVMQFYRNNLKTKGVFGRQ,CC(C(=O)OCCCc1cccnc1)c2cccc(c2)C(=O)c3ccccc3,1480014,36.276729583740234,995042300,14016 ROUTE 31W,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,1,1,1QBS,1,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.497360340644872, 1.7058694986686864, 5.278052678195135, 0.16000320889028383],""points"":[{""x"":0.10000000149011612,""y"":2.374499797821045},{""x"":0.6000000238418579,""y"":2.6242473125457764},{""x"":1.100000023841858,""y"":2.367267608642578},{""x"":1.600000023841858,""y"":2.6723148822784424},{""x"":2.0999999046325684,""y"":2.6537344455718994},{""x"":2.5999999046325684,""y"":2.3651671409606934},{""x"":3.0999999046325684,""y"":2.5654284954071045},{""x"":3.5999999046325684,""y"":2.4160959720611572},{""x"":4.099999904632568,""y"":2.286726713180542},{""x"":4.599999904632568,""y"":2.5100042819976807},{""x"":5.099999904632568,""y"":1.6676985025405884},{""x"":5.599999904632568,""y"":0.680136501789093},{""x"":6.099999904632568,""y"":0.3391543924808502},{""x"":6.599999904632568,""y"":0.09038983285427094},{""x"":7.099999904632568,""y"":0.19802775979042053}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[7.525235855508179, 1.3186911876809984, 5.335672608564294, 0.7860743343958098],""points"":[{""x"":0.10000000149011612,""y"":7.988070487976074},{""x"":0.6000000238418579,""y"":7.018453121185303},{""x"":1.100000023841858,""y"":8.115279197692871},{""x"":1.600000023841858,""y"":7.486658096313477},{""x"":2.0999999046325684,""y"":7.396438121795654},{""x"":2.5999999046325684,""y"":7.477052211761475},{""x"":3.0999999046325684,""y"":6.913095474243164},{""x"":3.5999999046325684,""y"":8.01385498046875},{""x"":4.099999904632568,""y"":6.985900402069092},{""x"":4.599999904632568,""y"":6.970335960388184},{""x"":5.099999904632568,""y"":5.448817253112793},{""x"":5.599999904632568,""y"":2.5534818172454834},{""x"":6.099999904632568,""y"":1.893947958946228},{""x"":6.599999904632568,""y"":0.6340042352676392},{""x"":7.099999904632568,""y"":0.8403874039649963}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,100,abc\nBurundi,MDYKETLLMPKTDFPMRGGLPNKEPQIQEKW,COc1ccc2cc(ccc2c1)C(C)C(=O)Oc3ccc(C)cc3OC,1480015,36.276729583740234,995073444,80 STATE HIGHWAY 310,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,2,2,1ZP8,2,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[4.431460753103398, 2.1691498799246745, 5.266445597102774, 0.7825762827017926],""points"":[{""x"":0.10000000149011612,""y"":4.751083850860596},{""x"":0.6000000238418579,""y"":4.203000068664551},{""x"":1.100000023841858,""y"":4.415858745574951},{""x"":1.600000023841858,""y"":4.68414306640625},{""x"":2.0999999046325684,""y"":4.198400974273682},{""x"":2.5999999046325684,""y"":4.179222106933594},{""x"":3.0999999046325684,""y"":4.638473987579346},{""x"":3.5999999046325684,""y"":4.708553314208984},{""x"":4.099999904632568,""y"":4.291589260101318},{""x"":4.599999904632568,""y"":4.038082599639893},{""x"":5.099999904632568,""y"":3.4349939823150635},{""x"":5.599999904632568,""y"":1.2194708585739136},{""x"":6.099999904632568,""y"":1.1920831203460693},{""x"":6.599999904632568,""y"":0.5352635979652405},{""x"":7.099999904632568,""y"":0.3346920311450958}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[2.339458017970126, -1.0734184310171178, 4.746332950550934, 0.2482416857595658],""points"":[{""x"":0.10000000149011612,""y"":0.2139337658882141},{""x"":0.6000000238418579,""y"":0.4269562065601349},{""x"":1.100000023841858,""y"":0.2441573292016983},{""x"":1.600000023841858,""y"":0.146635964512825},{""x"":2.0999999046325684,""y"":0.08818462491035461},{""x"":2.5999999046325684,""y"":0.2560656666755676},{""x"":3.0999999046325684,""y"":0.42434045672416687},{""x"":3.5999999046325684,""y"":0.37111231684684753},{""x"":4.099999904632568,""y"":0.5581737160682678},{""x"":4.599999904632568,""y"":1.183590054512024},{""x"":5.099999904632568,""y"":1.5629843473434448},{""x"":5.599999904632568,""y"":2.3211288452148438},{""x"":6.099999904632568,""y"":2.229961633682251},{""x"":6.599999904632568,""y"":2.2560226917266846},{""x"":7.099999904632568,""y"":2.2142398357391357}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCameroon,MIEVFLFGIVLGLIPITLAGLFVTAYLQYRRGDQLDL,COc1ccc2cc(ccc2c1)C(C)C(=O)OCCCc3cccnc3,1480016,36.26095962524414,995153596,30-56 WHITESTONE EXPY,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,3,3,2BDJ,3,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[4.6760652578642325, 0.9046956320756703, 5.651408971856738, 0.07738846012184185],""points"":[{""x"":0.10000000149011612,""y"":4.32425594329834},{""x"":0.6000000238418579,""y"":4.668442249298096},{""x"":1.100000023841858,""y"":4.379785060882568},{""x"":1.600000023841858,""y"":5.0345139503479},{""x"":2.0999999046325684,""y"":4.878653526306152},{""x"":2.5999999046325684,""y"":4.3451313972473145},{""x"":3.0999999046325684,""y"":4.336992263793945},{""x"":3.5999999046325684,""y"":5.037430286407471},{""x"":4.099999904632568,""y"":5.0092692375183105},{""x"":4.599999904632568,""y"":4.151902675628662},{""x"":5.099999904632568,""y"":3.4066951274871826},{""x"":5.599999904632568,""y"":2.3732759952545166},{""x"":6.099999904632568,""y"":1.673728108406067},{""x"":6.599999904632568,""y"":0.48574790358543396},{""x"":7.099999904632568,""y"":0.2783052325248718}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[2.938395863010111, -1.4658480661392117, 5.462702751996584, 0.3473139023615039],""points"":[{""x"":0.10000000149011612,""y"":0.4941710829734802},{""x"":0.6000000238418579,""y"":0.15323974192142487},{""x"":1.100000023841858,""y"":0.46373432874679565},{""x"":1.600000023841858,""y"":0.3370431363582611},{""x"":2.0999999046325684,""y"":0.5179030299186707},{""x"":2.5999999046325684,""y"":0.27899765968322754},{""x"":3.0999999046325684,""y"":0.22075064480304718},{""x"":3.5999999046325684,""y"":0.5789918899536133},{""x"":4.099999904632568,""y"":0.21169911324977875},{""x"":4.599999904632568,""y"":0.27857646346092224},{""x"":5.099999904632568,""y"":1.0906332731246948},{""x"":5.599999904632568,""y"":1.8520300388336182},{""x"":6.099999904632568,""y"":2.7177059650421143},{""x"":6.599999904632568,""y"":2.8680918216705322},{""x"":7.099999904632568,""y"":3.2413077354431152}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCanada,MMELVLKTIIGPIVVGVVLRIVDKWLNKDK,CC(C(=O)NCCS)c1cccc(c1)C(=O)c2ccccc2,1480017,36.26095962524414,99515,30-56 WHITESTONE EXPY,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,4,4,1IAN,4,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[0.8597390975430008, 1.0957625732481946, 5.260537067987958, 0.07974187998177736],""points"":[{""x"":0.10000000149011612,""y"":0.8190152645111084},{""x"":0.6000000238418579,""y"":0.8421689867973328},{""x"":1.100000023841858,""y"":0.8740922212600708},{""x"":1.600000023841858,""y"":0.8924275040626526},{""x"":2.0999999046325684,""y"":0.8249067664146423},{""x"":2.5999999046325684,""y"":0.9327669143676758},{""x"":3.0999999046325684,""y"":0.8522974252700806},{""x"":3.5999999046325684,""y"":0.8174492716789246},{""x"":4.099999904632568,""y"":0.8394647240638733},{""x"":4.599999904632568,""y"":0.7139387726783752},{""x"":5.099999904632568,""y"":0.5561167597770691},{""x"":5.599999904632568,""y"":0.3276226818561554},{""x"":6.099999904632568,""y"":0.12479474395513535},{""x"":6.599999904632568,""y"":0.13006797432899475},{""x"":7.099999904632568,""y"":0.059702079743146896}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.760930219582546, 1.6591793293833013, 4.667155929720851, 0.7858109544121652],""points"":[{""x"":0.10000000149011612,""y"":6.156993389129639},{""x"":0.6000000238418579,""y"":5.236701965332031},{""x"":1.100000023841858,""y"":6.010560512542725},{""x"":1.600000023841858,""y"":5.495512962341309},{""x"":2.0999999046325684,""y"":6.087770462036133},{""x"":2.5999999046325684,""y"":5.79986572265625},{""x"":3.0999999046325684,""y"":5.597546577453613},{""x"":3.5999999046325684,""y"":5.520902156829834},{""x"":4.099999904632568,""y"":5.360654354095459},{""x"":4.599999904632568,""y"":3.5539746284484863},{""x"":5.099999904632568,""y"":1.577236294746399},{""x"":5.599999904632568,""y"":1.0001264810562134},{""x"":6.099999904632568,""y"":0.9305797815322876},{""x"":6.599999904632568,""y"":0.6033638715744019},{""x"":7.099999904632568,""y"":0.4203685522079468}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nColombia,MDRTDEVSNHTHDKPTLTWFEEIFEEYHSPFHN,FC(F)(F)c1ccc(OC2CCNCC2)cc1,1480029,36.3309440612793,995152050,1 COURT HOUSE SQUARE,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,5,5,4UJ1,5,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[6.4995088314153655, 2.4270351004539914, 5.178659535348579, 0.625653346241577],""points"":[{""x"":0.10000000149011612,""y"":6.496231555938721},{""x"":0.6000000238418579,""y"":6.42543363571167},{""x"":1.100000023841858,""y"":7.040063858032227},{""x"":1.600000023841858,""y"":6.1115403175354},{""x"":2.0999999046325684,""y"":6.680728435516357},{""x"":2.5999999046325684,""y"":6.406774520874023},{""x"":3.0999999046325684,""y"":6.611269474029541},{""x"":3.5999999046325684,""y"":5.889094352722168},{""x"":4.099999904632568,""y"":6.75344705581665},{""x"":4.599999904632568,""y"":6.361435890197754},{""x"":5.099999904632568,""y"":4.1666975021362305},{""x"":5.599999904632568,""y"":1.172118902206421},{""x"":6.099999904632568,""y"":0.801048994064331},{""x"":6.599999904632568,""y"":0.4640021026134491},{""x"":7.099999904632568,""y"":0.0010357667924836278}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[1.4734381347446401, 1.1649805188074196, 4.82958608866421, 0.09500545496710007],""points"":[{""x"":0.10000000149011612,""y"":1.5279096364974976},{""x"":0.6000000238418579,""y"":1.3559974431991577},{""x"":1.100000023841858,""y"":1.5246378183364868},{""x"":1.600000023841858,""y"":1.5567657947540283},{""x"":2.0999999046325684,""y"":1.4114240407943726},{""x"":2.5999999046325684,""y"":1.4045010805130005},{""x"":3.0999999046325684,""y"":1.4769829511642456},{""x"":3.5999999046325684,""y"":1.4875500202178955},{""x"":4.099999904632568,""y"":1.2991987466812134},{""x"":4.599999904632568,""y"":0.922961413860321},{""x"":5.099999904632568,""y"":0.6520044803619385},{""x"":5.599999904632568,""y"":0.15350978076457977},{""x"":6.099999904632568,""y"":0.1078903079032898},{""x"":6.599999904632568,""y"":0.17276449501514435},{""x"":7.099999904632568,""y"":0.14066608250141144}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCosta Rica,MKSTKEEIQTIKTLLKDSRTAKYHKRLQIVL,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCCc3ccccc3,1480018,36.3309440612793,995084218,4041 SOUTHWESTERN BLVD,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,6,6,2BPW,6,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.4833641843311227, -1.8945978742090062, 4.671127708092568, 0.24159861311815153],""points"":[{""x"":0.10000000149011612,""y"":0.0969524160027504},{""x"":0.6000000238418579,""y"":0.028483040630817413},{""x"":1.100000023841858,""y"":0.22087176144123077},{""x"":1.600000023841858,""y"":0.0068915546871721745},{""x"":2.0999999046325684,""y"":0.4305879771709442},{""x"":2.5999999046325684,""y"":0.44774115085601807},{""x"":3.0999999046325684,""y"":0.45346319675445557},{""x"":3.5999999046325684,""y"":0.2370593100786209},{""x"":4.099999904632568,""y"":0.4657953977584839},{""x"":4.599999904632568,""y"":1.155200719833374},{""x"":5.099999904632568,""y"":2.2294070720672607},{""x"":5.599999904632568,""y"":2.4311530590057373},{""x"":6.099999904632568,""y"":2.33846116065979},{""x"":6.599999904632568,""y"":2.608201026916504},{""x"":7.099999904632568,""y"":2.8136143684387207}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.224573521642033, 1.4454033924198528, 5.6014197746076535, 0.2823216054197577],""points"":[{""x"":0.10000000149011612,""y"":4.95027494430542},{""x"":0.6000000238418579,""y"":5.1754679679870605},{""x"":1.100000023841858,""y"":5.276752948760986},{""x"":1.600000023841858,""y"":5.589294910430908},{""x"":2.0999999046325684,""y"":5.616994857788086},{""x"":2.5999999046325684,""y"":5.120813846588135},{""x"":3.0999999046325684,""y"":5.340766906738281},{""x"":3.5999999046325684,""y"":4.876471042633057},{""x"":4.099999904632568,""y"":4.94999361038208},{""x"":4.599999904632568,""y"":5.162564754486084},{""x"":5.099999904632568,""y"":4.399557590484619},{""x"":5.599999904632568,""y"":2.7977969646453857},{""x"":6.099999904632568,""y"":1.0229872465133667},{""x"":6.599999904632568,""y"":0.48275601863861084},{""x"":7.099999904632568,""y"":0.10408931970596313}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCuba,MHAILRYFIRRLFYHIFYKIYSLISKKHQSLPSDVRQF,COc1ccc2c(c1)c(CC(=O)N3CCCC3C(=O)Oc4ccc(C)cc4OC)c(C)n2C(=O)c5ccc(Cl)cc5,1480019,36.33115768432617,995081928,1227 US HIGHWAY 11,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,7,7,1QBS,7,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[3.320838679713925, -1.2421619987316728, 4.831325425225256, 0.3236011098403072],""points"":[{""x"":0.10000000149011612,""y"":0.3727470338344574},{""x"":0.6000000238418579,""y"":0.12365014106035233},{""x"":1.100000023841858,""y"":0.48422467708587646},{""x"":1.600000023841858,""y"":0.2264465093612671},{""x"":2.0999999046325684,""y"":0.16821794211864471},{""x"":2.5999999046325684,""y"":0.3879014551639557},{""x"":3.0999999046325684,""y"":0.5470244884490967},{""x"":3.5999999046325684,""y"":0.3419053554534912},{""x"":4.099999904632568,""y"":0.7655120491981506},{""x"":4.599999904632568,""y"":1.2346516847610474},{""x"":5.099999904632568,""y"":2.453336715698242},{""x"":5.599999904632568,""y"":2.9565491676330566},{""x"":6.099999904632568,""y"":3.335299491882324},{""x"":6.599999904632568,""y"":3.240290880203247},{""x"":7.099999904632568,""y"":3.1107218265533447}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[3.6401853521511094, 1.26211588875013, 5.399028074402744, 0.5089580830068091],""points"":[{""x"":0.10000000149011612,""y"":3.8585598468780518},{""x"":0.6000000238418579,""y"":3.6077206134796143},{""x"":1.100000023841858,""y"":3.855252265930176},{""x"":1.600000023841858,""y"":3.619039297103882},{""x"":2.0999999046325684,""y"":3.839388370513916},{""x"":2.5999999046325684,""y"":3.335283041000366},{""x"":3.0999999046325684,""y"":3.571141481399536},{""x"":3.5999999046325684,""y"":3.4155046939849854},{""x"":4.099999904632568,""y"":3.7316646575927734},{""x"":4.599999904632568,""y"":3.0680155754089355},{""x"":5.099999904632568,""y"":2.891066551208496},{""x"":5.599999904632568,""y"":1.6022753715515137},{""x"":6.099999904632568,""y"":0.7652576565742493},{""x"":6.599999904632568,""y"":0.6875326037406921},{""x"":7.099999904632568,""y"":0.5828871726989746}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nItaly,MSNFHNEHVMQFYRNNLKTKGVFGRQ,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCO[N+](=O)[O-],1480020,36.33115768432617,99502,"168-46 91ST AVE., 2ND FLR",https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,8,8,1ZP8,8,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.293592105923809, 1.3781586549141835, 5.1025898038676605, 0.03493851245291291],""points"":[{""x"":0.10000000149011612,""y"":2.1287283897399902},{""x"":0.6000000238418579,""y"":2.267972230911255},{""x"":1.100000023841858,""y"":2.398442506790161},{""x"":1.600000023841858,""y"":2.5130622386932373},{""x"":2.0999999046325684,""y"":2.3255116939544678},{""x"":2.5999999046325684,""y"":2.127340793609619},{""x"":3.0999999046325684,""y"":2.47259783744812},{""x"":3.5999999046325684,""y"":2.131181478500366},{""x"":4.099999904632568,""y"":2.090421438217163},{""x"":4.599999904632568,""y"":2.02299165725708},{""x"":5.099999904632568,""y"":1.1105059385299683},{""x"":5.599999904632568,""y"":0.4494485855102539},{""x"":6.099999904632568,""y"":0.1375635862350464},{""x"":6.599999904632568,""y"":0.036351121962070465},{""x"":7.099999904632568,""y"":0.1619771122932434}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.953125499439879, 1.2528620255306528, 5.187637440149802, 0.3110348753260886],""points"":[{""x"":0.10000000149011612,""y"":5.6585283279418945},{""x"":0.6000000238418579,""y"":5.911152362823486},{""x"":1.100000023841858,""y"":5.924920082092285},{""x"":1.600000023841858,""y"":5.8469438552856445},{""x"":2.0999999046325684,""y"":5.929472923278809},{""x"":2.5999999046325684,""y"":6.190037727355957},{""x"":3.0999999046325684,""y"":6.236179828643799},{""x"":3.5999999046325684,""y"":6.141019344329834},{""x"":4.099999904632568,""y"":5.295210838317871},{""x"":4.599999904632568,""y"":5.265801906585693},{""x"":5.099999904632568,""y"":3.3722851276397705},{""x"":5.599999904632568,""y"":1.8299226760864258},{""x"":6.099999904632568,""y"":0.32690900564193726},{""x"":6.599999904632568,""y"":0.6274543404579163},{""x"":7.099999904632568,""y"":0.8441857099533081}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nRwanda,MPNSEPASLLELFNSIATQGELVRSLKAGNASK,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCO,1480021,36.33137130737305,995037247,"168-46 91ST AVE., 2ND FLR",https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,9,9,2BDJ,9,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[3.8209972202654474, 1.3779216716448506, 5.299882228439686, 0.06040645519069608],""points"":[{""x"":0.10000000149011612,""y"":3.7821109294891357},{""x"":0.6000000238418579,""y"":3.542433023452759},{""x"":1.100000023841858,""y"":3.7008674144744873},{""x"":1.600000023841858,""y"":3.717301607131958},{""x"":2.0999999046325684,""y"":4.024452209472656},{""x"":2.5999999046325684,""y"":4.013899326324463},{""x"":3.0999999046325684,""y"":3.945094347000122},{""x"":3.5999999046325684,""y"":3.866621971130371},{""x"":4.099999904632568,""y"":3.7461626529693604},{""x"":4.599999904632568,""y"":3.3454740047454834},{""x"":5.099999904632568,""y"":2.61944317817688},{""x"":5.599999904632568,""y"":0.999405026435852},{""x"":6.099999904632568,""y"":0.46259793639183044},{""x"":6.599999904632568,""y"":0.054134611040353775},{""x"":7.099999904632568,""y"":0.05711187422275543}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.6318079657726035, 1.8495493770000595, 5.391793312471116, 0.17060707587348442],""points"":[{""x"":0.10000000149011612,""y"":5.458079814910889},{""x"":0.6000000238418579,""y"":5.554427146911621},{""x"":1.100000023841858,""y"":5.799983024597168},{""x"":1.600000023841858,""y"":5.364140033721924},{""x"":2.0999999046325684,""y"":5.864485740661621},{""x"":2.5999999046325684,""y"":5.4509806632995605},{""x"":3.0999999046325684,""y"":5.702574729919434},{""x"":3.5999999046325684,""y"":5.7314534187316895},{""x"":4.099999904632568,""y"":5.5123443603515625},{""x"":4.599999904632568,""y"":5.724395751953125},{""x"":5.099999904632568,""y"":4.354506969451904},{""x"":5.599999904632568,""y"":1.7307666540145874},{""x"":6.099999904632568,""y"":0.6305936574935913},{""x"":6.599999904632568,""y"":0.035183437168598175},{""x"":7.099999904632568,""y"":0.7575169205665588}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nSwitzerland,IRVVGRYLIEVWKAAGMDMDKVLFLWSSDEI,CN1CCC(CC1)Oc2ccc(cc2)C(F)(F)F,1480028,36.33137130737305,99504,92-11 179TH PLACE,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,9,10,1IAN,10,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[1.1190255865097471, 2.3163895161544437, 5.4968866182279195, 0.2035204047289052],""points"":[{""x"":0.10000000149011612,""y"":1.1057683229446411},{""x"":0.6000000238418579,""y"":1.1019697189331055},{""x"":1.100000023841858,""y"":1.0818607807159424},{""x"":1.600000023841858,""y"":1.062997817993164},{""x"":2.0999999046325684,""y"":1.046447515487671},{""x"":2.5999999046325684,""y"":1.1217249631881714},{""x"":3.0999999046325684,""y"":1.2166996002197266},{""x"":3.5999999046325684,""y"":1.215477705001831},{""x"":4.099999904632568,""y"":1.0581893920898438},{""x"":4.599999904632568,""y"":1.1747995615005493},{""x"":5.099999904632568,""y"":1.0181127786636353},{""x"":5.599999904632568,""y"":0.5344523191452026},{""x"":6.099999904632568,""y"":0.2569526433944702},{""x"":6.599999904632568,""y"":0.1912207305431366},{""x"":7.099999904632568,""y"":0.15060538053512573}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[3.1038581025805785, 2.0032224204185245, 5.087602825989163, 0.13277988512492753],""points"":[{""x"":0.10000000149011612,""y"":3.0498509407043457},{""x"":0.6000000238418579,""y"":2.805217742919922},{""x"":1.100000023841858,""y"":3.3415253162384033},{""x"":1.600000023841858,""y"":3.0549843311309814},{""x"":2.0999999046325684,""y"":3.250074863433838},{""x"":2.5999999046325684,""y"":3.0432586669921875},{""x"":3.0999999046325684,""y"":3.265852451324463},{""x"":3.5999999046325684,""y"":2.9475724697113037},{""x"":4.099999904632568,""y"":3.1929898262023926},{""x"":4.599999904632568,""y"":2.7460060119628906},{""x"":5.099999904632568,""y"":1.6175861358642578},{""x"":5.599999904632568,""y"":0.3006608486175537},{""x"":6.099999904632568,""y"":0.3444803059101105},{""x"":6.599999904632568,""y"":0.015537971630692482},{""x"":7.099999904632568,""y"":0.5527358055114746}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\n,,,,,,,,,,,,,,,,,,,,,');i.columns.add(o.Column.fromList(o.TYPE.BYTE_ARRAY,"BinaryImage",Array.from(new Uint8Array(11))));var s=function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))};const a=3e4,u=108e5,c=console.log.bind(console),l=console.info.bind(console),f=console.warn.bind(console),h=console.error.bind(console),p={},d="Auto Tests",g="Demo",m="Detectors",y="Core",v={};let b;var w;!function(t){t.notNull=function(t,e){if(null==t)throw new Error(`${null==e?"Value":e} not defined`)}}(w||(w={}));class A{constructor(t,e){this.catchUnhandled=!0,this.report=!1,void 0!==t&&(this.catchUnhandled=t),void 0!==e&&(this.report=e)}}class _{constructor(t,e,n,r){var o;this.category=t,this.name=e,null!=r||(r={}),null!==(o=r.timeout)&&void 0!==o||(r.timeout=a),this.options=r,this.test=()=>s(this,void 0,void 0,(function*(){return new Promise(((t,e)=>s(this,void 0,void 0,(function*(){let r="";try{r=yield n()}catch(t){e(t)}t(r)}))))}))}}function C(t,e,n,r=0,o="timeout"){return s(this,void 0,void 0,(function*(){return new Promise(((i,s)=>{const a=t.subscribe((t=>{try{e(t),i("OK")}catch(t){s(t)}finally{a.unsubscribe(),clearTimeout(u)}})),u=setTimeout((()=>{a.unsubscribe(),s(o)}),r);n()}))}))}function E(t,e,n){null==p[b]&&(p[b]={}),null==p[b].tests&&(p[b].tests=[]),p[b].tests.push(new _(b,t,e,n))}function x(t,e=!0,n){if(n=n?`${n}, `:"",t!==e)throw new Error(`${n}Expected "${e}", got "${t}"`)}function T(t,e,n=.001,r){if(t===Number.POSITIVE_INFINITY&&e===Number.POSITIVE_INFINITY||t===Number.NEGATIVE_INFINITY&&e===Number.NEGATIVE_INFINITY||t===Number.NaN&&e===Number.NaN||isNaN(t)&&isNaN(e))return;const o=Math.abs(t-e)<n;if(x(o,!0,`${null!=r?r:""} (tolerance = ${n})`),!o)throw new Error(`Expected ${e}, got ${t} (tolerance = ${n})`)}function I(t,e){for(const[n,r]of Object.entries(e)){if(!t.hasOwnProperty(n))throw new Error(`Expected property "${n}" not found`);const e=t[n];if(e instanceof Array&&r instanceof Array)P(e,r);else if(e instanceof Object&&r instanceof Object)I(e,r);else if(Number.isFinite(e)&&Number.isFinite(r))T(e,r);else if(e!=r)throw new Error(`Expected (${r}) for key '${n}', got (${e})`)}}function P(t,e){const n=t.length,r=e.length;if(n!=r)throw new Error(`Arrays are of different length: actual array length is ${n} and expected array length is ${r}`);for(let r=0;r<n;r++)if(t[r]instanceof Array&&e[r]instanceof Array)P(t[r],e[r]);else if(t[r]instanceof Object&&e[r]instanceof Object)I(t[r],e[r]);else if(t[r]!=e[r])throw new Error(`Expected ${e[r]} at position ${r}, got ${t[r]}`)}function O(t,e,n){var r;b=t,e(),p[b]&&(p[b].clear=null===(r=null==n?void 0:n.clear)||void 0===r||r,p[b].timeout=null==n?void 0:n.timeout,p[b].benchmarks=null==n?void 0:n.benchmarks,p[b].stressTests=null==n?void 0:n.stressTests)}function S(t){null==p[b]&&(p[b]={}),p[b].before=t}function N(t){null==p[b]&&(p[b]={}),p[b].after=t}function L(t,e){return t.replace(new RegExp(e.name,"gi"),e.nqName)}function M(t,e){var n,u,c,l;return s(this,void 0,void 0,(function*(){const f=t.id;if(v[f])return;const h=e?e.tests:p;if(void 0!==h[d]||void 0!==h[g]||Object.keys(h).find((t=>t.startsWith(d)||t.startsWith(y))))return void(v[f]=!0);if("DevTools"===t.name||e&&"DevTools"===e._package.name)for(const t of window.dartTests){const e=t.name.split(/\s*\|\s*!/g);let r=null!==(n=e.pop())&&void 0!==n?n:t.name,o=e.length?y+": "+e.join(": "):y,i=r.split(" | ");r=i[i.length-1],i.unshift(o),i.pop(),o=i.join(": "),void 0===h[o]&&(h[o]={tests:[],clear:!0}),h[o].tests.push(new _(o,r,t.test,{isAggregated:!1,timeout:null!==(c=null===(u=t.options)||void 0===u?void 0:u.timeout)&&void 0!==c?c:a,skipReason:null===(l=t.options)||void 0===l?void 0:l.skipReason}))}const b=[],w=[],A=[],C=yield r.dapi.functions.filter(`package.id = "${f}"`).list(),E=new RegExp(/skip:\s*([^,\s]+)|wait:\s*(\d+)|cat:\s*([^,\s]+)|timeout:\s*(\d+)/g);for(const e of C){const n=e.options.test,a=e.options.demoPath;if(n&&Array.isArray(n)&&n.length)for(let t=0;t<n.length;t++){const i=n[t].matchAll(E),a={};Array.from(i).forEach((t=>{t[0].startsWith("skip")?a.skip=t[1]:t[0].startsWith("wait")?a.wait=parseInt(t[2]):t[0].startsWith("cat")?a.cat=t[3]:t[0].startsWith("timeout")&&(a.timeout=parseInt(t[4]))}));const u=new _(d,1===n.length?e.name:`${e.name} ${t+1}`,(()=>s(this,void 0,void 0,(function*(){const o=yield r.functions.eval(L(n[t],e));if(a.wait&&(yield F(a.wait)),"boolean"==typeof o&&!o)throw`Failed: ${n[t]}, expected true, got ${o}`}))),{skipReason:a.skip,timeout:o.Test.isInBenchmark?a.benchmarkTimeout:a.timeout});if(a.cat){const t=d+": "+a.cat;u.category=t,void 0===h[t]&&(h[t]={tests:[],clear:!0}),h[t].tests.push(u)}else b.push(u)}if(a){const t=e.options.demoWait?parseInt(e.options.demoWait):void 0,n=new _(g,e.friendlyName,(()=>s(this,void 0,void 0,(function*(){r.shell.isInDemo=!0,void 0===r.shell.view(o.View.BROWSE)&&(r.shell.v=o.View.createByType(o.View.BROWSE)),yield F(300),r.shell.clearLastError(),yield e.apply(),yield F(t||2e3);const n=yield r.shell.lastError;if(n)throw new Error(n);r.shell.isInDemo=!1}))),{skipReason:e.options.demoSkip});w.push(n)}if(e.hasTag("semTypeDetector")){let n=i;e.options.testData&&(n=yield r.data.files.openTable(`System:AppData/${t.nqName}/${e.options.testData}`));const o=new _(m,e.friendlyName,(()=>s(this,void 0,void 0,(function*(){const r=[];console.log(`System:AppData/${t.nqName}/${e.options.testData}`);for(const t of n.clone().columns){const n=yield e.apply([t]);r.push(n||t.semType)}const o=r.filter((t=>t));x(o.length,1),e.options.testDataColumnName&&x(o[0],e.options.testDataColumnName)}))),{skipReason:e.options.skipTest});A.push(o)}}v[f]=!0,b.length>0&&(h[d]={tests:b,clear:!0}),w.length>0&&(h[g]={tests:w,clear:!0}),A.length>0&&(h[m]={tests:A,clear:!1})}))}function $(t){var e,n,i,a;return s(this,void 0,void 0,(function*(){const u=null===(n=null===(e=r.functions.getCurrentCall())||void 0===e?void 0:e.func)||void 0===n?void 0:n.package;yield M(u);const d=[];console.log("Running tests"),null!=t||(t={}),null!==(i=(a=t).testContext)&&void 0!==i||(a.testContext=new A),r.shell.clearLastError();const g=function(){const t=[];return console.log=(...e)=>{t.push(...e),c(...e)},console.info=(...e)=>{t.push(...e),l(...e)},console.warn=(...e)=>{t.push(...e),f(...e)},console.error=(...e)=>{t.push(...e),h(...e)},t}();yield function(t,e){var n,i,a,p,y,v,b,w,A;return s(this,void 0,void 0,(function*(){try{for(const[s,l]of Object.entries(t)){if((null==e?void 0:e.category)&&!s.toLowerCase().startsWith(null==e?void 0:e.category.toLowerCase())||(null===(n=e.exclude)||void 0===n?void 0:n.some((t=>s.startsWith(t)))))continue;c(`Started ${s} category`);const t=null===(i=l.tests)||void 0===i?void 0:i.every((t=>{var e;return null===(e=t.options)||void 0===e?void 0:e.skipReason}));t||(l.beforeStatus=yield m(l.before,null!==(a=e.category)&&void 0!==a?a:""));let f=null!==(p=l.tests)&&void 0!==p?p:[];e.stressTest&&(f=f.filter((t=>{var e;return null===(e=t.options)||void 0===e?void 0:e.stressTest})),f=R(f)),(null!==(v=null===(y=e.tags)||void 0===y?void 0:y.length)&&void 0!==v?v:0)>0&&(f=f.filter((t=>{var n,r;return null===(r=null===(n=t.options)||void 0===n?void 0:n.tags)||void 0===r?void 0:r.some((t=>{var n;return(null!==(n=null==e?void 0:e.tags)&&void 0!==n?n:[]).includes(t)}))})));const h=[];if(l.clear)for(let t=0;t<f.length;t++){f[t].options&&void 0===(null===(b=f[t].options)||void 0===b?void 0:b.benchmark)&&(f[t].options||(f[t].options={}),f[t].options.benchmark=null!==(w=l.benchmarks)&&void 0!==w&&w);let n=yield B(f[t],null==e?void 0:e.test,g,o.Test.isInBenchmark?l.benchmarkTimeout:l.timeout,u.name,e.verbose);n&&h.push(n),r.shell.closeAll(),o.Balloon.closeAll()}else for(let t=0;t<f.length;t++){let n=yield B(f[t],null==e?void 0:e.test,g,o.Test.isInBenchmark?l.benchmarkTimeout:l.timeout,u.name,e.verbose);n&&h.push(n)}const _=h.filter((t=>"skipped"!=t.result));t||(l.afterStatus=yield m(l.after,null!==(A=e.category)&&void 0!==A?A:"")),l.afterStatus&&_.push({date:(new Date).toISOString(),logs:"",category:s,name:"after",result:l.afterStatus,success:!1,ms:0,skipped:!1}),l.beforeStatus&&_.push({date:(new Date).toISOString(),logs:"",category:s,name:"before",result:l.beforeStatus,success:!1,ms:0,skipped:!1}),d.push(..._)}}finally{console.log=c,console.info=l,console.warn=f,console.error=h}if(e.testContext.catchUnhandled&&!o.Test.isInBenchmark){yield F(1e3);const t=yield r.shell.lastError,e={logs:"",date:(new Date).toISOString(),category:"Unhandled exceptions",name:"Exception",result:null!=t?t:"",success:!t,ms:0,skipped:!1};d.push(e),e.package=u.name,null!=r.shell.reportTest?yield r.shell.reportTest("package",e):yield fetch(`${r.dapi.root}/log/tests/package`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(e)})}}))}(p,t);for(let t of d)t.result=t.result.toString().replace(/"/g,"'"),null!=t.logs&&(t.logs=t.logs.toString().replace(/"/g,"'"));return d;function m(t,e){return s(this,void 0,void 0,(function*(){var n=void 0;try{void 0!==t&&(yield k((()=>s(this,void 0,void 0,(function*(){yield t()}))),1e5,`before ${e}: timeout error`))}catch(t){n=yield D(t)}return n}))}}))}function D(t){return s(this,void 0,void 0,(function*(){return`${t.toString()}\n${t.stack?yield o.Logger.translateStackTrace(t.stack):""}`}))}function B(t,e,n,i,l,f){var p,d,g,m,y,v,b,w;return s(this,void 0,void 0,(function*(){let s;n.length=0;let A="package";const _=null!=e&&t.name.toLowerCase()!==e.toLowerCase();let C=(null===(p=t.options)||void 0===p?void 0:p.skipReason)||_,E=_?"skipped":null===(d=t.options)||void 0===d?void 0:d.skipReason;if(o.Test.isInBenchmark&&!(null===(g=t.options)||void 0===g?void 0:g.benchmark))return void c(`SKIPPED: ${t.category} ${t.name} doesnt available in benchmark mode`);C||c(`Started ${t.category} ${t.name}`);const x=Date.now();try{if(C)s={date:(new Date).toISOString(),success:!0,result:E,ms:0,skipped:!0};else{let e=(null===(m=t.options)||void 0===m?void 0:m.timeout)===a&&i?i:null===(y=t.options)||void 0===y?void 0:y.timeout;e=e===a&&o.Test.isInBenchmark?u:e,s={date:(new Date).toISOString(),success:!0,result:null!==(v=yield k(t.test,e))&&void 0!==v?v:"OK",ms:0,skipped:!1}}}catch(t){h(t),s={date:(new Date).toISOString(),success:!1,result:yield D(t),ms:0,skipped:!1}}if((null===(b=t.options)||void 0===b?void 0:b.isAggregated)&&s.result.constructor===o.DataFrame){const t=s.result.col("success");if(t&&(s.success=t.stats.sum===t.length),!f){const t=s.result;t.columns.remove("stack"),t.rows.removeWhere((t=>t.get("success"))),s.result=t}s.result=s.result.toCsv()}if(s.logs=n.join("\n"),s.ms=Date.now()-x,C||c(`Finished ${t.category} ${t.name} for ${s.ms} ms`),s.category=t.category,s.name=t.name,!_){let e={success:s.success,result:s.result,ms:s.ms,skipped:s.skipped,package:l,category:t.category,name:t.name,logs:s.logs};if(s.result.constructor==Object){const t=Object.keys(s.result).reduce(((t,e)=>Object.assign(Object.assign({},t),{["result."+e]:s.result[e]})),{});e=Object.assign(Object.assign({},e),t)}e.result instanceof o.DataFrame&&(e.result=JSON.stringify(null===(w=e.result)||void 0===w?void 0:w.toJson())||""),null!=r.shell.reportTest?yield r.shell.reportTest(A,e):yield fetch(`${r.dapi.root}/log/tests/${A}`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(e)})}return s}))}function R(t){const e=t.slice();return e.sort((()=>Math.random()-.5)),e}function F(t){return s(this,void 0,void 0,(function*(){yield new Promise((e=>setTimeout(e,t)))}))}function k(t,e,n="EXECUTION TIMEOUT"){return s(this,void 0,void 0,(function*(){let r=null;const o=new Promise(((t,o)=>{r=setTimeout((()=>{o(n)}),e)}));try{return yield Promise.race([t(),o])}finally{r&&clearTimeout(r)}}))}o.DataFrame.fromColumns([o.Column.fromStrings("col",["val1","val2","val3"])])},74:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,".st-colored-text-input > textarea {\n width: 100%;\n -webkit-text-fill-color: transparent;\n background-color: transparent;\n position: relative;\n z-index: 1;\n resize: none;\n height: 22px; /* Fine tuned value to avoid \"jumping\" of the textarea upon autoresize */\n}\n\n.st-colored-text-input > div {\n /* The values here are fine tuned to those of the ui.input textarea in order\n * to achieve precise overlap */\n overflow: auto;\n position: absolute;\n pointer-events: none;\n cursor: text;\n z-index: 0;\n max-width: 100%;\n padding: 2px;\n line-height: normal;\n font-family: 'Roboto', 'Roboto Local', sans-serif;\n font-size: 13px;\n padding-top: 6px !important;\n color: transparent;\n white-space: pre-wrap;\n word-wrap: break-word;\n}\n","",{version:3,sources:["webpack://./src/apps/common/view/components/colored-input/style.css"],names:[],mappings:"AAAA;EACE,WAAW;EACX,oCAAoC;EACpC,6BAA6B;EAC7B,kBAAkB;EAClB,UAAU;EACV,YAAY;EACZ,YAAY,EAAE,wEAAwE;AACxF;;AAEA;EACE;iCAC+B;EAC/B,cAAc;EACd,kBAAkB;EAClB,oBAAoB;EACpB,YAAY;EACZ,UAAU;EACV,eAAe;EACf,YAAY;EACZ,mBAAmB;EACnB,iDAAiD;EACjD,eAAe;EACf,2BAA2B;EAC3B,kBAAkB;EAClB,qBAAqB;EACrB,qBAAqB;AACvB",sourcesContent:[".st-colored-text-input > textarea {\n width: 100%;\n -webkit-text-fill-color: transparent;\n background-color: transparent;\n position: relative;\n z-index: 1;\n resize: none;\n height: 22px; /* Fine tuned value to avoid \"jumping\" of the textarea upon autoresize */\n}\n\n.st-colored-text-input > div {\n /* The values here are fine tuned to those of the ui.input textarea in order\n * to achieve precise overlap */\n overflow: auto;\n position: absolute;\n pointer-events: none;\n cursor: text;\n z-index: 0;\n max-width: 100%;\n padding: 2px;\n line-height: normal;\n font-family: 'Roboto', 'Roboto Local', sans-serif;\n font-size: 13px;\n padding-top: 6px !important;\n color: transparent;\n white-space: pre-wrap;\n word-wrap: break-word;\n}\n"],sourceRoot:""}]);const a=s},252:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-pattern-text-input > textarea {\n resize: none;\n}\n","",{version:3,sources:["webpack://./src/apps/pattern/view/style.css"],names:[],mappings:"AAAA,gGAAgG;;AAEhG;EACE,YAAY;AACd",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-pattern-text-input > textarea {\n resize: none;\n}\n"],sourceRoot:""}]);const a=s},507:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-structure-body {\n padding-right: 20px;\n}\n\n.st-structure-mol-img {\n margin-right: 30px;\n float: right;\n}\n\n.st-structure-bool-button-block {\n justify-content: right;\n margin-bottom: 10px;\n}\n\n.st-structure-bottom {\n flex-direction: row-reverse;\n padding-top: 20px;\n}\n\n.st-structure-clear-buttons {\n justify-content: space-between;\n padding: 13px 10px 13px 10px;\n}\n\n.st-direction-inputs {\n align-items: end;\n}\n\n.st-structure-inputs {\n flex-grow: 2;\n padding-left: 10px;\n}","",{version:3,sources:["webpack://./src/apps/structure/view/style.css"],names:[],mappings:"AAAA,gGAAgG;;AAEhG;EACE,mBAAmB;AACrB;;AAEA;EACE,kBAAkB;EAClB,YAAY;AACd;;AAEA;EACE,sBAAsB;EACtB,mBAAmB;AACrB;;AAEA;EACE,2BAA2B;EAC3B,iBAAiB;AACnB;;AAEA;EACE,8BAA8B;EAC9B,4BAA4B;AAC9B;;AAEA;EACE,gBAAgB;AAClB;;AAEA;EACE,YAAY;EACZ,kBAAkB;AACpB",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-structure-body {\n padding-right: 20px;\n}\n\n.st-structure-mol-img {\n margin-right: 30px;\n float: right;\n}\n\n.st-structure-bool-button-block {\n justify-content: right;\n margin-bottom: 10px;\n}\n\n.st-structure-bottom {\n flex-direction: row-reverse;\n padding-top: 20px;\n}\n\n.st-structure-clear-buttons {\n justify-content: space-between;\n padding: 13px 10px 13px 10px;\n}\n\n.st-direction-inputs {\n align-items: end;\n}\n\n.st-structure-inputs {\n flex-grow: 2;\n padding-left: 10px;\n}"],sourceRoot:""}]);const a=s},254:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n.st-translator-input-table {\n /* width: 100%; */\n margin-right: 20px;\n}\n\n.st-translator-input-table td:has(textarea) {\n width: 100%;\n}\n\n.st-translator-input-table td:has(select) {\n min-width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table {\n margin-top: 20px;\n margin-right: 20px;\n margin-bottom: 10px;\n}\n\n.st-translator-output-table table {\n width: 100%;\n table-layout: fixed;\n}\n\n.st-translator-output-table td {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.st-translator-output-table tr:nth-child(even) {\n background-color: var(--grey-1);\n}\n\n.st-translator-output-table td:nth-child(odd) {\n width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table td a {\n overflow-wrap: break-word;\n}\n","",{version:3,sources:["webpack://./src/apps/translator/view/style.css"],names:[],mappings:"AAAA,gGAAgG;AAChG;EACE,iBAAiB;EACjB,kBAAkB;AACpB;;AAEA;EACE,WAAW;AACb;;AAEA;EACE,gBAAgB;EAChB,mBAAmB;AACrB;;AAEA;EACE,gBAAgB;EAChB,kBAAkB;EAClB,mBAAmB;AACrB;;AAEA;EACE,WAAW;EACX,mBAAmB;AACrB;;AAEA;EACE,gBAAgB;EAChB,mBAAmB;AACrB;AACA;EACE,+BAA+B;AACjC;;AAEA;EACE,YAAY;EACZ,mBAAmB;AACrB;;AAEA;EACE,yBAAyB;AAC3B",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n.st-translator-input-table {\n /* width: 100%; */\n margin-right: 20px;\n}\n\n.st-translator-input-table td:has(textarea) {\n width: 100%;\n}\n\n.st-translator-input-table td:has(select) {\n min-width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table {\n margin-top: 20px;\n margin-right: 20px;\n margin-bottom: 10px;\n}\n\n.st-translator-output-table table {\n width: 100%;\n table-layout: fixed;\n}\n\n.st-translator-output-table td {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.st-translator-output-table tr:nth-child(even) {\n background-color: var(--grey-1);\n}\n\n.st-translator-output-table td:nth-child(odd) {\n width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table td a {\n overflow-wrap: break-word;\n}\n"],sourceRoot:""}]);const a=s},314:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,o,i){"string"==typeof t&&(t=[[null,t,void 0]]);var s={};if(r)for(var a=0;a<this.length;a++){var u=this[a][0];null!=u&&(s[u]=!0)}for(var c=0;c<t.length;c++){var l=[].concat(t[c]);r&&s[l[0]]||(void 0!==i&&(void 0===l[5]||(l[1]="@layer".concat(l[5].length>0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=i),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),e.push(l))}},e}},354:t=>{"use strict";t.exports=function(t){var e=t[1],n=t[3];if(!n)return e;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),i="/*# ".concat(o," */");return[e].concat([i]).join("\n")}return[e].join("\n")}},982:function(t,e,n){var r;!function(){var e={};!function(t){"use strict";t.__esModule=!0,t.digestLength=32,t.blockSize=64;var e=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]);function n(t,n,r,o,i){for(var s,a,u,c,l,f,h,p,d,g,m,y,v;i>=64;){for(s=n[0],a=n[1],u=n[2],c=n[3],l=n[4],f=n[5],h=n[6],p=n[7],g=0;g<16;g++)m=o+4*g,t[g]=(255&r[m])<<24|(255&r[m+1])<<16|(255&r[m+2])<<8|255&r[m+3];for(g=16;g<64;g++)y=((d=t[g-2])>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,v=((d=t[g-15])>>>7|d<<25)^(d>>>18|d<<14)^d>>>3,t[g]=(y+t[g-7]|0)+(v+t[g-16]|0);for(g=0;g<64;g++)y=(((l>>>6|l<<26)^(l>>>11|l<<21)^(l>>>25|l<<7))+(l&f^~l&h)|0)+(p+(e[g]+t[g]|0)|0)|0,v=((s>>>2|s<<30)^(s>>>13|s<<19)^(s>>>22|s<<10))+(s&a^s&u^a&u)|0,p=h,h=f,f=l,l=c+y|0,c=u,u=a,a=s,s=y+v|0;n[0]+=s,n[1]+=a,n[2]+=u,n[3]+=c,n[4]+=l,n[5]+=f,n[6]+=h,n[7]+=p,o+=64,i-=64}return o}var r=function(){function e(){this.digestLength=t.digestLength,this.blockSize=t.blockSize,this.state=new Int32Array(8),this.temp=new Int32Array(64),this.buffer=new Uint8Array(128),this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this.reset()}return e.prototype.reset=function(){return this.state[0]=1779033703,this.state[1]=3144134277,this.state[2]=1013904242,this.state[3]=2773480762,this.state[4]=1359893119,this.state[5]=2600822924,this.state[6]=528734635,this.state[7]=1541459225,this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this},e.prototype.clean=function(){for(var t=0;t<this.buffer.length;t++)this.buffer[t]=0;for(t=0;t<this.temp.length;t++)this.temp[t]=0;this.reset()},e.prototype.update=function(t,e){if(void 0===e&&(e=t.length),this.finished)throw new Error("SHA256: can't update because hash was finished.");var r=0;if(this.bytesHashed+=e,this.bufferLength>0){for(;this.bufferLength<64&&e>0;)this.buffer[this.bufferLength++]=t[r++],e--;64===this.bufferLength&&(n(this.temp,this.state,this.buffer,0,64),this.bufferLength=0)}for(e>=64&&(r=n(this.temp,this.state,t,r,e),e%=64);e>0;)this.buffer[this.bufferLength++]=t[r++],e--;return this},e.prototype.finish=function(t){if(!this.finished){var e=this.bytesHashed,r=this.bufferLength,o=e/536870912|0,i=e<<3,s=e%64<56?64:128;this.buffer[r]=128;for(var a=r+1;a<s-8;a++)this.buffer[a]=0;this.buffer[s-8]=o>>>24&255,this.buffer[s-7]=o>>>16&255,this.buffer[s-6]=o>>>8&255,this.buffer[s-5]=o>>>0&255,this.buffer[s-4]=i>>>24&255,this.buffer[s-3]=i>>>16&255,this.buffer[s-2]=i>>>8&255,this.buffer[s-1]=i>>>0&255,n(this.temp,this.state,this.buffer,0,s),this.finished=!0}for(a=0;a<8;a++)t[4*a+0]=this.state[a]>>>24&255,t[4*a+1]=this.state[a]>>>16&255,t[4*a+2]=this.state[a]>>>8&255,t[4*a+3]=this.state[a]>>>0&255;return this},e.prototype.digest=function(){var t=new Uint8Array(this.digestLength);return this.finish(t),t},e.prototype._saveState=function(t){for(var e=0;e<this.state.length;e++)t[e]=this.state[e]},e.prototype._restoreState=function(t,e){for(var n=0;n<this.state.length;n++)this.state[n]=t[n];this.bytesHashed=e,this.finished=!1,this.bufferLength=0},e}();t.Hash=r;var o=function(){function t(t){this.inner=new r,this.outer=new r,this.blockSize=this.inner.blockSize,this.digestLength=this.inner.digestLength;var e=new Uint8Array(this.blockSize);if(t.length>this.blockSize)(new r).update(t).finish(e).clean();else for(var n=0;n<t.length;n++)e[n]=t[n];for(n=0;n<e.length;n++)e[n]^=54;for(this.inner.update(e),n=0;n<e.length;n++)e[n]^=106;for(this.outer.update(e),this.istate=new Uint32Array(8),this.ostate=new Uint32Array(8),this.inner._saveState(this.istate),this.outer._saveState(this.ostate),n=0;n<e.length;n++)e[n]=0}return t.prototype.reset=function(){return this.inner._restoreState(this.istate,this.inner.blockSize),this.outer._restoreState(this.ostate,this.outer.blockSize),this},t.prototype.clean=function(){for(var t=0;t<this.istate.length;t++)this.ostate[t]=this.istate[t]=0;this.inner.clean(),this.outer.clean()},t.prototype.update=function(t){return this.inner.update(t),this},t.prototype.finish=function(t){return this.outer.finished?this.outer.finish(t):(this.inner.finish(t),this.outer.update(t,this.digestLength).finish(t)),this},t.prototype.digest=function(){var t=new Uint8Array(this.digestLength);return this.finish(t),t},t}();function i(t){var e=(new r).update(t),n=e.digest();return e.clean(),n}function s(t,e){var n=new o(t).update(e),r=n.digest();return n.clean(),r}function a(t,e,n,r){var o=r[0];if(0===o)throw new Error("hkdf: cannot expand more");e.reset(),o>1&&e.update(t),n&&e.update(n),e.update(r),e.finish(t),r[0]++}t.HMAC=o,t.hash=i,t.default=i,t.hmac=s;var u=new Uint8Array(t.digestLength);t.hkdf=function(t,e,n,r){void 0===e&&(e=u),void 0===r&&(r=32);for(var i=new Uint8Array([1]),c=s(e,t),l=new o(c),f=new Uint8Array(l.digestLength),h=f.length,p=new Uint8Array(r),d=0;d<r;d++)h===f.length&&(a(f,l,n,i),h=0),p[d]=f[h++];return l.clean(),f.fill(0),i.fill(0),p},t.pbkdf2=function(t,e,n,r){for(var i=new o(t),s=i.digestLength,a=new Uint8Array(4),u=new Uint8Array(s),c=new Uint8Array(s),l=new Uint8Array(r),f=0;f*s<r;f++){var h=f+1;a[0]=h>>>24&255,a[1]=h>>>16&255,a[2]=h>>>8&255,a[3]=h>>>0&255,i.reset(),i.update(e),i.update(a),i.finish(c);for(var p=0;p<s;p++)u[p]=c[p];for(p=2;p<=n;p++){i.reset(),i.update(c).finish(c);for(var d=0;d<s;d++)u[d]^=c[d]}for(p=0;p<s&&f*s+p<r;p++)l[f*s+p]=u[p]}for(f=0;f<s;f++)u[f]=c[f]=0;for(f=0;f<4;f++)a[f]=0;return i.clean(),l}}(e);var o=e.default;for(var i in e)o[i]=e[i];"object"==typeof t.exports?t.exports=o:void 0===(r=function(){return o}.call(e,n,e,t))||(t.exports=r)}()},543:function(t,e,n){var r;t=n.nmd(t),function(){var o,i="Expected a function",s="__lodash_hash_undefined__",a="__lodash_placeholder__",u=32,c=128,l=1/0,f=9007199254740991,h=NaN,p=4294967295,d=[["ary",c],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",u],["partialRight",64],["rearg",256]],g="[object Arguments]",m="[object Array]",y="[object Boolean]",v="[object Date]",b="[object Error]",w="[object Function]",A="[object GeneratorFunction]",_="[object Map]",C="[object Number]",E="[object Object]",x="[object Promise]",T="[object RegExp]",I="[object Set]",P="[object String]",O="[object Symbol]",S="[object WeakMap]",N="[object ArrayBuffer]",L="[object DataView]",M="[object Float32Array]",$="[object Float64Array]",D="[object Int8Array]",B="[object Int16Array]",R="[object Int32Array]",F="[object Uint8Array]",k="[object Uint8ClampedArray]",H="[object Uint16Array]",G="[object Uint32Array]",j=/\b__p \+= '';/g,U=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,W=/&(?:amp|lt|gt|quot|#39);/g,Y=/[&<>"']/g,q=RegExp(W.source),K=RegExp(Y.source),z=/<%-([\s\S]+?)%>/g,J=/<%([\s\S]+?)%>/g,Q=/<%=([\s\S]+?)%>/g,Z=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,X=/^\w*$/,tt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,et=/[\\^$.*+?()[\]{}|]/g,nt=RegExp(et.source),rt=/^\s+/,ot=/\s/,it=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,st=/\{\n\/\* \[wrapped with (.+)\] \*/,at=/,? & /,ut=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ct=/[()=,{}\[\]\/\s]/,lt=/\\(\\)?/g,ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ht=/\w*$/,pt=/^[-+]0x[0-9a-f]+$/i,dt=/^0b[01]+$/i,gt=/^\[object .+?Constructor\]$/,mt=/^0o[0-7]+$/i,yt=/^(?:0|[1-9]\d*)$/,vt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,bt=/($^)/,wt=/['\n\r\u2028\u2029\\]/g,At="\\ud800-\\udfff",_t="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Ct="\\u2700-\\u27bf",Et="a-z\\xdf-\\xf6\\xf8-\\xff",xt="A-Z\\xc0-\\xd6\\xd8-\\xde",Tt="\\ufe0e\\ufe0f",It="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Pt="["+At+"]",Ot="["+It+"]",St="["+_t+"]",Nt="\\d+",Lt="["+Ct+"]",Mt="["+Et+"]",$t="[^"+At+It+Nt+Ct+Et+xt+"]",Dt="\\ud83c[\\udffb-\\udfff]",Bt="[^"+At+"]",Rt="(?:\\ud83c[\\udde6-\\uddff]){2}",Ft="[\\ud800-\\udbff][\\udc00-\\udfff]",kt="["+xt+"]",Ht="\\u200d",Gt="(?:"+Mt+"|"+$t+")",jt="(?:"+kt+"|"+$t+")",Ut="(?:['’](?:d|ll|m|re|s|t|ve))?",Vt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Wt="(?:"+St+"|"+Dt+")?",Yt="["+Tt+"]?",qt=Yt+Wt+"(?:"+Ht+"(?:"+[Bt,Rt,Ft].join("|")+")"+Yt+Wt+")*",Kt="(?:"+[Lt,Rt,Ft].join("|")+")"+qt,zt="(?:"+[Bt+St+"?",St,Rt,Ft,Pt].join("|")+")",Jt=RegExp("['’]","g"),Qt=RegExp(St,"g"),Zt=RegExp(Dt+"(?="+Dt+")|"+zt+qt,"g"),Xt=RegExp([kt+"?"+Mt+"+"+Ut+"(?="+[Ot,kt,"$"].join("|")+")",jt+"+"+Vt+"(?="+[Ot,kt+Gt,"$"].join("|")+")",kt+"?"+Gt+"+"+Ut,kt+"+"+Vt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Nt,Kt].join("|"),"g"),te=RegExp("["+Ht+At+_t+Tt+"]"),ee=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,ne=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],re=-1,oe={};oe[M]=oe[$]=oe[D]=oe[B]=oe[R]=oe[F]=oe[k]=oe[H]=oe[G]=!0,oe[g]=oe[m]=oe[N]=oe[y]=oe[L]=oe[v]=oe[b]=oe[w]=oe[_]=oe[C]=oe[E]=oe[T]=oe[I]=oe[P]=oe[S]=!1;var ie={};ie[g]=ie[m]=ie[N]=ie[L]=ie[y]=ie[v]=ie[M]=ie[$]=ie[D]=ie[B]=ie[R]=ie[_]=ie[C]=ie[E]=ie[T]=ie[I]=ie[P]=ie[O]=ie[F]=ie[k]=ie[H]=ie[G]=!0,ie[b]=ie[w]=ie[S]=!1;var se={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ae=parseFloat,ue=parseInt,ce="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,le="object"==typeof self&&self&&self.Object===Object&&self,fe=ce||le||Function("return this")(),he=e&&!e.nodeType&&e,pe=he&&t&&!t.nodeType&&t,de=pe&&pe.exports===he,ge=de&&ce.process,me=function(){try{return pe&&pe.require&&pe.require("util").types||ge&&ge.binding&&ge.binding("util")}catch(t){}}(),ye=me&&me.isArrayBuffer,ve=me&&me.isDate,be=me&&me.isMap,we=me&&me.isRegExp,Ae=me&&me.isSet,_e=me&&me.isTypedArray;function Ce(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Ee(t,e,n,r){for(var o=-1,i=null==t?0:t.length;++o<i;){var s=t[o];e(r,s,n(s),t)}return r}function xe(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function Te(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}function Ie(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function Pe(t,e){for(var n=-1,r=null==t?0:t.length,o=0,i=[];++n<r;){var s=t[n];e(s,n,t)&&(i[o++]=s)}return i}function Oe(t,e){return!(null==t||!t.length)&&ke(t,e,0)>-1}function Se(t,e,n){for(var r=-1,o=null==t?0:t.length;++r<o;)if(n(e,t[r]))return!0;return!1}function Ne(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}function Le(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}function Me(t,e,n,r){var o=-1,i=null==t?0:t.length;for(r&&i&&(n=t[++o]);++o<i;)n=e(n,t[o],o,t);return n}function $e(t,e,n,r){var o=null==t?0:t.length;for(r&&o&&(n=t[--o]);o--;)n=e(n,t[o],o,t);return n}function De(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var Be=Ue("length");function Re(t,e,n){var r;return n(t,(function(t,n,o){if(e(t,n,o))return r=n,!1})),r}function Fe(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i<o;)if(e(t[i],i,t))return i;return-1}function ke(t,e,n){return e==e?function(t,e,n){for(var r=n-1,o=t.length;++r<o;)if(t[r]===e)return r;return-1}(t,e,n):Fe(t,Ge,n)}function He(t,e,n,r){for(var o=n-1,i=t.length;++o<i;)if(r(t[o],e))return o;return-1}function Ge(t){return t!=t}function je(t,e){var n=null==t?0:t.length;return n?Ye(t,e)/n:h}function Ue(t){return function(e){return null==e?o:e[t]}}function Ve(t){return function(e){return null==t?o:t[e]}}function We(t,e,n,r,o){return o(t,(function(t,o,i){n=r?(r=!1,t):e(n,t,o,i)})),n}function Ye(t,e){for(var n,r=-1,i=t.length;++r<i;){var s=e(t[r]);s!==o&&(n=n===o?s:n+s)}return n}function qe(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Ke(t){return t?t.slice(0,hn(t)+1).replace(rt,""):t}function ze(t){return function(e){return t(e)}}function Je(t,e){return Ne(e,(function(e){return t[e]}))}function Qe(t,e){return t.has(e)}function Ze(t,e){for(var n=-1,r=t.length;++n<r&&ke(e,t[n],0)>-1;);return n}function Xe(t,e){for(var n=t.length;n--&&ke(e,t[n],0)>-1;);return n}var tn=Ve({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),en=Ve({"&":"&","<":"<",">":">",'"':""","'":"'"});function nn(t){return"\\"+se[t]}function rn(t){return te.test(t)}function on(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function sn(t,e){return function(n){return t(e(n))}}function an(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n];s!==e&&s!==a||(t[n]=a,i[o++]=n)}return i}function un(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}function cn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}function ln(t){return rn(t)?function(t){for(var e=Zt.lastIndex=0;Zt.test(t);)++e;return e}(t):Be(t)}function fn(t){return rn(t)?function(t){return t.match(Zt)||[]}(t):function(t){return t.split("")}(t)}function hn(t){for(var e=t.length;e--&&ot.test(t.charAt(e)););return e}var pn=Ve({"&":"&","<":"<",">":">",""":'"',"'":"'"}),dn=function t(e){var n,r=(e=null==e?fe:dn.defaults(fe.Object(),e,dn.pick(fe,ne))).Array,ot=e.Date,At=e.Error,_t=e.Function,Ct=e.Math,Et=e.Object,xt=e.RegExp,Tt=e.String,It=e.TypeError,Pt=r.prototype,Ot=_t.prototype,St=Et.prototype,Nt=e["__core-js_shared__"],Lt=Ot.toString,Mt=St.hasOwnProperty,$t=0,Dt=(n=/[^.]+$/.exec(Nt&&Nt.keys&&Nt.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Bt=St.toString,Rt=Lt.call(Et),Ft=fe._,kt=xt("^"+Lt.call(Mt).replace(et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ht=de?e.Buffer:o,Gt=e.Symbol,jt=e.Uint8Array,Ut=Ht?Ht.allocUnsafe:o,Vt=sn(Et.getPrototypeOf,Et),Wt=Et.create,Yt=St.propertyIsEnumerable,qt=Pt.splice,Kt=Gt?Gt.isConcatSpreadable:o,zt=Gt?Gt.iterator:o,Zt=Gt?Gt.toStringTag:o,te=function(){try{var t=ci(Et,"defineProperty");return t({},"",{}),t}catch(t){}}(),se=e.clearTimeout!==fe.clearTimeout&&e.clearTimeout,ce=ot&&ot.now!==fe.Date.now&&ot.now,le=e.setTimeout!==fe.setTimeout&&e.setTimeout,he=Ct.ceil,pe=Ct.floor,ge=Et.getOwnPropertySymbols,me=Ht?Ht.isBuffer:o,Be=e.isFinite,Ve=Pt.join,gn=sn(Et.keys,Et),mn=Ct.max,yn=Ct.min,vn=ot.now,bn=e.parseInt,wn=Ct.random,An=Pt.reverse,_n=ci(e,"DataView"),Cn=ci(e,"Map"),En=ci(e,"Promise"),xn=ci(e,"Set"),Tn=ci(e,"WeakMap"),In=ci(Et,"create"),Pn=Tn&&new Tn,On={},Sn=Ri(_n),Nn=Ri(Cn),Ln=Ri(En),Mn=Ri(xn),$n=Ri(Tn),Dn=Gt?Gt.prototype:o,Bn=Dn?Dn.valueOf:o,Rn=Dn?Dn.toString:o;function Fn(t){if(ta(t)&&!Us(t)&&!(t instanceof jn)){if(t instanceof Gn)return t;if(Mt.call(t,"__wrapped__"))return Fi(t)}return new Gn(t)}var kn=function(){function t(){}return function(e){if(!Xs(e))return{};if(Wt)return Wt(e);t.prototype=e;var n=new t;return t.prototype=o,n}}();function Hn(){}function Gn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=o}function jn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=p,this.__views__=[]}function Un(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Vn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Wn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Yn(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Wn;++e<n;)this.add(t[e])}function qn(t){var e=this.__data__=new Vn(t);this.size=e.size}function Kn(t,e){var n=Us(t),r=!n&&js(t),o=!n&&!r&&qs(t),i=!n&&!r&&!o&&ua(t),s=n||r||o||i,a=s?qe(t.length,Tt):[],u=a.length;for(var c in t)!e&&!Mt.call(t,c)||s&&("length"==c||o&&("offset"==c||"parent"==c)||i&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||mi(c,u))||a.push(c);return a}function zn(t){var e=t.length;return e?t[Wr(0,e-1)]:o}function Jn(t,e){return Li(Io(t),ir(e,0,t.length))}function Qn(t){return Li(Io(t))}function Zn(t,e,n){(n!==o&&!ks(t[e],n)||n===o&&!(e in t))&&rr(t,e,n)}function Xn(t,e,n){var r=t[e];Mt.call(t,e)&&ks(r,n)&&(n!==o||e in t)||rr(t,e,n)}function tr(t,e){for(var n=t.length;n--;)if(ks(t[n][0],e))return n;return-1}function er(t,e,n,r){return lr(t,(function(t,o,i){e(r,t,n(t),i)})),r}function nr(t,e){return t&&Po(e,Sa(e),t)}function rr(t,e,n){"__proto__"==e&&te?te(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function or(t,e){for(var n=-1,i=e.length,s=r(i),a=null==t;++n<i;)s[n]=a?o:xa(t,e[n]);return s}function ir(t,e,n){return t==t&&(n!==o&&(t=t<=n?t:n),e!==o&&(t=t>=e?t:e)),t}function sr(t,e,n,r,i,s){var a,u=1&e,c=2&e,l=4&e;if(n&&(a=i?n(t,r,i,s):n(t)),a!==o)return a;if(!Xs(t))return t;var f=Us(t);if(f){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&Mt.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!u)return Io(t,a)}else{var h=hi(t),p=h==w||h==A;if(qs(t))return Ao(t,u);if(h==E||h==g||p&&!i){if(a=c||p?{}:di(t),!u)return c?function(t,e){return Po(t,fi(t),e)}(t,function(t,e){return t&&Po(e,Na(e),t)}(a,t)):function(t,e){return Po(t,li(t),e)}(t,nr(a,t))}else{if(!ie[h])return i?t:{};a=function(t,e,n){var r,o=t.constructor;switch(e){case N:return _o(t);case y:case v:return new o(+t);case L:return function(t,e){var n=e?_o(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case M:case $:case D:case B:case R:case F:case k:case H:case G:return Co(t,n);case _:return new o;case C:case P:return new o(t);case T:return function(t){var e=new t.constructor(t.source,ht.exec(t));return e.lastIndex=t.lastIndex,e}(t);case I:return new o;case O:return r=t,Bn?Et(Bn.call(r)):{}}}(t,h,u)}}s||(s=new qn);var d=s.get(t);if(d)return d;s.set(t,a),ia(t)?t.forEach((function(r){a.add(sr(r,e,n,r,t,s))})):ea(t)&&t.forEach((function(r,o){a.set(o,sr(r,e,n,o,t,s))}));var m=f?o:(l?c?ni:ei:c?Na:Sa)(t);return xe(m||t,(function(r,o){m&&(r=t[o=r]),Xn(a,o,sr(r,e,n,o,t,s))})),a}function ar(t,e,n){var r=n.length;if(null==t)return!r;for(t=Et(t);r--;){var i=n[r],s=e[i],a=t[i];if(a===o&&!(i in t)||!s(a))return!1}return!0}function ur(t,e,n){if("function"!=typeof t)throw new It(i);return Pi((function(){t.apply(o,n)}),e)}function cr(t,e,n,r){var o=-1,i=Oe,s=!0,a=t.length,u=[],c=e.length;if(!a)return u;n&&(e=Ne(e,ze(n))),r?(i=Se,s=!1):e.length>=200&&(i=Qe,s=!1,e=new Yn(e));t:for(;++o<a;){var l=t[o],f=null==n?l:n(l);if(l=r||0!==l?l:0,s&&f==f){for(var h=c;h--;)if(e[h]===f)continue t;u.push(l)}else i(e,f,r)||u.push(l)}return u}Fn.templateSettings={escape:z,evaluate:J,interpolate:Q,variable:"",imports:{_:Fn}},Fn.prototype=Hn.prototype,Fn.prototype.constructor=Fn,Gn.prototype=kn(Hn.prototype),Gn.prototype.constructor=Gn,jn.prototype=kn(Hn.prototype),jn.prototype.constructor=jn,Un.prototype.clear=function(){this.__data__=In?In(null):{},this.size=0},Un.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Un.prototype.get=function(t){var e=this.__data__;if(In){var n=e[t];return n===s?o:n}return Mt.call(e,t)?e[t]:o},Un.prototype.has=function(t){var e=this.__data__;return In?e[t]!==o:Mt.call(e,t)},Un.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=In&&e===o?s:e,this},Vn.prototype.clear=function(){this.__data__=[],this.size=0},Vn.prototype.delete=function(t){var e=this.__data__,n=tr(e,t);return!(n<0||(n==e.length-1?e.pop():qt.call(e,n,1),--this.size,0))},Vn.prototype.get=function(t){var e=this.__data__,n=tr(e,t);return n<0?o:e[n][1]},Vn.prototype.has=function(t){return tr(this.__data__,t)>-1},Vn.prototype.set=function(t,e){var n=this.__data__,r=tr(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Wn.prototype.clear=function(){this.size=0,this.__data__={hash:new Un,map:new(Cn||Vn),string:new Un}},Wn.prototype.delete=function(t){var e=ai(this,t).delete(t);return this.size-=e?1:0,e},Wn.prototype.get=function(t){return ai(this,t).get(t)},Wn.prototype.has=function(t){return ai(this,t).has(t)},Wn.prototype.set=function(t,e){var n=ai(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Yn.prototype.add=Yn.prototype.push=function(t){return this.__data__.set(t,s),this},Yn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.clear=function(){this.__data__=new Vn,this.size=0},qn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},qn.prototype.get=function(t){return this.__data__.get(t)},qn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Vn){var r=n.__data__;if(!Cn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Wn(r)}return n.set(t,e),this.size=n.size,this};var lr=No(vr),fr=No(br,!0);function hr(t,e){var n=!0;return lr(t,(function(t,r,o){return n=!!e(t,r,o)})),n}function pr(t,e,n){for(var r=-1,i=t.length;++r<i;){var s=t[r],a=e(s);if(null!=a&&(u===o?a==a&&!aa(a):n(a,u)))var u=a,c=s}return c}function dr(t,e){var n=[];return lr(t,(function(t,r,o){e(t,r,o)&&n.push(t)})),n}function gr(t,e,n,r,o){var i=-1,s=t.length;for(n||(n=gi),o||(o=[]);++i<s;){var a=t[i];e>0&&n(a)?e>1?gr(a,e-1,n,r,o):Le(o,a):r||(o[o.length]=a)}return o}var mr=Lo(),yr=Lo(!0);function vr(t,e){return t&&mr(t,e,Sa)}function br(t,e){return t&&yr(t,e,Sa)}function wr(t,e){return Pe(e,(function(e){return Js(t[e])}))}function Ar(t,e){for(var n=0,r=(e=yo(e,t)).length;null!=t&&n<r;)t=t[Bi(e[n++])];return n&&n==r?t:o}function _r(t,e,n){var r=e(t);return Us(t)?r:Le(r,n(t))}function Cr(t){return null==t?t===o?"[object Undefined]":"[object Null]":Zt&&Zt in Et(t)?function(t){var e=Mt.call(t,Zt),n=t[Zt];try{t[Zt]=o;var r=!0}catch(t){}var i=Bt.call(t);return r&&(e?t[Zt]=n:delete t[Zt]),i}(t):function(t){return Bt.call(t)}(t)}function Er(t,e){return t>e}function xr(t,e){return null!=t&&Mt.call(t,e)}function Tr(t,e){return null!=t&&e in Et(t)}function Ir(t,e,n){for(var i=n?Se:Oe,s=t[0].length,a=t.length,u=a,c=r(a),l=1/0,f=[];u--;){var h=t[u];u&&e&&(h=Ne(h,ze(e))),l=yn(h.length,l),c[u]=!n&&(e||s>=120&&h.length>=120)?new Yn(u&&h):o}h=t[0];var p=-1,d=c[0];t:for(;++p<s&&f.length<l;){var g=h[p],m=e?e(g):g;if(g=n||0!==g?g:0,!(d?Qe(d,m):i(f,m,n))){for(u=a;--u;){var y=c[u];if(!(y?Qe(y,m):i(t[u],m,n)))continue t}d&&d.push(m),f.push(g)}}return f}function Pr(t,e,n){var r=null==(t=xi(t,e=yo(e,t)))?t:t[Bi(zi(e))];return null==r?o:Ce(r,t,n)}function Or(t){return ta(t)&&Cr(t)==g}function Sr(t,e,n,r,i){return t===e||(null==t||null==e||!ta(t)&&!ta(e)?t!=t&&e!=e:function(t,e,n,r,i,s){var a=Us(t),u=Us(e),c=a?m:hi(t),l=u?m:hi(e),f=(c=c==g?E:c)==E,h=(l=l==g?E:l)==E,p=c==l;if(p&&qs(t)){if(!qs(e))return!1;a=!0,f=!1}if(p&&!f)return s||(s=new qn),a||ua(t)?Xo(t,e,n,r,i,s):function(t,e,n,r,o,i,s){switch(n){case L:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case N:return!(t.byteLength!=e.byteLength||!i(new jt(t),new jt(e)));case y:case v:case C:return ks(+t,+e);case b:return t.name==e.name&&t.message==e.message;case T:case P:return t==e+"";case _:var a=on;case I:var u=1&r;if(a||(a=un),t.size!=e.size&&!u)return!1;var c=s.get(t);if(c)return c==e;r|=2,s.set(t,e);var l=Xo(a(t),a(e),r,o,i,s);return s.delete(t),l;case O:if(Bn)return Bn.call(t)==Bn.call(e)}return!1}(t,e,c,n,r,i,s);if(!(1&n)){var d=f&&Mt.call(t,"__wrapped__"),w=h&&Mt.call(e,"__wrapped__");if(d||w){var A=d?t.value():t,x=w?e.value():e;return s||(s=new qn),i(A,x,n,r,s)}}return!!p&&(s||(s=new qn),function(t,e,n,r,i,s){var a=1&n,u=ei(t),c=u.length;if(c!=ei(e).length&&!a)return!1;for(var l=c;l--;){var f=u[l];if(!(a?f in e:Mt.call(e,f)))return!1}var h=s.get(t),p=s.get(e);if(h&&p)return h==e&&p==t;var d=!0;s.set(t,e),s.set(e,t);for(var g=a;++l<c;){var m=t[f=u[l]],y=e[f];if(r)var v=a?r(y,m,f,e,t,s):r(m,y,f,t,e,s);if(!(v===o?m===y||i(m,y,n,r,s):v)){d=!1;break}g||(g="constructor"==f)}if(d&&!g){var b=t.constructor,w=e.constructor;b==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(d=!1)}return s.delete(t),s.delete(e),d}(t,e,n,r,i,s))}(t,e,n,r,Sr,i))}function Nr(t,e,n,r){var i=n.length,s=i,a=!r;if(null==t)return!s;for(t=Et(t);i--;){var u=n[i];if(a&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++i<s;){var c=(u=n[i])[0],l=t[c],f=u[1];if(a&&u[2]){if(l===o&&!(c in t))return!1}else{var h=new qn;if(r)var p=r(l,f,c,t,e,h);if(!(p===o?Sr(f,l,3,r,h):p))return!1}}return!0}function Lr(t){return!(!Xs(t)||(e=t,Dt&&Dt in e))&&(Js(t)?kt:gt).test(Ri(t));var e}function Mr(t){return"function"==typeof t?t:null==t?nu:"object"==typeof t?Us(t)?Fr(t[0],t[1]):Rr(t):fu(t)}function $r(t){if(!Ai(t))return gn(t);var e=[];for(var n in Et(t))Mt.call(t,n)&&"constructor"!=n&&e.push(n);return e}function Dr(t,e){return t<e}function Br(t,e){var n=-1,o=Ws(t)?r(t.length):[];return lr(t,(function(t,r,i){o[++n]=e(t,r,i)})),o}function Rr(t){var e=ui(t);return 1==e.length&&e[0][2]?Ci(e[0][0],e[0][1]):function(n){return n===t||Nr(n,t,e)}}function Fr(t,e){return vi(t)&&_i(e)?Ci(Bi(t),e):function(n){var r=xa(n,t);return r===o&&r===e?Ta(n,t):Sr(e,r,3)}}function kr(t,e,n,r,i){t!==e&&mr(e,(function(s,a){if(i||(i=new qn),Xs(s))!function(t,e,n,r,i,s,a){var u=Ti(t,n),c=Ti(e,n),l=a.get(c);if(l)Zn(t,n,l);else{var f=s?s(u,c,n+"",t,e,a):o,h=f===o;if(h){var p=Us(c),d=!p&&qs(c),g=!p&&!d&&ua(c);f=c,p||d||g?Us(u)?f=u:Ys(u)?f=Io(u):d?(h=!1,f=Ao(c,!0)):g?(h=!1,f=Co(c,!0)):f=[]:ra(c)||js(c)?(f=u,js(u)?f=ma(u):Xs(u)&&!Js(u)||(f=di(c))):h=!1}h&&(a.set(c,f),i(f,c,r,s,a),a.delete(c)),Zn(t,n,f)}}(t,e,a,n,kr,r,i);else{var u=r?r(Ti(t,a),s,a+"",t,e,i):o;u===o&&(u=s),Zn(t,a,u)}}),Na)}function Hr(t,e){var n=t.length;if(n)return mi(e+=e<0?n:0,n)?t[e]:o}function Gr(t,e,n){e=e.length?Ne(e,(function(t){return Us(t)?function(e){return Ar(e,1===t.length?t[0]:t)}:t})):[nu];var r=-1;e=Ne(e,ze(si()));var o=Br(t,(function(t,n,o){var i=Ne(e,(function(e){return e(t)}));return{criteria:i,index:++r,value:t}}));return function(t){var e=t.length;for(t.sort((function(t,e){return function(t,e,n){for(var r=-1,o=t.criteria,i=e.criteria,s=o.length,a=n.length;++r<s;){var u=Eo(o[r],i[r]);if(u)return r>=a?u:u*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}));e--;)t[e]=t[e].value;return t}(o)}function jr(t,e,n){for(var r=-1,o=e.length,i={};++r<o;){var s=e[r],a=Ar(t,s);n(a,s)&&Jr(i,yo(s,t),a)}return i}function Ur(t,e,n,r){var o=r?He:ke,i=-1,s=e.length,a=t;for(t===e&&(e=Io(e)),n&&(a=Ne(t,ze(n)));++i<s;)for(var u=0,c=e[i],l=n?n(c):c;(u=o(a,l,u,r))>-1;)a!==t&&qt.call(a,u,1),qt.call(t,u,1);return t}function Vr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var o=e[n];if(n==r||o!==i){var i=o;mi(o)?qt.call(t,o,1):uo(t,o)}}return t}function Wr(t,e){return t+pe(wn()*(e-t+1))}function Yr(t,e){var n="";if(!t||e<1||e>f)return n;do{e%2&&(n+=t),(e=pe(e/2))&&(t+=t)}while(e);return n}function qr(t,e){return Oi(Ei(t,e,nu),t+"")}function Kr(t){return zn(ka(t))}function zr(t,e){var n=ka(t);return Li(n,ir(e,0,n.length))}function Jr(t,e,n,r){if(!Xs(t))return t;for(var i=-1,s=(e=yo(e,t)).length,a=s-1,u=t;null!=u&&++i<s;){var c=Bi(e[i]),l=n;if("__proto__"===c||"constructor"===c||"prototype"===c)return t;if(i!=a){var f=u[c];(l=r?r(f,c,u):o)===o&&(l=Xs(f)?f:mi(e[i+1])?[]:{})}Xn(u,c,l),u=u[c]}return t}var Qr=Pn?function(t,e){return Pn.set(t,e),t}:nu,Zr=te?function(t,e){return te(t,"toString",{configurable:!0,enumerable:!1,value:Xa(e),writable:!0})}:nu;function Xr(t){return Li(ka(t))}function to(t,e,n){var o=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var s=r(i);++o<i;)s[o]=t[o+e];return s}function eo(t,e){var n;return lr(t,(function(t,r,o){return!(n=e(t,r,o))})),!!n}function no(t,e,n){var r=0,o=null==t?r:t.length;if("number"==typeof e&&e==e&&o<=2147483647){for(;r<o;){var i=r+o>>>1,s=t[i];null!==s&&!aa(s)&&(n?s<=e:s<e)?r=i+1:o=i}return o}return ro(t,e,nu,n)}function ro(t,e,n,r){var i=0,s=null==t?0:t.length;if(0===s)return 0;for(var a=(e=n(e))!=e,u=null===e,c=aa(e),l=e===o;i<s;){var f=pe((i+s)/2),h=n(t[f]),p=h!==o,d=null===h,g=h==h,m=aa(h);if(a)var y=r||g;else y=l?g&&(r||p):u?g&&p&&(r||!d):c?g&&p&&!d&&(r||!m):!d&&!m&&(r?h<=e:h<e);y?i=f+1:s=f}return yn(s,4294967294)}function oo(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n],a=e?e(s):s;if(!n||!ks(a,u)){var u=a;i[o++]=0===s?0:s}}return i}function io(t){return"number"==typeof t?t:aa(t)?h:+t}function so(t){if("string"==typeof t)return t;if(Us(t))return Ne(t,so)+"";if(aa(t))return Rn?Rn.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function ao(t,e,n){var r=-1,o=Oe,i=t.length,s=!0,a=[],u=a;if(n)s=!1,o=Se;else if(i>=200){var c=e?null:qo(t);if(c)return un(c);s=!1,o=Qe,u=new Yn}else u=e?[]:a;t:for(;++r<i;){var l=t[r],f=e?e(l):l;if(l=n||0!==l?l:0,s&&f==f){for(var h=u.length;h--;)if(u[h]===f)continue t;e&&u.push(f),a.push(l)}else o(u,f,n)||(u!==a&&u.push(f),a.push(l))}return a}function uo(t,e){return null==(t=xi(t,e=yo(e,t)))||delete t[Bi(zi(e))]}function co(t,e,n,r){return Jr(t,e,n(Ar(t,e)),r)}function lo(t,e,n,r){for(var o=t.length,i=r?o:-1;(r?i--:++i<o)&&e(t[i],i,t););return n?to(t,r?0:i,r?i+1:o):to(t,r?i+1:0,r?o:i)}function fo(t,e){var n=t;return n instanceof jn&&(n=n.value()),Me(e,(function(t,e){return e.func.apply(e.thisArg,Le([t],e.args))}),n)}function ho(t,e,n){var o=t.length;if(o<2)return o?ao(t[0]):[];for(var i=-1,s=r(o);++i<o;)for(var a=t[i],u=-1;++u<o;)u!=i&&(s[i]=cr(s[i]||a,t[u],e,n));return ao(gr(s,1),e,n)}function po(t,e,n){for(var r=-1,i=t.length,s=e.length,a={};++r<i;){var u=r<s?e[r]:o;n(a,t[r],u)}return a}function go(t){return Ys(t)?t:[]}function mo(t){return"function"==typeof t?t:nu}function yo(t,e){return Us(t)?t:vi(t,e)?[t]:Di(ya(t))}var vo=qr;function bo(t,e,n){var r=t.length;return n=n===o?r:n,!e&&n>=r?t:to(t,e,n)}var wo=se||function(t){return fe.clearTimeout(t)};function Ao(t,e){if(e)return t.slice();var n=t.length,r=Ut?Ut(n):new t.constructor(n);return t.copy(r),r}function _o(t){var e=new t.constructor(t.byteLength);return new jt(e).set(new jt(t)),e}function Co(t,e){var n=e?_o(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Eo(t,e){if(t!==e){var n=t!==o,r=null===t,i=t==t,s=aa(t),a=e!==o,u=null===e,c=e==e,l=aa(e);if(!u&&!l&&!s&&t>e||s&&a&&c&&!u&&!l||r&&a&&c||!n&&c||!i)return 1;if(!r&&!s&&!l&&t<e||l&&n&&i&&!r&&!s||u&&n&&i||!a&&i||!c)return-1}return 0}function xo(t,e,n,o){for(var i=-1,s=t.length,a=n.length,u=-1,c=e.length,l=mn(s-a,0),f=r(c+l),h=!o;++u<c;)f[u]=e[u];for(;++i<a;)(h||i<s)&&(f[n[i]]=t[i]);for(;l--;)f[u++]=t[i++];return f}function To(t,e,n,o){for(var i=-1,s=t.length,a=-1,u=n.length,c=-1,l=e.length,f=mn(s-u,0),h=r(f+l),p=!o;++i<f;)h[i]=t[i];for(var d=i;++c<l;)h[d+c]=e[c];for(;++a<u;)(p||i<s)&&(h[d+n[a]]=t[i++]);return h}function Io(t,e){var n=-1,o=t.length;for(e||(e=r(o));++n<o;)e[n]=t[n];return e}function Po(t,e,n,r){var i=!n;n||(n={});for(var s=-1,a=e.length;++s<a;){var u=e[s],c=r?r(n[u],t[u],u,n,t):o;c===o&&(c=t[u]),i?rr(n,u,c):Xn(n,u,c)}return n}function Oo(t,e){return function(n,r){var o=Us(n)?Ee:er,i=e?e():{};return o(n,t,si(r,2),i)}}function So(t){return qr((function(e,n){var r=-1,i=n.length,s=i>1?n[i-1]:o,a=i>2?n[2]:o;for(s=t.length>3&&"function"==typeof s?(i--,s):o,a&&yi(n[0],n[1],a)&&(s=i<3?o:s,i=1),e=Et(e);++r<i;){var u=n[r];u&&t(e,u,r,s)}return e}))}function No(t,e){return function(n,r){if(null==n)return n;if(!Ws(n))return t(n,r);for(var o=n.length,i=e?o:-1,s=Et(n);(e?i--:++i<o)&&!1!==r(s[i],i,s););return n}}function Lo(t){return function(e,n,r){for(var o=-1,i=Et(e),s=r(e),a=s.length;a--;){var u=s[t?a:++o];if(!1===n(i[u],u,i))break}return e}}function Mo(t){return function(e){var n=rn(e=ya(e))?fn(e):o,r=n?n[0]:e.charAt(0),i=n?bo(n,1).join(""):e.slice(1);return r[t]()+i}}function $o(t){return function(e){return Me(Ja(ja(e).replace(Jt,"")),t,"")}}function Do(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=kn(t.prototype),r=t.apply(n,e);return Xs(r)?r:n}}function Bo(t){return function(e,n,r){var i=Et(e);if(!Ws(e)){var s=si(n,3);e=Sa(e),n=function(t){return s(i[t],t,i)}}var a=t(e,n,r);return a>-1?i[s?e[a]:a]:o}}function Ro(t){return ti((function(e){var n=e.length,r=n,s=Gn.prototype.thru;for(t&&e.reverse();r--;){var a=e[r];if("function"!=typeof a)throw new It(i);if(s&&!u&&"wrapper"==oi(a))var u=new Gn([],!0)}for(r=u?r:n;++r<n;){var c=oi(a=e[r]),l="wrapper"==c?ri(a):o;u=l&&bi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?u[oi(l[0])].apply(u,l[3]):1==a.length&&bi(a)?u[c]():u.thru(a)}return function(){var t=arguments,r=t[0];if(u&&1==t.length&&Us(r))return u.plant(r).value();for(var o=0,i=n?e[o].apply(this,t):r;++o<n;)i=e[o].call(this,i);return i}}))}function Fo(t,e,n,i,s,a,u,l,f,h){var p=e&c,d=1&e,g=2&e,m=24&e,y=512&e,v=g?o:Do(t);return function c(){for(var b=arguments.length,w=r(b),A=b;A--;)w[A]=arguments[A];if(m)var _=ii(c),C=function(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}(w,_);if(i&&(w=xo(w,i,s,m)),a&&(w=To(w,a,u,m)),b-=C,m&&b<h){var E=an(w,_);return Wo(t,e,Fo,c.placeholder,n,w,E,l,f,h-b)}var x=d?n:this,T=g?x[t]:t;return b=w.length,l?w=function(t,e){for(var n=t.length,r=yn(e.length,n),i=Io(t);r--;){var s=e[r];t[r]=mi(s,n)?i[s]:o}return t}(w,l):y&&b>1&&w.reverse(),p&&f<b&&(w.length=f),this&&this!==fe&&this instanceof c&&(T=v||Do(T)),T.apply(x,w)}}function ko(t,e){return function(n,r){return function(t,e,n,r){return vr(t,(function(t,o,i){e(r,n(t),o,i)})),r}(n,t,e(r),{})}}function Ho(t,e){return function(n,r){var i;if(n===o&&r===o)return e;if(n!==o&&(i=n),r!==o){if(i===o)return r;"string"==typeof n||"string"==typeof r?(n=so(n),r=so(r)):(n=io(n),r=io(r)),i=t(n,r)}return i}}function Go(t){return ti((function(e){return e=Ne(e,ze(si())),qr((function(n){var r=this;return t(e,(function(t){return Ce(t,r,n)}))}))}))}function jo(t,e){var n=(e=e===o?" ":so(e)).length;if(n<2)return n?Yr(e,t):e;var r=Yr(e,he(t/ln(e)));return rn(e)?bo(fn(r),0,t).join(""):r.slice(0,t)}function Uo(t){return function(e,n,i){return i&&"number"!=typeof i&&yi(e,n,i)&&(n=i=o),e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n,o){for(var i=-1,s=mn(he((e-t)/(n||1)),0),a=r(s);s--;)a[o?s:++i]=t,t+=n;return a}(e,n,i=i===o?e<n?1:-1:ha(i),t)}}function Vo(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=ga(e),n=ga(n)),t(e,n)}}function Wo(t,e,n,r,i,s,a,c,l,f){var h=8&e;e|=h?u:64,4&(e&=~(h?64:u))||(e&=-4);var p=[t,e,i,h?s:o,h?a:o,h?o:s,h?o:a,c,l,f],d=n.apply(o,p);return bi(t)&&Ii(d,p),d.placeholder=r,Si(d,t,e)}function Yo(t){var e=Ct[t];return function(t,n){if(t=ga(t),(n=null==n?0:yn(pa(n),292))&&Be(t)){var r=(ya(t)+"e").split("e");return+((r=(ya(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var qo=xn&&1/un(new xn([,-0]))[1]==l?function(t){return new xn(t)}:au;function Ko(t){return function(e){var n=hi(e);return n==_?on(e):n==I?cn(e):function(t,e){return Ne(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function zo(t,e,n,s,l,f,h,p){var d=2&e;if(!d&&"function"!=typeof t)throw new It(i);var g=s?s.length:0;if(g||(e&=-97,s=l=o),h=h===o?h:mn(pa(h),0),p=p===o?p:pa(p),g-=l?l.length:0,64&e){var m=s,y=l;s=l=o}var v=d?o:ri(t),b=[t,e,n,s,l,m,y,f,h,p];if(v&&function(t,e){var n=t[1],r=e[1],o=n|r,i=o<131,s=r==c&&8==n||r==c&&256==n&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!i&&!s)return t;1&r&&(t[2]=e[2],o|=1&n?0:4);var u=e[3];if(u){var l=t[3];t[3]=l?xo(l,u,e[4]):u,t[4]=l?an(t[3],a):e[4]}(u=e[5])&&(l=t[5],t[5]=l?To(l,u,e[6]):u,t[6]=l?an(t[5],a):e[6]),(u=e[7])&&(t[7]=u),r&c&&(t[8]=null==t[8]?e[8]:yn(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=o}(b,v),t=b[0],e=b[1],n=b[2],s=b[3],l=b[4],!(p=b[9]=b[9]===o?d?0:t.length:mn(b[9]-g,0))&&24&e&&(e&=-25),e&&1!=e)w=8==e||16==e?function(t,e,n){var i=Do(t);return function s(){for(var a=arguments.length,u=r(a),c=a,l=ii(s);c--;)u[c]=arguments[c];var f=a<3&&u[0]!==l&&u[a-1]!==l?[]:an(u,l);return(a-=f.length)<n?Wo(t,e,Fo,s.placeholder,o,u,f,o,o,n-a):Ce(this&&this!==fe&&this instanceof s?i:t,this,u)}}(t,e,p):e!=u&&33!=e||l.length?Fo.apply(o,b):function(t,e,n,o){var i=1&e,s=Do(t);return function e(){for(var a=-1,u=arguments.length,c=-1,l=o.length,f=r(l+u),h=this&&this!==fe&&this instanceof e?s:t;++c<l;)f[c]=o[c];for(;u--;)f[c++]=arguments[++a];return Ce(h,i?n:this,f)}}(t,e,n,s);else var w=function(t,e,n){var r=1&e,o=Do(t);return function e(){return(this&&this!==fe&&this instanceof e?o:t).apply(r?n:this,arguments)}}(t,e,n);return Si((v?Qr:Ii)(w,b),t,e)}function Jo(t,e,n,r){return t===o||ks(t,St[n])&&!Mt.call(r,n)?e:t}function Qo(t,e,n,r,i,s){return Xs(t)&&Xs(e)&&(s.set(e,t),kr(t,e,o,Qo,s),s.delete(e)),t}function Zo(t){return ra(t)?o:t}function Xo(t,e,n,r,i,s){var a=1&n,u=t.length,c=e.length;if(u!=c&&!(a&&c>u))return!1;var l=s.get(t),f=s.get(e);if(l&&f)return l==e&&f==t;var h=-1,p=!0,d=2&n?new Yn:o;for(s.set(t,e),s.set(e,t);++h<u;){var g=t[h],m=e[h];if(r)var y=a?r(m,g,h,e,t,s):r(g,m,h,t,e,s);if(y!==o){if(y)continue;p=!1;break}if(d){if(!De(e,(function(t,e){if(!Qe(d,e)&&(g===t||i(g,t,n,r,s)))return d.push(e)}))){p=!1;break}}else if(g!==m&&!i(g,m,n,r,s)){p=!1;break}}return s.delete(t),s.delete(e),p}function ti(t){return Oi(Ei(t,o,Vi),t+"")}function ei(t){return _r(t,Sa,li)}function ni(t){return _r(t,Na,fi)}var ri=Pn?function(t){return Pn.get(t)}:au;function oi(t){for(var e=t.name+"",n=On[e],r=Mt.call(On,e)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==t)return o.name}return e}function ii(t){return(Mt.call(Fn,"placeholder")?Fn:t).placeholder}function si(){var t=Fn.iteratee||ru;return t=t===ru?Mr:t,arguments.length?t(arguments[0],arguments[1]):t}function ai(t,e){var n,r,o=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof e?"string":"hash"]:o.map}function ui(t){for(var e=Sa(t),n=e.length;n--;){var r=e[n],o=t[r];e[n]=[r,o,_i(o)]}return e}function ci(t,e){var n=function(t,e){return null==t?o:t[e]}(t,e);return Lr(n)?n:o}var li=ge?function(t){return null==t?[]:(t=Et(t),Pe(ge(t),(function(e){return Yt.call(t,e)})))}:du,fi=ge?function(t){for(var e=[];t;)Le(e,li(t)),t=Vt(t);return e}:du,hi=Cr;function pi(t,e,n){for(var r=-1,o=(e=yo(e,t)).length,i=!1;++r<o;){var s=Bi(e[r]);if(!(i=null!=t&&n(t,s)))break;t=t[s]}return i||++r!=o?i:!!(o=null==t?0:t.length)&&Zs(o)&&mi(s,o)&&(Us(t)||js(t))}function di(t){return"function"!=typeof t.constructor||Ai(t)?{}:kn(Vt(t))}function gi(t){return Us(t)||js(t)||!!(Kt&&t&&t[Kt])}function mi(t,e){var n=typeof t;return!!(e=null==e?f:e)&&("number"==n||"symbol"!=n&&yt.test(t))&&t>-1&&t%1==0&&t<e}function yi(t,e,n){if(!Xs(n))return!1;var r=typeof e;return!!("number"==r?Ws(n)&&mi(e,n.length):"string"==r&&e in n)&&ks(n[e],t)}function vi(t,e){if(Us(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!aa(t))||X.test(t)||!Z.test(t)||null!=e&&t in Et(e)}function bi(t){var e=oi(t),n=Fn[e];if("function"!=typeof n||!(e in jn.prototype))return!1;if(t===n)return!0;var r=ri(n);return!!r&&t===r[0]}(_n&&hi(new _n(new ArrayBuffer(1)))!=L||Cn&&hi(new Cn)!=_||En&&hi(En.resolve())!=x||xn&&hi(new xn)!=I||Tn&&hi(new Tn)!=S)&&(hi=function(t){var e=Cr(t),n=e==E?t.constructor:o,r=n?Ri(n):"";if(r)switch(r){case Sn:return L;case Nn:return _;case Ln:return x;case Mn:return I;case $n:return S}return e});var wi=Nt?Js:gu;function Ai(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||St)}function _i(t){return t==t&&!Xs(t)}function Ci(t,e){return function(n){return null!=n&&n[t]===e&&(e!==o||t in Et(n))}}function Ei(t,e,n){return e=mn(e===o?t.length-1:e,0),function(){for(var o=arguments,i=-1,s=mn(o.length-e,0),a=r(s);++i<s;)a[i]=o[e+i];i=-1;for(var u=r(e+1);++i<e;)u[i]=o[i];return u[e]=n(a),Ce(t,this,u)}}function xi(t,e){return e.length<2?t:Ar(t,to(e,0,-1))}function Ti(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Ii=Ni(Qr),Pi=le||function(t,e){return fe.setTimeout(t,e)},Oi=Ni(Zr);function Si(t,e,n){var r=e+"";return Oi(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(it,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return xe(d,(function(n){var r="_."+n[0];e&n[1]&&!Oe(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(st);return e?e[1].split(at):[]}(r),n)))}function Ni(t){var e=0,n=0;return function(){var r=vn(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(o,arguments)}}function Li(t,e){var n=-1,r=t.length,i=r-1;for(e=e===o?r:e;++n<e;){var s=Wr(n,i),a=t[s];t[s]=t[n],t[n]=a}return t.length=e,t}var Mi,$i,Di=(Mi=Ms((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(tt,(function(t,n,r,o){e.push(r?o.replace(lt,"$1"):n||t)})),e}),(function(t){return 500===$i.size&&$i.clear(),t})),$i=Mi.cache,Mi);function Bi(t){if("string"==typeof t||aa(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Ri(t){if(null!=t){try{return Lt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Fi(t){if(t instanceof jn)return t.clone();var e=new Gn(t.__wrapped__,t.__chain__);return e.__actions__=Io(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var ki=qr((function(t,e){return Ys(t)?cr(t,gr(e,1,Ys,!0)):[]})),Hi=qr((function(t,e){var n=zi(e);return Ys(n)&&(n=o),Ys(t)?cr(t,gr(e,1,Ys,!0),si(n,2)):[]})),Gi=qr((function(t,e){var n=zi(e);return Ys(n)&&(n=o),Ys(t)?cr(t,gr(e,1,Ys,!0),o,n):[]}));function ji(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:pa(n);return o<0&&(o=mn(r+o,0)),Fe(t,si(e,3),o)}function Ui(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r-1;return n!==o&&(i=pa(n),i=n<0?mn(r+i,0):yn(i,r-1)),Fe(t,si(e,3),i,!0)}function Vi(t){return null!=t&&t.length?gr(t,1):[]}function Wi(t){return t&&t.length?t[0]:o}var Yi=qr((function(t){var e=Ne(t,go);return e.length&&e[0]===t[0]?Ir(e):[]})),qi=qr((function(t){var e=zi(t),n=Ne(t,go);return e===zi(n)?e=o:n.pop(),n.length&&n[0]===t[0]?Ir(n,si(e,2)):[]})),Ki=qr((function(t){var e=zi(t),n=Ne(t,go);return(e="function"==typeof e?e:o)&&n.pop(),n.length&&n[0]===t[0]?Ir(n,o,e):[]}));function zi(t){var e=null==t?0:t.length;return e?t[e-1]:o}var Ji=qr(Qi);function Qi(t,e){return t&&t.length&&e&&e.length?Ur(t,e):t}var Zi=ti((function(t,e){var n=null==t?0:t.length,r=or(t,e);return Vr(t,Ne(e,(function(t){return mi(t,n)?+t:t})).sort(Eo)),r}));function Xi(t){return null==t?t:An.call(t)}var ts=qr((function(t){return ao(gr(t,1,Ys,!0))})),es=qr((function(t){var e=zi(t);return Ys(e)&&(e=o),ao(gr(t,1,Ys,!0),si(e,2))})),ns=qr((function(t){var e=zi(t);return e="function"==typeof e?e:o,ao(gr(t,1,Ys,!0),o,e)}));function rs(t){if(!t||!t.length)return[];var e=0;return t=Pe(t,(function(t){if(Ys(t))return e=mn(t.length,e),!0})),qe(e,(function(e){return Ne(t,Ue(e))}))}function os(t,e){if(!t||!t.length)return[];var n=rs(t);return null==e?n:Ne(n,(function(t){return Ce(e,o,t)}))}var is=qr((function(t,e){return Ys(t)?cr(t,e):[]})),ss=qr((function(t){return ho(Pe(t,Ys))})),as=qr((function(t){var e=zi(t);return Ys(e)&&(e=o),ho(Pe(t,Ys),si(e,2))})),us=qr((function(t){var e=zi(t);return e="function"==typeof e?e:o,ho(Pe(t,Ys),o,e)})),cs=qr(rs),ls=qr((function(t){var e=t.length,n=e>1?t[e-1]:o;return n="function"==typeof n?(t.pop(),n):o,os(t,n)}));function fs(t){var e=Fn(t);return e.__chain__=!0,e}function hs(t,e){return e(t)}var ps=ti((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return or(e,t)};return!(e>1||this.__actions__.length)&&r instanceof jn&&mi(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:hs,args:[i],thisArg:o}),new Gn(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(o),t}))):this.thru(i)})),ds=Oo((function(t,e,n){Mt.call(t,n)?++t[n]:rr(t,n,1)})),gs=Bo(ji),ms=Bo(Ui);function ys(t,e){return(Us(t)?xe:lr)(t,si(e,3))}function vs(t,e){return(Us(t)?Te:fr)(t,si(e,3))}var bs=Oo((function(t,e,n){Mt.call(t,n)?t[n].push(e):rr(t,n,[e])})),ws=qr((function(t,e,n){var o=-1,i="function"==typeof e,s=Ws(t)?r(t.length):[];return lr(t,(function(t){s[++o]=i?Ce(e,t,n):Pr(t,e,n)})),s})),As=Oo((function(t,e,n){rr(t,n,e)}));function _s(t,e){return(Us(t)?Ne:Br)(t,si(e,3))}var Cs=Oo((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]})),Es=qr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&yi(t,e[0],e[1])?e=[]:n>2&&yi(e[0],e[1],e[2])&&(e=[e[0]]),Gr(t,gr(e,1),[])})),xs=ce||function(){return fe.Date.now()};function Ts(t,e,n){return e=n?o:e,e=t&&null==e?t.length:e,zo(t,c,o,o,o,o,e)}function Is(t,e){var n;if("function"!=typeof e)throw new It(i);return t=pa(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=o),n}}var Ps=qr((function(t,e,n){var r=1;if(n.length){var o=an(n,ii(Ps));r|=u}return zo(t,r,e,n,o)})),Os=qr((function(t,e,n){var r=3;if(n.length){var o=an(n,ii(Os));r|=u}return zo(e,r,t,n,o)}));function Ss(t,e,n){var r,s,a,u,c,l,f=0,h=!1,p=!1,d=!0;if("function"!=typeof t)throw new It(i);function g(e){var n=r,i=s;return r=s=o,f=e,u=t.apply(i,n)}function m(t){var n=t-l;return l===o||n>=e||n<0||p&&t-f>=a}function y(){var t=xs();if(m(t))return v(t);c=Pi(y,function(t){var n=e-(t-l);return p?yn(n,a-(t-f)):n}(t))}function v(t){return c=o,d&&r?g(t):(r=s=o,u)}function b(){var t=xs(),n=m(t);if(r=arguments,s=this,l=t,n){if(c===o)return function(t){return f=t,c=Pi(y,e),h?g(t):u}(l);if(p)return wo(c),c=Pi(y,e),g(l)}return c===o&&(c=Pi(y,e)),u}return e=ga(e)||0,Xs(n)&&(h=!!n.leading,a=(p="maxWait"in n)?mn(ga(n.maxWait)||0,e):a,d="trailing"in n?!!n.trailing:d),b.cancel=function(){c!==o&&wo(c),f=0,r=l=s=c=o},b.flush=function(){return c===o?u:v(xs())},b}var Ns=qr((function(t,e){return ur(t,1,e)})),Ls=qr((function(t,e,n){return ur(t,ga(e)||0,n)}));function Ms(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new It(i);var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var s=t.apply(this,r);return n.cache=i.set(o,s)||i,s};return n.cache=new(Ms.Cache||Wn),n}function $s(t){if("function"!=typeof t)throw new It(i);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}Ms.Cache=Wn;var Ds=vo((function(t,e){var n=(e=1==e.length&&Us(e[0])?Ne(e[0],ze(si())):Ne(gr(e,1),ze(si()))).length;return qr((function(r){for(var o=-1,i=yn(r.length,n);++o<i;)r[o]=e[o].call(this,r[o]);return Ce(t,this,r)}))})),Bs=qr((function(t,e){var n=an(e,ii(Bs));return zo(t,u,o,e,n)})),Rs=qr((function(t,e){var n=an(e,ii(Rs));return zo(t,64,o,e,n)})),Fs=ti((function(t,e){return zo(t,256,o,o,o,e)}));function ks(t,e){return t===e||t!=t&&e!=e}var Hs=Vo(Er),Gs=Vo((function(t,e){return t>=e})),js=Or(function(){return arguments}())?Or:function(t){return ta(t)&&Mt.call(t,"callee")&&!Yt.call(t,"callee")},Us=r.isArray,Vs=ye?ze(ye):function(t){return ta(t)&&Cr(t)==N};function Ws(t){return null!=t&&Zs(t.length)&&!Js(t)}function Ys(t){return ta(t)&&Ws(t)}var qs=me||gu,Ks=ve?ze(ve):function(t){return ta(t)&&Cr(t)==v};function zs(t){if(!ta(t))return!1;var e=Cr(t);return e==b||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!ra(t)}function Js(t){if(!Xs(t))return!1;var e=Cr(t);return e==w||e==A||"[object AsyncFunction]"==e||"[object Proxy]"==e}function Qs(t){return"number"==typeof t&&t==pa(t)}function Zs(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=f}function Xs(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ta(t){return null!=t&&"object"==typeof t}var ea=be?ze(be):function(t){return ta(t)&&hi(t)==_};function na(t){return"number"==typeof t||ta(t)&&Cr(t)==C}function ra(t){if(!ta(t)||Cr(t)!=E)return!1;var e=Vt(t);if(null===e)return!0;var n=Mt.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Lt.call(n)==Rt}var oa=we?ze(we):function(t){return ta(t)&&Cr(t)==T},ia=Ae?ze(Ae):function(t){return ta(t)&&hi(t)==I};function sa(t){return"string"==typeof t||!Us(t)&&ta(t)&&Cr(t)==P}function aa(t){return"symbol"==typeof t||ta(t)&&Cr(t)==O}var ua=_e?ze(_e):function(t){return ta(t)&&Zs(t.length)&&!!oe[Cr(t)]},ca=Vo(Dr),la=Vo((function(t,e){return t<=e}));function fa(t){if(!t)return[];if(Ws(t))return sa(t)?fn(t):Io(t);if(zt&&t[zt])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[zt]());var e=hi(t);return(e==_?on:e==I?un:ka)(t)}function ha(t){return t?(t=ga(t))===l||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function pa(t){var e=ha(t),n=e%1;return e==e?n?e-n:e:0}function da(t){return t?ir(pa(t),0,p):0}function ga(t){if("number"==typeof t)return t;if(aa(t))return h;if(Xs(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Xs(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ke(t);var n=dt.test(t);return n||mt.test(t)?ue(t.slice(2),n?2:8):pt.test(t)?h:+t}function ma(t){return Po(t,Na(t))}function ya(t){return null==t?"":so(t)}var va=So((function(t,e){if(Ai(e)||Ws(e))Po(e,Sa(e),t);else for(var n in e)Mt.call(e,n)&&Xn(t,n,e[n])})),ba=So((function(t,e){Po(e,Na(e),t)})),wa=So((function(t,e,n,r){Po(e,Na(e),t,r)})),Aa=So((function(t,e,n,r){Po(e,Sa(e),t,r)})),_a=ti(or),Ca=qr((function(t,e){t=Et(t);var n=-1,r=e.length,i=r>2?e[2]:o;for(i&&yi(e[0],e[1],i)&&(r=1);++n<r;)for(var s=e[n],a=Na(s),u=-1,c=a.length;++u<c;){var l=a[u],f=t[l];(f===o||ks(f,St[l])&&!Mt.call(t,l))&&(t[l]=s[l])}return t})),Ea=qr((function(t){return t.push(o,Qo),Ce(Ma,o,t)}));function xa(t,e,n){var r=null==t?o:Ar(t,e);return r===o?n:r}function Ta(t,e){return null!=t&&pi(t,e,Tr)}var Ia=ko((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Bt.call(e)),t[e]=n}),Xa(nu)),Pa=ko((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Bt.call(e)),Mt.call(t,e)?t[e].push(n):t[e]=[n]}),si),Oa=qr(Pr);function Sa(t){return Ws(t)?Kn(t):$r(t)}function Na(t){return Ws(t)?Kn(t,!0):function(t){if(!Xs(t))return function(t){var e=[];if(null!=t)for(var n in Et(t))e.push(n);return e}(t);var e=Ai(t),n=[];for(var r in t)("constructor"!=r||!e&&Mt.call(t,r))&&n.push(r);return n}(t)}var La=So((function(t,e,n){kr(t,e,n)})),Ma=So((function(t,e,n,r){kr(t,e,n,r)})),$a=ti((function(t,e){var n={};if(null==t)return n;var r=!1;e=Ne(e,(function(e){return e=yo(e,t),r||(r=e.length>1),e})),Po(t,ni(t),n),r&&(n=sr(n,7,Zo));for(var o=e.length;o--;)uo(n,e[o]);return n})),Da=ti((function(t,e){return null==t?{}:function(t,e){return jr(t,e,(function(e,n){return Ta(t,n)}))}(t,e)}));function Ba(t,e){if(null==t)return{};var n=Ne(ni(t),(function(t){return[t]}));return e=si(e),jr(t,n,(function(t,n){return e(t,n[0])}))}var Ra=Ko(Sa),Fa=Ko(Na);function ka(t){return null==t?[]:Je(t,Sa(t))}var Ha=$o((function(t,e,n){return e=e.toLowerCase(),t+(n?Ga(e):e)}));function Ga(t){return za(ya(t).toLowerCase())}function ja(t){return(t=ya(t))&&t.replace(vt,tn).replace(Qt,"")}var Ua=$o((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Va=$o((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Wa=Mo("toLowerCase"),Ya=$o((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()})),qa=$o((function(t,e,n){return t+(n?" ":"")+za(e)})),Ka=$o((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),za=Mo("toUpperCase");function Ja(t,e,n){return t=ya(t),(e=n?o:e)===o?function(t){return ee.test(t)}(t)?function(t){return t.match(Xt)||[]}(t):function(t){return t.match(ut)||[]}(t):t.match(e)||[]}var Qa=qr((function(t,e){try{return Ce(t,o,e)}catch(t){return zs(t)?t:new At(t)}})),Za=ti((function(t,e){return xe(e,(function(e){e=Bi(e),rr(t,e,Ps(t[e],t))})),t}));function Xa(t){return function(){return t}}var tu=Ro(),eu=Ro(!0);function nu(t){return t}function ru(t){return Mr("function"==typeof t?t:sr(t,1))}var ou=qr((function(t,e){return function(n){return Pr(n,t,e)}})),iu=qr((function(t,e){return function(n){return Pr(t,n,e)}}));function su(t,e,n){var r=Sa(e),o=wr(e,r);null!=n||Xs(e)&&(o.length||!r.length)||(n=e,e=t,t=this,o=wr(e,Sa(e)));var i=!(Xs(n)&&"chain"in n&&!n.chain),s=Js(t);return xe(o,(function(n){var r=e[n];t[n]=r,s&&(t.prototype[n]=function(){var e=this.__chain__;if(i||e){var n=t(this.__wrapped__);return(n.__actions__=Io(this.__actions__)).push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Le([this.value()],arguments))})})),t}function au(){}var uu=Go(Ne),cu=Go(Ie),lu=Go(De);function fu(t){return vi(t)?Ue(Bi(t)):function(t){return function(e){return Ar(e,t)}}(t)}var hu=Uo(),pu=Uo(!0);function du(){return[]}function gu(){return!1}var mu,yu=Ho((function(t,e){return t+e}),0),vu=Yo("ceil"),bu=Ho((function(t,e){return t/e}),1),wu=Yo("floor"),Au=Ho((function(t,e){return t*e}),1),_u=Yo("round"),Cu=Ho((function(t,e){return t-e}),0);return Fn.after=function(t,e){if("function"!=typeof e)throw new It(i);return t=pa(t),function(){if(--t<1)return e.apply(this,arguments)}},Fn.ary=Ts,Fn.assign=va,Fn.assignIn=ba,Fn.assignInWith=wa,Fn.assignWith=Aa,Fn.at=_a,Fn.before=Is,Fn.bind=Ps,Fn.bindAll=Za,Fn.bindKey=Os,Fn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Us(t)?t:[t]},Fn.chain=fs,Fn.chunk=function(t,e,n){e=(n?yi(t,e,n):e===o)?1:mn(pa(e),0);var i=null==t?0:t.length;if(!i||e<1)return[];for(var s=0,a=0,u=r(he(i/e));s<i;)u[a++]=to(t,s,s+=e);return u},Fn.compact=function(t){for(var e=-1,n=null==t?0:t.length,r=0,o=[];++e<n;){var i=t[e];i&&(o[r++]=i)}return o},Fn.concat=function(){var t=arguments.length;if(!t)return[];for(var e=r(t-1),n=arguments[0],o=t;o--;)e[o-1]=arguments[o];return Le(Us(n)?Io(n):[n],gr(e,1))},Fn.cond=function(t){var e=null==t?0:t.length,n=si();return t=e?Ne(t,(function(t){if("function"!=typeof t[1])throw new It(i);return[n(t[0]),t[1]]})):[],qr((function(n){for(var r=-1;++r<e;){var o=t[r];if(Ce(o[0],this,n))return Ce(o[1],this,n)}}))},Fn.conforms=function(t){return function(t){var e=Sa(t);return function(n){return ar(n,t,e)}}(sr(t,1))},Fn.constant=Xa,Fn.countBy=ds,Fn.create=function(t,e){var n=kn(t);return null==e?n:nr(n,e)},Fn.curry=function t(e,n,r){var i=zo(e,8,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Fn.curryRight=function t(e,n,r){var i=zo(e,16,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Fn.debounce=Ss,Fn.defaults=Ca,Fn.defaultsDeep=Ea,Fn.defer=Ns,Fn.delay=Ls,Fn.difference=ki,Fn.differenceBy=Hi,Fn.differenceWith=Gi,Fn.drop=function(t,e,n){var r=null==t?0:t.length;return r?to(t,(e=n||e===o?1:pa(e))<0?0:e,r):[]},Fn.dropRight=function(t,e,n){var r=null==t?0:t.length;return r?to(t,0,(e=r-(e=n||e===o?1:pa(e)))<0?0:e):[]},Fn.dropRightWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!0,!0):[]},Fn.dropWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!0):[]},Fn.fill=function(t,e,n,r){var i=null==t?0:t.length;return i?(n&&"number"!=typeof n&&yi(t,e,n)&&(n=0,r=i),function(t,e,n,r){var i=t.length;for((n=pa(n))<0&&(n=-n>i?0:i+n),(r=r===o||r>i?i:pa(r))<0&&(r+=i),r=n>r?0:da(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},Fn.filter=function(t,e){return(Us(t)?Pe:dr)(t,si(e,3))},Fn.flatMap=function(t,e){return gr(_s(t,e),1)},Fn.flatMapDeep=function(t,e){return gr(_s(t,e),l)},Fn.flatMapDepth=function(t,e,n){return n=n===o?1:pa(n),gr(_s(t,e),n)},Fn.flatten=Vi,Fn.flattenDeep=function(t){return null!=t&&t.length?gr(t,l):[]},Fn.flattenDepth=function(t,e){return null!=t&&t.length?gr(t,e=e===o?1:pa(e)):[]},Fn.flip=function(t){return zo(t,512)},Fn.flow=tu,Fn.flowRight=eu,Fn.fromPairs=function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var o=t[e];r[o[0]]=o[1]}return r},Fn.functions=function(t){return null==t?[]:wr(t,Sa(t))},Fn.functionsIn=function(t){return null==t?[]:wr(t,Na(t))},Fn.groupBy=bs,Fn.initial=function(t){return null!=t&&t.length?to(t,0,-1):[]},Fn.intersection=Yi,Fn.intersectionBy=qi,Fn.intersectionWith=Ki,Fn.invert=Ia,Fn.invertBy=Pa,Fn.invokeMap=ws,Fn.iteratee=ru,Fn.keyBy=As,Fn.keys=Sa,Fn.keysIn=Na,Fn.map=_s,Fn.mapKeys=function(t,e){var n={};return e=si(e,3),vr(t,(function(t,r,o){rr(n,e(t,r,o),t)})),n},Fn.mapValues=function(t,e){var n={};return e=si(e,3),vr(t,(function(t,r,o){rr(n,r,e(t,r,o))})),n},Fn.matches=function(t){return Rr(sr(t,1))},Fn.matchesProperty=function(t,e){return Fr(t,sr(e,1))},Fn.memoize=Ms,Fn.merge=La,Fn.mergeWith=Ma,Fn.method=ou,Fn.methodOf=iu,Fn.mixin=su,Fn.negate=$s,Fn.nthArg=function(t){return t=pa(t),qr((function(e){return Hr(e,t)}))},Fn.omit=$a,Fn.omitBy=function(t,e){return Ba(t,$s(si(e)))},Fn.once=function(t){return Is(2,t)},Fn.orderBy=function(t,e,n,r){return null==t?[]:(Us(e)||(e=null==e?[]:[e]),Us(n=r?o:n)||(n=null==n?[]:[n]),Gr(t,e,n))},Fn.over=uu,Fn.overArgs=Ds,Fn.overEvery=cu,Fn.overSome=lu,Fn.partial=Bs,Fn.partialRight=Rs,Fn.partition=Cs,Fn.pick=Da,Fn.pickBy=Ba,Fn.property=fu,Fn.propertyOf=function(t){return function(e){return null==t?o:Ar(t,e)}},Fn.pull=Ji,Fn.pullAll=Qi,Fn.pullAllBy=function(t,e,n){return t&&t.length&&e&&e.length?Ur(t,e,si(n,2)):t},Fn.pullAllWith=function(t,e,n){return t&&t.length&&e&&e.length?Ur(t,e,o,n):t},Fn.pullAt=Zi,Fn.range=hu,Fn.rangeRight=pu,Fn.rearg=Fs,Fn.reject=function(t,e){return(Us(t)?Pe:dr)(t,$s(si(e,3)))},Fn.remove=function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,o=[],i=t.length;for(e=si(e,3);++r<i;){var s=t[r];e(s,r,t)&&(n.push(s),o.push(r))}return Vr(t,o),n},Fn.rest=function(t,e){if("function"!=typeof t)throw new It(i);return qr(t,e=e===o?e:pa(e))},Fn.reverse=Xi,Fn.sampleSize=function(t,e,n){return e=(n?yi(t,e,n):e===o)?1:pa(e),(Us(t)?Jn:zr)(t,e)},Fn.set=function(t,e,n){return null==t?t:Jr(t,e,n)},Fn.setWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:Jr(t,e,n,r)},Fn.shuffle=function(t){return(Us(t)?Qn:Xr)(t)},Fn.slice=function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&yi(t,e,n)?(e=0,n=r):(e=null==e?0:pa(e),n=n===o?r:pa(n)),to(t,e,n)):[]},Fn.sortBy=Es,Fn.sortedUniq=function(t){return t&&t.length?oo(t):[]},Fn.sortedUniqBy=function(t,e){return t&&t.length?oo(t,si(e,2)):[]},Fn.split=function(t,e,n){return n&&"number"!=typeof n&&yi(t,e,n)&&(e=n=o),(n=n===o?p:n>>>0)?(t=ya(t))&&("string"==typeof e||null!=e&&!oa(e))&&!(e=so(e))&&rn(t)?bo(fn(t),0,n):t.split(e,n):[]},Fn.spread=function(t,e){if("function"!=typeof t)throw new It(i);return e=null==e?0:mn(pa(e),0),qr((function(n){var r=n[e],o=bo(n,0,e);return r&&Le(o,r),Ce(t,this,o)}))},Fn.tail=function(t){var e=null==t?0:t.length;return e?to(t,1,e):[]},Fn.take=function(t,e,n){return t&&t.length?to(t,0,(e=n||e===o?1:pa(e))<0?0:e):[]},Fn.takeRight=function(t,e,n){var r=null==t?0:t.length;return r?to(t,(e=r-(e=n||e===o?1:pa(e)))<0?0:e,r):[]},Fn.takeRightWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!1,!0):[]},Fn.takeWhile=function(t,e){return t&&t.length?lo(t,si(e,3)):[]},Fn.tap=function(t,e){return e(t),t},Fn.throttle=function(t,e,n){var r=!0,o=!0;if("function"!=typeof t)throw new It(i);return Xs(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),Ss(t,e,{leading:r,maxWait:e,trailing:o})},Fn.thru=hs,Fn.toArray=fa,Fn.toPairs=Ra,Fn.toPairsIn=Fa,Fn.toPath=function(t){return Us(t)?Ne(t,Bi):aa(t)?[t]:Io(Di(ya(t)))},Fn.toPlainObject=ma,Fn.transform=function(t,e,n){var r=Us(t),o=r||qs(t)||ua(t);if(e=si(e,4),null==n){var i=t&&t.constructor;n=o?r?new i:[]:Xs(t)&&Js(i)?kn(Vt(t)):{}}return(o?xe:vr)(t,(function(t,r,o){return e(n,t,r,o)})),n},Fn.unary=function(t){return Ts(t,1)},Fn.union=ts,Fn.unionBy=es,Fn.unionWith=ns,Fn.uniq=function(t){return t&&t.length?ao(t):[]},Fn.uniqBy=function(t,e){return t&&t.length?ao(t,si(e,2)):[]},Fn.uniqWith=function(t,e){return e="function"==typeof e?e:o,t&&t.length?ao(t,o,e):[]},Fn.unset=function(t,e){return null==t||uo(t,e)},Fn.unzip=rs,Fn.unzipWith=os,Fn.update=function(t,e,n){return null==t?t:co(t,e,mo(n))},Fn.updateWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:co(t,e,mo(n),r)},Fn.values=ka,Fn.valuesIn=function(t){return null==t?[]:Je(t,Na(t))},Fn.without=is,Fn.words=Ja,Fn.wrap=function(t,e){return Bs(mo(e),t)},Fn.xor=ss,Fn.xorBy=as,Fn.xorWith=us,Fn.zip=cs,Fn.zipObject=function(t,e){return po(t||[],e||[],Xn)},Fn.zipObjectDeep=function(t,e){return po(t||[],e||[],Jr)},Fn.zipWith=ls,Fn.entries=Ra,Fn.entriesIn=Fa,Fn.extend=ba,Fn.extendWith=wa,su(Fn,Fn),Fn.add=yu,Fn.attempt=Qa,Fn.camelCase=Ha,Fn.capitalize=Ga,Fn.ceil=vu,Fn.clamp=function(t,e,n){return n===o&&(n=e,e=o),n!==o&&(n=(n=ga(n))==n?n:0),e!==o&&(e=(e=ga(e))==e?e:0),ir(ga(t),e,n)},Fn.clone=function(t){return sr(t,4)},Fn.cloneDeep=function(t){return sr(t,5)},Fn.cloneDeepWith=function(t,e){return sr(t,5,e="function"==typeof e?e:o)},Fn.cloneWith=function(t,e){return sr(t,4,e="function"==typeof e?e:o)},Fn.conformsTo=function(t,e){return null==e||ar(t,e,Sa(e))},Fn.deburr=ja,Fn.defaultTo=function(t,e){return null==t||t!=t?e:t},Fn.divide=bu,Fn.endsWith=function(t,e,n){t=ya(t),e=so(e);var r=t.length,i=n=n===o?r:ir(pa(n),0,r);return(n-=e.length)>=0&&t.slice(n,i)==e},Fn.eq=ks,Fn.escape=function(t){return(t=ya(t))&&K.test(t)?t.replace(Y,en):t},Fn.escapeRegExp=function(t){return(t=ya(t))&&nt.test(t)?t.replace(et,"\\$&"):t},Fn.every=function(t,e,n){var r=Us(t)?Ie:hr;return n&&yi(t,e,n)&&(e=o),r(t,si(e,3))},Fn.find=gs,Fn.findIndex=ji,Fn.findKey=function(t,e){return Re(t,si(e,3),vr)},Fn.findLast=ms,Fn.findLastIndex=Ui,Fn.findLastKey=function(t,e){return Re(t,si(e,3),br)},Fn.floor=wu,Fn.forEach=ys,Fn.forEachRight=vs,Fn.forIn=function(t,e){return null==t?t:mr(t,si(e,3),Na)},Fn.forInRight=function(t,e){return null==t?t:yr(t,si(e,3),Na)},Fn.forOwn=function(t,e){return t&&vr(t,si(e,3))},Fn.forOwnRight=function(t,e){return t&&br(t,si(e,3))},Fn.get=xa,Fn.gt=Hs,Fn.gte=Gs,Fn.has=function(t,e){return null!=t&&pi(t,e,xr)},Fn.hasIn=Ta,Fn.head=Wi,Fn.identity=nu,Fn.includes=function(t,e,n,r){t=Ws(t)?t:ka(t),n=n&&!r?pa(n):0;var o=t.length;return n<0&&(n=mn(o+n,0)),sa(t)?n<=o&&t.indexOf(e,n)>-1:!!o&&ke(t,e,n)>-1},Fn.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:pa(n);return o<0&&(o=mn(r+o,0)),ke(t,e,o)},Fn.inRange=function(t,e,n){return e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n){return t>=yn(e,n)&&t<mn(e,n)}(t=ga(t),e,n)},Fn.invoke=Oa,Fn.isArguments=js,Fn.isArray=Us,Fn.isArrayBuffer=Vs,Fn.isArrayLike=Ws,Fn.isArrayLikeObject=Ys,Fn.isBoolean=function(t){return!0===t||!1===t||ta(t)&&Cr(t)==y},Fn.isBuffer=qs,Fn.isDate=Ks,Fn.isElement=function(t){return ta(t)&&1===t.nodeType&&!ra(t)},Fn.isEmpty=function(t){if(null==t)return!0;if(Ws(t)&&(Us(t)||"string"==typeof t||"function"==typeof t.splice||qs(t)||ua(t)||js(t)))return!t.length;var e=hi(t);if(e==_||e==I)return!t.size;if(Ai(t))return!$r(t).length;for(var n in t)if(Mt.call(t,n))return!1;return!0},Fn.isEqual=function(t,e){return Sr(t,e)},Fn.isEqualWith=function(t,e,n){var r=(n="function"==typeof n?n:o)?n(t,e):o;return r===o?Sr(t,e,o,n):!!r},Fn.isError=zs,Fn.isFinite=function(t){return"number"==typeof t&&Be(t)},Fn.isFunction=Js,Fn.isInteger=Qs,Fn.isLength=Zs,Fn.isMap=ea,Fn.isMatch=function(t,e){return t===e||Nr(t,e,ui(e))},Fn.isMatchWith=function(t,e,n){return n="function"==typeof n?n:o,Nr(t,e,ui(e),n)},Fn.isNaN=function(t){return na(t)&&t!=+t},Fn.isNative=function(t){if(wi(t))throw new At("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Lr(t)},Fn.isNil=function(t){return null==t},Fn.isNull=function(t){return null===t},Fn.isNumber=na,Fn.isObject=Xs,Fn.isObjectLike=ta,Fn.isPlainObject=ra,Fn.isRegExp=oa,Fn.isSafeInteger=function(t){return Qs(t)&&t>=-9007199254740991&&t<=f},Fn.isSet=ia,Fn.isString=sa,Fn.isSymbol=aa,Fn.isTypedArray=ua,Fn.isUndefined=function(t){return t===o},Fn.isWeakMap=function(t){return ta(t)&&hi(t)==S},Fn.isWeakSet=function(t){return ta(t)&&"[object WeakSet]"==Cr(t)},Fn.join=function(t,e){return null==t?"":Ve.call(t,e)},Fn.kebabCase=Ua,Fn.last=zi,Fn.lastIndexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r;return n!==o&&(i=(i=pa(n))<0?mn(r+i,0):yn(i,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,i):Fe(t,Ge,i,!0)},Fn.lowerCase=Va,Fn.lowerFirst=Wa,Fn.lt=ca,Fn.lte=la,Fn.max=function(t){return t&&t.length?pr(t,nu,Er):o},Fn.maxBy=function(t,e){return t&&t.length?pr(t,si(e,2),Er):o},Fn.mean=function(t){return je(t,nu)},Fn.meanBy=function(t,e){return je(t,si(e,2))},Fn.min=function(t){return t&&t.length?pr(t,nu,Dr):o},Fn.minBy=function(t,e){return t&&t.length?pr(t,si(e,2),Dr):o},Fn.stubArray=du,Fn.stubFalse=gu,Fn.stubObject=function(){return{}},Fn.stubString=function(){return""},Fn.stubTrue=function(){return!0},Fn.multiply=Au,Fn.nth=function(t,e){return t&&t.length?Hr(t,pa(e)):o},Fn.noConflict=function(){return fe._===this&&(fe._=Ft),this},Fn.noop=au,Fn.now=xs,Fn.pad=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;if(!e||r>=e)return t;var o=(e-r)/2;return jo(pe(o),n)+t+jo(he(o),n)},Fn.padEnd=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;return e&&r<e?t+jo(e-r,n):t},Fn.padStart=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;return e&&r<e?jo(e-r,n)+t:t},Fn.parseInt=function(t,e,n){return n||null==e?e=0:e&&(e=+e),bn(ya(t).replace(rt,""),e||0)},Fn.random=function(t,e,n){if(n&&"boolean"!=typeof n&&yi(t,e,n)&&(e=n=o),n===o&&("boolean"==typeof e?(n=e,e=o):"boolean"==typeof t&&(n=t,t=o)),t===o&&e===o?(t=0,e=1):(t=ha(t),e===o?(e=t,t=0):e=ha(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var i=wn();return yn(t+i*(e-t+ae("1e-"+((i+"").length-1))),e)}return Wr(t,e)},Fn.reduce=function(t,e,n){var r=Us(t)?Me:We,o=arguments.length<3;return r(t,si(e,4),n,o,lr)},Fn.reduceRight=function(t,e,n){var r=Us(t)?$e:We,o=arguments.length<3;return r(t,si(e,4),n,o,fr)},Fn.repeat=function(t,e,n){return e=(n?yi(t,e,n):e===o)?1:pa(e),Yr(ya(t),e)},Fn.replace=function(){var t=arguments,e=ya(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Fn.result=function(t,e,n){var r=-1,i=(e=yo(e,t)).length;for(i||(i=1,t=o);++r<i;){var s=null==t?o:t[Bi(e[r])];s===o&&(r=i,s=n),t=Js(s)?s.call(t):s}return t},Fn.round=_u,Fn.runInContext=t,Fn.sample=function(t){return(Us(t)?zn:Kr)(t)},Fn.size=function(t){if(null==t)return 0;if(Ws(t))return sa(t)?ln(t):t.length;var e=hi(t);return e==_||e==I?t.size:$r(t).length},Fn.snakeCase=Ya,Fn.some=function(t,e,n){var r=Us(t)?De:eo;return n&&yi(t,e,n)&&(e=o),r(t,si(e,3))},Fn.sortedIndex=function(t,e){return no(t,e)},Fn.sortedIndexBy=function(t,e,n){return ro(t,e,si(n,2))},Fn.sortedIndexOf=function(t,e){var n=null==t?0:t.length;if(n){var r=no(t,e);if(r<n&&ks(t[r],e))return r}return-1},Fn.sortedLastIndex=function(t,e){return no(t,e,!0)},Fn.sortedLastIndexBy=function(t,e,n){return ro(t,e,si(n,2),!0)},Fn.sortedLastIndexOf=function(t,e){if(null!=t&&t.length){var n=no(t,e,!0)-1;if(ks(t[n],e))return n}return-1},Fn.startCase=qa,Fn.startsWith=function(t,e,n){return t=ya(t),n=null==n?0:ir(pa(n),0,t.length),e=so(e),t.slice(n,n+e.length)==e},Fn.subtract=Cu,Fn.sum=function(t){return t&&t.length?Ye(t,nu):0},Fn.sumBy=function(t,e){return t&&t.length?Ye(t,si(e,2)):0},Fn.template=function(t,e,n){var r=Fn.templateSettings;n&&yi(t,e,n)&&(e=o),t=ya(t),e=wa({},e,r,Jo);var i,s,a=wa({},e.imports,r.imports,Jo),u=Sa(a),c=Je(a,u),l=0,f=e.interpolate||bt,h="__p += '",p=xt((e.escape||bt).source+"|"+f.source+"|"+(f===Q?ft:bt).source+"|"+(e.evaluate||bt).source+"|$","g"),d="//# sourceURL="+(Mt.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++re+"]")+"\n";t.replace(p,(function(e,n,r,o,a,u){return r||(r=o),h+=t.slice(l,u).replace(wt,nn),n&&(i=!0,h+="' +\n__e("+n+") +\n'"),a&&(s=!0,h+="';\n"+a+";\n__p += '"),r&&(h+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+e.length,e})),h+="';\n";var g=Mt.call(e,"variable")&&e.variable;if(g){if(ct.test(g))throw new At("Invalid `variable` option passed into `_.template`")}else h="with (obj) {\n"+h+"\n}\n";h=(s?h.replace(j,""):h).replace(U,"$1").replace(V,"$1;"),h="function("+(g||"obj")+") {\n"+(g?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+h+"return __p\n}";var m=Qa((function(){return _t(u,d+"return "+h).apply(o,c)}));if(m.source=h,zs(m))throw m;return m},Fn.times=function(t,e){if((t=pa(t))<1||t>f)return[];var n=p,r=yn(t,p);e=si(e),t-=p;for(var o=qe(r,e);++n<t;)e(n);return o},Fn.toFinite=ha,Fn.toInteger=pa,Fn.toLength=da,Fn.toLower=function(t){return ya(t).toLowerCase()},Fn.toNumber=ga,Fn.toSafeInteger=function(t){return t?ir(pa(t),-9007199254740991,f):0===t?t:0},Fn.toString=ya,Fn.toUpper=function(t){return ya(t).toUpperCase()},Fn.trim=function(t,e,n){if((t=ya(t))&&(n||e===o))return Ke(t);if(!t||!(e=so(e)))return t;var r=fn(t),i=fn(e);return bo(r,Ze(r,i),Xe(r,i)+1).join("")},Fn.trimEnd=function(t,e,n){if((t=ya(t))&&(n||e===o))return t.slice(0,hn(t)+1);if(!t||!(e=so(e)))return t;var r=fn(t);return bo(r,0,Xe(r,fn(e))+1).join("")},Fn.trimStart=function(t,e,n){if((t=ya(t))&&(n||e===o))return t.replace(rt,"");if(!t||!(e=so(e)))return t;var r=fn(t);return bo(r,Ze(r,fn(e))).join("")},Fn.truncate=function(t,e){var n=30,r="...";if(Xs(e)){var i="separator"in e?e.separator:i;n="length"in e?pa(e.length):n,r="omission"in e?so(e.omission):r}var s=(t=ya(t)).length;if(rn(t)){var a=fn(t);s=a.length}if(n>=s)return t;var u=n-ln(r);if(u<1)return r;var c=a?bo(a,0,u).join(""):t.slice(0,u);if(i===o)return c+r;if(a&&(u+=c.length-u),oa(i)){if(t.slice(u).search(i)){var l,f=c;for(i.global||(i=xt(i.source,ya(ht.exec(i))+"g")),i.lastIndex=0;l=i.exec(f);)var h=l.index;c=c.slice(0,h===o?u:h)}}else if(t.indexOf(so(i),u)!=u){var p=c.lastIndexOf(i);p>-1&&(c=c.slice(0,p))}return c+r},Fn.unescape=function(t){return(t=ya(t))&&q.test(t)?t.replace(W,pn):t},Fn.uniqueId=function(t){var e=++$t;return ya(t)+e},Fn.upperCase=Ka,Fn.upperFirst=za,Fn.each=ys,Fn.eachRight=vs,Fn.first=Wi,su(Fn,(mu={},vr(Fn,(function(t,e){Mt.call(Fn.prototype,e)||(mu[e]=t)})),mu),{chain:!1}),Fn.VERSION="4.17.21",xe(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Fn[t].placeholder=Fn})),xe(["drop","take"],(function(t,e){jn.prototype[t]=function(n){n=n===o?1:mn(pa(n),0);var r=this.__filtered__&&!e?new jn(this):this.clone();return r.__filtered__?r.__takeCount__=yn(n,r.__takeCount__):r.__views__.push({size:yn(n,p),type:t+(r.__dir__<0?"Right":"")}),r},jn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),xe(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;jn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:si(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),xe(["head","last"],(function(t,e){var n="take"+(e?"Right":"");jn.prototype[t]=function(){return this[n](1).value()[0]}})),xe(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");jn.prototype[t]=function(){return this.__filtered__?new jn(this):this[n](1)}})),jn.prototype.compact=function(){return this.filter(nu)},jn.prototype.find=function(t){return this.filter(t).head()},jn.prototype.findLast=function(t){return this.reverse().find(t)},jn.prototype.invokeMap=qr((function(t,e){return"function"==typeof t?new jn(this):this.map((function(n){return Pr(n,t,e)}))})),jn.prototype.reject=function(t){return this.filter($s(si(t)))},jn.prototype.slice=function(t,e){t=pa(t);var n=this;return n.__filtered__&&(t>0||e<0)?new jn(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==o&&(n=(e=pa(e))<0?n.dropRight(-e):n.take(e-t)),n)},jn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},jn.prototype.toArray=function(){return this.take(p)},vr(jn.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=Fn[r?"take"+("last"==e?"Right":""):e],s=r||/^find/.test(e);i&&(Fn.prototype[e]=function(){var e=this.__wrapped__,a=r?[1]:arguments,u=e instanceof jn,c=a[0],l=u||Us(e),f=function(t){var e=i.apply(Fn,Le([t],a));return r&&h?e[0]:e};l&&n&&"function"==typeof c&&1!=c.length&&(u=l=!1);var h=this.__chain__,p=!!this.__actions__.length,d=s&&!h,g=u&&!p;if(!s&&l){e=g?e:new jn(this);var m=t.apply(e,a);return m.__actions__.push({func:hs,args:[f],thisArg:o}),new Gn(m,h)}return d&&g?t.apply(this,a):(m=this.thru(f),d?r?m.value()[0]:m.value():m)})})),xe(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Pt[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Fn.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var o=this.value();return e.apply(Us(o)?o:[],t)}return this[n]((function(n){return e.apply(Us(n)?n:[],t)}))}})),vr(jn.prototype,(function(t,e){var n=Fn[e];if(n){var r=n.name+"";Mt.call(On,r)||(On[r]=[]),On[r].push({name:e,func:n})}})),On[Fo(o,2).name]=[{name:"wrapper",func:o}],jn.prototype.clone=function(){var t=new jn(this.__wrapped__);return t.__actions__=Io(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Io(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Io(this.__views__),t},jn.prototype.reverse=function(){if(this.__filtered__){var t=new jn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},jn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Us(t),r=e<0,o=n?t.length:0,i=function(t,e,n){for(var r=-1,o=n.length;++r<o;){var i=n[r],s=i.size;switch(i.type){case"drop":t+=s;break;case"dropRight":e-=s;break;case"take":e=yn(e,t+s);break;case"takeRight":t=mn(t,e-s)}}return{start:t,end:e}}(0,o,this.__views__),s=i.start,a=i.end,u=a-s,c=r?a:s-1,l=this.__iteratees__,f=l.length,h=0,p=yn(u,this.__takeCount__);if(!n||!r&&o==u&&p==u)return fo(t,this.__actions__);var d=[];t:for(;u--&&h<p;){for(var g=-1,m=t[c+=e];++g<f;){var y=l[g],v=y.iteratee,b=y.type,w=v(m);if(2==b)m=w;else if(!w){if(1==b)continue t;break t}}d[h++]=m}return d},Fn.prototype.at=ps,Fn.prototype.chain=function(){return fs(this)},Fn.prototype.commit=function(){return new Gn(this.value(),this.__chain__)},Fn.prototype.next=function(){this.__values__===o&&(this.__values__=fa(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?o:this.__values__[this.__index__++]}},Fn.prototype.plant=function(t){for(var e,n=this;n instanceof Hn;){var r=Fi(n);r.__index__=0,r.__values__=o,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e},Fn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof jn){var e=t;return this.__actions__.length&&(e=new jn(this)),(e=e.reverse()).__actions__.push({func:hs,args:[Xi],thisArg:o}),new Gn(e,this.__chain__)}return this.thru(Xi)},Fn.prototype.toJSON=Fn.prototype.valueOf=Fn.prototype.value=function(){return fo(this.__wrapped__,this.__actions__)},Fn.prototype.first=Fn.prototype.head,zt&&(Fn.prototype[zt]=function(){return this}),Fn}();fe._=dn,(r=function(){return dn}.call(e,n,e,t))===o||(t.exports=r)}.call(this)},802:t=>{t.exports=function t(e,n,r){function o(s,a){if(!n[s]){if(!e[s]){if(i)return i(s,!0);throw new Error("Cannot find module '"+s+"'")}a=n[s]={exports:{}},e[s][0].call(a.exports,(function(t){return o(e[s][1][t]||t)}),a,a.exports,t,e,n,r)}return n[s].exports}for(var i=void 0,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(t,e,n){(function(r,o,i,s,a,u,c,l,f){"use strict";var h=t("crypto");function p(t,e){var n;return void 0===(n="passthrough"!==(e=m(t,e)).algorithm?h.createHash(e.algorithm):new b).write&&(n.write=n.update,n.end=n.update),v(e,n).dispatch(t),n.update||n.end(""),n.digest?n.digest("buffer"===e.encoding?void 0:e.encoding):(t=n.read(),"buffer"!==e.encoding?t.toString(e.encoding):t)}(n=e.exports=p).sha1=function(t){return p(t)},n.keys=function(t){return p(t,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},n.MD5=function(t){return p(t,{algorithm:"md5",encoding:"hex"})},n.keysMD5=function(t){return p(t,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var d=h.getHashes?h.getHashes().slice():["sha1","md5"],g=(d.push("passthrough"),["buffer","hex","binary","base64"]);function m(t,e){var n={};if(n.algorithm=(e=e||{}).algorithm||"sha1",n.encoding=e.encoding||"hex",n.excludeValues=!!e.excludeValues,n.algorithm=n.algorithm.toLowerCase(),n.encoding=n.encoding.toLowerCase(),n.ignoreUnknown=!0===e.ignoreUnknown,n.respectType=!1!==e.respectType,n.respectFunctionNames=!1!==e.respectFunctionNames,n.respectFunctionProperties=!1!==e.respectFunctionProperties,n.unorderedArrays=!0===e.unorderedArrays,n.unorderedSets=!1!==e.unorderedSets,n.unorderedObjects=!1!==e.unorderedObjects,n.replacer=e.replacer||void 0,n.excludeKeys=e.excludeKeys||void 0,void 0===t)throw new Error("Object argument required.");for(var r=0;r<d.length;++r)d[r].toLowerCase()===n.algorithm.toLowerCase()&&(n.algorithm=d[r]);if(-1===d.indexOf(n.algorithm))throw new Error('Algorithm "'+n.algorithm+'" not supported. supported values: '+d.join(", "));if(-1===g.indexOf(n.encoding)&&"passthrough"!==n.algorithm)throw new Error('Encoding "'+n.encoding+'" not supported. supported values: '+g.join(", "));return n}function y(t){if("function"==typeof t)return null!=/^function\s+\w*\s*\(\s*\)\s*{\s+\[native code\]\s+}$/i.exec(Function.prototype.toString.call(t))}function v(t,e,n){function r(t){return e.update?e.update(t,"utf8"):e.write(t,"utf8")}return n=n||[],{dispatch:function(e){return this["_"+(null===(e=t.replacer?t.replacer(e):e)?"null":typeof e)](e)},_object:function(e){var o,s=Object.prototype.toString.call(e),a=/\[object (.*)\]/i.exec(s);if(a=(a=a?a[1]:"unknown:["+s+"]").toLowerCase(),0<=(s=n.indexOf(e)))return this.dispatch("[CIRCULAR:"+s+"]");if(n.push(e),void 0!==i&&i.isBuffer&&i.isBuffer(e))return r("buffer:"),r(e);if("object"===a||"function"===a||"asyncfunction"===a)return s=Object.keys(e),t.unorderedObjects&&(s=s.sort()),!1===t.respectType||y(e)||s.splice(0,0,"prototype","__proto__","constructor"),t.excludeKeys&&(s=s.filter((function(e){return!t.excludeKeys(e)}))),r("object:"+s.length+":"),o=this,s.forEach((function(n){o.dispatch(n),r(":"),t.excludeValues||o.dispatch(e[n]),r(",")}));if(!this["_"+a]){if(t.ignoreUnknown)return r("["+a+"]");throw new Error('Unknown object type "'+a+'"')}this["_"+a](e)},_array:function(e,o){o=void 0!==o?o:!1!==t.unorderedArrays;var i=this;if(r("array:"+e.length+":"),!o||e.length<=1)return e.forEach((function(t){return i.dispatch(t)}));var s=[];return o=e.map((function(e){var r=new b,o=n.slice();return v(t,r,o).dispatch(e),s=s.concat(o.slice(n.length)),r.read().toString()})),n=n.concat(s),o.sort(),this._array(o,!1)},_date:function(t){return r("date:"+t.toJSON())},_symbol:function(t){return r("symbol:"+t.toString())},_error:function(t){return r("error:"+t.toString())},_boolean:function(t){return r("bool:"+t.toString())},_string:function(t){r("string:"+t.length+":"),r(t.toString())},_function:function(e){r("fn:"),y(e)?this.dispatch("[native]"):this.dispatch(e.toString()),!1!==t.respectFunctionNames&&this.dispatch("function-name:"+String(e.name)),t.respectFunctionProperties&&this._object(e)},_number:function(t){return r("number:"+t.toString())},_xml:function(t){return r("xml:"+t.toString())},_null:function(){return r("Null")},_undefined:function(){return r("Undefined")},_regexp:function(t){return r("regex:"+t.toString())},_uint8array:function(t){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint8clampedarray:function(t){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(t))},_int8array:function(t){return r("int8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint16array:function(t){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(t))},_int16array:function(t){return r("int16array:"),this.dispatch(Array.prototype.slice.call(t))},_uint32array:function(t){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(t))},_int32array:function(t){return r("int32array:"),this.dispatch(Array.prototype.slice.call(t))},_float32array:function(t){return r("float32array:"),this.dispatch(Array.prototype.slice.call(t))},_float64array:function(t){return r("float64array:"),this.dispatch(Array.prototype.slice.call(t))},_arraybuffer:function(t){return r("arraybuffer:"),this.dispatch(new Uint8Array(t))},_url:function(t){return r("url:"+t.toString())},_map:function(e){return r("map:"),e=Array.from(e),this._array(e,!1!==t.unorderedSets)},_set:function(e){return r("set:"),e=Array.from(e),this._array(e,!1!==t.unorderedSets)},_file:function(t){return r("file:"),this.dispatch([t.name,t.size,t.type,t.lastModfied])},_blob:function(){if(t.ignoreUnknown)return r("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return r("domwindow")},_bigint:function(t){return r("bigint:"+t.toString())},_process:function(){return r("process")},_timer:function(){return r("timer")},_pipe:function(){return r("pipe")},_tcp:function(){return r("tcp")},_udp:function(){return r("udp")},_tty:function(){return r("tty")},_statwatcher:function(){return r("statwatcher")},_securecontext:function(){return r("securecontext")},_connection:function(){return r("connection")},_zlib:function(){return r("zlib")},_context:function(){return r("context")},_nodescript:function(){return r("nodescript")},_httpparser:function(){return r("httpparser")},_dataview:function(){return r("dataview")},_signal:function(){return r("signal")},_fsevent:function(){return r("fsevent")},_tlswrap:function(){return r("tlswrap")}}}function b(){return{buf:"",write:function(t){this.buf+=t},end:function(t){this.buf+=t},read:function(){return this.buf}}}n.writeToStream=function(t,e,n){return void 0===n&&(n=e,e={}),v(e=m(t,e),n).dispatch(t)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_9a5aa49d.js","/")},{buffer:3,crypto:5,lYpoI2:11}],2:[function(t,e,n){(function(t,e,r,o,i,s,a,u,c){!function(t){"use strict";var e="undefined"!=typeof Uint8Array?Uint8Array:Array,n="+".charCodeAt(0),r="/".charCodeAt(0),o="0".charCodeAt(0),i="a".charCodeAt(0),s="A".charCodeAt(0),a="-".charCodeAt(0),u="_".charCodeAt(0);function c(t){return(t=t.charCodeAt(0))===n||t===a?62:t===r||t===u?63:t<o?-1:t<o+10?t-o+26+26:t<s+26?t-s:t<i+26?t-i+26:void 0}t.toByteArray=function(t){var n,r;if(0<t.length%4)throw new Error("Invalid string. Length must be a multiple of 4");var o=t.length,i=(o="="===t.charAt(o-2)?2:"="===t.charAt(o-1)?1:0,new e(3*t.length/4-o)),s=0<o?t.length-4:t.length,a=0;function u(t){i[a++]=t}for(n=0;n<s;n+=4,0)u((16711680&(r=c(t.charAt(n))<<18|c(t.charAt(n+1))<<12|c(t.charAt(n+2))<<6|c(t.charAt(n+3))))>>16),u((65280&r)>>8),u(255&r);return 2==o?u(255&(r=c(t.charAt(n))<<2|c(t.charAt(n+1))>>4)):1==o&&(u((r=c(t.charAt(n))<<10|c(t.charAt(n+1))<<4|c(t.charAt(n+2))>>2)>>8&255),u(255&r)),i},t.fromByteArray=function(t){var e,n,r,o,i=t.length%3,s="";function a(t){return"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t)}for(e=0,r=t.length-i;e<r;e+=3)s+=a((o=n=(t[e]<<16)+(t[e+1]<<8)+t[e+2])>>18&63)+a(o>>12&63)+a(o>>6&63)+a(63&o);switch(i){case 1:s=(s+=a((n=t[t.length-1])>>2))+a(n<<4&63)+"==";break;case 2:s=(s=(s+=a((n=(t[t.length-2]<<8)+t[t.length-1])>>10))+a(n>>4&63))+a(n<<2&63)+"="}return s}}(void 0===n?this.base64js={}:n)}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:11}],3:[function(t,e,n){(function(e,r,o,i,s,a,u,c,l){var f=t("base64-js"),h=t("ieee754");function o(t,e,n){if(!(this instanceof o))return new o(t,e,n);var r,i,s,a,u=typeof t;if("base64"===e&&"string"==u)for(t=(a=t).trim?a.trim():a.replace(/^\s+|\s+$/g,"");t.length%4!=0;)t+="=";if("number"==u)r=I(t);else if("string"==u)r=o.byteLength(t,e);else{if("object"!=u)throw new Error("First argument needs to be a number, array or string.");r=I(t.length)}if(o._useTypedArrays?i=o._augment(new Uint8Array(r)):((i=this).length=r,i._isBuffer=!0),o._useTypedArrays&&"number"==typeof t.byteLength)i._set(t);else if(P(a=t)||o.isBuffer(a)||a&&"object"==typeof a&&"number"==typeof a.length)for(s=0;s<r;s++)o.isBuffer(t)?i[s]=t.readUInt8(s):i[s]=t[s];else if("string"==u)i.write(t,0,e);else if("number"==u&&!o._useTypedArrays&&!n)for(s=0;s<r;s++)i[s]=0;return i}function p(t,e,n,r){var o;if(r||(R("boolean"==typeof n,"missing or invalid endian"),R(null!=e,"missing offset"),R(e+1<t.length,"Trying to read beyond buffer length")),!((r=t.length)<=e))return n?(o=t[e],e+1<r&&(o|=t[e+1]<<8)):(o=t[e]<<8,e+1<r&&(o|=t[e+1])),o}function d(t,e,n,r){var o;if(r||(R("boolean"==typeof n,"missing or invalid endian"),R(null!=e,"missing offset"),R(e+3<t.length,"Trying to read beyond buffer length")),!((r=t.length)<=e))return n?(e+2<r&&(o=t[e+2]<<16),e+1<r&&(o|=t[e+1]<<8),o|=t[e],e+3<r&&(o+=t[e+3]<<24>>>0)):(e+1<r&&(o=t[e+1]<<16),e+2<r&&(o|=t[e+2]<<8),e+3<r&&(o|=t[e+3]),o+=t[e]<<24>>>0),o}function g(t,e,n,r){if(r||(R("boolean"==typeof n,"missing or invalid endian"),R(null!=e,"missing offset"),R(e+1<t.length,"Trying to read beyond buffer length")),!(t.length<=e))return 32768&(r=p(t,e,n,!0))?-1*(65535-r+1):r}function m(t,e,n,r){if(r||(R("boolean"==typeof n,"missing or invalid endian"),R(null!=e,"missing offset"),R(e+3<t.length,"Trying to read beyond buffer length")),!(t.length<=e))return 2147483648&(r=d(t,e,n,!0))?-1*(4294967295-r+1):r}function y(t,e,n,r){return r||(R("boolean"==typeof n,"missing or invalid endian"),R(e+3<t.length,"Trying to read beyond buffer length")),h.read(t,e,n,23,4)}function v(t,e,n,r){return r||(R("boolean"==typeof n,"missing or invalid endian"),R(e+7<t.length,"Trying to read beyond buffer length")),h.read(t,e,n,52,8)}function b(t,e,n,r,o){if(o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+1<t.length,"trying to write beyond buffer length"),$(e,65535)),!((o=t.length)<=n))for(var i=0,s=Math.min(o-n,2);i<s;i++)t[n+i]=(e&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function w(t,e,n,r,o){if(o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+3<t.length,"trying to write beyond buffer length"),$(e,4294967295)),!((o=t.length)<=n))for(var i=0,s=Math.min(o-n,4);i<s;i++)t[n+i]=e>>>8*(r?i:3-i)&255}function A(t,e,n,r,o){o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+1<t.length,"Trying to write beyond buffer length"),D(e,32767,-32768)),t.length<=n||b(t,0<=e?e:65535+e+1,n,r,o)}function _(t,e,n,r,o){o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+3<t.length,"Trying to write beyond buffer length"),D(e,2147483647,-2147483648)),t.length<=n||w(t,0<=e?e:4294967295+e+1,n,r,o)}function C(t,e,n,r,o){o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+3<t.length,"Trying to write beyond buffer length"),B(e,34028234663852886e22,-34028234663852886e22)),t.length<=n||h.write(t,e,n,r,23,4)}function E(t,e,n,r,o){o||(R(null!=e,"missing value"),R("boolean"==typeof r,"missing or invalid endian"),R(null!=n,"missing offset"),R(n+7<t.length,"Trying to write beyond buffer length"),B(e,17976931348623157e292,-17976931348623157e292)),t.length<=n||h.write(t,e,n,r,52,8)}n.Buffer=o,n.SlowBuffer=o,n.INSPECT_MAX_BYTES=50,o.poolSize=8192,o._useTypedArrays=function(){try{var t=new ArrayBuffer(0),e=new Uint8Array(t);return e.foo=function(){return 42},42===e.foo()&&"function"==typeof e.subarray}catch(t){return!1}}(),o.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.isBuffer=function(t){return!(null==t||!t._isBuffer)},o.byteLength=function(t,e){var n;switch(t+="",e||"utf8"){case"hex":n=t.length/2;break;case"utf8":case"utf-8":n=S(t).length;break;case"ascii":case"binary":case"raw":n=t.length;break;case"base64":n=N(t).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*t.length;break;default:throw new Error("Unknown encoding")}return n},o.concat=function(t,e){if(R(P(t),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===t.length)return new o(0);if(1===t.length)return t[0];if("number"!=typeof e)for(i=e=0;i<t.length;i++)e+=t[i].length;for(var n=new o(e),r=0,i=0;i<t.length;i++){var s=t[i];s.copy(n,r),r+=s.length}return n},o.prototype.write=function(t,e,n,r){isFinite(e)?isFinite(n)||(r=n,n=void 0):(c=r,r=e,e=n,n=c),e=Number(e)||0;var i,s,a,u,c=this.length-e;switch((!n||c<(n=Number(n)))&&(n=c),r=String(r||"utf8").toLowerCase()){case"hex":i=function(t,e,n,r){n=Number(n)||0;var i=t.length-n;(!r||i<(r=Number(r)))&&(r=i),R((i=e.length)%2==0,"Invalid hex string"),i/2<r&&(r=i/2);for(var s=0;s<r;s++){var a=parseInt(e.substr(2*s,2),16);R(!isNaN(a),"Invalid hex string"),t[n+s]=a}return o._charsWritten=2*s,s}(this,t,e,n);break;case"utf8":case"utf-8":s=this,a=e,u=n,i=o._charsWritten=L(S(t),s,a,u);break;case"ascii":case"binary":i=function(t,e,n,r){return o._charsWritten=L(function(t){for(var e=[],n=0;n<t.length;n++)e.push(255&t.charCodeAt(n));return e}(e),t,n,r)}(this,t,e,n);break;case"base64":s=this,a=e,u=n,i=o._charsWritten=L(N(t),s,a,u);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":i=function(t,e,n,r){return o._charsWritten=L(function(t){for(var e,n,r=[],o=0;o<t.length;o++)e=(n=t.charCodeAt(o))>>8,n%=256,r.push(n),r.push(e);return r}(e),t,n,r)}(this,t,e,n);break;default:throw new Error("Unknown encoding")}return i},o.prototype.toString=function(t,e,n){var r,o,i,s,a=this;if(t=String(t||"utf8").toLowerCase(),e=Number(e)||0,(n=void 0!==n?Number(n):a.length)===e)return"";switch(t){case"hex":r=function(t,e,n){var r=t.length;(!e||e<0)&&(e=0),(!n||n<0||r<n)&&(n=r);for(var o="",i=e;i<n;i++)o+=O(t[i]);return o}(a,e,n);break;case"utf8":case"utf-8":r=function(t,e,n){var r="",o="";n=Math.min(t.length,n);for(var i=e;i<n;i++)t[i]<=127?(r+=M(o)+String.fromCharCode(t[i]),o=""):o+="%"+t[i].toString(16);return r+M(o)}(a,e,n);break;case"ascii":case"binary":r=function(t,e,n){var r="";n=Math.min(t.length,n);for(var o=e;o<n;o++)r+=String.fromCharCode(t[o]);return r}(a,e,n);break;case"base64":o=a,s=n,r=0===(i=e)&&s===o.length?f.fromByteArray(o):f.fromByteArray(o.slice(i,s));break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":r=function(t,e,n){for(var r=t.slice(e,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}(a,e,n);break;default:throw new Error("Unknown encoding")}return r},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.copy=function(t,e,n,r){if(e=e||0,(r=r||0===r?r:this.length)!==(n=n||0)&&0!==t.length&&0!==this.length){R(n<=r,"sourceEnd < sourceStart"),R(0<=e&&e<t.length,"targetStart out of bounds"),R(0<=n&&n<this.length,"sourceStart out of bounds"),R(0<=r&&r<=this.length,"sourceEnd out of bounds"),r>this.length&&(r=this.length);var i=(r=t.length-e<r-n?t.length-e+n:r)-n;if(i<100||!o._useTypedArrays)for(var s=0;s<i;s++)t[s+e]=this[s+n];else t._set(this.subarray(n,n+i),e)}},o.prototype.slice=function(t,e){var n=this.length;if(t=T(t,n,0),e=T(e,n,n),o._useTypedArrays)return o._augment(this.subarray(t,e));for(var r=e-t,i=new o(r,void 0,!0),s=0;s<r;s++)i[s]=this[s+t];return i},o.prototype.get=function(t){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(t)},o.prototype.set=function(t,e){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(t,e)},o.prototype.readUInt8=function(t,e){if(e||(R(null!=t,"missing offset"),R(t<this.length,"Trying to read beyond buffer length")),!(t>=this.length))return this[t]},o.prototype.readUInt16LE=function(t,e){return p(this,t,!0,e)},o.prototype.readUInt16BE=function(t,e){return p(this,t,!1,e)},o.prototype.readUInt32LE=function(t,e){return d(this,t,!0,e)},o.prototype.readUInt32BE=function(t,e){return d(this,t,!1,e)},o.prototype.readInt8=function(t,e){if(e||(R(null!=t,"missing offset"),R(t<this.length,"Trying to read beyond buffer length")),!(t>=this.length))return 128&this[t]?-1*(255-this[t]+1):this[t]},o.prototype.readInt16LE=function(t,e){return g(this,t,!0,e)},o.prototype.readInt16BE=function(t,e){return g(this,t,!1,e)},o.prototype.readInt32LE=function(t,e){return m(this,t,!0,e)},o.prototype.readInt32BE=function(t,e){return m(this,t,!1,e)},o.prototype.readFloatLE=function(t,e){return y(this,t,!0,e)},o.prototype.readFloatBE=function(t,e){return y(this,t,!1,e)},o.prototype.readDoubleLE=function(t,e){return v(this,t,!0,e)},o.prototype.readDoubleBE=function(t,e){return v(this,t,!1,e)},o.prototype.writeUInt8=function(t,e,n){n||(R(null!=t,"missing value"),R(null!=e,"missing offset"),R(e<this.length,"trying to write beyond buffer length"),$(t,255)),e>=this.length||(this[e]=t)},o.prototype.writeUInt16LE=function(t,e,n){b(this,t,e,!0,n)},o.prototype.writeUInt16BE=function(t,e,n){b(this,t,e,!1,n)},o.prototype.writeUInt32LE=function(t,e,n){w(this,t,e,!0,n)},o.prototype.writeUInt32BE=function(t,e,n){w(this,t,e,!1,n)},o.prototype.writeInt8=function(t,e,n){n||(R(null!=t,"missing value"),R(null!=e,"missing offset"),R(e<this.length,"Trying to write beyond buffer length"),D(t,127,-128)),e>=this.length||(0<=t?this.writeUInt8(t,e,n):this.writeUInt8(255+t+1,e,n))},o.prototype.writeInt16LE=function(t,e,n){A(this,t,e,!0,n)},o.prototype.writeInt16BE=function(t,e,n){A(this,t,e,!1,n)},o.prototype.writeInt32LE=function(t,e,n){_(this,t,e,!0,n)},o.prototype.writeInt32BE=function(t,e,n){_(this,t,e,!1,n)},o.prototype.writeFloatLE=function(t,e,n){C(this,t,e,!0,n)},o.prototype.writeFloatBE=function(t,e,n){C(this,t,e,!1,n)},o.prototype.writeDoubleLE=function(t,e,n){E(this,t,e,!0,n)},o.prototype.writeDoubleBE=function(t,e,n){E(this,t,e,!1,n)},o.prototype.fill=function(t,e,n){if(e=e||0,n=n||this.length,R("number"==typeof(t="string"==typeof(t=t||0)?t.charCodeAt(0):t)&&!isNaN(t),"value is not a number"),R(e<=n,"end < start"),n!==e&&0!==this.length){R(0<=e&&e<this.length,"start out of bounds"),R(0<=n&&n<=this.length,"end out of bounds");for(var r=e;r<n;r++)this[r]=t}},o.prototype.inspect=function(){for(var t=[],e=this.length,r=0;r<e;r++)if(t[r]=O(this[r]),r===n.INSPECT_MAX_BYTES){t[r+1]="...";break}return"<Buffer "+t.join(" ")+">"},o.prototype.toArrayBuffer=function(){if("undefined"==typeof Uint8Array)throw new Error("Buffer.toArrayBuffer not supported in this browser");if(o._useTypedArrays)return new o(this).buffer;for(var t=new Uint8Array(this.length),e=0,n=t.length;e<n;e+=1)t[e]=this[e];return t.buffer};var x=o.prototype;function T(t,e,n){return"number"!=typeof t?n:e<=(t=~~t)?e:0<=t||0<=(t+=e)?t:0}function I(t){return(t=~~Math.ceil(+t))<0?0:t}function P(t){return(Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)})(t)}function O(t){return t<16?"0"+t.toString(16):t.toString(16)}function S(t){for(var e=[],n=0;n<t.length;n++){var r=t.charCodeAt(n);if(r<=127)e.push(t.charCodeAt(n));else for(var o=n,i=(55296<=r&&r<=57343&&n++,encodeURIComponent(t.slice(o,n+1)).substr(1).split("%")),s=0;s<i.length;s++)e.push(parseInt(i[s],16))}return e}function N(t){return f.toByteArray(t)}function L(t,e,n,r){for(var o=0;o<r&&!(o+n>=e.length||o>=t.length);o++)e[o+n]=t[o];return o}function M(t){try{return decodeURIComponent(t)}catch(t){return String.fromCharCode(65533)}}function $(t,e){R("number"==typeof t,"cannot write a non-number as a number"),R(0<=t,"specified a negative value for writing an unsigned value"),R(t<=e,"value is larger than maximum value for type"),R(Math.floor(t)===t,"value has a fractional component")}function D(t,e,n){R("number"==typeof t,"cannot write a non-number as a number"),R(t<=e,"value larger than maximum allowed value"),R(n<=t,"value smaller than minimum allowed value"),R(Math.floor(t)===t,"value has a fractional component")}function B(t,e,n){R("number"==typeof t,"cannot write a non-number as a number"),R(t<=e,"value larger than maximum allowed value"),R(n<=t,"value smaller than minimum allowed value")}function R(t,e){if(!t)throw new Error(e||"Failed assertion")}o._augment=function(t){return t._isBuffer=!0,t._get=t.get,t._set=t.set,t.get=x.get,t.set=x.set,t.write=x.write,t.toString=x.toString,t.toLocaleString=x.toString,t.toJSON=x.toJSON,t.copy=x.copy,t.slice=x.slice,t.readUInt8=x.readUInt8,t.readUInt16LE=x.readUInt16LE,t.readUInt16BE=x.readUInt16BE,t.readUInt32LE=x.readUInt32LE,t.readUInt32BE=x.readUInt32BE,t.readInt8=x.readInt8,t.readInt16LE=x.readInt16LE,t.readInt16BE=x.readInt16BE,t.readInt32LE=x.readInt32LE,t.readInt32BE=x.readInt32BE,t.readFloatLE=x.readFloatLE,t.readFloatBE=x.readFloatBE,t.readDoubleLE=x.readDoubleLE,t.readDoubleBE=x.readDoubleBE,t.writeUInt8=x.writeUInt8,t.writeUInt16LE=x.writeUInt16LE,t.writeUInt16BE=x.writeUInt16BE,t.writeUInt32LE=x.writeUInt32LE,t.writeUInt32BE=x.writeUInt32BE,t.writeInt8=x.writeInt8,t.writeInt16LE=x.writeInt16LE,t.writeInt16BE=x.writeInt16BE,t.writeInt32LE=x.writeInt32LE,t.writeInt32BE=x.writeInt32BE,t.writeFloatLE=x.writeFloatLE,t.writeFloatBE=x.writeFloatBE,t.writeDoubleLE=x.writeDoubleLE,t.writeDoubleBE=x.writeDoubleBE,t.fill=x.fill,t.inspect=x.inspect,t.toArrayBuffer=x.toArrayBuffer,t}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:10,lYpoI2:11}],4:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){o=t("buffer").Buffer;var f=new o(4);f.fill(0),e.exports={hash:function(t,e,n,r){for(var i=e(function(t,e){t.length%4!=0&&(n=t.length+(4-t.length%4),t=o.concat([t,f],n));for(var n,r=[],i=e?t.readInt32BE:t.readInt32LE,s=0;s<t.length;s+=4)r.push(i.call(t,s));return r}(t=o.isBuffer(t)?t:new o(t),r),8*t.length),s=(e=r,new o(n)),a=e?s.writeInt32BE:s.writeInt32LE,u=0;u<i.length;u++)a.call(s,i[u],4*u,!0);return s}}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/helpers.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:11}],5:[function(t,e,n){(function(e,r,o,i,s,a,u,c,l){o=t("buffer").Buffer;var f=t("./sha"),h=t("./sha256"),p=t("./rng"),d={sha1:f,sha256:h,md5:t("./md5")},g=64,m=new o(g);function y(t,e){var n=d[t=t||"sha1"],r=[];return n||v("algorithm:",t,"is not yet supported"),{update:function(t){return o.isBuffer(t)||(t=new o(t)),r.push(t),t.length,this},digest:function(t){var i=o.concat(r);return i=e?function(t,e,n){o.isBuffer(e)||(e=new o(e)),o.isBuffer(n)||(n=new o(n)),e.length>g?e=t(e):e.length<g&&(e=o.concat([e,m],g));for(var r=new o(g),i=new o(g),s=0;s<g;s++)r[s]=54^e[s],i[s]=92^e[s];return n=t(o.concat([r,n])),t(o.concat([i,n]))}(n,e,i):n(i),r=null,t?i.toString(t):i}}}function v(){var t=[].slice.call(arguments).join(" ");throw new Error([t,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}m.fill(0),n.createHash=function(t){return y(t)},n.createHmac=y,n.randomBytes=function(t,e){if(!e||!e.call)return new o(p(t));try{e.call(this,void 0,new o(p(t)))}catch(t){e(t)}};var b,w=["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],A=function(t){n[t]=function(){v("sorry,",t,"is not implemented yet")}};for(b in w)A(w[b])}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/index.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./md5":6,"./rng":7,"./sha":8,"./sha256":9,buffer:3,lYpoI2:11}],6:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){var f=t("./helpers");function h(t,e){t[e>>5]|=128<<e%32,t[14+(e+64>>>9<<4)]=e;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,s=0;s<t.length;s+=16){var a=n,u=r,c=o,l=i;n=d(n,r,o,i,t[s+0],7,-680876936),i=d(i,n,r,o,t[s+1],12,-389564586),o=d(o,i,n,r,t[s+2],17,606105819),r=d(r,o,i,n,t[s+3],22,-1044525330),n=d(n,r,o,i,t[s+4],7,-176418897),i=d(i,n,r,o,t[s+5],12,1200080426),o=d(o,i,n,r,t[s+6],17,-1473231341),r=d(r,o,i,n,t[s+7],22,-45705983),n=d(n,r,o,i,t[s+8],7,1770035416),i=d(i,n,r,o,t[s+9],12,-1958414417),o=d(o,i,n,r,t[s+10],17,-42063),r=d(r,o,i,n,t[s+11],22,-1990404162),n=d(n,r,o,i,t[s+12],7,1804603682),i=d(i,n,r,o,t[s+13],12,-40341101),o=d(o,i,n,r,t[s+14],17,-1502002290),n=g(n,r=d(r,o,i,n,t[s+15],22,1236535329),o,i,t[s+1],5,-165796510),i=g(i,n,r,o,t[s+6],9,-1069501632),o=g(o,i,n,r,t[s+11],14,643717713),r=g(r,o,i,n,t[s+0],20,-373897302),n=g(n,r,o,i,t[s+5],5,-701558691),i=g(i,n,r,o,t[s+10],9,38016083),o=g(o,i,n,r,t[s+15],14,-660478335),r=g(r,o,i,n,t[s+4],20,-405537848),n=g(n,r,o,i,t[s+9],5,568446438),i=g(i,n,r,o,t[s+14],9,-1019803690),o=g(o,i,n,r,t[s+3],14,-187363961),r=g(r,o,i,n,t[s+8],20,1163531501),n=g(n,r,o,i,t[s+13],5,-1444681467),i=g(i,n,r,o,t[s+2],9,-51403784),o=g(o,i,n,r,t[s+7],14,1735328473),n=m(n,r=g(r,o,i,n,t[s+12],20,-1926607734),o,i,t[s+5],4,-378558),i=m(i,n,r,o,t[s+8],11,-2022574463),o=m(o,i,n,r,t[s+11],16,1839030562),r=m(r,o,i,n,t[s+14],23,-35309556),n=m(n,r,o,i,t[s+1],4,-1530992060),i=m(i,n,r,o,t[s+4],11,1272893353),o=m(o,i,n,r,t[s+7],16,-155497632),r=m(r,o,i,n,t[s+10],23,-1094730640),n=m(n,r,o,i,t[s+13],4,681279174),i=m(i,n,r,o,t[s+0],11,-358537222),o=m(o,i,n,r,t[s+3],16,-722521979),r=m(r,o,i,n,t[s+6],23,76029189),n=m(n,r,o,i,t[s+9],4,-640364487),i=m(i,n,r,o,t[s+12],11,-421815835),o=m(o,i,n,r,t[s+15],16,530742520),n=y(n,r=m(r,o,i,n,t[s+2],23,-995338651),o,i,t[s+0],6,-198630844),i=y(i,n,r,o,t[s+7],10,1126891415),o=y(o,i,n,r,t[s+14],15,-1416354905),r=y(r,o,i,n,t[s+5],21,-57434055),n=y(n,r,o,i,t[s+12],6,1700485571),i=y(i,n,r,o,t[s+3],10,-1894986606),o=y(o,i,n,r,t[s+10],15,-1051523),r=y(r,o,i,n,t[s+1],21,-2054922799),n=y(n,r,o,i,t[s+8],6,1873313359),i=y(i,n,r,o,t[s+15],10,-30611744),o=y(o,i,n,r,t[s+6],15,-1560198380),r=y(r,o,i,n,t[s+13],21,1309151649),n=y(n,r,o,i,t[s+4],6,-145523070),i=y(i,n,r,o,t[s+11],10,-1120210379),o=y(o,i,n,r,t[s+2],15,718787259),r=y(r,o,i,n,t[s+9],21,-343485551),n=v(n,a),r=v(r,u),o=v(o,c),i=v(i,l)}return Array(n,r,o,i)}function p(t,e,n,r,o,i){return v((e=v(v(e,t),v(r,i)))<<o|e>>>32-o,n)}function d(t,e,n,r,o,i,s){return p(e&n|~e&r,t,e,o,i,s)}function g(t,e,n,r,o,i,s){return p(e&r|n&~r,t,e,o,i,s)}function m(t,e,n,r,o,i,s){return p(e^n^r,t,e,o,i,s)}function y(t,e,n,r,o,i,s){return p(n^(e|~r),t,e,o,i,s)}function v(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}e.exports=function(t){return f.hash(t,h,16)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],7:[function(t,e,n){(function(t,n,r,o,i,s,a,u,c){e.exports=function(t){for(var e,n=new Array(t),r=0;r<t;r++)!(3&r)&&(e=4294967296*Math.random()),n[r]=e>>>((3&r)<<3)&255;return n}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:11}],8:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){var f=t("./helpers");function h(t,e){t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var n,r,o,i=Array(80),s=1732584193,a=-271733879,u=-1732584194,c=271733878,l=-1009589776,f=0;f<t.length;f+=16){for(var h=s,g=a,m=u,y=c,v=l,b=0;b<80;b++){i[b]=b<16?t[f+b]:d(i[b-3]^i[b-8]^i[b-14]^i[b-16],1);var w=p(p(d(s,5),(w=a,r=u,o=c,(n=b)<20?w&r|~w&o:!(n<40)&&n<60?w&r|w&o|r&o:w^r^o)),p(p(l,i[b]),(n=b)<20?1518500249:n<40?1859775393:n<60?-1894007588:-899497514));l=c,c=u,u=d(a,30),a=s,s=w}s=p(s,h),a=p(a,g),u=p(u,m),c=p(c,y),l=p(l,v)}return Array(s,a,u,c,l)}function p(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}function d(t,e){return t<<e|t>>>32-e}e.exports=function(t){return f.hash(t,h,20,!0)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],9:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){function f(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}function h(t,e){var n,r=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),o=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),i=new Array(64);t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var s,a,u=0;u<t.length;u+=16){for(var c=o[0],l=o[1],h=o[2],p=o[3],m=o[4],y=o[5],v=o[6],b=o[7],w=0;w<64;w++)i[w]=w<16?t[w+u]:f(f(f((a=i[w-2],d(a,17)^d(a,19)^g(a,10)),i[w-7]),(a=i[w-15],d(a,7)^d(a,18)^g(a,3))),i[w-16]),n=f(f(f(f(b,d(a=m,6)^d(a,11)^d(a,25)),m&y^~m&v),r[w]),i[w]),s=f(d(s=c,2)^d(s,13)^d(s,22),c&l^c&h^l&h),b=v,v=y,y=m,m=f(p,n),p=h,h=l,l=c,c=f(n,s);o[0]=f(c,o[0]),o[1]=f(l,o[1]),o[2]=f(h,o[2]),o[3]=f(p,o[3]),o[4]=f(m,o[4]),o[5]=f(y,o[5]),o[6]=f(v,o[6]),o[7]=f(b,o[7])}return o}var p=t("./helpers"),d=function(t,e){return t>>>e|t<<32-e},g=function(t,e){return t>>>e};e.exports=function(t){return p.hash(t,h,32,!0)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],10:[function(t,e,n){(function(t,e,r,o,i,s,a,u,c){n.read=function(t,e,n,r,o){var i,s,a=8*o-r-1,u=(1<<a)-1,c=u>>1,l=-7,f=n?o-1:0,h=n?-1:1;for(o=t[e+f],f+=h,i=o&(1<<-l)-1,o>>=-l,l+=a;0<l;i=256*i+t[e+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=r;0<l;s=256*s+t[e+f],f+=h,l-=8);if(0===i)i=1-c;else{if(i===u)return s?NaN:1/0*(o?-1:1);s+=Math.pow(2,r),i-=c}return(o?-1:1)*s*Math.pow(2,i-r)},n.write=function(t,e,n,r,o,i){var s,a,u=8*i-o-1,c=(1<<u)-1,l=c>>1,f=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:i-1,p=r?1:-1;for(i=e<0||0===e&&1/e<0?1:0,e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(r=Math.pow(2,-s))<1&&(s--,r*=2),2<=(e+=1<=s+l?f/r:f*Math.pow(2,1-l))*r&&(s++,r/=2),c<=s+l?(a=0,s=c):1<=s+l?(a=(e*r-1)*Math.pow(2,o),s+=l):(a=e*Math.pow(2,l-1)*Math.pow(2,o),s=0));8<=o;t[n+h]=255&a,h+=p,a/=256,o-=8);for(s=s<<o|a,u+=o;0<u;t[n+h]=255&s,h+=p,s/=256,u-=8);t[n+h-p]|=128*i}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/ieee754/index.js","/node_modules/gulp-browserify/node_modules/ieee754")},{buffer:3,lYpoI2:11}],11:[function(t,e,n){(function(t,n,r,o,i,s,a,u,c){var l,f,h;function p(){}(t=e.exports={}).nextTick=(f="undefined"!=typeof window&&window.setImmediate,h="undefined"!=typeof window&&window.postMessage&&window.addEventListener,f?function(t){return window.setImmediate(t)}:h?(l=[],window.addEventListener("message",(function(t){var e=t.source;e!==window&&null!==e||"process-tick"!==t.data||(t.stopPropagation(),0<l.length&&l.shift()())}),!0),function(t){l.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}),t.title="browser",t.browser=!0,t.env={},t.argv=[],t.on=p,t.addListener=p,t.once=p,t.off=p,t.removeListener=p,t.removeAllListeners=p,t.emit=p,t.binding=function(t){throw new Error("process.binding is not supported")},t.cwd=function(){return"/"},t.chdir=function(t){throw new Error("process.chdir is not supported")}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:11}]},{},[1])(1)},146:(t,e)=>{"use strict";var n;!function(){var r=e||{}||this||window;void 0===(n=function(){return r}.apply(e,[]))||(t.exports=n),r.default=r;var o="http://www.w3.org/2000/xmlns/",i="http://www.w3.org/2000/svg",s=/url\(["']?(.+?)["']?\)/,a={woff2:"font/woff2",woff:"font/woff",otf:"application/x-font-opentype",ttf:"application/x-font-ttf",eot:"application/vnd.ms-fontobject",sfnt:"application/font-sfnt",svg:"image/svg+xml"},u=function(t){return t instanceof HTMLElement||t instanceof SVGElement},c=function(t){if(!u(t))throw new Error("an HTMLElement or SVGElement is required; got "+t)},l=function(t){return new Promise((function(e,n){u(t)?e(t):n(new Error("an HTMLElement or SVGElement is required; got "+t))}))},f=function(t,e,n){var r=t.viewBox&&t.viewBox.baseVal&&t.viewBox.baseVal[n]||null!==e.getAttribute(n)&&!e.getAttribute(n).match(/%$/)&&parseInt(e.getAttribute(n))||t.getBoundingClientRect()[n]||parseInt(e.style[n])||parseInt(window.getComputedStyle(t).getPropertyValue(n));return null==r||isNaN(parseFloat(r))?0:r},h=function(t){for(var e=window.atob(t.split(",")[1]),n=t.split(",")[0].split(":")[1].split(";")[0],r=new ArrayBuffer(e.length),o=new Uint8Array(r),i=0;i<e.length;i++)o[i]=e.charCodeAt(i);return new Blob([r],{type:n})},p={},d=null,g=function(t,e){var n=e||{},r=n.selectorRemap,o=n.modifyStyle,i=n.modifyCss,u=n.fonts,c=n.excludeUnusedCss,l=i||function(t,e){return(r?r(t):t)+"{"+(o?o(e):e)+"}\n"},f=[],h=void 0===u,g=u||[];return(d||(d=Array.from(document.styleSheets).map((function(t){try{return{rules:t.cssRules,href:t.href}}catch(e){return console.warn("Stylesheet could not be loaded: "+t.href,e),{}}})))).forEach((function(e){var n=e.rules,r=e.href;n&&Array.from(n).forEach((function(e){if(void 0!==e.style)if(function(t,e){if(e)try{return t.querySelector(e)||t.parentNode&&t.parentNode.querySelector(e)}catch(t){console.warn('Invalid CSS selector "'+e+'"',t)}}(t,e.selectorText))f.push(l(e.selectorText,e.style.cssText));else if(h&&e.cssText.match(/^@font-face/)){var n=function(t,e){var n=t.cssText.match(s),r=n&&n[1]||"";if(r&&!r.match(/^data:/)&&"about:blank"!==r){var o,i,u=r.startsWith("../")?e+"/../"+r:r.startsWith("./")?e+"/."+r:r;return{text:t.cssText,format:(o=u,i=Object.keys(a).filter((function(t){return o.indexOf("."+t)>0})).map((function(t){return a[t]})),i?i[0]:(console.error("Unknown font format for "+o+". Fonts may not be working correctly."),"application/octet-stream")),url:u}}}(e,r);n&&g.push(n)}else c||f.push(e.cssText)}))})),function(t){return Promise.all(t.map((function(t){return new Promise((function(e,n){if(p[t.url])return e(p[t.url]);var r=new XMLHttpRequest;r.addEventListener("load",(function(){var n=function(t){for(var e="",n=new Uint8Array(t),r=0;r<n.byteLength;r++)e+=String.fromCharCode(n[r]);return window.btoa(e)}(r.response),o=t.text.replace(s,'url("data:'+t.format+";base64,"+n+'")')+"\n";p[t.url]=o,e(o)})),r.addEventListener("error",(function(n){console.warn("Failed to load font from: "+t.url,n),p[t.url]=null,e(null)})),r.addEventListener("abort",(function(n){console.warn("Aborted loading font from: "+t.url,n),e(null)})),r.open("GET",t.url),r.responseType="arraybuffer",r.send()}))}))).then((function(t){return t.filter((function(t){return t})).join("")}))}(g).then((function(t){return f.join("\n")+t}))},m=function(){if(!navigator.msSaveOrOpenBlob&&!("download"in document.createElement("a")))return{popup:window.open()}};r.prepareSvg=function(t,e,n){c(t);var r=e||{},s=r.left,a=void 0===s?0:s,u=r.top,l=void 0===u?0:u,h=r.width,p=r.height,d=r.scale,m=void 0===d?1:d,y=r.responsive,v=void 0!==y&&y,b=r.excludeCss,w=void 0!==b&&b;return function(t){return Promise.all(Array.from(t.querySelectorAll("image")).map((function(t){var e,n=t.getAttributeNS("http://www.w3.org/1999/xlink","href")||t.getAttribute("href");return n?((e=n)&&0===e.lastIndexOf("http",0)&&-1===e.lastIndexOf(window.location.host)&&(n+=(-1===n.indexOf("?")?"?":"&")+"t="+(new Date).valueOf()),new Promise((function(e,r){var o=document.createElement("canvas"),i=new Image;i.crossOrigin="anonymous",i.src=n,i.onerror=function(){return r(new Error("Could not load "+n))},i.onload=function(){o.width=i.width,o.height=i.height,o.getContext("2d").drawImage(i,0,0),t.setAttributeNS("http://www.w3.org/1999/xlink","href",o.toDataURL("image/png")),e(!0)}}))):Promise.resolve(null)})))}(t).then((function(){var r=t.cloneNode(!0);r.style.backgroundColor=(e||{}).backgroundColor||t.style.backgroundColor;var s=function(t,e,n,r){if("svg"===t.tagName)return{width:n||f(t,e,"width"),height:r||f(t,e,"height")};if(t.getBBox){var o=t.getBBox(),i=o.x,s=o.y;return{width:i+o.width,height:s+o.height}}}(t,r,h,p),u=s.width,c=s.height;if("svg"!==t.tagName){if(!t.getBBox)return void console.error("Attempted to render non-SVG element",t);null!=r.getAttribute("transform")&&r.setAttribute("transform",r.getAttribute("transform").replace(/translate\(.*?\)/,""));var d=document.createElementNS("http://www.w3.org/2000/svg","svg");d.appendChild(r),r=d}if(r.setAttribute("version","1.1"),r.setAttribute("viewBox",[a,l,u,c].join(" ")),r.getAttribute("xmlns")||r.setAttributeNS(o,"xmlns",i),r.getAttribute("xmlns:xlink")||r.setAttributeNS(o,"xmlns:xlink","http://www.w3.org/1999/xlink"),v?(r.removeAttribute("width"),r.removeAttribute("height"),r.setAttribute("preserveAspectRatio","xMinYMin meet")):(r.setAttribute("width",u*m),r.setAttribute("height",c*m)),Array.from(r.querySelectorAll("foreignObject > *")).forEach((function(t){t.setAttributeNS(o,"xmlns","svg"===t.tagName?i:"http://www.w3.org/1999/xhtml")})),!w)return g(t,e).then((function(t){var e=document.createElement("style");e.setAttribute("type","text/css"),e.innerHTML="<![CDATA[\n"+t+"\n]]>";var o=document.createElement("defs");o.appendChild(e),r.insertBefore(o,r.firstChild);var i=document.createElement("div");i.appendChild(r);var s=i.innerHTML.replace(/NS\d+:href/gi,'xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href');if("function"!=typeof n)return{src:s,width:u,height:c};n(s,u,c)}));var y=document.createElement("div");y.appendChild(r);var b=y.innerHTML;if("function"!=typeof n)return{src:b,width:u,height:c};n(b,u,c)}))},r.svgAsDataUri=function(t,e,n){return c(t),r.prepareSvg(t,e).then((function(t){var e=t.src,r=t.width,o=t.height,i="data:image/svg+xml;base64,"+window.btoa(decodeURIComponent(encodeURIComponent('<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [<!ENTITY nbsp " ">]>'+e).replace(/%([0-9A-F]{2})/g,(function(t,e){var n=String.fromCharCode("0x"+e);return"%"===n?"%25":n}))));return"function"==typeof n&&n(i,r,o),i}))},r.svgAsPngUri=function(t,e,n){c(t);var o=e||{},i=o.encoderType,s=void 0===i?"image/png":i,a=o.encoderOptions,u=void 0===a?.8:a,l=o.canvg,f=function(t){var e=t.src,r=t.width,o=t.height,i=document.createElement("canvas"),a=i.getContext("2d"),c=window.devicePixelRatio||1;i.width=r*c,i.height=o*c,i.style.width=i.width+"px",i.style.height=i.height+"px",a.setTransform(c,0,0,c,0,0),l?l(i,e):a.drawImage(e,0,0);var f=void 0;try{f=i.toDataURL(s,u)}catch(t){if("undefined"!=typeof SecurityError&&t instanceof SecurityError||"SecurityError"===t.name)return void console.error("Rendered SVG images cannot be downloaded in this browser.");throw t}return"function"==typeof n&&n(f,i.width,i.height),Promise.resolve(f)};return l?r.prepareSvg(t,e).then(f):r.svgAsDataUri(t,e).then((function(t){return new Promise((function(e,n){var r=new Image;r.onload=function(){return e(f({src:r,width:r.width,height:r.height}))},r.onerror=function(){n("There was an error loading the data URI as an image on the following SVG\n"+window.atob(t.slice(26))+"Open the following link to see browser's diagnosis\n"+t)},r.src=t}))}))},r.download=function(t,e,n){if(navigator.msSaveOrOpenBlob)navigator.msSaveOrOpenBlob(h(e),t);else{var r=document.createElement("a");if("download"in r){r.download=t,r.style.display="none",document.body.appendChild(r);try{var o=h(e),i=URL.createObjectURL(o);r.href=i,r.onclick=function(){return requestAnimationFrame((function(){return URL.revokeObjectURL(i)}))}}catch(t){console.error(t),console.warn("Error while getting object URL. Falling back to string URL."),r.href=e}r.click(),document.body.removeChild(r)}else n&&n.popup&&(n.popup.document.title=t,n.popup.location.replace(e))}},r.saveSvg=function(t,e,n){var o=m();return l(t).then((function(t){return r.svgAsDataUri(t,n||{})})).then((function(t){return r.download(e,t,o)}))},r.saveSvgAsPng=function(t,e,n){var o=m();return l(t).then((function(t){return r.svgAsPngUri(t,n||{})})).then((function(t){return r.download(e,t,o)}))}}()},72:t=>{"use strict";var e=[];function n(t){for(var n=-1,r=0;r<e.length;r++)if(e[r].identifier===t){n=r;break}return n}function r(t,r){for(var i={},s=[],a=0;a<t.length;a++){var u=t[a],c=r.base?u[0]+r.base:u[0],l=i[c]||0,f="".concat(c," ").concat(l);i[c]=l+1;var h=n(f),p={css:u[1],media:u[2],sourceMap:u[3],supports:u[4],layer:u[5]};if(-1!==h)e[h].references++,e[h].updater(p);else{var d=o(p,r);r.byIndex=a,e.splice(a,0,{identifier:f,updater:d,references:1})}s.push(f)}return s}function o(t,e){var n=e.domAPI(e);return n.update(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;n.update(t=e)}else n.remove()}}t.exports=function(t,o){var i=r(t=t||[],o=o||{});return function(t){t=t||[];for(var s=0;s<i.length;s++){var a=n(i[s]);e[a].references--}for(var u=r(t,o),c=0;c<i.length;c++){var l=n(i[c]);0===e[l].references&&(e[l].updater(),e.splice(l,1))}i=u}}},659:t=>{"use strict";var e={};t.exports=function(t,n){var r=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},540:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},56:(t,e,n)=>{"use strict";t.exports=function(t){var e=n.nc;e&&t.setAttribute("nonce",e)}},825:t=>{"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(n){!function(t,e,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),e.styleTagTransform(r,t,e.options)}(e,t,n)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},113:t=>{"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},686:(t,e,n)=>{"use strict";n.d(e,{AL:()=>r,NO:()=>o});const r=["A","G","C","U"];var o;!function(t){t.HELM="HELM",t.AXOLABS="Axolabs"}(o||(o={}))},670:(t,e,n)=>{"use strict";function r(t,e=!0){let n="\n Datagrok macromolecule handler\n\n";n+=" 0 0 0 0 0 0 999 V3000\n",n+="M V30 BEGIN CTAB\n";let r="",a="",u="";const c=[];let l=0,f=0,h=0;if(t.antiStrands.length>0)for(let e=0;e<t.antiStrands.length;e++)t.antiStrands[e]=o(t.antiStrands[e]);let p=!1;const d=t.senseStrands.concat(t.antiStrands);let g=0;for(let e=0;e<d.length;e++){d[e]=d[e].replaceAll("(-\nM V30 ","(").replaceAll("-\nM V30 ","").replaceAll(" )",")");const n=i(d[e]),o=s(d[e]);if(e>=t.senseStrands.length?!1===p&&(p=!0,h=0):g=Math.min(g,Math.min(...o.y.filter((t=>t<0)))),p){const t=Math.min(...o.x)-h,e=Math.max(...o.y)+5;for(let e=0;e<o.x.length;e++)o.x[e]-=t;for(let t=0;t<o.y.length;t++)o.y[t]-=e-g}let u=d[e].indexOf("M V30 BEGIN ATOM");u=d[e].indexOf("\n",u);let m=u,y=u;for(let t=0;t<n.natom;t++){m=d[e].indexOf("V30",m)+4,y=d[e].indexOf(" ",m);const n=parseInt(d[e].substring(m,y))+l;d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf(" ",m)+1,m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m);let r=Math.round(1e4*o.x[t])/1e4;d[e]=d[e].slice(0,m)+r+d[e].slice(y),m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m),r=Math.round(1e4*o.y[t])/1e4,d[e]=d[e].slice(0,m)+r+d[e].slice(y),m=d[e].indexOf("\n",m)+1}const v=d[e].indexOf("M V30 END ATOM");r+=d[e].substring(u+1,v);let b=d[e].indexOf("M V30 BEGIN BOND");b=d[e].indexOf("\n",b),m=b,y=b;for(let t=0;t<n.nbond;t++){m=d[e].indexOf("V30",m)+4,y=d[e].indexOf(" ",m);const t=parseInt(d[e].substring(m,y))+f;d[e]=d[e].slice(0,m)+t+d[e].slice(y),m=d[e].indexOf(" ",m)+1,m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m);let n=parseInt(d[e].substring(m,y))+l;d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf(" ",m)+1,y=Math.min(d[e].indexOf("\n",m),d[e].indexOf(" ",m)),n=parseInt(d[e].substring(m,y))+l,d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf("\n",m)+1}const w=d[e].indexOf("M V30 END BOND");a+=d[e].substring(b+1,w);let A=d[e].indexOf("M V30 MDLV30/STEABS ATOMS=(");for(;-1!==A;){A+=28;const t=d[e].indexOf(")",A);d[e].substring(A,t).split(" ").slice(1).forEach((t=>{c.push(parseInt(t)+l)})),A=t,A=d[e].indexOf("M V30 MDLV30/STEABS ATOMS=(",A)}l+=n.natom,f+=n.nbond,h+=Math.max(...o.x)+5}const m=Math.ceil(c.length/4);u+="M V30 MDLV30/STEABS ATOMS=("+c.length+" -\n";for(let t=0;t<m;t++){u+="M V30 ";const e=t+1===m?c.length-4*(m-1):4;for(let n=0;n<e;n++)u+=n+1===e?t===m-1?c[4*t+n]+")\n":c[4*t+n]+" -\n":c[4*t+n]+" "}return n+="M V30 COUNTS "+l+" "+f+" 0 0 0\n",n+="M V30 BEGIN ATOM\n",n+=r,n+="M V30 END ATOM\n",n+="M V30 BEGIN BOND\n",n+=a,n+="M V30 END BOND\n",e&&c.length>0?(n+="M V30 BEGIN COLLECTION\n",n+=u,n+="M V30 END COLLECTION\n"):n=n.replace(/ CFG=\d/g," "),n+="M V30 END CTAB\n",n+="M END",n}function o(t){const e=s(t),n=e.atomIndex.length,r=(Math.max(...e.x)+Math.min(...e.x))/2,o=(Math.max(...e.y)+Math.min(...e.y))/2;for(let t=0;t<n;t++)e.x[t]-=r,e.y[t]-=o;const i=Math.PI,a=Math.cos(i),u=Math.sin(i);for(let t=0;t<n;t++){const n=e.x[t];e.x[t]=n*a-e.y[t]*u,e.y[t]=n*u+e.y[t]*a}const c=Math.max(...e.y);for(let t=0;t<n;t++)e.x[t]+=r,e.y[t]-=c;let l=t.indexOf("M V30 BEGIN ATOM");l=t.indexOf("\n",l);let f=l;for(let r=0;r<n;r++)l=t.indexOf("V30",l)+4,l=t.indexOf(" ",l)+1,l=t.indexOf(" ",l)+1,f=t.indexOf(" ",l)+1,f=t.indexOf(" ",f),l=(t=t.slice(0,l)+e.x[r]+" "+e.y[r]+t.slice(f)).indexOf("\n",l)+1;return t}function i(t){let e=(t=t.replaceAll("\r","")).indexOf("COUNTS")+7,n=t.indexOf(" ",e);const r=parseInt(t.substring(e,n));return e=n+1,n=t.indexOf(" ",e),{natom:r,nbond:parseInt(t.substring(e,n))}}function s(t){const e=i(t);let n=t.indexOf("M V30 BEGIN ATOM");n=t.indexOf("\n",n);let r=n;const o=Array(e.natom),s=Array(e.natom),a=Array(e.natom),u=Array(e.natom);for(let i=0;i<e.natom;i++)n=t.indexOf("V30",n)+4,r=t.indexOf(" ",n),o[i]=parseInt(t.substring(n,r)),n=r+1,r=t.indexOf(" ",n),s[i]=t.substring(n,r),n=r+1,r=t.indexOf(" ",n),a[i]=parseFloat(t.substring(n,r)),n=r+1,r=t.indexOf(" ",n),u[i]=parseFloat(t.substring(n,r)),n=t.indexOf("\n",n)+1;return{atomIndex:o,atomType:s,x:a,y:u}}n.d(e,{cx:()=>s,vS:()=>r})},537:(t,e,n)=>{"use strict";n.d(e,{iL:()=>i,q7:()=>o,ti:()=>r});const r={NUCLEOSIDE:"nucleoside",LINKAGE:"phosphateBackbone"},o="p",i="<?>"},480:(t,e,n)=>{"use strict";n.d(e,{C6:()=>u,Hs:()=>a,OT:()=>c,bD:()=>s});var r=n(686),o=n(67),i=n(537);function s(t,e,n,o){const i=Object.keys(o.jsonData.codesToHelmDict).concat([r.NO.HELM]);if(!t||-1!==e&&n!==r.NO.HELM)return{};if(!i.includes(n))throw new Error(`${n} format is not supported by SequenceTranslator`);const s=i.filter((t=>t!=n)).sort(((t,e)=>t.localeCompare(e))),u=o.createFormatConverter(t,n),c=Object.fromEntries(s.map((t=>{let e;try{e=u.convertTo(t)}catch{e=null}return[t,e]})).filter((([t,e])=>e))),l=a(n===r.NO.HELM?t:c[r.NO.HELM],o.monomerLibWrapper);return l&&(c.Nucleotides=l),c}function a(t,e){const n=new RegExp("\\([^()]*\\)","g"),o=t.match(n);return o?o.map((t=>{const n=t.replace(/[\[\]()]/g,"");return r.AL.includes(n)?n:e.getNaturalAnalogBySymbol(n)})).map((t=>t||i.iL)).join(""):null}function u(t,e,n,i){const s=i.createFormatConverter(t,e);return n===o.qP?a(s.convertTo(r.NO.HELM),i.monomerLibWrapper):s.convertTo(n)}function c(t){return Object.keys(t.jsonData.codesToHelmDict).concat([r.NO.HELM,o.qP]).sort()}},67:(t,e,n)=>{"use strict";n.d(e,{U_:()=>o,n_:()=>r,qP:()=>i});const r="Copied",o="Copy sequence",i="Nucleotides"},544:(t,e,n)=>{"use strict";n.d(e,{_package:()=>It});var r=n(328),o=n(82);n(439),new class{constructor(){this.seqHandler="seq-handler",this.notationProvider="seq-handler.notation-provider"}};var i=n(890);class s{constructor(t,e,n=""){this.target=t,this.debugEnabled=e,this.prefix=n}error(t,e,n){return this.target.error(this.prefix+t,e,n)}warning(t,e){return this.target.warning(this.prefix+t,e)}info(t,e){return this.target.info(this.prefix+t,e)}debug(t,e){if(this.debugEnabled)return this.target.debug(this.prefix+t,e)}}const a="System:AppData/SequenceTranslator/monomers-sample",u="pattern-app-data.json",c="formats-to-helm.json",l="codes-to-symbols.json",f="linkers.json";var h=n(686);function p(t){return t.sort(((t,e)=>e.length-t.length))}class d{constructor(t,e){this.sequence=t,this.th=e,this.libWrapper=this.th.monomerLibWrapper}getInvalidCodeIndex(t){if(t===h.NO.HELM)return this.sequence.length;const e=["r","d"],n=p(this.libWrapper.getCodesByFormat(t));let r=0;for(;r<this.sequence.length;){const t=n.find((t=>t===this.sequence.substring(r,r+t.length)));if(!t)break;if(r>1&&h.AL.includes(this.sequence[r])&&e.includes(this.sequence[r-2]))break;if(e.includes(this.sequence[r+1])&&h.AL.includes(this.sequence[r])){r++;break}r+=t.length}return r===this.sequence.length&&(r=-1),r}isValidSequence(t){return-1===this.getInvalidCodeIndex(t)}}class g{constructor(t,e,n,r){this.patternAppData=t,this.codesToHelmDict=e,this.codesToSymbolsDict=n,this.monomersWithPhosphate=r}}async function m(t){const e=await Promise.all([u,c,l,f].map((e=>async function(t,e){const n=t.endsWith("/")?`${t}${e}`:`${t}/${e}`;try{const t=await r.dapi.files.readAsText(n);return JSON.parse(t)}catch(t){console.error(`Error loading json from '${n}':`,t)}}(t,e))));return new g(e[0],e[1],e[2],e[3])}class y{constructor(t,e){if(this.lib=t,this.jsonData=e,null===this.lib)throw new Error("SequenceTranslator: monomer library is null");this.allMonomers=this.getAllMonomers()}formatMonomerForViewer(t){const e={};return e.name=t.symbol,e.symbol=t.symbol,e.molfile=t.molfile,this.getAllFormats().forEach((n=>{if(n===h.NO.HELM)return;const r=this.jsonData.codesToSymbolsDict[n],o=Object.keys(r).filter((e=>r[e]===t.symbol));e[n]=o.join(", ")})),e}getAllMonomers(){const t=this.lib.getPolymerTypes();let e=[];for(const n of t){const t=this.lib.getMonomerSymbolsByType(n).map((t=>this.lib.getMonomer(n,t))).filter((t=>null!==t));e=e.concat(t)}return e}getMonomer(t){const e=this.lib.getMonomer("RNA",t);if(void 0===e)throw new Error(`SequenceTranslator: no monomer with symbol ${t}`);return e}getMolfileBySymbol(t){return this.getMonomer(t).molfile}getNaturalAnalogBySymbol(t){const e=this.getMonomer(t).naturalAnalog;if(!e)throw new Error(`ST: no natural analog for ${t}`);return e}isModification(t){return!!this.getMolfileBySymbol(t).includes("MODIFICATION")}getCodeToSymbolMap(t){return new Map(Object.entries(this.jsonData.codesToSymbolsDict[t]))}getCodesByFormat(t){return Object.keys(this.jsonData.codesToSymbolsDict[t])}getAllFormats(){return Object.keys(this.jsonData.codesToSymbolsDict)}getTableForViewer(){const t=this.allMonomers.map((t=>this.formatMonomerForViewer(t)));return o.DataFrame.fromObjects(t)}getCodesToWeightsMap(){const t=new Map;return Object.entries(this.jsonData.codesToSymbolsDict).forEach((([e,n])=>{Object.entries(n).forEach((([e,n])=>{const r=this.getMonomer(n),o=r.meta?.molecularWeight;t.set(e,o)}))})),t}}var v=n(537);const b=(t,e)=>e.length-t.length;class w{constructor(t){this.th=t,this.formats=this.getFormats()}getFormatNames(){return this.formats.sort()}getCodesByFormat(t){if(this.validateFormat(t),this.isHelm(t))throw new Error("Codes cannot be obtained for HELM");return this.getFormatCodes(t)}getHelmToFormatDict(t){return this.validateFormat(t),function(t){const e={};return Object.values(t).forEach((t=>{Object.entries(t).forEach((([t,n])=>{const r=n.replace(/\)p/g,")").replace(/\]p/g,"]");void 0===e[r]?e[r]=[t]:e[r].push(t)}))})),Object.entries(e).forEach((([t,n])=>{const r=n.sort(b);e[t]=r[0]})),e}(this.th.jsonData.codesToHelmDict[t])}getFormatToHelmDict(t){this.validateFormat(t);const e=this.th.jsonData.codesToHelmDict[t];return Object.assign({},...Object.values(e))}getTargetFormatHelmCodes(t){this.validateFormat(t);const e=this.getHelmToFormatDict(t);return Object.keys(e).sort(b)}getTargetFormatHelmCodesRegExp(t){this.validateFormat(t);const e=this.getTargetFormatHelmCodes(t);return new RegExp(A(e)+"|.","g")}getFormatRegExp(t){if(this.validateFormat(t),this.isHelm(t))throw new Error("Helm RegExp can be built for non-HELM target formats");return this.getNonHelmFormatRegExp(t)}getPhosphateHelmCodesRegExp(t){this.validateFormat(t);const e=this.th.jsonData.codesToHelmDict[t],n=A(Array.from(new Set(Object.values(e[v.ti.LINKAGE]))).sort(b));return new RegExp(`${v.q7}.(${n})`,"g")}isValidFormat(t){return this.formats.includes(t)}getFormats(){return Object.keys(this.th.jsonData.codesToHelmDict)}validateFormat(t){if(!this.isValidFormat(t))throw new Error(`Invalid format: ${t}`)}isHelm(t){return t===h.NO.HELM}getFormatCodes(t){const e=this.getFormatToHelmDict(t);return Object.keys(e).sort(b)}getNonHelmFormatRegExp(t){const e=this.getCodesByFormat(t);return new RegExp(A(e)+"|\\([^()]*\\)|.","g")}}function A(t){return t.map((t=>t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"))).map((t=>t.includes("(")||t.includes(")")?t:`(?<!\\([^()]*)${t}(?![^()]*\\))`)).join("|")}const _={LEFT:"RNA1{",RIGHT:"}$$$$"};class C{constructor(t,e,n){this.sequence=t,this.sourceFormat=e,this.th=n,this.formats=new w(this.th)}convertTo(t){const e=this.formats.getFormatNames();if(this.sourceFormat===h.NO.HELM&&e.includes(t))return this.helmToFormat(this.sequence,t);if(e.includes(this.sourceFormat)&&t===h.NO.HELM)return this.formatToHelm(this.sequence,this.sourceFormat);if([this.sourceFormat,t].every((t=>e.includes(t)))){const e=this.formatToHelm(this.sequence,this.sourceFormat);return this.helmToFormat(e,t)}throw new Error(`ST: unsupported translation direction ${this.sourceFormat} -> ${t}`)}helmToFormat(t,e){const n=new RegExp(A(Object.values(_)),"g");let r=t.replace(n,"");const o=this.formats.getHelmToFormatDict(e),i=this.formats.getTargetFormatHelmCodes(e),s=this.formats.getTargetFormatHelmCodesRegExp(e);return r=r.replace(s,(t=>i.includes(t)?o[t]:"p"===t||"."===t?t:"?")).replace(/\?+/g,v.iL).replace(/p\.|\./g,""),r=r.replace(/<empty>/g,""),r=r.replace(/\/\//g,"/"),r}formatToHelm(t,e){const n=this.formats.getFormatToHelmDict(e),r=this.formats.getCodesByFormat(e),o=this.formats.getFormatRegExp(e),i=this.formats.getPhosphateHelmCodesRegExp(e);let s=t?t.replace(o,(t=>r.includes(t)?n[t]+".":"?")):"";return s=s.replace(/\?+/g,`${v.iL}.`),s=s.slice(0,-1),s[s.length-1]===v.q7&&(s=s.slice(0,-1)),s=s.replace(i,((t,e)=>e)),s=s.replace(/<empty>/g,""),`${_.LEFT+s+_.RIGHT}`}}class E{constructor(t,e){this.sequence=t,this.th=e,this.libWrapper=this.th.monomerLibWrapper,this.formats=Object.keys(this.th.jsonData.codesToHelmDict)}getFormat(){if(this.sequence.startsWith("RNA"))return h.NO.HELM;const t=this.getListOfPossibleSynthesizersByFirstMatchedCode();if(0===t.length)return null;const e=this.th.createSequenceValidator(this.sequence),n=Array(t.length).fill(0);for(let r=0;r<t.length;++r){const o=t[r];n[r]=e.getInvalidCodeIndex(o)}const r=n.some((t=>-1===t))?-1:Math.max(...n);return t[n.indexOf(r)]}getListOfPossibleSynthesizersByFirstMatchedCode(){const t=this.sequence,e=[];for(const n of this.formats){const r=p(this.libWrapper.getCodesByFormat(n));let o=0;for(let e=0;e<t.length;e++)if(")"===t[e]&&e!==t.length-1){o=e+1;break}r.some((e=>e===t.slice(o,o+e.length)))&&e.push(n)}return e}}var x=n(389);const T=$;var I=n.n(T);class P extends o.Package{get seqHelper(){if(!this._seqHelper)throw new Error("Package SequenceTranslator .seqHelper is not initialized");return this._seqHelper}get monomerLib(){if(!this._monomerLib)throw new Error("Monomer lib not loaded");return this._monomerLib}get jsonData(){if(!this._jsonData)throw new Error("Json data not loaded");return this._jsonData}get monomerLibWrapper(){if(!this._monomerLibWrapper)throw new Error("Monomer lib wrapper not loaded");return this._monomerLibWrapper}constructor(t={debug:!1}){super(),this.highlightInvalidSubsequence=t=>function(t,e){let n=0;const r=e.createFormatDetector(t).getFormat();null!==r&&(n=new d(t,e).getInvalidCodeIndex(r));const o=n<0||""===t,i=x.span([]);I()(i).css("-webkit-text-fill-color","var(--grey-6)");const s=x.span([]);return I()(s).css("-webkit-text-fill-color","red"),o?i.innerHTML=t:(i.innerHTML=t.slice(0,n),s.innerHTML=t.slice(n)),[i,s]}(t,this),super._logger=new s(super.logger,t.debug)}completeInit(t){this._seqHelper=t}async initLibData(){return this.initPromise||(this.initPromise=(async()=>{let t=(await this.getSettings()).MonomersPath;t&&await r.dapi.files.exists(t)||(this.logger.warning(`Monomers path '${t}' not found. Fallback to monomers sample path '${a}'.`),t=a),[this._jsonData,this._monomerLib]=await Promise.all([m(t),O(t)]),this._monomerLibWrapper=new y(this.monomerLib,this.jsonData)})()),this.initPromise}async getTranslationHelper(){return await r.functions.call(`${this.name}:getTranslationHelper`)}createSequenceValidator(t){return new d(t,this)}createFormatConverter(t,e){return new C(t,e,this)}createFormatDetector(t){return new E(t,this)}}async function O(t){const e=o.TaskBarProgressIndicator.create("Initializing Oligo Toolkit monomer library ...");try{const e=await(0,i.pj)();return await e.readLibrary(t,"monomer-lib.json")}finally{e.close()}}const S=["SS","AS"],N={SS:"Sense strand",AS:"Anti sense"},L=["3'","5'"];var M,D,B,R;!function(t){t.IS_ANTISENSE_STRAND_INCLUDED="isAntisenseStrandIncluded",t.NUCLEOTIDE_SEQUENCES="nucleotideSequences",t.PHOSPHOROTHIOATE_LINKAGE_FLAGS="phosphorothioateLinkageFlags",t.STRAND_TERMINUS_MODIFICATIONS="strandTerminusModifications"}(M||(M={})),function(t){t.PATTERN_NAME="patternName",t.PATTERN_COMMENT="patternComment",t.NUCLEOTIDES_WITH_NUMERIC_LABELS="nucleotidesWithNumericLabels"}(D||(D={})),function(t){t.PATTERN_CONFIG="patternConfig",t.AUTHOR_ID="authorID",t.DATE="date"}(B||(B={})),function(t){t.CREATE="create",t.MODIFY="modify"}(R||(R={})),M.IS_ANTISENSE_STRAND_INCLUDED,M.NUCLEOTIDE_SEQUENCES,M.PHOSPHOROTHIOATE_LINKAGE_FLAGS,M.STRAND_TERMINUS_MODIFICATIONS,D.PATTERN_NAME,D.PATTERN_COMMENT,D.NUCLEOTIDES_WITH_NUMERIC_LABELS,Error,Error,n(802);const F=rxjs;var k;rxjs.operators,function(t){t.getTruncatedStrandData=function(t,e,n){return{nucleotides:t.slice(0,n),ptoFlags:e.slice(0,n+1)}},t.getExtendedStrandData=function(t,e,n,r){const o=n-t.length,i=t.concat(new Array(n-t.length).fill(r)),s=0===t.length?n+1:o;return{nucleotides:i,ptoFlags:e.concat(new Array(s).fill(!0))}}}(k||(k={}));var H=n(543),G=n.n(H),j=n(72),U=n.n(j),V=n(825),W=n.n(V),Y=n(659),q=n.n(Y),K=n(56),z=n.n(K),J=n(540),Q=n.n(J),Z=n(113),X=n.n(Z),tt=n(252),et={};et.styleTagTransform=X(),et.setAttributes=z(),et.insert=q().bind(null,"head"),et.domAPI=W(),et.insertStyleElement=Q(),U()(tt.A,et),tt.A&&tt.A.locals&&tt.A.locals;class nt{constructor(t,e,n){this.eventBus=t,this.initialPatternConfig=e,this.subscriptions=n}create(){return x.divV([x.h1("PTO"),x.divH([this.createAllPtoActivationInput().root,...this.createFirstPtoInputs().map((t=>t.root))],{style:{gap:"12px"}})])}areAllPtoLinkagesSet(t){return S.map((e=>t[e].filter((t=>t)).length)).reduce(((t,e)=>t+e),0)===S.map((t=>this.initialPatternConfig.nucleotideSequences[t].length)).reduce(((t,e)=>t+e),0)+S.filter((e=>t[e].length)).length}createAllPtoActivationInput(){const t=this.initialPatternConfig.phosphorothioateLinkageFlags,e=this.areAllPtoLinkagesSet(t),n=x.input.bool("All PTO",{value:e});n.onInput.subscribe((()=>{const t=n.value;this.eventBus.setAllPTOLinkages(t)}));const r=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((()=>{const t=this.eventBus.getPatternConfig().phosphorothioateLinkageFlags,e=this.areAllPtoLinkagesSet(t);n.value=e}));return this.subscriptions.add(r),this.addStyleToPtoInput(n),x.tooltip.bind(n.captionLabel,"Activate all phosphothioates"),n}addStyleToPtoInput(t){const e=t.captionLabel;e.classList.add("ui-label-right"),Object.assign(e.style,{textAlign:"left",maxWidth:"100px",minWidth:"40px",width:"auto"})}createFirstPtoInputs(){return S.map((t=>{if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return;const e=this.isFirstPtoActive(t),n=x.input.bool(`First ${t} PTO`,{value:e});n.onInput.subscribe((()=>{const e=n.value;this.eventBus.setPhosphorothioateLinkageFlag(t,0,e)}));const r=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((e=>{const r=e[t][0];n.value=r}));return this.subscriptions.add(r),this.addStyleToPtoInput(n),x.tooltip.bind(n.captionLabel,`Activate first phosphothioate in ${t}`),n})).filter((t=>void 0!==t))}isFirstPtoActive(t){return this.initialPatternConfig.phosphorothioateLinkageFlags[t][0]}}class rt{constructor(t,e,n){this.eventBus=t,this.dataManager=e,this.subscriptions=n;const r=this.eventBus.nucleotideSequencesChanged$.subscribe((()=>{this.displayedInputLabels=this.computeDisplayedInputLabels()}));this.subscriptions.add(r)}create(){const t=S.map((t=>this.constructControlsPanel(t)));return x.divH(t,{style:{gap:"24px"}})}constructControlsPanel(t){if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return x.div([]);const e=this.constructHeader(),n=this.createControls(t);return x.block([x.h1(`${N[t]}`),e,n],{style:{paddingTop:"12px"}})}constructHeader(){return x.divH([x.div([x.divText("#")],{style:{width:"20px"}}),x.block75([x.divText("Modification")]),x.div([x.divText("PTO")])])}createControls(t){const e=this.createNucleobaseInputs(t),n=this.createLabelDivs(t),r=this.createPTOFlagInputs(t);return x.div(e.map(((t,e)=>x.divH([n[e],x.block75([t.root]),r[e].root],{style:{alignItems:"center"}}))))}createNucleobaseInputs(t){const e=this.dataManager.fetchAvailableNucleotideBases().sort(((t,e)=>t.toLowerCase().localeCompare(e.toLowerCase())));return this.eventBus.getNucleotideSequences()[t].map(((n,r)=>{const o=x.input.choice("",{value:n,items:e});return o.onInput.subscribe((()=>{const e=o.value;this.eventBus.setNucleotide(t,r,e)})),o}))}createPTOFlagInputs(t){return this.eventBus.getPhosphorothioateLinkageFlags()[t].slice(1).map(((e,n)=>{const r=x.input.bool("",{value:e});r.onInput.subscribe((()=>{const e=r.value;this.eventBus.setPhosphorothioateLinkageFlag(t,n+1,e)}));const o=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((e=>{const o=e[t][n+1];r.value=o}));return this.subscriptions.add(o),r}))}computeDisplayedInputLabels(){const t=this.eventBus.getNucleotideSequences(),e=new Map;return S.forEach((n=>{let r=1;const o=t[n].map((t=>{if(function(t){return t.endsWith("(o)")}(t))return"";const e=String(r);return r++,e}));e.set(n,o)})),e}createLabelDivs(t){const e=this.createLabels(t).map((t=>x.div([t],{style:{width:"20px"}}))),n=this.eventBus.nucleotideSequencesChanged$.subscribe((()=>{this.createLabels(t).forEach(((t,n)=>{I()(e[n]).empty(),I()(e[n]).append(t)}))}));return this.subscriptions.add(n),e}createLabels(t){return this.eventBus.getNucleotideSequences()[t].map(((e,n)=>{const r=this.displayedInputLabels.get(t)[n];return x.label(r)}))}}class ot{constructor(){this.rxjsSubscriptions=[],this.dgSubscriptions=[]}add(t){t instanceof F.Subscription?this.rxjsSubscriptions.push(t):this.dgSubscriptions.push(t)}unsubscribeAll(){for(const t of[this.rxjsSubscriptions,this.dgSubscriptions])t.forEach((t=>t.unsubscribe())),t.length=0}}class it{constructor(t,e){this.eventBus=t,this.dataManager=e,this.subscriptions=new ot}static open(t,e){it.isDialogOpen||(it.instance||(it.instance=new it(t,e)),it.instance.openDialog())}openDialog(){this.initialPatternConfig=G().cloneDeep(this.eventBus.getPatternConfig()),it.isDialogOpen=!0,this.createDialog().show()}createDialog(){const t=x.divV([]);this.subscriptions.add(this.eventBus.strandsUpdated$.subscribe((()=>this.onStrandsUpdated(t))));const e=x.dialog("Edit strands").add(t).onOK((()=>{})).onCancel((()=>this.resetToInitialState()));return this.subscriptions.add(e.onClose.subscribe((()=>{it.isDialogOpen=!1,this.subscriptions.unsubscribeAll()}))),e}onStrandsUpdated(t){const e=new nt(this.eventBus,this.initialPatternConfig,this.subscriptions).create(),n=new rt(this.eventBus,this.dataManager,this.subscriptions).create();I()(t).empty(),I()(t).append(e,n)}resetToInitialState(){this.eventBus.setPatternConfig(this.initialPatternConfig)}}it.isDialogOpen=!1;class st{constructor(t){this.eventBus=t,this.subscriptions=new ot}static open(t){st.isDialogOpen||(st.instance||(st.instance=new st(t)),st.instance.openDialog())}openDialog(){this.initialPatternConfig=G().cloneDeep(this.eventBus.getPatternConfig()),st.isDialogOpen=!0,this.createDialog().show()}createDialog(){const t=x.divV([]);this.subscriptions.add(this.eventBus.strandsUpdated$.subscribe((()=>this.onStrandsUpdated(t))));const e=x.dialog("Edit terminal modifications").add(t).onOK((()=>{})).onCancel((()=>this.resetToInitialState()));return this.subscriptions.add(e.onClose.subscribe((()=>{st.isDialogOpen=!1,this.subscriptions.unsubscribeAll()}))),e}onStrandsUpdated(t){const e=new at(this.eventBus).create();I()(t).empty(),I()(t).append(e)}resetToInitialState(){this.eventBus.setPatternConfig(this.initialPatternConfig)}}st.isDialogOpen=!1;class at{constructor(t){this.eventBus=t}create(){const t=S.map((t=>this.constructControlsPanel(t)));return x.divH(t,{style:{gap:"24px"}})}constructControlsPanel(t){if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return x.div([]);const e=this.createInputs(t);return x.block([x.h1(`${N[t]}`),e],{style:{paddingTop:"12px"}})}createInputs(t){const e=("SS"===t?[...L].reverse():L).map((e=>this.createInputForTerminus(t,e)));return x.form(e)}createInputForTerminus(t,e){const n=this.eventBus.getTerminalModifications()[t][e],r=x.input.textArea(e,{value:n});return this.applyStylingToInput(r),r.onInput.subscribe((()=>{const n=r.value;null!==n&&this.eventBus.updateTerminusModification(t,e,n)})),r}applyStylingToInput(t){const e=t.root.getElementsByTagName("textarea")[0];I()(e).css("resize","none")}}n(146);var ut=n(507),ct={};ct.styleTagTransform=X(),ct.setAttributes=z(),ct.insert=q().bind(null,"head"),ct.domAPI=W(),ct.insertStyleElement=Q(),U()(ut.A,ct),ut.A&&ut.A.locals&&ut.A.locals;var lt,ft=n(74),ht={};ht.styleTagTransform=X(),ht.setAttributes=z(),ht.insert=q().bind(null,"head"),ht.domAPI=W(),ht.insertStyleElement=Q(),U()(ft.A,ht),ft.A&&ft.A.locals&&ft.A.locals,function(t){t.TYPE="V2000",t[t.NUM_OF_HEADER_LINES=3]="NUM_OF_HEADER_LINES",t[t.NUM_OF_COUNTS_DIGITS=3]="NUM_OF_COUNTS_DIGITS",t[t.ATOM_TYPE_COL=4]="ATOM_TYPE_COL",t[t.FIRST_BONDED_ATOM_COL=1]="FIRST_BONDED_ATOM_COL",t[t.BOND_TYPE_COL=3]="BOND_TYPE_COL",t[t.RGP_SHIFT=8]="RGP_SHIFT",t[t.MAX_ATOM_COUNT=999]="MAX_ATOM_COUNT",t.RGP_LINE_START="M RGP",t.ATOM_ALIAS_LINE_START="A ",t.END="M END"}(lt||(lt={})),Error,Error,n(670),n(3),n(480),n(67);var pt=n(254),dt={};dt.styleTagTransform=X(),dt.setAttributes=z(),dt.insert=q().bind(null,"head"),dt.domAPI=W(),dt.insertStyleElement=Q(),U()(pt.A,dt),pt.A&&pt.A.locals&&pt.A.locals;var gt=n(70);n(124),n(312),n(991),"object"==typeof performance&&performance&&"function"==typeof performance.now?performance:Date,new Set;const mt="object"==typeof process&&process?process:{};let yt=globalThis.AbortController,vt=globalThis.AbortSignal;if(void 0===yt){vt=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(t,e){this._onabort.push(e)}},yt=class{constructor(){e()}signal=new vt;abort(t){if(!this.signal.aborted){this.signal.reason=t,this.signal.aborted=!0;for(const e of this.signal._onabort)e(t);this.signal.onabort?.(t)}}};let t="1"!==mt.env?.LRU_CACHE_IGNORE_AC_WARNING;const e=()=>{var n,r,o,i;t&&(t=!1,n="AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.",r="NO_ABORT_CONTROLLER",o="ENOTSUP",i=e,"function"==typeof mt.emitWarning?mt.emitWarning(n,r,o,i):console.error(`[${o}] ${r}: ${n}`))}}Symbol("type"),Symbol.iterator,Symbol.toStringTag,Map,n(151),n(599),n(717),n(702),n(682);class bt extends o.InputBase{constructor(t,e){super(x.input.column(t,e).dart,e?.onValueChanged),this.options=e}setColumnInputTable(t){x.input.setColumnInputTable(this,t,this.options?.filter)}}var wt;x.input.column2=function(t,e){return new bt(t,e)},n(296),n(820),o.JsInputBase,o.JsInputBase,function(t){t.table="table",t.seqCol="seqCol",t.generateHelm="generateHelm",t.chiralityEngine="chiralityEngine",t.rules="rules"}(wt||(wt={}));class At{onKeyDown(t,e){}onKeyPress(t,e){}onMouseEnter(t,e){}onMouseLeave(t,e){}onMouseDown(t,e){}onMouseUp(t,e){}onMouseMove(t,e){}onClick(t,e){}onDoubleClick(t,e){}}class _t extends At{constructor(t,e,n){super(),this.gridCol=t,this.tableCol=e,this.logger=n,this.subs=[],this.dirty=!0,this.destroyed=!1,this.viewerId=++_t.viewerCounter,this.errors=[],this._onRendered=new F.Subject,this.tableCol&&this.tableCol.dataFrame&&this.subs.push(this.tableCol.dataFrame.onDataChanged.subscribe((()=>{this.dirty=!0}))),this.tableCol&&this.subs.push(r.events.onTableRemoved.subscribe((t=>{try{const e=t.args.dataFrame;this.tableCol?.dataFrame.id!==e.id||this.destroyed||this.destroy()}catch(t){this.logger.error(t)}}))),this.gridCol&&this.subs.push(r.events.onViewRemoving.subscribe((t=>{try{const e=t.args.view;this.gridCol?.dart&&this.gridCol.grid&&this.gridCol?.grid?.dart&&this.gridCol?.grid?.view?.id===e.id&&!this.destroyed&&this.destroy()}catch(t){this.logger.error(t)}})))}toLog(){return`${this.constructor.name}<${this.viewerId}>`}destroy(){for(const t of this.subs)t.unsubscribe();this.destroyed=!0}invalidateGrid(){this.gridCol&&this.gridCol.dart&&this.gridCol.grid?.invalidate()}reset(){this.dirty=!1}get onRendered(){return this._onRendered}invalidate(t){this.invalidateGrid()}async awaitRendered(t=1e4,e=`${t} timeout`){const n=`${this.toLog()}.awaitRendered()`;if(this.logger.debug(`${n}, start, testEvent before`),await(0,gt.PE)(this._onRendered,(()=>{}),(()=>{this.invalidate()}),t,`${n}, ${e}`),this.errors.length>0){const t=this.errors[0];throw this.errors=[],t}this.logger.debug(`${n}, end`)}}_t.viewerCounter=-1,n(192);var Ct,Et,xt,Tt=n(291);Tt.zS,function(t){t.maxMonomerLength=".mm.cellRenderer.maxMonomerLength"}(Ct||(Ct={})),function(t){t.applyToBackground=".m.cellRenderer.applyToBackground"}(Et||(Et={})),function(t){t.MSA="MSA",t.classic="classic"}(xt||(xt={})),new class{constructor(){this.color="rgb(100,100,100)",this.pivot=0,this.left=!1,this.transparencyRate=1,this.separator="",this.last=!1,this.drawStyle=xt.classic,this.maxWord=[],this.wordIdx=0,this.gridCell=null,this.referenceSequence=null,this.maxLengthOfMonomer=null,this.monomerTextSizeMap={},this.logger=void 0}},Tt.Mu;const It=new P({debug:!0})},682:(t,e,n)=>{"use strict";n.d(e,{by:()=>l,kl:()=>f,sW:()=>c});var r=n(328),o=(n(991),n(599)),i=(n(890),n(717),n(192)),s=n(124),a=n(296),u=n(544);class c{constructor(t,e,n){this.linkages=e,this.monomers=t,this.mol=n}static fromHelm(t){const e=t.split("$"),n=e[0].split("|"),r=e[1].split("|"),o=new Array(n.length),i=[];for(let t=0;t<n.length;t++){const e=n[t].indexOf("{"),r=n[t].indexOf("}");o[t]=n[t].slice(e+1,r).split(".")}for(let t=0;t<r.length;t++)if(""!==r[t]&&"V2.0"!==r[t]){const e=r[t].split(","),n=e[0].replace("PEPTIDE","")-1,o=e[1].replace("PEPTIDE","")-1,s=e[2].split("-"),a=s[0].split(":"),u=s[1].split(":");i.push({fChain:n,sChain:o,fMonomer:a[0],sMonomer:u[0],fR:a[1].replace("R",""),sR:u[1].replace("R","")})}return new c(o,i,null)}static fromNotation(t,e){const n=e.heterodimerCode,r=e.homodimerCode,o=[],i=[],s=null!==n?t.split(`(${e.heterodimerCode})`):"";null!==n&&s.length>1?(i.push({fChain:0,sChain:1,fMonomer:1,sMonomer:1,fR:1,sR:1}),o.push(s[1].replaceAll("{","").replaceAll("}","")),o.push(s[2].replaceAll("{","").replaceAll("}",""))):o.push(t);for(let t=0;t<o.length;t++)if(null!==r&&o[t].includes(`(${r})`)){const e=o.length;i.push({fChain:t,sChain:e,fMonomer:1,sMonomer:1,fR:1,sR:1});const n=o[t].replace(`(${r})`,""),s=n.indexOf("{"),a=n.slice(0,s),u=n.replace(a,"").replaceAll("{","").replaceAll("}","");o[t]=a+u,o.push(u)}for(let t=0;t<o.length;t++)if(null!==r&&o[t].includes(`(${r})`)){const e=o.length;i.push({fChain:t,sChain:e,fMonomer:1,sMonomer:1,fR:1,sR:1});const n=o[t].replace(`(${r})`,""),s=n.indexOf("{"),a=n.slice(0,s),u=n.replace(a,"").replaceAll("{","").replaceAll("}","");o[t]=a+u,o.push(u)}const a=new Array(o.length);for(let t=0;t<o.length;t++){const n=o[t].split("-"),r=this.getLinkedPositions(n,e.linkRules),[s,u,c,l,f]=this.getAllCycles(e.linkRules,n,r);new Array(s.length);for(let e=0;e<u.length;e++)i.push({fChain:t,sChain:t,fMonomer:u[e],sMonomer:c[e],fR:l[e],sR:f[e]});a[t]=s}const u=[];for(let t=0;t<a.length;t++){const n=this.getLinkedPositions(a[t],e.reactionRules),[r,o,s,c]=this.getAllReactants(e.reactionRules,a[t],n);if(o.length>=1){const t=new Array(s[0]-1),n=new Array(r.length-s[0]);for(let e=0;e<s[0]-1;e++)t[e]=r[e];for(let t=s[0];t<r.length;t++)n[t-s[0]]=r[t];t[o[0]-1]=e.reactionRules[c[0]].name;for(let t=0;t<i.length;t++)i[t].fMonomer>s[0]&&(i[t].fMonomer-=s[0],i[t].fChain++),i[t].sMonomer>s[0]&&(i[t].sMonomer-=s[0],i[t].sChain++);i.push({fChain:0,sChain:0,fMonomer:o[0],sMonomer:s[0]-1,fR:3,sR:2}),i.push({fChain:0,sChain:1,fMonomer:o[0],sMonomer:1,fR:4,sR:1});const a=new Array(t.length);for(let e=0;e<t.length;e++)a[e]=`[${t[e]}]`;const l=new Array(n.length);for(let t=0;t<n.length;t++)l[t]=`[${n[t]}]`;u.push(t),u.push(n)}else u.push(a[t])}return new c(u,i,null)}static async parseNotation(t){const e=[],n=[],r=(await(0,s.b2)()).createHelmWebEditor().editor.m,i=/(\(.\d+\))?\{[^\}]*\}/g,a=[];a.push(t.replaceAll(i,""));const u=t.matchAll(i);for(const t of u){const e=t[0];e&&a.push(e)}let l=0;for(let t=0;t<a.length;t++){const r=a[t].split("-"),o=new Array(r.length);for(let e=0;e<r.length;e++){const i=r[e].replace("{","").replace("}","");""!==i?(o[e]=i,l++):n.push({fChain:t,sChain:t+1,fMonomer:l,sMonomer:l+1,fR:1,sR:1})}e.push(o)}l=0;const f=new JSDraw2.Point(0,0);for(let t=0;t<e.length;t++)for(let n=0;n<e[t].length;n++){if(e[t][n]){const i=e[t][n],s={type:o.o.AA,i:t,j:n},a=new JSDraw2.Atom(f,i,s);if(r.addAtom(a),0!==n){const t=r.atoms[l-1],e=r.atoms[l],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,r.addBond(n)}l++,f.x+=JSDraw2.Editor.BONDLENGTH}f.y+=4*JSDraw2.Editor.BONDLENGTH}for(let t=0;t<n.length;t++){const e=r.atoms[n[t].fMonomer-1],o=r.atoms[n[t].sMonomer-1],i=new JSDraw2.Bond(e,o);i.r1=n[t].fR,i.r2=n[t].sR,r.addBond(i)}return new c(e,n,r)}getHelmChanged(t,e){let n=0,r=0,o=0;t:for(let e=0;e<this.monomers.length;e++)for(let i=0;i<this.monomers[e].length;i++){if(n==t){r=e,o=i;break t}n++}const i=this.monomers[r][o];this.monomers[r][o]=`[${e}]`;const s=this.getHelm();return this.monomers[r][o]=i,s}getNotationHelm(){return this.getHelm()}getHelm(){let t="";for(let e=0;e<this.monomers.length;e++){e>0&&(t+="|"),t+=`PEPTIDE${e+1}{`;for(let n=0;n<this.monomers[e].length;n++){n>0&&(t+=".");const r=this.monomers[e][n];t+=r.length>1?`[${r}]`:r}t+="}"}t+="$";for(let e=0;e<this.linkages.length;e++)e>0&&(t+="|"),t+=`PEPTIDE${this.linkages[e].fChain+1},PEPTIDE${this.linkages[e].sChain+1},`,t+=`${this.linkages[e].fMonomer}:R${this.linkages[e].fR}-`,t+=`${this.linkages[e].sMonomer}:R${this.linkages[e].sR}`;return t+="$$$",t}getNotation(){const t=this.mol.atoms,e=this.mol.bonds,n=[],r=[];for(let t=0;t<e.length;t++)e[t].a1.bio.i!==e[t].a2.bio.i&&r.push(t);for(let e=0;e<t.length;e++){const r=t[e].bio?.i;r+1>n.length?n.push(1):n[r]++}const o=new Array(n.length);let i=0;for(let e=0;e<n.length;e++){const r=new Array(n[e]);for(let o=0;o<n[e];o++)r[o]=t[i].elem,i++;o[e]=r}let s="";for(let t=0;t<o.length;t++){let n="";for(let e=0;e<o[t].length;e++)n+=`${0==e?"":"-"}${o[t][e]}`;if(0!==t){const t=/(\(.\d+\))/,e=n.match(t);n=n.replace(e?.[0],""),n=`${e?e?.[0]:""}{${n}}`}else if(o.length>1){const t=0==e[r[0]].a1.bio.i&&0==e[r[0]].a1.bio.j,o=1==e[r[0]].a2.bio.i&&0==e[r[0]].a1.bio.j;t&&o&&(n+="-")}s+=n}return s}static getLinkedPositions(t,e){const n=new Array(e.length);for(let r=0;r<e.length;r++){let o=!1,i=!1,s=!1,a=-1,u=-1;const c=`(${e[r].code})`;for(let n=0;n<t.length;n++)if(t[n].includes(c)){if(o){if(s&&t[n]==e[r].secondMonomer+c){i=!0,u=n;break}if(s||t[n]!=e[r].firstMonomer+c)continue;i=!0,u=n;break}if(t[n]==e[r].firstMonomer+c)o=!0,s=!0,a=n;else{if(t[n]!=e[r].secondMonomer+c)continue;o=!0,s=!1,a=n}}n[r]=o&&i?s?[a,u,r]:[u,a,r]:[-1,-1,-1]}return n}static getAllCycles(t,e,n){const r=[],o=[],i=[],s=[],a=t.length;for(let u=0;u<a;u++){if(-1==n[u][0])continue;const a=e[n[u][0]],c=e[n[u][1]];e[n[u][0]]=e[n[u][0]].replace(a,t[u].firstSubstitution),e[n[u][1]]=e[n[u][1]].replace(c,t[u].secondSubstitution),r.push(n[u][0]+1),o.push(n[u][1]+1),i.push(t[u].firstLinkingGroup),s.push(t[u].secondLinkingGroup)}return[e,r,o,i,s]}static getAllReactants(t,e,n){const r=[],o=[],i=[],s=t.length;for(let a=0;a<s;a++){if(-1==n[a][0])continue;const s=e[n[a][0]],u=e[n[a][1]];e[n[a][0]]=e[n[a][0]].replace(s,t[a].firstMonomer),e[n[a][1]]=e[n[a][1]].replace(u,t[a].secondMonomer),r.push(n[a][0]+1),o.push(n[a][1]+1),i.push(n[a][2])}return[e,r,o,i]}}function l(t,e){const n=new Array(t.length);for(let r=0;r<t.length;r++)try{if(null==t[r])n[r]="";else{const o=c.fromNotation(t[r],e);n[r]=o.getHelm()}}catch(t){const[e,o]=(0,i.AP)(t);u._package.logger.error(e,void 0,o),n[r]=""}return n}function f(t,e,n){const o=n.reaction,s=n.name,u=e.getMonomer("PEPTIDE",n.firstMonomer);if(!u)throw new a.bl("PEPTIDE",n.firstMonomer);const c=e.getMonomer("PEPTIDE",n.secondMonomer);if(!c)throw new a.bl("PEPTIDE",n.secondMonomer);const[l,f]=function(t,e){const n=t.molfile;let r=e.molfile;const o=t.rgroups.length,i=r.indexOf("M RGP");if(-1!==i){const t=r.substring(i+6,i+9),e=Number(t);for(let t=0;t<e;t++){const e=i+9+4+8*t,n=i+9+8+8*t,s=r.substring(e,n),a=Number(s)+o,u=Math.floor(Math.log10(a)+1),c=" ".repeat(4-u)+String(a);r=r.substring(0,e)+c+r.substring(n,r.length)}}return[n,r]}(u,c),h=function(t,e,n,o,s){let u=null,c=null,l=null,f=null,h=null,p=null,d="";try{if(u=t.get_rxn(e),!u)throw new a.J5(e);c=new t.MolList,l=t.get_mol(n),f=t.get_mol(o),c.append(l),c.append(f),h=u.run_reactants(c,1),p=h.get(0).next(),d=p?.get_molblock()}catch(t){const[e,n]=(0,i.AP)(t);throw r.shell.error(`Can not assemble monomer '${s}': ${e}.`),t}finally{u?.delete(),c?.delete(),l?.delete(),f?.delete(),h?.delete(),p?.delete()}return d}(t,o,l,f,s),p=function(t,e){const n=new Array(t?.rgroups.length+e?.rgroups.length),r=t?.rgroups.length,o=e?.rgroups.length;for(let e=0;e<r;e++)n[e]=t?.rgroups[e];for(let t=0;t<o;t++){const o=e?.rgroups[t].label.replace("R",""),i=Number(o)+r,s={capGroupSMILES:e?.rgroups[t].capGroupSMILES.replace(o,String(i)),alternateId:e?.rgroups[t].alternateId.replace(o,String(i)),capGroupName:e?.rgroups[t].capGroupName,label:e?.rgroups[t].label.replace(o,String(i))};n[t+r]=s}return n}(u,c),d={symbol:s,name:s,molfile:h,author:"",id:0,rgroups:p,smiles:"",polymerType:"PEPTIDE",monomerType:"Backbone",createDate:null};return d.meta=Object.assign(d.meta??{},{colors:{default:{line:"#2083D5",text:"#2083D5",background:"#F2F2F5"}}}),[s,d]}},820:(t,e,n)=>{"use strict";n.d(e,{o:()=>i});var r=n(296);function o(t,e,n,r){const o=new Array(r.length*(n-e+1));for(let i=0;i<r.length;++i){const s=n-e+1;for(let n=0;n<s;++n){const a=e+n,u=r[i],c=o[i*s+n]=t.clone(),l=c.atoms[a].elem;c.atoms[a].elem=u;const f=l?.length>1?`[${l}]`:l,h=u?.length>1?`[${u}]`:u;c.name=`${t.name}-${f}${a+1}${h}`}}return o}function i(t,e,n){const i=new JSDraw2.MolHandler,s=new org.helm.webeditor.Plugin(i);org.helm.webeditor.IO.parseHelm(s,t,new JSDraw2.Point(0,0),void 0);const a=i.m;a.name=e;let u=[];if(n.placeholders)switch(n.type){case r.aK.Single:u=function(t,e){return e.map((e=>o(t,e.position,e.position,e.monomers))).reduce(((t,e)=>t.concat(e)),[])}(i.m,n.placeholders);break;case r.aK.Matrix:u=function(t,e){let n=[t];for(const t of e){const e=n.map((e=>o(e,t.position,t.position,t.monomers)));n=e.reduce(((t,e)=>t.concat(e)),[])}return n}(i.m,n.placeholders)}let c=[];n.placeholdersBreadth&&(c=function(t,e){let n=[t];for(const t of e){const e=n.map((e=>o(e,t.start,t.end,t.monomers)));n=e.reduce(((t,e)=>t.concat(e)),[])}return n}(i.m,n.placeholdersBreadth)),u=u.concat(c),n.keepOriginal&&(u=[a,...u]);const l=u.map((t=>[org.helm.webeditor.IO.getHelm(t),t.name]));return l}},702:(t,e,n)=>{"use strict";n.d(e,{Q4:()=>l});var r=n(82),o=n(328);n(389),n(991);const i="System:AppData/SequenceTranslator/polytool-rules/",s="link",a="reaction",u="fragmentDuplication",c="differentFragments";async function l(t){const e=new r.FileSource(i),n=[],l=[],f={homodimerCode:null,heterodimerCode:null,linkRules:n,reactionRules:l};for(let r=0;r<t.length;r++){const h=await e.readAsText(t[r].replace(i,"")),p=JSON.parse(h);for(let t=0;t<p.length;t++)if(void 0!==p[t].type&&void 0!==p[t].code)switch(p[t].type){case s:{const e=p[t].monomericSubstitution;e.code=p[t].code,n.push(e);break}case a:{const e=p[t].monomericSubstitution;e.code=p[t].code,l.push(e);break}case u:f.homodimerCode&&o.shell.warning("PolyTool: homodimer code is duplicated in rules."),f.homodimerCode=p[t].code;break;case c:f.heterodimerCode&&o.shell.warning("PolyTool: heterodimer code is duplicated in rules."),f.heterodimerCode=p[t].code;break;default:o.shell.warning(`PolyTool: Unexpected type - '${p[t]}'.`)}else o.shell.warning("Polytool: rules contain invalid rule")}return f}},296:(t,e,n)=>{"use strict";var r;n.d(e,{J5:()=>i,aK:()=>r,bl:()=>o}),function(t){t.Single="single",t.Matrix="matrix"}(r||(r={}));class o extends Error{constructor(t,e,n){super(`Monomer '${e}' of polymer type '${t}' not found`,n),this.type="MonomerNotFoundError"}}class i extends Error{constructor(t,e){super(`Invalid reaction '${t}'.`),this.type="InvalidReactionError"}}},82:t=>{"use strict";t.exports=DG},328:t=>{"use strict";t.exports=grok},389:t=>{"use strict";t.exports=ui},991:t=>{"use strict";t.exports=wu}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.m=t,n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.u=t=>t+".js",n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),(()=>{var t;n.g.importScripts&&(t=n.g.location+"");var e=n.g.document;if(!t&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(t=e.currentScript.src),!t)){var r=e.getElementsByTagName("script");if(r.length)for(var o=r.length-1;o>-1&&(!t||!/^http(s?):/.test(t));)t=r[o--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=t})(),n.b=document.baseURI||self.location.href,n.nc=void 0;var r={};(()=>{"use strict";n.r(r),n.d(r,{_package:()=>S,initAutoTests:()=>L,test:()=>N,tests:()=>e.CN});var t=n(82),e=n(70),o=n(328),i=n(686);class s extends t.Package{async getTranslationHelper(){return await o.functions.call(`${this.name}:getTranslationHelper`)}}function a(t,e,n){return n.createFormatConverter(t,e).convertTo(i.NO.HELM)}function u(t,e,n){return n.createFormatConverter(t,i.NO.HELM).convertTo(e)}const c={Axolabs:{UfAfsCfsGfuacg:"RNA1{[fR](U)p.[fR](A)[sp].[fR](C)[sp].[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$"},BioSpring:{"A*GC*123456789":"RNA1{r(A)[sp].r(G)p.r(C)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)p.d([m5C])}$$$$"},Mermade12:{hefglijkLIJKHEFG:"RNA1{[25r](U)[sp].[25r](A)[sp].[25r](C)[sp].[25r](G)[sp].[fR](U)[sp].[fR](A)[sp].[fR](C)[sp].[fR](G)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$"}},l={"RNA1{[fR](U)p.[fR](A)[sp].[fR](C)[sp].[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$":"UACGUACG","RNA1{r(A)[sp].r(G)p.r(C)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)p}$$$$":"AGCUACGUACG","RNA1{[25r](U)[sp].[25r](A)[sp].[25r](C)[sp].[25r](G)[sp].[fR](U)[sp].[fR](A)[sp].[fR](C)[sp].[fR](G)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$":"UACGUACGUACGUACG"};(0,e.L1)("Formats to HELM",(()=>{let t;(0,e.gM)((async()=>{t=await S.getTranslationHelper()}));for(const n of Object.keys(c))for(const[r,o]of Object.entries(c[n]))(0,e.t6)(`${n} to HELM`,(async()=>{const i=o,s=a(r,n,t);(0,e.E3)(s,i)}))})),(0,e.L1)("HELM to Formats",(()=>{let t;(0,e.gM)((async()=>{t=await S.getTranslationHelper()}));for(const n of Object.keys(c))for(const[r,o]of Object.entries(c[n]))(0,e.t6)(`${n} to HELM`,(async()=>{const i=r,s=u(o,n,t);(0,e.E3)(s,i)}))}));var f=n(480);(0,e.L1)("HELM to Nucleotides",(()=>{let t;(0,e.gM)((async()=>{t=await S.getTranslationHelper()})),Object.entries(l).forEach((([n,r],o)=>{(0,e.t6)(`Sequence ${o+1} to nucleotides`,(async()=>{const o=r,i=(0,f.Hs)(n,t.monomerLibWrapper);(0,e.E3)(i,o)}))}))}));const h={[i.NO.AXOLABS]:"Afcgacsu",[i.NO.HELM]:"RNA1{[fR](A)p.[25r](C)p.[25r](G)p.[25r](A)p.[25r](C)[sp].[25r](U)}$$$$"};(0,e.L1)("Formats support",(()=>{let t;(0,e.gM)((async()=>{t=await S.getTranslationHelper()})),Object.entries(h).forEach((([n,r])=>{(0,e.t6)(`All formats for ${n}`,(async()=>{const o=function(t,e,n){const r=n.createSequenceValidator(t).getInvalidCodeIndex(e);return(0,f.bD)(t,r,e,n)}(r,n,t),i=Object.keys(o).length,s=Object.keys(c).length+1;(0,e.E3)(!0,s<=i)}))}))}));var p=n(192);(0,e.L1)("files",(()=>{let n;(0,e.gM)((async()=>{n=await S.getTranslationHelper()})),(0,e.t6)("list",(async()=>{let r;const o=t.DataFrame.fromColumns([t.Column.string("subTest"),r=t.Column.bool("success"),t.Column.string("format"),t.Column.string("src"),t.Column.string("res"),t.Column.string("tgt"),t.Column.string("error"),t.Column.string("stack")]),i=await S.files.list("tests",!0,".csv");for(const r of i){const i=t.DataFrame.fromCsv(await r.readAsString()),s=i.columns.byIndex(0),u=s.name,c=i.columns.byIndex(1),l=i.rowCount;for(let t=0;t<l;++t){const i=o.rows.addNew();i.subTest=`${r.name}, row: ${t}`;try{const r=s.get(t),o=c.get(t);i.format=u,i.src=r,i.tgt=o;const l=i.res=a(r,u,n);(0,e.E3)(l,o),i.success=!0}catch(t){const[e,n]=(0,p.AP)(t);i.error=e,i.stack=n,i.success=!1}}}0==o.rowCount&&o.rows.addNew(["empty",!0,"",""]);const s=r.toList().findIndex((t=>1!=t));if(-1!=s){const t=o.rows.get(s);throw new Error(`Subtest '${t.subTest}' failed: ${t.error}`)}return o}),{skipReason:"Can not create test in async manner based on files in Shares."})}));var d=n(312),g=n(3);class m{constructor(t,e,n,r,o,i){this.units=t,this.aligned=e,this.alphabet=n,this.alphabetSize=r,this.alphabetIsMultichar=o,this.separator=i}}async function y(e,n){const r=(await e()).getCol(n),i=await o.functions.call("Bio:detectMacromolecule",{col:r});if(i&&(r.semType=i),r.semType===t.SEMTYPE.MACROMOLECULE){const t=`Negative test detected semType='${r.semType}', units='${r.meta.units}'.`;throw new Error(t)}}async function v(n,r,i,s,a,u,c,l,f=null){const h=(await n()).col(r),p=await o.functions.call("Bio:detectMacromolecule",{col:h});p&&(h.semType=p),(0,e.E3)(h.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(h.meta.units,s),(0,e.E3)(h.getTag(g.gp.aligned),a),(0,e.E3)(h.getTag(g.gp.alphabet),u),f&&(0,e.E3)(h.getTag(g.gp.separator),f);const d=i.getSeqHandler(h);(0,e.E3)(d.getAlphabetSize(),c),(0,e.E3)(d.getAlphabetIsMultichar(),l),d.isHelm()||((0,e.E3)(d.aligned,a),(0,e.E3)(d.alphabet,u))}(0,e.L1)("PolyTool: detectors",(()=>{let n;(0,e.gM)((async()=>{n=await(0,d.Q)()}));const r={cyclized1:{csv:"n,seq\n1,R-F-C(1)-T-G-H-F-Y-G-H-F-Y-G-H-F-Y-P-C(1)-meI\n2,C(1)-T-G-H-F-Y-P-C(1)-meI\n3,R-F-C(1)-T-G-H-F-Y-P-C(1)\n4,C(1)-T-G-H-F-H-P-C(1)\n5,R-F-D(2)-T-G-H-F-Y-P-NH2(2)\n6,R-F-aG(3)-T-G-H-F-Y-P-azG(3)-meI",pos:{seq:new m(g.Hi.CUSTOM,"SEQ",g.YI.UN,13,!0,"-")}}};for(const[o,i]of Object.entries(r))(0,e.t6)(`${o}`,(async()=>{const e=async()=>t.DataFrame.fromCsv(i.csv);for(const t of i.neg??[])await y(e,t);for(const[t,r]of Object.entries(i.pos??{}))await v(e,t,n,r.units,r.aligned,r.alphabet,r.alphabetSize,r.alphabetIsMultichar,r.separator)}))}));var b=n(890);const w="Libraries";let A=Promise.resolve();async function _(){let t;return A=A.then((async()=>{const e=o.userSettings.getValue(w,"Settings",!0);t=e?JSON.parse(e):{exclude:[],explicit:[],duplicateMonomerPreferences:{}},t.exclude=t.exclude instanceof Array?t.exclude:[],t.explicit=t.explicit instanceof Array?t.explicit:[],t.duplicateMonomerPreferences=t.duplicateMonomerPreferences instanceof Object?t.duplicateMonomerPreferences:{},console.debug(`Bio: getUserLibSettings()\n${JSON.stringify(t,void 0,2)}`)})),await A,t}async function C(t){A=A.then((async()=>{console.debug(`Bio: setUserLibSettings()\n${JSON.stringify(t,void 0,2)}`),o.userSettings.add(w,"Settings",JSON.stringify(t),!0)})),await A}var E=n(682),x=n(702);(0,e.L1)("PolyTool: Convert",(()=>{let n,r;(0,e.gM)((async()=>{n=await(0,b.pj)(),r=await _(),await n.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await C(r),await n.loadMonomerLib(!0)}));const i={cyclized:{src:["R-F-C(1)-T-G-H-F-Y-P-C(1)-meI","C(1)-T-G-H-F-Y-P-C(1)-meI","R-F-C(1)-T-G-H-F-Y-P-C(1)","C(1)-T-G-H-F-H-P-C(1)","R-F-D(2)-T-G-H-F-Y-P-NH2(2)"],tgt:["PEPTIDE1{R.F.C.T.G.H.F.Y.P.C.[meI]}$PEPTIDE1,PEPTIDE1,3:R3-10:R3$$$","PEPTIDE1{C.T.G.H.F.Y.P.C.[meI]}$PEPTIDE1,PEPTIDE1,1:R3-8:R3$$$","PEPTIDE1{R.F.C.T.G.H.F.Y.P.C}$PEPTIDE1,PEPTIDE1,3:R3-10:R3$$$","PEPTIDE1{C.T.G.H.F.H.P.C}$PEPTIDE1,PEPTIDE1,1:R3-8:R3$$$","PEPTIDE1{R.F.D.T.G.H.F.Y.P.[NH2]}$PEPTIDE1,PEPTIDE1,10:R2-3:R3$$$"]}};for(const[t,n]of Object.entries(i))(0,e.t6)(`${t}`,(async()=>{const t=await(0,x.Q4)(["rules_example.json"]),r=(0,E.by)(n.src,t);(0,e.J6)(r,n.tgt)}));(0,e.t6)("ui-col-wo-table",(async()=>{const n=S.name,r=t.Column.fromStrings("seq",i.cyclized.src),s=await o.functions.call(`${n}:polyToolConvert2`,{seqCol:r,generateHelm:!0,chiralityEngine:!0,rules:["rules_example.json"]});(0,e.E3)(s.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(s.meta.units,g.Hi.HELM),(0,e.E3)(s.dataFrame,null)})),(0,e.t6)("ui-col",(async()=>{const n=S.name,r=t.Column.fromStrings("seq",i.cyclized.src),s=t.DataFrame.fromColumns([r]),a=o.shell.addTableView(s),u=await o.functions.call(`${n}:polyToolConvert2`,{seqCol:r,generateHelm:!0,chiralityEngine:!0,rules:["rules_example.json"]});(0,e.E3)(u.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(u.meta.units,g.Hi.HELM),(0,e.E3)(u.dataFrame.id,s.id),await(0,e.PE)(a.grid.onAfterDrawContent,(()=>{}),(async()=>{a.grid.invalidate()}),15e3),(0,e.E3)(u.getTag(t.TAGS.CELL_RENDERER),"helm")}))}));var T=n(124),I=n(296),P=n(820);(0,e.L1)("PolyTool: Enumerate",(()=>{let t,n,r;(0,e.gM)((async()=>{t=await(0,T.b2)(),n=await(0,b.pj)(),r=await _(),await n.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await C(r),await n.loadMonomerLib(!0)}));const o={single1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholders:[{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5P"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.[F4COO].L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5[F4COO]"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7T"}]},"single-with-original":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholders:[{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}],keepOriginal:!0},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:""},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5P"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.[F4COO].L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5[F4COO]"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7T"}]},matrix1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Matrix,placeholders:[{position:1,monomers:["D","L"]},{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].D.W.G.K.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5K-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.K.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5K-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5P-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5P-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.[F4COO].L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5[F4COO]-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.[F4COO].L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5[F4COO]-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.K.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5K-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.K.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5K-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5P-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5P-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.[F4COO].L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5[F4COO]-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.[F4COO].L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5[F4COO]-[Tic]7T"}]}};for(const[t,n]of Object.entries(o))(0,e.t6)(`${t}`,(async()=>{const t=(0,P.o)(n.src,"",n.params);(0,e.J6)(t,n.tgt.map((t=>[t.seq,t.name])))}))})),(0,e.L1)("PolyTool: Enumerate",(()=>{let t,n,r;(0,e.gM)((async()=>{t=await(0,T.b2)(),n=await(0,b.pj)(),r=await _(),await n.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await C(r),await n.loadMonomerLib(!0)}));const o={breadth1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholdersBreadth:[{start:2,end:4,monomers:["K"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"}]},"breadth1-with-original":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholdersBreadth:[{start:2,end:4,monomers:["K"]}],keepOriginal:!0},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:""},{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"}]},breadth2:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholdersBreadth:[{start:2,end:4,monomers:["K","Y"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.Y.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5Y"}]},"breadth-double":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:I.aK.Single,placeholdersBreadth:[{start:2,end:4,monomers:["K"]},{start:2,end:4,monomers:["Y"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.Y.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-K3Y"},{seq:"PEPTIDE1{[Ac(1)].F.K.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.K.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-P5Y"},{seq:"PEPTIDE1{[Ac(1)].F.Y.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-K4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-P5Y"},{seq:"PEPTIDE1{[Ac(1)].F.Y.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-K5Y"}]}};for(const[t,n]of Object.entries(o))(0,e.t6)(`${t}`,(async()=>{const t=(0,P.o)(n.src,"",n.params);(0,e.J6)(t,n.tgt.map((t=>[t.seq,t.name])))}))})),(0,e.L1)("PolyTool: Chain: parseNotation",(()=>{let t;(0,e.gM)((async()=>{t=await(0,T.b2)()}));const n={cyclized:{src:{seq:"R-F-C(1)-T-G-H-F-Y-P-C(1)-meI"},tgt:{helm:"PEPTIDE1{R.F.[C(1)].T.G.H.F.Y.P.[C(1)].[meI]}$$$$V2.0"}},dimerized1:{src:{seq:"(#2)Succ-{A(CHOL)-F-C(2)-T-G-H-Y-P-C(2)-NH2}"},tgt:{helm:"PEPTIDE1{[(#2)Succ]}|PEPTIDE2{[A(CHOL)].F.[C(2)].T.G.H.Y.P.[C(2)].[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0"}},dimerized2:{src:{seq:"($2)Succ-{R-F-C(1)-T-G-H-F-P-C(1)-NH2}($2){A(CHOL)-F-C(1)-T-G-H-F-P-C(1)-NH2}"},tgt:{helm:"PEPTIDE1{[($2)Succ]}|PEPTIDE2{R.F.[C(1)].T.G.H.F.P.[C(1)].[NH2]}|PEPTIDE3{[($2)A(CHOL)].F.[C(1)].T.G.H.F.P.[C(1)].[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0"}}};for(const[r,o]of Object.entries(n))(0,e.t6)(`${r}`,(async()=>{await(0,x.Q4)(["rules_example.json"]);const n=(await E.sW.parseNotation(o.src.seq)).mol,r=t.createHelmWebEditor();r.editor.setMol(n);const i=r.editor.getHelm();(0,e.E3)(i,o.tgt.helm)}),"reaction2"==r?{skipReason:"reverse reaction"}:void 0)}));var O=n(717);(0,e.L1)("toAtomicLevel",(()=>{let n,r,o;(0,e.gM)((async()=>{r=await(0,b.pj)(),n=await _(),o=await(0,O.j)(),await r.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await C(n),await r.loadMonomerLib(!0)})),(0,e.t6)("override",(async()=>{const n=r.getMonomerLib(),i=await S.files.readAsText("tests/polytool-reaction-lib.json"),s=JSON.parse(i).find((t=>"GGaz"===t.symbol));(0,e.E3)(null!=s,!0,"Monomer 'GGaz' not found.");const a={PEPTIDE:{GGaz:s}},u=n.override(a,"test"),c=await(0,d.Q)(),l=t.Column.fromList(t.COLUMN_TYPE.STRING,"helm",["PEPTIDE1{F.P.Y.[GGaz].H.A.A.G.G.A.C}|PEPTIDE2{A.A.A}$PEPTIDE1,PEPTIDE2,4:R4-1:R1|PEPTIDE1,PEPTIDE1,11:R2-4:R3$$$V2.0"]);l.semType=t.SEMTYPE.MACROMOLECULE,l.meta.units=g.Hi.HELM;const f=await c.helmToAtomicLevel(l,!1,!1,u);(0,e.E3)(null!=f.molCol,!0,"Result molCol is null");const h=f.molCol.get(0);(0,e.E3)(!!h,!0,"Molfile is empty");const p=o.get_mol(h);try{const t=p.get_inchi(),n=o.get_inchikey_for_inchi(t);(0,e.E3)(p.get_num_bonds(),103),(0,e.E3)(p.get_num_atoms(),98),(0,e.E3)(n,"XPQUTLNSNIMERR-WKBTUBAPSA-N")}finally{p.delete()}})),(0,e.t6)("getNewMonomer",(async()=>{const t=await(0,O.j)(),n=r.getMonomerLib(),o=(await(0,x.Q4)(["rules_example.json"])).reactionRules.find((t=>"GGaz"==t.name)),[i,s]=(0,E.kl)(t,n,o);(0,e.E3)(i,o.name);const a=t.get_mol(s.molfile);try{const n=a.get_inchi();t.get_inchikey_for_inchi(n),(0,e.E3)(a.get_num_bonds(),18),(0,e.E3)(a.get_num_atoms(),18)}finally{a.delete()}}))}));const S=new s;async function N(n,r,o){const i=await(0,e.N$)({category:n,test:r,testContext:o,verbose:!0});return t.DataFrame.fromObjects(i)}async function L(){await(0,e.Xb)(S,S.getModule("package-test.js"))}})(),sequencetranslator_test=r})();
|
|
2
|
+
var sequencetranslator_test;(()=>{var t={717:(t,e,n)=>{"use strict";n.d(e,{j:()=>o});var r=n(82);async function o(){const t=r.Func.find({package:"Chem",name:"getRdKitModule"});if(0===t.length)throw new Error('Package "Chem" must be installed for getRdKitModule.');return(await t[0].prepare().call()).getOutputParamValue()}},599:(t,e,n)=>{"use strict";n.d(e,{o:()=>r.o});var r=n(869)},124:(t,e,n)=>{"use strict";n.d(e,{b2:()=>i});var r=n(389),o=n(82);async function i(){const t="Helm",e=o.Func.find({package:t,name:"getHelmHelper"});if(0===e.length)throw new Error(`Package '${t}' must be installed for HelmHelper.`);return(await e[0].prepare().call()).getOutputParamValue()}o.JsInputBase,Error,r.input.helmAsync=async function(t,e){return(await i()).createHelmInput(t,e)}},890:(t,e,n)=>{"use strict";n.d(e,{pj:()=>p});var r,o,i,s,a,u,c,l=n(82);n(328);class f{constructor(t,e=!1){if(this._length=0,this._version=0,this._updateLevel=0,this._selectedCount=0,this._selectedCountVersion=-1,this._selectedIndexesVersion=-1,this._versionedName="",this._versionedNameVersion=-1,this.SHRINK_THRESHOLD=256,"number"==typeof t){const n=t,r=f._createBuffer(n);if(e)for(let t=0;t<r.length;t++)r[t]=-1;this._data=r,this._length=n}else{if(!(t instanceof Uint32Array))throw new Error("Invalid constructor");this._data=t,this._length=e}}getRawData(){return this._data}assureGoez(t,e){if(t<0)throw new Error(`${e} should be greater than zero`)}assureInRange(t,e,n,r){if(t<e||t>n)throw new Error(`Argument ${r} (${t}) out of range (${e}, ${n})`)}copy(t,e,n){for(let r=0;r<n;r++)e[r]=t[r]}copyFrom(t){if(this._length!=t._length)throw new Error(`Lengths differ (${this._length} != ${t._length})`);this.copy(t._data,this._data,this.lengthInInts),this._version++}get length(){return this._length}get buffer(){return this._data}set buffer(t){this._data=t,this._version++}get version(){return this._version}set version(t){this._version=t}incrementVersion(t=!0){this._version++}get lengthInInts(){return Math.floor((this._length+31)/32)}get versionedName(){return this._version==this._versionedNameVersion?this._versionedName:""}set versionedName(t){this._versionedName=t,this._versionedNameVersion=this._version}get self(){return this}setLength(t){if(t<0)throw new Error("should be >= 0");if(t==this._length)return;const e=Math.floor((t+31)/32);if(e>this._data.length||e+this.SHRINK_THRESHOLD<this._data.length){const t=new Uint32Array(e);this.copy(this._data,t,e>this._data.length?this._data.length:e),this._data=t}t>this._length&&(this._length%32>0&&(this._data[this.lengthInInts-1]&=(1<<(this._length%32&31))-1),this._data.fill(0,this.lengthInInts,e)),this._length=t,this._version++}static fromAnd(t,e){if(t._length!=e._length)throw new Error(`Lengths differ (${t._length} != ${e._length})`);const n=new f(t._length);n._length=t._length,n._data=f._createBuffer(n._length),n._version=0;const r=t.lengthInInts;for(let o=0;o<r;o++)n._data[o]=t._data[o]&e._data[o];return n}static _createBuffer(t){return new Uint32Array(Math.floor((t+31)/32))}static fromValues(t){const e=new f(t.length);e._version=0;for(let n=0;n<e._length;n++)t[n]&&(e._data[Math.floor(n/32)]|=1<<(n%32&31));return e}static fromSeq(t,e){const n=new f(t);for(let r=0;r<t;++r)n.setBit(r,e(r));return n._version=0,n}static fromString(t){return f.fromSeq(t.length,(e=>"1"==t.charAt(e)))}static fromUint32Array(t,e){const n=new f(t);return n._data=e,n}static fromBytes(t){const e=t.length,n=new f(8*e);n._data=new Uint32Array(Math.floor((e+3)/4)),n._length=8*e;let r=0,o=0;for(;e-o>=4;)n._data[r++]=255&t[o]|(255&t[o+1])<<8|(255&t[o+2])<<16|(255&t[o+3])<<24,o+=4;return e-o==3&&(n._data[r]=(255&t[o+2])<<16),e-o==2&&(n._data[r]|=(255&t[o+1])<<8),e-o==1&&(n._data[r]|=255&t[o]),n._version=0,n}toString(){return`${this._length} bits, ${this.countBits(!0)} set`}equals(t){if(this==t)return!0;if(null==t)return!1;if(this._length!=t._length)return!1;if(0==this._length)return!0;for(let e=0;e<this._data.length-1;e++)if(this._data[e]!=t._data[e])return!1;for(let e=8*(this._data.length-1);e<this._length;e++)if(this.getBit(e)!=t.getBit(e))return!1;return!0}clone(){const t=new f(0,!1);return t._data=Uint32Array.from(this._data),t._length=this._length,t._version=this._version,t}init(t,e){this.setAll(!1,!1);for(let e=0;e<this._length;e++)t(e)&&(this._data[Math.floor(e/32)]|=1<<(e%32&31));return this.incrementVersion(e),this}invert(t=!0){for(let t=0;t<this._data.length;t++)this._data[t]^=-1;this.incrementVersion(t)}setAll(t,e=!1){const n=t?-1:0,r=this.lengthInInts;for(let t=0;t<r;t++)this._data[t]=n;this.incrementVersion(e)}setIndexes(t,e=!0,n=!0,r=!0){n&&this.setAll(!e,!1);for(const n of t)this.setFast(n,e);this.incrementVersion(r)}everyIndex(t,e=!0){for(const n of t)if(this.getBit(n)!=e)return!1;return!0}anyIndex(t,e=!0){for(const n of t)if(this.getBit(n)==e)return!0;return!1}setWhere(t,e=!0,n=!0,r=!0,o=!0){if(n&&o&&this.setAll(!e,!1),o)for(let n=0;n<this._length;n++)t(n)&&this.setFast(n,e);else for(let n=0;n<this._length;n++)this.setFast(n,t(n)?e:!e);this.incrementVersion(r)}getRange(t,e){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length,"to");const n=[];for(let r=t;r<e;++r)n.push(this.getBit(r));return f.fromValues(n)}getRangeAsList(t,e){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length,"to");const n=[];for(let r=t;r<e;++r)n.push(this.getBit(r));return n}setRange(t,e,n,r=!0){this.assureInRange(t,0,this._length-1,"from"),this.assureInRange(e,0,this._length-1,"to");const o=Math.min(t,e),i=Math.max(t,e);if(n)for(let t=o;t<=i;t++)this.setTrue(t);else for(let t=o;t<=i;t++)this.setFalse(t);return this.incrementVersion(r),this}setRandom(t,e,n=!0){if(t<0||t>this._length)throw new Error("n must be >= 0 && <= Count");t>this._length/2&&this.setRandom(this._length-t,!e),this.setAll(!e);for(let n=0;n<t;){const t=Math.floor(Math.random()*this._length);this.getBit(t)!=e&&(this.setFast(t,e),n++)}this.incrementVersion(n)}and(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]&=t._data[e];return this.incrementVersion(e),this}andNot(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");const n=this.lengthInInts;for(let e=0;e<n;e++)this._data[e]&=~t._data[e];return this.incrementVersion(e),this}notAnd(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]=~this._data[e]&t._data[e];return this.incrementVersion(e),this}not(t=!0){for(let t=0,e=this.lengthInInts;t<e;t++)this._data[t]=~this._data[t];return this.incrementVersion(t),this}or(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]|=t._data[e];return this.incrementVersion(e),this}xor(t,e=!0){if(this._length!=t._length)throw new Error("Array lengths differ.");for(let e=0,n=this.lengthInInts;e<n;e++)this._data[e]^=t._data[e];return this.incrementVersion(e),this}insertAt(t,e,n=!1){if(this.assureInRange(t,0,this._length,"pos"),0==e)return;const r=this._length;this.setLength(this._length+e);for(let n=r-1;n>=t;n--)this.setBit(n+e,this.getBit(n));for(let r=t;r<t+e;r++)this.setBit(r,n)}removeAt(t,e=1){if(e<0)throw new Error("n cannot be negative");if(this.assureInRange(t,0,this._length-e,"pos"),this.contains(!0))for(let n=t;n<this._length-e;n++)this.setBit(n,this.getBit(n+e));this.setLength(this._length-e)}removeByMask(t,e=!0){if(this._length!=t.length)throw new Error("length != mask.length");if(t==this)this.setLength(t.countBits(!e)),this.setAll(!e);else{let n=0;for(let r=-1;-1!=(r=t.findNext(r,!e));)this.setFast(n++,this.getBit(r));this._length=n,this._version++}return this}getBit(t){return!!(this._data[Math.floor(t/32)]&1<<(31&t))}setBit(t,e,n=!0){this.setFast(t,e),this._version++}setFast(t,e){e?this._data[Math.floor(t/32)]|=1<<(31&t):this._data[Math.floor(t/32)]&=~(1<<(31&t))}setTrue(t){this._data[Math.floor(t/32)]|=1<<(31&t)}setFalse(t){this._data[Math.floor(t/32)]&=~(1<<(31&t))}trueCount(){return this.countBits(!0)}falseCount(){return this.countBits(!1)}countBits(t){if(0==this._length)return 0;if(this._selectedCountVersion!=this._version){this._selectedCount=0;const t=this.lengthInInts;let e=0;for(;e<t-1;e++)for(let t=this._data[e];0!=t;t>>>=8)this._selectedCount+=f._onBitCount[255&t];let n=this._data[e];const r=31&this._length;for(0!=r&&(n&=~(4294967295<<r));0!=n;n>>>=8)this._selectedCount+=f._onBitCount[255&n];this._selectedCountVersion=this._version}return t?this._selectedCount:this._length-this._selectedCount}countWhere(t){let e=0;if(this.trueCount()==this._length)for(let n=0;n<this._length;n++)e+=t(n)?1:0;else for(let n=-1;-1!=(n=this.findNext(n,!0));)e+=t(n)?1:0;return e}andWithCountBits(t,e){if(0==this._length)return 0;let n=0;const r=this.lengthInInts;let o=0;for(;o<r-1;o++)for(let e=this._data[o]&t._data[o];0!=e;e>>>=8)n+=f._onBitCount[255&e];let i=this._data[o]&t._data[o];const s=31&this._length;for(0!=s&&(i&=~(4294967295<<s));0!=i;i>>>=8)n+=f._onBitCount[255&i];return e?n:this._length-n}clear(){this.setLength(0)}contains(t){return this.findNext(-1,t)>=0}get allTrue(){return this.countBits(!0)==this._length}get allFalse(){return this.countBits(!1)==this._length}get anyTrue(){return this.countBits(!0)>0}get anyFalse(){return this.countBits(!1)>0}findNext(t,e=!0){if(this.assureInRange(t,-1,this._length,"index"),t>=this._length-1)return-1;let n=31&(t=t<0?0:t+1);const r=this.lengthInInts;for(let o=Math.floor(t/32);o<r;o++){let r=e?this._data[o]:~this._data[o];if(0!=n)r&=4294967295<<n&4294967295,n=0;else if(!e&&-4294967296==r)continue;for(let e=0;0!=r;e+=8,r>>>=8){const n=f._firstOnBit[255&r];if(n>=0)return(t=n+32*o+e)>=this._length?-1:t}}return-1}findPrev(t,e=!0){if(0==t)return-1;this.assureInRange(t,-1,this._length,"index");let n=1+(t=t<0?this._length-1:t-1)&31;for(let r=Math.floor(t/32);r>=0;r--){let t=e?this._data[r]:~this._data[r];0!=n&&(t&=~(4294967295<<n),n=0);for(let e=24;0!=t;e-=8,t<<=8){const n=f._lastOnBit[t>>>24];if(n>=0)return n+32*r+e}}return-1}}f._onBitCount=Int8Array.from([0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,1,2,2,3,2,3,3,4,2,3,3,4,3,4,4,5,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,2,3,3,4,3,4,4,5,3,4,4,5,4,5,5,6,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,3,4,4,5,4,5,5,6,4,5,5,6,5,6,6,7,4,5,5,6,5,6,6,7,5,6,6,7,6,7,7,8]),f._firstOnBit=Int8Array.from([-1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0]),f._lastOnBit=Int8Array.from([-1,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7]),function(t){t.Levenshtein="Levenshtein",t.JaroWinkler="Jaro-Winkler",t.Manhattan="Manhattan",t.Onehot="One-Hot"}(r||(r={})),function(t){t.Euclidean="Euclidean"}(o||(o={})),function(t){t.Tanimoto="Tanimoto",t.Dice="Dice",t.Asymmetric="Asymmetric",t.BraunBlanquet="Braun-Blanquet",t.Cosine="Cosine",t.Kulczynski="Kulczynski",t.McConnaughey="Mc-Connaughey",t.RogotGoldberg="Rogot-Goldberg",t.Russel="Russel",t.Sokal="Sokal",t.Hamming="Hamming",t.Euclidean="Euclidean"}(i||(i={})),function(t){t.TanimotoIntArray="TanimotoIntArray"}(s||(s={})),function(t){t.Vector="Vector",t.String="String",t.BitArray="BitArray",t.MacroMolecule="MacroMolecule",t.Number="Number",t.IntArray="IntArray",t.NumberArray="NumberArray"}(a||(a={})),function(t){t.Difference="Difference"}(u||(u={})),function(t){t.CommonItems="Common Items"}(c||(c={}));new Uint32Array(65536);var h;async function p(){const t=l.Func.find({package:"Bio",name:"getMonomerLibHelper"});if(0===t.length)throw new Error('Package "Bio" must be installed for MonomerLibHelper.');return(await t[0].prepare().call()).getOutputParamValue()}!function(t){t.HAMMING="Hamming",t.LEVENSHTEIN="Levenshtein",t.NEEDLEMANN_WUNSCH="Needlemann-Wunsch",t.MONOMER_CHEMICAL_DISTANCE="Monomer chemical distance"}(h||(h={})),h.HAMMING,h.LEVENSHTEIN,h.NEEDLEMANN_WUNSCH,h.MONOMER_CHEMICAL_DISTANCE,i.Tanimoto,i.Dice,i.Asymmetric,i.BraunBlanquet,i.Cosine,i.Kulczynski,i.McConnaughey,i.RogotGoldberg,i.Russel,i.Sokal,i.Hamming,i.Euclidean,i.Tanimoto,i.Dice,i.Asymmetric,i.BraunBlanquet,i.Cosine,i.Kulczynski,i.McConnaughey,i.RogotGoldberg,i.Russel,i.Sokal,i.Hamming,i.Euclidean,i.Tanimoto,i.Dice,i.Cosine,i.Tanimoto,i.Asymmetric,i.Cosine,i.Sokal,h.HAMMING,h.LEVENSHTEIN,h.MONOMER_CHEMICAL_DISTANCE,h.NEEDLEMANN_WUNSCH,n(151),n(439)},151:(t,e,n)=>{"use strict";new RegExp("[rd]\\((\\w)\\)p?","g")},192:(t,e,n)=>{"use strict";function r(t){return"string"==typeof t||t instanceof String?t:"StateError"===t.constructor.name?t.message:"StateError"===t.constructor.name&&"$thrownJsError"in t?r(t.$thrownJsError):t instanceof Error?t.message:t.toString()}function o(t){return t instanceof Error?t.stack:"StateError"===t.constructor.name&&"$thrownJsError"in t?o(t.$thrownJsError):void 0}function i(t){return[r(t),o(t)]}n.d(e,{AP:()=>i})},439:(t,e,n)=>{"use strict";n.d(e,{Hi:()=>r,YI:()=>o,_S:()=>u,gp:()=>i});var r,o,i,s=n(738);!function(t){t.FASTA="fasta",t.SEPARATOR="separator",t.HELM="helm",t.CUSTOM="custom"}(r||(r={})),function(t){t.DNA="DNA",t.RNA="RNA",t.PT="PT",t.UN="UN"}(o||(o={})),function(t){t.aligned="aligned",t.alphabet="alphabet",t.alphabetSize=".alphabetSize",t.alphabetIsMultichar=".alphabetIsMultichar",t.separator="separator",t.isHelmCompatible=".isHelmCompatible",t.positionNames=".positionNames",t.positionLabels=".positionLabels",t.regions=".regions"}(i||(i={}));const a=new class{constructor(){this.fasta={peptide:new Set(["G","L","Y","S","E","Q","D","N","F","A","K","R","H","C","V","P","W","I","M","T"]),dna:new Set(["A","C","G","T"]),rna:new Set(["A","C","G","U"])}}},u=(new s.a(o.PT,a.fasta.peptide,.5),new s.a(o.DNA,a.fasta.dna,.55),new s.a(o.RNA,a.fasta.rna,.55),"");r.FASTA,r.SEPARATOR,r.HELM},3:(t,e,n)=>{"use strict";n.d(e,{Hi:()=>r.Hi,YI:()=>r.YI,gp:()=>r.gp});var r=n(439);n(291)},738:(t,e,n)=>{"use strict";n.d(e,{a:()=>r});class r{constructor(t,e,n){this.name=t,this.alphabet=e,this.cutoff=n}}},291:(t,e,n)=>{"use strict";n.d(e,{Mu:()=>d,zS:()=>m});var r=n(82),o=(n(991),n(738),n(439));class i{static makePalette(t,e=!1,n=i){const r={};return t.forEach((t=>{const n=t[0],o=t[1];n.forEach(((t,n)=>{r[t]=this.colourPalette[o][e?0:n]}))})),new n(r)}constructor(t){this._palette=t}get(t,e){return this._palette[t]}}i.undefinedColor="rgb(100,100,100)",i.colourPalette={orange:["rgb(255,187,120)","rgb(245,167,100)","rgb(235,137,70)","rgb(205, 111, 71)"],all_green:["rgb(44,160,44)","rgb(74,160,74)","rgb(23,103,57)","rgb(30,110,96)","rgb(60,131,95)","rgb(24,110,79)","rgb(152,223,138)","rgb(182, 223, 138)","rgb(152, 193, 138)"],all_blue:["rgb(31,119,180)","rgb(23,190,207)","rgb(122, 102, 189)","rgb(158,218,229)","rgb(141, 124, 217)","rgb(31, 120, 150)"],magenta:["rgb(162,106,192)","rgb(197,165,224)","rgb(208,113,218)"],red:["rgb(214,39,40)","rgb(255,152,150)"],st_blue:["rgb(23,190,207)","rgb(158,218,229)","rgb(31,119,180)"],dark_blue:["rgb(31,119,180)","rgb(31, 120, 150)"],light_blue:["rgb(23,190,207)","rgb(158,218,229)","rgb(108, 218, 229)","rgb(23,190,227)"],lilac_blue:["rgb(124,102,211)","rgb(149,134,217)","rgb(97, 81, 150)"],dark_green:["rgb(23,103,57)","rgb(30,110,96)","rgb(60,131,95)","rgb(24,110,79)"],green:["rgb(44,160,44)","rgb(74,160,74)"],light_green:["rgb(152,223,138)","rgb(182, 223, 138)","rgb(152, 193, 138)"],st_green:["rgb(44,160,44)","rgb(152,223,138)","rgb(39, 174, 96)","rgb(74,160,74)"],pink:["rgb(247,182,210)"],brown:["rgb(140,86,75)","rgb(102, 62, 54)"],gray:["rgb(127,127,127)","rgb(199,199,199)","rgb(196,156,148)","rgb(222, 222, 180)"],yellow:["rgb(188,189,34)"],white:["rgb(230,230,230)"]};class s extends i{static get Lesk(){return void 0===this.lesk&&(this.lesk=this.makePalette([[["G","A","S","T"],"orange"],[["C","V","I","L","P","F","Y","M","W"],"all_green"],[["N","Q","H"],"magenta"],[["D","E"],"red"],[["K","R"],"all_blue"]],!1,s)),this.lesk}static get GrokGroups(){return void 0===this.grokGroups&&(this.grokGroups=this.makePalette([[["C","U"],"yellow"],[["G","P"],"red"],[["A","V","I","L","M","F","Y","W"],"all_green"],[["R","H","K"],"light_blue"],[["D","E"],"dark_blue"],[["S","T","N","Q"],"orange"]],!1,s)),this.grokGroups}static get RasMol(){return void 0===this.rasMol&&(this.rasMol=new s({D:"#E60A0A",E:"#E60A0A",C:"#E6E600",M:"#E6E600",K:"#145AFF",R:"#145AFF",S:"#FA9600",T:"#FA9600",F:"#3232AA",Y:"#3232AA",N:"#00DCDC",Q:"#00DCDC",G:"#EBEBEB",L:"#0F820F",V:"#0F820F",I:"#0F820F",A:"#C8C8C8",W:"#B45AB4",H:"#8282D2",P:"#DC9682",others:"#BEA06E"})),this.rasMol}get(t){const e=t in s.aaSynonyms?s.aaSynonyms[t]:t;return super.get(e)}}s.aaSynonyms={MeNle:"L",MeA:"A",MeG:"G",MeF:"F"};class a{static getPalette(t="grok"){switch(t){case"grok":return s.GrokGroups;case"lesk":return s.Lesk;default:throw new Error(`ChemPalette: scheme \`${t}\` does not exist`)}}static getInnerOuter(t){let e=0,n="",r="";for(const o of t)"("==o?e++:")"==o?e--:e?n+=o:r+=o;return isNaN(parseInt(n))?[r,n]:[r,""]}static getColorAAPivot(t="",e="grok"){const n=this.getPalette(e);let[r,o]=this.getInnerOuter(t);if(r=r.length>6?`${r.slice(0,3)}...`:r,o=o.length>6?`${o.slice(0,3)}...`:o,1==t.length||"("==t[1]){const e=t[0]?.toUpperCase();return e in n?[n.get(e),e,o,1]:[this.undefinedColor,r,o,1]}if("d"==t[0]&&t[1]in n&&(2==t.length||"("==t[2])){const e=t[1]?.toUpperCase();return e in n?[n.get(e),e,o,2]:[this.undefinedColor,r,o,2]}if(t.substring(0,3)in this.AAFullNames&&(3==t.length||"("==t[3])){const e=this.AAFullNames[t.substring(0,3)];return e in n?[n.get(e),e,o,3]:[this.undefinedColor,r,o,3]}if(t[0]?.toLowerCase()==t[0]&&t.substring(1,3)in this.AAFullNames&&(4==t.length||"("==t[4])){const e=this.AAFullNames[t.substring(1,3)];return e in n?[n.get(e),e,o,4]:[this.undefinedColor,r,o,4]}return[this.undefinedColor,r,o,0]}}a.SemType="Aminoacids",a.SemTypeMultipleAlignment="AminoacidsMultipleAlignment",a.undefinedColor="rgb(100,100,100)",a.Names={G:"Glycine",L:"Leucine",Y:"Tyrosine",S:"Serine",E:"Glutamic acid",Q:"Glutamine",D:"Aspartic acid",N:"Asparagine",F:"Phenylalanine",A:"Alanine",K:"Lysine",R:"Arginine",H:"Histidine",C:"Cysteine",V:"Valine",P:"Proline",W:"Tryptophan",I:"Isoleucine",M:"Methionine",T:"Threonine"},a.AASmiles={G:"NCC(=O)O",L:"N[C@H](CC(C)C)C(=O)O",Y:"NC(CC1=CC=C(O)C=C1)C(=O)O",S:"NC(CO)C(=O)O",E:"N[C@@H](CCC(O)=O)C(=O)O",Q:"N[C@@H](CCC(N)=O)C(=O)O",D:"N[C@@H](CC(O)=O)C(=O)O",N:"N[C@@H](CC(N)=O)C(=O)O",F:"NC(CC1=CC=CC=C1)C(=O)O",A:"N[C@H](C)C(=O)O",K:"NC(CCCCN)C(=O)O",R:"N[C@H](CCCNC(=N)C)C(=O)O",H:"NC(CC1=CN=C[N]1)C(=O)O",C:"N[C@@H](CS)C(=O)O",V:"NC(C(C)C)C(=O)O",P:"N(CCC1)C1C(=O)O",W:"N[C@@H](Cc1c2ccccc2n([H])c1)C(=O)O",I:"N[C@H]([C@H](C)CC)C(=O)O",M:"NC(CCSC)C(=O)O",T:"NC(C(O)C)C(=O)O"},a.AASmilesTruncated={G:"*C*",L:"CC(C)C[C@H](*)*",Y:"C1=CC(=CC=C1CC(*)*)O",S:"OCC(*)C*",E:"*[C@@H](CCC(O)=O)*",Q:"*N[C@@H](CCC(N)=O)*",D:"*[C@@H](CC(O)=O)*",N:"*[C@@H](CC(N)=O)*",F:"C1=CC=C(C=C1)CC(*)*",A:"C[C@H](*)*",K:"C(CCN)CC(*)*",R:"*[C@H](CCCNC(=N)C)*",H:"C1=C(NC=N1)CC(*)*",C:"C([C@@H](*)*)S",V:"CC(C)C(*)*",P:"C1CCN(*)C1*",W:"*[C@@H](Cc1c2ccccc2n([H])c1)*",I:"CC[C@H](C)[C@H](*)*",M:"CSCCC(*)*",T:"CC(O)C(*)*"},a.AAFullNames={Ala:"A",Arg:"R",Asn:"N",Asp:"D",Cys:"C",Gln:"Q",Glu:"E",Gly:"G",His:"H",Ile:"I",Leu:"L",Lys:"K",Met:"M",Phe:"F",Pro:"P",Ser:"S",Thr:"T",Trp:"W",Tyr:"Y",Val:"V"};class u{}u.SemType="Nucleotides",u.SemTypeMultipleAlignment="NucleotidesMultipleAlignment",u.Names={A:"Adenine",C:"Cytosine",G:"Guanine",T:"Thymine",U:"Uracil"};var c=n(890);function l(t,e=!0){if(null==t)return"rgb(100,100,100)";const n=r.Color.fromHtml(t);if(e){const t=r.Color.g(n),e=r.Color.r(n),o=r.Color.b(n),i=Math.sqrt(Math.pow(0-e,2)+Math.pow(0-t,2)+Math.pow(0-o,2));if(i>210)return`rgb(${e/i*210},${t/i*210},${o/i*210})`}return r.Color.toRgb(n)}class f{static hashCode(t){let e=0;if(0===t.length)return e;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n),e|=0;return e}}class h{}class p extends h{static buildPalette(){return(0,c.pj)().then((t=>{t.awaitLoaded(1/0).then((()=>{const e=t.getMonomerLib();e.onChanged.subscribe((()=>{p.customMonomerColors={},p.polymerTypes=e.getPolymerTypes();for(const t of this.polymerTypes){const n=e.getMonomerSymbolsByType(t);for(const r of n){const n=e.getMonomer(t,r);n?.meta?.colors?.default?.background&&(this.customMonomerColors[r]||(this.customMonomerColors[r]={}),this.customMonomerColors[r][t]=l(n.meta.colors.default.background))}}}))}))})),[].concat(...Object.values(i.colourPalette))}get(t,e){const n=p.customMonomerColors[t],r=e??"PEPTIDE";if(n&&n[r])return n[r];const o=f.hashCode(t)%p.palette.length;return l(p.palette[o])}}p.palette=p.buildPalette(),p.customMonomerColors={},p.polymerTypes=[];class d{get length(){return this.mList.length}isGap(t){return this.getOriginal(t)===this.gapOriginalMonomer}getCanonical(t){if(this.length<=t)throw new Error("Index out of bounds");const e=this.mList[t];return e!==this.gapOriginalMonomer?e:o._S}getOriginal(t){if(this.length<=t)throw new Error("Index out of bounds");return this.mList[t]}constructor(t,e){this.mList=t,this.gapOriginalMonomer=e}}const g=/([^\W_]+)/g;function m(t,e){if(t.length<=e)return t;const n=t.match(g),r=t.length>e||(n?.length??0)>1,o=n?.[0]??" ";return r?o.substring(0,e-1)+"…":o}},312:(t,e,n)=>{"use strict";n.d(e,{Q:()=>o});var r=n(82);async function o(){const t=r.Func.find({package:"Bio",name:"getSeqHelper"});if(0===t.length)throw new Error("Package 'Bio' must be installed for SeqHelper.");return(await t[0].prepare().call()).getOutputParamValue()}},869:(t,e,n)=>{"use strict";var r;n.d(e,{o:()=>r}),function(t){t.BASE="HELM_BASE",t.SUGAR="HELM_SUGAR",t.LINKER="HELM_LINKER",t.AA="HELM_AA",t.CHEM="HELM_CHEM",t.BLOB="HELM_BLOB",t.NUCLEOTIDE="HELM_NUCLETIDE"}(r||(r={}))},70:(t,e,n)=>{"use strict";n.d(e,{Pl:()=>N,gM:()=>O,L1:()=>S,E3:()=>x,J6:()=>P,Xk:()=>I,Xb:()=>$,N$:()=>M,t6:()=>_,PE:()=>E,CN:()=>p});var r=n(328),o=n(82);n(982);const i=o.DataFrame.fromCsv('countries,fasta,smiles,molregno,LON,Zip Code,Street Address Line 1,ImageUrl,user_id,error_message,xray,flag,magnitude,CS-id,pdb_id,accel_a,time_offset,chart,fit,Questions,empty_number,empty_string\nBelgium,MSNFHNEHVMQFYRNNLKTKGVFGRQ,CC(C(=O)OCCCc1cccnc1)c2cccc(c2)C(=O)c3ccccc3,1480014,36.276729583740234,995042300,14016 ROUTE 31W,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,1,1,1QBS,1,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.497360340644872, 1.7058694986686864, 5.278052678195135, 0.16000320889028383],""points"":[{""x"":0.10000000149011612,""y"":2.374499797821045},{""x"":0.6000000238418579,""y"":2.6242473125457764},{""x"":1.100000023841858,""y"":2.367267608642578},{""x"":1.600000023841858,""y"":2.6723148822784424},{""x"":2.0999999046325684,""y"":2.6537344455718994},{""x"":2.5999999046325684,""y"":2.3651671409606934},{""x"":3.0999999046325684,""y"":2.5654284954071045},{""x"":3.5999999046325684,""y"":2.4160959720611572},{""x"":4.099999904632568,""y"":2.286726713180542},{""x"":4.599999904632568,""y"":2.5100042819976807},{""x"":5.099999904632568,""y"":1.6676985025405884},{""x"":5.599999904632568,""y"":0.680136501789093},{""x"":6.099999904632568,""y"":0.3391543924808502},{""x"":6.599999904632568,""y"":0.09038983285427094},{""x"":7.099999904632568,""y"":0.19802775979042053}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[7.525235855508179, 1.3186911876809984, 5.335672608564294, 0.7860743343958098],""points"":[{""x"":0.10000000149011612,""y"":7.988070487976074},{""x"":0.6000000238418579,""y"":7.018453121185303},{""x"":1.100000023841858,""y"":8.115279197692871},{""x"":1.600000023841858,""y"":7.486658096313477},{""x"":2.0999999046325684,""y"":7.396438121795654},{""x"":2.5999999046325684,""y"":7.477052211761475},{""x"":3.0999999046325684,""y"":6.913095474243164},{""x"":3.5999999046325684,""y"":8.01385498046875},{""x"":4.099999904632568,""y"":6.985900402069092},{""x"":4.599999904632568,""y"":6.970335960388184},{""x"":5.099999904632568,""y"":5.448817253112793},{""x"":5.599999904632568,""y"":2.5534818172454834},{""x"":6.099999904632568,""y"":1.893947958946228},{""x"":6.599999904632568,""y"":0.6340042352676392},{""x"":7.099999904632568,""y"":0.8403874039649963}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,100,abc\nBurundi,MDYKETLLMPKTDFPMRGGLPNKEPQIQEKW,COc1ccc2cc(ccc2c1)C(C)C(=O)Oc3ccc(C)cc3OC,1480015,36.276729583740234,995073444,80 STATE HIGHWAY 310,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,2,2,1ZP8,2,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[4.431460753103398, 2.1691498799246745, 5.266445597102774, 0.7825762827017926],""points"":[{""x"":0.10000000149011612,""y"":4.751083850860596},{""x"":0.6000000238418579,""y"":4.203000068664551},{""x"":1.100000023841858,""y"":4.415858745574951},{""x"":1.600000023841858,""y"":4.68414306640625},{""x"":2.0999999046325684,""y"":4.198400974273682},{""x"":2.5999999046325684,""y"":4.179222106933594},{""x"":3.0999999046325684,""y"":4.638473987579346},{""x"":3.5999999046325684,""y"":4.708553314208984},{""x"":4.099999904632568,""y"":4.291589260101318},{""x"":4.599999904632568,""y"":4.038082599639893},{""x"":5.099999904632568,""y"":3.4349939823150635},{""x"":5.599999904632568,""y"":1.2194708585739136},{""x"":6.099999904632568,""y"":1.1920831203460693},{""x"":6.599999904632568,""y"":0.5352635979652405},{""x"":7.099999904632568,""y"":0.3346920311450958}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[2.339458017970126, -1.0734184310171178, 4.746332950550934, 0.2482416857595658],""points"":[{""x"":0.10000000149011612,""y"":0.2139337658882141},{""x"":0.6000000238418579,""y"":0.4269562065601349},{""x"":1.100000023841858,""y"":0.2441573292016983},{""x"":1.600000023841858,""y"":0.146635964512825},{""x"":2.0999999046325684,""y"":0.08818462491035461},{""x"":2.5999999046325684,""y"":0.2560656666755676},{""x"":3.0999999046325684,""y"":0.42434045672416687},{""x"":3.5999999046325684,""y"":0.37111231684684753},{""x"":4.099999904632568,""y"":0.5581737160682678},{""x"":4.599999904632568,""y"":1.183590054512024},{""x"":5.099999904632568,""y"":1.5629843473434448},{""x"":5.599999904632568,""y"":2.3211288452148438},{""x"":6.099999904632568,""y"":2.229961633682251},{""x"":6.599999904632568,""y"":2.2560226917266846},{""x"":7.099999904632568,""y"":2.2142398357391357}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCameroon,MIEVFLFGIVLGLIPITLAGLFVTAYLQYRRGDQLDL,COc1ccc2cc(ccc2c1)C(C)C(=O)OCCCc3cccnc3,1480016,36.26095962524414,995153596,30-56 WHITESTONE EXPY,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,3,3,2BDJ,3,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[4.6760652578642325, 0.9046956320756703, 5.651408971856738, 0.07738846012184185],""points"":[{""x"":0.10000000149011612,""y"":4.32425594329834},{""x"":0.6000000238418579,""y"":4.668442249298096},{""x"":1.100000023841858,""y"":4.379785060882568},{""x"":1.600000023841858,""y"":5.0345139503479},{""x"":2.0999999046325684,""y"":4.878653526306152},{""x"":2.5999999046325684,""y"":4.3451313972473145},{""x"":3.0999999046325684,""y"":4.336992263793945},{""x"":3.5999999046325684,""y"":5.037430286407471},{""x"":4.099999904632568,""y"":5.0092692375183105},{""x"":4.599999904632568,""y"":4.151902675628662},{""x"":5.099999904632568,""y"":3.4066951274871826},{""x"":5.599999904632568,""y"":2.3732759952545166},{""x"":6.099999904632568,""y"":1.673728108406067},{""x"":6.599999904632568,""y"":0.48574790358543396},{""x"":7.099999904632568,""y"":0.2783052325248718}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[2.938395863010111, -1.4658480661392117, 5.462702751996584, 0.3473139023615039],""points"":[{""x"":0.10000000149011612,""y"":0.4941710829734802},{""x"":0.6000000238418579,""y"":0.15323974192142487},{""x"":1.100000023841858,""y"":0.46373432874679565},{""x"":1.600000023841858,""y"":0.3370431363582611},{""x"":2.0999999046325684,""y"":0.5179030299186707},{""x"":2.5999999046325684,""y"":0.27899765968322754},{""x"":3.0999999046325684,""y"":0.22075064480304718},{""x"":3.5999999046325684,""y"":0.5789918899536133},{""x"":4.099999904632568,""y"":0.21169911324977875},{""x"":4.599999904632568,""y"":0.27857646346092224},{""x"":5.099999904632568,""y"":1.0906332731246948},{""x"":5.599999904632568,""y"":1.8520300388336182},{""x"":6.099999904632568,""y"":2.7177059650421143},{""x"":6.599999904632568,""y"":2.8680918216705322},{""x"":7.099999904632568,""y"":3.2413077354431152}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCanada,MMELVLKTIIGPIVVGVVLRIVDKWLNKDK,CC(C(=O)NCCS)c1cccc(c1)C(=O)c2ccccc2,1480017,36.26095962524414,99515,30-56 WHITESTONE EXPY,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,4,4,1IAN,4,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[0.8597390975430008, 1.0957625732481946, 5.260537067987958, 0.07974187998177736],""points"":[{""x"":0.10000000149011612,""y"":0.8190152645111084},{""x"":0.6000000238418579,""y"":0.8421689867973328},{""x"":1.100000023841858,""y"":0.8740922212600708},{""x"":1.600000023841858,""y"":0.8924275040626526},{""x"":2.0999999046325684,""y"":0.8249067664146423},{""x"":2.5999999046325684,""y"":0.9327669143676758},{""x"":3.0999999046325684,""y"":0.8522974252700806},{""x"":3.5999999046325684,""y"":0.8174492716789246},{""x"":4.099999904632568,""y"":0.8394647240638733},{""x"":4.599999904632568,""y"":0.7139387726783752},{""x"":5.099999904632568,""y"":0.5561167597770691},{""x"":5.599999904632568,""y"":0.3276226818561554},{""x"":6.099999904632568,""y"":0.12479474395513535},{""x"":6.599999904632568,""y"":0.13006797432899475},{""x"":7.099999904632568,""y"":0.059702079743146896}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.760930219582546, 1.6591793293833013, 4.667155929720851, 0.7858109544121652],""points"":[{""x"":0.10000000149011612,""y"":6.156993389129639},{""x"":0.6000000238418579,""y"":5.236701965332031},{""x"":1.100000023841858,""y"":6.010560512542725},{""x"":1.600000023841858,""y"":5.495512962341309},{""x"":2.0999999046325684,""y"":6.087770462036133},{""x"":2.5999999046325684,""y"":5.79986572265625},{""x"":3.0999999046325684,""y"":5.597546577453613},{""x"":3.5999999046325684,""y"":5.520902156829834},{""x"":4.099999904632568,""y"":5.360654354095459},{""x"":4.599999904632568,""y"":3.5539746284484863},{""x"":5.099999904632568,""y"":1.577236294746399},{""x"":5.599999904632568,""y"":1.0001264810562134},{""x"":6.099999904632568,""y"":0.9305797815322876},{""x"":6.599999904632568,""y"":0.6033638715744019},{""x"":7.099999904632568,""y"":0.4203685522079468}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nColombia,MDRTDEVSNHTHDKPTLTWFEEIFEEYHSPFHN,FC(F)(F)c1ccc(OC2CCNCC2)cc1,1480029,36.3309440612793,995152050,1 COURT HOUSE SQUARE,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,5,5,4UJ1,5,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[6.4995088314153655, 2.4270351004539914, 5.178659535348579, 0.625653346241577],""points"":[{""x"":0.10000000149011612,""y"":6.496231555938721},{""x"":0.6000000238418579,""y"":6.42543363571167},{""x"":1.100000023841858,""y"":7.040063858032227},{""x"":1.600000023841858,""y"":6.1115403175354},{""x"":2.0999999046325684,""y"":6.680728435516357},{""x"":2.5999999046325684,""y"":6.406774520874023},{""x"":3.0999999046325684,""y"":6.611269474029541},{""x"":3.5999999046325684,""y"":5.889094352722168},{""x"":4.099999904632568,""y"":6.75344705581665},{""x"":4.599999904632568,""y"":6.361435890197754},{""x"":5.099999904632568,""y"":4.1666975021362305},{""x"":5.599999904632568,""y"":1.172118902206421},{""x"":6.099999904632568,""y"":0.801048994064331},{""x"":6.599999904632568,""y"":0.4640021026134491},{""x"":7.099999904632568,""y"":0.0010357667924836278}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[1.4734381347446401, 1.1649805188074196, 4.82958608866421, 0.09500545496710007],""points"":[{""x"":0.10000000149011612,""y"":1.5279096364974976},{""x"":0.6000000238418579,""y"":1.3559974431991577},{""x"":1.100000023841858,""y"":1.5246378183364868},{""x"":1.600000023841858,""y"":1.5567657947540283},{""x"":2.0999999046325684,""y"":1.4114240407943726},{""x"":2.5999999046325684,""y"":1.4045010805130005},{""x"":3.0999999046325684,""y"":1.4769829511642456},{""x"":3.5999999046325684,""y"":1.4875500202178955},{""x"":4.099999904632568,""y"":1.2991987466812134},{""x"":4.599999904632568,""y"":0.922961413860321},{""x"":5.099999904632568,""y"":0.6520044803619385},{""x"":5.599999904632568,""y"":0.15350978076457977},{""x"":6.099999904632568,""y"":0.1078903079032898},{""x"":6.599999904632568,""y"":0.17276449501514435},{""x"":7.099999904632568,""y"":0.14066608250141144}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCosta Rica,MKSTKEEIQTIKTLLKDSRTAKYHKRLQIVL,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCCc3ccccc3,1480018,36.3309440612793,995084218,4041 SOUTHWESTERN BLVD,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,6,6,2BPW,6,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.4833641843311227, -1.8945978742090062, 4.671127708092568, 0.24159861311815153],""points"":[{""x"":0.10000000149011612,""y"":0.0969524160027504},{""x"":0.6000000238418579,""y"":0.028483040630817413},{""x"":1.100000023841858,""y"":0.22087176144123077},{""x"":1.600000023841858,""y"":0.0068915546871721745},{""x"":2.0999999046325684,""y"":0.4305879771709442},{""x"":2.5999999046325684,""y"":0.44774115085601807},{""x"":3.0999999046325684,""y"":0.45346319675445557},{""x"":3.5999999046325684,""y"":0.2370593100786209},{""x"":4.099999904632568,""y"":0.4657953977584839},{""x"":4.599999904632568,""y"":1.155200719833374},{""x"":5.099999904632568,""y"":2.2294070720672607},{""x"":5.599999904632568,""y"":2.4311530590057373},{""x"":6.099999904632568,""y"":2.33846116065979},{""x"":6.599999904632568,""y"":2.608201026916504},{""x"":7.099999904632568,""y"":2.8136143684387207}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.224573521642033, 1.4454033924198528, 5.6014197746076535, 0.2823216054197577],""points"":[{""x"":0.10000000149011612,""y"":4.95027494430542},{""x"":0.6000000238418579,""y"":5.1754679679870605},{""x"":1.100000023841858,""y"":5.276752948760986},{""x"":1.600000023841858,""y"":5.589294910430908},{""x"":2.0999999046325684,""y"":5.616994857788086},{""x"":2.5999999046325684,""y"":5.120813846588135},{""x"":3.0999999046325684,""y"":5.340766906738281},{""x"":3.5999999046325684,""y"":4.876471042633057},{""x"":4.099999904632568,""y"":4.94999361038208},{""x"":4.599999904632568,""y"":5.162564754486084},{""x"":5.099999904632568,""y"":4.399557590484619},{""x"":5.599999904632568,""y"":2.7977969646453857},{""x"":6.099999904632568,""y"":1.0229872465133667},{""x"":6.599999904632568,""y"":0.48275601863861084},{""x"":7.099999904632568,""y"":0.10408931970596313}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nCuba,MHAILRYFIRRLFYHIFYKIYSLISKKHQSLPSDVRQF,COc1ccc2c(c1)c(CC(=O)N3CCCC3C(=O)Oc4ccc(C)cc4OC)c(C)n2C(=O)c5ccc(Cl)cc5,1480019,36.33115768432617,995081928,1227 US HIGHWAY 11,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,7,7,1QBS,7,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[3.320838679713925, -1.2421619987316728, 4.831325425225256, 0.3236011098403072],""points"":[{""x"":0.10000000149011612,""y"":0.3727470338344574},{""x"":0.6000000238418579,""y"":0.12365014106035233},{""x"":1.100000023841858,""y"":0.48422467708587646},{""x"":1.600000023841858,""y"":0.2264465093612671},{""x"":2.0999999046325684,""y"":0.16821794211864471},{""x"":2.5999999046325684,""y"":0.3879014551639557},{""x"":3.0999999046325684,""y"":0.5470244884490967},{""x"":3.5999999046325684,""y"":0.3419053554534912},{""x"":4.099999904632568,""y"":0.7655120491981506},{""x"":4.599999904632568,""y"":1.2346516847610474},{""x"":5.099999904632568,""y"":2.453336715698242},{""x"":5.599999904632568,""y"":2.9565491676330566},{""x"":6.099999904632568,""y"":3.335299491882324},{""x"":6.599999904632568,""y"":3.240290880203247},{""x"":7.099999904632568,""y"":3.1107218265533447}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[3.6401853521511094, 1.26211588875013, 5.399028074402744, 0.5089580830068091],""points"":[{""x"":0.10000000149011612,""y"":3.8585598468780518},{""x"":0.6000000238418579,""y"":3.6077206134796143},{""x"":1.100000023841858,""y"":3.855252265930176},{""x"":1.600000023841858,""y"":3.619039297103882},{""x"":2.0999999046325684,""y"":3.839388370513916},{""x"":2.5999999046325684,""y"":3.335283041000366},{""x"":3.0999999046325684,""y"":3.571141481399536},{""x"":3.5999999046325684,""y"":3.4155046939849854},{""x"":4.099999904632568,""y"":3.7316646575927734},{""x"":4.599999904632568,""y"":3.0680155754089355},{""x"":5.099999904632568,""y"":2.891066551208496},{""x"":5.599999904632568,""y"":1.6022753715515137},{""x"":6.099999904632568,""y"":0.7652576565742493},{""x"":6.599999904632568,""y"":0.6875326037406921},{""x"":7.099999904632568,""y"":0.5828871726989746}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nItaly,MSNFHNEHVMQFYRNNLKTKGVFGRQ,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCO[N+](=O)[O-],1480020,36.33115768432617,99502,"168-46 91ST AVE., 2ND FLR",https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,8,8,1ZP8,8,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[2.293592105923809, 1.3781586549141835, 5.1025898038676605, 0.03493851245291291],""points"":[{""x"":0.10000000149011612,""y"":2.1287283897399902},{""x"":0.6000000238418579,""y"":2.267972230911255},{""x"":1.100000023841858,""y"":2.398442506790161},{""x"":1.600000023841858,""y"":2.5130622386932373},{""x"":2.0999999046325684,""y"":2.3255116939544678},{""x"":2.5999999046325684,""y"":2.127340793609619},{""x"":3.0999999046325684,""y"":2.47259783744812},{""x"":3.5999999046325684,""y"":2.131181478500366},{""x"":4.099999904632568,""y"":2.090421438217163},{""x"":4.599999904632568,""y"":2.02299165725708},{""x"":5.099999904632568,""y"":1.1105059385299683},{""x"":5.599999904632568,""y"":0.4494485855102539},{""x"":6.099999904632568,""y"":0.1375635862350464},{""x"":6.599999904632568,""y"":0.036351121962070465},{""x"":7.099999904632568,""y"":0.1619771122932434}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.953125499439879, 1.2528620255306528, 5.187637440149802, 0.3110348753260886],""points"":[{""x"":0.10000000149011612,""y"":5.6585283279418945},{""x"":0.6000000238418579,""y"":5.911152362823486},{""x"":1.100000023841858,""y"":5.924920082092285},{""x"":1.600000023841858,""y"":5.8469438552856445},{""x"":2.0999999046325684,""y"":5.929472923278809},{""x"":2.5999999046325684,""y"":6.190037727355957},{""x"":3.0999999046325684,""y"":6.236179828643799},{""x"":3.5999999046325684,""y"":6.141019344329834},{""x"":4.099999904632568,""y"":5.295210838317871},{""x"":4.599999904632568,""y"":5.265801906585693},{""x"":5.099999904632568,""y"":3.3722851276397705},{""x"":5.599999904632568,""y"":1.8299226760864258},{""x"":6.099999904632568,""y"":0.32690900564193726},{""x"":6.599999904632568,""y"":0.6274543404579163},{""x"":7.099999904632568,""y"":0.8441857099533081}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nRwanda,MPNSEPASLLELFNSIATQGELVRSLKAGNASK,CC(C)Cc1ccc(cc1)C(C)C(=O)N2CCCC2C(=O)OCCO,1480021,36.33137130737305,995037247,"168-46 91ST AVE., 2ND FLR",https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,9,9,2BDJ,9,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[3.8209972202654474, 1.3779216716448506, 5.299882228439686, 0.06040645519069608],""points"":[{""x"":0.10000000149011612,""y"":3.7821109294891357},{""x"":0.6000000238418579,""y"":3.542433023452759},{""x"":1.100000023841858,""y"":3.7008674144744873},{""x"":1.600000023841858,""y"":3.717301607131958},{""x"":2.0999999046325684,""y"":4.024452209472656},{""x"":2.5999999046325684,""y"":4.013899326324463},{""x"":3.0999999046325684,""y"":3.945094347000122},{""x"":3.5999999046325684,""y"":3.866621971130371},{""x"":4.099999904632568,""y"":3.7461626529693604},{""x"":4.599999904632568,""y"":3.3454740047454834},{""x"":5.099999904632568,""y"":2.61944317817688},{""x"":5.599999904632568,""y"":0.999405026435852},{""x"":6.099999904632568,""y"":0.46259793639183044},{""x"":6.599999904632568,""y"":0.054134611040353775},{""x"":7.099999904632568,""y"":0.05711187422275543}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[5.6318079657726035, 1.8495493770000595, 5.391793312471116, 0.17060707587348442],""points"":[{""x"":0.10000000149011612,""y"":5.458079814910889},{""x"":0.6000000238418579,""y"":5.554427146911621},{""x"":1.100000023841858,""y"":5.799983024597168},{""x"":1.600000023841858,""y"":5.364140033721924},{""x"":2.0999999046325684,""y"":5.864485740661621},{""x"":2.5999999046325684,""y"":5.4509806632995605},{""x"":3.0999999046325684,""y"":5.702574729919434},{""x"":3.5999999046325684,""y"":5.7314534187316895},{""x"":4.099999904632568,""y"":5.5123443603515625},{""x"":4.599999904632568,""y"":5.724395751953125},{""x"":5.099999904632568,""y"":4.354506969451904},{""x"":5.599999904632568,""y"":1.7307666540145874},{""x"":6.099999904632568,""y"":0.6305936574935913},{""x"":6.599999904632568,""y"":0.035183437168598175},{""x"":7.099999904632568,""y"":0.7575169205665588}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\nSwitzerland,IRVVGRYLIEVWKAAGMDMDKVLFLWSSDEI,CN1CCC(CC1)Oc2ccc(cc2)C(F)(F)F,1480028,36.33137130737305,99504,92-11 179TH PLACE,https://datagrok.ai/img/slides/access-db-connect.png,id,ErrorMessage,"COMPND \nATOM \nEND",flag,9,10,1IAN,10,1.23,<chart></chart>,"{""series"":[{""name"":""Run:2023-08-08"",""fitFunction"":""sigmoid"",""fitLineColor"":""#1f77b4"",""pointColor"":""#1f77b4"",""showPoints"":""points"",""parameters"":[1.1190255865097471, 2.3163895161544437, 5.4968866182279195, 0.2035204047289052],""points"":[{""x"":0.10000000149011612,""y"":1.1057683229446411},{""x"":0.6000000238418579,""y"":1.1019697189331055},{""x"":1.100000023841858,""y"":1.0818607807159424},{""x"":1.600000023841858,""y"":1.062997817993164},{""x"":2.0999999046325684,""y"":1.046447515487671},{""x"":2.5999999046325684,""y"":1.1217249631881714},{""x"":3.0999999046325684,""y"":1.2166996002197266},{""x"":3.5999999046325684,""y"":1.215477705001831},{""x"":4.099999904632568,""y"":1.0581893920898438},{""x"":4.599999904632568,""y"":1.1747995615005493},{""x"":5.099999904632568,""y"":1.0181127786636353},{""x"":5.599999904632568,""y"":0.5344523191452026},{""x"":6.099999904632568,""y"":0.2569526433944702},{""x"":6.599999904632568,""y"":0.1912207305431366},{""x"":7.099999904632568,""y"":0.15060538053512573}]},{""name"":""Run:2023-08-08"",""fitLineColor"":""#ffbb78"",""pointColor"":""#ffbb78"",""showPoints"":""points"",""parameters"":[3.1038581025805785, 2.0032224204185245, 5.087602825989163, 0.13277988512492753],""points"":[{""x"":0.10000000149011612,""y"":3.0498509407043457},{""x"":0.6000000238418579,""y"":2.805217742919922},{""x"":1.100000023841858,""y"":3.3415253162384033},{""x"":1.600000023841858,""y"":3.0549843311309814},{""x"":2.0999999046325684,""y"":3.250074863433838},{""x"":2.5999999046325684,""y"":3.0432586669921875},{""x"":3.0999999046325684,""y"":3.265852451324463},{""x"":3.5999999046325684,""y"":2.9475724697113037},{""x"":4.099999904632568,""y"":3.1929898262023926},{""x"":4.599999904632568,""y"":2.7460060119628906},{""x"":5.099999904632568,""y"":1.6175861358642578},{""x"":5.599999904632568,""y"":0.3006608486175537},{""x"":6.099999904632568,""y"":0.3444803059101105},{""x"":6.599999904632568,""y"":0.015537971630692482},{""x"":7.099999904632568,""y"":0.5527358055114746}]}],""chartOptions"":{""xAxisName"":""Conc."",""yAxisName"":""Activity"",""title"":""Dose-Response curves""}}",text,,\n,,,,,,,,,,,,,,,,,,,,,');i.columns.add(o.Column.fromList(o.TYPE.BYTE_ARRAY,"BinaryImage",Array.from(new Uint8Array(11))));var s=function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))};const a=3e4,u=108e5,c=console.log.bind(console),l=console.info.bind(console),f=console.warn.bind(console),h=console.error.bind(console),p={},d="Auto Tests",g="Demo",m="Detectors",y="Core",v={};let b;var C;!function(t){t.notNull=function(t,e){if(null==t)throw new Error(`${null==e?"Value":e} not defined`)}}(C||(C={}));class w{constructor(t,e){this.catchUnhandled=!0,this.report=!1,void 0!==t&&(this.catchUnhandled=t),void 0!==e&&(this.report=e)}}class A{constructor(t,e,n,r){var o;this.category=t,this.name=e,null!=r||(r={}),null!==(o=r.timeout)&&void 0!==o||(r.timeout=a),this.options=r,this.test=()=>s(this,void 0,void 0,(function*(){return new Promise(((t,e)=>s(this,void 0,void 0,(function*(){let r="";try{r=yield n()}catch(t){e(t)}t(r)}))))}))}}function E(t,e,n,r=0,o="timeout"){return s(this,void 0,void 0,(function*(){return new Promise(((i,s)=>{const a=t.subscribe((t=>{try{e(t),i("OK")}catch(t){s(t)}finally{a.unsubscribe(),clearTimeout(u)}})),u=setTimeout((()=>{a.unsubscribe(),s(o)}),r);n()}))}))}function _(t,e,n){null==p[b]&&(p[b]={}),null==p[b].tests&&(p[b].tests=[]),p[b].tests.push(new A(b,t,e,n))}function x(t,e=!0,n){if(n=n?`${n}, `:"",t!==e)throw new Error(`${n}Expected "${e}", got "${t}"`)}function T(t,e,n=.001,r){if(t===Number.POSITIVE_INFINITY&&e===Number.POSITIVE_INFINITY||t===Number.NEGATIVE_INFINITY&&e===Number.NEGATIVE_INFINITY||t===Number.NaN&&e===Number.NaN||isNaN(t)&&isNaN(e))return;const o=Math.abs(t-e)<n;if(x(o,!0,`${null!=r?r:""} (tolerance = ${n})`),!o)throw new Error(`Expected ${e}, got ${t} (tolerance = ${n})`)}function I(t,e){for(const[n,r]of Object.entries(e)){if(!t.hasOwnProperty(n))throw new Error(`Expected property "${n}" not found`);const e=t[n];if(e instanceof Array&&r instanceof Array)P(e,r);else if(e instanceof Object&&r instanceof Object)I(e,r);else if(Number.isFinite(e)&&Number.isFinite(r))T(e,r);else if(e!=r)throw new Error(`Expected (${r}) for key '${n}', got (${e})`)}}function P(t,e){const n=t.length,r=e.length;if(n!=r)throw new Error(`Arrays are of different length: actual array length is ${n} and expected array length is ${r}`);for(let r=0;r<n;r++)if(t[r]instanceof Array&&e[r]instanceof Array)P(t[r],e[r]);else if(t[r]instanceof Object&&e[r]instanceof Object)I(t[r],e[r]);else if(t[r]!=e[r])throw new Error(`Expected ${e[r]} at position ${r}, got ${t[r]}`)}function S(t,e,n){var r;b=t,e(),p[b]&&(p[b].clear=null===(r=null==n?void 0:n.clear)||void 0===r||r,p[b].timeout=null==n?void 0:n.timeout,p[b].benchmarks=null==n?void 0:n.benchmarks,p[b].stressTests=null==n?void 0:n.stressTests)}function O(t){null==p[b]&&(p[b]={}),p[b].before=t}function N(t){null==p[b]&&(p[b]={}),p[b].after=t}function L(t,e){return t.replace(new RegExp(e.name,"gi"),e.nqName)}function $(t,e){var n,u,c,l;return s(this,void 0,void 0,(function*(){const f=t.id;if(v[f])return;const h=e?e.tests:p;if(void 0!==h[d]||void 0!==h[g]||Object.keys(h).find((t=>t.startsWith(d)||t.startsWith(y))))return void(v[f]=!0);if("DevTools"===t.name||e&&"DevTools"===e._package.name)for(const t of window.dartTests){const e=t.name.split(/\s*\|\s*!/g);let r=null!==(n=e.pop())&&void 0!==n?n:t.name,o=e.length?y+": "+e.join(": "):y,i=r.split(" | ");r=i[i.length-1],i.unshift(o),i.pop(),o=i.join(": "),void 0===h[o]&&(h[o]={tests:[],clear:!0}),h[o].tests.push(new A(o,r,t.test,{isAggregated:!1,timeout:null!==(c=null===(u=t.options)||void 0===u?void 0:u.timeout)&&void 0!==c?c:a,skipReason:null===(l=t.options)||void 0===l?void 0:l.skipReason}))}const b=[],C=[],w=[],E=yield r.dapi.functions.filter(`package.id = "${f}"`).list(),_=new RegExp(/skip:\s*([^,\s]+)|wait:\s*(\d+)|cat:\s*([^,\s]+)|timeout:\s*(\d+)/g);for(const e of E){const n=e.options.test,a=e.options.demoPath;if(n&&Array.isArray(n)&&n.length)for(let t=0;t<n.length;t++){const i=n[t].matchAll(_),a={};Array.from(i).forEach((t=>{t[0].startsWith("skip")?a.skip=t[1]:t[0].startsWith("wait")?a.wait=parseInt(t[2]):t[0].startsWith("cat")?a.cat=t[3]:t[0].startsWith("timeout")&&(a.timeout=parseInt(t[4]))}));const u=new A(d,1===n.length?e.name:`${e.name} ${t+1}`,(()=>s(this,void 0,void 0,(function*(){const o=yield r.functions.eval(L(n[t],e));if(a.wait&&(yield F(a.wait)),"boolean"==typeof o&&!o)throw`Failed: ${n[t]}, expected true, got ${o}`}))),{skipReason:a.skip,timeout:o.Test.isInBenchmark?a.benchmarkTimeout:a.timeout});if(a.cat){const t=d+": "+a.cat;u.category=t,void 0===h[t]&&(h[t]={tests:[],clear:!0}),h[t].tests.push(u)}else b.push(u)}if(a){const t=e.options.demoWait?parseInt(e.options.demoWait):void 0,n=new A(g,e.friendlyName,(()=>s(this,void 0,void 0,(function*(){r.shell.isInDemo=!0,void 0===r.shell.view(o.View.BROWSE)&&(r.shell.v=o.View.createByType(o.View.BROWSE)),yield F(300),r.shell.clearLastError(),yield e.apply(),yield F(t||2e3);const n=yield r.shell.lastError;if(n)throw new Error(n);r.shell.isInDemo=!1}))),{skipReason:e.options.demoSkip});C.push(n)}if(e.hasTag("semTypeDetector")){let n=i;e.options.testData&&(n=yield r.data.files.openTable(`System:AppData/${t.nqName}/${e.options.testData}`));const o=new A(m,e.friendlyName,(()=>s(this,void 0,void 0,(function*(){const r=[];console.log(`System:AppData/${t.nqName}/${e.options.testData}`);for(const t of n.clone().columns){const n=yield e.apply([t]);r.push(n||t.semType)}const o=r.filter((t=>t));x(o.length,1),e.options.testDataColumnName&&x(o[0],e.options.testDataColumnName)}))),{skipReason:e.options.skipTest});w.push(o)}}v[f]=!0,b.length>0&&(h[d]={tests:b,clear:!0}),C.length>0&&(h[g]={tests:C,clear:!0}),w.length>0&&(h[m]={tests:w,clear:!1})}))}function M(t){var e,n,i,a;return s(this,void 0,void 0,(function*(){const u=null===(n=null===(e=r.functions.getCurrentCall())||void 0===e?void 0:e.func)||void 0===n?void 0:n.package;yield $(u);const d=[];console.log("Running tests"),null!=t||(t={}),null!==(i=(a=t).testContext)&&void 0!==i||(a.testContext=new w),r.shell.clearLastError();const g=function(){const t=[];return console.log=(...e)=>{t.push(...e),c(...e)},console.info=(...e)=>{t.push(...e),l(...e)},console.warn=(...e)=>{t.push(...e),f(...e)},console.error=(...e)=>{t.push(...e),h(...e)},t}();yield function(t,e){var n,i,a,p,y,v,b,C,w;return s(this,void 0,void 0,(function*(){try{for(const[s,l]of Object.entries(t)){if((null==e?void 0:e.category)&&!s.toLowerCase().startsWith(null==e?void 0:e.category.toLowerCase())||(null===(n=e.exclude)||void 0===n?void 0:n.some((t=>s.startsWith(t)))))continue;c(`Started ${s} category`);const t=null===(i=l.tests)||void 0===i?void 0:i.every((t=>{var e;return null===(e=t.options)||void 0===e?void 0:e.skipReason}));t||(l.beforeStatus=yield m(l.before,null!==(a=e.category)&&void 0!==a?a:""));let f=null!==(p=l.tests)&&void 0!==p?p:[];e.stressTest&&(f=f.filter((t=>{var e;return null===(e=t.options)||void 0===e?void 0:e.stressTest})),f=B(f)),(null!==(v=null===(y=e.tags)||void 0===y?void 0:y.length)&&void 0!==v?v:0)>0&&(f=f.filter((t=>{var n,r;return null===(r=null===(n=t.options)||void 0===n?void 0:n.tags)||void 0===r?void 0:r.some((t=>{var n;return(null!==(n=null==e?void 0:e.tags)&&void 0!==n?n:[]).includes(t)}))})));const h=[];if(l.clear)for(let t=0;t<f.length;t++){f[t].options&&void 0===(null===(b=f[t].options)||void 0===b?void 0:b.benchmark)&&(f[t].options||(f[t].options={}),f[t].options.benchmark=null!==(C=l.benchmarks)&&void 0!==C&&C);let n=yield R(f[t],null==e?void 0:e.test,g,o.Test.isInBenchmark?l.benchmarkTimeout:l.timeout,u.name,e.verbose);n&&h.push(n),r.shell.closeAll(),o.Balloon.closeAll()}else for(let t=0;t<f.length;t++){let n=yield R(f[t],null==e?void 0:e.test,g,o.Test.isInBenchmark?l.benchmarkTimeout:l.timeout,u.name,e.verbose);n&&h.push(n)}const A=h.filter((t=>"skipped"!=t.result));t||(l.afterStatus=yield m(l.after,null!==(w=e.category)&&void 0!==w?w:"")),l.afterStatus&&A.push({date:(new Date).toISOString(),logs:"",category:s,name:"after",result:l.afterStatus,success:!1,ms:0,skipped:!1}),l.beforeStatus&&A.push({date:(new Date).toISOString(),logs:"",category:s,name:"before",result:l.beforeStatus,success:!1,ms:0,skipped:!1}),d.push(...A)}}finally{console.log=c,console.info=l,console.warn=f,console.error=h}if(e.testContext.catchUnhandled&&!o.Test.isInBenchmark){yield F(1e3);const t=yield r.shell.lastError,e={logs:"",date:(new Date).toISOString(),category:"Unhandled exceptions",name:"Exception",result:null!=t?t:"",success:!t,ms:0,skipped:!1};d.push(e),e.package=u.name,null!=r.shell.reportTest?yield r.shell.reportTest("package",e):yield fetch(`${r.dapi.root}/log/tests/package`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(e)})}}))}(p,t);for(let t of d)t.result=t.result.toString().replace(/"/g,"'"),null!=t.logs&&(t.logs=t.logs.toString().replace(/"/g,"'"));return d;function m(t,e){return s(this,void 0,void 0,(function*(){var n=void 0;try{void 0!==t&&(yield H((()=>s(this,void 0,void 0,(function*(){yield t()}))),1e5,`before ${e}: timeout error`))}catch(t){n=yield D(t)}return n}))}}))}function D(t){return s(this,void 0,void 0,(function*(){return`${t.toString()}\n${t.stack?yield o.Logger.translateStackTrace(t.stack):""}`}))}function R(t,e,n,i,l,f){var p,d,g,m,y,v,b,C;return s(this,void 0,void 0,(function*(){let s;n.length=0;let w="package";const A=null!=e&&t.name.toLowerCase()!==e.toLowerCase();let E=(null===(p=t.options)||void 0===p?void 0:p.skipReason)||A,_=A?"skipped":null===(d=t.options)||void 0===d?void 0:d.skipReason;if(o.Test.isInBenchmark&&!(null===(g=t.options)||void 0===g?void 0:g.benchmark))return void c(`SKIPPED: ${t.category} ${t.name} doesnt available in benchmark mode`);E||c(`Started ${t.category} ${t.name}`);const x=Date.now();try{if(E)s={date:(new Date).toISOString(),success:!0,result:_,ms:0,skipped:!0};else{let e=(null===(m=t.options)||void 0===m?void 0:m.timeout)===a&&i?i:null===(y=t.options)||void 0===y?void 0:y.timeout;e=e===a&&o.Test.isInBenchmark?u:e,s={date:(new Date).toISOString(),success:!0,result:null!==(v=yield H(t.test,e))&&void 0!==v?v:"OK",ms:0,skipped:!1}}}catch(t){h(t),s={date:(new Date).toISOString(),success:!1,result:yield D(t),ms:0,skipped:!1}}if((null===(b=t.options)||void 0===b?void 0:b.isAggregated)&&s.result.constructor===o.DataFrame){const t=s.result.col("success");if(t&&(s.success=t.stats.sum===t.length),!f){const t=s.result;t.columns.remove("stack"),t.rows.removeWhere((t=>t.get("success"))),s.result=t}s.result=s.result.toCsv()}if(s.logs=n.join("\n"),s.ms=Date.now()-x,E||c(`Finished ${t.category} ${t.name} for ${s.ms} ms`),s.category=t.category,s.name=t.name,!A){let e={success:s.success,result:s.result,ms:s.ms,skipped:s.skipped,package:l,category:t.category,name:t.name,logs:s.logs};if(s.result.constructor==Object){const t=Object.keys(s.result).reduce(((t,e)=>Object.assign(Object.assign({},t),{["result."+e]:s.result[e]})),{});e=Object.assign(Object.assign({},e),t)}e.result instanceof o.DataFrame&&(e.result=JSON.stringify(null===(C=e.result)||void 0===C?void 0:C.toJson())||""),null!=r.shell.reportTest?yield r.shell.reportTest(w,e):yield fetch(`${r.dapi.root}/log/tests/${w}`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"same-origin",body:JSON.stringify(e)})}return s}))}function B(t){const e=t.slice();return e.sort((()=>Math.random()-.5)),e}function F(t){return s(this,void 0,void 0,(function*(){yield new Promise((e=>setTimeout(e,t)))}))}function H(t,e,n="EXECUTION TIMEOUT"){return s(this,void 0,void 0,(function*(){let r=null;const o=new Promise(((t,o)=>{r=setTimeout((()=>{o(n)}),e)}));try{return yield Promise.race([t(),o])}finally{r&&clearTimeout(r)}}))}o.DataFrame.fromColumns([o.Column.fromStrings("col",["val1","val2","val3"])])},74:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,".st-colored-text-input > textarea {\n width: 100%;\n -webkit-text-fill-color: transparent;\n background-color: transparent;\n position: relative;\n z-index: 1;\n resize: none;\n height: 22px; /* Fine tuned value to avoid \"jumping\" of the textarea upon autoresize */\n}\n\n.st-colored-text-input > div {\n /* The values here are fine tuned to those of the ui.input textarea in order\n * to achieve precise overlap */\n overflow: auto;\n position: absolute;\n pointer-events: none;\n cursor: text;\n z-index: 0;\n max-width: 100%;\n padding: 2px;\n line-height: normal;\n font-family: 'Roboto', 'Roboto Local', sans-serif;\n font-size: 13px;\n padding-top: 6px !important;\n color: transparent;\n white-space: pre-wrap;\n word-wrap: break-word;\n}\n","",{version:3,sources:["webpack://./src/apps/common/view/components/colored-input/style.css"],names:[],mappings:"AAAA;EACE,WAAW;EACX,oCAAoC;EACpC,6BAA6B;EAC7B,kBAAkB;EAClB,UAAU;EACV,YAAY;EACZ,YAAY,EAAE,wEAAwE;AACxF;;AAEA;EACE;iCAC+B;EAC/B,cAAc;EACd,kBAAkB;EAClB,oBAAoB;EACpB,YAAY;EACZ,UAAU;EACV,eAAe;EACf,YAAY;EACZ,mBAAmB;EACnB,iDAAiD;EACjD,eAAe;EACf,2BAA2B;EAC3B,kBAAkB;EAClB,qBAAqB;EACrB,qBAAqB;AACvB",sourcesContent:[".st-colored-text-input > textarea {\n width: 100%;\n -webkit-text-fill-color: transparent;\n background-color: transparent;\n position: relative;\n z-index: 1;\n resize: none;\n height: 22px; /* Fine tuned value to avoid \"jumping\" of the textarea upon autoresize */\n}\n\n.st-colored-text-input > div {\n /* The values here are fine tuned to those of the ui.input textarea in order\n * to achieve precise overlap */\n overflow: auto;\n position: absolute;\n pointer-events: none;\n cursor: text;\n z-index: 0;\n max-width: 100%;\n padding: 2px;\n line-height: normal;\n font-family: 'Roboto', 'Roboto Local', sans-serif;\n font-size: 13px;\n padding-top: 6px !important;\n color: transparent;\n white-space: pre-wrap;\n word-wrap: break-word;\n}\n"],sourceRoot:""}]);const a=s},252:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-pattern-text-input > textarea {\n resize: none;\n}\n","",{version:3,sources:["webpack://./src/apps/pattern/view/style.css"],names:[],mappings:"AAAA,gGAAgG;;AAEhG;EACE,YAAY;AACd",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-pattern-text-input > textarea {\n resize: none;\n}\n"],sourceRoot:""}]);const a=s},507:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-structure-body {\n padding-right: 20px;\n}\n\n.st-structure-mol-img {\n margin-right: 30px;\n float: right;\n}\n\n.st-structure-bool-button-block {\n justify-content: right;\n margin-bottom: 10px;\n}\n\n.st-structure-bottom {\n flex-direction: row-reverse;\n padding-top: 20px;\n}\n\n.st-structure-clear-buttons {\n justify-content: space-between;\n padding: 13px 10px 13px 10px;\n}\n\n.st-direction-inputs {\n align-items: end;\n}\n\n.st-structure-inputs {\n flex-grow: 2;\n padding-left: 10px;\n}","",{version:3,sources:["webpack://./src/apps/structure/view/style.css"],names:[],mappings:"AAAA,gGAAgG;;AAEhG;EACE,mBAAmB;AACrB;;AAEA;EACE,kBAAkB;EAClB,YAAY;AACd;;AAEA;EACE,sBAAsB;EACtB,mBAAmB;AACrB;;AAEA;EACE,2BAA2B;EAC3B,iBAAiB;AACnB;;AAEA;EACE,8BAA8B;EAC9B,4BAA4B;AAC9B;;AAEA;EACE,gBAAgB;AAClB;;AAEA;EACE,YAAY;EACZ,kBAAkB;AACpB",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n\n.st-structure-body {\n padding-right: 20px;\n}\n\n.st-structure-mol-img {\n margin-right: 30px;\n float: right;\n}\n\n.st-structure-bool-button-block {\n justify-content: right;\n margin-bottom: 10px;\n}\n\n.st-structure-bottom {\n flex-direction: row-reverse;\n padding-top: 20px;\n}\n\n.st-structure-clear-buttons {\n justify-content: space-between;\n padding: 13px 10px 13px 10px;\n}\n\n.st-direction-inputs {\n align-items: end;\n}\n\n.st-structure-inputs {\n flex-grow: 2;\n padding-left: 10px;\n}"],sourceRoot:""}]);const a=s},254:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var r=n(354),o=n.n(r),i=n(314),s=n.n(i)()(o());s.push([t.id,"/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n.st-translator-input-table {\n /* width: 100%; */\n margin-right: 20px;\n}\n\n.st-translator-input-table td:has(textarea) {\n width: 100%;\n}\n\n.st-translator-input-table td:has(select) {\n min-width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table {\n margin-top: 20px;\n margin-right: 20px;\n margin-bottom: 10px;\n}\n\n.st-translator-output-table table {\n width: 100%;\n table-layout: fixed;\n}\n\n.st-translator-output-table td {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.st-translator-output-table tr:nth-child(even) {\n background-color: var(--grey-1);\n}\n\n.st-translator-output-table td:nth-child(odd) {\n width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table td a {\n overflow-wrap: break-word;\n}\n","",{version:3,sources:["webpack://./src/apps/translator/view/style.css"],names:[],mappings:"AAAA,gGAAgG;AAChG;EACE,iBAAiB;EACjB,kBAAkB;AACpB;;AAEA;EACE,WAAW;AACb;;AAEA;EACE,gBAAgB;EAChB,mBAAmB;AACrB;;AAEA;EACE,gBAAgB;EAChB,kBAAkB;EAClB,mBAAmB;AACrB;;AAEA;EACE,WAAW;EACX,mBAAmB;AACrB;;AAEA;EACE,gBAAgB;EAChB,mBAAmB;AACrB;AACA;EACE,+BAA+B;AACjC;;AAEA;EACE,YAAY;EACZ,mBAAmB;AACrB;;AAEA;EACE,yBAAyB;AAC3B",sourcesContent:["/* Naming convention: class names should begin with st and app name to avoid naming collitions */\n.st-translator-input-table {\n /* width: 100%; */\n margin-right: 20px;\n}\n\n.st-translator-input-table td:has(textarea) {\n width: 100%;\n}\n\n.st-translator-input-table td:has(select) {\n min-width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table {\n margin-top: 20px;\n margin-right: 20px;\n margin-bottom: 10px;\n}\n\n.st-translator-output-table table {\n width: 100%;\n table-layout: fixed;\n}\n\n.st-translator-output-table td {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.st-translator-output-table tr:nth-child(even) {\n background-color: var(--grey-1);\n}\n\n.st-translator-output-table td:nth-child(odd) {\n width: 120px;\n vertical-align: top;\n}\n\n.st-translator-output-table td a {\n overflow-wrap: break-word;\n}\n"],sourceRoot:""}]);const a=s},314:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,o,i){"string"==typeof t&&(t=[[null,t,void 0]]);var s={};if(r)for(var a=0;a<this.length;a++){var u=this[a][0];null!=u&&(s[u]=!0)}for(var c=0;c<t.length;c++){var l=[].concat(t[c]);r&&s[l[0]]||(void 0!==i&&(void 0===l[5]||(l[1]="@layer".concat(l[5].length>0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=i),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),e.push(l))}},e}},354:t=>{"use strict";t.exports=function(t){var e=t[1],n=t[3];if(!n)return e;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),i="/*# ".concat(o," */");return[e].concat([i]).join("\n")}return[e].join("\n")}},982:function(t,e,n){var r;!function(){var e={};!function(t){"use strict";t.__esModule=!0,t.digestLength=32,t.blockSize=64;var e=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]);function n(t,n,r,o,i){for(var s,a,u,c,l,f,h,p,d,g,m,y,v;i>=64;){for(s=n[0],a=n[1],u=n[2],c=n[3],l=n[4],f=n[5],h=n[6],p=n[7],g=0;g<16;g++)m=o+4*g,t[g]=(255&r[m])<<24|(255&r[m+1])<<16|(255&r[m+2])<<8|255&r[m+3];for(g=16;g<64;g++)y=((d=t[g-2])>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,v=((d=t[g-15])>>>7|d<<25)^(d>>>18|d<<14)^d>>>3,t[g]=(y+t[g-7]|0)+(v+t[g-16]|0);for(g=0;g<64;g++)y=(((l>>>6|l<<26)^(l>>>11|l<<21)^(l>>>25|l<<7))+(l&f^~l&h)|0)+(p+(e[g]+t[g]|0)|0)|0,v=((s>>>2|s<<30)^(s>>>13|s<<19)^(s>>>22|s<<10))+(s&a^s&u^a&u)|0,p=h,h=f,f=l,l=c+y|0,c=u,u=a,a=s,s=y+v|0;n[0]+=s,n[1]+=a,n[2]+=u,n[3]+=c,n[4]+=l,n[5]+=f,n[6]+=h,n[7]+=p,o+=64,i-=64}return o}var r=function(){function e(){this.digestLength=t.digestLength,this.blockSize=t.blockSize,this.state=new Int32Array(8),this.temp=new Int32Array(64),this.buffer=new Uint8Array(128),this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this.reset()}return e.prototype.reset=function(){return this.state[0]=1779033703,this.state[1]=3144134277,this.state[2]=1013904242,this.state[3]=2773480762,this.state[4]=1359893119,this.state[5]=2600822924,this.state[6]=528734635,this.state[7]=1541459225,this.bufferLength=0,this.bytesHashed=0,this.finished=!1,this},e.prototype.clean=function(){for(var t=0;t<this.buffer.length;t++)this.buffer[t]=0;for(t=0;t<this.temp.length;t++)this.temp[t]=0;this.reset()},e.prototype.update=function(t,e){if(void 0===e&&(e=t.length),this.finished)throw new Error("SHA256: can't update because hash was finished.");var r=0;if(this.bytesHashed+=e,this.bufferLength>0){for(;this.bufferLength<64&&e>0;)this.buffer[this.bufferLength++]=t[r++],e--;64===this.bufferLength&&(n(this.temp,this.state,this.buffer,0,64),this.bufferLength=0)}for(e>=64&&(r=n(this.temp,this.state,t,r,e),e%=64);e>0;)this.buffer[this.bufferLength++]=t[r++],e--;return this},e.prototype.finish=function(t){if(!this.finished){var e=this.bytesHashed,r=this.bufferLength,o=e/536870912|0,i=e<<3,s=e%64<56?64:128;this.buffer[r]=128;for(var a=r+1;a<s-8;a++)this.buffer[a]=0;this.buffer[s-8]=o>>>24&255,this.buffer[s-7]=o>>>16&255,this.buffer[s-6]=o>>>8&255,this.buffer[s-5]=o>>>0&255,this.buffer[s-4]=i>>>24&255,this.buffer[s-3]=i>>>16&255,this.buffer[s-2]=i>>>8&255,this.buffer[s-1]=i>>>0&255,n(this.temp,this.state,this.buffer,0,s),this.finished=!0}for(a=0;a<8;a++)t[4*a+0]=this.state[a]>>>24&255,t[4*a+1]=this.state[a]>>>16&255,t[4*a+2]=this.state[a]>>>8&255,t[4*a+3]=this.state[a]>>>0&255;return this},e.prototype.digest=function(){var t=new Uint8Array(this.digestLength);return this.finish(t),t},e.prototype._saveState=function(t){for(var e=0;e<this.state.length;e++)t[e]=this.state[e]},e.prototype._restoreState=function(t,e){for(var n=0;n<this.state.length;n++)this.state[n]=t[n];this.bytesHashed=e,this.finished=!1,this.bufferLength=0},e}();t.Hash=r;var o=function(){function t(t){this.inner=new r,this.outer=new r,this.blockSize=this.inner.blockSize,this.digestLength=this.inner.digestLength;var e=new Uint8Array(this.blockSize);if(t.length>this.blockSize)(new r).update(t).finish(e).clean();else for(var n=0;n<t.length;n++)e[n]=t[n];for(n=0;n<e.length;n++)e[n]^=54;for(this.inner.update(e),n=0;n<e.length;n++)e[n]^=106;for(this.outer.update(e),this.istate=new Uint32Array(8),this.ostate=new Uint32Array(8),this.inner._saveState(this.istate),this.outer._saveState(this.ostate),n=0;n<e.length;n++)e[n]=0}return t.prototype.reset=function(){return this.inner._restoreState(this.istate,this.inner.blockSize),this.outer._restoreState(this.ostate,this.outer.blockSize),this},t.prototype.clean=function(){for(var t=0;t<this.istate.length;t++)this.ostate[t]=this.istate[t]=0;this.inner.clean(),this.outer.clean()},t.prototype.update=function(t){return this.inner.update(t),this},t.prototype.finish=function(t){return this.outer.finished?this.outer.finish(t):(this.inner.finish(t),this.outer.update(t,this.digestLength).finish(t)),this},t.prototype.digest=function(){var t=new Uint8Array(this.digestLength);return this.finish(t),t},t}();function i(t){var e=(new r).update(t),n=e.digest();return e.clean(),n}function s(t,e){var n=new o(t).update(e),r=n.digest();return n.clean(),r}function a(t,e,n,r){var o=r[0];if(0===o)throw new Error("hkdf: cannot expand more");e.reset(),o>1&&e.update(t),n&&e.update(n),e.update(r),e.finish(t),r[0]++}t.HMAC=o,t.hash=i,t.default=i,t.hmac=s;var u=new Uint8Array(t.digestLength);t.hkdf=function(t,e,n,r){void 0===e&&(e=u),void 0===r&&(r=32);for(var i=new Uint8Array([1]),c=s(e,t),l=new o(c),f=new Uint8Array(l.digestLength),h=f.length,p=new Uint8Array(r),d=0;d<r;d++)h===f.length&&(a(f,l,n,i),h=0),p[d]=f[h++];return l.clean(),f.fill(0),i.fill(0),p},t.pbkdf2=function(t,e,n,r){for(var i=new o(t),s=i.digestLength,a=new Uint8Array(4),u=new Uint8Array(s),c=new Uint8Array(s),l=new Uint8Array(r),f=0;f*s<r;f++){var h=f+1;a[0]=h>>>24&255,a[1]=h>>>16&255,a[2]=h>>>8&255,a[3]=h>>>0&255,i.reset(),i.update(e),i.update(a),i.finish(c);for(var p=0;p<s;p++)u[p]=c[p];for(p=2;p<=n;p++){i.reset(),i.update(c).finish(c);for(var d=0;d<s;d++)u[d]^=c[d]}for(p=0;p<s&&f*s+p<r;p++)l[f*s+p]=u[p]}for(f=0;f<s;f++)u[f]=c[f]=0;for(f=0;f<4;f++)a[f]=0;return i.clean(),l}}(e);var o=e.default;for(var i in e)o[i]=e[i];"object"==typeof t.exports?t.exports=o:void 0===(r=function(){return o}.call(e,n,e,t))||(t.exports=r)}()},543:function(t,e,n){var r;t=n.nmd(t),function(){var o,i="Expected a function",s="__lodash_hash_undefined__",a="__lodash_placeholder__",u=32,c=128,l=1/0,f=9007199254740991,h=NaN,p=4294967295,d=[["ary",c],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",u],["partialRight",64],["rearg",256]],g="[object Arguments]",m="[object Array]",y="[object Boolean]",v="[object Date]",b="[object Error]",C="[object Function]",w="[object GeneratorFunction]",A="[object Map]",E="[object Number]",_="[object Object]",x="[object Promise]",T="[object RegExp]",I="[object Set]",P="[object String]",S="[object Symbol]",O="[object WeakMap]",N="[object ArrayBuffer]",L="[object DataView]",$="[object Float32Array]",M="[object Float64Array]",D="[object Int8Array]",R="[object Int16Array]",B="[object Int32Array]",F="[object Uint8Array]",H="[object Uint8ClampedArray]",k="[object Uint16Array]",G="[object Uint32Array]",j=/\b__p \+= '';/g,U=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,W=/&(?:amp|lt|gt|quot|#39);/g,Y=/[&<>"']/g,q=RegExp(W.source),K=RegExp(Y.source),z=/<%-([\s\S]+?)%>/g,J=/<%([\s\S]+?)%>/g,Q=/<%=([\s\S]+?)%>/g,X=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Z=/^\w*$/,tt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,et=/[\\^$.*+?()[\]{}|]/g,nt=RegExp(et.source),rt=/^\s+/,ot=/\s/,it=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,st=/\{\n\/\* \[wrapped with (.+)\] \*/,at=/,? & /,ut=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ct=/[()=,{}\[\]\/\s]/,lt=/\\(\\)?/g,ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ht=/\w*$/,pt=/^[-+]0x[0-9a-f]+$/i,dt=/^0b[01]+$/i,gt=/^\[object .+?Constructor\]$/,mt=/^0o[0-7]+$/i,yt=/^(?:0|[1-9]\d*)$/,vt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,bt=/($^)/,Ct=/['\n\r\u2028\u2029\\]/g,wt="\\ud800-\\udfff",At="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Et="\\u2700-\\u27bf",_t="a-z\\xdf-\\xf6\\xf8-\\xff",xt="A-Z\\xc0-\\xd6\\xd8-\\xde",Tt="\\ufe0e\\ufe0f",It="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Pt="["+wt+"]",St="["+It+"]",Ot="["+At+"]",Nt="\\d+",Lt="["+Et+"]",$t="["+_t+"]",Mt="[^"+wt+It+Nt+Et+_t+xt+"]",Dt="\\ud83c[\\udffb-\\udfff]",Rt="[^"+wt+"]",Bt="(?:\\ud83c[\\udde6-\\uddff]){2}",Ft="[\\ud800-\\udbff][\\udc00-\\udfff]",Ht="["+xt+"]",kt="\\u200d",Gt="(?:"+$t+"|"+Mt+")",jt="(?:"+Ht+"|"+Mt+")",Ut="(?:['’](?:d|ll|m|re|s|t|ve))?",Vt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Wt="(?:"+Ot+"|"+Dt+")?",Yt="["+Tt+"]?",qt=Yt+Wt+"(?:"+kt+"(?:"+[Rt,Bt,Ft].join("|")+")"+Yt+Wt+")*",Kt="(?:"+[Lt,Bt,Ft].join("|")+")"+qt,zt="(?:"+[Rt+Ot+"?",Ot,Bt,Ft,Pt].join("|")+")",Jt=RegExp("['’]","g"),Qt=RegExp(Ot,"g"),Xt=RegExp(Dt+"(?="+Dt+")|"+zt+qt,"g"),Zt=RegExp([Ht+"?"+$t+"+"+Ut+"(?="+[St,Ht,"$"].join("|")+")",jt+"+"+Vt+"(?="+[St,Ht+Gt,"$"].join("|")+")",Ht+"?"+Gt+"+"+Ut,Ht+"+"+Vt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Nt,Kt].join("|"),"g"),te=RegExp("["+kt+wt+At+Tt+"]"),ee=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,ne=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],re=-1,oe={};oe[$]=oe[M]=oe[D]=oe[R]=oe[B]=oe[F]=oe[H]=oe[k]=oe[G]=!0,oe[g]=oe[m]=oe[N]=oe[y]=oe[L]=oe[v]=oe[b]=oe[C]=oe[A]=oe[E]=oe[_]=oe[T]=oe[I]=oe[P]=oe[O]=!1;var ie={};ie[g]=ie[m]=ie[N]=ie[L]=ie[y]=ie[v]=ie[$]=ie[M]=ie[D]=ie[R]=ie[B]=ie[A]=ie[E]=ie[_]=ie[T]=ie[I]=ie[P]=ie[S]=ie[F]=ie[H]=ie[k]=ie[G]=!0,ie[b]=ie[C]=ie[O]=!1;var se={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ae=parseFloat,ue=parseInt,ce="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,le="object"==typeof self&&self&&self.Object===Object&&self,fe=ce||le||Function("return this")(),he=e&&!e.nodeType&&e,pe=he&&t&&!t.nodeType&&t,de=pe&&pe.exports===he,ge=de&&ce.process,me=function(){try{return pe&&pe.require&&pe.require("util").types||ge&&ge.binding&&ge.binding("util")}catch(t){}}(),ye=me&&me.isArrayBuffer,ve=me&&me.isDate,be=me&&me.isMap,Ce=me&&me.isRegExp,we=me&&me.isSet,Ae=me&&me.isTypedArray;function Ee(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function _e(t,e,n,r){for(var o=-1,i=null==t?0:t.length;++o<i;){var s=t[o];e(r,s,n(s),t)}return r}function xe(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function Te(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}function Ie(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function Pe(t,e){for(var n=-1,r=null==t?0:t.length,o=0,i=[];++n<r;){var s=t[n];e(s,n,t)&&(i[o++]=s)}return i}function Se(t,e){return!(null==t||!t.length)&&He(t,e,0)>-1}function Oe(t,e,n){for(var r=-1,o=null==t?0:t.length;++r<o;)if(n(e,t[r]))return!0;return!1}function Ne(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}function Le(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}function $e(t,e,n,r){var o=-1,i=null==t?0:t.length;for(r&&i&&(n=t[++o]);++o<i;)n=e(n,t[o],o,t);return n}function Me(t,e,n,r){var o=null==t?0:t.length;for(r&&o&&(n=t[--o]);o--;)n=e(n,t[o],o,t);return n}function De(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var Re=Ue("length");function Be(t,e,n){var r;return n(t,(function(t,n,o){if(e(t,n,o))return r=n,!1})),r}function Fe(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i<o;)if(e(t[i],i,t))return i;return-1}function He(t,e,n){return e==e?function(t,e,n){for(var r=n-1,o=t.length;++r<o;)if(t[r]===e)return r;return-1}(t,e,n):Fe(t,Ge,n)}function ke(t,e,n,r){for(var o=n-1,i=t.length;++o<i;)if(r(t[o],e))return o;return-1}function Ge(t){return t!=t}function je(t,e){var n=null==t?0:t.length;return n?Ye(t,e)/n:h}function Ue(t){return function(e){return null==e?o:e[t]}}function Ve(t){return function(e){return null==t?o:t[e]}}function We(t,e,n,r,o){return o(t,(function(t,o,i){n=r?(r=!1,t):e(n,t,o,i)})),n}function Ye(t,e){for(var n,r=-1,i=t.length;++r<i;){var s=e(t[r]);s!==o&&(n=n===o?s:n+s)}return n}function qe(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Ke(t){return t?t.slice(0,hn(t)+1).replace(rt,""):t}function ze(t){return function(e){return t(e)}}function Je(t,e){return Ne(e,(function(e){return t[e]}))}function Qe(t,e){return t.has(e)}function Xe(t,e){for(var n=-1,r=t.length;++n<r&&He(e,t[n],0)>-1;);return n}function Ze(t,e){for(var n=t.length;n--&&He(e,t[n],0)>-1;);return n}var tn=Ve({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),en=Ve({"&":"&","<":"<",">":">",'"':""","'":"'"});function nn(t){return"\\"+se[t]}function rn(t){return te.test(t)}function on(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function sn(t,e){return function(n){return t(e(n))}}function an(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n];s!==e&&s!==a||(t[n]=a,i[o++]=n)}return i}function un(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}function cn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}function ln(t){return rn(t)?function(t){for(var e=Xt.lastIndex=0;Xt.test(t);)++e;return e}(t):Re(t)}function fn(t){return rn(t)?function(t){return t.match(Xt)||[]}(t):function(t){return t.split("")}(t)}function hn(t){for(var e=t.length;e--&&ot.test(t.charAt(e)););return e}var pn=Ve({"&":"&","<":"<",">":">",""":'"',"'":"'"}),dn=function t(e){var n,r=(e=null==e?fe:dn.defaults(fe.Object(),e,dn.pick(fe,ne))).Array,ot=e.Date,wt=e.Error,At=e.Function,Et=e.Math,_t=e.Object,xt=e.RegExp,Tt=e.String,It=e.TypeError,Pt=r.prototype,St=At.prototype,Ot=_t.prototype,Nt=e["__core-js_shared__"],Lt=St.toString,$t=Ot.hasOwnProperty,Mt=0,Dt=(n=/[^.]+$/.exec(Nt&&Nt.keys&&Nt.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Rt=Ot.toString,Bt=Lt.call(_t),Ft=fe._,Ht=xt("^"+Lt.call($t).replace(et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),kt=de?e.Buffer:o,Gt=e.Symbol,jt=e.Uint8Array,Ut=kt?kt.allocUnsafe:o,Vt=sn(_t.getPrototypeOf,_t),Wt=_t.create,Yt=Ot.propertyIsEnumerable,qt=Pt.splice,Kt=Gt?Gt.isConcatSpreadable:o,zt=Gt?Gt.iterator:o,Xt=Gt?Gt.toStringTag:o,te=function(){try{var t=ci(_t,"defineProperty");return t({},"",{}),t}catch(t){}}(),se=e.clearTimeout!==fe.clearTimeout&&e.clearTimeout,ce=ot&&ot.now!==fe.Date.now&&ot.now,le=e.setTimeout!==fe.setTimeout&&e.setTimeout,he=Et.ceil,pe=Et.floor,ge=_t.getOwnPropertySymbols,me=kt?kt.isBuffer:o,Re=e.isFinite,Ve=Pt.join,gn=sn(_t.keys,_t),mn=Et.max,yn=Et.min,vn=ot.now,bn=e.parseInt,Cn=Et.random,wn=Pt.reverse,An=ci(e,"DataView"),En=ci(e,"Map"),_n=ci(e,"Promise"),xn=ci(e,"Set"),Tn=ci(e,"WeakMap"),In=ci(_t,"create"),Pn=Tn&&new Tn,Sn={},On=Bi(An),Nn=Bi(En),Ln=Bi(_n),$n=Bi(xn),Mn=Bi(Tn),Dn=Gt?Gt.prototype:o,Rn=Dn?Dn.valueOf:o,Bn=Dn?Dn.toString:o;function Fn(t){if(ta(t)&&!Us(t)&&!(t instanceof jn)){if(t instanceof Gn)return t;if($t.call(t,"__wrapped__"))return Fi(t)}return new Gn(t)}var Hn=function(){function t(){}return function(e){if(!Zs(e))return{};if(Wt)return Wt(e);t.prototype=e;var n=new t;return t.prototype=o,n}}();function kn(){}function Gn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=o}function jn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=p,this.__views__=[]}function Un(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Vn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Wn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Yn(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Wn;++e<n;)this.add(t[e])}function qn(t){var e=this.__data__=new Vn(t);this.size=e.size}function Kn(t,e){var n=Us(t),r=!n&&js(t),o=!n&&!r&&qs(t),i=!n&&!r&&!o&&ua(t),s=n||r||o||i,a=s?qe(t.length,Tt):[],u=a.length;for(var c in t)!e&&!$t.call(t,c)||s&&("length"==c||o&&("offset"==c||"parent"==c)||i&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||mi(c,u))||a.push(c);return a}function zn(t){var e=t.length;return e?t[Wr(0,e-1)]:o}function Jn(t,e){return Li(Io(t),ir(e,0,t.length))}function Qn(t){return Li(Io(t))}function Xn(t,e,n){(n!==o&&!Hs(t[e],n)||n===o&&!(e in t))&&rr(t,e,n)}function Zn(t,e,n){var r=t[e];$t.call(t,e)&&Hs(r,n)&&(n!==o||e in t)||rr(t,e,n)}function tr(t,e){for(var n=t.length;n--;)if(Hs(t[n][0],e))return n;return-1}function er(t,e,n,r){return lr(t,(function(t,o,i){e(r,t,n(t),i)})),r}function nr(t,e){return t&&Po(e,Oa(e),t)}function rr(t,e,n){"__proto__"==e&&te?te(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function or(t,e){for(var n=-1,i=e.length,s=r(i),a=null==t;++n<i;)s[n]=a?o:xa(t,e[n]);return s}function ir(t,e,n){return t==t&&(n!==o&&(t=t<=n?t:n),e!==o&&(t=t>=e?t:e)),t}function sr(t,e,n,r,i,s){var a,u=1&e,c=2&e,l=4&e;if(n&&(a=i?n(t,r,i,s):n(t)),a!==o)return a;if(!Zs(t))return t;var f=Us(t);if(f){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&$t.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!u)return Io(t,a)}else{var h=hi(t),p=h==C||h==w;if(qs(t))return wo(t,u);if(h==_||h==g||p&&!i){if(a=c||p?{}:di(t),!u)return c?function(t,e){return Po(t,fi(t),e)}(t,function(t,e){return t&&Po(e,Na(e),t)}(a,t)):function(t,e){return Po(t,li(t),e)}(t,nr(a,t))}else{if(!ie[h])return i?t:{};a=function(t,e,n){var r,o=t.constructor;switch(e){case N:return Ao(t);case y:case v:return new o(+t);case L:return function(t,e){var n=e?Ao(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case $:case M:case D:case R:case B:case F:case H:case k:case G:return Eo(t,n);case A:return new o;case E:case P:return new o(t);case T:return function(t){var e=new t.constructor(t.source,ht.exec(t));return e.lastIndex=t.lastIndex,e}(t);case I:return new o;case S:return r=t,Rn?_t(Rn.call(r)):{}}}(t,h,u)}}s||(s=new qn);var d=s.get(t);if(d)return d;s.set(t,a),ia(t)?t.forEach((function(r){a.add(sr(r,e,n,r,t,s))})):ea(t)&&t.forEach((function(r,o){a.set(o,sr(r,e,n,o,t,s))}));var m=f?o:(l?c?ni:ei:c?Na:Oa)(t);return xe(m||t,(function(r,o){m&&(r=t[o=r]),Zn(a,o,sr(r,e,n,o,t,s))})),a}function ar(t,e,n){var r=n.length;if(null==t)return!r;for(t=_t(t);r--;){var i=n[r],s=e[i],a=t[i];if(a===o&&!(i in t)||!s(a))return!1}return!0}function ur(t,e,n){if("function"!=typeof t)throw new It(i);return Pi((function(){t.apply(o,n)}),e)}function cr(t,e,n,r){var o=-1,i=Se,s=!0,a=t.length,u=[],c=e.length;if(!a)return u;n&&(e=Ne(e,ze(n))),r?(i=Oe,s=!1):e.length>=200&&(i=Qe,s=!1,e=new Yn(e));t:for(;++o<a;){var l=t[o],f=null==n?l:n(l);if(l=r||0!==l?l:0,s&&f==f){for(var h=c;h--;)if(e[h]===f)continue t;u.push(l)}else i(e,f,r)||u.push(l)}return u}Fn.templateSettings={escape:z,evaluate:J,interpolate:Q,variable:"",imports:{_:Fn}},Fn.prototype=kn.prototype,Fn.prototype.constructor=Fn,Gn.prototype=Hn(kn.prototype),Gn.prototype.constructor=Gn,jn.prototype=Hn(kn.prototype),jn.prototype.constructor=jn,Un.prototype.clear=function(){this.__data__=In?In(null):{},this.size=0},Un.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Un.prototype.get=function(t){var e=this.__data__;if(In){var n=e[t];return n===s?o:n}return $t.call(e,t)?e[t]:o},Un.prototype.has=function(t){var e=this.__data__;return In?e[t]!==o:$t.call(e,t)},Un.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=In&&e===o?s:e,this},Vn.prototype.clear=function(){this.__data__=[],this.size=0},Vn.prototype.delete=function(t){var e=this.__data__,n=tr(e,t);return!(n<0||(n==e.length-1?e.pop():qt.call(e,n,1),--this.size,0))},Vn.prototype.get=function(t){var e=this.__data__,n=tr(e,t);return n<0?o:e[n][1]},Vn.prototype.has=function(t){return tr(this.__data__,t)>-1},Vn.prototype.set=function(t,e){var n=this.__data__,r=tr(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Wn.prototype.clear=function(){this.size=0,this.__data__={hash:new Un,map:new(En||Vn),string:new Un}},Wn.prototype.delete=function(t){var e=ai(this,t).delete(t);return this.size-=e?1:0,e},Wn.prototype.get=function(t){return ai(this,t).get(t)},Wn.prototype.has=function(t){return ai(this,t).has(t)},Wn.prototype.set=function(t,e){var n=ai(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Yn.prototype.add=Yn.prototype.push=function(t){return this.__data__.set(t,s),this},Yn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.clear=function(){this.__data__=new Vn,this.size=0},qn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},qn.prototype.get=function(t){return this.__data__.get(t)},qn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Vn){var r=n.__data__;if(!En||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Wn(r)}return n.set(t,e),this.size=n.size,this};var lr=No(vr),fr=No(br,!0);function hr(t,e){var n=!0;return lr(t,(function(t,r,o){return n=!!e(t,r,o)})),n}function pr(t,e,n){for(var r=-1,i=t.length;++r<i;){var s=t[r],a=e(s);if(null!=a&&(u===o?a==a&&!aa(a):n(a,u)))var u=a,c=s}return c}function dr(t,e){var n=[];return lr(t,(function(t,r,o){e(t,r,o)&&n.push(t)})),n}function gr(t,e,n,r,o){var i=-1,s=t.length;for(n||(n=gi),o||(o=[]);++i<s;){var a=t[i];e>0&&n(a)?e>1?gr(a,e-1,n,r,o):Le(o,a):r||(o[o.length]=a)}return o}var mr=Lo(),yr=Lo(!0);function vr(t,e){return t&&mr(t,e,Oa)}function br(t,e){return t&&yr(t,e,Oa)}function Cr(t,e){return Pe(e,(function(e){return Js(t[e])}))}function wr(t,e){for(var n=0,r=(e=yo(e,t)).length;null!=t&&n<r;)t=t[Ri(e[n++])];return n&&n==r?t:o}function Ar(t,e,n){var r=e(t);return Us(t)?r:Le(r,n(t))}function Er(t){return null==t?t===o?"[object Undefined]":"[object Null]":Xt&&Xt in _t(t)?function(t){var e=$t.call(t,Xt),n=t[Xt];try{t[Xt]=o;var r=!0}catch(t){}var i=Rt.call(t);return r&&(e?t[Xt]=n:delete t[Xt]),i}(t):function(t){return Rt.call(t)}(t)}function _r(t,e){return t>e}function xr(t,e){return null!=t&&$t.call(t,e)}function Tr(t,e){return null!=t&&e in _t(t)}function Ir(t,e,n){for(var i=n?Oe:Se,s=t[0].length,a=t.length,u=a,c=r(a),l=1/0,f=[];u--;){var h=t[u];u&&e&&(h=Ne(h,ze(e))),l=yn(h.length,l),c[u]=!n&&(e||s>=120&&h.length>=120)?new Yn(u&&h):o}h=t[0];var p=-1,d=c[0];t:for(;++p<s&&f.length<l;){var g=h[p],m=e?e(g):g;if(g=n||0!==g?g:0,!(d?Qe(d,m):i(f,m,n))){for(u=a;--u;){var y=c[u];if(!(y?Qe(y,m):i(t[u],m,n)))continue t}d&&d.push(m),f.push(g)}}return f}function Pr(t,e,n){var r=null==(t=xi(t,e=yo(e,t)))?t:t[Ri(zi(e))];return null==r?o:Ee(r,t,n)}function Sr(t){return ta(t)&&Er(t)==g}function Or(t,e,n,r,i){return t===e||(null==t||null==e||!ta(t)&&!ta(e)?t!=t&&e!=e:function(t,e,n,r,i,s){var a=Us(t),u=Us(e),c=a?m:hi(t),l=u?m:hi(e),f=(c=c==g?_:c)==_,h=(l=l==g?_:l)==_,p=c==l;if(p&&qs(t)){if(!qs(e))return!1;a=!0,f=!1}if(p&&!f)return s||(s=new qn),a||ua(t)?Zo(t,e,n,r,i,s):function(t,e,n,r,o,i,s){switch(n){case L:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case N:return!(t.byteLength!=e.byteLength||!i(new jt(t),new jt(e)));case y:case v:case E:return Hs(+t,+e);case b:return t.name==e.name&&t.message==e.message;case T:case P:return t==e+"";case A:var a=on;case I:var u=1&r;if(a||(a=un),t.size!=e.size&&!u)return!1;var c=s.get(t);if(c)return c==e;r|=2,s.set(t,e);var l=Zo(a(t),a(e),r,o,i,s);return s.delete(t),l;case S:if(Rn)return Rn.call(t)==Rn.call(e)}return!1}(t,e,c,n,r,i,s);if(!(1&n)){var d=f&&$t.call(t,"__wrapped__"),C=h&&$t.call(e,"__wrapped__");if(d||C){var w=d?t.value():t,x=C?e.value():e;return s||(s=new qn),i(w,x,n,r,s)}}return!!p&&(s||(s=new qn),function(t,e,n,r,i,s){var a=1&n,u=ei(t),c=u.length;if(c!=ei(e).length&&!a)return!1;for(var l=c;l--;){var f=u[l];if(!(a?f in e:$t.call(e,f)))return!1}var h=s.get(t),p=s.get(e);if(h&&p)return h==e&&p==t;var d=!0;s.set(t,e),s.set(e,t);for(var g=a;++l<c;){var m=t[f=u[l]],y=e[f];if(r)var v=a?r(y,m,f,e,t,s):r(m,y,f,t,e,s);if(!(v===o?m===y||i(m,y,n,r,s):v)){d=!1;break}g||(g="constructor"==f)}if(d&&!g){var b=t.constructor,C=e.constructor;b==C||!("constructor"in t)||!("constructor"in e)||"function"==typeof b&&b instanceof b&&"function"==typeof C&&C instanceof C||(d=!1)}return s.delete(t),s.delete(e),d}(t,e,n,r,i,s))}(t,e,n,r,Or,i))}function Nr(t,e,n,r){var i=n.length,s=i,a=!r;if(null==t)return!s;for(t=_t(t);i--;){var u=n[i];if(a&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++i<s;){var c=(u=n[i])[0],l=t[c],f=u[1];if(a&&u[2]){if(l===o&&!(c in t))return!1}else{var h=new qn;if(r)var p=r(l,f,c,t,e,h);if(!(p===o?Or(f,l,3,r,h):p))return!1}}return!0}function Lr(t){return!(!Zs(t)||(e=t,Dt&&Dt in e))&&(Js(t)?Ht:gt).test(Bi(t));var e}function $r(t){return"function"==typeof t?t:null==t?nu:"object"==typeof t?Us(t)?Fr(t[0],t[1]):Br(t):fu(t)}function Mr(t){if(!wi(t))return gn(t);var e=[];for(var n in _t(t))$t.call(t,n)&&"constructor"!=n&&e.push(n);return e}function Dr(t,e){return t<e}function Rr(t,e){var n=-1,o=Ws(t)?r(t.length):[];return lr(t,(function(t,r,i){o[++n]=e(t,r,i)})),o}function Br(t){var e=ui(t);return 1==e.length&&e[0][2]?Ei(e[0][0],e[0][1]):function(n){return n===t||Nr(n,t,e)}}function Fr(t,e){return vi(t)&&Ai(e)?Ei(Ri(t),e):function(n){var r=xa(n,t);return r===o&&r===e?Ta(n,t):Or(e,r,3)}}function Hr(t,e,n,r,i){t!==e&&mr(e,(function(s,a){if(i||(i=new qn),Zs(s))!function(t,e,n,r,i,s,a){var u=Ti(t,n),c=Ti(e,n),l=a.get(c);if(l)Xn(t,n,l);else{var f=s?s(u,c,n+"",t,e,a):o,h=f===o;if(h){var p=Us(c),d=!p&&qs(c),g=!p&&!d&&ua(c);f=c,p||d||g?Us(u)?f=u:Ys(u)?f=Io(u):d?(h=!1,f=wo(c,!0)):g?(h=!1,f=Eo(c,!0)):f=[]:ra(c)||js(c)?(f=u,js(u)?f=ma(u):Zs(u)&&!Js(u)||(f=di(c))):h=!1}h&&(a.set(c,f),i(f,c,r,s,a),a.delete(c)),Xn(t,n,f)}}(t,e,a,n,Hr,r,i);else{var u=r?r(Ti(t,a),s,a+"",t,e,i):o;u===o&&(u=s),Xn(t,a,u)}}),Na)}function kr(t,e){var n=t.length;if(n)return mi(e+=e<0?n:0,n)?t[e]:o}function Gr(t,e,n){e=e.length?Ne(e,(function(t){return Us(t)?function(e){return wr(e,1===t.length?t[0]:t)}:t})):[nu];var r=-1;e=Ne(e,ze(si()));var o=Rr(t,(function(t,n,o){var i=Ne(e,(function(e){return e(t)}));return{criteria:i,index:++r,value:t}}));return function(t){var e=t.length;for(t.sort((function(t,e){return function(t,e,n){for(var r=-1,o=t.criteria,i=e.criteria,s=o.length,a=n.length;++r<s;){var u=_o(o[r],i[r]);if(u)return r>=a?u:u*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}));e--;)t[e]=t[e].value;return t}(o)}function jr(t,e,n){for(var r=-1,o=e.length,i={};++r<o;){var s=e[r],a=wr(t,s);n(a,s)&&Jr(i,yo(s,t),a)}return i}function Ur(t,e,n,r){var o=r?ke:He,i=-1,s=e.length,a=t;for(t===e&&(e=Io(e)),n&&(a=Ne(t,ze(n)));++i<s;)for(var u=0,c=e[i],l=n?n(c):c;(u=o(a,l,u,r))>-1;)a!==t&&qt.call(a,u,1),qt.call(t,u,1);return t}function Vr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var o=e[n];if(n==r||o!==i){var i=o;mi(o)?qt.call(t,o,1):uo(t,o)}}return t}function Wr(t,e){return t+pe(Cn()*(e-t+1))}function Yr(t,e){var n="";if(!t||e<1||e>f)return n;do{e%2&&(n+=t),(e=pe(e/2))&&(t+=t)}while(e);return n}function qr(t,e){return Si(_i(t,e,nu),t+"")}function Kr(t){return zn(Ha(t))}function zr(t,e){var n=Ha(t);return Li(n,ir(e,0,n.length))}function Jr(t,e,n,r){if(!Zs(t))return t;for(var i=-1,s=(e=yo(e,t)).length,a=s-1,u=t;null!=u&&++i<s;){var c=Ri(e[i]),l=n;if("__proto__"===c||"constructor"===c||"prototype"===c)return t;if(i!=a){var f=u[c];(l=r?r(f,c,u):o)===o&&(l=Zs(f)?f:mi(e[i+1])?[]:{})}Zn(u,c,l),u=u[c]}return t}var Qr=Pn?function(t,e){return Pn.set(t,e),t}:nu,Xr=te?function(t,e){return te(t,"toString",{configurable:!0,enumerable:!1,value:Za(e),writable:!0})}:nu;function Zr(t){return Li(Ha(t))}function to(t,e,n){var o=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var s=r(i);++o<i;)s[o]=t[o+e];return s}function eo(t,e){var n;return lr(t,(function(t,r,o){return!(n=e(t,r,o))})),!!n}function no(t,e,n){var r=0,o=null==t?r:t.length;if("number"==typeof e&&e==e&&o<=2147483647){for(;r<o;){var i=r+o>>>1,s=t[i];null!==s&&!aa(s)&&(n?s<=e:s<e)?r=i+1:o=i}return o}return ro(t,e,nu,n)}function ro(t,e,n,r){var i=0,s=null==t?0:t.length;if(0===s)return 0;for(var a=(e=n(e))!=e,u=null===e,c=aa(e),l=e===o;i<s;){var f=pe((i+s)/2),h=n(t[f]),p=h!==o,d=null===h,g=h==h,m=aa(h);if(a)var y=r||g;else y=l?g&&(r||p):u?g&&p&&(r||!d):c?g&&p&&!d&&(r||!m):!d&&!m&&(r?h<=e:h<e);y?i=f+1:s=f}return yn(s,4294967294)}function oo(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n],a=e?e(s):s;if(!n||!Hs(a,u)){var u=a;i[o++]=0===s?0:s}}return i}function io(t){return"number"==typeof t?t:aa(t)?h:+t}function so(t){if("string"==typeof t)return t;if(Us(t))return Ne(t,so)+"";if(aa(t))return Bn?Bn.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function ao(t,e,n){var r=-1,o=Se,i=t.length,s=!0,a=[],u=a;if(n)s=!1,o=Oe;else if(i>=200){var c=e?null:qo(t);if(c)return un(c);s=!1,o=Qe,u=new Yn}else u=e?[]:a;t:for(;++r<i;){var l=t[r],f=e?e(l):l;if(l=n||0!==l?l:0,s&&f==f){for(var h=u.length;h--;)if(u[h]===f)continue t;e&&u.push(f),a.push(l)}else o(u,f,n)||(u!==a&&u.push(f),a.push(l))}return a}function uo(t,e){return null==(t=xi(t,e=yo(e,t)))||delete t[Ri(zi(e))]}function co(t,e,n,r){return Jr(t,e,n(wr(t,e)),r)}function lo(t,e,n,r){for(var o=t.length,i=r?o:-1;(r?i--:++i<o)&&e(t[i],i,t););return n?to(t,r?0:i,r?i+1:o):to(t,r?i+1:0,r?o:i)}function fo(t,e){var n=t;return n instanceof jn&&(n=n.value()),$e(e,(function(t,e){return e.func.apply(e.thisArg,Le([t],e.args))}),n)}function ho(t,e,n){var o=t.length;if(o<2)return o?ao(t[0]):[];for(var i=-1,s=r(o);++i<o;)for(var a=t[i],u=-1;++u<o;)u!=i&&(s[i]=cr(s[i]||a,t[u],e,n));return ao(gr(s,1),e,n)}function po(t,e,n){for(var r=-1,i=t.length,s=e.length,a={};++r<i;){var u=r<s?e[r]:o;n(a,t[r],u)}return a}function go(t){return Ys(t)?t:[]}function mo(t){return"function"==typeof t?t:nu}function yo(t,e){return Us(t)?t:vi(t,e)?[t]:Di(ya(t))}var vo=qr;function bo(t,e,n){var r=t.length;return n=n===o?r:n,!e&&n>=r?t:to(t,e,n)}var Co=se||function(t){return fe.clearTimeout(t)};function wo(t,e){if(e)return t.slice();var n=t.length,r=Ut?Ut(n):new t.constructor(n);return t.copy(r),r}function Ao(t){var e=new t.constructor(t.byteLength);return new jt(e).set(new jt(t)),e}function Eo(t,e){var n=e?Ao(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function _o(t,e){if(t!==e){var n=t!==o,r=null===t,i=t==t,s=aa(t),a=e!==o,u=null===e,c=e==e,l=aa(e);if(!u&&!l&&!s&&t>e||s&&a&&c&&!u&&!l||r&&a&&c||!n&&c||!i)return 1;if(!r&&!s&&!l&&t<e||l&&n&&i&&!r&&!s||u&&n&&i||!a&&i||!c)return-1}return 0}function xo(t,e,n,o){for(var i=-1,s=t.length,a=n.length,u=-1,c=e.length,l=mn(s-a,0),f=r(c+l),h=!o;++u<c;)f[u]=e[u];for(;++i<a;)(h||i<s)&&(f[n[i]]=t[i]);for(;l--;)f[u++]=t[i++];return f}function To(t,e,n,o){for(var i=-1,s=t.length,a=-1,u=n.length,c=-1,l=e.length,f=mn(s-u,0),h=r(f+l),p=!o;++i<f;)h[i]=t[i];for(var d=i;++c<l;)h[d+c]=e[c];for(;++a<u;)(p||i<s)&&(h[d+n[a]]=t[i++]);return h}function Io(t,e){var n=-1,o=t.length;for(e||(e=r(o));++n<o;)e[n]=t[n];return e}function Po(t,e,n,r){var i=!n;n||(n={});for(var s=-1,a=e.length;++s<a;){var u=e[s],c=r?r(n[u],t[u],u,n,t):o;c===o&&(c=t[u]),i?rr(n,u,c):Zn(n,u,c)}return n}function So(t,e){return function(n,r){var o=Us(n)?_e:er,i=e?e():{};return o(n,t,si(r,2),i)}}function Oo(t){return qr((function(e,n){var r=-1,i=n.length,s=i>1?n[i-1]:o,a=i>2?n[2]:o;for(s=t.length>3&&"function"==typeof s?(i--,s):o,a&&yi(n[0],n[1],a)&&(s=i<3?o:s,i=1),e=_t(e);++r<i;){var u=n[r];u&&t(e,u,r,s)}return e}))}function No(t,e){return function(n,r){if(null==n)return n;if(!Ws(n))return t(n,r);for(var o=n.length,i=e?o:-1,s=_t(n);(e?i--:++i<o)&&!1!==r(s[i],i,s););return n}}function Lo(t){return function(e,n,r){for(var o=-1,i=_t(e),s=r(e),a=s.length;a--;){var u=s[t?a:++o];if(!1===n(i[u],u,i))break}return e}}function $o(t){return function(e){var n=rn(e=ya(e))?fn(e):o,r=n?n[0]:e.charAt(0),i=n?bo(n,1).join(""):e.slice(1);return r[t]()+i}}function Mo(t){return function(e){return $e(Ja(ja(e).replace(Jt,"")),t,"")}}function Do(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=Hn(t.prototype),r=t.apply(n,e);return Zs(r)?r:n}}function Ro(t){return function(e,n,r){var i=_t(e);if(!Ws(e)){var s=si(n,3);e=Oa(e),n=function(t){return s(i[t],t,i)}}var a=t(e,n,r);return a>-1?i[s?e[a]:a]:o}}function Bo(t){return ti((function(e){var n=e.length,r=n,s=Gn.prototype.thru;for(t&&e.reverse();r--;){var a=e[r];if("function"!=typeof a)throw new It(i);if(s&&!u&&"wrapper"==oi(a))var u=new Gn([],!0)}for(r=u?r:n;++r<n;){var c=oi(a=e[r]),l="wrapper"==c?ri(a):o;u=l&&bi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?u[oi(l[0])].apply(u,l[3]):1==a.length&&bi(a)?u[c]():u.thru(a)}return function(){var t=arguments,r=t[0];if(u&&1==t.length&&Us(r))return u.plant(r).value();for(var o=0,i=n?e[o].apply(this,t):r;++o<n;)i=e[o].call(this,i);return i}}))}function Fo(t,e,n,i,s,a,u,l,f,h){var p=e&c,d=1&e,g=2&e,m=24&e,y=512&e,v=g?o:Do(t);return function c(){for(var b=arguments.length,C=r(b),w=b;w--;)C[w]=arguments[w];if(m)var A=ii(c),E=function(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}(C,A);if(i&&(C=xo(C,i,s,m)),a&&(C=To(C,a,u,m)),b-=E,m&&b<h){var _=an(C,A);return Wo(t,e,Fo,c.placeholder,n,C,_,l,f,h-b)}var x=d?n:this,T=g?x[t]:t;return b=C.length,l?C=function(t,e){for(var n=t.length,r=yn(e.length,n),i=Io(t);r--;){var s=e[r];t[r]=mi(s,n)?i[s]:o}return t}(C,l):y&&b>1&&C.reverse(),p&&f<b&&(C.length=f),this&&this!==fe&&this instanceof c&&(T=v||Do(T)),T.apply(x,C)}}function Ho(t,e){return function(n,r){return function(t,e,n,r){return vr(t,(function(t,o,i){e(r,n(t),o,i)})),r}(n,t,e(r),{})}}function ko(t,e){return function(n,r){var i;if(n===o&&r===o)return e;if(n!==o&&(i=n),r!==o){if(i===o)return r;"string"==typeof n||"string"==typeof r?(n=so(n),r=so(r)):(n=io(n),r=io(r)),i=t(n,r)}return i}}function Go(t){return ti((function(e){return e=Ne(e,ze(si())),qr((function(n){var r=this;return t(e,(function(t){return Ee(t,r,n)}))}))}))}function jo(t,e){var n=(e=e===o?" ":so(e)).length;if(n<2)return n?Yr(e,t):e;var r=Yr(e,he(t/ln(e)));return rn(e)?bo(fn(r),0,t).join(""):r.slice(0,t)}function Uo(t){return function(e,n,i){return i&&"number"!=typeof i&&yi(e,n,i)&&(n=i=o),e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n,o){for(var i=-1,s=mn(he((e-t)/(n||1)),0),a=r(s);s--;)a[o?s:++i]=t,t+=n;return a}(e,n,i=i===o?e<n?1:-1:ha(i),t)}}function Vo(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=ga(e),n=ga(n)),t(e,n)}}function Wo(t,e,n,r,i,s,a,c,l,f){var h=8&e;e|=h?u:64,4&(e&=~(h?64:u))||(e&=-4);var p=[t,e,i,h?s:o,h?a:o,h?o:s,h?o:a,c,l,f],d=n.apply(o,p);return bi(t)&&Ii(d,p),d.placeholder=r,Oi(d,t,e)}function Yo(t){var e=Et[t];return function(t,n){if(t=ga(t),(n=null==n?0:yn(pa(n),292))&&Re(t)){var r=(ya(t)+"e").split("e");return+((r=(ya(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var qo=xn&&1/un(new xn([,-0]))[1]==l?function(t){return new xn(t)}:au;function Ko(t){return function(e){var n=hi(e);return n==A?on(e):n==I?cn(e):function(t,e){return Ne(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function zo(t,e,n,s,l,f,h,p){var d=2&e;if(!d&&"function"!=typeof t)throw new It(i);var g=s?s.length:0;if(g||(e&=-97,s=l=o),h=h===o?h:mn(pa(h),0),p=p===o?p:pa(p),g-=l?l.length:0,64&e){var m=s,y=l;s=l=o}var v=d?o:ri(t),b=[t,e,n,s,l,m,y,f,h,p];if(v&&function(t,e){var n=t[1],r=e[1],o=n|r,i=o<131,s=r==c&&8==n||r==c&&256==n&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!i&&!s)return t;1&r&&(t[2]=e[2],o|=1&n?0:4);var u=e[3];if(u){var l=t[3];t[3]=l?xo(l,u,e[4]):u,t[4]=l?an(t[3],a):e[4]}(u=e[5])&&(l=t[5],t[5]=l?To(l,u,e[6]):u,t[6]=l?an(t[5],a):e[6]),(u=e[7])&&(t[7]=u),r&c&&(t[8]=null==t[8]?e[8]:yn(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=o}(b,v),t=b[0],e=b[1],n=b[2],s=b[3],l=b[4],!(p=b[9]=b[9]===o?d?0:t.length:mn(b[9]-g,0))&&24&e&&(e&=-25),e&&1!=e)C=8==e||16==e?function(t,e,n){var i=Do(t);return function s(){for(var a=arguments.length,u=r(a),c=a,l=ii(s);c--;)u[c]=arguments[c];var f=a<3&&u[0]!==l&&u[a-1]!==l?[]:an(u,l);return(a-=f.length)<n?Wo(t,e,Fo,s.placeholder,o,u,f,o,o,n-a):Ee(this&&this!==fe&&this instanceof s?i:t,this,u)}}(t,e,p):e!=u&&33!=e||l.length?Fo.apply(o,b):function(t,e,n,o){var i=1&e,s=Do(t);return function e(){for(var a=-1,u=arguments.length,c=-1,l=o.length,f=r(l+u),h=this&&this!==fe&&this instanceof e?s:t;++c<l;)f[c]=o[c];for(;u--;)f[c++]=arguments[++a];return Ee(h,i?n:this,f)}}(t,e,n,s);else var C=function(t,e,n){var r=1&e,o=Do(t);return function e(){return(this&&this!==fe&&this instanceof e?o:t).apply(r?n:this,arguments)}}(t,e,n);return Oi((v?Qr:Ii)(C,b),t,e)}function Jo(t,e,n,r){return t===o||Hs(t,Ot[n])&&!$t.call(r,n)?e:t}function Qo(t,e,n,r,i,s){return Zs(t)&&Zs(e)&&(s.set(e,t),Hr(t,e,o,Qo,s),s.delete(e)),t}function Xo(t){return ra(t)?o:t}function Zo(t,e,n,r,i,s){var a=1&n,u=t.length,c=e.length;if(u!=c&&!(a&&c>u))return!1;var l=s.get(t),f=s.get(e);if(l&&f)return l==e&&f==t;var h=-1,p=!0,d=2&n?new Yn:o;for(s.set(t,e),s.set(e,t);++h<u;){var g=t[h],m=e[h];if(r)var y=a?r(m,g,h,e,t,s):r(g,m,h,t,e,s);if(y!==o){if(y)continue;p=!1;break}if(d){if(!De(e,(function(t,e){if(!Qe(d,e)&&(g===t||i(g,t,n,r,s)))return d.push(e)}))){p=!1;break}}else if(g!==m&&!i(g,m,n,r,s)){p=!1;break}}return s.delete(t),s.delete(e),p}function ti(t){return Si(_i(t,o,Vi),t+"")}function ei(t){return Ar(t,Oa,li)}function ni(t){return Ar(t,Na,fi)}var ri=Pn?function(t){return Pn.get(t)}:au;function oi(t){for(var e=t.name+"",n=Sn[e],r=$t.call(Sn,e)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==t)return o.name}return e}function ii(t){return($t.call(Fn,"placeholder")?Fn:t).placeholder}function si(){var t=Fn.iteratee||ru;return t=t===ru?$r:t,arguments.length?t(arguments[0],arguments[1]):t}function ai(t,e){var n,r,o=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof e?"string":"hash"]:o.map}function ui(t){for(var e=Oa(t),n=e.length;n--;){var r=e[n],o=t[r];e[n]=[r,o,Ai(o)]}return e}function ci(t,e){var n=function(t,e){return null==t?o:t[e]}(t,e);return Lr(n)?n:o}var li=ge?function(t){return null==t?[]:(t=_t(t),Pe(ge(t),(function(e){return Yt.call(t,e)})))}:du,fi=ge?function(t){for(var e=[];t;)Le(e,li(t)),t=Vt(t);return e}:du,hi=Er;function pi(t,e,n){for(var r=-1,o=(e=yo(e,t)).length,i=!1;++r<o;){var s=Ri(e[r]);if(!(i=null!=t&&n(t,s)))break;t=t[s]}return i||++r!=o?i:!!(o=null==t?0:t.length)&&Xs(o)&&mi(s,o)&&(Us(t)||js(t))}function di(t){return"function"!=typeof t.constructor||wi(t)?{}:Hn(Vt(t))}function gi(t){return Us(t)||js(t)||!!(Kt&&t&&t[Kt])}function mi(t,e){var n=typeof t;return!!(e=null==e?f:e)&&("number"==n||"symbol"!=n&&yt.test(t))&&t>-1&&t%1==0&&t<e}function yi(t,e,n){if(!Zs(n))return!1;var r=typeof e;return!!("number"==r?Ws(n)&&mi(e,n.length):"string"==r&&e in n)&&Hs(n[e],t)}function vi(t,e){if(Us(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!aa(t))||Z.test(t)||!X.test(t)||null!=e&&t in _t(e)}function bi(t){var e=oi(t),n=Fn[e];if("function"!=typeof n||!(e in jn.prototype))return!1;if(t===n)return!0;var r=ri(n);return!!r&&t===r[0]}(An&&hi(new An(new ArrayBuffer(1)))!=L||En&&hi(new En)!=A||_n&&hi(_n.resolve())!=x||xn&&hi(new xn)!=I||Tn&&hi(new Tn)!=O)&&(hi=function(t){var e=Er(t),n=e==_?t.constructor:o,r=n?Bi(n):"";if(r)switch(r){case On:return L;case Nn:return A;case Ln:return x;case $n:return I;case Mn:return O}return e});var Ci=Nt?Js:gu;function wi(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Ot)}function Ai(t){return t==t&&!Zs(t)}function Ei(t,e){return function(n){return null!=n&&n[t]===e&&(e!==o||t in _t(n))}}function _i(t,e,n){return e=mn(e===o?t.length-1:e,0),function(){for(var o=arguments,i=-1,s=mn(o.length-e,0),a=r(s);++i<s;)a[i]=o[e+i];i=-1;for(var u=r(e+1);++i<e;)u[i]=o[i];return u[e]=n(a),Ee(t,this,u)}}function xi(t,e){return e.length<2?t:wr(t,to(e,0,-1))}function Ti(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Ii=Ni(Qr),Pi=le||function(t,e){return fe.setTimeout(t,e)},Si=Ni(Xr);function Oi(t,e,n){var r=e+"";return Si(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(it,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return xe(d,(function(n){var r="_."+n[0];e&n[1]&&!Se(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(st);return e?e[1].split(at):[]}(r),n)))}function Ni(t){var e=0,n=0;return function(){var r=vn(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(o,arguments)}}function Li(t,e){var n=-1,r=t.length,i=r-1;for(e=e===o?r:e;++n<e;){var s=Wr(n,i),a=t[s];t[s]=t[n],t[n]=a}return t.length=e,t}var $i,Mi,Di=($i=$s((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(tt,(function(t,n,r,o){e.push(r?o.replace(lt,"$1"):n||t)})),e}),(function(t){return 500===Mi.size&&Mi.clear(),t})),Mi=$i.cache,$i);function Ri(t){if("string"==typeof t||aa(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Bi(t){if(null!=t){try{return Lt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Fi(t){if(t instanceof jn)return t.clone();var e=new Gn(t.__wrapped__,t.__chain__);return e.__actions__=Io(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var Hi=qr((function(t,e){return Ys(t)?cr(t,gr(e,1,Ys,!0)):[]})),ki=qr((function(t,e){var n=zi(e);return Ys(n)&&(n=o),Ys(t)?cr(t,gr(e,1,Ys,!0),si(n,2)):[]})),Gi=qr((function(t,e){var n=zi(e);return Ys(n)&&(n=o),Ys(t)?cr(t,gr(e,1,Ys,!0),o,n):[]}));function ji(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:pa(n);return o<0&&(o=mn(r+o,0)),Fe(t,si(e,3),o)}function Ui(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r-1;return n!==o&&(i=pa(n),i=n<0?mn(r+i,0):yn(i,r-1)),Fe(t,si(e,3),i,!0)}function Vi(t){return null!=t&&t.length?gr(t,1):[]}function Wi(t){return t&&t.length?t[0]:o}var Yi=qr((function(t){var e=Ne(t,go);return e.length&&e[0]===t[0]?Ir(e):[]})),qi=qr((function(t){var e=zi(t),n=Ne(t,go);return e===zi(n)?e=o:n.pop(),n.length&&n[0]===t[0]?Ir(n,si(e,2)):[]})),Ki=qr((function(t){var e=zi(t),n=Ne(t,go);return(e="function"==typeof e?e:o)&&n.pop(),n.length&&n[0]===t[0]?Ir(n,o,e):[]}));function zi(t){var e=null==t?0:t.length;return e?t[e-1]:o}var Ji=qr(Qi);function Qi(t,e){return t&&t.length&&e&&e.length?Ur(t,e):t}var Xi=ti((function(t,e){var n=null==t?0:t.length,r=or(t,e);return Vr(t,Ne(e,(function(t){return mi(t,n)?+t:t})).sort(_o)),r}));function Zi(t){return null==t?t:wn.call(t)}var ts=qr((function(t){return ao(gr(t,1,Ys,!0))})),es=qr((function(t){var e=zi(t);return Ys(e)&&(e=o),ao(gr(t,1,Ys,!0),si(e,2))})),ns=qr((function(t){var e=zi(t);return e="function"==typeof e?e:o,ao(gr(t,1,Ys,!0),o,e)}));function rs(t){if(!t||!t.length)return[];var e=0;return t=Pe(t,(function(t){if(Ys(t))return e=mn(t.length,e),!0})),qe(e,(function(e){return Ne(t,Ue(e))}))}function os(t,e){if(!t||!t.length)return[];var n=rs(t);return null==e?n:Ne(n,(function(t){return Ee(e,o,t)}))}var is=qr((function(t,e){return Ys(t)?cr(t,e):[]})),ss=qr((function(t){return ho(Pe(t,Ys))})),as=qr((function(t){var e=zi(t);return Ys(e)&&(e=o),ho(Pe(t,Ys),si(e,2))})),us=qr((function(t){var e=zi(t);return e="function"==typeof e?e:o,ho(Pe(t,Ys),o,e)})),cs=qr(rs),ls=qr((function(t){var e=t.length,n=e>1?t[e-1]:o;return n="function"==typeof n?(t.pop(),n):o,os(t,n)}));function fs(t){var e=Fn(t);return e.__chain__=!0,e}function hs(t,e){return e(t)}var ps=ti((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return or(e,t)};return!(e>1||this.__actions__.length)&&r instanceof jn&&mi(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:hs,args:[i],thisArg:o}),new Gn(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(o),t}))):this.thru(i)})),ds=So((function(t,e,n){$t.call(t,n)?++t[n]:rr(t,n,1)})),gs=Ro(ji),ms=Ro(Ui);function ys(t,e){return(Us(t)?xe:lr)(t,si(e,3))}function vs(t,e){return(Us(t)?Te:fr)(t,si(e,3))}var bs=So((function(t,e,n){$t.call(t,n)?t[n].push(e):rr(t,n,[e])})),Cs=qr((function(t,e,n){var o=-1,i="function"==typeof e,s=Ws(t)?r(t.length):[];return lr(t,(function(t){s[++o]=i?Ee(e,t,n):Pr(t,e,n)})),s})),ws=So((function(t,e,n){rr(t,n,e)}));function As(t,e){return(Us(t)?Ne:Rr)(t,si(e,3))}var Es=So((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]})),_s=qr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&yi(t,e[0],e[1])?e=[]:n>2&&yi(e[0],e[1],e[2])&&(e=[e[0]]),Gr(t,gr(e,1),[])})),xs=ce||function(){return fe.Date.now()};function Ts(t,e,n){return e=n?o:e,e=t&&null==e?t.length:e,zo(t,c,o,o,o,o,e)}function Is(t,e){var n;if("function"!=typeof e)throw new It(i);return t=pa(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=o),n}}var Ps=qr((function(t,e,n){var r=1;if(n.length){var o=an(n,ii(Ps));r|=u}return zo(t,r,e,n,o)})),Ss=qr((function(t,e,n){var r=3;if(n.length){var o=an(n,ii(Ss));r|=u}return zo(e,r,t,n,o)}));function Os(t,e,n){var r,s,a,u,c,l,f=0,h=!1,p=!1,d=!0;if("function"!=typeof t)throw new It(i);function g(e){var n=r,i=s;return r=s=o,f=e,u=t.apply(i,n)}function m(t){var n=t-l;return l===o||n>=e||n<0||p&&t-f>=a}function y(){var t=xs();if(m(t))return v(t);c=Pi(y,function(t){var n=e-(t-l);return p?yn(n,a-(t-f)):n}(t))}function v(t){return c=o,d&&r?g(t):(r=s=o,u)}function b(){var t=xs(),n=m(t);if(r=arguments,s=this,l=t,n){if(c===o)return function(t){return f=t,c=Pi(y,e),h?g(t):u}(l);if(p)return Co(c),c=Pi(y,e),g(l)}return c===o&&(c=Pi(y,e)),u}return e=ga(e)||0,Zs(n)&&(h=!!n.leading,a=(p="maxWait"in n)?mn(ga(n.maxWait)||0,e):a,d="trailing"in n?!!n.trailing:d),b.cancel=function(){c!==o&&Co(c),f=0,r=l=s=c=o},b.flush=function(){return c===o?u:v(xs())},b}var Ns=qr((function(t,e){return ur(t,1,e)})),Ls=qr((function(t,e,n){return ur(t,ga(e)||0,n)}));function $s(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new It(i);var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var s=t.apply(this,r);return n.cache=i.set(o,s)||i,s};return n.cache=new($s.Cache||Wn),n}function Ms(t){if("function"!=typeof t)throw new It(i);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}$s.Cache=Wn;var Ds=vo((function(t,e){var n=(e=1==e.length&&Us(e[0])?Ne(e[0],ze(si())):Ne(gr(e,1),ze(si()))).length;return qr((function(r){for(var o=-1,i=yn(r.length,n);++o<i;)r[o]=e[o].call(this,r[o]);return Ee(t,this,r)}))})),Rs=qr((function(t,e){var n=an(e,ii(Rs));return zo(t,u,o,e,n)})),Bs=qr((function(t,e){var n=an(e,ii(Bs));return zo(t,64,o,e,n)})),Fs=ti((function(t,e){return zo(t,256,o,o,o,e)}));function Hs(t,e){return t===e||t!=t&&e!=e}var ks=Vo(_r),Gs=Vo((function(t,e){return t>=e})),js=Sr(function(){return arguments}())?Sr:function(t){return ta(t)&&$t.call(t,"callee")&&!Yt.call(t,"callee")},Us=r.isArray,Vs=ye?ze(ye):function(t){return ta(t)&&Er(t)==N};function Ws(t){return null!=t&&Xs(t.length)&&!Js(t)}function Ys(t){return ta(t)&&Ws(t)}var qs=me||gu,Ks=ve?ze(ve):function(t){return ta(t)&&Er(t)==v};function zs(t){if(!ta(t))return!1;var e=Er(t);return e==b||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!ra(t)}function Js(t){if(!Zs(t))return!1;var e=Er(t);return e==C||e==w||"[object AsyncFunction]"==e||"[object Proxy]"==e}function Qs(t){return"number"==typeof t&&t==pa(t)}function Xs(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=f}function Zs(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ta(t){return null!=t&&"object"==typeof t}var ea=be?ze(be):function(t){return ta(t)&&hi(t)==A};function na(t){return"number"==typeof t||ta(t)&&Er(t)==E}function ra(t){if(!ta(t)||Er(t)!=_)return!1;var e=Vt(t);if(null===e)return!0;var n=$t.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Lt.call(n)==Bt}var oa=Ce?ze(Ce):function(t){return ta(t)&&Er(t)==T},ia=we?ze(we):function(t){return ta(t)&&hi(t)==I};function sa(t){return"string"==typeof t||!Us(t)&&ta(t)&&Er(t)==P}function aa(t){return"symbol"==typeof t||ta(t)&&Er(t)==S}var ua=Ae?ze(Ae):function(t){return ta(t)&&Xs(t.length)&&!!oe[Er(t)]},ca=Vo(Dr),la=Vo((function(t,e){return t<=e}));function fa(t){if(!t)return[];if(Ws(t))return sa(t)?fn(t):Io(t);if(zt&&t[zt])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[zt]());var e=hi(t);return(e==A?on:e==I?un:Ha)(t)}function ha(t){return t?(t=ga(t))===l||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function pa(t){var e=ha(t),n=e%1;return e==e?n?e-n:e:0}function da(t){return t?ir(pa(t),0,p):0}function ga(t){if("number"==typeof t)return t;if(aa(t))return h;if(Zs(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Zs(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ke(t);var n=dt.test(t);return n||mt.test(t)?ue(t.slice(2),n?2:8):pt.test(t)?h:+t}function ma(t){return Po(t,Na(t))}function ya(t){return null==t?"":so(t)}var va=Oo((function(t,e){if(wi(e)||Ws(e))Po(e,Oa(e),t);else for(var n in e)$t.call(e,n)&&Zn(t,n,e[n])})),ba=Oo((function(t,e){Po(e,Na(e),t)})),Ca=Oo((function(t,e,n,r){Po(e,Na(e),t,r)})),wa=Oo((function(t,e,n,r){Po(e,Oa(e),t,r)})),Aa=ti(or),Ea=qr((function(t,e){t=_t(t);var n=-1,r=e.length,i=r>2?e[2]:o;for(i&&yi(e[0],e[1],i)&&(r=1);++n<r;)for(var s=e[n],a=Na(s),u=-1,c=a.length;++u<c;){var l=a[u],f=t[l];(f===o||Hs(f,Ot[l])&&!$t.call(t,l))&&(t[l]=s[l])}return t})),_a=qr((function(t){return t.push(o,Qo),Ee($a,o,t)}));function xa(t,e,n){var r=null==t?o:wr(t,e);return r===o?n:r}function Ta(t,e){return null!=t&&pi(t,e,Tr)}var Ia=Ho((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Rt.call(e)),t[e]=n}),Za(nu)),Pa=Ho((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Rt.call(e)),$t.call(t,e)?t[e].push(n):t[e]=[n]}),si),Sa=qr(Pr);function Oa(t){return Ws(t)?Kn(t):Mr(t)}function Na(t){return Ws(t)?Kn(t,!0):function(t){if(!Zs(t))return function(t){var e=[];if(null!=t)for(var n in _t(t))e.push(n);return e}(t);var e=wi(t),n=[];for(var r in t)("constructor"!=r||!e&&$t.call(t,r))&&n.push(r);return n}(t)}var La=Oo((function(t,e,n){Hr(t,e,n)})),$a=Oo((function(t,e,n,r){Hr(t,e,n,r)})),Ma=ti((function(t,e){var n={};if(null==t)return n;var r=!1;e=Ne(e,(function(e){return e=yo(e,t),r||(r=e.length>1),e})),Po(t,ni(t),n),r&&(n=sr(n,7,Xo));for(var o=e.length;o--;)uo(n,e[o]);return n})),Da=ti((function(t,e){return null==t?{}:function(t,e){return jr(t,e,(function(e,n){return Ta(t,n)}))}(t,e)}));function Ra(t,e){if(null==t)return{};var n=Ne(ni(t),(function(t){return[t]}));return e=si(e),jr(t,n,(function(t,n){return e(t,n[0])}))}var Ba=Ko(Oa),Fa=Ko(Na);function Ha(t){return null==t?[]:Je(t,Oa(t))}var ka=Mo((function(t,e,n){return e=e.toLowerCase(),t+(n?Ga(e):e)}));function Ga(t){return za(ya(t).toLowerCase())}function ja(t){return(t=ya(t))&&t.replace(vt,tn).replace(Qt,"")}var Ua=Mo((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Va=Mo((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Wa=$o("toLowerCase"),Ya=Mo((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()})),qa=Mo((function(t,e,n){return t+(n?" ":"")+za(e)})),Ka=Mo((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),za=$o("toUpperCase");function Ja(t,e,n){return t=ya(t),(e=n?o:e)===o?function(t){return ee.test(t)}(t)?function(t){return t.match(Zt)||[]}(t):function(t){return t.match(ut)||[]}(t):t.match(e)||[]}var Qa=qr((function(t,e){try{return Ee(t,o,e)}catch(t){return zs(t)?t:new wt(t)}})),Xa=ti((function(t,e){return xe(e,(function(e){e=Ri(e),rr(t,e,Ps(t[e],t))})),t}));function Za(t){return function(){return t}}var tu=Bo(),eu=Bo(!0);function nu(t){return t}function ru(t){return $r("function"==typeof t?t:sr(t,1))}var ou=qr((function(t,e){return function(n){return Pr(n,t,e)}})),iu=qr((function(t,e){return function(n){return Pr(t,n,e)}}));function su(t,e,n){var r=Oa(e),o=Cr(e,r);null!=n||Zs(e)&&(o.length||!r.length)||(n=e,e=t,t=this,o=Cr(e,Oa(e)));var i=!(Zs(n)&&"chain"in n&&!n.chain),s=Js(t);return xe(o,(function(n){var r=e[n];t[n]=r,s&&(t.prototype[n]=function(){var e=this.__chain__;if(i||e){var n=t(this.__wrapped__);return(n.__actions__=Io(this.__actions__)).push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Le([this.value()],arguments))})})),t}function au(){}var uu=Go(Ne),cu=Go(Ie),lu=Go(De);function fu(t){return vi(t)?Ue(Ri(t)):function(t){return function(e){return wr(e,t)}}(t)}var hu=Uo(),pu=Uo(!0);function du(){return[]}function gu(){return!1}var mu,yu=ko((function(t,e){return t+e}),0),vu=Yo("ceil"),bu=ko((function(t,e){return t/e}),1),Cu=Yo("floor"),wu=ko((function(t,e){return t*e}),1),Au=Yo("round"),Eu=ko((function(t,e){return t-e}),0);return Fn.after=function(t,e){if("function"!=typeof e)throw new It(i);return t=pa(t),function(){if(--t<1)return e.apply(this,arguments)}},Fn.ary=Ts,Fn.assign=va,Fn.assignIn=ba,Fn.assignInWith=Ca,Fn.assignWith=wa,Fn.at=Aa,Fn.before=Is,Fn.bind=Ps,Fn.bindAll=Xa,Fn.bindKey=Ss,Fn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Us(t)?t:[t]},Fn.chain=fs,Fn.chunk=function(t,e,n){e=(n?yi(t,e,n):e===o)?1:mn(pa(e),0);var i=null==t?0:t.length;if(!i||e<1)return[];for(var s=0,a=0,u=r(he(i/e));s<i;)u[a++]=to(t,s,s+=e);return u},Fn.compact=function(t){for(var e=-1,n=null==t?0:t.length,r=0,o=[];++e<n;){var i=t[e];i&&(o[r++]=i)}return o},Fn.concat=function(){var t=arguments.length;if(!t)return[];for(var e=r(t-1),n=arguments[0],o=t;o--;)e[o-1]=arguments[o];return Le(Us(n)?Io(n):[n],gr(e,1))},Fn.cond=function(t){var e=null==t?0:t.length,n=si();return t=e?Ne(t,(function(t){if("function"!=typeof t[1])throw new It(i);return[n(t[0]),t[1]]})):[],qr((function(n){for(var r=-1;++r<e;){var o=t[r];if(Ee(o[0],this,n))return Ee(o[1],this,n)}}))},Fn.conforms=function(t){return function(t){var e=Oa(t);return function(n){return ar(n,t,e)}}(sr(t,1))},Fn.constant=Za,Fn.countBy=ds,Fn.create=function(t,e){var n=Hn(t);return null==e?n:nr(n,e)},Fn.curry=function t(e,n,r){var i=zo(e,8,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Fn.curryRight=function t(e,n,r){var i=zo(e,16,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Fn.debounce=Os,Fn.defaults=Ea,Fn.defaultsDeep=_a,Fn.defer=Ns,Fn.delay=Ls,Fn.difference=Hi,Fn.differenceBy=ki,Fn.differenceWith=Gi,Fn.drop=function(t,e,n){var r=null==t?0:t.length;return r?to(t,(e=n||e===o?1:pa(e))<0?0:e,r):[]},Fn.dropRight=function(t,e,n){var r=null==t?0:t.length;return r?to(t,0,(e=r-(e=n||e===o?1:pa(e)))<0?0:e):[]},Fn.dropRightWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!0,!0):[]},Fn.dropWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!0):[]},Fn.fill=function(t,e,n,r){var i=null==t?0:t.length;return i?(n&&"number"!=typeof n&&yi(t,e,n)&&(n=0,r=i),function(t,e,n,r){var i=t.length;for((n=pa(n))<0&&(n=-n>i?0:i+n),(r=r===o||r>i?i:pa(r))<0&&(r+=i),r=n>r?0:da(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},Fn.filter=function(t,e){return(Us(t)?Pe:dr)(t,si(e,3))},Fn.flatMap=function(t,e){return gr(As(t,e),1)},Fn.flatMapDeep=function(t,e){return gr(As(t,e),l)},Fn.flatMapDepth=function(t,e,n){return n=n===o?1:pa(n),gr(As(t,e),n)},Fn.flatten=Vi,Fn.flattenDeep=function(t){return null!=t&&t.length?gr(t,l):[]},Fn.flattenDepth=function(t,e){return null!=t&&t.length?gr(t,e=e===o?1:pa(e)):[]},Fn.flip=function(t){return zo(t,512)},Fn.flow=tu,Fn.flowRight=eu,Fn.fromPairs=function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var o=t[e];r[o[0]]=o[1]}return r},Fn.functions=function(t){return null==t?[]:Cr(t,Oa(t))},Fn.functionsIn=function(t){return null==t?[]:Cr(t,Na(t))},Fn.groupBy=bs,Fn.initial=function(t){return null!=t&&t.length?to(t,0,-1):[]},Fn.intersection=Yi,Fn.intersectionBy=qi,Fn.intersectionWith=Ki,Fn.invert=Ia,Fn.invertBy=Pa,Fn.invokeMap=Cs,Fn.iteratee=ru,Fn.keyBy=ws,Fn.keys=Oa,Fn.keysIn=Na,Fn.map=As,Fn.mapKeys=function(t,e){var n={};return e=si(e,3),vr(t,(function(t,r,o){rr(n,e(t,r,o),t)})),n},Fn.mapValues=function(t,e){var n={};return e=si(e,3),vr(t,(function(t,r,o){rr(n,r,e(t,r,o))})),n},Fn.matches=function(t){return Br(sr(t,1))},Fn.matchesProperty=function(t,e){return Fr(t,sr(e,1))},Fn.memoize=$s,Fn.merge=La,Fn.mergeWith=$a,Fn.method=ou,Fn.methodOf=iu,Fn.mixin=su,Fn.negate=Ms,Fn.nthArg=function(t){return t=pa(t),qr((function(e){return kr(e,t)}))},Fn.omit=Ma,Fn.omitBy=function(t,e){return Ra(t,Ms(si(e)))},Fn.once=function(t){return Is(2,t)},Fn.orderBy=function(t,e,n,r){return null==t?[]:(Us(e)||(e=null==e?[]:[e]),Us(n=r?o:n)||(n=null==n?[]:[n]),Gr(t,e,n))},Fn.over=uu,Fn.overArgs=Ds,Fn.overEvery=cu,Fn.overSome=lu,Fn.partial=Rs,Fn.partialRight=Bs,Fn.partition=Es,Fn.pick=Da,Fn.pickBy=Ra,Fn.property=fu,Fn.propertyOf=function(t){return function(e){return null==t?o:wr(t,e)}},Fn.pull=Ji,Fn.pullAll=Qi,Fn.pullAllBy=function(t,e,n){return t&&t.length&&e&&e.length?Ur(t,e,si(n,2)):t},Fn.pullAllWith=function(t,e,n){return t&&t.length&&e&&e.length?Ur(t,e,o,n):t},Fn.pullAt=Xi,Fn.range=hu,Fn.rangeRight=pu,Fn.rearg=Fs,Fn.reject=function(t,e){return(Us(t)?Pe:dr)(t,Ms(si(e,3)))},Fn.remove=function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,o=[],i=t.length;for(e=si(e,3);++r<i;){var s=t[r];e(s,r,t)&&(n.push(s),o.push(r))}return Vr(t,o),n},Fn.rest=function(t,e){if("function"!=typeof t)throw new It(i);return qr(t,e=e===o?e:pa(e))},Fn.reverse=Zi,Fn.sampleSize=function(t,e,n){return e=(n?yi(t,e,n):e===o)?1:pa(e),(Us(t)?Jn:zr)(t,e)},Fn.set=function(t,e,n){return null==t?t:Jr(t,e,n)},Fn.setWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:Jr(t,e,n,r)},Fn.shuffle=function(t){return(Us(t)?Qn:Zr)(t)},Fn.slice=function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&yi(t,e,n)?(e=0,n=r):(e=null==e?0:pa(e),n=n===o?r:pa(n)),to(t,e,n)):[]},Fn.sortBy=_s,Fn.sortedUniq=function(t){return t&&t.length?oo(t):[]},Fn.sortedUniqBy=function(t,e){return t&&t.length?oo(t,si(e,2)):[]},Fn.split=function(t,e,n){return n&&"number"!=typeof n&&yi(t,e,n)&&(e=n=o),(n=n===o?p:n>>>0)?(t=ya(t))&&("string"==typeof e||null!=e&&!oa(e))&&!(e=so(e))&&rn(t)?bo(fn(t),0,n):t.split(e,n):[]},Fn.spread=function(t,e){if("function"!=typeof t)throw new It(i);return e=null==e?0:mn(pa(e),0),qr((function(n){var r=n[e],o=bo(n,0,e);return r&&Le(o,r),Ee(t,this,o)}))},Fn.tail=function(t){var e=null==t?0:t.length;return e?to(t,1,e):[]},Fn.take=function(t,e,n){return t&&t.length?to(t,0,(e=n||e===o?1:pa(e))<0?0:e):[]},Fn.takeRight=function(t,e,n){var r=null==t?0:t.length;return r?to(t,(e=r-(e=n||e===o?1:pa(e)))<0?0:e,r):[]},Fn.takeRightWhile=function(t,e){return t&&t.length?lo(t,si(e,3),!1,!0):[]},Fn.takeWhile=function(t,e){return t&&t.length?lo(t,si(e,3)):[]},Fn.tap=function(t,e){return e(t),t},Fn.throttle=function(t,e,n){var r=!0,o=!0;if("function"!=typeof t)throw new It(i);return Zs(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),Os(t,e,{leading:r,maxWait:e,trailing:o})},Fn.thru=hs,Fn.toArray=fa,Fn.toPairs=Ba,Fn.toPairsIn=Fa,Fn.toPath=function(t){return Us(t)?Ne(t,Ri):aa(t)?[t]:Io(Di(ya(t)))},Fn.toPlainObject=ma,Fn.transform=function(t,e,n){var r=Us(t),o=r||qs(t)||ua(t);if(e=si(e,4),null==n){var i=t&&t.constructor;n=o?r?new i:[]:Zs(t)&&Js(i)?Hn(Vt(t)):{}}return(o?xe:vr)(t,(function(t,r,o){return e(n,t,r,o)})),n},Fn.unary=function(t){return Ts(t,1)},Fn.union=ts,Fn.unionBy=es,Fn.unionWith=ns,Fn.uniq=function(t){return t&&t.length?ao(t):[]},Fn.uniqBy=function(t,e){return t&&t.length?ao(t,si(e,2)):[]},Fn.uniqWith=function(t,e){return e="function"==typeof e?e:o,t&&t.length?ao(t,o,e):[]},Fn.unset=function(t,e){return null==t||uo(t,e)},Fn.unzip=rs,Fn.unzipWith=os,Fn.update=function(t,e,n){return null==t?t:co(t,e,mo(n))},Fn.updateWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:co(t,e,mo(n),r)},Fn.values=Ha,Fn.valuesIn=function(t){return null==t?[]:Je(t,Na(t))},Fn.without=is,Fn.words=Ja,Fn.wrap=function(t,e){return Rs(mo(e),t)},Fn.xor=ss,Fn.xorBy=as,Fn.xorWith=us,Fn.zip=cs,Fn.zipObject=function(t,e){return po(t||[],e||[],Zn)},Fn.zipObjectDeep=function(t,e){return po(t||[],e||[],Jr)},Fn.zipWith=ls,Fn.entries=Ba,Fn.entriesIn=Fa,Fn.extend=ba,Fn.extendWith=Ca,su(Fn,Fn),Fn.add=yu,Fn.attempt=Qa,Fn.camelCase=ka,Fn.capitalize=Ga,Fn.ceil=vu,Fn.clamp=function(t,e,n){return n===o&&(n=e,e=o),n!==o&&(n=(n=ga(n))==n?n:0),e!==o&&(e=(e=ga(e))==e?e:0),ir(ga(t),e,n)},Fn.clone=function(t){return sr(t,4)},Fn.cloneDeep=function(t){return sr(t,5)},Fn.cloneDeepWith=function(t,e){return sr(t,5,e="function"==typeof e?e:o)},Fn.cloneWith=function(t,e){return sr(t,4,e="function"==typeof e?e:o)},Fn.conformsTo=function(t,e){return null==e||ar(t,e,Oa(e))},Fn.deburr=ja,Fn.defaultTo=function(t,e){return null==t||t!=t?e:t},Fn.divide=bu,Fn.endsWith=function(t,e,n){t=ya(t),e=so(e);var r=t.length,i=n=n===o?r:ir(pa(n),0,r);return(n-=e.length)>=0&&t.slice(n,i)==e},Fn.eq=Hs,Fn.escape=function(t){return(t=ya(t))&&K.test(t)?t.replace(Y,en):t},Fn.escapeRegExp=function(t){return(t=ya(t))&&nt.test(t)?t.replace(et,"\\$&"):t},Fn.every=function(t,e,n){var r=Us(t)?Ie:hr;return n&&yi(t,e,n)&&(e=o),r(t,si(e,3))},Fn.find=gs,Fn.findIndex=ji,Fn.findKey=function(t,e){return Be(t,si(e,3),vr)},Fn.findLast=ms,Fn.findLastIndex=Ui,Fn.findLastKey=function(t,e){return Be(t,si(e,3),br)},Fn.floor=Cu,Fn.forEach=ys,Fn.forEachRight=vs,Fn.forIn=function(t,e){return null==t?t:mr(t,si(e,3),Na)},Fn.forInRight=function(t,e){return null==t?t:yr(t,si(e,3),Na)},Fn.forOwn=function(t,e){return t&&vr(t,si(e,3))},Fn.forOwnRight=function(t,e){return t&&br(t,si(e,3))},Fn.get=xa,Fn.gt=ks,Fn.gte=Gs,Fn.has=function(t,e){return null!=t&&pi(t,e,xr)},Fn.hasIn=Ta,Fn.head=Wi,Fn.identity=nu,Fn.includes=function(t,e,n,r){t=Ws(t)?t:Ha(t),n=n&&!r?pa(n):0;var o=t.length;return n<0&&(n=mn(o+n,0)),sa(t)?n<=o&&t.indexOf(e,n)>-1:!!o&&He(t,e,n)>-1},Fn.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:pa(n);return o<0&&(o=mn(r+o,0)),He(t,e,o)},Fn.inRange=function(t,e,n){return e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n){return t>=yn(e,n)&&t<mn(e,n)}(t=ga(t),e,n)},Fn.invoke=Sa,Fn.isArguments=js,Fn.isArray=Us,Fn.isArrayBuffer=Vs,Fn.isArrayLike=Ws,Fn.isArrayLikeObject=Ys,Fn.isBoolean=function(t){return!0===t||!1===t||ta(t)&&Er(t)==y},Fn.isBuffer=qs,Fn.isDate=Ks,Fn.isElement=function(t){return ta(t)&&1===t.nodeType&&!ra(t)},Fn.isEmpty=function(t){if(null==t)return!0;if(Ws(t)&&(Us(t)||"string"==typeof t||"function"==typeof t.splice||qs(t)||ua(t)||js(t)))return!t.length;var e=hi(t);if(e==A||e==I)return!t.size;if(wi(t))return!Mr(t).length;for(var n in t)if($t.call(t,n))return!1;return!0},Fn.isEqual=function(t,e){return Or(t,e)},Fn.isEqualWith=function(t,e,n){var r=(n="function"==typeof n?n:o)?n(t,e):o;return r===o?Or(t,e,o,n):!!r},Fn.isError=zs,Fn.isFinite=function(t){return"number"==typeof t&&Re(t)},Fn.isFunction=Js,Fn.isInteger=Qs,Fn.isLength=Xs,Fn.isMap=ea,Fn.isMatch=function(t,e){return t===e||Nr(t,e,ui(e))},Fn.isMatchWith=function(t,e,n){return n="function"==typeof n?n:o,Nr(t,e,ui(e),n)},Fn.isNaN=function(t){return na(t)&&t!=+t},Fn.isNative=function(t){if(Ci(t))throw new wt("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Lr(t)},Fn.isNil=function(t){return null==t},Fn.isNull=function(t){return null===t},Fn.isNumber=na,Fn.isObject=Zs,Fn.isObjectLike=ta,Fn.isPlainObject=ra,Fn.isRegExp=oa,Fn.isSafeInteger=function(t){return Qs(t)&&t>=-9007199254740991&&t<=f},Fn.isSet=ia,Fn.isString=sa,Fn.isSymbol=aa,Fn.isTypedArray=ua,Fn.isUndefined=function(t){return t===o},Fn.isWeakMap=function(t){return ta(t)&&hi(t)==O},Fn.isWeakSet=function(t){return ta(t)&&"[object WeakSet]"==Er(t)},Fn.join=function(t,e){return null==t?"":Ve.call(t,e)},Fn.kebabCase=Ua,Fn.last=zi,Fn.lastIndexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r;return n!==o&&(i=(i=pa(n))<0?mn(r+i,0):yn(i,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,i):Fe(t,Ge,i,!0)},Fn.lowerCase=Va,Fn.lowerFirst=Wa,Fn.lt=ca,Fn.lte=la,Fn.max=function(t){return t&&t.length?pr(t,nu,_r):o},Fn.maxBy=function(t,e){return t&&t.length?pr(t,si(e,2),_r):o},Fn.mean=function(t){return je(t,nu)},Fn.meanBy=function(t,e){return je(t,si(e,2))},Fn.min=function(t){return t&&t.length?pr(t,nu,Dr):o},Fn.minBy=function(t,e){return t&&t.length?pr(t,si(e,2),Dr):o},Fn.stubArray=du,Fn.stubFalse=gu,Fn.stubObject=function(){return{}},Fn.stubString=function(){return""},Fn.stubTrue=function(){return!0},Fn.multiply=wu,Fn.nth=function(t,e){return t&&t.length?kr(t,pa(e)):o},Fn.noConflict=function(){return fe._===this&&(fe._=Ft),this},Fn.noop=au,Fn.now=xs,Fn.pad=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;if(!e||r>=e)return t;var o=(e-r)/2;return jo(pe(o),n)+t+jo(he(o),n)},Fn.padEnd=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;return e&&r<e?t+jo(e-r,n):t},Fn.padStart=function(t,e,n){t=ya(t);var r=(e=pa(e))?ln(t):0;return e&&r<e?jo(e-r,n)+t:t},Fn.parseInt=function(t,e,n){return n||null==e?e=0:e&&(e=+e),bn(ya(t).replace(rt,""),e||0)},Fn.random=function(t,e,n){if(n&&"boolean"!=typeof n&&yi(t,e,n)&&(e=n=o),n===o&&("boolean"==typeof e?(n=e,e=o):"boolean"==typeof t&&(n=t,t=o)),t===o&&e===o?(t=0,e=1):(t=ha(t),e===o?(e=t,t=0):e=ha(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var i=Cn();return yn(t+i*(e-t+ae("1e-"+((i+"").length-1))),e)}return Wr(t,e)},Fn.reduce=function(t,e,n){var r=Us(t)?$e:We,o=arguments.length<3;return r(t,si(e,4),n,o,lr)},Fn.reduceRight=function(t,e,n){var r=Us(t)?Me:We,o=arguments.length<3;return r(t,si(e,4),n,o,fr)},Fn.repeat=function(t,e,n){return e=(n?yi(t,e,n):e===o)?1:pa(e),Yr(ya(t),e)},Fn.replace=function(){var t=arguments,e=ya(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Fn.result=function(t,e,n){var r=-1,i=(e=yo(e,t)).length;for(i||(i=1,t=o);++r<i;){var s=null==t?o:t[Ri(e[r])];s===o&&(r=i,s=n),t=Js(s)?s.call(t):s}return t},Fn.round=Au,Fn.runInContext=t,Fn.sample=function(t){return(Us(t)?zn:Kr)(t)},Fn.size=function(t){if(null==t)return 0;if(Ws(t))return sa(t)?ln(t):t.length;var e=hi(t);return e==A||e==I?t.size:Mr(t).length},Fn.snakeCase=Ya,Fn.some=function(t,e,n){var r=Us(t)?De:eo;return n&&yi(t,e,n)&&(e=o),r(t,si(e,3))},Fn.sortedIndex=function(t,e){return no(t,e)},Fn.sortedIndexBy=function(t,e,n){return ro(t,e,si(n,2))},Fn.sortedIndexOf=function(t,e){var n=null==t?0:t.length;if(n){var r=no(t,e);if(r<n&&Hs(t[r],e))return r}return-1},Fn.sortedLastIndex=function(t,e){return no(t,e,!0)},Fn.sortedLastIndexBy=function(t,e,n){return ro(t,e,si(n,2),!0)},Fn.sortedLastIndexOf=function(t,e){if(null!=t&&t.length){var n=no(t,e,!0)-1;if(Hs(t[n],e))return n}return-1},Fn.startCase=qa,Fn.startsWith=function(t,e,n){return t=ya(t),n=null==n?0:ir(pa(n),0,t.length),e=so(e),t.slice(n,n+e.length)==e},Fn.subtract=Eu,Fn.sum=function(t){return t&&t.length?Ye(t,nu):0},Fn.sumBy=function(t,e){return t&&t.length?Ye(t,si(e,2)):0},Fn.template=function(t,e,n){var r=Fn.templateSettings;n&&yi(t,e,n)&&(e=o),t=ya(t),e=Ca({},e,r,Jo);var i,s,a=Ca({},e.imports,r.imports,Jo),u=Oa(a),c=Je(a,u),l=0,f=e.interpolate||bt,h="__p += '",p=xt((e.escape||bt).source+"|"+f.source+"|"+(f===Q?ft:bt).source+"|"+(e.evaluate||bt).source+"|$","g"),d="//# sourceURL="+($t.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++re+"]")+"\n";t.replace(p,(function(e,n,r,o,a,u){return r||(r=o),h+=t.slice(l,u).replace(Ct,nn),n&&(i=!0,h+="' +\n__e("+n+") +\n'"),a&&(s=!0,h+="';\n"+a+";\n__p += '"),r&&(h+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+e.length,e})),h+="';\n";var g=$t.call(e,"variable")&&e.variable;if(g){if(ct.test(g))throw new wt("Invalid `variable` option passed into `_.template`")}else h="with (obj) {\n"+h+"\n}\n";h=(s?h.replace(j,""):h).replace(U,"$1").replace(V,"$1;"),h="function("+(g||"obj")+") {\n"+(g?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+h+"return __p\n}";var m=Qa((function(){return At(u,d+"return "+h).apply(o,c)}));if(m.source=h,zs(m))throw m;return m},Fn.times=function(t,e){if((t=pa(t))<1||t>f)return[];var n=p,r=yn(t,p);e=si(e),t-=p;for(var o=qe(r,e);++n<t;)e(n);return o},Fn.toFinite=ha,Fn.toInteger=pa,Fn.toLength=da,Fn.toLower=function(t){return ya(t).toLowerCase()},Fn.toNumber=ga,Fn.toSafeInteger=function(t){return t?ir(pa(t),-9007199254740991,f):0===t?t:0},Fn.toString=ya,Fn.toUpper=function(t){return ya(t).toUpperCase()},Fn.trim=function(t,e,n){if((t=ya(t))&&(n||e===o))return Ke(t);if(!t||!(e=so(e)))return t;var r=fn(t),i=fn(e);return bo(r,Xe(r,i),Ze(r,i)+1).join("")},Fn.trimEnd=function(t,e,n){if((t=ya(t))&&(n||e===o))return t.slice(0,hn(t)+1);if(!t||!(e=so(e)))return t;var r=fn(t);return bo(r,0,Ze(r,fn(e))+1).join("")},Fn.trimStart=function(t,e,n){if((t=ya(t))&&(n||e===o))return t.replace(rt,"");if(!t||!(e=so(e)))return t;var r=fn(t);return bo(r,Xe(r,fn(e))).join("")},Fn.truncate=function(t,e){var n=30,r="...";if(Zs(e)){var i="separator"in e?e.separator:i;n="length"in e?pa(e.length):n,r="omission"in e?so(e.omission):r}var s=(t=ya(t)).length;if(rn(t)){var a=fn(t);s=a.length}if(n>=s)return t;var u=n-ln(r);if(u<1)return r;var c=a?bo(a,0,u).join(""):t.slice(0,u);if(i===o)return c+r;if(a&&(u+=c.length-u),oa(i)){if(t.slice(u).search(i)){var l,f=c;for(i.global||(i=xt(i.source,ya(ht.exec(i))+"g")),i.lastIndex=0;l=i.exec(f);)var h=l.index;c=c.slice(0,h===o?u:h)}}else if(t.indexOf(so(i),u)!=u){var p=c.lastIndexOf(i);p>-1&&(c=c.slice(0,p))}return c+r},Fn.unescape=function(t){return(t=ya(t))&&q.test(t)?t.replace(W,pn):t},Fn.uniqueId=function(t){var e=++Mt;return ya(t)+e},Fn.upperCase=Ka,Fn.upperFirst=za,Fn.each=ys,Fn.eachRight=vs,Fn.first=Wi,su(Fn,(mu={},vr(Fn,(function(t,e){$t.call(Fn.prototype,e)||(mu[e]=t)})),mu),{chain:!1}),Fn.VERSION="4.17.21",xe(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Fn[t].placeholder=Fn})),xe(["drop","take"],(function(t,e){jn.prototype[t]=function(n){n=n===o?1:mn(pa(n),0);var r=this.__filtered__&&!e?new jn(this):this.clone();return r.__filtered__?r.__takeCount__=yn(n,r.__takeCount__):r.__views__.push({size:yn(n,p),type:t+(r.__dir__<0?"Right":"")}),r},jn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),xe(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;jn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:si(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),xe(["head","last"],(function(t,e){var n="take"+(e?"Right":"");jn.prototype[t]=function(){return this[n](1).value()[0]}})),xe(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");jn.prototype[t]=function(){return this.__filtered__?new jn(this):this[n](1)}})),jn.prototype.compact=function(){return this.filter(nu)},jn.prototype.find=function(t){return this.filter(t).head()},jn.prototype.findLast=function(t){return this.reverse().find(t)},jn.prototype.invokeMap=qr((function(t,e){return"function"==typeof t?new jn(this):this.map((function(n){return Pr(n,t,e)}))})),jn.prototype.reject=function(t){return this.filter(Ms(si(t)))},jn.prototype.slice=function(t,e){t=pa(t);var n=this;return n.__filtered__&&(t>0||e<0)?new jn(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==o&&(n=(e=pa(e))<0?n.dropRight(-e):n.take(e-t)),n)},jn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},jn.prototype.toArray=function(){return this.take(p)},vr(jn.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=Fn[r?"take"+("last"==e?"Right":""):e],s=r||/^find/.test(e);i&&(Fn.prototype[e]=function(){var e=this.__wrapped__,a=r?[1]:arguments,u=e instanceof jn,c=a[0],l=u||Us(e),f=function(t){var e=i.apply(Fn,Le([t],a));return r&&h?e[0]:e};l&&n&&"function"==typeof c&&1!=c.length&&(u=l=!1);var h=this.__chain__,p=!!this.__actions__.length,d=s&&!h,g=u&&!p;if(!s&&l){e=g?e:new jn(this);var m=t.apply(e,a);return m.__actions__.push({func:hs,args:[f],thisArg:o}),new Gn(m,h)}return d&&g?t.apply(this,a):(m=this.thru(f),d?r?m.value()[0]:m.value():m)})})),xe(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Pt[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Fn.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var o=this.value();return e.apply(Us(o)?o:[],t)}return this[n]((function(n){return e.apply(Us(n)?n:[],t)}))}})),vr(jn.prototype,(function(t,e){var n=Fn[e];if(n){var r=n.name+"";$t.call(Sn,r)||(Sn[r]=[]),Sn[r].push({name:e,func:n})}})),Sn[Fo(o,2).name]=[{name:"wrapper",func:o}],jn.prototype.clone=function(){var t=new jn(this.__wrapped__);return t.__actions__=Io(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Io(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Io(this.__views__),t},jn.prototype.reverse=function(){if(this.__filtered__){var t=new jn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},jn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Us(t),r=e<0,o=n?t.length:0,i=function(t,e,n){for(var r=-1,o=n.length;++r<o;){var i=n[r],s=i.size;switch(i.type){case"drop":t+=s;break;case"dropRight":e-=s;break;case"take":e=yn(e,t+s);break;case"takeRight":t=mn(t,e-s)}}return{start:t,end:e}}(0,o,this.__views__),s=i.start,a=i.end,u=a-s,c=r?a:s-1,l=this.__iteratees__,f=l.length,h=0,p=yn(u,this.__takeCount__);if(!n||!r&&o==u&&p==u)return fo(t,this.__actions__);var d=[];t:for(;u--&&h<p;){for(var g=-1,m=t[c+=e];++g<f;){var y=l[g],v=y.iteratee,b=y.type,C=v(m);if(2==b)m=C;else if(!C){if(1==b)continue t;break t}}d[h++]=m}return d},Fn.prototype.at=ps,Fn.prototype.chain=function(){return fs(this)},Fn.prototype.commit=function(){return new Gn(this.value(),this.__chain__)},Fn.prototype.next=function(){this.__values__===o&&(this.__values__=fa(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?o:this.__values__[this.__index__++]}},Fn.prototype.plant=function(t){for(var e,n=this;n instanceof kn;){var r=Fi(n);r.__index__=0,r.__values__=o,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e},Fn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof jn){var e=t;return this.__actions__.length&&(e=new jn(this)),(e=e.reverse()).__actions__.push({func:hs,args:[Zi],thisArg:o}),new Gn(e,this.__chain__)}return this.thru(Zi)},Fn.prototype.toJSON=Fn.prototype.valueOf=Fn.prototype.value=function(){return fo(this.__wrapped__,this.__actions__)},Fn.prototype.first=Fn.prototype.head,zt&&(Fn.prototype[zt]=function(){return this}),Fn}();fe._=dn,(r=function(){return dn}.call(e,n,e,t))===o||(t.exports=r)}.call(this)},802:t=>{t.exports=function t(e,n,r){function o(s,a){if(!n[s]){if(!e[s]){if(i)return i(s,!0);throw new Error("Cannot find module '"+s+"'")}a=n[s]={exports:{}},e[s][0].call(a.exports,(function(t){return o(e[s][1][t]||t)}),a,a.exports,t,e,n,r)}return n[s].exports}for(var i=void 0,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(t,e,n){(function(r,o,i,s,a,u,c,l,f){"use strict";var h=t("crypto");function p(t,e){var n;return void 0===(n="passthrough"!==(e=m(t,e)).algorithm?h.createHash(e.algorithm):new b).write&&(n.write=n.update,n.end=n.update),v(e,n).dispatch(t),n.update||n.end(""),n.digest?n.digest("buffer"===e.encoding?void 0:e.encoding):(t=n.read(),"buffer"!==e.encoding?t.toString(e.encoding):t)}(n=e.exports=p).sha1=function(t){return p(t)},n.keys=function(t){return p(t,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},n.MD5=function(t){return p(t,{algorithm:"md5",encoding:"hex"})},n.keysMD5=function(t){return p(t,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var d=h.getHashes?h.getHashes().slice():["sha1","md5"],g=(d.push("passthrough"),["buffer","hex","binary","base64"]);function m(t,e){var n={};if(n.algorithm=(e=e||{}).algorithm||"sha1",n.encoding=e.encoding||"hex",n.excludeValues=!!e.excludeValues,n.algorithm=n.algorithm.toLowerCase(),n.encoding=n.encoding.toLowerCase(),n.ignoreUnknown=!0===e.ignoreUnknown,n.respectType=!1!==e.respectType,n.respectFunctionNames=!1!==e.respectFunctionNames,n.respectFunctionProperties=!1!==e.respectFunctionProperties,n.unorderedArrays=!0===e.unorderedArrays,n.unorderedSets=!1!==e.unorderedSets,n.unorderedObjects=!1!==e.unorderedObjects,n.replacer=e.replacer||void 0,n.excludeKeys=e.excludeKeys||void 0,void 0===t)throw new Error("Object argument required.");for(var r=0;r<d.length;++r)d[r].toLowerCase()===n.algorithm.toLowerCase()&&(n.algorithm=d[r]);if(-1===d.indexOf(n.algorithm))throw new Error('Algorithm "'+n.algorithm+'" not supported. supported values: '+d.join(", "));if(-1===g.indexOf(n.encoding)&&"passthrough"!==n.algorithm)throw new Error('Encoding "'+n.encoding+'" not supported. supported values: '+g.join(", "));return n}function y(t){if("function"==typeof t)return null!=/^function\s+\w*\s*\(\s*\)\s*{\s+\[native code\]\s+}$/i.exec(Function.prototype.toString.call(t))}function v(t,e,n){function r(t){return e.update?e.update(t,"utf8"):e.write(t,"utf8")}return n=n||[],{dispatch:function(e){return this["_"+(null===(e=t.replacer?t.replacer(e):e)?"null":typeof e)](e)},_object:function(e){var o,s=Object.prototype.toString.call(e),a=/\[object (.*)\]/i.exec(s);if(a=(a=a?a[1]:"unknown:["+s+"]").toLowerCase(),0<=(s=n.indexOf(e)))return this.dispatch("[CIRCULAR:"+s+"]");if(n.push(e),void 0!==i&&i.isBuffer&&i.isBuffer(e))return r("buffer:"),r(e);if("object"===a||"function"===a||"asyncfunction"===a)return s=Object.keys(e),t.unorderedObjects&&(s=s.sort()),!1===t.respectType||y(e)||s.splice(0,0,"prototype","__proto__","constructor"),t.excludeKeys&&(s=s.filter((function(e){return!t.excludeKeys(e)}))),r("object:"+s.length+":"),o=this,s.forEach((function(n){o.dispatch(n),r(":"),t.excludeValues||o.dispatch(e[n]),r(",")}));if(!this["_"+a]){if(t.ignoreUnknown)return r("["+a+"]");throw new Error('Unknown object type "'+a+'"')}this["_"+a](e)},_array:function(e,o){o=void 0!==o?o:!1!==t.unorderedArrays;var i=this;if(r("array:"+e.length+":"),!o||e.length<=1)return e.forEach((function(t){return i.dispatch(t)}));var s=[];return o=e.map((function(e){var r=new b,o=n.slice();return v(t,r,o).dispatch(e),s=s.concat(o.slice(n.length)),r.read().toString()})),n=n.concat(s),o.sort(),this._array(o,!1)},_date:function(t){return r("date:"+t.toJSON())},_symbol:function(t){return r("symbol:"+t.toString())},_error:function(t){return r("error:"+t.toString())},_boolean:function(t){return r("bool:"+t.toString())},_string:function(t){r("string:"+t.length+":"),r(t.toString())},_function:function(e){r("fn:"),y(e)?this.dispatch("[native]"):this.dispatch(e.toString()),!1!==t.respectFunctionNames&&this.dispatch("function-name:"+String(e.name)),t.respectFunctionProperties&&this._object(e)},_number:function(t){return r("number:"+t.toString())},_xml:function(t){return r("xml:"+t.toString())},_null:function(){return r("Null")},_undefined:function(){return r("Undefined")},_regexp:function(t){return r("regex:"+t.toString())},_uint8array:function(t){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint8clampedarray:function(t){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(t))},_int8array:function(t){return r("int8array:"),this.dispatch(Array.prototype.slice.call(t))},_uint16array:function(t){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(t))},_int16array:function(t){return r("int16array:"),this.dispatch(Array.prototype.slice.call(t))},_uint32array:function(t){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(t))},_int32array:function(t){return r("int32array:"),this.dispatch(Array.prototype.slice.call(t))},_float32array:function(t){return r("float32array:"),this.dispatch(Array.prototype.slice.call(t))},_float64array:function(t){return r("float64array:"),this.dispatch(Array.prototype.slice.call(t))},_arraybuffer:function(t){return r("arraybuffer:"),this.dispatch(new Uint8Array(t))},_url:function(t){return r("url:"+t.toString())},_map:function(e){return r("map:"),e=Array.from(e),this._array(e,!1!==t.unorderedSets)},_set:function(e){return r("set:"),e=Array.from(e),this._array(e,!1!==t.unorderedSets)},_file:function(t){return r("file:"),this.dispatch([t.name,t.size,t.type,t.lastModfied])},_blob:function(){if(t.ignoreUnknown)return r("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return r("domwindow")},_bigint:function(t){return r("bigint:"+t.toString())},_process:function(){return r("process")},_timer:function(){return r("timer")},_pipe:function(){return r("pipe")},_tcp:function(){return r("tcp")},_udp:function(){return r("udp")},_tty:function(){return r("tty")},_statwatcher:function(){return r("statwatcher")},_securecontext:function(){return r("securecontext")},_connection:function(){return r("connection")},_zlib:function(){return r("zlib")},_context:function(){return r("context")},_nodescript:function(){return r("nodescript")},_httpparser:function(){return r("httpparser")},_dataview:function(){return r("dataview")},_signal:function(){return r("signal")},_fsevent:function(){return r("fsevent")},_tlswrap:function(){return r("tlswrap")}}}function b(){return{buf:"",write:function(t){this.buf+=t},end:function(t){this.buf+=t},read:function(){return this.buf}}}n.writeToStream=function(t,e,n){return void 0===n&&(n=e,e={}),v(e=m(t,e),n).dispatch(t)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_9a5aa49d.js","/")},{buffer:3,crypto:5,lYpoI2:11}],2:[function(t,e,n){(function(t,e,r,o,i,s,a,u,c){!function(t){"use strict";var e="undefined"!=typeof Uint8Array?Uint8Array:Array,n="+".charCodeAt(0),r="/".charCodeAt(0),o="0".charCodeAt(0),i="a".charCodeAt(0),s="A".charCodeAt(0),a="-".charCodeAt(0),u="_".charCodeAt(0);function c(t){return(t=t.charCodeAt(0))===n||t===a?62:t===r||t===u?63:t<o?-1:t<o+10?t-o+26+26:t<s+26?t-s:t<i+26?t-i+26:void 0}t.toByteArray=function(t){var n,r;if(0<t.length%4)throw new Error("Invalid string. Length must be a multiple of 4");var o=t.length,i=(o="="===t.charAt(o-2)?2:"="===t.charAt(o-1)?1:0,new e(3*t.length/4-o)),s=0<o?t.length-4:t.length,a=0;function u(t){i[a++]=t}for(n=0;n<s;n+=4,0)u((16711680&(r=c(t.charAt(n))<<18|c(t.charAt(n+1))<<12|c(t.charAt(n+2))<<6|c(t.charAt(n+3))))>>16),u((65280&r)>>8),u(255&r);return 2==o?u(255&(r=c(t.charAt(n))<<2|c(t.charAt(n+1))>>4)):1==o&&(u((r=c(t.charAt(n))<<10|c(t.charAt(n+1))<<4|c(t.charAt(n+2))>>2)>>8&255),u(255&r)),i},t.fromByteArray=function(t){var e,n,r,o,i=t.length%3,s="";function a(t){return"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t)}for(e=0,r=t.length-i;e<r;e+=3)s+=a((o=n=(t[e]<<16)+(t[e+1]<<8)+t[e+2])>>18&63)+a(o>>12&63)+a(o>>6&63)+a(63&o);switch(i){case 1:s=(s+=a((n=t[t.length-1])>>2))+a(n<<4&63)+"==";break;case 2:s=(s=(s+=a((n=(t[t.length-2]<<8)+t[t.length-1])>>10))+a(n>>4&63))+a(n<<2&63)+"="}return s}}(void 0===n?this.base64js={}:n)}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:11}],3:[function(t,e,n){(function(e,r,o,i,s,a,u,c,l){var f=t("base64-js"),h=t("ieee754");function o(t,e,n){if(!(this instanceof o))return new o(t,e,n);var r,i,s,a,u=typeof t;if("base64"===e&&"string"==u)for(t=(a=t).trim?a.trim():a.replace(/^\s+|\s+$/g,"");t.length%4!=0;)t+="=";if("number"==u)r=I(t);else if("string"==u)r=o.byteLength(t,e);else{if("object"!=u)throw new Error("First argument needs to be a number, array or string.");r=I(t.length)}if(o._useTypedArrays?i=o._augment(new Uint8Array(r)):((i=this).length=r,i._isBuffer=!0),o._useTypedArrays&&"number"==typeof t.byteLength)i._set(t);else if(P(a=t)||o.isBuffer(a)||a&&"object"==typeof a&&"number"==typeof a.length)for(s=0;s<r;s++)o.isBuffer(t)?i[s]=t.readUInt8(s):i[s]=t[s];else if("string"==u)i.write(t,0,e);else if("number"==u&&!o._useTypedArrays&&!n)for(s=0;s<r;s++)i[s]=0;return i}function p(t,e,n,r){var o;if(r||(B("boolean"==typeof n,"missing or invalid endian"),B(null!=e,"missing offset"),B(e+1<t.length,"Trying to read beyond buffer length")),!((r=t.length)<=e))return n?(o=t[e],e+1<r&&(o|=t[e+1]<<8)):(o=t[e]<<8,e+1<r&&(o|=t[e+1])),o}function d(t,e,n,r){var o;if(r||(B("boolean"==typeof n,"missing or invalid endian"),B(null!=e,"missing offset"),B(e+3<t.length,"Trying to read beyond buffer length")),!((r=t.length)<=e))return n?(e+2<r&&(o=t[e+2]<<16),e+1<r&&(o|=t[e+1]<<8),o|=t[e],e+3<r&&(o+=t[e+3]<<24>>>0)):(e+1<r&&(o=t[e+1]<<16),e+2<r&&(o|=t[e+2]<<8),e+3<r&&(o|=t[e+3]),o+=t[e]<<24>>>0),o}function g(t,e,n,r){if(r||(B("boolean"==typeof n,"missing or invalid endian"),B(null!=e,"missing offset"),B(e+1<t.length,"Trying to read beyond buffer length")),!(t.length<=e))return 32768&(r=p(t,e,n,!0))?-1*(65535-r+1):r}function m(t,e,n,r){if(r||(B("boolean"==typeof n,"missing or invalid endian"),B(null!=e,"missing offset"),B(e+3<t.length,"Trying to read beyond buffer length")),!(t.length<=e))return 2147483648&(r=d(t,e,n,!0))?-1*(4294967295-r+1):r}function y(t,e,n,r){return r||(B("boolean"==typeof n,"missing or invalid endian"),B(e+3<t.length,"Trying to read beyond buffer length")),h.read(t,e,n,23,4)}function v(t,e,n,r){return r||(B("boolean"==typeof n,"missing or invalid endian"),B(e+7<t.length,"Trying to read beyond buffer length")),h.read(t,e,n,52,8)}function b(t,e,n,r,o){if(o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+1<t.length,"trying to write beyond buffer length"),M(e,65535)),!((o=t.length)<=n))for(var i=0,s=Math.min(o-n,2);i<s;i++)t[n+i]=(e&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function C(t,e,n,r,o){if(o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+3<t.length,"trying to write beyond buffer length"),M(e,4294967295)),!((o=t.length)<=n))for(var i=0,s=Math.min(o-n,4);i<s;i++)t[n+i]=e>>>8*(r?i:3-i)&255}function w(t,e,n,r,o){o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+1<t.length,"Trying to write beyond buffer length"),D(e,32767,-32768)),t.length<=n||b(t,0<=e?e:65535+e+1,n,r,o)}function A(t,e,n,r,o){o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+3<t.length,"Trying to write beyond buffer length"),D(e,2147483647,-2147483648)),t.length<=n||C(t,0<=e?e:4294967295+e+1,n,r,o)}function E(t,e,n,r,o){o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+3<t.length,"Trying to write beyond buffer length"),R(e,34028234663852886e22,-34028234663852886e22)),t.length<=n||h.write(t,e,n,r,23,4)}function _(t,e,n,r,o){o||(B(null!=e,"missing value"),B("boolean"==typeof r,"missing or invalid endian"),B(null!=n,"missing offset"),B(n+7<t.length,"Trying to write beyond buffer length"),R(e,17976931348623157e292,-17976931348623157e292)),t.length<=n||h.write(t,e,n,r,52,8)}n.Buffer=o,n.SlowBuffer=o,n.INSPECT_MAX_BYTES=50,o.poolSize=8192,o._useTypedArrays=function(){try{var t=new ArrayBuffer(0),e=new Uint8Array(t);return e.foo=function(){return 42},42===e.foo()&&"function"==typeof e.subarray}catch(t){return!1}}(),o.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.isBuffer=function(t){return!(null==t||!t._isBuffer)},o.byteLength=function(t,e){var n;switch(t+="",e||"utf8"){case"hex":n=t.length/2;break;case"utf8":case"utf-8":n=O(t).length;break;case"ascii":case"binary":case"raw":n=t.length;break;case"base64":n=N(t).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*t.length;break;default:throw new Error("Unknown encoding")}return n},o.concat=function(t,e){if(B(P(t),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===t.length)return new o(0);if(1===t.length)return t[0];if("number"!=typeof e)for(i=e=0;i<t.length;i++)e+=t[i].length;for(var n=new o(e),r=0,i=0;i<t.length;i++){var s=t[i];s.copy(n,r),r+=s.length}return n},o.prototype.write=function(t,e,n,r){isFinite(e)?isFinite(n)||(r=n,n=void 0):(c=r,r=e,e=n,n=c),e=Number(e)||0;var i,s,a,u,c=this.length-e;switch((!n||c<(n=Number(n)))&&(n=c),r=String(r||"utf8").toLowerCase()){case"hex":i=function(t,e,n,r){n=Number(n)||0;var i=t.length-n;(!r||i<(r=Number(r)))&&(r=i),B((i=e.length)%2==0,"Invalid hex string"),i/2<r&&(r=i/2);for(var s=0;s<r;s++){var a=parseInt(e.substr(2*s,2),16);B(!isNaN(a),"Invalid hex string"),t[n+s]=a}return o._charsWritten=2*s,s}(this,t,e,n);break;case"utf8":case"utf-8":s=this,a=e,u=n,i=o._charsWritten=L(O(t),s,a,u);break;case"ascii":case"binary":i=function(t,e,n,r){return o._charsWritten=L(function(t){for(var e=[],n=0;n<t.length;n++)e.push(255&t.charCodeAt(n));return e}(e),t,n,r)}(this,t,e,n);break;case"base64":s=this,a=e,u=n,i=o._charsWritten=L(N(t),s,a,u);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":i=function(t,e,n,r){return o._charsWritten=L(function(t){for(var e,n,r=[],o=0;o<t.length;o++)e=(n=t.charCodeAt(o))>>8,n%=256,r.push(n),r.push(e);return r}(e),t,n,r)}(this,t,e,n);break;default:throw new Error("Unknown encoding")}return i},o.prototype.toString=function(t,e,n){var r,o,i,s,a=this;if(t=String(t||"utf8").toLowerCase(),e=Number(e)||0,(n=void 0!==n?Number(n):a.length)===e)return"";switch(t){case"hex":r=function(t,e,n){var r=t.length;(!e||e<0)&&(e=0),(!n||n<0||r<n)&&(n=r);for(var o="",i=e;i<n;i++)o+=S(t[i]);return o}(a,e,n);break;case"utf8":case"utf-8":r=function(t,e,n){var r="",o="";n=Math.min(t.length,n);for(var i=e;i<n;i++)t[i]<=127?(r+=$(o)+String.fromCharCode(t[i]),o=""):o+="%"+t[i].toString(16);return r+$(o)}(a,e,n);break;case"ascii":case"binary":r=function(t,e,n){var r="";n=Math.min(t.length,n);for(var o=e;o<n;o++)r+=String.fromCharCode(t[o]);return r}(a,e,n);break;case"base64":o=a,s=n,r=0===(i=e)&&s===o.length?f.fromByteArray(o):f.fromByteArray(o.slice(i,s));break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":r=function(t,e,n){for(var r=t.slice(e,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}(a,e,n);break;default:throw new Error("Unknown encoding")}return r},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.copy=function(t,e,n,r){if(e=e||0,(r=r||0===r?r:this.length)!==(n=n||0)&&0!==t.length&&0!==this.length){B(n<=r,"sourceEnd < sourceStart"),B(0<=e&&e<t.length,"targetStart out of bounds"),B(0<=n&&n<this.length,"sourceStart out of bounds"),B(0<=r&&r<=this.length,"sourceEnd out of bounds"),r>this.length&&(r=this.length);var i=(r=t.length-e<r-n?t.length-e+n:r)-n;if(i<100||!o._useTypedArrays)for(var s=0;s<i;s++)t[s+e]=this[s+n];else t._set(this.subarray(n,n+i),e)}},o.prototype.slice=function(t,e){var n=this.length;if(t=T(t,n,0),e=T(e,n,n),o._useTypedArrays)return o._augment(this.subarray(t,e));for(var r=e-t,i=new o(r,void 0,!0),s=0;s<r;s++)i[s]=this[s+t];return i},o.prototype.get=function(t){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(t)},o.prototype.set=function(t,e){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(t,e)},o.prototype.readUInt8=function(t,e){if(e||(B(null!=t,"missing offset"),B(t<this.length,"Trying to read beyond buffer length")),!(t>=this.length))return this[t]},o.prototype.readUInt16LE=function(t,e){return p(this,t,!0,e)},o.prototype.readUInt16BE=function(t,e){return p(this,t,!1,e)},o.prototype.readUInt32LE=function(t,e){return d(this,t,!0,e)},o.prototype.readUInt32BE=function(t,e){return d(this,t,!1,e)},o.prototype.readInt8=function(t,e){if(e||(B(null!=t,"missing offset"),B(t<this.length,"Trying to read beyond buffer length")),!(t>=this.length))return 128&this[t]?-1*(255-this[t]+1):this[t]},o.prototype.readInt16LE=function(t,e){return g(this,t,!0,e)},o.prototype.readInt16BE=function(t,e){return g(this,t,!1,e)},o.prototype.readInt32LE=function(t,e){return m(this,t,!0,e)},o.prototype.readInt32BE=function(t,e){return m(this,t,!1,e)},o.prototype.readFloatLE=function(t,e){return y(this,t,!0,e)},o.prototype.readFloatBE=function(t,e){return y(this,t,!1,e)},o.prototype.readDoubleLE=function(t,e){return v(this,t,!0,e)},o.prototype.readDoubleBE=function(t,e){return v(this,t,!1,e)},o.prototype.writeUInt8=function(t,e,n){n||(B(null!=t,"missing value"),B(null!=e,"missing offset"),B(e<this.length,"trying to write beyond buffer length"),M(t,255)),e>=this.length||(this[e]=t)},o.prototype.writeUInt16LE=function(t,e,n){b(this,t,e,!0,n)},o.prototype.writeUInt16BE=function(t,e,n){b(this,t,e,!1,n)},o.prototype.writeUInt32LE=function(t,e,n){C(this,t,e,!0,n)},o.prototype.writeUInt32BE=function(t,e,n){C(this,t,e,!1,n)},o.prototype.writeInt8=function(t,e,n){n||(B(null!=t,"missing value"),B(null!=e,"missing offset"),B(e<this.length,"Trying to write beyond buffer length"),D(t,127,-128)),e>=this.length||(0<=t?this.writeUInt8(t,e,n):this.writeUInt8(255+t+1,e,n))},o.prototype.writeInt16LE=function(t,e,n){w(this,t,e,!0,n)},o.prototype.writeInt16BE=function(t,e,n){w(this,t,e,!1,n)},o.prototype.writeInt32LE=function(t,e,n){A(this,t,e,!0,n)},o.prototype.writeInt32BE=function(t,e,n){A(this,t,e,!1,n)},o.prototype.writeFloatLE=function(t,e,n){E(this,t,e,!0,n)},o.prototype.writeFloatBE=function(t,e,n){E(this,t,e,!1,n)},o.prototype.writeDoubleLE=function(t,e,n){_(this,t,e,!0,n)},o.prototype.writeDoubleBE=function(t,e,n){_(this,t,e,!1,n)},o.prototype.fill=function(t,e,n){if(e=e||0,n=n||this.length,B("number"==typeof(t="string"==typeof(t=t||0)?t.charCodeAt(0):t)&&!isNaN(t),"value is not a number"),B(e<=n,"end < start"),n!==e&&0!==this.length){B(0<=e&&e<this.length,"start out of bounds"),B(0<=n&&n<=this.length,"end out of bounds");for(var r=e;r<n;r++)this[r]=t}},o.prototype.inspect=function(){for(var t=[],e=this.length,r=0;r<e;r++)if(t[r]=S(this[r]),r===n.INSPECT_MAX_BYTES){t[r+1]="...";break}return"<Buffer "+t.join(" ")+">"},o.prototype.toArrayBuffer=function(){if("undefined"==typeof Uint8Array)throw new Error("Buffer.toArrayBuffer not supported in this browser");if(o._useTypedArrays)return new o(this).buffer;for(var t=new Uint8Array(this.length),e=0,n=t.length;e<n;e+=1)t[e]=this[e];return t.buffer};var x=o.prototype;function T(t,e,n){return"number"!=typeof t?n:e<=(t=~~t)?e:0<=t||0<=(t+=e)?t:0}function I(t){return(t=~~Math.ceil(+t))<0?0:t}function P(t){return(Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)})(t)}function S(t){return t<16?"0"+t.toString(16):t.toString(16)}function O(t){for(var e=[],n=0;n<t.length;n++){var r=t.charCodeAt(n);if(r<=127)e.push(t.charCodeAt(n));else for(var o=n,i=(55296<=r&&r<=57343&&n++,encodeURIComponent(t.slice(o,n+1)).substr(1).split("%")),s=0;s<i.length;s++)e.push(parseInt(i[s],16))}return e}function N(t){return f.toByteArray(t)}function L(t,e,n,r){for(var o=0;o<r&&!(o+n>=e.length||o>=t.length);o++)e[o+n]=t[o];return o}function $(t){try{return decodeURIComponent(t)}catch(t){return String.fromCharCode(65533)}}function M(t,e){B("number"==typeof t,"cannot write a non-number as a number"),B(0<=t,"specified a negative value for writing an unsigned value"),B(t<=e,"value is larger than maximum value for type"),B(Math.floor(t)===t,"value has a fractional component")}function D(t,e,n){B("number"==typeof t,"cannot write a non-number as a number"),B(t<=e,"value larger than maximum allowed value"),B(n<=t,"value smaller than minimum allowed value"),B(Math.floor(t)===t,"value has a fractional component")}function R(t,e,n){B("number"==typeof t,"cannot write a non-number as a number"),B(t<=e,"value larger than maximum allowed value"),B(n<=t,"value smaller than minimum allowed value")}function B(t,e){if(!t)throw new Error(e||"Failed assertion")}o._augment=function(t){return t._isBuffer=!0,t._get=t.get,t._set=t.set,t.get=x.get,t.set=x.set,t.write=x.write,t.toString=x.toString,t.toLocaleString=x.toString,t.toJSON=x.toJSON,t.copy=x.copy,t.slice=x.slice,t.readUInt8=x.readUInt8,t.readUInt16LE=x.readUInt16LE,t.readUInt16BE=x.readUInt16BE,t.readUInt32LE=x.readUInt32LE,t.readUInt32BE=x.readUInt32BE,t.readInt8=x.readInt8,t.readInt16LE=x.readInt16LE,t.readInt16BE=x.readInt16BE,t.readInt32LE=x.readInt32LE,t.readInt32BE=x.readInt32BE,t.readFloatLE=x.readFloatLE,t.readFloatBE=x.readFloatBE,t.readDoubleLE=x.readDoubleLE,t.readDoubleBE=x.readDoubleBE,t.writeUInt8=x.writeUInt8,t.writeUInt16LE=x.writeUInt16LE,t.writeUInt16BE=x.writeUInt16BE,t.writeUInt32LE=x.writeUInt32LE,t.writeUInt32BE=x.writeUInt32BE,t.writeInt8=x.writeInt8,t.writeInt16LE=x.writeInt16LE,t.writeInt16BE=x.writeInt16BE,t.writeInt32LE=x.writeInt32LE,t.writeInt32BE=x.writeInt32BE,t.writeFloatLE=x.writeFloatLE,t.writeFloatBE=x.writeFloatBE,t.writeDoubleLE=x.writeDoubleLE,t.writeDoubleBE=x.writeDoubleBE,t.fill=x.fill,t.inspect=x.inspect,t.toArrayBuffer=x.toArrayBuffer,t}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:10,lYpoI2:11}],4:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){o=t("buffer").Buffer;var f=new o(4);f.fill(0),e.exports={hash:function(t,e,n,r){for(var i=e(function(t,e){t.length%4!=0&&(n=t.length+(4-t.length%4),t=o.concat([t,f],n));for(var n,r=[],i=e?t.readInt32BE:t.readInt32LE,s=0;s<t.length;s+=4)r.push(i.call(t,s));return r}(t=o.isBuffer(t)?t:new o(t),r),8*t.length),s=(e=r,new o(n)),a=e?s.writeInt32BE:s.writeInt32LE,u=0;u<i.length;u++)a.call(s,i[u],4*u,!0);return s}}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/helpers.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:11}],5:[function(t,e,n){(function(e,r,o,i,s,a,u,c,l){o=t("buffer").Buffer;var f=t("./sha"),h=t("./sha256"),p=t("./rng"),d={sha1:f,sha256:h,md5:t("./md5")},g=64,m=new o(g);function y(t,e){var n=d[t=t||"sha1"],r=[];return n||v("algorithm:",t,"is not yet supported"),{update:function(t){return o.isBuffer(t)||(t=new o(t)),r.push(t),t.length,this},digest:function(t){var i=o.concat(r);return i=e?function(t,e,n){o.isBuffer(e)||(e=new o(e)),o.isBuffer(n)||(n=new o(n)),e.length>g?e=t(e):e.length<g&&(e=o.concat([e,m],g));for(var r=new o(g),i=new o(g),s=0;s<g;s++)r[s]=54^e[s],i[s]=92^e[s];return n=t(o.concat([r,n])),t(o.concat([i,n]))}(n,e,i):n(i),r=null,t?i.toString(t):i}}}function v(){var t=[].slice.call(arguments).join(" ");throw new Error([t,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}m.fill(0),n.createHash=function(t){return y(t)},n.createHmac=y,n.randomBytes=function(t,e){if(!e||!e.call)return new o(p(t));try{e.call(this,void 0,new o(p(t)))}catch(t){e(t)}};var b,C=["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],w=function(t){n[t]=function(){v("sorry,",t,"is not implemented yet")}};for(b in C)w(C[b])}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/index.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./md5":6,"./rng":7,"./sha":8,"./sha256":9,buffer:3,lYpoI2:11}],6:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){var f=t("./helpers");function h(t,e){t[e>>5]|=128<<e%32,t[14+(e+64>>>9<<4)]=e;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,s=0;s<t.length;s+=16){var a=n,u=r,c=o,l=i;n=d(n,r,o,i,t[s+0],7,-680876936),i=d(i,n,r,o,t[s+1],12,-389564586),o=d(o,i,n,r,t[s+2],17,606105819),r=d(r,o,i,n,t[s+3],22,-1044525330),n=d(n,r,o,i,t[s+4],7,-176418897),i=d(i,n,r,o,t[s+5],12,1200080426),o=d(o,i,n,r,t[s+6],17,-1473231341),r=d(r,o,i,n,t[s+7],22,-45705983),n=d(n,r,o,i,t[s+8],7,1770035416),i=d(i,n,r,o,t[s+9],12,-1958414417),o=d(o,i,n,r,t[s+10],17,-42063),r=d(r,o,i,n,t[s+11],22,-1990404162),n=d(n,r,o,i,t[s+12],7,1804603682),i=d(i,n,r,o,t[s+13],12,-40341101),o=d(o,i,n,r,t[s+14],17,-1502002290),n=g(n,r=d(r,o,i,n,t[s+15],22,1236535329),o,i,t[s+1],5,-165796510),i=g(i,n,r,o,t[s+6],9,-1069501632),o=g(o,i,n,r,t[s+11],14,643717713),r=g(r,o,i,n,t[s+0],20,-373897302),n=g(n,r,o,i,t[s+5],5,-701558691),i=g(i,n,r,o,t[s+10],9,38016083),o=g(o,i,n,r,t[s+15],14,-660478335),r=g(r,o,i,n,t[s+4],20,-405537848),n=g(n,r,o,i,t[s+9],5,568446438),i=g(i,n,r,o,t[s+14],9,-1019803690),o=g(o,i,n,r,t[s+3],14,-187363961),r=g(r,o,i,n,t[s+8],20,1163531501),n=g(n,r,o,i,t[s+13],5,-1444681467),i=g(i,n,r,o,t[s+2],9,-51403784),o=g(o,i,n,r,t[s+7],14,1735328473),n=m(n,r=g(r,o,i,n,t[s+12],20,-1926607734),o,i,t[s+5],4,-378558),i=m(i,n,r,o,t[s+8],11,-2022574463),o=m(o,i,n,r,t[s+11],16,1839030562),r=m(r,o,i,n,t[s+14],23,-35309556),n=m(n,r,o,i,t[s+1],4,-1530992060),i=m(i,n,r,o,t[s+4],11,1272893353),o=m(o,i,n,r,t[s+7],16,-155497632),r=m(r,o,i,n,t[s+10],23,-1094730640),n=m(n,r,o,i,t[s+13],4,681279174),i=m(i,n,r,o,t[s+0],11,-358537222),o=m(o,i,n,r,t[s+3],16,-722521979),r=m(r,o,i,n,t[s+6],23,76029189),n=m(n,r,o,i,t[s+9],4,-640364487),i=m(i,n,r,o,t[s+12],11,-421815835),o=m(o,i,n,r,t[s+15],16,530742520),n=y(n,r=m(r,o,i,n,t[s+2],23,-995338651),o,i,t[s+0],6,-198630844),i=y(i,n,r,o,t[s+7],10,1126891415),o=y(o,i,n,r,t[s+14],15,-1416354905),r=y(r,o,i,n,t[s+5],21,-57434055),n=y(n,r,o,i,t[s+12],6,1700485571),i=y(i,n,r,o,t[s+3],10,-1894986606),o=y(o,i,n,r,t[s+10],15,-1051523),r=y(r,o,i,n,t[s+1],21,-2054922799),n=y(n,r,o,i,t[s+8],6,1873313359),i=y(i,n,r,o,t[s+15],10,-30611744),o=y(o,i,n,r,t[s+6],15,-1560198380),r=y(r,o,i,n,t[s+13],21,1309151649),n=y(n,r,o,i,t[s+4],6,-145523070),i=y(i,n,r,o,t[s+11],10,-1120210379),o=y(o,i,n,r,t[s+2],15,718787259),r=y(r,o,i,n,t[s+9],21,-343485551),n=v(n,a),r=v(r,u),o=v(o,c),i=v(i,l)}return Array(n,r,o,i)}function p(t,e,n,r,o,i){return v((e=v(v(e,t),v(r,i)))<<o|e>>>32-o,n)}function d(t,e,n,r,o,i,s){return p(e&n|~e&r,t,e,o,i,s)}function g(t,e,n,r,o,i,s){return p(e&r|n&~r,t,e,o,i,s)}function m(t,e,n,r,o,i,s){return p(e^n^r,t,e,o,i,s)}function y(t,e,n,r,o,i,s){return p(n^(e|~r),t,e,o,i,s)}function v(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}e.exports=function(t){return f.hash(t,h,16)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],7:[function(t,e,n){(function(t,n,r,o,i,s,a,u,c){e.exports=function(t){for(var e,n=new Array(t),r=0;r<t;r++)!(3&r)&&(e=4294967296*Math.random()),n[r]=e>>>((3&r)<<3)&255;return n}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:11}],8:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){var f=t("./helpers");function h(t,e){t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var n,r,o,i=Array(80),s=1732584193,a=-271733879,u=-1732584194,c=271733878,l=-1009589776,f=0;f<t.length;f+=16){for(var h=s,g=a,m=u,y=c,v=l,b=0;b<80;b++){i[b]=b<16?t[f+b]:d(i[b-3]^i[b-8]^i[b-14]^i[b-16],1);var C=p(p(d(s,5),(C=a,r=u,o=c,(n=b)<20?C&r|~C&o:!(n<40)&&n<60?C&r|C&o|r&o:C^r^o)),p(p(l,i[b]),(n=b)<20?1518500249:n<40?1859775393:n<60?-1894007588:-899497514));l=c,c=u,u=d(a,30),a=s,s=C}s=p(s,h),a=p(a,g),u=p(u,m),c=p(c,y),l=p(l,v)}return Array(s,a,u,c,l)}function p(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}function d(t,e){return t<<e|t>>>32-e}e.exports=function(t){return f.hash(t,h,20,!0)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],9:[function(t,e,n){(function(n,r,o,i,s,a,u,c,l){function f(t,e){var n=(65535&t)+(65535&e);return(t>>16)+(e>>16)+(n>>16)<<16|65535&n}function h(t,e){var n,r=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),o=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),i=new Array(64);t[e>>5]|=128<<24-e%32,t[15+(e+64>>9<<4)]=e;for(var s,a,u=0;u<t.length;u+=16){for(var c=o[0],l=o[1],h=o[2],p=o[3],m=o[4],y=o[5],v=o[6],b=o[7],C=0;C<64;C++)i[C]=C<16?t[C+u]:f(f(f((a=i[C-2],d(a,17)^d(a,19)^g(a,10)),i[C-7]),(a=i[C-15],d(a,7)^d(a,18)^g(a,3))),i[C-16]),n=f(f(f(f(b,d(a=m,6)^d(a,11)^d(a,25)),m&y^~m&v),r[C]),i[C]),s=f(d(s=c,2)^d(s,13)^d(s,22),c&l^c&h^l&h),b=v,v=y,y=m,m=f(p,n),p=h,h=l,l=c,c=f(n,s);o[0]=f(c,o[0]),o[1]=f(l,o[1]),o[2]=f(h,o[2]),o[3]=f(p,o[3]),o[4]=f(m,o[4]),o[5]=f(y,o[5]),o[6]=f(v,o[6]),o[7]=f(b,o[7])}return o}var p=t("./helpers"),d=function(t,e){return t>>>e|t<<32-e},g=function(t,e){return t>>>e};e.exports=function(t){return p.hash(t,h,32,!0)}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],10:[function(t,e,n){(function(t,e,r,o,i,s,a,u,c){n.read=function(t,e,n,r,o){var i,s,a=8*o-r-1,u=(1<<a)-1,c=u>>1,l=-7,f=n?o-1:0,h=n?-1:1;for(o=t[e+f],f+=h,i=o&(1<<-l)-1,o>>=-l,l+=a;0<l;i=256*i+t[e+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=r;0<l;s=256*s+t[e+f],f+=h,l-=8);if(0===i)i=1-c;else{if(i===u)return s?NaN:1/0*(o?-1:1);s+=Math.pow(2,r),i-=c}return(o?-1:1)*s*Math.pow(2,i-r)},n.write=function(t,e,n,r,o,i){var s,a,u=8*i-o-1,c=(1<<u)-1,l=c>>1,f=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:i-1,p=r?1:-1;for(i=e<0||0===e&&1/e<0?1:0,e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(r=Math.pow(2,-s))<1&&(s--,r*=2),2<=(e+=1<=s+l?f/r:f*Math.pow(2,1-l))*r&&(s++,r/=2),c<=s+l?(a=0,s=c):1<=s+l?(a=(e*r-1)*Math.pow(2,o),s+=l):(a=e*Math.pow(2,l-1)*Math.pow(2,o),s=0));8<=o;t[n+h]=255&a,h+=p,a/=256,o-=8);for(s=s<<o|a,u+=o;0<u;t[n+h]=255&s,h+=p,s/=256,u-=8);t[n+h-p]|=128*i}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/ieee754/index.js","/node_modules/gulp-browserify/node_modules/ieee754")},{buffer:3,lYpoI2:11}],11:[function(t,e,n){(function(t,n,r,o,i,s,a,u,c){var l,f,h;function p(){}(t=e.exports={}).nextTick=(f="undefined"!=typeof window&&window.setImmediate,h="undefined"!=typeof window&&window.postMessage&&window.addEventListener,f?function(t){return window.setImmediate(t)}:h?(l=[],window.addEventListener("message",(function(t){var e=t.source;e!==window&&null!==e||"process-tick"!==t.data||(t.stopPropagation(),0<l.length&&l.shift()())}),!0),function(t){l.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}),t.title="browser",t.browser=!0,t.env={},t.argv=[],t.on=p,t.addListener=p,t.once=p,t.off=p,t.removeListener=p,t.removeAllListeners=p,t.emit=p,t.binding=function(t){throw new Error("process.binding is not supported")},t.cwd=function(){return"/"},t.chdir=function(t){throw new Error("process.chdir is not supported")}}).call(this,t("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},t("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:11}]},{},[1])(1)},146:(t,e)=>{"use strict";var n;!function(){var r=e||{}||this||window;void 0===(n=function(){return r}.apply(e,[]))||(t.exports=n),r.default=r;var o="http://www.w3.org/2000/xmlns/",i="http://www.w3.org/2000/svg",s=/url\(["']?(.+?)["']?\)/,a={woff2:"font/woff2",woff:"font/woff",otf:"application/x-font-opentype",ttf:"application/x-font-ttf",eot:"application/vnd.ms-fontobject",sfnt:"application/font-sfnt",svg:"image/svg+xml"},u=function(t){return t instanceof HTMLElement||t instanceof SVGElement},c=function(t){if(!u(t))throw new Error("an HTMLElement or SVGElement is required; got "+t)},l=function(t){return new Promise((function(e,n){u(t)?e(t):n(new Error("an HTMLElement or SVGElement is required; got "+t))}))},f=function(t,e,n){var r=t.viewBox&&t.viewBox.baseVal&&t.viewBox.baseVal[n]||null!==e.getAttribute(n)&&!e.getAttribute(n).match(/%$/)&&parseInt(e.getAttribute(n))||t.getBoundingClientRect()[n]||parseInt(e.style[n])||parseInt(window.getComputedStyle(t).getPropertyValue(n));return null==r||isNaN(parseFloat(r))?0:r},h=function(t){for(var e=window.atob(t.split(",")[1]),n=t.split(",")[0].split(":")[1].split(";")[0],r=new ArrayBuffer(e.length),o=new Uint8Array(r),i=0;i<e.length;i++)o[i]=e.charCodeAt(i);return new Blob([r],{type:n})},p={},d=null,g=function(t,e){var n=e||{},r=n.selectorRemap,o=n.modifyStyle,i=n.modifyCss,u=n.fonts,c=n.excludeUnusedCss,l=i||function(t,e){return(r?r(t):t)+"{"+(o?o(e):e)+"}\n"},f=[],h=void 0===u,g=u||[];return(d||(d=Array.from(document.styleSheets).map((function(t){try{return{rules:t.cssRules,href:t.href}}catch(e){return console.warn("Stylesheet could not be loaded: "+t.href,e),{}}})))).forEach((function(e){var n=e.rules,r=e.href;n&&Array.from(n).forEach((function(e){if(void 0!==e.style)if(function(t,e){if(e)try{return t.querySelector(e)||t.parentNode&&t.parentNode.querySelector(e)}catch(t){console.warn('Invalid CSS selector "'+e+'"',t)}}(t,e.selectorText))f.push(l(e.selectorText,e.style.cssText));else if(h&&e.cssText.match(/^@font-face/)){var n=function(t,e){var n=t.cssText.match(s),r=n&&n[1]||"";if(r&&!r.match(/^data:/)&&"about:blank"!==r){var o,i,u=r.startsWith("../")?e+"/../"+r:r.startsWith("./")?e+"/."+r:r;return{text:t.cssText,format:(o=u,i=Object.keys(a).filter((function(t){return o.indexOf("."+t)>0})).map((function(t){return a[t]})),i?i[0]:(console.error("Unknown font format for "+o+". Fonts may not be working correctly."),"application/octet-stream")),url:u}}}(e,r);n&&g.push(n)}else c||f.push(e.cssText)}))})),function(t){return Promise.all(t.map((function(t){return new Promise((function(e,n){if(p[t.url])return e(p[t.url]);var r=new XMLHttpRequest;r.addEventListener("load",(function(){var n=function(t){for(var e="",n=new Uint8Array(t),r=0;r<n.byteLength;r++)e+=String.fromCharCode(n[r]);return window.btoa(e)}(r.response),o=t.text.replace(s,'url("data:'+t.format+";base64,"+n+'")')+"\n";p[t.url]=o,e(o)})),r.addEventListener("error",(function(n){console.warn("Failed to load font from: "+t.url,n),p[t.url]=null,e(null)})),r.addEventListener("abort",(function(n){console.warn("Aborted loading font from: "+t.url,n),e(null)})),r.open("GET",t.url),r.responseType="arraybuffer",r.send()}))}))).then((function(t){return t.filter((function(t){return t})).join("")}))}(g).then((function(t){return f.join("\n")+t}))},m=function(){if(!navigator.msSaveOrOpenBlob&&!("download"in document.createElement("a")))return{popup:window.open()}};r.prepareSvg=function(t,e,n){c(t);var r=e||{},s=r.left,a=void 0===s?0:s,u=r.top,l=void 0===u?0:u,h=r.width,p=r.height,d=r.scale,m=void 0===d?1:d,y=r.responsive,v=void 0!==y&&y,b=r.excludeCss,C=void 0!==b&&b;return function(t){return Promise.all(Array.from(t.querySelectorAll("image")).map((function(t){var e,n=t.getAttributeNS("http://www.w3.org/1999/xlink","href")||t.getAttribute("href");return n?((e=n)&&0===e.lastIndexOf("http",0)&&-1===e.lastIndexOf(window.location.host)&&(n+=(-1===n.indexOf("?")?"?":"&")+"t="+(new Date).valueOf()),new Promise((function(e,r){var o=document.createElement("canvas"),i=new Image;i.crossOrigin="anonymous",i.src=n,i.onerror=function(){return r(new Error("Could not load "+n))},i.onload=function(){o.width=i.width,o.height=i.height,o.getContext("2d").drawImage(i,0,0),t.setAttributeNS("http://www.w3.org/1999/xlink","href",o.toDataURL("image/png")),e(!0)}}))):Promise.resolve(null)})))}(t).then((function(){var r=t.cloneNode(!0);r.style.backgroundColor=(e||{}).backgroundColor||t.style.backgroundColor;var s=function(t,e,n,r){if("svg"===t.tagName)return{width:n||f(t,e,"width"),height:r||f(t,e,"height")};if(t.getBBox){var o=t.getBBox(),i=o.x,s=o.y;return{width:i+o.width,height:s+o.height}}}(t,r,h,p),u=s.width,c=s.height;if("svg"!==t.tagName){if(!t.getBBox)return void console.error("Attempted to render non-SVG element",t);null!=r.getAttribute("transform")&&r.setAttribute("transform",r.getAttribute("transform").replace(/translate\(.*?\)/,""));var d=document.createElementNS("http://www.w3.org/2000/svg","svg");d.appendChild(r),r=d}if(r.setAttribute("version","1.1"),r.setAttribute("viewBox",[a,l,u,c].join(" ")),r.getAttribute("xmlns")||r.setAttributeNS(o,"xmlns",i),r.getAttribute("xmlns:xlink")||r.setAttributeNS(o,"xmlns:xlink","http://www.w3.org/1999/xlink"),v?(r.removeAttribute("width"),r.removeAttribute("height"),r.setAttribute("preserveAspectRatio","xMinYMin meet")):(r.setAttribute("width",u*m),r.setAttribute("height",c*m)),Array.from(r.querySelectorAll("foreignObject > *")).forEach((function(t){t.setAttributeNS(o,"xmlns","svg"===t.tagName?i:"http://www.w3.org/1999/xhtml")})),!C)return g(t,e).then((function(t){var e=document.createElement("style");e.setAttribute("type","text/css"),e.innerHTML="<![CDATA[\n"+t+"\n]]>";var o=document.createElement("defs");o.appendChild(e),r.insertBefore(o,r.firstChild);var i=document.createElement("div");i.appendChild(r);var s=i.innerHTML.replace(/NS\d+:href/gi,'xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href');if("function"!=typeof n)return{src:s,width:u,height:c};n(s,u,c)}));var y=document.createElement("div");y.appendChild(r);var b=y.innerHTML;if("function"!=typeof n)return{src:b,width:u,height:c};n(b,u,c)}))},r.svgAsDataUri=function(t,e,n){return c(t),r.prepareSvg(t,e).then((function(t){var e=t.src,r=t.width,o=t.height,i="data:image/svg+xml;base64,"+window.btoa(decodeURIComponent(encodeURIComponent('<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [<!ENTITY nbsp " ">]>'+e).replace(/%([0-9A-F]{2})/g,(function(t,e){var n=String.fromCharCode("0x"+e);return"%"===n?"%25":n}))));return"function"==typeof n&&n(i,r,o),i}))},r.svgAsPngUri=function(t,e,n){c(t);var o=e||{},i=o.encoderType,s=void 0===i?"image/png":i,a=o.encoderOptions,u=void 0===a?.8:a,l=o.canvg,f=function(t){var e=t.src,r=t.width,o=t.height,i=document.createElement("canvas"),a=i.getContext("2d"),c=window.devicePixelRatio||1;i.width=r*c,i.height=o*c,i.style.width=i.width+"px",i.style.height=i.height+"px",a.setTransform(c,0,0,c,0,0),l?l(i,e):a.drawImage(e,0,0);var f=void 0;try{f=i.toDataURL(s,u)}catch(t){if("undefined"!=typeof SecurityError&&t instanceof SecurityError||"SecurityError"===t.name)return void console.error("Rendered SVG images cannot be downloaded in this browser.");throw t}return"function"==typeof n&&n(f,i.width,i.height),Promise.resolve(f)};return l?r.prepareSvg(t,e).then(f):r.svgAsDataUri(t,e).then((function(t){return new Promise((function(e,n){var r=new Image;r.onload=function(){return e(f({src:r,width:r.width,height:r.height}))},r.onerror=function(){n("There was an error loading the data URI as an image on the following SVG\n"+window.atob(t.slice(26))+"Open the following link to see browser's diagnosis\n"+t)},r.src=t}))}))},r.download=function(t,e,n){if(navigator.msSaveOrOpenBlob)navigator.msSaveOrOpenBlob(h(e),t);else{var r=document.createElement("a");if("download"in r){r.download=t,r.style.display="none",document.body.appendChild(r);try{var o=h(e),i=URL.createObjectURL(o);r.href=i,r.onclick=function(){return requestAnimationFrame((function(){return URL.revokeObjectURL(i)}))}}catch(t){console.error(t),console.warn("Error while getting object URL. Falling back to string URL."),r.href=e}r.click(),document.body.removeChild(r)}else n&&n.popup&&(n.popup.document.title=t,n.popup.location.replace(e))}},r.saveSvg=function(t,e,n){var o=m();return l(t).then((function(t){return r.svgAsDataUri(t,n||{})})).then((function(t){return r.download(e,t,o)}))},r.saveSvgAsPng=function(t,e,n){var o=m();return l(t).then((function(t){return r.svgAsPngUri(t,n||{})})).then((function(t){return r.download(e,t,o)}))}}()},72:t=>{"use strict";var e=[];function n(t){for(var n=-1,r=0;r<e.length;r++)if(e[r].identifier===t){n=r;break}return n}function r(t,r){for(var i={},s=[],a=0;a<t.length;a++){var u=t[a],c=r.base?u[0]+r.base:u[0],l=i[c]||0,f="".concat(c," ").concat(l);i[c]=l+1;var h=n(f),p={css:u[1],media:u[2],sourceMap:u[3],supports:u[4],layer:u[5]};if(-1!==h)e[h].references++,e[h].updater(p);else{var d=o(p,r);r.byIndex=a,e.splice(a,0,{identifier:f,updater:d,references:1})}s.push(f)}return s}function o(t,e){var n=e.domAPI(e);return n.update(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;n.update(t=e)}else n.remove()}}t.exports=function(t,o){var i=r(t=t||[],o=o||{});return function(t){t=t||[];for(var s=0;s<i.length;s++){var a=n(i[s]);e[a].references--}for(var u=r(t,o),c=0;c<i.length;c++){var l=n(i[c]);0===e[l].references&&(e[l].updater(),e.splice(l,1))}i=u}}},659:t=>{"use strict";var e={};t.exports=function(t,n){var r=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},540:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},56:(t,e,n)=>{"use strict";t.exports=function(t){var e=n.nc;e&&t.setAttribute("nonce",e)}},825:t=>{"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(n){!function(t,e,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),e.styleTagTransform(r,t,e.options)}(e,t,n)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},113:t=>{"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},686:(t,e,n)=>{"use strict";n.d(e,{AL:()=>r,NO:()=>o});const r=["A","G","C","U"];var o;!function(t){t.HELM="HELM",t.AXOLABS="Axolabs"}(o||(o={}))},670:(t,e,n)=>{"use strict";function r(t,e=!0){let n="\n Datagrok macromolecule handler\n\n";n+=" 0 0 0 0 0 0 999 V3000\n",n+="M V30 BEGIN CTAB\n";let r="",a="",u="";const c=[];let l=0,f=0,h=0;if(t.antiStrands.length>0)for(let e=0;e<t.antiStrands.length;e++)t.antiStrands[e]=o(t.antiStrands[e]);let p=!1;const d=t.senseStrands.concat(t.antiStrands);let g=0;for(let e=0;e<d.length;e++){d[e]=d[e].replaceAll("(-\nM V30 ","(").replaceAll("-\nM V30 ","").replaceAll(" )",")");const n=i(d[e]),o=s(d[e]);if(e>=t.senseStrands.length?!1===p&&(p=!0,h=0):g=Math.min(g,Math.min(...o.y.filter((t=>t<0)))),p){const t=Math.min(...o.x)-h,e=Math.max(...o.y)+5;for(let e=0;e<o.x.length;e++)o.x[e]-=t;for(let t=0;t<o.y.length;t++)o.y[t]-=e-g}let u=d[e].indexOf("M V30 BEGIN ATOM");u=d[e].indexOf("\n",u);let m=u,y=u;for(let t=0;t<n.natom;t++){m=d[e].indexOf("V30",m)+4,y=d[e].indexOf(" ",m);const n=parseInt(d[e].substring(m,y))+l;d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf(" ",m)+1,m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m);let r=Math.round(1e4*o.x[t])/1e4;d[e]=d[e].slice(0,m)+r+d[e].slice(y),m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m),r=Math.round(1e4*o.y[t])/1e4,d[e]=d[e].slice(0,m)+r+d[e].slice(y),m=d[e].indexOf("\n",m)+1}const v=d[e].indexOf("M V30 END ATOM");r+=d[e].substring(u+1,v);let b=d[e].indexOf("M V30 BEGIN BOND");b=d[e].indexOf("\n",b),m=b,y=b;for(let t=0;t<n.nbond;t++){m=d[e].indexOf("V30",m)+4,y=d[e].indexOf(" ",m);const t=parseInt(d[e].substring(m,y))+f;d[e]=d[e].slice(0,m)+t+d[e].slice(y),m=d[e].indexOf(" ",m)+1,m=d[e].indexOf(" ",m)+1,y=d[e].indexOf(" ",m);let n=parseInt(d[e].substring(m,y))+l;d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf(" ",m)+1,y=Math.min(d[e].indexOf("\n",m),d[e].indexOf(" ",m)),n=parseInt(d[e].substring(m,y))+l,d[e]=d[e].slice(0,m)+n+d[e].slice(y),m=d[e].indexOf("\n",m)+1}const C=d[e].indexOf("M V30 END BOND");a+=d[e].substring(b+1,C);let w=d[e].indexOf("M V30 MDLV30/STEABS ATOMS=(");for(;-1!==w;){w+=28;const t=d[e].indexOf(")",w);d[e].substring(w,t).split(" ").slice(1).forEach((t=>{c.push(parseInt(t)+l)})),w=t,w=d[e].indexOf("M V30 MDLV30/STEABS ATOMS=(",w)}l+=n.natom,f+=n.nbond,h+=Math.max(...o.x)+5}const m=Math.ceil(c.length/4);u+="M V30 MDLV30/STEABS ATOMS=("+c.length+" -\n";for(let t=0;t<m;t++){u+="M V30 ";const e=t+1===m?c.length-4*(m-1):4;for(let n=0;n<e;n++)u+=n+1===e?t===m-1?c[4*t+n]+")\n":c[4*t+n]+" -\n":c[4*t+n]+" "}return n+="M V30 COUNTS "+l+" "+f+" 0 0 0\n",n+="M V30 BEGIN ATOM\n",n+=r,n+="M V30 END ATOM\n",n+="M V30 BEGIN BOND\n",n+=a,n+="M V30 END BOND\n",e&&c.length>0?(n+="M V30 BEGIN COLLECTION\n",n+=u,n+="M V30 END COLLECTION\n"):n=n.replace(/ CFG=\d/g," "),n+="M V30 END CTAB\n",n+="M END",n}function o(t){const e=s(t),n=e.atomIndex.length,r=(Math.max(...e.x)+Math.min(...e.x))/2,o=(Math.max(...e.y)+Math.min(...e.y))/2;for(let t=0;t<n;t++)e.x[t]-=r,e.y[t]-=o;const i=Math.PI,a=Math.cos(i),u=Math.sin(i);for(let t=0;t<n;t++){const n=e.x[t];e.x[t]=n*a-e.y[t]*u,e.y[t]=n*u+e.y[t]*a}const c=Math.max(...e.y);for(let t=0;t<n;t++)e.x[t]+=r,e.y[t]-=c;let l=t.indexOf("M V30 BEGIN ATOM");l=t.indexOf("\n",l);let f=l;for(let r=0;r<n;r++)l=t.indexOf("V30",l)+4,l=t.indexOf(" ",l)+1,l=t.indexOf(" ",l)+1,f=t.indexOf(" ",l)+1,f=t.indexOf(" ",f),l=(t=t.slice(0,l)+e.x[r]+" "+e.y[r]+t.slice(f)).indexOf("\n",l)+1;return t}function i(t){let e=(t=t.replaceAll("\r","")).indexOf("COUNTS")+7,n=t.indexOf(" ",e);const r=parseInt(t.substring(e,n));return e=n+1,n=t.indexOf(" ",e),{natom:r,nbond:parseInt(t.substring(e,n))}}function s(t){const e=i(t);let n=t.indexOf("M V30 BEGIN ATOM");n=t.indexOf("\n",n);let r=n;const o=Array(e.natom),s=Array(e.natom),a=Array(e.natom),u=Array(e.natom);for(let i=0;i<e.natom;i++)n=t.indexOf("V30",n)+4,r=t.indexOf(" ",n),o[i]=parseInt(t.substring(n,r)),n=r+1,r=t.indexOf(" ",n),s[i]=t.substring(n,r),n=r+1,r=t.indexOf(" ",n),a[i]=parseFloat(t.substring(n,r)),n=r+1,r=t.indexOf(" ",n),u[i]=parseFloat(t.substring(n,r)),n=t.indexOf("\n",n)+1;return{atomIndex:o,atomType:s,x:a,y:u}}n.d(e,{cx:()=>s,vS:()=>r})},537:(t,e,n)=>{"use strict";n.d(e,{iL:()=>i,q7:()=>o,ti:()=>r});const r={NUCLEOSIDE:"nucleoside",LINKAGE:"phosphateBackbone"},o="p",i="<?>"},480:(t,e,n)=>{"use strict";n.d(e,{C6:()=>u,Hs:()=>a,OT:()=>c,bD:()=>s});var r=n(686),o=n(67),i=n(537);function s(t,e,n,o){const i=Object.keys(o.jsonData.codesToHelmDict).concat([r.NO.HELM]);if(!t||-1!==e&&n!==r.NO.HELM)return{};if(!i.includes(n))throw new Error(`${n} format is not supported by SequenceTranslator`);const s=i.filter((t=>t!=n)).sort(((t,e)=>t.localeCompare(e))),u=o.createFormatConverter(t,n),c=Object.fromEntries(s.map((t=>{let e;try{e=u.convertTo(t)}catch{e=null}return[t,e]})).filter((([t,e])=>e))),l=a(n===r.NO.HELM?t:c[r.NO.HELM],o.monomerLibWrapper);return l&&(c.Nucleotides=l),c}function a(t,e){const n=new RegExp("\\([^()]*\\)","g"),o=t.match(n);return o?o.map((t=>{const n=t.replace(/[\[\]()]/g,"");return r.AL.includes(n)?n:e.getNaturalAnalogBySymbol(n)})).map((t=>t||i.iL)).join(""):null}function u(t,e,n,i){const s=i.createFormatConverter(t,e);return n===o.qP?a(s.convertTo(r.NO.HELM),i.monomerLibWrapper):s.convertTo(n)}function c(t){return Object.keys(t.jsonData.codesToHelmDict).concat([r.NO.HELM,o.qP]).sort()}},67:(t,e,n)=>{"use strict";n.d(e,{U_:()=>o,n_:()=>r,qP:()=>i});const r="Copied",o="Copy sequence",i="Nucleotides"},544:(t,e,n)=>{"use strict";n.d(e,{_package:()=>It});var r=n(328),o=n(82);n(439),new class{constructor(){this.seqHandler="seq-handler",this.notationProvider="seq-handler.notation-provider"}},o.SemanticValue;var i=n(890);class s{constructor(t,e,n=""){this.target=t,this.debugEnabled=e,this.prefix=n}error(t,e,n){return this.target.error(this.prefix+t,e,n)}warning(t,e){return this.target.warning(this.prefix+t,e)}info(t,e){return this.target.info(this.prefix+t,e)}debug(t,e){if(this.debugEnabled)return this.target.debug(this.prefix+t,e)}}const a="System:AppData/SequenceTranslator/monomers-sample",u="pattern-app-data.json",c="formats-to-helm.json",l="codes-to-symbols.json",f="linkers.json";var h=n(686);function p(t){return t.sort(((t,e)=>e.length-t.length))}class d{constructor(t,e){this.sequence=t,this.th=e,this.libWrapper=this.th.monomerLibWrapper}getInvalidCodeIndex(t){if(t===h.NO.HELM)return this.sequence.length;const e=["r","d"],n=p(this.libWrapper.getCodesByFormat(t));let r=0;for(;r<this.sequence.length;){const t=n.find((t=>t===this.sequence.substring(r,r+t.length)));if(!t)break;if(r>1&&h.AL.includes(this.sequence[r])&&e.includes(this.sequence[r-2]))break;if(e.includes(this.sequence[r+1])&&h.AL.includes(this.sequence[r])){r++;break}r+=t.length}return r===this.sequence.length&&(r=-1),r}isValidSequence(t){return-1===this.getInvalidCodeIndex(t)}}class g{constructor(t,e,n,r){this.patternAppData=t,this.codesToHelmDict=e,this.codesToSymbolsDict=n,this.monomersWithPhosphate=r}}async function m(t){const e=await Promise.all([u,c,l,f].map((e=>async function(t,e){const n=t.endsWith("/")?`${t}${e}`:`${t}/${e}`;try{const t=await r.dapi.files.readAsText(n);return JSON.parse(t)}catch(t){console.error(`Error loading json from '${n}':`,t)}}(t,e))));return new g(e[0],e[1],e[2],e[3])}class y{constructor(t,e){if(this.lib=t,this.jsonData=e,null===this.lib)throw new Error("SequenceTranslator: monomer library is null");this.allMonomers=this.getAllMonomers()}formatMonomerForViewer(t){const e={};return e.name=t.symbol,e.symbol=t.symbol,e.molfile=t.molfile,this.getAllFormats().forEach((n=>{if(n===h.NO.HELM)return;const r=this.jsonData.codesToSymbolsDict[n],o=Object.keys(r).filter((e=>r[e]===t.symbol));e[n]=o.join(", ")})),e}getAllMonomers(){const t=this.lib.getPolymerTypes();let e=[];for(const n of t){const t=this.lib.getMonomerSymbolsByType(n).map((t=>this.lib.getMonomer(n,t))).filter((t=>null!==t));e=e.concat(t)}return e}getMonomer(t){const e=this.lib.getMonomer("RNA",t);if(void 0===e)throw new Error(`SequenceTranslator: no monomer with symbol ${t}`);return e}getMolfileBySymbol(t){return this.getMonomer(t).molfile}getNaturalAnalogBySymbol(t){const e=this.getMonomer(t).naturalAnalog;if(!e)throw new Error(`ST: no natural analog for ${t}`);return e}isModification(t){return!!this.getMolfileBySymbol(t).includes("MODIFICATION")}getCodeToSymbolMap(t){return new Map(Object.entries(this.jsonData.codesToSymbolsDict[t]))}getCodesByFormat(t){return Object.keys(this.jsonData.codesToSymbolsDict[t])}getAllFormats(){return Object.keys(this.jsonData.codesToSymbolsDict)}getTableForViewer(){const t=this.allMonomers.map((t=>this.formatMonomerForViewer(t)));return o.DataFrame.fromObjects(t)}getCodesToWeightsMap(){const t=new Map;return Object.entries(this.jsonData.codesToSymbolsDict).forEach((([e,n])=>{Object.entries(n).forEach((([e,n])=>{const r=this.getMonomer(n),o=r.meta?.molecularWeight;t.set(e,o)}))})),t}}var v=n(537);const b=(t,e)=>e.length-t.length;class C{constructor(t){this.th=t,this.formats=this.getFormats()}getFormatNames(){return this.formats.sort()}getCodesByFormat(t){if(this.validateFormat(t),this.isHelm(t))throw new Error("Codes cannot be obtained for HELM");return this.getFormatCodes(t)}getHelmToFormatDict(t){return this.validateFormat(t),function(t){const e={};return Object.values(t).forEach((t=>{Object.entries(t).forEach((([t,n])=>{const r=n.replace(/\)p/g,")").replace(/\]p/g,"]");void 0===e[r]?e[r]=[t]:e[r].push(t)}))})),Object.entries(e).forEach((([t,n])=>{const r=n.sort(b);e[t]=r[0]})),e}(this.th.jsonData.codesToHelmDict[t])}getFormatToHelmDict(t){this.validateFormat(t);const e=this.th.jsonData.codesToHelmDict[t];return Object.assign({},...Object.values(e))}getTargetFormatHelmCodes(t){this.validateFormat(t);const e=this.getHelmToFormatDict(t);return Object.keys(e).sort(b)}getTargetFormatHelmCodesRegExp(t){this.validateFormat(t);const e=this.getTargetFormatHelmCodes(t);return new RegExp(w(e)+"|.","g")}getFormatRegExp(t){if(this.validateFormat(t),this.isHelm(t))throw new Error("Helm RegExp can be built for non-HELM target formats");return this.getNonHelmFormatRegExp(t)}getPhosphateHelmCodesRegExp(t){this.validateFormat(t);const e=this.th.jsonData.codesToHelmDict[t],n=w(Array.from(new Set(Object.values(e[v.ti.LINKAGE]))).sort(b));return new RegExp(`${v.q7}.(${n})`,"g")}isValidFormat(t){return this.formats.includes(t)}getFormats(){return Object.keys(this.th.jsonData.codesToHelmDict)}validateFormat(t){if(!this.isValidFormat(t))throw new Error(`Invalid format: ${t}`)}isHelm(t){return t===h.NO.HELM}getFormatCodes(t){const e=this.getFormatToHelmDict(t);return Object.keys(e).sort(b)}getNonHelmFormatRegExp(t){const e=this.getCodesByFormat(t);return new RegExp(w(e)+"|\\([^()]*\\)|.","g")}}function w(t){return t.map((t=>t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"))).map((t=>t.includes("(")||t.includes(")")?t:`(?<!\\([^()]*)${t}(?![^()]*\\))`)).join("|")}const A={LEFT:"RNA1{",RIGHT:"}$$$$"};class E{constructor(t,e,n){this.sequence=t,this.sourceFormat=e,this.th=n,this.formats=new C(this.th)}convertTo(t){const e=this.formats.getFormatNames();if(this.sourceFormat===h.NO.HELM&&e.includes(t))return this.helmToFormat(this.sequence,t);if(e.includes(this.sourceFormat)&&t===h.NO.HELM)return this.formatToHelm(this.sequence,this.sourceFormat);if([this.sourceFormat,t].every((t=>e.includes(t)))){const e=this.formatToHelm(this.sequence,this.sourceFormat);return this.helmToFormat(e,t)}throw new Error(`ST: unsupported translation direction ${this.sourceFormat} -> ${t}`)}helmToFormat(t,e){const n=new RegExp(w(Object.values(A)),"g");let r=t.replace(n,"");const o=this.formats.getHelmToFormatDict(e),i=this.formats.getTargetFormatHelmCodes(e),s=this.formats.getTargetFormatHelmCodesRegExp(e);return r=r.replace(s,(t=>i.includes(t)?o[t]:"p"===t||"."===t?t:"?")).replace(/\?+/g,v.iL).replace(/p\.|\./g,""),r=r.replace(/<empty>/g,""),r=r.replace(/\/\//g,"/"),r}formatToHelm(t,e){const n=this.formats.getFormatToHelmDict(e),r=this.formats.getCodesByFormat(e),o=this.formats.getFormatRegExp(e),i=this.formats.getPhosphateHelmCodesRegExp(e);let s=t?t.replace(o,(t=>r.includes(t)?n[t]+".":"?")):"";return s=s.replace(/\?+/g,`${v.iL}.`),s=s.slice(0,-1),s[s.length-1]===v.q7&&(s=s.slice(0,-1)),s=s.replace(i,((t,e)=>e)),s=s.replace(/<empty>/g,""),`${A.LEFT+s+A.RIGHT}`}}class _{constructor(t,e){this.sequence=t,this.th=e,this.libWrapper=this.th.monomerLibWrapper,this.formats=Object.keys(this.th.jsonData.codesToHelmDict)}getFormat(){if(this.sequence.startsWith("RNA"))return h.NO.HELM;const t=this.getListOfPossibleSynthesizersByFirstMatchedCode();if(0===t.length)return null;const e=this.th.createSequenceValidator(this.sequence),n=Array(t.length).fill(0);for(let r=0;r<t.length;++r){const o=t[r];n[r]=e.getInvalidCodeIndex(o)}const r=n.some((t=>-1===t))?-1:Math.max(...n);return t[n.indexOf(r)]}getListOfPossibleSynthesizersByFirstMatchedCode(){const t=this.sequence,e=[];for(const n of this.formats){const r=p(this.libWrapper.getCodesByFormat(n));let o=0;for(let e=0;e<t.length;e++)if(")"===t[e]&&e!==t.length-1){o=e+1;break}r.some((e=>e===t.slice(o,o+e.length)))&&e.push(n)}return e}}var x=n(389);const T=$;var I=n.n(T);class P extends o.Package{get seqHelper(){if(!this._seqHelper)throw new Error("Package SequenceTranslator .seqHelper is not initialized");return this._seqHelper}get monomerLib(){if(!this._monomerLib)throw new Error("Monomer lib not loaded");return this._monomerLib}get jsonData(){if(!this._jsonData)throw new Error("Json data not loaded");return this._jsonData}get monomerLibWrapper(){if(!this._monomerLibWrapper)throw new Error("Monomer lib wrapper not loaded");return this._monomerLibWrapper}get initPromise(){return this._initPromise}constructor(t={debug:!1}){super(),this.highlightInvalidSubsequence=t=>function(t,e){let n=0;const r=e.createFormatDetector(t).getFormat();null!==r&&(n=new d(t,e).getInvalidCodeIndex(r));const o=n<0||""===t,i=x.span([]);I()(i).css("-webkit-text-fill-color","var(--grey-6)");const s=x.span([]);return I()(s).css("-webkit-text-fill-color","red"),o?i.innerHTML=t:(i.innerHTML=t.slice(0,n),s.innerHTML=t.slice(n)),[i,s]}(t,this),super._logger=new s(super.logger,t.debug)}startInit(t){this._initPromise=t}completeInit(t){this._seqHelper=t}async initLibData(){return this.initLibDataPromise||(this.initLibDataPromise=(async()=>{let t=(await this.getSettings()).MonomersPath;t&&await r.dapi.files.exists(t)||(this.logger.warning(`Monomers path '${t}' not found. Fallback to monomers sample path '${a}'.`),t=a),[this._jsonData,this._monomerLib]=await Promise.all([m(t),S(t)]),this._monomerLibWrapper=new y(this.monomerLib,this.jsonData)})()),this.initLibDataPromise}async getTranslationHelper(){return await r.functions.call(`${this.name}:getTranslationHelper`)}createSequenceValidator(t){return new d(t,this)}createFormatConverter(t,e){return new E(t,e,this)}createFormatDetector(t){return new _(t,this)}}async function S(t){const e=o.TaskBarProgressIndicator.create("Initializing Oligo Toolkit monomer library ...");try{const e=await(0,i.pj)();return await e.readLibrary(t,"monomer-lib.json")}finally{e.close()}}const O=["SS","AS"],N={SS:"Sense strand",AS:"Anti sense"},L=["3'","5'"];var M,D,R,B;!function(t){t.IS_ANTISENSE_STRAND_INCLUDED="isAntisenseStrandIncluded",t.NUCLEOTIDE_SEQUENCES="nucleotideSequences",t.PHOSPHOROTHIOATE_LINKAGE_FLAGS="phosphorothioateLinkageFlags",t.STRAND_TERMINUS_MODIFICATIONS="strandTerminusModifications"}(M||(M={})),function(t){t.PATTERN_NAME="patternName",t.PATTERN_COMMENT="patternComment",t.NUCLEOTIDES_WITH_NUMERIC_LABELS="nucleotidesWithNumericLabels"}(D||(D={})),function(t){t.PATTERN_CONFIG="patternConfig",t.AUTHOR_ID="authorID",t.DATE="date"}(R||(R={})),function(t){t.CREATE="create",t.MODIFY="modify"}(B||(B={})),M.IS_ANTISENSE_STRAND_INCLUDED,M.NUCLEOTIDE_SEQUENCES,M.PHOSPHOROTHIOATE_LINKAGE_FLAGS,M.STRAND_TERMINUS_MODIFICATIONS,D.PATTERN_NAME,D.PATTERN_COMMENT,D.NUCLEOTIDES_WITH_NUMERIC_LABELS,Error,Error,n(802);const F=rxjs;var H;rxjs.operators,function(t){t.getTruncatedStrandData=function(t,e,n){return{nucleotides:t.slice(0,n),ptoFlags:e.slice(0,n+1)}},t.getExtendedStrandData=function(t,e,n,r){const o=n-t.length,i=t.concat(new Array(n-t.length).fill(r)),s=0===t.length?n+1:o;return{nucleotides:i,ptoFlags:e.concat(new Array(s).fill(!0))}}}(H||(H={}));var k=n(543),G=n.n(k),j=n(72),U=n.n(j),V=n(825),W=n.n(V),Y=n(659),q=n.n(Y),K=n(56),z=n.n(K),J=n(540),Q=n.n(J),X=n(113),Z=n.n(X),tt=n(252),et={};et.styleTagTransform=Z(),et.setAttributes=z(),et.insert=q().bind(null,"head"),et.domAPI=W(),et.insertStyleElement=Q(),U()(tt.A,et),tt.A&&tt.A.locals&&tt.A.locals;class nt{constructor(t,e,n){this.eventBus=t,this.initialPatternConfig=e,this.subscriptions=n}create(){return x.divV([x.h1("PTO"),x.divH([this.createAllPtoActivationInput().root,...this.createFirstPtoInputs().map((t=>t.root))],{style:{gap:"12px"}})])}areAllPtoLinkagesSet(t){return O.map((e=>t[e].filter((t=>t)).length)).reduce(((t,e)=>t+e),0)===O.map((t=>this.initialPatternConfig.nucleotideSequences[t].length)).reduce(((t,e)=>t+e),0)+O.filter((e=>t[e].length)).length}createAllPtoActivationInput(){const t=this.initialPatternConfig.phosphorothioateLinkageFlags,e=this.areAllPtoLinkagesSet(t),n=x.input.bool("All PTO",{value:e});n.onInput.subscribe((()=>{const t=n.value;this.eventBus.setAllPTOLinkages(t)}));const r=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((()=>{const t=this.eventBus.getPatternConfig().phosphorothioateLinkageFlags,e=this.areAllPtoLinkagesSet(t);n.value=e}));return this.subscriptions.add(r),this.addStyleToPtoInput(n),x.tooltip.bind(n.captionLabel,"Activate all phosphothioates"),n}addStyleToPtoInput(t){const e=t.captionLabel;e.classList.add("ui-label-right"),Object.assign(e.style,{textAlign:"left",maxWidth:"100px",minWidth:"40px",width:"auto"})}createFirstPtoInputs(){return O.map((t=>{if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return;const e=this.isFirstPtoActive(t),n=x.input.bool(`First ${t} PTO`,{value:e});n.onInput.subscribe((()=>{const e=n.value;this.eventBus.setPhosphorothioateLinkageFlag(t,0,e)}));const r=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((e=>{const r=e[t][0];n.value=r}));return this.subscriptions.add(r),this.addStyleToPtoInput(n),x.tooltip.bind(n.captionLabel,`Activate first phosphothioate in ${t}`),n})).filter((t=>void 0!==t))}isFirstPtoActive(t){return this.initialPatternConfig.phosphorothioateLinkageFlags[t][0]}}class rt{constructor(t,e,n){this.eventBus=t,this.dataManager=e,this.subscriptions=n;const r=this.eventBus.nucleotideSequencesChanged$.subscribe((()=>{this.displayedInputLabels=this.computeDisplayedInputLabels()}));this.subscriptions.add(r)}create(){const t=O.map((t=>this.constructControlsPanel(t)));return x.divH(t,{style:{gap:"24px"}})}constructControlsPanel(t){if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return x.div([]);const e=this.constructHeader(),n=this.createControls(t);return x.block([x.h1(`${N[t]}`),e,n],{style:{paddingTop:"12px"}})}constructHeader(){return x.divH([x.div([x.divText("#")],{style:{width:"20px"}}),x.block75([x.divText("Modification")]),x.div([x.divText("PTO")])])}createControls(t){const e=this.createNucleobaseInputs(t),n=this.createLabelDivs(t),r=this.createPTOFlagInputs(t);return x.div(e.map(((t,e)=>x.divH([n[e],x.block75([t.root]),r[e].root],{style:{alignItems:"center"}}))))}createNucleobaseInputs(t){const e=this.dataManager.fetchAvailableNucleotideBases().sort(((t,e)=>t.toLowerCase().localeCompare(e.toLowerCase())));return this.eventBus.getNucleotideSequences()[t].map(((n,r)=>{const o=x.input.choice("",{value:n,items:e});return o.onInput.subscribe((()=>{const e=o.value;this.eventBus.setNucleotide(t,r,e)})),o}))}createPTOFlagInputs(t){return this.eventBus.getPhosphorothioateLinkageFlags()[t].slice(1).map(((e,n)=>{const r=x.input.bool("",{value:e});r.onInput.subscribe((()=>{const e=r.value;this.eventBus.setPhosphorothioateLinkageFlag(t,n+1,e)}));const o=this.eventBus.phosphorothioateLingeFlagsChanged$.subscribe((e=>{const o=e[t][n+1];r.value=o}));return this.subscriptions.add(o),r}))}computeDisplayedInputLabels(){const t=this.eventBus.getNucleotideSequences(),e=new Map;return O.forEach((n=>{let r=1;const o=t[n].map((t=>{if(function(t){return t.endsWith("(o)")}(t))return"";const e=String(r);return r++,e}));e.set(n,o)})),e}createLabelDivs(t){const e=this.createLabels(t).map((t=>x.div([t],{style:{width:"20px"}}))),n=this.eventBus.nucleotideSequencesChanged$.subscribe((()=>{this.createLabels(t).forEach(((t,n)=>{I()(e[n]).empty(),I()(e[n]).append(t)}))}));return this.subscriptions.add(n),e}createLabels(t){return this.eventBus.getNucleotideSequences()[t].map(((e,n)=>{const r=this.displayedInputLabels.get(t)[n];return x.label(r)}))}}class ot{constructor(){this.rxjsSubscriptions=[],this.dgSubscriptions=[]}add(t){t instanceof F.Subscription?this.rxjsSubscriptions.push(t):this.dgSubscriptions.push(t)}unsubscribeAll(){for(const t of[this.rxjsSubscriptions,this.dgSubscriptions])t.forEach((t=>t.unsubscribe())),t.length=0}}class it{constructor(t,e){this.eventBus=t,this.dataManager=e,this.subscriptions=new ot}static open(t,e){it.isDialogOpen||(it.instance||(it.instance=new it(t,e)),it.instance.openDialog())}openDialog(){this.initialPatternConfig=G().cloneDeep(this.eventBus.getPatternConfig()),it.isDialogOpen=!0,this.createDialog().show()}createDialog(){const t=x.divV([]);this.subscriptions.add(this.eventBus.strandsUpdated$.subscribe((()=>this.onStrandsUpdated(t))));const e=x.dialog("Edit strands").add(t).onOK((()=>{})).onCancel((()=>this.resetToInitialState()));return this.subscriptions.add(e.onClose.subscribe((()=>{it.isDialogOpen=!1,this.subscriptions.unsubscribeAll()}))),e}onStrandsUpdated(t){const e=new nt(this.eventBus,this.initialPatternConfig,this.subscriptions).create(),n=new rt(this.eventBus,this.dataManager,this.subscriptions).create();I()(t).empty(),I()(t).append(e,n)}resetToInitialState(){this.eventBus.setPatternConfig(this.initialPatternConfig)}}it.isDialogOpen=!1;class st{constructor(t){this.eventBus=t,this.subscriptions=new ot}static open(t){st.isDialogOpen||(st.instance||(st.instance=new st(t)),st.instance.openDialog())}openDialog(){this.initialPatternConfig=G().cloneDeep(this.eventBus.getPatternConfig()),st.isDialogOpen=!0,this.createDialog().show()}createDialog(){const t=x.divV([]);this.subscriptions.add(this.eventBus.strandsUpdated$.subscribe((()=>this.onStrandsUpdated(t))));const e=x.dialog("Edit terminal modifications").add(t).onOK((()=>{})).onCancel((()=>this.resetToInitialState()));return this.subscriptions.add(e.onClose.subscribe((()=>{st.isDialogOpen=!1,this.subscriptions.unsubscribeAll()}))),e}onStrandsUpdated(t){const e=new at(this.eventBus).create();I()(t).empty(),I()(t).append(e)}resetToInitialState(){this.eventBus.setPatternConfig(this.initialPatternConfig)}}st.isDialogOpen=!1;class at{constructor(t){this.eventBus=t}create(){const t=O.map((t=>this.constructControlsPanel(t)));return x.divH(t,{style:{gap:"24px"}})}constructControlsPanel(t){if(!this.eventBus.isAntisenseStrandActive()&&"AS"===t)return x.div([]);const e=this.createInputs(t);return x.block([x.h1(`${N[t]}`),e],{style:{paddingTop:"12px"}})}createInputs(t){const e=("SS"===t?[...L].reverse():L).map((e=>this.createInputForTerminus(t,e)));return x.form(e)}createInputForTerminus(t,e){const n=this.eventBus.getTerminalModifications()[t][e],r=x.input.textArea(e,{value:n});return this.applyStylingToInput(r),r.onInput.subscribe((()=>{const n=r.value;null!==n&&this.eventBus.updateTerminusModification(t,e,n)})),r}applyStylingToInput(t){const e=t.root.getElementsByTagName("textarea")[0];I()(e).css("resize","none")}}n(146);var ut=n(507),ct={};ct.styleTagTransform=Z(),ct.setAttributes=z(),ct.insert=q().bind(null,"head"),ct.domAPI=W(),ct.insertStyleElement=Q(),U()(ut.A,ct),ut.A&&ut.A.locals&&ut.A.locals;var lt,ft=n(74),ht={};ht.styleTagTransform=Z(),ht.setAttributes=z(),ht.insert=q().bind(null,"head"),ht.domAPI=W(),ht.insertStyleElement=Q(),U()(ft.A,ht),ft.A&&ft.A.locals&&ft.A.locals,function(t){t.TYPE="V2000",t[t.NUM_OF_HEADER_LINES=3]="NUM_OF_HEADER_LINES",t[t.NUM_OF_COUNTS_DIGITS=3]="NUM_OF_COUNTS_DIGITS",t[t.ATOM_TYPE_COL=4]="ATOM_TYPE_COL",t[t.FIRST_BONDED_ATOM_COL=1]="FIRST_BONDED_ATOM_COL",t[t.BOND_TYPE_COL=3]="BOND_TYPE_COL",t[t.RGP_SHIFT=8]="RGP_SHIFT",t[t.MAX_ATOM_COUNT=999]="MAX_ATOM_COUNT",t.RGP_LINE_START="M RGP",t.ATOM_ALIAS_LINE_START="A ",t.END="M END"}(lt||(lt={})),Error,Error,n(670),n(3),n(480),n(67);var pt=n(254),dt={};dt.styleTagTransform=Z(),dt.setAttributes=z(),dt.insert=q().bind(null,"head"),dt.domAPI=W(),dt.insertStyleElement=Q(),U()(pt.A,dt),pt.A&&pt.A.locals&&pt.A.locals;var gt=n(70);n(124),n(312),n(991),"object"==typeof performance&&performance&&"function"==typeof performance.now?performance:Date,new Set;const mt="object"==typeof process&&process?process:{};let yt=globalThis.AbortController,vt=globalThis.AbortSignal;if(void 0===yt){vt=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(t,e){this._onabort.push(e)}},yt=class{constructor(){e()}signal=new vt;abort(t){if(!this.signal.aborted){this.signal.reason=t,this.signal.aborted=!0;for(const e of this.signal._onabort)e(t);this.signal.onabort?.(t)}}};let t="1"!==mt.env?.LRU_CACHE_IGNORE_AC_WARNING;const e=()=>{var n,r,o,i;t&&(t=!1,n="AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.",r="NO_ABORT_CONTROLLER",o="ENOTSUP",i=e,"function"==typeof mt.emitWarning?mt.emitWarning(n,r,o,i):console.error(`[${o}] ${r}: ${n}`))}}Symbol("type"),Symbol.iterator,Symbol.toStringTag,Map,n(151),n(599),n(717),n(702),n(948);class bt extends o.InputBase{constructor(t,e){super(x.input.column(t,e).dart,e?.onValueChanged),this.options=e}setColumnInputTable(t){x.input.setColumnInputTable(this,t,this.options?.filter)}}var Ct;x.input.column2=function(t,e){return new bt(t,e)},n(296),n(820),o.JsInputBase,o.JsInputBase,function(t){t.table="table",t.seqCol="seqCol",t.generateHelm="generateHelm",t.chiralityEngine="chiralityEngine",t.rules="rules"}(Ct||(Ct={}));class wt{onKeyDown(t,e){}onKeyPress(t,e){}onMouseEnter(t,e){}onMouseLeave(t,e){}onMouseDown(t,e){}onMouseUp(t,e){}onMouseMove(t,e){}onClick(t,e){}onDoubleClick(t,e){}}class At extends wt{constructor(t,e,n){super(),this.gridCol=t,this.tableCol=e,this.logger=n,this.subs=[],this.dirty=!0,this.destroyed=!1,this.viewerId=++At.viewerCounter,this.errors=[],this._onRendered=new F.Subject,this.tableCol&&this.tableCol.dataFrame&&this.subs.push(this.tableCol.dataFrame.onDataChanged.subscribe((()=>{this.dirty=!0}))),this.tableCol&&this.subs.push(r.events.onTableRemoved.subscribe((t=>{try{const e=t.args.dataFrame;this.tableCol?.dataFrame.id!==e.id||this.destroyed||this.destroy()}catch(t){this.logger.error(t)}}))),this.gridCol&&this.subs.push(r.events.onViewRemoving.subscribe((t=>{try{const e=t.args.view;this.gridCol?.dart&&this.gridCol.grid&&this.gridCol?.grid?.dart&&this.gridCol?.grid?.view?.id===e.id&&!this.destroyed&&this.destroy()}catch(t){this.logger.error(t)}})))}toLog(){return`${this.constructor.name}<${this.viewerId}>`}destroy(){for(const t of this.subs)t.unsubscribe();this.destroyed=!0}invalidateGrid(){this.gridCol&&this.gridCol.dart&&this.gridCol.grid?.invalidate()}reset(){this.dirty=!1}get onRendered(){return this._onRendered}invalidate(t){this.invalidateGrid()}async awaitRendered(t=1e4,e=`${t} timeout`){const n=`${this.toLog()}.awaitRendered()`;if(this.logger.debug(`${n}, start, testEvent before`),await(0,gt.PE)(this._onRendered,(()=>{}),(()=>{this.invalidate()}),t,`${n}, ${e}`),this.errors.length>0){const t=this.errors[0];throw this.errors=[],t}this.logger.debug(`${n}, end`)}}At.viewerCounter=-1,n(192);var Et,_t,xt,Tt=n(291);Tt.zS,function(t){t.maxMonomerLength=".mm.cellRenderer.maxMonomerLength"}(Et||(Et={})),function(t){t.applyToBackground=".m.cellRenderer.applyToBackground"}(_t||(_t={})),function(t){t.MSA="MSA",t.classic="classic"}(xt||(xt={})),new class{constructor(){this.color="rgb(100,100,100)",this.pivot=0,this.left=!1,this.transparencyRate=1,this.separator="",this.last=!1,this.drawStyle=xt.classic,this.maxWord=[],this.wordIdx=0,this.gridCell=null,this.referenceSequence=null,this.maxLengthOfMonomer=null,this.monomerTextSizeMap={},this.logger=void 0}},Tt.Mu;const It=new P({debug:!0})},948:(t,e,n)=>{"use strict";n.d(e,{sW:()=>h,by:()=>p,MH:()=>m,kl:()=>d,jX:()=>y,AM:()=>g});var r=n(328),o=n(991),i=n.n(o),s=n(599),a=n(890),u=n(717),c=n(192),l=n(296),f=n(544);class h{constructor(t,e,n){this.linkages=e,this.monomers=t,this.mol=n}static parseHelm(t,e){const n=/(\w+\{.*\})\$(.*)\$(.*)\$(.*)\$/g.exec(t),r=[n[1],n[2],n[3],n[4]],o=r[0].split("|"),i=r[1].split("|"),a=new Array(o.length),u=[],c=e.createHelmWebEditor().editor.m;let l=0;const f=new JSDraw2.Point(0,0);for(let t=0;t<o.length;t++){const e=o[t].indexOf("{"),n=o[t].indexOf("}");a[t]=o[t].slice(e+1,n).split(".").map((t=>{return(e=t).startsWith("[")&&e.endsWith("]")?e.slice(1,-1):e;var e}));for(let e=0;e<a[t].length;e++){const n=a[t][e],r={type:s.o.AA,i:t,j:e,continuousId:l},o=new JSDraw2.Atom(f,n,r);if(c.addAtom(o),0!==e){const t=c.atoms[l-1],e=c.atoms[l],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,c.addBond(n)}l++,f.x+=JSDraw2.Editor.BONDLENGTH}f.y+=4*JSDraw2.Editor.BONDLENGTH}for(let t=0;t<i.length;t++)if(""!==i[t]&&"V2.0"!==i[t]){const e=i[t].split(","),n=parseInt(e[0].replace("PEPTIDE",""))-1,r=parseInt(e[1].replace("PEPTIDE",""))-1,o=e[2].split("-"),s=o[0].split(":"),c=o[1].split(":");u.push({fChain:n,sChain:r,fMonomer:y(parseInt(s[0]),n,a),sMonomer:y(parseInt(c[0]),r,a),fR:parseInt(s[1].replace("R","")),sR:parseInt(c[1].replace("R",""))})}for(let t=0;t<u.length;t++){const e=c.atoms[u[t].fMonomer-1],n=c.atoms[u[t].sMonomer-1],r=new JSDraw2.Bond(e,n);r.r1=u[t].fR,r.r2=u[t].sR,c.addBond(r)}return new h(a,u,c)}applyRules(t){throw this.monomers.map((t=>[...t])),this.linkages,this.mol.clone(),new Error("not implemented")}static fromNotation(t,e,n){const r=e.heterodimerCode,o=e.homodimerCode,i=[],a=[],u=null!==r?t.split(`(${e.heterodimerCode})`):"";null!==r&&u.length>1?(a.push({fChain:0,sChain:1,fMonomer:1,sMonomer:1,fR:1,sR:1}),i.push(u[1].replaceAll("{","").replaceAll("}","")),i.push(u[2].replaceAll("{","").replaceAll("}",""))):i.push(t);for(let t=0;t<i.length;t++)if(null!==o&&i[t].includes(`(${o})`)){const e=i.length;a.push({fChain:t,sChain:e,fMonomer:1,sMonomer:1,fR:1,sR:1});const n=i[t].replace(`(${o})`,""),r=n.indexOf("{"),s=n.slice(0,r),u=n.replace(s,"").replaceAll("{","").replaceAll("}","");i[t]=s+u,i.push(u)}for(let t=0;t<i.length;t++)if(null!==o&&i[t].includes(`(${o})`)){const e=i.length;a.push({fChain:t,sChain:e,fMonomer:1,sMonomer:1,fR:1,sR:1});const n=i[t].replace(`(${o})`,""),r=n.indexOf("{"),s=n.slice(0,r),u=n.replace(s,"").replaceAll("{","").replaceAll("}","");i[t]=s+u,i.push(u)}const c=new Array(i.length);for(let t=0;t<i.length;t++){const n=i[t].split("-"),r=this.getLinkedPositions(n,e.linkRules),[o,s,u,l,f]=this.getAllCycles(e.linkRules,n,r);new Array(o.length);for(let e=0;e<s.length;e++)a.push({fChain:t,sChain:t,fMonomer:s[e],sMonomer:u[e],fR:l[e],sR:f[e]});c[t]=o}const l=[],f=n.createHelmWebEditor().editor.m;let p=0;const d=new JSDraw2.Point(0,0);for(let t=0;t<c.length;t++){const n=this.getLinkedPositions(c[t],e.reactionRules),[r,o,i,u]=this.getAllReactants(e.reactionRules,c[t],n);if(o.length>=1){const n=new Array(i[0]-1),c=new Array(r.length-i[0]);for(let e=0;e<i[0]-1;e++){const o=n[e]=r[e],i={type:s.o.AA,i:t,j:e,continuousId:p},a=new JSDraw2.Atom(d,o,i);if(f.addAtom(a),e>0){const t=f.atoms[p-1],e=f.atoms[p],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,f.addBond(n)}p++}for(let e=i[0];e<r.length;e++){const n=c[e-i[0]]=r[e],o={type:s.o.AA,i:t,j:e,continuousId:p},a=new JSDraw2.Atom(d,n,o);if(f.addAtom(a),e>i[0]){const t=f.atoms[p-1],e=f.atoms[p],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,f.addBond(n)}p++}f.atoms[o[0]-1].elem=n[o[0]-1]=e.reactionRules[u[0]].name;for(let t=0;t<a.length;t++)a[t].fMonomer>i[0]&&(a[t].fMonomer-=i[0],a[t].fChain++),a[t].sMonomer>i[0]&&(a[t].sMonomer-=i[0],a[t].sChain++);a.push({fChain:0,sChain:0,fMonomer:o[0],sMonomer:i[0]-1,fR:3,sR:2}),a.push({fChain:0,sChain:1,fMonomer:o[0],sMonomer:1,fR:4,sR:1});const h=new Array(n.length);for(let t=0;t<n.length;t++)h[t]=`[${n[t]}]`;const g=new Array(c.length);for(let t=0;t<c.length;t++)g[t]=`[${c[t]}]`;l.push(n),l.push(c)}else{for(let e=0;e<c[t].length;e++){const n=c[t][e],r={type:s.o.AA,i:t,j:e,continuousId:p},o=new JSDraw2.Atom(d,n,r);if(f.addAtom(o),e>0){const t=f.atoms[p-1],e=f.atoms[p],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,f.addBond(n)}p++}l.push(c[t])}}for(const t of a){const e=f.atoms[t.fMonomer-1],n=f.atoms[t.sMonomer-1],r=new JSDraw2.Bond(e,n);r.r1=t.fR,r.r2=t.sR,f.addBond(r)}return new h(l,a,f)}static parseNotation(t,e){const n=[],r=[],o=e.createHelmWebEditor().editor.m,i=/(\(.\d+\))?\{[^\}]*\}/g,a=[];a.push(t.replaceAll(i,""));const u=t.matchAll(i);for(const t of u){const e=t[0];e&&a.push(e)}let c=0;for(let t=0;t<a.length;t++){const e=a[t].split("-"),o=new Array(e.length);let i=0;for(let n=0;n<e.length;n++){const s=e[n].replace("{","").replace("}","");""!==s?(o[n]=s,c++,i++):r.push({fChain:t,sChain:t+1,fMonomer:c,sMonomer:c+1,fR:1,sR:1})}n.push(o.slice(0,i))}c=0;const l=new JSDraw2.Point(0,0);for(let t=0;t<n.length;t++)for(let e=0;e<n[t].length;e++){if(n[t][e]){const r=n[t][e],i={type:s.o.AA,i:t,j:e,continuousId:c},a=new JSDraw2.Atom(l,r,i);if(o.addAtom(a),0!==e){const t=o.atoms[c-1],e=o.atoms[c],n=new JSDraw2.Bond(t,e);n.r1=2,n.r2=1,o.addBond(n)}c++,l.x+=JSDraw2.Editor.BONDLENGTH}l.y+=4*JSDraw2.Editor.BONDLENGTH}for(let t=0;t<r.length;t++){const e=o.atoms[r[t].fMonomer-1],n=o.atoms[r[t].sMonomer-1],i=new JSDraw2.Bond(e,n);i.r1=r[t].fR,i.r2=r[t].sR,o.addBond(i)}return new h(n,r,o)}getHelmChanged(t,e){let n=0,r=0,o=0;t:for(let e=0;e<this.monomers.length;e++)for(let i=0;i<this.monomers[e].length;i++){if(n==t){r=e,o=i;break t}n++}const i=this.monomers[r][o];this.monomers[r][o]=`[${e}]`;const s=this.getHelm();return this.monomers[r][o]=i,s}getNotationHelm(){return this.getHelm()}getHelm(){let t="";for(let e=0;e<this.monomers.length;e++){e>0&&(t+="|"),t+=`PEPTIDE${e+1}{`;for(let n=0;n<this.monomers[e].length;n++){n>0&&(t+=".");const r=this.monomers[e][n];t+=r.length>1?`[${r}]`:r}t+="}"}t+="$";for(let e=0;e<this.linkages.length;e++)e>0&&(t+="|"),t+=`PEPTIDE${this.linkages[e].fChain+1},PEPTIDE${this.linkages[e].sChain+1},`,t+=`${m(this.linkages[e].fMonomer-1,this.monomers)[0]+1}:R${this.linkages[e].fR}-`,t+=`${m(this.linkages[e].sMonomer-1,this.monomers)[0]+1}:R${this.linkages[e].sR}`;return t+="$$$V2.0",t}getNotation(){const t=this.mol.atoms,e=this.mol.bonds,n=[],r=[];for(let t=0;t<e.length;t++)e[t].a1.bio.i!==e[t].a2.bio.i&&r.push(t);for(let e=0;e<t.length;e++){const r=t[e].bio?.i;r+1>n.length?n.push(1):n[r]++}const o=new Array(n.length);let i=0;for(let e=0;e<n.length;e++){const r=new Array(n[e]);for(let o=0;o<n[e];o++)r[o]=t[i].elem,i++;o[e]=r}let s="";for(let t=0;t<o.length;t++){let n="";for(let e=0;e<o[t].length;e++)n+=`${0==e?"":"-"}${o[t][e]}`;if(0!==t){const t=/(\(.\d+\))/,e=n.match(t);n=n.replace(e?.[0],""),n=`${e?e?.[0]:""}{${n}}`}else if(o.length>1){const t=0==e[r[0]].a1.bio.i&&0==e[r[0]].a1.bio.j,o=1==e[r[0]].a2.bio.i&&0==e[r[0]].a1.bio.j;t&&o&&(n+="-")}s+=n}return s}static getLinkedPositions(t,e){const n=new Array(e.length);for(let r=0;r<e.length;r++){let o=!1,i=!1,s=!1,a=-1,u=-1;const c=`(${e[r].code})`;for(let n=0;n<t.length;n++)if(t[n].includes(c)){if(o){if(s&&t[n]==e[r].secondMonomer+c){i=!0,u=n;break}if(s||t[n]!=e[r].firstMonomer+c)continue;i=!0,u=n;break}if(t[n]==e[r].firstMonomer+c)o=!0,s=!0,a=n;else{if(t[n]!=e[r].secondMonomer+c)continue;o=!0,s=!1,a=n}}n[r]=o&&i?s?[a,u,r]:[u,a,r]:[-1,-1,-1]}return n}static getAllCycles(t,e,n){const r=[],o=[],i=[],s=[],a=t.length;for(let u=0;u<a;u++){if(-1==n[u][0])continue;const a=e[n[u][0]],c=e[n[u][1]];e[n[u][0]]=e[n[u][0]].replace(a,t[u].firstSubstitution),e[n[u][1]]=e[n[u][1]].replace(c,t[u].secondSubstitution),r.push(n[u][0]+1),o.push(n[u][1]+1),i.push(t[u].firstLinkingGroup),s.push(t[u].secondLinkingGroup)}return[e,r,o,i,s]}static getAllReactants(t,e,n){const r=[],o=[],i=[],s=t.length;for(let a=0;a<s;a++){if(-1==n[a][0])continue;const s=e[n[a][0]],u=e[n[a][1]];e[n[a][0]]=e[n[a][0]].replace(s,t[a].firstMonomer),e[n[a][1]]=e[n[a][1]].replace(u,t[a].secondMonomer),r.push(n[a][0]+1),o.push(n[a][1]+1),i.push(n[a][2])}return[e,r,o,i]}check(t=!1){const e=[],n=this.monomers.map((t=>t.length)).reduce(((t,e)=>t+e),0);this.mol.atoms.length!==n&&e.push(`The mol atoms count ${this.mol.atoms.length} does not match the total number ${n} of chains' monomers.`);const r=this.monomers.map((t=>t.length-1)).reduce(((t,e)=>t+e),0)+this.linkages.length;this.mol.bonds.length!==r&&e.push(`The mol bonds count ${this.mol.bonds.length} does not match the total number ${r} in- and inter-chain linkages.`);let o=0;for(let t=0;t<this.monomers.length;++t){const n=this.monomers[t];for(let t=0;t<n.length;++t)try{const r=n[t],i=this.mol.atoms[o];i.bio.continuousId!==o&&e.push(`Atom #${o} has incorrect .bio.continuousId: ${i.bio.continuousId}.`),i.elem!==r&&e.push(`Atom #${o} elem: '${i.elem}' does not match chain monomer: '${r}'.`)}finally{o++}}if(t&&e.length>0)throw new Error(`Chain errors:\n${e.map((t=>` ${t}`)).join("\n")}`);return e}}function p(t,e,n){const r=new Array(t.length);for(let o=0;o<t.length;o++)try{if(null==t[o])r[o]="";else{const i=h.fromNotation(t[o],e,n);r[o]=i.getHelm()}}catch(t){const[e,n]=(0,c.AP)(t);f._package.logger.error(e,void 0,n),r[o]=""}return r}function d(t,e,n){const o=n.reaction,i=n.name,s=e.getMonomer("PEPTIDE",n.firstMonomer);if(!s)throw new l.bl("PEPTIDE",n.firstMonomer);const a=e.getMonomer("PEPTIDE",n.secondMonomer);if(!a)throw new l.bl("PEPTIDE",n.secondMonomer);const[u,f]=function(t,e){const n=t.molfile;let r=e.molfile;const o=t.rgroups.length,i=r.indexOf("M RGP");if(-1!==i){const t=r.substring(i+6,i+9),e=Number(t);for(let t=0;t<e;t++){const e=i+9+4+8*t,n=i+9+8+8*t,s=r.substring(e,n),a=Number(s)+o,u=Math.floor(Math.log10(a)+1),c=" ".repeat(4-u)+String(a);r=r.substring(0,e)+c+r.substring(n,r.length)}}return[n,r]}(s,a),h=function(t,e,n,o,i){let s=null,a=null,u=null,f=null,h=null,p=null,d="";try{if(s=t.get_rxn(e),!s)throw new l.J5(e);a=new t.MolList,u=t.get_mol(n),f=t.get_mol(o),a.append(u),a.append(f),h=s.run_reactants(a,1),p=h.get(0).next(),d=p?.get_molblock()}catch(t){const[e,n]=(0,c.AP)(t);throw r.shell.error(`Can not assemble monomer '${i}': ${e}.`),t}finally{s?.delete(),a?.delete(),u?.delete(),f?.delete(),h?.delete(),p?.delete()}return d}(t,o,u,f,i),p=function(t,e){const n=new Array(t?.rgroups.length+e?.rgroups.length),r=t?.rgroups.length,o=e?.rgroups.length;for(let e=0;e<r;e++)n[e]=t?.rgroups[e];for(let t=0;t<o;t++){const o=e?.rgroups[t].label.replace("R",""),i=Number(o)+r,s={capGroupSMILES:e?.rgroups[t].capGroupSMILES.replace(o,String(i)),alternateId:e?.rgroups[t].alternateId.replace(o,String(i)),capGroupName:e?.rgroups[t].capGroupName,label:e?.rgroups[t].label.replace(o,String(i))};n[t+r]=s}return n}(s,a),d={symbol:i,name:i,molfile:h,author:"",id:0,rgroups:p,smiles:"",polymerType:"PEPTIDE",monomerType:"Backbone",createDate:null};return d.meta=Object.assign(d.meta??{},{colors:{default:{line:"#2083D5",text:"#2083D5",background:"#F2F2F5"}}}),[i,d]}async function g(t){const e=(await(0,a.pj)()).getMonomerLib(),n=await(0,u.j)(),r={};for(let o=0;o<t.reactionRules.length;o++){const[i,s]=d(n,e,t.reactionRules[o]);r[i]=s}const o={PEPTIDE:r};return e.override(o,"ST-PT-reactions."+i().repeat(1).map((()=>Math.floor(36*Math.random()).toString(36))).take(4).toArray().join(""))}function m(t,e){let n,r=t;for(n=0;n<e.length&&r>=e[n].length;++n)r-=e[n].length;return[r,n]}function y(t,e,n){let r=0;for(let t=0;t<e;++t)r+=n[t].length;return r+t}},820:(t,e,n)=>{"use strict";n.d(e,{o:()=>i});var r=n(296);function o(t,e,n,r){const o=new Array(r.length*(n-e+1));for(let i=0;i<r.length;++i){const s=n-e+1;for(let n=0;n<s;++n){const a=e+n,u=r[i],c=o[i*s+n]=t.clone(),l=c.atoms[a].elem;c.atoms[a].elem=u;const f=l?.length>1?`[${l}]`:l,h=u?.length>1?`[${u}]`:u;c.name=`${t.name}-${f}${a+1}${h}`}}return o}function i(t,e,n){const i=new JSDraw2.MolHandler,s=new org.helm.webeditor.Plugin(i);org.helm.webeditor.IO.parseHelm(s,t,new JSDraw2.Point(0,0),void 0);const a=i.m;a.name=e;let u=[];if(n.placeholders)switch(n.type){case r.aK.Single:u=function(t,e){return e.map((e=>o(t,e.position,e.position,e.monomers))).reduce(((t,e)=>t.concat(e)),[])}(i.m,n.placeholders);break;case r.aK.Matrix:u=function(t,e){let n=[t];for(const t of e){const e=n.map((e=>o(e,t.position,t.position,t.monomers)));n=e.reduce(((t,e)=>t.concat(e)),[])}return n}(i.m,n.placeholders)}let c=[];n.breadthPlaceholders&&(c=function(t,e){if(0==e.length)return[];let n=[t];for(const t of e){const e=n.map((e=>o(e,t.start,t.end,t.monomers)));n=e.reduce(((t,e)=>t.concat(e)),[])}return n}(i.m,n.breadthPlaceholders)),u=u.concat(c),n.keepOriginal&&(u=[a,...u]);const l=u.map((t=>[org.helm.webeditor.IO.getHelm(t),t.name]));return l}},702:(t,e,n)=>{"use strict";n.d(e,{Q4:()=>l});var r=n(82),o=n(328);n(389),n(991);const i="System:AppData/SequenceTranslator/polytool-rules/",s="link",a="reaction",u="fragmentDuplication",c="differentFragments";async function l(t){const e=new r.FileSource(i),n=[],l=[],f={homodimerCode:null,heterodimerCode:null,linkRules:n,reactionRules:l};for(let r=0;r<t.length;r++){const h=await e.readAsText(t[r].replace(i,"")),p=JSON.parse(h);for(let t=0;t<p.length;t++)if(void 0!==p[t].type&&void 0!==p[t].code)switch(p[t].type){case s:{const e=p[t].monomericSubstitution;e.code=p[t].code,n.push(e);break}case a:{const e=p[t].monomericSubstitution;e.code=p[t].code,l.push(e);break}case u:f.homodimerCode&&o.shell.warning("PolyTool: homodimer code is duplicated in rules."),f.homodimerCode=p[t].code;break;case c:f.heterodimerCode&&o.shell.warning("PolyTool: heterodimer code is duplicated in rules."),f.heterodimerCode=p[t].code;break;default:o.shell.warning(`PolyTool: Unexpected type - '${p[t]}'.`)}else o.shell.warning("Polytool: rules contain invalid rule")}return f}},296:(t,e,n)=>{"use strict";var r;n.d(e,{J5:()=>i,aK:()=>r,bl:()=>o}),function(t){t.Single="single",t.Matrix="matrix"}(r||(r={}));class o extends Error{constructor(t,e,n){super(`Monomer '${e}' of polymer type '${t}' not found`,n),this.type="MonomerNotFoundError"}}class i extends Error{constructor(t,e){super(`Invalid reaction '${t}'.`),this.type="InvalidReactionError"}}},82:t=>{"use strict";t.exports=DG},328:t=>{"use strict";t.exports=grok},389:t=>{"use strict";t.exports=ui},991:t=>{"use strict";t.exports=wu}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.m=t,n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.u=t=>t+".js",n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),(()=>{var t;n.g.importScripts&&(t=n.g.location+"");var e=n.g.document;if(!t&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(t=e.currentScript.src),!t)){var r=e.getElementsByTagName("script");if(r.length)for(var o=r.length-1;o>-1&&(!t||!/^http(s?):/.test(t));)t=r[o--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=t})(),n.b=document.baseURI||self.location.href,n.nc=void 0;var r={};(()=>{"use strict";n.r(r),n.d(r,{_package:()=>O,initAutoTests:()=>L,test:()=>N,tests:()=>e.CN});var t=n(82),e=n(70),o=n(328),i=n(686);class s extends t.Package{async getTranslationHelper(){return await o.functions.call(`${this.name}:getTranslationHelper`)}}function a(t,e,n){return n.createFormatConverter(t,e).convertTo(i.NO.HELM)}function u(t,e,n){return n.createFormatConverter(t,i.NO.HELM).convertTo(e)}const c={Axolabs:{UfAfsCfsGfuacg:"RNA1{[fR](U)p.[fR](A)[sp].[fR](C)[sp].[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$"},BioSpring:{"A*GC*123456789":"RNA1{r(A)[sp].r(G)p.r(C)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)p.d([m5C])}$$$$"},Mermade12:{hefglijkLIJKHEFG:"RNA1{[25r](U)[sp].[25r](A)[sp].[25r](C)[sp].[25r](G)[sp].[fR](U)[sp].[fR](A)[sp].[fR](C)[sp].[fR](G)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$"}},l={"RNA1{[fR](U)p.[fR](A)[sp].[fR](C)[sp].[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$":"UACGUACG","RNA1{r(A)[sp].r(G)p.r(C)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)p}$$$$":"AGCUACGUACG","RNA1{[25r](U)[sp].[25r](A)[sp].[25r](C)[sp].[25r](G)[sp].[fR](U)[sp].[fR](A)[sp].[fR](C)[sp].[fR](G)[sp].[fR](U)p.[fR](A)p.[fR](C)p.[fR](G)p.[25r](U)p.[25r](A)p.[25r](C)p.[25r](G)}$$$$":"UACGUACGUACGUACG"};(0,e.L1)("Formats to HELM",(()=>{let t;(0,e.gM)((async()=>{t=await O.getTranslationHelper()}));for(const n of Object.keys(c))for(const[r,o]of Object.entries(c[n]))(0,e.t6)(`${n} to HELM`,(async()=>{const i=o,s=a(r,n,t);(0,e.E3)(s,i)}))})),(0,e.L1)("HELM to Formats",(()=>{let t;(0,e.gM)((async()=>{t=await O.getTranslationHelper()}));for(const n of Object.keys(c))for(const[r,o]of Object.entries(c[n]))(0,e.t6)(`${n} to HELM`,(async()=>{const i=r,s=u(o,n,t);(0,e.E3)(s,i)}))}));var f=n(480);(0,e.L1)("HELM to Nucleotides",(()=>{let t;(0,e.gM)((async()=>{t=await O.getTranslationHelper()})),Object.entries(l).forEach((([n,r],o)=>{(0,e.t6)(`Sequence ${o+1} to nucleotides`,(async()=>{const o=r,i=(0,f.Hs)(n,t.monomerLibWrapper);(0,e.E3)(i,o)}))}))}));const h={[i.NO.AXOLABS]:"Afcgacsu",[i.NO.HELM]:"RNA1{[fR](A)p.[25r](C)p.[25r](G)p.[25r](A)p.[25r](C)[sp].[25r](U)}$$$$"};(0,e.L1)("Formats support",(()=>{let t;(0,e.gM)((async()=>{t=await O.getTranslationHelper()})),Object.entries(h).forEach((([n,r])=>{(0,e.t6)(`All formats for ${n}`,(async()=>{const o=function(t,e,n){const r=n.createSequenceValidator(t).getInvalidCodeIndex(e);return(0,f.bD)(t,r,e,n)}(r,n,t),i=Object.keys(o).length,s=Object.keys(c).length+1;(0,e.E3)(!0,s<=i)}))}))}));var p=n(192);(0,e.L1)("files",(()=>{let n;(0,e.gM)((async()=>{n=await O.getTranslationHelper()})),(0,e.t6)("list",(async()=>{let r;const o=t.DataFrame.fromColumns([t.Column.string("subTest"),r=t.Column.bool("success"),t.Column.string("format"),t.Column.string("src"),t.Column.string("res"),t.Column.string("tgt"),t.Column.string("error"),t.Column.string("stack")]),i=await O.files.list("tests",!0,".csv");for(const r of i){const i=t.DataFrame.fromCsv(await r.readAsString()),s=i.columns.byIndex(0),u=s.name,c=i.columns.byIndex(1),l=i.rowCount;for(let t=0;t<l;++t){const i=o.rows.addNew();i.subTest=`${r.name}, row: ${t}`;try{const r=s.get(t),o=c.get(t);i.format=u,i.src=r,i.tgt=o;const l=i.res=a(r,u,n);(0,e.E3)(l,o),i.success=!0}catch(t){const[e,n]=(0,p.AP)(t);i.error=e,i.stack=n,i.success=!1}}}0==o.rowCount&&o.rows.addNew(["empty",!0,"",""]);const s=r.toList().findIndex((t=>1!=t));if(-1!=s){const t=o.rows.get(s);throw new Error(`Subtest '${t.subTest}' failed: ${t.error}`)}return o}),{skipReason:"Can not create test in async manner based on files in Shares."})}));var d=n(312),g=n(3);class m{constructor(t,e,n,r,o,i){this.units=t,this.aligned=e,this.alphabet=n,this.alphabetSize=r,this.alphabetIsMultichar=o,this.separator=i}}async function y(e,n){const r=(await e()).getCol(n),i=await o.functions.call("Bio:detectMacromolecule",{col:r});if(i&&(r.semType=i),r.semType===t.SEMTYPE.MACROMOLECULE){const t=`Negative test detected semType='${r.semType}', units='${r.meta.units}'.`;throw new Error(t)}}async function v(n,r,i,s,a,u,c,l,f=null){const h=(await n()).col(r),p=await o.functions.call("Bio:detectMacromolecule",{col:h});p&&(h.semType=p),(0,e.E3)(h.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(h.meta.units,s),(0,e.E3)(h.getTag(g.gp.aligned),a),(0,e.E3)(h.getTag(g.gp.alphabet),u),f&&(0,e.E3)(h.getTag(g.gp.separator),f);const d=i.getSeqHandler(h);(0,e.E3)(d.getAlphabetSize(),c),(0,e.E3)(d.getAlphabetIsMultichar(),l),d.isHelm()||((0,e.E3)(d.aligned,a),(0,e.E3)(d.alphabet,u))}(0,e.L1)("PolyTool: detectors",(()=>{let n;(0,e.gM)((async()=>{n=await(0,d.Q)()}));const r={cyclized1:{csv:"n,seq\n1,R-F-C(1)-T-G-H-F-Y-G-H-F-Y-G-H-F-Y-P-C(1)-meI\n2,C(1)-T-G-H-F-Y-P-C(1)-meI\n3,R-F-C(1)-T-G-H-F-Y-P-C(1)\n4,C(1)-T-G-H-F-H-P-C(1)\n5,R-F-D(2)-T-G-H-F-Y-P-NH2(2)\n6,R-F-aG(4)-T-G-H-F-Y-P-azG(4)-meI",pos:{seq:new m(g.Hi.CUSTOM,"SEQ",g.YI.UN,13,!0,"-")}}};for(const[o,i]of Object.entries(r))(0,e.t6)(`${o}`,(async()=>{const e=async()=>t.DataFrame.fromCsv(i.csv);for(const t of i.neg??[])await y(e,t);for(const[t,r]of Object.entries(i.pos??{}))await v(e,t,n,r.units,r.aligned,r.alphabet,r.alphabetSize,r.alphabetIsMultichar,r.separator)}))}));var b=n(890);const C="Libraries";let w=Promise.resolve();async function A(){let t;return w=w.then((async()=>{const e=o.userSettings.getValue(C,"Settings",!0);t=e?JSON.parse(e):{exclude:[],explicit:[],duplicateMonomerPreferences:{}},t.exclude=t.exclude instanceof Array?t.exclude:[],t.explicit=t.explicit instanceof Array?t.explicit:[],t.duplicateMonomerPreferences=t.duplicateMonomerPreferences instanceof Object?t.duplicateMonomerPreferences:{},console.debug(`Bio: getUserLibSettings()\n${JSON.stringify(t,void 0,2)}`)})),await w,t}async function E(t){w=w.then((async()=>{console.debug(`Bio: setUserLibSettings()\n${JSON.stringify(t,void 0,2)}`),o.userSettings.add(C,"Settings",JSON.stringify(t),!0)})),await w}var _=n(717),x=n(124),T=n(948),I=n(702);(0,e.L1)("PolyTool: Convert",(()=>{let n,r,i,s,a;(0,e.gM)((async()=>{n=await(0,x.b2)(),r=await(0,d.Q)(),i=await(0,_.j)(),s=await(0,b.pj)(),a=await A(),await s.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await E(a),await s.loadMonomerLib(!0)}));const u={"cyclized-C(1)-2-1":{src:{seq:"R-F-C(1)-T-G-H-F-Y-P-C(1)-meI"},tgt:{helm:"PEPTIDE1{R.F.C.T.G.H.F.Y.P.C.[meI]}$PEPTIDE1,PEPTIDE1,3:R3-10:R3$$$V2.0",mol:{atomCount:95,bondCount:100,inchiKey:"LMJUFVBPWWJJPN-AJJYTACESA-N"}}},"cyclized-C(1)-0-1":{src:{seq:"C(1)-T-G-H-F-Y-P-C(1)-meI"},tgt:{helm:"PEPTIDE1{C.T.G.H.F.Y.P.C.[meI]}$PEPTIDE1,PEPTIDE1,1:R3-8:R3$$$V2.0",mol:{atomCount:73,bondCount:77,inchiKey:"KLFRBMUPPMMGJM-HXTBFBBASA-N"}}},"cyclized-C(1)-2-0":{src:{seq:"R-F-C(1)-T-G-H-F-Y-P-C(1)"},tgt:{helm:"PEPTIDE1{R.F.C.T.G.H.F.Y.P.C}$PEPTIDE1,PEPTIDE1,3:R3-10:R3$$$V2.0",mol:{atomCount:86,bondCount:91,inchiKey:"WIHSRTQGMICACU-DDDKLKPZSA-N"}}},"cyclized-C(1)-0-0":{src:{seq:"C(1)-T-G-H-F-Y-P-C(1)"},tgt:{helm:"PEPTIDE1{C.T.G.H.F.Y.P.C}$PEPTIDE1,PEPTIDE1,1:R3-8:R3$$$V2.0",mol:{atomCount:64,bondCount:68,inchiKey:"LOSMDBLEXLWPLB-OFZKBENXSA-N"}}},"cyclized-D(2)-NH2(2)-3-0":{src:{seq:"R-F-D(2)-T-G-H-F-Y-P-NH2(2)"},tgt:{helm:"PEPTIDE1{R.F.D.T.G.H.F.Y.P.[NH2]}$PEPTIDE1,PEPTIDE1,10:R2-3:R3$$$V2.0",mol:{atomCount:81,bondCount:86,inchiKey:"CBMGNYKOZWNVNK-AHGCAHLCSA-N"}}},"cyclized-D(2)-NH2(2)-0-0":{src:{seq:"D(2)-T-G-H-F-Y-P-NH2(2)"},tgt:{helm:"PEPTIDE1{D.T.G.H.F.Y.P.[NH2]}$PEPTIDE1,PEPTIDE1,8:R2-1:R3$$$V2.0",mol:{atomCount:59,bondCount:63,inchiKey:"HGRHAUQBJXFERJ-MUFWPYSASA-N"}}},"cyclized-azG(4)-aG(4)-2-1":{src:{seq:"R-F-azG(4)-T-G-H-F-Y-P-aG(4)-meI"},tgt:{helm:"PEPTIDE1{R.F.[GGaz].T.G.H.F.Y.P}|PEPTIDE2{[meI]}$PEPTIDE1,PEPTIDE1,3:R3-9:R2|PEPTIDE1,PEPTIDE2,3:R4-1:R1$$$V2.0",mol:{atomCount:97,bondCount:103,inchiKey:"WJSYGVBGPCCSJF-PERUNASMSA-N"}}}};for(const[t,r]of Object.entries(u))(0,e.t6)(`toHelm-${t}`,(async()=>{const t=await(0,I.Q4)(["rules_example.json"]),o=(0,T.by)([r.src.seq],t,n);(0,e.E3)(o[0],r.tgt.helm)}));for(const[o,s]of Object.entries(u))(0,e.t6)(`toAtomicLevel-${o}`,(async()=>{const o=await(0,I.Q4)(["rules_example.json"]),a=(0,T.by)([s.src.seq],o,n),u=await(0,T.AM)(o),c=t.Column.fromStrings("helm",a);c.semType=t.SEMTYPE.MACROMOLECULE,c.meta.units=g.Hi.HELM;const l=await r.helmToAtomicLevel(c,!1,!1,u);if(l.warnings&&l.warnings.length>0)throw new Error(l.warnings[0]);(0,e.E3)(null!=l.molCol,!0,".molCol is not null");const f=l.molCol.get(0),h=i.get_mol(f);try{const t={atomCount:h.get_num_atoms(),bondCount:h.get_num_bonds(),inchiKey:i.get_inchikey_for_inchi(h.get_inchi())};(0,e.Xk)(t,s.tgt.mol)}finally{h.delete()}}));(0,e.t6)("ui-col-wo-table",(async()=>{const n=O.name,r=Object.values(u).map((t=>t.src.seq)),i=Object.values(u).map((t=>t.tgt.helm)),s=t.Column.fromStrings("seq",r),a=await o.functions.call(`${n}:polyToolConvert2`,{seqCol:s,generateHelm:!0,chiralityEngine:!0,rules:["rules_example.json"]});(0,e.J6)(a.toList(),i),(0,e.E3)(a.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(a.meta.units,g.Hi.HELM),(0,e.E3)(a.dataFrame,null)})),(0,e.t6)("ui-col",(async()=>{const n=O.name,r=Object.values(u).map((t=>t.src.seq)),i=Object.values(u).map((t=>t.tgt.helm)),s=t.Column.fromStrings("seq",r),a=t.DataFrame.fromColumns([s]),c=o.shell.addTableView(a),l=await o.functions.call(`${n}:polyToolConvert2`,{seqCol:s,generateHelm:!0,chiralityEngine:!0,rules:["rules_example.json"]});(0,e.J6)(l.toList(),i),(0,e.E3)(l.semType,t.SEMTYPE.MACROMOLECULE),(0,e.E3)(l.meta.units,g.Hi.HELM),(0,e.E3)(l.dataFrame.id,a.id),await(0,e.PE)(c.grid.onAfterDrawContent,(()=>{}),(async()=>{c.grid.invalidate()}),15e3),(0,e.E3)(l.getTag(t.TAGS.CELL_RENDERER),"helm")}))}));var P=n(296),S=n(820);(0,e.L1)("PolyTool: Enumerate",(()=>{let t,n,r;(0,e.gM)((async()=>{t=await(0,x.b2)(),n=await(0,b.pj)(),r=await A(),await n.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await E(r),await n.loadMonomerLib(!0)}));const o={single1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,placeholders:[{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5P"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.[F4COO].L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5[F4COO]"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7T"}]},"single-with-original":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,placeholders:[{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}],keepOriginal:!0},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:""},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5P"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.[F4COO].L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5[F4COO]"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-[Tic]7T"}]},matrix1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Matrix,placeholders:[{position:1,monomers:["D","L"]},{position:4,monomers:["K","P","F4COO"]},{position:6,monomers:["Y","T"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].D.W.G.K.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5K-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.K.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5K-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5P-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5P-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.[F4COO].L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5[F4COO]-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].D.W.G.[F4COO].L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2D-P5[F4COO]-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.K.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5K-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.K.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5K-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.P.L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5P-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.P.L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5P-[Tic]7T"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.[F4COO].L.Y.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5[F4COO]-[Tic]7Y"},{seq:"PEPTIDE1{[Ac(1)].L.W.G.[F4COO].L.T.[C(1)].G.[NH2]}$$$$V2.0",name:"-F2L-P5[F4COO]-[Tic]7T"}]}};for(const[t,n]of Object.entries(o))(0,e.t6)(`${t}`,(async()=>{const t=(0,S.o)(n.src,"",n.params);(0,e.J6)(t,n.tgt.map((t=>[t.seq,t.name])))}))})),(0,e.L1)("PolyTool: Enumerate",(()=>{let t,n,r;(0,e.gM)((async()=>{t=await(0,x.b2)(),n=await(0,b.pj)(),r=await A(),await n.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await E(r),await n.loadMonomerLib(!0)}));const o={breadth1:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,breadthPlaceholders:[{start:2,end:4,monomers:["K"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"}]},"breadth1-with-original":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,breadthPlaceholders:[{start:2,end:4,monomers:["K"]}],keepOriginal:!0},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:""},{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"}]},breadth2:{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,breadthPlaceholders:[{start:2,end:4,monomers:["K","Y"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.K.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K"},{seq:"PEPTIDE1{[Ac(1)].F.Y.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5Y"}]},"breadth-double":{src:"PEPTIDE1{[Ac(1)].F.W.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",params:{type:P.aK.Single,breadthPlaceholders:[{start:2,end:4,monomers:["K"]},{start:2,end:4,monomers:["Y"]}]},tgt:[{seq:"PEPTIDE1{[Ac(1)].F.Y.G.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-K3Y"},{seq:"PEPTIDE1{[Ac(1)].F.K.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.K.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-W3K-P5Y"},{seq:"PEPTIDE1{[Ac(1)].F.Y.K.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.P.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-K4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.K.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-G4K-P5Y"},{seq:"PEPTIDE1{[Ac(1)].F.Y.G.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-W3Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.Y.K.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-G4Y"},{seq:"PEPTIDE1{[Ac(1)].F.W.G.Y.L.[Tic].[C(1)].G.[NH2]}$$$$V2.0",name:"-P5K-K5Y"}]}};for(const[t,n]of Object.entries(o))(0,e.t6)(`${t}`,(async()=>{const t=(0,S.o)(n.src,"",n.params);(0,e.J6)(t,n.tgt.map((t=>[t.seq,t.name])))}))})),(0,e.L1)("PolyTool: Chain: parseNotation",(()=>{let t;(0,e.gM)((async()=>{t=await(0,x.b2)()}));const n={cyclized:{src:{seq:"R-F-C(1)-T-G-H-F-Y-P-C(1)-meI"},tgt:{helm:"PEPTIDE1{R.F.[C(1)].T.G.H.F.Y.P.[C(1)].[meI]}$$$$V2.0"}},dimerized1:{src:{seq:"(#3)Succ-{A(CHOL)-F-C(1)-T-G-H-Y-P-C(1)-NH2}"},tgt:{helm:"PEPTIDE1{[(#3)Succ]}|PEPTIDE2{[A(CHOL)].F.[C(1)].T.G.H.Y.P.[C(1)].[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0"}},dimerized2:{src:{seq:"($3)Succ-{R-F-C(1)-T-G-H-F-P-C(1)-NH2}($2){A(CHOL)-F-C(1)-T-G-H-F-P-C(1)-NH2}"},tgt:{helm:"PEPTIDE1{[($3)Succ]}|PEPTIDE2{R.F.[C(1)].T.G.H.F.P.[C(1)].[NH2]}|PEPTIDE3{[($2)A(CHOL)].F.[C(1)].T.G.H.F.P.[C(1)].[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0"}}};for(const[r,o]of Object.entries(n))(0,e.t6)(`${r}`,(async()=>{await(0,I.Q4)(["rules_example.json"]);const n=await T.sW.parseNotation(o.src.seq,t),r=n.mol,i=t.createHelmWebEditor();i.editor.setMol(r);const s=i.editor.getHelm(),a=n.getNotationHelm();(0,e.E3)(s,o.tgt.helm),(0,e.E3)(a,o.tgt.helm)}),"reaction2"==r?{skipReason:"reverse reaction"}:void 0);const r={"0-in-4-4-3":{inIdx:0,spIdx:0,outIdx:0,monomers:[["0","1","2","3"],["4","5","6","7"],["8","9","10"]]},"3-in-4-4-3":{inIdx:3,spIdx:0,outIdx:3,monomers:[["0","1","2","3"],["4","5","6","7"],["8","9","10"]]},"4-in-4-4-3":{inIdx:0,spIdx:1,outIdx:4,monomers:[["0","1","2","3"],["4","5","6","7"],["8","9","10"]]},"7-in-4-4-3":{inIdx:3,spIdx:1,outIdx:7,monomers:[["0","1","2","3"],["4","5","6","7"],["8","9","10"]]},"8-in-4-4-3":{inIdx:0,spIdx:2,outIdx:8,monomers:[["0","1","2","3"],["4","5","6","7"],["8","9","10"]]},"0-in-1-1-6-3":{inIdx:0,spIdx:0,outIdx:0,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]},"1-in-1-1-6-3":{inIdx:0,spIdx:1,outIdx:1,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]},"2-in-1-1-6-3":{inIdx:0,spIdx:2,outIdx:2,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]},"3-in-1-1-6-3":{inIdx:1,spIdx:2,outIdx:3,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]},"7-in-1-1-6-3":{inIdx:5,spIdx:2,outIdx:7,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]},"8-in-1-1-6-3":{inIdx:0,spIdx:3,outIdx:8,monomers:[["0"],["1"],["2","3","4","5","6","7"],["8","9","10"]]}};for(const[t,{inIdx:n,spIdx:o,outIdx:i,monomers:s}]of Object.entries(r))(0,e.t6)(`innerIdx-${t}`,(async()=>{const[t,r]=(0,T.MH)(i,s);(0,e.E3)(t,n),(0,e.E3)(r,o)}));for(const[t,{inIdx:n,spIdx:o,outIdx:i,monomers:s}]of Object.entries(r))(0,e.t6)(`outerIdx-${t}`,(async()=>{const t=(0,T.jX)(n,o,s);(0,e.E3)(t,i)}))})),(0,e.L1)("PolyTool: Chain",(()=>{let t;(0,e.gM)((async()=>{t=await(0,x.b2)()}));const n={cyclized:{data:{templateSeq:"R-F-C(1)-T-G-H-F-Y-P-C(1)-meI",templateHelm:"PEPTIDE1{R.F.[C(1)].T.G.H.F.Y.P.[C(1)].[meI]}$$$$V2.0",mmHelm:"PEPTIDE1{R.F.C.T.G.H.F.Y.P.C.[meI]}$PEPTIDE1,PEPTIDE1,3:R3-10:R3$$$V2.0"},tgt:{templateChain:{monomerCount:[11],linkageCount:0},mmChain:{monomerCount:[11],linkageCount:1}}},reaction1:{data:{templateSeq:"R-F-azG(4)-T-G-H-F-Y-P-aG(4)-meI",templateHelm:"PEPTIDE1{R.F.[azG(4)].T.G.H.F.Y.P.[aG(4)].[meI]}$$$$V2.0",mmHelm:"PEPTIDE1{R.F.[GGaz].T.G.H.F.Y.P}|PEPTIDE2{[meI]}$PEPTIDE1,PEPTIDE1,3:R3-9:R2|PEPTIDE1,PEPTIDE2,3:R4-1:R1$$$V2.0"},tgt:{templateChain:{monomerCount:[11],linkageCount:0},mmChain:{monomerCount:[9,1],linkageCount:2}}},reaction2:{data:{templateSeq:"R-F-aG(4)-T-G-H-F-Y-P-azG(4)-meI",templateHelm:"PEPTIDE1{R.F.[aG(4)].T.G.H.F.Y.P.[azG(4)].[meI]}$$$$V2.0",mmHelm:"PEPTIDE1{R.F}|PEPTIDE2{T.G.H.F.Y.P.[GGaz].[meI]}$PEPTIDE1,PEPTIDE2,2:R2-7:R3|PEPTIDE2,PEPTIDE2,1:R1-7:R4,$$$V2.0"},tgt:{templateChain:{monomerCount:[11],linkageCount:0},mmChain:{monomerCount:[2,8],linkageCount:2}}},dimerized1:{data:{templateSeq:"(#3)Succ-{A(CHOL)-F-C(1)-T-G-H-Y-P-C(1)-NH2}",templateHelm:"PEPTIDE1{[(#3)Succ]}|PEPTIDE2{[A(CHOL)].F.[C(1)].T.G.H.Y.P.[C(1)].[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0",mmHelm:"PEPTIDE1{[Succ].[A(CHOL)].F.C.T.G.H.Y.P.C.[NH2]}|PEPTIDE2{[A(CHOL)].F.C.T.G.H.Y.P.C.[NH2]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1|PEPTIDE1,PEPTIDE1,4:R3-10:R3|PEPTIDE2,PEPTIDE2,3:R3-9:R3$$$V2.0"},tgt:{templateChain:{monomerCount:[1,10],linkageCount:1},mmChain:{monomerCount:[11,10],linkageCount:3}}},dimerized2:{data:{templateSeq:"($3)Succ-{R-F-C(1)-T-G-H-F-P-C(1)-NH2}($3){A(CHOL)-F-C(1)-Y-H-G-D-N-C(1)-meI}",templateHelm:"PEPTIDE1{[($3)Succ]}|PEPTIDE2{R.F.[C(1)].T.G.H.F.P.[C(1)].[NH2]}|PEPTIDE3{[($3)A(CHOL)].F.[C(1)].Y.H.G.D.N.[C(1)].[meI]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1$$$V2.0",mmHelm:"PEPTIDE1{[Succ].R.F.C.T.G.H.F.P.C.[NH2]}|PEPTIDE2{[A(CHOL)].F.C.Y.H.G.D.N.C.[meI]}$PEPTIDE1,PEPTIDE2,1:R1-1:R1|PEPTIDE1,PEPTIDE1,4:R3-10:R3|PEPTIDE2,PEPTIDE2,3:R3-9:R3$$$V2.0"},tgt:{templateChain:{monomerCount:[1,10,10],linkageCount:1},mmChain:{monomerCount:[11,10],linkageCount:3}}}};for(const[r,{data:o,tgt:i}]of Object.entries(n))(0,e.t6)(`fromNotation-${r}`,(async()=>{const n=await(0,I.Q4)(["rules_example.json"]),r=T.sW.fromNotation(o.templateSeq,n,t);r.check(!0),(0,e.J6)(r.monomers.map((t=>t.length)),i.mmChain.monomerCount),(0,e.E3)(r.linkages.length,i.mmChain.linkageCount),(0,e.E3)(r.getHelm(),o.mmHelm)}),"reaction2"==r?{skipReason:"reverse reaction"}:void 0);for(const[r,{data:o,tgt:i}]of Object.entries(n))(0,e.t6)(`parseNotation-${r}`,(async()=>{await(0,I.Q4)(["rules_example.json"]);const n=T.sW.parseNotation(o.templateSeq,t);n.check(!0),(0,e.J6)(n.monomers.map((t=>t.length)),i.templateChain.monomerCount),(0,e.E3)(n.linkages.length,i.templateChain.linkageCount),(0,e.E3)(n.getHelm(),o.templateHelm),(0,e.E3)(n.getNotation(),o.templateSeq)}));for(const[r,{data:o,tgt:i}]of Object.entries(n))(0,e.t6)(`parseHelm-${r}`,(async()=>{await(0,I.Q4)(["rules_example.json"]);const n=T.sW.parseHelm(o.templateHelm,t);n.check(!0),(0,e.J6)(n.monomers.map((t=>t.length)),i.templateChain.monomerCount),(0,e.E3)(n.linkages.length,i.templateChain.linkageCount),(0,e.E3)(n.getHelm(),o.templateHelm),(0,e.E3)(n.getNotation(),o.templateSeq)}));for(const[r,{data:o,tgt:i}]of Object.entries(n))(0,e.t6)(`applyRules-${r}`,(async()=>{const n=await(0,I.Q4)(["rules_example.json"]),r=T.sW.parseNotation(o.templateSeq,t).applyRules(n);r.check(!0),(0,e.J6)(r.monomers.map((t=>t.length)),i.mmChain.monomerCount),(0,e.E3)(r.linkages.length,i.mmChain.linkageCount),(0,e.E3)(r.getHelm(),o.mmHelm)}),{skipReason:"applyRules is not implemented"})})),(0,e.L1)("toAtomicLevel",(()=>{let n,r,o;(0,e.gM)((async()=>{r=await(0,b.pj)(),n=await A(),o=await(0,_.j)(),await r.loadMonomerLibForTests()})),(0,e.Pl)((async()=>{await E(n),await r.loadMonomerLib(!0)})),(0,e.t6)("override",(async()=>{const n=r.getMonomerLib(),i=await O.files.readAsText("tests/polytool-reaction-lib.json"),s=JSON.parse(i).find((t=>"GGaz"===t.symbol));(0,e.E3)(null!=s,!0,"Monomer 'GGaz' not found.");const a={PEPTIDE:{GGaz:s}},u=n.override(a,"test"),c=await(0,d.Q)(),l=t.Column.fromList(t.COLUMN_TYPE.STRING,"helm",["PEPTIDE1{F.P.Y.[GGaz].H.A.A.G.G.A.C}|PEPTIDE2{A.A.A}$PEPTIDE1,PEPTIDE2,4:R4-1:R1|PEPTIDE1,PEPTIDE1,11:R2-4:R3$$$V2.0"]);l.semType=t.SEMTYPE.MACROMOLECULE,l.meta.units=g.Hi.HELM;const f=await c.helmToAtomicLevel(l,!1,!1,u);(0,e.E3)(null!=f.molCol,!0,"Result molCol is null");const h=f.molCol.get(0);(0,e.E3)(!!h,!0,"Molfile is empty");const p=o.get_mol(h);try{const t=p.get_inchi(),n=o.get_inchikey_for_inchi(t);(0,e.E3)(p.get_num_bonds(),103),(0,e.E3)(p.get_num_atoms(),98),(0,e.E3)(n,"XPQUTLNSNIMERR-WKBTUBAPSA-N")}finally{p.delete()}})),(0,e.t6)("getNewMonomer",(async()=>{const t=await(0,_.j)(),n=r.getMonomerLib(),o=(await(0,I.Q4)(["rules_example.json"])).reactionRules.find((t=>"GGaz"==t.name)),[i,s]=(0,T.kl)(t,n,o);(0,e.E3)(i,o.name);const a=t.get_mol(s.molfile);try{const n=a.get_inchi();t.get_inchikey_for_inchi(n),(0,e.E3)(a.get_num_bonds(),18),(0,e.E3)(a.get_num_atoms(),18)}finally{a.delete()}}))}));const O=new s;async function N(n,r,o){const i=await(0,e.N$)({category:n,test:r,testContext:o,verbose:!0});return t.DataFrame.fromObjects(i)}async function L(){await(0,e.Xb)(O,O.getModule("package-test.js"))}})(),sequencetranslator_test=r})();
|
|
3
3
|
//# sourceMappingURL=package-test.js.map
|