From 3e9c84d643a7e2654ef9489f04b0895713ac0000 Mon Sep 17 00:00:00 2001 From: MusketPosition Date: Tue, 28 Feb 2023 17:40:20 +0700 Subject: [PATCH 1/2] get fee share with pair manager --- contracts/implement/AutoMarketMakerCore.sol | 2 +- contracts/interfaces/IGetFeeShareAMM.sol | 8 ++++++++ docs/main.js | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/contracts/implement/AutoMarketMakerCore.sol b/contracts/implement/AutoMarketMakerCore.sol index 599bf26..a3cc1aa 100644 --- a/contracts/implement/AutoMarketMakerCore.sol +++ b/contracts/implement/AutoMarketMakerCore.sol @@ -282,7 +282,7 @@ abstract contract AutoMarketMakerCore is AMMCoreStorage { /// @inheritdoc IAutoMarketMakerCore function feeShareAmm() public view virtual override returns (uint32) { - return spotFactory.feeShareAmm(); + return spotFactory.feeShareAmmWithPair(address(this)); } struct OnCrossPipParams { diff --git a/contracts/interfaces/IGetFeeShareAMM.sol b/contracts/interfaces/IGetFeeShareAMM.sol index 73f1475..9f206db 100644 --- a/contracts/interfaces/IGetFeeShareAMM.sol +++ b/contracts/interfaces/IGetFeeShareAMM.sol @@ -5,4 +5,12 @@ interface IGetFeeShareAMM { /// @notice fee share for liquidity provider /// @return the rate share function feeShareAmm() external view returns (uint32); + + + /// @notice fee share for liquidity provider + /// @param pairManager the address of pair want to know the pai + /// @return the rate share + function feeShareAmmWithPair( + address pairManager + ) external view returns (uint32); } diff --git a/docs/main.js b/docs/main.js index 6740a72..166a731 100644 --- a/docs/main.js +++ b/docs/main.js @@ -1,2 +1,2 @@ /*! For license information please see main.js.LICENSE.txt */ -(()=>{var e={424:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var i=n(81),a=n.n(i),r=n(645),o=n.n(r)()(a());o.push([e.id,"@import url(https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;500;600;700&display=swap);"]),o.push([e.id,"\nhtml,\nbody {\n font-family: 'Source Code Pro', monospace;\n}\n",""]);const u=o},645:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",i=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),i&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),i&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,i,a,r){"string"==typeof e&&(e=[[null,e,void 0]]);var o={};if(i)for(var u=0;u0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=r),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),a&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=a):l[4]="".concat(a)),t.push(l))}},t}},81:e=>{"use strict";e.exports=function(e){return e[1]}},838:(e,t,n)=>{var i=n(424);i.__esModule&&(i=i.default),"string"==typeof i&&(i=[[e.id,i,""]]),i.locals&&(e.exports=i.locals),(0,n(346).Z)("20211576",i,!1,{})},346:(e,t,n)=>{"use strict";function i(e,t){for(var n=[],i={},a=0;am});var a="undefined"!=typeof document;if("undefined"!=typeof DEBUG&&DEBUG&&!a)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var r={},o=a&&(document.head||document.getElementsByTagName("head")[0]),u=null,s=0,p=!1,l=function(){},d=null,c="data-vue-ssr-id",y="undefined"!=typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function m(e,t,n,a){p=n,d=a||{};var o=i(e,t);return f(o),function(t){for(var n=[],a=0;an.parts.length&&(i.parts.length=n.parts.length)}else{var o=[];for(a=0;a{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{"use strict";var e=Object.freeze({}),t=Array.isArray;function i(e){return null==e}function a(e){return null!=e}function r(e){return!0===e}function o(e){return"string"==typeof e||"number"==typeof e||"symbol"==typeof e||"boolean"==typeof e}function u(e){return"function"==typeof e}function s(e){return null!==e&&"object"==typeof e}var p=Object.prototype.toString;function l(e){return"[object Object]"===p.call(e)}function d(e){var t=parseFloat(String(e));return t>=0&&Math.floor(t)===t&&isFinite(e)}function c(e){return a(e)&&"function"==typeof e.then&&"function"==typeof e.catch}function y(e){return null==e?"":Array.isArray(e)||l(e)&&e.toString===p?JSON.stringify(e,null,2):String(e)}function m(e){var t=parseFloat(e);return isNaN(t)?e:t}function f(e,t){for(var n=Object.create(null),i=e.split(","),a=0;a-1)return e.splice(i,1)}}var b=Object.prototype.hasOwnProperty;function T(e,t){return b.call(e,t)}function w(e){var t=Object.create(null);return function(n){return t[n]||(t[n]=e(n))}}var x=/-(\w)/g,_=w((function(e){return e.replace(x,(function(e,t){return t?t.toUpperCase():""}))})),M=w((function(e){return e.charAt(0).toUpperCase()+e.slice(1)})),q=/\B([A-Z])/g,k=w((function(e){return e.replace(q,"-$1").toLowerCase()})),A=Function.prototype.bind?function(e,t){return e.bind(t)}:function(e,t){function n(n){var i=arguments.length;return i?i>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n};function C(e,t){t=t||0;for(var n=e.length-t,i=new Array(n);n--;)i[n]=e[n+t];return i}function O(e,t){for(var n in t)e[n]=t[n];return e}function I(e){for(var t={},n=0;n0,Y=V&&V.indexOf("edge/")>0;V&&V.indexOf("android");var X=V&&/iphone|ipad|ipod|ios/.test(V);V&&/chrome\/\d+/.test(V),V&&/phantomjs/.test(V);var Z,ee=V&&V.match(/firefox\/(\d+)/),te={}.watch,ne=!1;if(H)try{var ie={};Object.defineProperty(ie,"passive",{get:function(){ne=!0}}),window.addEventListener("test-passive",null,ie)}catch(e){}var ae=function(){return void 0===Z&&(Z=!H&&void 0!==n.g&&n.g.process&&"server"===n.g.process.env.VUE_ENV),Z},re=H&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function oe(e){return"function"==typeof e&&/native code/.test(e.toString())}var ue,se="undefined"!=typeof Symbol&&oe(Symbol)&&"undefined"!=typeof Reflect&&oe(Reflect.ownKeys);ue="undefined"!=typeof Set&&oe(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var pe=null;function le(e){void 0===e&&(e=null),e||pe&&pe._scope.off(),pe=e,e&&e._scope.on()}var de=function(){function e(e,t,n,i,a,r,o,u){this.tag=e,this.data=t,this.children=n,this.text=i,this.elm=a,this.ns=void 0,this.context=r,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=t&&t.key,this.componentOptions=o,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=u,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1}return Object.defineProperty(e.prototype,"child",{get:function(){return this.componentInstance},enumerable:!1,configurable:!0}),e}(),ce=function(e){void 0===e&&(e="");var t=new de;return t.text=e,t.isComment=!0,t};function ye(e){return new de(void 0,void 0,void 0,String(e))}function me(e){var t=new de(e.tag,e.data,e.children&&e.children.slice(),e.text,e.elm,e.context,e.componentOptions,e.asyncFactory);return t.ns=e.ns,t.isStatic=e.isStatic,t.key=e.key,t.isComment=e.isComment,t.fnContext=e.fnContext,t.fnOptions=e.fnOptions,t.fnScopeId=e.fnScopeId,t.asyncMeta=e.asyncMeta,t.isCloned=!0,t}var fe=0,he=[],ve=function(){function e(){this._pending=!1,this.id=fe++,this.subs=[]}return e.prototype.addSub=function(e){this.subs.push(e)},e.prototype.removeSub=function(e){this.subs[this.subs.indexOf(e)]=null,this._pending||(this._pending=!0,he.push(this))},e.prototype.depend=function(t){e.target&&e.target.addDep(this)},e.prototype.notify=function(e){for(var t=this.subs.filter((function(e){return e})),n=0,i=t.length;n0&&(We((s=Ge(s,"".concat(n||"","_").concat(u)))[0])&&We(l)&&(d[p]=ye(l.text+s[0].text),s.shift()),d.push.apply(d,s)):o(s)?We(l)?d[p]=ye(l.text+s):""!==s&&d.push(ye(s)):We(s)&&We(l)?d[p]=ye(l.text+s.text):(r(e._isVList)&&a(s.tag)&&i(s.key)&&a(n)&&(s.key="__vlist".concat(n,"_").concat(u,"__")),d.push(s)));return d}function Qe(e,n,i,p,l,d){return(t(i)||o(i))&&(l=p,p=i,i=void 0),r(d)&&(l=2),function(e,n,i,r,o){if(a(i)&&a(i.__ob__))return ce();if(a(i)&&a(i.is)&&(n=i.is),!n)return ce();var p,l;if(t(r)&&u(r[0])&&((i=i||{}).scopedSlots={default:r[0]},r.length=0),2===o?r=Ue(r):1===o&&(r=function(e){for(var n=0;n0,u=n?!!n.$stable:!o,s=n&&n.$key;if(n){if(n._normalized)return n._normalized;if(u&&a&&a!==e&&s===a.$key&&!o&&!a.$hasNormal)return a;for(var p in r={},n)n[p]&&"$"!==p[0]&&(r[p]=yt(t,i,p,n[p]))}else r={};for(var l in i)l in r||(r[l]=mt(i,l));return n&&Object.isExtensible(n)&&(n._normalized=r),W(r,"$stable",u),W(r,"$key",s),W(r,"$hasNormal",o),r}function yt(e,n,i,a){var r=function(){var n=pe;le(e);var i=arguments.length?a.apply(null,arguments):a({}),r=(i=i&&"object"==typeof i&&!t(i)?[i]:Ue(i))&&i[0];return le(n),i&&(!r||1===i.length&&r.isComment&&!dt(r))?void 0:i};return a.proxy&&Object.defineProperty(n,i,{get:r,enumerable:!0,configurable:!0}),r}function mt(e,t){return function(){return e[t]}}function ft(e,t,n,i,a){var r=!1;for(var o in t)o in e?t[o]!==n[o]&&(r=!0):(r=!0,ht(e,o,i,a));for(var o in e)o in t||(r=!0,delete e[o]);return r}function ht(e,t,n,i){Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get:function(){return n[i][t]}})}function vt(e,t){for(var n in t)e[n]=t[n];for(var n in e)n in t||delete e[n]}var gt,bt=null;function Tt(e,t){return(e.__esModule||se&&"Module"===e[Symbol.toStringTag])&&(e=e.default),s(e)?t.extend(e):e}function wt(e){if(t(e))for(var n=0;ndocument.createEvent("Event").timeStamp&&(jt=function(){return Nt.now()})}var Dt=function(e,t){if(e.post){if(!t.post)return 1}else if(t.post)return-1;return e.id-t.id};function zt(){var e,t;for(Bt=jt(),Et=!0,St.sort(Dt),$t=0;$t$t&&St[n].id>e.id;)n--;St.splice(n+1,0,e)}else St.push(e);Lt||(Lt=!0,on(zt))}}(this)},e.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||s(e)||this.deep){var t=this.value;if(this.value=e,this.user){var n='callback for watcher "'.concat(this.expression,'"');Ht(this.cb,this.vm,[e,t],this.vm,n)}else this.cb.call(this.vm,e,t)}}},e.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},e.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},e.prototype.teardown=function(){if(this.vm&&!this.vm._isBeingDestroyed&&g(this.vm._scope.effects,this),this.active){for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1,this.onStop&&this.onStop()}},e}(),yn={enumerable:!0,configurable:!0,get:F,set:F};function mn(e,t,n){yn.get=function(){return this[t][n]},yn.set=function(e){this[t][n]=e},Object.defineProperty(e,n,yn)}function fn(n){var i=n.$options;if(i.props&&function(e,t){var n=e.$options.propsData||{},i=e._props=Re({}),a=e.$options._propKeys=[];e.$parent&&ke(!1);var r=function(r){a.push(r);var o=Dn(r,t,n,e);Ie(i,r,o),r in e||mn(e,"_props",r)};for(var o in t)r(o);ke(!0)}(n,i.props),function(t){var n=t.$options,i=n.setup;if(i){var a=t._setupContext=function(t){return{get attrs(){if(!t._attrsProxy){var n=t._attrsProxy={};W(n,"_v_attr_proxy",!0),ft(n,t.$attrs,e,t,"$attrs")}return t._attrsProxy},get listeners(){return t._listenersProxy||ft(t._listenersProxy={},t.$listeners,e,t,"$listeners"),t._listenersProxy},get slots(){return function(e){return e._slotsProxy||vt(e._slotsProxy={},e.$scopedSlots),e._slotsProxy}(t)},emit:A(t.$emit,t),expose:function(e){e&&Object.keys(e).forEach((function(n){return $e(t,e,n)}))}}}(t);le(t),be();var r=Ht(i,null,[t._props||Re({}),a],t,"setup");if(Te(),le(),u(r))n.render=r;else if(s(r))if(t._setupState=r,r.__sfc){var o=t._setupProxy={};for(var p in r)"__sfc"!==p&&$e(o,r,p)}else for(var p in r)U(p)||$e(t,r,p)}}(n),i.methods&&function(e,t){for(var n in e.$options.props,t)e[n]="function"!=typeof t[n]?F:A(t[n],e)}(n,i.methods),i.data)!function(e){var t=e.$options.data;l(t=e._data=u(t)?function(e,t){be();try{return e.call(t,t)}catch(e){return Qt(e,t,"data()"),{}}finally{Te()}}(t,e):t||{})||(t={});for(var n=Object.keys(t),i=e.$options.props,a=(e.$options.methods,n.length);a--;){var r=n[a];i&&T(i,r)||U(r)||mn(e,"_data",r)}var o=Oe(t);o&&o.vmCount++}(n);else{var a=Oe(n._data={});a&&a.vmCount++}i.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),i=ae();for(var a in t){var r=t[a],o=u(r)?r:r.get;i||(n[a]=new cn(e,o||F,F,hn)),a in e||vn(e,a,r)}}(n,i.computed),i.watch&&i.watch!==te&&function(e,n){for(var i in n){var a=n[i];if(t(a))for(var r=0;r-1)if(r&&!T(a,"default"))o=!1;else if(""===o||o===k(e)){var p=Gn(String,a.type);(p<0||s-1:"string"==typeof e?e.split(",").indexOf(n)>-1:(i=e,!("[object RegExp]"!==p.call(i))&&e.test(n));var i}function Kn(e,t){var n=e.cache,i=e.keys,a=e._vnode;for(var r in n){var o=n[r];if(o){var u=o.name;u&&!t(u)&&Jn(n,r,i,a)}}}function Jn(e,t,n,i){var a=e[t];!a||i&&a.tag===i.tag||a.componentInstance.$destroy(),e[t]=null,g(n,t)}!function(t){t.prototype._init=function(t){var n=this;n._uid=xn++,n._isVue=!0,n.__v_skip=!0,n._scope=new Gt(!0),n._scope._vm=!0,t&&t._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),i=t._parentVnode;n.parent=t.parent,n._parentVnode=i;var a=i.componentOptions;n.propsData=a.propsData,n._parentListeners=a.listeners,n._renderChildren=a.children,n._componentTag=a.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(n,t):n.$options=jn(_n(n.constructor),t||{},n),n._renderProxy=n,n._self=n,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._provided=n?n._provided:Object.create(null),e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(n),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&qt(e,t)}(n),function(t){t._vnode=null,t._staticTrees=null;var n=t.$options,i=t.$vnode=n._parentVnode,a=i&&i.context;t.$slots=pt(n._renderChildren,a),t.$scopedSlots=i?ct(t.$parent,i.data.scopedSlots,t.$slots):e,t._c=function(e,n,i,a){return Qe(t,e,n,i,a,!1)},t.$createElement=function(e,n,i,a){return Qe(t,e,n,i,a,!0)};var r=i&&i.data;Ie(t,"$attrs",r&&r.attrs||e,null,!0),Ie(t,"$listeners",n._parentListeners||e,null,!0)}(n),Ft(n,"beforeCreate",void 0,!1),function(e){var t=wn(e.$options.inject,e);t&&(ke(!1),Object.keys(t).forEach((function(n){Ie(e,n,t[n])})),ke(!0))}(n),fn(n),function(e){var t=e.$options.provide;if(t){var n=u(t)?t.call(e):t;if(!s(n))return;for(var i=function(e){var t=e._provided,n=e.$parent&&e.$parent._provided;return n===t?e._provided=Object.create(n):t}(e),a=se?Reflect.ownKeys(n):Object.keys(n),r=0;r1?C(n):n;for(var i=C(arguments,1),a='event handler for "'.concat(e,'"'),r=0,o=n.length;rparseInt(this.max)&&Jn(t,n[0],n,this._vnode),this.vnodeToCache=null}}},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){for(var e in this.cache)Jn(this.cache,e,this.keys)},mounted:function(){var e=this;this.cacheVNode(),this.$watch("include",(function(t){Kn(e,(function(e){return Vn(t,e)}))})),this.$watch("exclude",(function(t){Kn(e,(function(e){return!Vn(t,e)}))}))},updated:function(){this.cacheVNode()},render:function(){var e=this.$slots.default,t=wt(e),n=t&&t.componentOptions;if(n){var i=Hn(n),a=this.include,r=this.exclude;if(a&&(!i||!Vn(a,i))||r&&i&&Vn(r,i))return t;var o=this.cache,u=this.keys,s=null==t.key?n.Ctor.cid+(n.tag?"::".concat(n.tag):""):t.key;o[s]?(t.componentInstance=o[s].componentInstance,g(u,s),u.push(s)):(this.vnodeToCache=t,this.keyToCache=s),t.data.keepAlive=!0}return t||e&&e[0]}}};!function(e){var t={get:function(){return D}};Object.defineProperty(e,"config",t),e.util={warn:Sn,extend:O,mergeOptions:jn,defineReactive:Ie},e.set=Fe,e.delete=Se,e.nextTick=on,e.observable=function(e){return Oe(e),e},e.options=Object.create(null),j.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,O(e.options.components,Xn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=C(arguments,1);return n.unshift(this),u(e.install)?e.install.apply(e,n):u(e)&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=jn(this.options,e),this}}(e),function(e){e.cid=0;var t=1;e.extend=function(e){e=e||{};var n=this,i=n.cid,a=e._Ctor||(e._Ctor={});if(a[i])return a[i];var r=An(e)||An(n.options),o=function(e){this._init(e)};return(o.prototype=Object.create(n.prototype)).constructor=o,o.cid=t++,o.options=jn(n.options,e),o.super=n,o.options.props&&function(e){var t=e.options.props;for(var n in t)mn(e.prototype,"_props",n)}(o),o.options.computed&&function(e){var t=e.options.computed;for(var n in t)vn(e.prototype,n,t[n])}(o),o.extend=n.extend,o.mixin=n.mixin,o.use=n.use,j.forEach((function(e){o[e]=n[e]})),r&&(o.options.components[r]=o),o.superOptions=n.options,o.extendOptions=e,o.sealedOptions=O({},o.options),a[i]=o,o}}(e),function(e){j.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&l(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&u(n)&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)}(Qn),Object.defineProperty(Qn.prototype,"$isServer",{get:ae}),Object.defineProperty(Qn.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(Qn,"FunctionalRenderContext",{value:Mn}),Qn.version="2.7.14";var Zn=f("style,class"),ei=f("input,textarea,option,select,progress"),ti=function(e,t,n){return"value"===n&&ei(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},ni=f("contenteditable,draggable,spellcheck"),ii=f("events,caret,typing,plaintext-only"),ai=f("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,truespeed,typemustmatch,visible"),ri="http://www.w3.org/1999/xlink",oi=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},ui=function(e){return oi(e)?e.slice(6,e.length):""},si=function(e){return null==e||!1===e};function pi(e,t){return{staticClass:li(e.staticClass,t.staticClass),class:a(e.class)?[e.class,t.class]:t.class}}function li(e,t){return e?t?e+" "+t:e:t||""}function di(e){return Array.isArray(e)?function(e){for(var t,n="",i=0,r=e.length;i-1?$i(e,t,n):ai(t)?si(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n)):ni(t)?e.setAttribute(t,function(e,t){return si(t)||"false"===t?"false":"contenteditable"===e&&ii(t)?t:"true"}(t,n)):oi(t)?si(n)?e.removeAttributeNS(ri,ui(t)):e.setAttributeNS(ri,t,n):$i(e,t,n)}function $i(e,t,n){if(si(n))e.removeAttribute(t);else{if(K&&!J&&"TEXTAREA"===e.tagName&&"placeholder"===t&&""!==n&&!e.__ieph){var i=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",i)};e.addEventListener("input",i),e.__ieph=!0}e.setAttribute(t,n)}}var Bi={create:Li,update:Li};function ji(e,t){var n=t.elm,r=t.data,o=e.data;if(!(i(r.staticClass)&&i(r.class)&&(i(o)||i(o.staticClass)&&i(o.class)))){var u=function(e){for(var t=e.data,n=e,i=e;a(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(t=pi(i.data,t));for(;a(n=n.parent);)n&&n.data&&(t=pi(t,n.data));return r=t.staticClass,o=t.class,a(r)||a(o)?li(r,di(o)):"";var r,o}(t),s=n._transitionClasses;a(s)&&(u=li(u,di(s))),u!==n._prevClass&&(n.setAttribute("class",u),n._prevClass=u)}}var Ni,Di,zi,Ui,Wi,Gi,Qi={create:ji,update:ji},Hi=/[\w).+\-_$\]]/;function Vi(e){var t,n,i,a,r,o=!1,u=!1,s=!1,p=!1,l=0,d=0,c=0,y=0;for(i=0;i=0&&" "===(f=e.charAt(m));m--);f&&Hi.test(f)||(p=!0)}}else void 0===a?(y=i+1,a=e.slice(0,i).trim()):h();function h(){(r||(r=[])).push(e.slice(y,i).trim()),y=i+1}if(void 0===a?a=e.slice(0,i).trim():0!==y&&h(),r)for(i=0;i-1?{exp:e.slice(0,Ui),key:'"'+e.slice(Ui+1)+'"'}:{exp:e,key:null};for(Di=e,Ui=Wi=Gi=0;!da();)ca(zi=la())?ma(zi):91===zi&&ya(zi);return{exp:e.slice(0,Wi),key:e.slice(Wi+1,Gi)}}(e);return null===n.key?"".concat(e,"=").concat(t):"$set(".concat(n.exp,", ").concat(n.key,", ").concat(t,")")}function la(){return Di.charCodeAt(++Ui)}function da(){return Ui>=Ni}function ca(e){return 34===e||39===e}function ya(e){var t=1;for(Wi=Ui;!da();)if(ca(e=la()))ma(e);else if(91===e&&t++,93===e&&t--,0===t){Gi=Ui;break}}function ma(e){for(var t=e;!da()&&(e=la())!==t;);}var fa;function ha(e,t,n){var i=fa;return function a(){var r=t.apply(null,arguments);null!==r&&ba(e,a,n,i)}}var va=Yt&&!(ee&&Number(ee[1])<=53);function ga(e,t,n,i){if(va){var a=Bt,r=t;t=r._wrapper=function(e){if(e.target===e.currentTarget||e.timeStamp>=a||e.timeStamp<=0||e.target.ownerDocument!==document)return r.apply(this,arguments)}}fa.addEventListener(e,t,ne?{capture:n,passive:i}:n)}function ba(e,t,n,i){(i||fa).removeEventListener(e,t._wrapper||t,n)}function Ta(e,t){if(!i(e.data.on)||!i(t.data.on)){var n=t.data.on||{},r=e.data.on||{};fa=t.elm||e.elm,function(e){if(a(e.__r)){var t=K?"change":"input";e[t]=[].concat(e.__r,e[t]||[]),delete e.__r}a(e.__c)&&(e.change=[].concat(e.__c,e.change||[]),delete e.__c)}(n),Ne(n,r,ga,ba,ha,t.context),fa=void 0}}var wa,xa={create:Ta,update:Ta,destroy:function(e){return Ta(e,Mi)}};function _a(e,t){if(!i(e.data.domProps)||!i(t.data.domProps)){var n,o,u=t.elm,s=e.data.domProps||{},p=t.data.domProps||{};for(n in(a(p.__ob__)||r(p._v_attr_proxy))&&(p=t.data.domProps=O({},p)),s)n in p||(u[n]="");for(n in p){if(o=p[n],"textContent"===n||"innerHTML"===n){if(t.children&&(t.children.length=0),o===s[n])continue;1===u.childNodes.length&&u.removeChild(u.childNodes[0])}if("value"===n&&"PROGRESS"!==u.tagName){u._value=o;var l=i(o)?"":String(o);Ma(u,l)&&(u.value=l)}else if("innerHTML"===n&&mi(u.tagName)&&i(u.innerHTML)){(wa=wa||document.createElement("div")).innerHTML="".concat(o,"");for(var d=wa.firstChild;u.firstChild;)u.removeChild(u.firstChild);for(;d.firstChild;)u.appendChild(d.firstChild)}else if(o!==s[n])try{u[n]=o}catch(e){}}}}function Ma(e,t){return!e.composing&&("OPTION"===e.tagName||function(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}(e,t)||function(e,t){var n=e.value,i=e._vModifiers;if(a(i)){if(i.number)return m(n)!==m(t);if(i.trim)return n.trim()!==t.trim()}return n!==t}(e,t))}var qa={create:_a,update:_a},ka=w((function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach((function(e){if(e){var i=e.split(n);i.length>1&&(t[i[0].trim()]=i[1].trim())}})),t}));function Aa(e){var t=Ca(e.style);return e.staticStyle?O(e.staticStyle,t):t}function Ca(e){return Array.isArray(e)?I(e):"string"==typeof e?ka(e):e}var Oa,Ia=/^--/,Fa=/\s*!important$/,Sa=function(e,t,n){if(Ia.test(t))e.style.setProperty(t,n);else if(Fa.test(n))e.style.setProperty(k(t),n.replace(Fa,""),"important");else{var i=Ra(t);if(Array.isArray(n))for(var a=0,r=n.length;a-1?t.split($a).forEach((function(t){return e.classList.add(t)})):e.classList.add(t);else{var n=" ".concat(e.getAttribute("class")||""," ");n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function ja(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split($a).forEach((function(t){return e.classList.remove(t)})):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" ".concat(e.getAttribute("class")||""," "),i=" "+t+" ";n.indexOf(i)>=0;)n=n.replace(i," ");(n=n.trim())?e.setAttribute("class",n):e.removeAttribute("class")}}function Na(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&O(t,Da(e.name||"v")),O(t,e),t}return"string"==typeof e?Da(e):void 0}}var Da=w((function(e){return{enterClass:"".concat(e,"-enter"),enterToClass:"".concat(e,"-enter-to"),enterActiveClass:"".concat(e,"-enter-active"),leaveClass:"".concat(e,"-leave"),leaveToClass:"".concat(e,"-leave-to"),leaveActiveClass:"".concat(e,"-leave-active")}})),za=H&&!J,Ua="transition",Wa="animation",Ga="transition",Qa="transitionend",Ha="animation",Va="animationend";za&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(Ga="WebkitTransition",Qa="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(Ha="WebkitAnimation",Va="webkitAnimationEnd"));var Ka=H?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()};function Ja(e){Ka((function(){Ka(e)}))}function Ya(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),Ba(e,t))}function Xa(e,t){e._transitionClasses&&g(e._transitionClasses,t),ja(e,t)}function Za(e,t,n){var i=tr(e,t),a=i.type,r=i.timeout,o=i.propCount;if(!a)return n();var u=a===Ua?Qa:Va,s=0,p=function(){e.removeEventListener(u,l),n()},l=function(t){t.target===e&&++s>=o&&p()};setTimeout((function(){s0&&(n=Ua,l=o,d=r.length):t===Wa?p>0&&(n=Wa,l=p,d=s.length):d=(n=(l=Math.max(o,p))>0?o>p?Ua:Wa:null)?n===Ua?r.length:s.length:0,{type:n,timeout:l,propCount:d,hasTransform:n===Ua&&er.test(i[Ga+"Property"])}}function nr(e,t){for(;e.length1}function sr(e,t){!0!==t.data.show&&ar(t)}var pr=function(e){var n,u,s={},p=e.modules,l=e.nodeOps;for(n=0;nm?T(e,i(n[v+1])?null:n[v+1].elm,n,y,v,r):y>v&&x(t,d,m)}(d,f,h,n,p):a(h)?(a(e.text)&&l.setTextContent(d,""),T(d,null,h,0,h.length-1,n)):a(f)?x(f,0,f.length-1):a(e.text)&&l.setTextContent(d,""):e.text!==t.text&&l.setTextContent(d,t.text),a(m)&&a(y=m.hook)&&a(y=y.postpatch)&&y(e,t)}}}function k(e,t,n){if(r(n)&&a(e.parent))e.parent.data.pendingInsert=t;else for(var i=0;i-1,o.selected!==r&&(o.selected=r);else if(R(mr(o),i))return void(e.selectedIndex!==u&&(e.selectedIndex=u));a||(e.selectedIndex=-1)}}function yr(e,t){return t.every((function(t){return!R(t,e)}))}function mr(e){return"_value"in e?e._value:e.value}function fr(e){e.target.composing=!0}function hr(e){e.target.composing&&(e.target.composing=!1,vr(e.target,"input"))}function vr(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function gr(e){return!e.componentInstance||e.data&&e.data.transition?e:gr(e.componentInstance._vnode)}var br={model:lr,show:{bind:function(e,t,n){var i=t.value,a=(n=gr(n)).data&&n.data.transition,r=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;i&&a?(n.data.show=!0,ar(n,(function(){e.style.display=r}))):e.style.display=i?r:"none"},update:function(e,t,n){var i=t.value;!i!=!t.oldValue&&((n=gr(n)).data&&n.data.transition?(n.data.show=!0,i?ar(n,(function(){e.style.display=e.__vOriginalDisplay})):rr(n,(function(){e.style.display="none"}))):e.style.display=i?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,i,a){a||(e.style.display=e.__vOriginalDisplay)}}},Tr={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function wr(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?wr(wt(t.children)):e}function xr(e){var t={},n=e.$options;for(var i in n.propsData)t[i]=e[i];var a=n._parentListeners;for(var i in a)t[_(i)]=a[i];return t}function _r(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}var Mr=function(e){return e.tag||dt(e)},qr=function(e){return"show"===e.name},kr={name:"transition",props:Tr,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(Mr)).length){var i=this.mode,a=n[0];if(function(e){for(;e=e.parent;)if(e.data.transition)return!0}(this.$vnode))return a;var r=wr(a);if(!r)return a;if(this._leaving)return _r(e,a);var u="__transition-".concat(this._uid,"-");r.key=null==r.key?r.isComment?u+"comment":u+r.tag:o(r.key)?0===String(r.key).indexOf(u)?r.key:u+r.key:r.key;var s=(r.data||(r.data={})).transition=xr(this),p=this._vnode,l=wr(p);if(r.data.directives&&r.data.directives.some(qr)&&(r.data.show=!0),l&&l.data&&!function(e,t){return t.key===e.key&&t.tag===e.tag}(r,l)&&!dt(l)&&(!l.componentInstance||!l.componentInstance._vnode.isComment)){var d=l.data.transition=O({},s);if("out-in"===i)return this._leaving=!0,De(d,"afterLeave",(function(){t._leaving=!1,t.$forceUpdate()})),_r(e,a);if("in-out"===i){if(dt(r))return p;var c,y=function(){c()};De(s,"afterEnter",y),De(s,"enterCancelled",y),De(d,"delayLeave",(function(e){c=e}))}}return a}}},Ar=O({tag:String,moveClass:String},Tr);delete Ar.mode;var Cr={props:Ar,beforeMount:function(){var e=this,t=this._update;this._update=function(n,i){var a=At(e);e.__patch__(e._vnode,e.kept,!1,!0),e._vnode=e.kept,a(),t.call(e,n,i)}},render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),i=this.prevChildren=this.children,a=this.$slots.default||[],r=this.children=[],o=xr(this),u=0;u-1?vi[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:vi[e]=/HTMLUnknownElement/.test(t.toString())},O(Qn.options.directives,br),O(Qn.options.components,Sr),Qn.prototype.__patch__=H?pr:F,Qn.prototype.$mount=function(e,t){return function(e,t,n){var i;e.$el=t,e.$options.render||(e.$options.render=ce),Ft(e,"beforeMount"),i=function(){e._update(e._render(),n)},new cn(e,i,F,{before:function(){e._isMounted&&!e._isDestroyed&&Ft(e,"beforeUpdate")}},!0),n=!1;var a=e._preWatchers;if(a)for(var r=0;r\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Ur=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Wr="[a-zA-Z_][\\-\\.0-9_a-zA-Z".concat(z.source,"]*"),Gr="((?:".concat(Wr,"\\:)?").concat(Wr,")"),Qr=new RegExp("^<".concat(Gr)),Hr=/^\s*(\/?)>/,Vr=new RegExp("^<\\/".concat(Gr,"[^>]*>")),Kr=/^]+>/i,Jr=/^",""":'"',"&":"&"," ":"\n"," ":"\t","'":"'"},to=/&(?:lt|gt|quot|amp|#39);/g,no=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,io=f("pre,textarea",!0),ao=function(e,t){return e&&io(e)&&"\n"===t[0]};function ro(e,t){var n=t?no:to;return e.replace(n,(function(e){return eo[e]}))}var oo,uo,so,po,lo,co,yo,mo,fo=/^@|^v-on:/,ho=/^v-|^@|^:|^#/,vo=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,go=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,bo=/^\(|\)$/g,To=/^\[.*\]$/,wo=/:(.*)$/,xo=/^:|^\.|^v-bind:/,_o=/\.[^.\]]+(?=[^\]]*$)/g,Mo=/^v-slot(:|$)|^#/,qo=/[\r\n]/,ko=/[ \f\t\r\n]+/g,Ao=w((function(e){return(Pr=Pr||document.createElement("div")).innerHTML=e,Pr.textContent})),Co="_empty_";function Oo(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:Eo(t),rawAttrsMap:{},parent:n,children:[]}}function Io(e,t){oo=t.warn||Ji,co=t.isPreTag||S,yo=t.mustUseProp||S,mo=t.getTagNamespace||S;t.isReservedTag;so=Yi(t.modules,"transformNode"),po=Yi(t.modules,"preTransformNode"),lo=Yi(t.modules,"postTransformNode"),uo=t.delimiters;var n,i,a=[],r=!1!==t.preserveWhitespace,o=t.whitespace,u=!1,s=!1;function p(e){if(l(e),u||e.processed||(e=Fo(e,t)),a.length||e===n||n.if&&(e.elseif||e.else)&&Po(n,{exp:e.elseif,block:e}),i&&!e.forbidden)if(e.elseif||e.else)o=e,p=function(e){for(var t=e.length;t--;){if(1===e[t].type)return e[t];e.pop()}}(i.children),p&&p.if&&Po(p,{exp:o.elseif,block:o});else{if(e.slotScope){var r=e.slotTarget||'"default"';(i.scopedSlots||(i.scopedSlots={}))[r]=e}i.children.push(e),e.parent=i}var o,p;e.children=e.children.filter((function(e){return!e.slotScope})),l(e),e.pre&&(u=!1),co(e.tag)&&(s=!1);for(var d=0;d]*>)","i"));x=e.replace(y,(function(e,n,i){return p=i.length,Xr(c)||"noscript"===c||(n=n.replace(//g,"$1").replace(//g,"$1")),ao(c,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""})),s+=e.length-x.length,e=x,d(c,s-p,s)}else{var m=e.indexOf("<");if(0===m){if(Jr.test(e)){var f=e.indexOf("--\x3e");if(f>=0)return t.shouldKeepComment&&t.comment&&t.comment(e.substring(4,f),s,s+f+3),l(f+3),"continue"}if(Yr.test(e)){var h=e.indexOf("]>");if(h>=0)return l(h+2),"continue"}var v=e.match(Kr);if(v)return l(v[0].length),"continue";var g=e.match(Vr);if(g){var b=s;return l(g[0].length),d(g[1],b,s),"continue"}var T=function(){var t=e.match(Qr);if(t){var n={tagName:t[1],attrs:[],start:s};l(t[0].length);for(var i=void 0,a=void 0;!(i=e.match(Hr))&&(a=e.match(Ur)||e.match(zr));)a.start=s,l(a[0].length),a.end=s,n.attrs.push(a);if(i)return n.unarySlash=i[1],l(i[0].length),n.end=s,n}}();if(T)return function(e){var n=e.tagName,s=e.unarySlash;r&&("p"===i&&Dr(n)&&d(i),u(n)&&i===n&&d(n));for(var p=o(n)||!!s,l=e.attrs.length,c=new Array(l),y=0;y=0){for(x=e.slice(m);!(Vr.test(x)||Qr.test(x)||Jr.test(x)||Yr.test(x)||(_=x.indexOf("<",1))<0);)m+=_,x=e.slice(m);w=e.substring(0,m)}m<0&&(w=e),w&&l(w.length),t.chars&&w&&t.chars(w,s-w.length,s)}if(e===n)return t.chars&&t.chars(e),"break"};e&&"break"!==p(););function l(t){s+=t,e=e.substring(t)}function d(e,n,r){var o,u;if(null==n&&(n=s),null==r&&(r=s),e)for(u=e.toLowerCase(),o=a.length-1;o>=0&&a[o].lowerCasedTag!==u;o--);else o=0;if(o>=0){for(var p=a.length-1;p>=o;p--)t.end&&t.end(a[p].tag,n,r);a.length=o,i=o&&a[o-1].tag}else"br"===u?t.start&&t.start(e,[],!0,n,r):"p"===u&&(t.start&&t.start(e,[],!1,n,r),t.end&&t.end(e,n,r))}d()}(e,{warn:oo,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,outputSourceRange:t.outputSourceRange,start:function(e,r,o,l,d){var c=i&&i.ns||mo(e);K&&"svg"===c&&(r=function(e){for(var t=[],n=0;ns&&(u.push(r=e.slice(s,a)),o.push(JSON.stringify(r)));var p=Vi(i[1].trim());o.push("_s(".concat(p,")")),u.push({"@binding":p}),s=a+i[0].length}return s-1")+("true"===r?":(".concat(t,")"):":_q(".concat(t,",").concat(r,")"))),ia(e,"change","var $$a=".concat(t,",")+"$$el=$event.target,"+"$$c=$$el.checked?(".concat(r,"):(").concat(o,");")+"if(Array.isArray($$a)){"+"var $$v=".concat(i?"_n("+a+")":a,",")+"$$i=_i($$a,$$v);"+"if($$el.checked){$$i<0&&(".concat(pa(t,"$$a.concat([$$v])"),")}")+"else{$$i>-1&&(".concat(pa(t,"$$a.slice(0,$$i).concat($$a.slice($$i+1))"),")}")+"}else{".concat(pa(t,"$$c"),"}"),null,!0)}(e,i,a);else if("input"===r&&"radio"===o)!function(e,t,n){var i=n&&n.number,a=aa(e,"value")||"null";a=i?"_n(".concat(a,")"):a,Xi(e,"checked","_q(".concat(t,",").concat(a,")")),ia(e,"change",pa(t,a),null,!0)}(e,i,a);else if("input"===r||"textarea"===r)!function(e,t,n){var i=e.attrsMap.type,a=n||{},r=a.lazy,o=a.number,u=a.trim,s=!r&&"range"!==i,p=r?"change":"range"===i?"__r":"input",l="$event.target.value";u&&(l="$event.target.value.trim()"),o&&(l="_n(".concat(l,")"));var d=pa(t,l);s&&(d="if($event.target.composing)return;".concat(d)),Xi(e,"value","(".concat(t,")")),ia(e,p,d,null,!0),(u||o)&&ia(e,"blur","$forceUpdate()")}(e,i,a);else if(!D.isReservedTag(r))return sa(e,i,a),!1;return!0},text:function(e,t){t.value&&Xi(e,"textContent","_s(".concat(t.value,")"),t)},html:function(e,t){t.value&&Xi(e,"innerHTML","_s(".concat(t.value,")"),t)}},isPreTag:function(e){return"pre"===e},isUnaryTag:jr,mustUseProp:ti,canBeLeftOpenTag:Nr,isReservedTag:fi,getTagNamespace:hi,staticKeys:function(e){return e.reduce((function(e,t){return e.concat(t.staticKeys||[])}),[]).join(",")}(zo)},Wo=w((function(e){return f("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(e?","+e:""))}));function Go(e,t){e&&(No=Wo(t.staticKeys||""),Do=t.isReservedTag||S,Qo(e),Ho(e,!1))}function Qo(e){if(e.static=function(e){return 2!==e.type&&(3===e.type||!(!e.pre&&(e.hasBindings||e.if||e.for||h(e.tag)||!Do(e.tag)||function(e){for(;e.parent;){if("template"!==(e=e.parent).tag)return!1;if(e.for)return!0}return!1}(e)||!Object.keys(e).every(No))))}(e),1===e.type){if(!Do(e.tag)&&"slot"!==e.tag&&null==e.attrsMap["inline-template"])return;for(var t=0,n=e.children.length;t|^function(?:\s+[\w$]+)?\s*\(/,Ko=/\([^)]*?\);*$/,Jo=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,Yo={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Xo={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},Zo=function(e){return"if(".concat(e,")return null;")},eu={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Zo("$event.target !== $event.currentTarget"),ctrl:Zo("!$event.ctrlKey"),shift:Zo("!$event.shiftKey"),alt:Zo("!$event.altKey"),meta:Zo("!$event.metaKey"),left:Zo("'button' in $event && $event.button !== 0"),middle:Zo("'button' in $event && $event.button !== 1"),right:Zo("'button' in $event && $event.button !== 2")};function tu(e,t){var n=t?"nativeOn:":"on:",i="",a="";for(var r in e){var o=nu(e[r]);e[r]&&e[r].dynamic?a+="".concat(r,",").concat(o,","):i+='"'.concat(r,'":').concat(o,",")}return i="{".concat(i.slice(0,-1),"}"),a?n+"_d(".concat(i,",[").concat(a.slice(0,-1),"])"):n+i}function nu(e){if(!e)return"function(){}";if(Array.isArray(e))return"[".concat(e.map((function(e){return nu(e)})).join(","),"]");var t=Jo.test(e.value),n=Vo.test(e.value),i=Jo.test(e.value.replace(Ko,""));if(e.modifiers){var a="",r="",o=[],u=function(t){if(eu[t])r+=eu[t],Yo[t]&&o.push(t);else if("exact"===t){var n=e.modifiers;r+=Zo(["ctrl","shift","alt","meta"].filter((function(e){return!n[e]})).map((function(e){return"$event.".concat(e,"Key")})).join("||"))}else o.push(t)};for(var s in e.modifiers)u(s);o.length&&(a+=function(e){return"if(!$event.type.indexOf('key')&&"+"".concat(e.map(iu).join("&&"),")return null;")}(o)),r&&(a+=r);var p=t?"return ".concat(e.value,".apply(null, arguments)"):n?"return (".concat(e.value,").apply(null, arguments)"):i?"return ".concat(e.value):e.value;return"function($event){".concat(a).concat(p,"}")}return t||n?e.value:"function($event){".concat(i?"return ".concat(e.value):e.value,"}")}function iu(e){var t=parseInt(e,10);if(t)return"$event.keyCode!==".concat(t);var n=Yo[e],i=Xo[e];return"_k($event.keyCode,"+"".concat(JSON.stringify(e),",")+"".concat(JSON.stringify(n),",")+"$event.key,"+"".concat(JSON.stringify(i))+")"}var au={on:function(e,t){e.wrapListeners=function(e){return"_g(".concat(e,",").concat(t.value,")")}},bind:function(e,t){e.wrapData=function(n){return"_b(".concat(n,",'").concat(e.tag,"',").concat(t.value,",").concat(t.modifiers&&t.modifiers.prop?"true":"false").concat(t.modifiers&&t.modifiers.sync?",true":"",")")}},cloak:F},ru=function(e){this.options=e,this.warn=e.warn||Ji,this.transforms=Yi(e.modules,"transformCode"),this.dataGenFns=Yi(e.modules,"genData"),this.directives=O(O({},au),e.directives);var t=e.isReservedTag||S;this.maybeComponent=function(e){return!!e.component||!t(e.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function ou(e,t){var n=new ru(t),i=e?"script"===e.tag?"null":uu(e,n):'_c("div")';return{render:"with(this){return ".concat(i,"}"),staticRenderFns:n.staticRenderFns}}function uu(e,t){if(e.parent&&(e.pre=e.pre||e.parent.pre),e.staticRoot&&!e.staticProcessed)return su(e,t);if(e.once&&!e.onceProcessed)return pu(e,t);if(e.for&&!e.forProcessed)return cu(e,t);if(e.if&&!e.ifProcessed)return lu(e,t);if("template"!==e.tag||e.slotTarget||t.pre){if("slot"===e.tag)return function(e,t){var n=e.slotName||'"default"',i=hu(e,t),a="_t(".concat(n).concat(i?",function(){return ".concat(i,"}"):""),r=e.attrs||e.dynamicAttrs?bu((e.attrs||[]).concat(e.dynamicAttrs||[]).map((function(e){return{name:_(e.name),value:e.value,dynamic:e.dynamic}}))):null,o=e.attrsMap["v-bind"];return!r&&!o||i||(a+=",null"),r&&(a+=",".concat(r)),o&&(a+="".concat(r?"":",null",",").concat(o)),a+")"}(e,t);var n=void 0;if(e.component)n=function(e,t,n){var i=t.inlineTemplate?null:hu(t,n,!0);return"_c(".concat(e,",").concat(yu(t,n)).concat(i?",".concat(i):"",")")}(e.component,e,t);else{var i=void 0,a=t.maybeComponent(e);(!e.plain||e.pre&&a)&&(i=yu(e,t));var r=void 0,o=t.options.bindings;a&&o&&!1!==o.__isScriptSetup&&(r=function(e,t){var n=_(t),i=M(n),a=function(a){return e[t]===a?t:e[n]===a?n:e[i]===a?i:void 0},r=a("setup-const")||a("setup-reactive-const");if(r)return r;var o=a("setup-let")||a("setup-ref")||a("setup-maybe-ref");return o||void 0}(o,e.tag)),r||(r="'".concat(e.tag,"'"));var u=e.inlineTemplate?null:hu(e,t,!0);n="_c(".concat(r).concat(i?",".concat(i):"").concat(u?",".concat(u):"",")")}for(var s=0;s>>0}(o)):"",")")}(e,e.scopedSlots,t),",")),e.model&&(n+="model:{value:".concat(e.model.value,",callback:").concat(e.model.callback,",expression:").concat(e.model.expression,"},")),e.inlineTemplate){var r=function(e,t){var n=e.children[0];if(n&&1===n.type){var i=ou(n,t.options);return"inlineTemplate:{render:function(){".concat(i.render,"},staticRenderFns:[").concat(i.staticRenderFns.map((function(e){return"function(){".concat(e,"}")})).join(","),"]}")}}(e,t);r&&(n+="".concat(r,","))}return n=n.replace(/,$/,"")+"}",e.dynamicAttrs&&(n="_b(".concat(n,',"').concat(e.tag,'",').concat(bu(e.dynamicAttrs),")")),e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function mu(e){return 1===e.type&&("slot"===e.tag||e.children.some(mu))}function fu(e,t){var n=e.attrsMap["slot-scope"];if(e.if&&!e.ifProcessed&&!n)return lu(e,t,fu,"null");if(e.for&&!e.forProcessed)return cu(e,t,fu);var i=e.slotScope===Co?"":String(e.slotScope),a="function(".concat(i,"){")+"return ".concat("template"===e.tag?e.if&&n?"(".concat(e.if,")?").concat(hu(e,t)||"undefined",":undefined"):hu(e,t)||"undefined":uu(e,t),"}"),r=i?"":",proxy:true";return"{key:".concat(e.slotTarget||'"default"',",fn:").concat(a).concat(r,"}")}function hu(e,t,n,i,a){var r=e.children;if(r.length){var o=r[0];if(1===r.length&&o.for&&"template"!==o.tag&&"slot"!==o.tag){var u=n?t.maybeComponent(o)?",1":",0":"";return"".concat((i||uu)(o,t)).concat(u)}var s=n?function(e,t){for(var n=0,i=0;i':'
',Mu.innerHTML.indexOf(" ")>0}var Cu=!!H&&Au(!1),Ou=!!H&&Au(!0),Iu=w((function(e){var t=bi(e);return t&&t.innerHTML})),Fu=Qn.prototype.$mount;function Su(e,t){for(var n in t)e[n]=t[n];return e}Qn.prototype.$mount=function(e,t){if((e=e&&bi(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var i=n.template;if(i)if("string"==typeof i)"#"===i.charAt(0)&&(i=Iu(i));else{if(!i.nodeType)return this;i=i.innerHTML}else e&&(i=function(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}(e));if(i){var a=ku(i,{outputSourceRange:!1,shouldDecodeNewlines:Cu,shouldDecodeNewlinesForHref:Ou,delimiters:n.delimiters,comments:n.comments},this),r=a.render,o=a.staticRenderFns;n.render=r,n.staticRenderFns=o}}return Fu.call(this,e,t)},Qn.compile=ku;var Pu=/[!'()*]/g,Ru=function(e){return"%"+e.charCodeAt(0).toString(16)},Lu=/%2C/g,Eu=function(e){return encodeURIComponent(e).replace(Pu,Ru).replace(Lu,",")};function $u(e){try{return decodeURIComponent(e)}catch(e){}return e}var Bu=function(e){return null==e||"object"==typeof e?e:String(e)};function ju(e){var t={};return(e=e.trim().replace(/^(\?|#|&)/,""))?(e.split("&").forEach((function(e){var n=e.replace(/\+/g," ").split("="),i=$u(n.shift()),a=n.length>0?$u(n.join("=")):null;void 0===t[i]?t[i]=a:Array.isArray(t[i])?t[i].push(a):t[i]=[t[i],a]})),t):t}function Nu(e){var t=e?Object.keys(e).map((function(t){var n=e[t];if(void 0===n)return"";if(null===n)return Eu(t);if(Array.isArray(n)){var i=[];return n.forEach((function(e){void 0!==e&&(null===e?i.push(Eu(t)):i.push(Eu(t)+"="+Eu(e)))})),i.join("&")}return Eu(t)+"="+Eu(n)})).filter((function(e){return e.length>0})).join("&"):null;return t?"?"+t:""}var Du=/\/?$/;function zu(e,t,n,i){var a=i&&i.options.stringifyQuery,r=t.query||{};try{r=Uu(r)}catch(e){}var o={name:t.name||e&&e.name,meta:e&&e.meta||{},path:t.path||"/",hash:t.hash||"",query:r,params:t.params||{},fullPath:Qu(t,a),matched:e?Gu(e):[]};return n&&(o.redirectedFrom=Qu(n,a)),Object.freeze(o)}function Uu(e){if(Array.isArray(e))return e.map(Uu);if(e&&"object"==typeof e){var t={};for(var n in e)t[n]=Uu(e[n]);return t}return e}var Wu=zu(null,{path:"/"});function Gu(e){for(var t=[];e;)t.unshift(e),e=e.parent;return t}function Qu(e,t){var n=e.path,i=e.query;void 0===i&&(i={});var a=e.hash;return void 0===a&&(a=""),(n||"/")+(t||Nu)(i)+a}function Hu(e,t,n){return t===Wu?e===t:!!t&&(e.path&&t.path?e.path.replace(Du,"")===t.path.replace(Du,"")&&(n||e.hash===t.hash&&Vu(e.query,t.query)):!(!e.name||!t.name)&&e.name===t.name&&(n||e.hash===t.hash&&Vu(e.query,t.query)&&Vu(e.params,t.params)))}function Vu(e,t){if(void 0===e&&(e={}),void 0===t&&(t={}),!e||!t)return e===t;var n=Object.keys(e).sort(),i=Object.keys(t).sort();return n.length===i.length&&n.every((function(n,a){var r=e[n];if(i[a]!==n)return!1;var o=t[n];return null==r||null==o?r===o:"object"==typeof r&&"object"==typeof o?Vu(r,o):String(r)===String(o)}))}function Ku(e){for(var t=0;t=0&&(t=e.slice(i),e=e.slice(0,i));var a=e.indexOf("?");return a>=0&&(n=e.slice(a+1),e=e.slice(0,a)),{path:e,query:n,hash:t}}(a.path||""),p=t&&t.path||"/",l=s.path?Xu(s.path,p,n||a.append):p,d=function(e,t,n){void 0===t&&(t={});var i,a=n||ju;try{i=a(e||"")}catch(e){i={}}for(var r in t){var o=t[r];i[r]=Array.isArray(o)?o.map(Bu):Bu(o)}return i}(s.query,a.query,i&&i.options.parseQuery),c=a.hash||s.hash;return c&&"#"!==c.charAt(0)&&(c="#"+c),{_normalized:!0,path:l,query:d,hash:c}}var gs,bs=function(){},Ts={name:"RouterLink",props:{to:{type:[String,Object],required:!0},tag:{type:String,default:"a"},custom:Boolean,exact:Boolean,exactPath:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,ariaCurrentValue:{type:String,default:"page"},event:{type:[String,Array],default:"click"}},render:function(e){var t=this,n=this.$router,i=this.$route,a=n.resolve(this.to,i,this.append),r=a.location,o=a.route,u=a.href,s={},p=n.options.linkActiveClass,l=n.options.linkExactActiveClass,d=null==p?"router-link-active":p,c=null==l?"router-link-exact-active":l,y=null==this.activeClass?d:this.activeClass,m=null==this.exactActiveClass?c:this.exactActiveClass,f=o.redirectedFrom?zu(null,vs(o.redirectedFrom),null,n):o;s[m]=Hu(i,f,this.exactPath),s[y]=this.exact||this.exactPath?s[m]:function(e,t){return 0===e.path.replace(Du,"/").indexOf(t.path.replace(Du,"/"))&&(!t.hash||e.hash===t.hash)&&function(e,t){for(var n in t)if(!(n in e))return!1;return!0}(e.query,t.query)}(i,f);var h=s[m]?this.ariaCurrentValue:null,v=function(e){ws(e)&&(t.replace?n.replace(r,bs):n.push(r,bs))},g={click:ws};Array.isArray(this.event)?this.event.forEach((function(e){g[e]=v})):g[this.event]=v;var b={class:s},T=!this.$scopedSlots.$hasNormal&&this.$scopedSlots.default&&this.$scopedSlots.default({href:u,route:o,navigate:v,isActive:s[y],isExactActive:s[m]});if(T){if(1===T.length)return T[0];if(T.length>1||!T.length)return 0===T.length?e():e("span",{},T)}if("a"===this.tag)b.on=g,b.attrs={href:u,"aria-current":h};else{var w=xs(this.$slots.default);if(w){w.isStatic=!1;var x=w.data=Su({},w.data);for(var _ in x.on=x.on||{},x.on){var M=x.on[_];_ in g&&(x.on[_]=Array.isArray(M)?M:[M])}for(var q in g)q in x.on?x.on[q].push(g[q]):x.on[q]=v;var k=w.data.attrs=Su({},w.data.attrs);k.href=u,k["aria-current"]=h}else b.on=g}return e(this.tag,b,this.$slots.default)}};function ws(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey||e.defaultPrevented||void 0!==e.button&&0!==e.button)){if(e.currentTarget&&e.currentTarget.getAttribute){var t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function xs(e){if(e)for(var t,n=0;n-1&&(s.params[c]=n.params[c]);return s.path=hs(l.path,s.params),u(l,s,o)}if(s.path){s.params={};for(var y=0;y-1}function Zs(e,t){return Xs(e)&&e._isRouter&&(null==t||e.type===t)}function ep(e,t,n){var i=function(a){a>=e.length?n():e[a]?t(e[a],(function(){i(a+1)})):i(a+1)};i(0)}function tp(e,t){return np(e.map((function(e){return Object.keys(e.components).map((function(n){return t(e.components[n],e.instances[n],e,n)}))})))}function np(e){return Array.prototype.concat.apply([],e)}var ip="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;function ap(e){var t=!1;return function(){for(var n=[],i=arguments.length;i--;)n[i]=arguments[i];if(!t)return t=!0,e.apply(this,n)}}var rp=function(e,t){this.router=e,this.base=function(e){if(!e)if(_s){var t=document.querySelector("base");e=(e=t&&t.getAttribute("href")||"/").replace(/^https?:\/\/[^\/]+/,"")}else e="/";return"/"!==e.charAt(0)&&(e="/"+e),e.replace(/\/$/,"")}(t),this.current=Wu,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[],this.listeners=[]};function op(e,t,n,i){var a=tp(e,(function(e,i,a,r){var o=function(e,t){return"function"!=typeof e&&(e=gs.extend(e)),e.options[t]}(e,t);if(o)return Array.isArray(o)?o.map((function(e){return n(e,i,a,r)})):n(o,i,a,r)}));return np(i?a.reverse():a)}function up(e,t){if(t)return function(){return e.apply(t,arguments)}}rp.prototype.listen=function(e){this.cb=e},rp.prototype.onReady=function(e,t){this.ready?e():(this.readyCbs.push(e),t&&this.readyErrorCbs.push(t))},rp.prototype.onError=function(e){this.errorCbs.push(e)},rp.prototype.transitionTo=function(e,t,n){var i,a=this;try{i=this.router.match(e,this.current)}catch(e){throw this.errorCbs.forEach((function(t){t(e)})),e}var r=this.current;this.confirmTransition(i,(function(){a.updateRoute(i),t&&t(i),a.ensureURL(),a.router.afterHooks.forEach((function(e){e&&e(i,r)})),a.ready||(a.ready=!0,a.readyCbs.forEach((function(e){e(i)})))}),(function(e){n&&n(e),e&&!a.ready&&(Zs(e,Vs.redirected)&&r===Wu||(a.ready=!0,a.readyErrorCbs.forEach((function(t){t(e)}))))}))},rp.prototype.confirmTransition=function(e,t,n){var i=this,a=this.current;this.pending=e;var r,o,u=function(e){!Zs(e)&&Xs(e)&&(i.errorCbs.length?i.errorCbs.forEach((function(t){t(e)})):console.error(e)),n&&n(e)},s=e.matched.length-1,p=a.matched.length-1;if(Hu(e,a)&&s===p&&e.matched[s]===a.matched[p])return this.ensureURL(),e.hash&&Es(this.router,a,e,!1),u(((o=Js(r=a,e,Vs.duplicated,'Avoided redundant navigation to current location: "'+r.fullPath+'".')).name="NavigationDuplicated",o));var l,d=function(e,t){var n,i=Math.max(e.length,t.length);for(n=0;n0)){var t=this.router,n=t.options.scrollBehavior,i=Gs&&n;i&&this.listeners.push(Ls());var a=function(){var n=e.current,a=pp(e.base);e.current===Wu&&a===e._startLocation||e.transitionTo(a,(function(e){i&&Es(t,e,n,!0)}))};window.addEventListener("popstate",a),this.listeners.push((function(){window.removeEventListener("popstate",a)}))}},t.prototype.go=function(e){window.history.go(e)},t.prototype.push=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){Qs(Zu(i.base+e.fullPath)),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){Hs(Zu(i.base+e.fullPath)),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.ensureURL=function(e){if(pp(this.base)!==this.current.fullPath){var t=Zu(this.base+this.current.fullPath);e?Qs(t):Hs(t)}},t.prototype.getCurrentLocation=function(){return pp(this.base)},t}(rp);function pp(e){var t=window.location.pathname,n=t.toLowerCase(),i=e.toLowerCase();return!e||n!==i&&0!==n.indexOf(Zu(i+"/"))||(t=t.slice(e.length)),(t||"/")+window.location.search+window.location.hash}var lp=function(e){function t(t,n,i){e.call(this,t,n),i&&function(e){var t=pp(e);if(!/^\/#/.test(t))return window.location.replace(Zu(e+"/#"+t)),!0}(this.base)||dp()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setupListeners=function(){var e=this;if(!(this.listeners.length>0)){var t=this.router.options.scrollBehavior,n=Gs&&t;n&&this.listeners.push(Ls());var i=function(){var t=e.current;dp()&&e.transitionTo(cp(),(function(i){n&&Es(e.router,i,t,!0),Gs||fp(i.fullPath)}))},a=Gs?"popstate":"hashchange";window.addEventListener(a,i),this.listeners.push((function(){window.removeEventListener(a,i)}))}},t.prototype.push=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){mp(e.fullPath),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){fp(e.fullPath),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.go=function(e){window.history.go(e)},t.prototype.ensureURL=function(e){var t=this.current.fullPath;cp()!==t&&(e?mp(t):fp(t))},t.prototype.getCurrentLocation=function(){return cp()},t}(rp);function dp(){var e=cp();return"/"===e.charAt(0)||(fp("/"+e),!1)}function cp(){var e=window.location.href,t=e.indexOf("#");return t<0?"":e=e.slice(t+1)}function yp(e){var t=window.location.href,n=t.indexOf("#");return(n>=0?t.slice(0,n):t)+"#"+e}function mp(e){Gs?Qs(yp(e)):window.location.hash=e}function fp(e){Gs?Hs(yp(e)):window.location.replace(yp(e))}var hp=function(e){function t(t,n){e.call(this,t,n),this.stack=[],this.index=-1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.push=function(e,t,n){var i=this;this.transitionTo(e,(function(e){i.stack=i.stack.slice(0,i.index+1).concat(e),i.index++,t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this;this.transitionTo(e,(function(e){i.stack=i.stack.slice(0,i.index).concat(e),t&&t(e)}),n)},t.prototype.go=function(e){var t=this,n=this.index+e;if(!(n<0||n>=this.stack.length)){var i=this.stack[n];this.confirmTransition(i,(function(){var e=t.current;t.index=n,t.updateRoute(i),t.router.afterHooks.forEach((function(t){t&&t(i,e)}))}),(function(e){Zs(e,Vs.duplicated)&&(t.index=n)}))}},t.prototype.getCurrentLocation=function(){var e=this.stack[this.stack.length-1];return e?e.fullPath:"/"},t.prototype.ensureURL=function(){},t}(rp),vp=function(e){void 0===e&&(e={}),this.app=null,this.apps=[],this.options=e,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=As(e.routes||[],this);var t=e.mode||"hash";switch(this.fallback="history"===t&&!Gs&&!1!==e.fallback,this.fallback&&(t="hash"),_s||(t="abstract"),this.mode=t,t){case"history":this.history=new sp(this,e.base);break;case"hash":this.history=new lp(this,e.base,this.fallback);break;case"abstract":this.history=new hp(this,e.base)}},gp={currentRoute:{configurable:!0}};vp.prototype.match=function(e,t,n){return this.matcher.match(e,t,n)},gp.currentRoute.get=function(){return this.history&&this.history.current},vp.prototype.init=function(e){var t=this;if(this.apps.push(e),e.$once("hook:destroyed",(function(){var n=t.apps.indexOf(e);n>-1&&t.apps.splice(n,1),t.app===e&&(t.app=t.apps[0]||null),t.app||t.history.teardown()})),!this.app){this.app=e;var n=this.history;if(n instanceof sp||n instanceof lp){var i=function(e){n.setupListeners(),function(e){var i=n.current,a=t.options.scrollBehavior;Gs&&a&&"fullPath"in e&&Es(t,e,i,!1)}(e)};n.transitionTo(n.getCurrentLocation(),i,i)}n.listen((function(e){t.apps.forEach((function(t){t._route=e}))}))}},vp.prototype.beforeEach=function(e){return Tp(this.beforeHooks,e)},vp.prototype.beforeResolve=function(e){return Tp(this.resolveHooks,e)},vp.prototype.afterEach=function(e){return Tp(this.afterHooks,e)},vp.prototype.onReady=function(e,t){this.history.onReady(e,t)},vp.prototype.onError=function(e){this.history.onError(e)},vp.prototype.push=function(e,t,n){var i=this;if(!t&&!n&&"undefined"!=typeof Promise)return new Promise((function(t,n){i.history.push(e,t,n)}));this.history.push(e,t,n)},vp.prototype.replace=function(e,t,n){var i=this;if(!t&&!n&&"undefined"!=typeof Promise)return new Promise((function(t,n){i.history.replace(e,t,n)}));this.history.replace(e,t,n)},vp.prototype.go=function(e){this.history.go(e)},vp.prototype.back=function(){this.go(-1)},vp.prototype.forward=function(){this.go(1)},vp.prototype.getMatchedComponents=function(e){var t=e?e.matched?e:this.resolve(e).route:this.currentRoute;return t?[].concat.apply([],t.matched.map((function(e){return Object.keys(e.components).map((function(t){return e.components[t]}))}))):[]},vp.prototype.resolve=function(e,t,n){var i=vs(e,t=t||this.history.current,n,this),a=this.match(i,t),r=a.redirectedFrom||a.fullPath,o=function(e,t,n){var i="hash"===n?"#"+t:t;return e?Zu(e+"/"+i):i}(this.history.base,r,this.mode);return{location:i,route:a,href:o,normalizedTo:i,resolved:a}},vp.prototype.getRoutes=function(){return this.matcher.getRoutes()},vp.prototype.addRoute=function(e,t){this.matcher.addRoute(e,t),this.history.current!==Wu&&this.history.transitionTo(this.history.getCurrentLocation())},vp.prototype.addRoutes=function(e){this.matcher.addRoutes(e),this.history.current!==Wu&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(vp.prototype,gp);var bp=vp;function Tp(e,t){return e.push(t),function(){var n=e.indexOf(t);n>-1&&e.splice(n,1)}}vp.install=function e(t){if(!e.installed||gs!==t){e.installed=!0,gs=t;var n=function(e){return void 0!==e},i=function(e,t){var i=e.$options._parentVnode;n(i)&&n(i=i.data)&&n(i=i.registerRouteInstance)&&i(e,t)};t.mixin({beforeCreate:function(){n(this.$options.router)?(this._routerRoot=this,this._router=this.$options.router,this._router.init(this),t.util.defineReactive(this,"_route",this._router.history.current)):this._routerRoot=this.$parent&&this.$parent._routerRoot||this,i(this,this)},destroyed:function(){i(this)}}),Object.defineProperty(t.prototype,"$router",{get:function(){return this._routerRoot._router}}),Object.defineProperty(t.prototype,"$route",{get:function(){return this._routerRoot._route}}),t.component("RouterView",Ju),t.component("RouterLink",Ts);var a=t.config.optionMergeStrategies;a.beforeRouteEnter=a.beforeRouteLeave=a.beforeRouteUpdate=a.created}},vp.version="3.6.5",vp.isNavigationFailure=Zs,vp.NavigationFailureType=Vs,vp.START_LOCATION=Wu,_s&&window.Vue&&window.Vue.use(vp);var wp=function(){var e=this._self._c;return e("div",{staticClass:"min-h-screen bg-gray-100 px-4 pt-6"},[e("router-view")],1)};function xp(e,t,n,i,a,r,o,u){var s,p="function"==typeof e?e.options:e;if(t&&(p.render=t,p.staticRenderFns=n,p._compiled=!0),i&&(p.functional=!0),r&&(p._scopeId="data-v-"+r),o?(s=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),a&&a.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(o)},p._ssrRegister=s):a&&(s=u?function(){a.call(this,(p.functional?this.parent:this).$root.$options.shadowRoot)}:a),s)if(p.functional){p._injectStyles=s;var l=p.render;p.render=function(e,t){return s.call(t),l(e,t)}}else{var d=p.beforeCreate;p.beforeCreate=d?[].concat(d,s):[s]}return{exports:e,options:p}}wp._withStripped=!0,n(838);const _p=xp({},wp,[],!1,null,null,null).exports;var Mp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full space-y-10 md:max-w-screen-sm lg:max-w-screen-md mx-auto"},[t("HeaderBar"),e._v(" "),t("div",{staticClass:"pb-32"},[t("div",{staticClass:"space-y-4"},[t("span",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.source)+"\n ")]),e._v(" "),t("h1",{staticClass:"text-xl"},[e._v("\n "+e._s(e.json.name)+"\n ")]),e._v(" "),t("h2",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.title)+"\n ")]),e._v(" "),t("h2",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.author)+"\n ")]),e._v(" "),t("p",[e._v(e._s(e.json.notice))]),e._v(" "),t("p",[e._v(e._s(e.json.details))])]),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.hasOwnProperty("constructor")?t("Member",{attrs:{json:e.json.constructor}}):e._e()],1),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.receive?t("Member",{attrs:{json:e.json.receive}}):e._e()],1),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.fallback?t("Member",{attrs:{json:e.json.fallback}}):e._e()],1),e._v(" "),e.json.events?t("MemberSet",{attrs:{title:"Events",json:e.json.events}}):e._e(),e._v(" "),e.json.stateVariables?t("MemberSet",{attrs:{title:"State Variables",json:e.json.stateVariables}}):e._e(),e._v(" "),e.json.methods?t("MemberSet",{attrs:{title:"Methods",json:e.json.methods}}):e._e()],1),e._v(" "),t("FooterBar")],1)};Mp._withStripped=!0;var qp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"bg-gray-100 fixed bottom-0 right-0 w-full border-t border-dashed border-gray-300"},[t("div",{staticClass:"w-full text-center py-2 md:max-w-screen-sm lg:max-w-screen-md mx-auto"},[t("button",{staticClass:"py-1 px-2 text-gray-500",on:{click:function(t){return e.openLink(e.repository)}}},[e._v("\n built with "+e._s(e.name)+"\n ")])])])};qp._withStripped=!0;const kp=JSON.parse('{"u2":"hardhat-docgen","cj":"https://github.com/ItsNickBarry/hardhat-docgen"}'),Ap=xp({data:function(){return{repository:kp.cj,name:kp.u2}},methods:{openLink(e){window.open(e,"_blank")}}},qp,[],!1,null,null,null).exports;var Cp=function(){var e=this._self._c;return e("div",{staticClass:"w-full border-b border-dashed py-2 border-gray-300"},[e("router-link",{staticClass:"py-2 text-gray-500",attrs:{to:"/"}},[this._v("\n <- Go back\n ")])],1)};Cp._withStripped=!0;const Op=xp({},Cp,[],!1,null,null,null).exports;var Ip=function(){var e=this,t=e._self._c;return t("div",{staticClass:"border-2 border-gray-400 border-dashed w-full p-2"},[t("h3",{staticClass:"text-lg pb-2 mb-2 border-b-2 border-gray-400 border-dashed"},[e._v("\n "+e._s(e.name)+" "+e._s(e.keywords)+" "+e._s(e.inputSignature)+"\n ")]),e._v(" "),t("div",{staticClass:"space-y-3"},[t("p",[e._v(e._s(e.json.notice))]),e._v(" "),t("p",[e._v(e._s(e.json.details))]),e._v(" "),t("MemberSection",{attrs:{name:"Parameters",items:e.inputs}}),e._v(" "),t("MemberSection",{attrs:{name:"Return Values",items:e.outputs}})],1)])};Ip._withStripped=!0;var Fp=function(){var e=this,t=e._self._c;return e.items.length>0?t("ul",[t("h4",{staticClass:"text-lg"},[e._v("\n "+e._s(e.name)+"\n ")]),e._v(" "),e._l(e.items,(function(n,i){return t("li",{key:i},[t("span",{staticClass:"bg-gray-300"},[e._v(e._s(n.type))]),e._v(" "),t("b",[e._v(e._s(n.name||`_${i}`))]),n.desc?t("span",[e._v(": "),t("i",[e._v(e._s(n.desc))])]):e._e()])}))],2):e._e()};Fp._withStripped=!0;const Sp={components:{MemberSection:xp({props:{name:{type:String,default:""},items:{type:Array,default:()=>new Array}}},Fp,[],!1,null,null,null).exports},props:{json:{type:Object,default:()=>new Object}},computed:{name:function(){return this.json.name||this.json.type},keywords:function(){let e=[];return this.json.stateMutability&&e.push(this.json.stateMutability),"true"===this.json.anonymous&&e.push("anonymous"),e.join(" ")},params:function(){return this.json.params||{}},returns:function(){return this.json.returns||{}},inputs:function(){return(this.json.inputs||[]).map((e=>({...e,desc:this.params[e.name]})))},inputSignature:function(){return`(${this.inputs.map((e=>e.type)).join(",")})`},outputs:function(){return(this.json.outputs||[]).map(((e,t)=>({...e,desc:this.returns[e.name||`_${t}`]})))},outputSignature:function(){return`(${this.outputs.map((e=>e.type)).join(",")})`}}},Pp=xp(Sp,Ip,[],!1,null,null,null).exports;var Rp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full mt-8"},[t("h2",{staticClass:"text-lg"},[e._v(e._s(e.title))]),e._v(" "),e._l(Object.keys(e.json),(function(n){return t("Member",{key:n,staticClass:"mt-3",attrs:{json:e.json[n]}})}))],2)};Rp._withStripped=!0;var Lp=xp({components:{Member:Pp},props:{title:{type:String,default:""},json:{type:Object,default:()=>new Object}}},Rp,[],!1,null,null,null);const Ep=xp({components:{Member:Pp,MemberSet:Lp.exports,HeaderBar:Op,FooterBar:Ap},props:{json:{type:Object,default:()=>new Object}}},Mp,[],!1,null,null,null).exports;var $p=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full space-y-10 md:max-w-screen-sm lg:max-w-screen-md mx-auto pb-32"},[t("Branch",{attrs:{json:e.trees,name:"Sources:"}}),e._v(" "),t("FooterBar",{staticClass:"mt-20"})],1)};$p._withStripped=!0;var Bp=function(){var e=this,t=e._self._c;return t("div",[e._v("\n "+e._s(e.name)+"\n "),Array.isArray(e.json)?t("div",{staticClass:"pl-5"},e._l(e.json,(function(n,i){return t("div",{key:i},[t("router-link",{attrs:{to:`${n.source}:${n.name}`}},[e._v("\n "+e._s(n.name)+"\n ")])],1)})),0):t("div",{staticClass:"pl-5"},e._l(Object.keys(e.json),(function(n){return t("div",{key:n},[t("Branch",{attrs:{json:e.json[n],name:n}})],1)})),0)])};Bp._withStripped=!0;var jp=xp({name:"Branch",props:{name:{type:String,default:null},json:{type:[Object,Array],default:()=>new Object}}},Bp,[],!1,null,null,null);const Np=xp({components:{Branch:jp.exports,FooterBar:Ap},props:{json:{type:Object,default:()=>new Object}},computed:{trees:function(){let e={};for(let t in this.json)t.replace("/","//").split(/\/(?=[^\/])/).reduce(function(e,n){if(!n.includes(":"))return e[n]=e[n]||{},e[n];{let[i]=n.split(":");e[i]=e[i]||[],e[i].push(this.json[t])}}.bind(this),e);return e}}},$p,[],!1,null,null,null).exports;Qn.use(bp);const Dp={"contracts/MatchingEngineAMM.sol:MatchingEngineAMM":{source:"contracts/MatchingEngineAMM.sol",name:"MatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the pip want to calculate",quantity:"the size of base amount"},notice:"implement calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"counterParties(address)":{inputs:[{internalType:"address",name:"",type:"address"}],name:"counterParties",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"The current pip of pair"},notice:"get current pip"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"initialize the sub contract, approve contract",notice:"initialize the contract right after deployonly call once time"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"rangeFindingWordsAmm()":{inputs:[],name:"rangeFindingWordsAmm",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/implement/AutoMarketMakerCore.sol:AutoMarketMakerCore":{source:"contracts/implement/AutoMarketMakerCore.sol",name:"AutoMarketMakerCore",methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function to get current pip"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"}}},"contracts/implement/Block.sol:Block":{source:"contracts/implement/Block.sol",name:"Block"},"contracts/implement/MatchingEngineCore.sol:MatchingEngineCore":{source:"contracts/implement/MatchingEngineCore.sol",name:"MatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"hook function calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get currnet pip"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/interfaces/IAutoMarketMakerCore.sol:IAutoMarketMakerCore":{source:"contracts/interfaces/IAutoMarketMakerCore.sol",name:"IAutoMarketMakerCore",methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load current current index pip range from storage",returns:{_0:"the current index pip range"},notice:"get current index pip range"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"index",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",details:"load data from storage and return",params:{index:"want to get info"},returns:{baseReal:"base real of liquidity of index",feeGrowthBase:"the growth of base",feeGrowthQuote:"the growth of base",indexedPipRange:"index of liquidity info",quoteReal:"quote real of liquidity of index",sqrtK:"sqrt of k=quoteReal*baseReal,",sqrtMaxPip:"sqrt of max pip",sqrtMinPip:"sqrt of min pip"},notice:"get liquidity info of any index pip range"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",details:"load current index pip range from storage",returns:{_0:"The current pip range"},notice:"get current index pip range"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load current tick space from storage",returns:{_0:"the config tick space"},notice:"get the tick space for external generate orderbook"}}},"contracts/interfaces/IFee.sol:IFee":{source:"contracts/interfaces/IFee.sol",name:"IFee",methods:{"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"baseFeeFunding",type:"uint256"},{internalType:"uint256",name:"quoteFeeFunding",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{baseFeeFunding:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"}}},"contracts/interfaces/IGetFeeShareAMM.sol:IGetFeeShareAMM":{source:"contracts/interfaces/IGetFeeShareAMM.sol",name:"IGetFeeShareAMM",methods:{"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",returns:{_0:"the rate share"},notice:"fee share for liquidity provider"}}},"contracts/interfaces/IMatchingEngineAMM.sol:IMatchingEngineAMM":{source:"contracts/interfaces/IMatchingEngineAMM.sol",name:"IMatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load current current index pip range from storage",returns:{_0:"the current index pip range"},notice:"get current index pip range"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"baseFeeFunding",type:"uint256"},{internalType:"uint256",name:"quoteFeeFunding",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{baseFeeFunding:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"save storage the init data",params:{params:"the init params with struct InitParams"},notice:"init the pair right after cloned"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"index",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",details:"load data from storage and return",params:{index:"want to get info"},returns:{baseReal:"base real of liquidity of index",feeGrowthBase:"the growth of base",feeGrowthQuote:"the growth of base",indexedPipRange:"index of liquidity info",quoteReal:"quote real of liquidity of index",sqrtK:"sqrt of k=quoteReal*baseReal,",sqrtMaxPip:"sqrt of max pip",sqrtMinPip:"sqrt of min pip"},notice:"get liquidity info of any index pip range"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",details:"load current index pip range from storage",returns:{_0:"The current pip range"},notice:"get current index pip range"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load current tick space from storage",returns:{_0:"the config tick space"},notice:"get the tick space for external generate orderbook"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/interfaces/IMatchingEngineCore.sol:IMatchingEngineCore":{source:"contracts/interfaces/IMatchingEngineCore.sol",name:"IMatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",params:{isBuy:"fill start pip",orderId:"id of order cancel",pip:"of order",size:"size of order"},notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",params:{isBuy:"fill start pip",orderId:"side of order",pip:"amount filled",size:"fill to pip"},notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",params:{orderId:"id of order",pairManager:"address of pair",pip:"at order",size:"of order"},notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",params:{amount:"amount filled",filledIndex:"number of index filled",isBuy:"side of order",remainingLiquidity:"remaining liquidity in pip",startPip:"fill start pip",toPip:"fill to pip"},notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",params:{newMaxWordRangeForLimitOrder:"new value"},notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",params:{newMaxWordRangeForMarketOrder:"new value"},notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",params:{pip:"pip snap shot",timestamp:"time snap shot"},notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",params:{amount0In:"amount 0 int",amount0Out:"amount 0 out",amount1In:"amount 1 in",amount1Out:"amount 1 out",sender:"address of trader",to:"swap for address"},notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",params:{newMaxFindingWordsIndex:"new value",pairManager:"address of pair"},notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/libraries/amm/CrossPipResult.sol:CrossPipResult":{source:"contracts/libraries/amm/CrossPipResult.sol",name:"CrossPipResult"},"contracts/libraries/amm/Liquidity.sol:Liquidity":{source:"contracts/libraries/amm/Liquidity.sol",name:"Liquidity"},"contracts/libraries/amm/LiquidityMath.sol:LiquidityMath":{source:"contracts/libraries/amm/LiquidityMath.sol",name:"LiquidityMath",title:"All formulas used in the AMM"},"contracts/libraries/exchange/BitMath.sol:BitMath":{source:"contracts/libraries/exchange/BitMath.sol",name:"BitMath",title:"BitMath",details:"This libraries provides functionality for computing bit properties of an unsigned integer"},"contracts/libraries/exchange/LimitOrder.sol:LimitOrder":{source:"contracts/libraries/exchange/LimitOrder.sol",name:"LimitOrder"},"contracts/libraries/exchange/LiquidityBitmap.sol:LiquidityBitmap":{source:"contracts/libraries/exchange/LiquidityBitmap.sol",name:"LiquidityBitmap",methods:{"MAX_UINT256()":{inputs:[],name:"MAX_UINT256",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}}},"contracts/libraries/exchange/SwapState.sol:SwapState":{source:"contracts/libraries/exchange/SwapState.sol",name:"SwapState"},"contracts/libraries/exchange/TickPosition.sol:TickPosition":{source:"contracts/libraries/exchange/TickPosition.sol",name:"TickPosition"},"contracts/libraries/extensions/Fee.sol:Fee":{source:"contracts/libraries/extensions/Fee.sol",name:"Fee",methods:{"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"}}},"contracts/libraries/extensions/ReserveSnapshots.sol:ReserveSnapshots":{source:"contracts/libraries/extensions/ReserveSnapshots.sol",name:"ReserveSnapshots",events:{"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event"}},methods:{"reserveSnapshots(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"reserveSnapshots",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"timestamp",type:"uint64"},{internalType:"uint64",name:"blockNumber",type:"uint64"}],stateMutability:"view",type:"function"}}},"contracts/libraries/helper/Convert.sol:Convert":{source:"contracts/libraries/helper/Convert.sol",name:"Convert"},"contracts/libraries/helper/Errors.sol:Errors":{source:"contracts/libraries/helper/Errors.sol",name:"Errors",notice:"Mapping error code to error message",methods:{"ME_INITIALIZED()":{inputs:[],name:"ME_INITIALIZED",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_INPUT()":{inputs:[],name:"ME_INVALID_INPUT",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_LEVERAGE()":{inputs:[],name:"ME_INVALID_LEVERAGE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_SIZE()":{inputs:[],name:"ME_INVALID_SIZE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_LIMIT_OVER_PRICE_NOT_ENOUGH_LIQUIDITY()":{inputs:[],name:"ME_LIMIT_OVER_PRICE_NOT_ENOUGH_LIQUIDITY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MARKET_ORDER_MUST_CLOSE_TO_INDEX_PRICE()":{inputs:[],name:"ME_MARKET_ORDER_MUST_CLOSE_TO_INDEX_PRICE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MUST_CLOSE_TO_INDEX_PRICE_BUY()":{inputs:[],name:"ME_MUST_CLOSE_TO_INDEX_PRICE_BUY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MUST_CLOSE_TO_INDEX_PRICE_SELL()":{inputs:[],name:"ME_MUST_CLOSE_TO_INDEX_PRICE_SELL",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_NOT_ENOUGH_LIQUIDITY()":{inputs:[],name:"ME_NOT_ENOUGH_LIQUIDITY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_NOT_PASS_MARKET_MARKER()":{inputs:[],name:"ME_NOT_PASS_MARKET_MARKER",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_ONLY_COUNTERPARTY()":{inputs:[],name:"ME_ONLY_COUNTERPARTY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_ONLY_PENDING_ORDER()":{inputs:[],name:"ME_ONLY_PENDING_ORDER",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_SETTLE_FUNDING_TOO_EARLY()":{inputs:[],name:"ME_SETTLE_FUNDING_TOO_EARLY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"}}},"contracts/libraries/helper/FixedPoint128.sol:FixedPoint128":{source:"contracts/libraries/helper/FixedPoint128.sol",name:"FixedPoint128",title:"FixedPoint128",notice:"A library for handling binary fixed point numbers, see https://en.wikipedia.org/wiki/Q_(number_format)"},"contracts/libraries/helper/Math.sol:Math":{source:"contracts/libraries/helper/Math.sol",name:"Math"},"contracts/libraries/helper/Require.sol:Require":{source:"contracts/libraries/helper/Require.sol",name:"Require",notice:"this library is used to reduce size contract when require condition"},"contracts/libraries/helper/TradeConvert.sol:TradeConvert":{source:"contracts/libraries/helper/TradeConvert.sol",name:"TradeConvert"},"contracts/libraries/helper/TransferHelper.sol:TransferHelper":{source:"contracts/libraries/helper/TransferHelper.sol",name:"TransferHelper"},"contracts/libraries/helper/U128Math.sol:U128Math":{source:"contracts/libraries/helper/U128Math.sol",name:"U128Math"},"contracts/libraries/types/AMMCoreStorage.sol:AMMCoreStorage":{source:"contracts/libraries/types/AMMCoreStorage.sol",name:"AMMCoreStorage",stateVariables:{"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"stateVariable",details:"load current current index pip range from storage",return:"the current index pip range",returns:{_0:"the current index pip range"},notice:"the current index pip active"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"stateVariable",details:"load current index pip range from storage",return:"The current pip range",returns:{_0:"The current pip range"},notice:"the range of liquidity"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"stateVariable",return:"the config fee",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"stateVariable",details:"load current tick space from storage",return:"the config tick space",returns:{_0:"the config tick space"},notice:"the tick space of external bulid order book"}},methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"}}},"contracts/libraries/types/MatchingEngineCoreStorage.sol:MatchingEngineCoreStorage":{source:"contracts/libraries/types/MatchingEngineCoreStorage.sol",name:"MatchingEngineCoreStorage",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},stateVariables:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"stateVariable",return:"the basis point of pair",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"}},methods:{"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/LiquidityBitmapTest.sol:LiquidityBitmapTest":{source:"contracts/test/LiquidityBitmapTest.sol",name:"LiquidityBitmapTest",events:{"GasUse(uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"gas",type:"uint256"}],name:"GasUse",type:"event"}},methods:{"findHasLiquidityInMultipleWords(uint128,uint128,bool)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"maxWords",type:"uint128"},{internalType:"bool",name:"lte",type:"bool"}],name:"findHasLiquidityInMultipleWords",outputs:[{internalType:"uint128",name:"next",type:"uint128"}],stateMutability:"view",type:"function"},"findNextInitializedLiquidity(uint128,bool)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"bool",name:"lte",type:"bool"}],name:"findNextInitializedLiquidity",outputs:[{internalType:"uint128",name:"next",type:"uint128"}],stateMutability:"view",type:"function"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"setBitsInRange(uint128,uint128)":{inputs:[{internalType:"uint128",name:"startPip",type:"uint128"},{internalType:"uint128",name:"toPip",type:"uint128"}],name:"setBitsInRange",outputs:[],stateMutability:"nonpayable",type:"function"},"toggleSingleBit(uint128,bool)":{inputs:[{internalType:"uint128",name:"bit",type:"uint128"},{internalType:"bool",name:"isSet",type:"bool"}],name:"toggleSingleBit",outputs:[],stateMutability:"nonpayable",type:"function"},"unsetBitsRange(uint128,uint128)":{inputs:[{internalType:"uint128",name:"startPip",type:"uint128"},{internalType:"uint128",name:"toPip",type:"uint128"}],name:"unsetBitsRange",outputs:[],stateMutability:"nonpayable",type:"function"}}},"contracts/test/LiquidityMathTest.sol:LiquidityMathTest":{source:"contracts/test/LiquidityMathTest.sol",name:"LiquidityMathTest",methods:{"CURVE_PIP()":{inputs:[],name:"CURVE_PIP",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseByLiquidity(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint128",name:"sqrtPriceMax",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"}],name:"calculateBaseByLiquidity",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseReal(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"maxPip",type:"uint128"},{internalType:"uint128",name:"xVirtual",type:"uint128"},{internalType:"uint128",name:"currentPrice",type:"uint128"}],name:"calculateBaseReal",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseWithPriceWhenBuy(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateBaseWithPriceWhenBuy",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseWithPriceWhenSell(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateBaseWithPriceWhenSell",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateLiquidity(uint128,uint128,bool)":{inputs:[{internalType:"uint128",name:"amountReal",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"},{internalType:"bool",name:"isBase",type:"bool"}],name:"calculateLiquidity",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"calculateQuoteByLiquidity(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint128",name:"sqrtPriceMin",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"}],name:"calculateQuoteByLiquidity",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateQuoteReal(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"yVirtual",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteReal",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateQuoteWithPriceWhenBuy(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteWithPriceWhenBuy",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"calculateQuoteWithPriceWhenSell(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteWithPriceWhenSell",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"}}},"contracts/test/MockMatchingEngineAMM.sol:MockMatchingEngineAMM":{source:"contracts/test/MockMatchingEngineAMM.sol",name:"MockMatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the pip want to calculate",quantity:"the size of base amount"},notice:"implement calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"counterParties(address)":{inputs:[{internalType:"address",name:"",type:"address"}],name:"counterParties",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"The current pip of pair"},notice:"get current pip"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"initialize the sub contract, approve contract",notice:"initialize the contract right after deployonly call once time"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"rangeFindingWordsAmm()":{inputs:[],name:"rangeFindingWordsAmm",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"setCounterParty()":{inputs:[],name:"setCounterParty",outputs:[],stateMutability:"nonpayable",type:"function"},"setCurrentPip(uint128)":{inputs:[{internalType:"uint128",name:"currentPip",type:"uint128"}],name:"setCurrentPip",outputs:[],stateMutability:"nonpayable",type:"function"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/MockMatchingEngineCore.sol:MockMatchingEngineCore":{source:"contracts/test/MockMatchingEngineCore.sol",name:"MockMatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"hook function calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get currnet pip"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/MockReflexToken.sol:MockReflexToken":{source:"contracts/test/MockReflexToken.sol",name:"MockReflexToken",constructor:{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"}},methods:{"allowance(address,address)":{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-allowance}."},"approve(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Sets `amount` as the allowance of `spender` over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event."},"balanceOf(address)":{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-balanceOf}."},"decimals()":{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function",details:"Returns the decimals places of the token."},"decreaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"subtractedValue",type:"uint256"}],name:"decreaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},"increaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"addedValue",type:"uint256"}],name:"increaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},"mint(address,uint256)":{inputs:[{internalType:"address",name:"recipient",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},"name()":{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the name of the token."},"symbol()":{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the symbol of the token, usually a shorter version of the name."},"totalSupply()":{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-totalSupply}."},"transfer(address,uint256)":{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Moves `amount` tokens from the caller's account to `to`. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event."},"transferFrom(address,address,uint256)":{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Moves `amount` tokens from `from` to `to` using the allowance mechanism. `amount` is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event."}}},"contracts/test/MockToken.sol:MockToken":{source:"contracts/test/MockToken.sol",name:"MockToken",constructor:{inputs:[{internalType:"string",name:"name",type:"string"},{internalType:"string",name:"symbol",type:"string"}],stateMutability:"nonpayable",type:"constructor"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"}},methods:{"allowance(address,address)":{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-allowance}."},"approve(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-approve}. NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on `transferFrom`. This is semantically equivalent to an infinite approval. Requirements: - `spender` cannot be the zero address."},"balanceOf(address)":{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-balanceOf}."},"decimals()":{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function",details:"Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5.05` (`505 / 10 ** 2`). Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. This is the value {ERC20} uses, unless this function is overridden; NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}."},"decreaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"subtractedValue",type:"uint256"}],name:"decreaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Atomically decreases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`."},"increaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"addedValue",type:"uint256"}],name:"increaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Atomically increases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address."},"mint(address,uint256)":{inputs:[{internalType:"address",name:"recipient",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},"name()":{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the name of the token."},"owner()":{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},"setOwner(address)":{inputs:[{internalType:"address",name:"_owner",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},"symbol()":{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the symbol of the token, usually a shorter version of the name."},"totalSupply()":{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-totalSupply}."},"transfer(address,uint256)":{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-transfer}. Requirements: - `to` cannot be the zero address. - the caller must have a balance of at least `amount`."},"transferFrom(address,address,uint256)":{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-transferFrom}. Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}. NOTE: Does not update the allowance if the current allowance is the maximum `uint256`. Requirements: - `from` and `to` cannot be the zero address. - `from` must have a balance of at least `amount`. - the caller must have allowance for ``from``'s tokens of at least `amount`."}}},"contracts/test/MockWBNB.sol:MockWBNB":{source:"contracts/test/MockWBNB.sol",name:"MockWBNB",fallback:{payable:!0,stateMutability:"payable",type:"fallback"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!0,name:"guy",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!0,name:"dst",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Transfer",type:"event"},"Deposit(address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"dst",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Deposit",type:"event"},"Withdrawal(address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Withdrawal",type:"event"}},methods:{"name()":{constant:!0,inputs:[],name:"name",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},"approve(address,uint256)":{constant:!1,inputs:[{name:"guy",type:"address"},{name:"wad",type:"uint256"}],name:"approve",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"totalSupply()":{constant:!0,inputs:[],name:"totalSupply",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},"transferFrom(address,address,uint256)":{constant:!1,inputs:[{name:"src",type:"address"},{name:"dst",type:"address"},{name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"withdraw(uint256)":{constant:!1,inputs:[{name:"wad",type:"uint256"}],name:"withdraw",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},"decimals()":{constant:!0,inputs:[],name:"decimals",outputs:[{name:"",type:"uint8"}],payable:!1,stateMutability:"view",type:"function"},"balanceOf(address)":{constant:!0,inputs:[{name:"",type:"address"}],name:"balanceOf",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},"symbol()":{constant:!0,inputs:[],name:"symbol",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},"transfer(address,uint256)":{constant:!1,inputs:[{name:"dst",type:"address"},{name:"wad",type:"uint256"}],name:"transfer",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"deposit()":{constant:!1,inputs:[],name:"deposit",outputs:[],payable:!0,stateMutability:"payable",type:"function"},"allowance(address,address)":{constant:!0,inputs:[{name:"",type:"address"},{name:"",type:"address"}],name:"allowance",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"}}},"contracts/test/TickPositionTest.sol:TickPositionTest":{source:"contracts/test/TickPositionTest.sol",name:"TickPositionTest",methods:{"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"}}}};new Qn({el:"#app",router:new bp({routes:[{path:"/",component:Np,props:()=>({json:Dp})},{path:"*",component:Ep,props:e=>({json:Dp[e.path.slice(1)]})}]}),mounted(){document.dispatchEvent(new Event("render-event"))},render:e=>e(_p)})})()})(); \ No newline at end of file +(()=>{var e={424:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var i=n(81),a=n.n(i),r=n(645),o=n.n(r)()(a());o.push([e.id,"@import url(https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;500;600;700&display=swap);"]),o.push([e.id,"\nhtml,\nbody {\n font-family: 'Source Code Pro', monospace;\n}\n",""]);const u=o},645:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",i=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),i&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),i&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,i,a,r){"string"==typeof e&&(e=[[null,e,void 0]]);var o={};if(i)for(var u=0;u0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=r),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),a&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=a):l[4]="".concat(a)),t.push(l))}},t}},81:e=>{"use strict";e.exports=function(e){return e[1]}},838:(e,t,n)=>{var i=n(424);i.__esModule&&(i=i.default),"string"==typeof i&&(i=[[e.id,i,""]]),i.locals&&(e.exports=i.locals),(0,n(346).Z)("20211576",i,!1,{})},346:(e,t,n)=>{"use strict";function i(e,t){for(var n=[],i={},a=0;am});var a="undefined"!=typeof document;if("undefined"!=typeof DEBUG&&DEBUG&&!a)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var r={},o=a&&(document.head||document.getElementsByTagName("head")[0]),u=null,s=0,p=!1,l=function(){},d=null,c="data-vue-ssr-id",y="undefined"!=typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function m(e,t,n,a){p=n,d=a||{};var o=i(e,t);return f(o),function(t){for(var n=[],a=0;an.parts.length&&(i.parts.length=n.parts.length)}else{var o=[];for(a=0;a{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{"use strict";var e=Object.freeze({}),t=Array.isArray;function i(e){return null==e}function a(e){return null!=e}function r(e){return!0===e}function o(e){return"string"==typeof e||"number"==typeof e||"symbol"==typeof e||"boolean"==typeof e}function u(e){return"function"==typeof e}function s(e){return null!==e&&"object"==typeof e}var p=Object.prototype.toString;function l(e){return"[object Object]"===p.call(e)}function d(e){var t=parseFloat(String(e));return t>=0&&Math.floor(t)===t&&isFinite(e)}function c(e){return a(e)&&"function"==typeof e.then&&"function"==typeof e.catch}function y(e){return null==e?"":Array.isArray(e)||l(e)&&e.toString===p?JSON.stringify(e,null,2):String(e)}function m(e){var t=parseFloat(e);return isNaN(t)?e:t}function f(e,t){for(var n=Object.create(null),i=e.split(","),a=0;a-1)return e.splice(i,1)}}var b=Object.prototype.hasOwnProperty;function T(e,t){return b.call(e,t)}function w(e){var t=Object.create(null);return function(n){return t[n]||(t[n]=e(n))}}var x=/-(\w)/g,_=w((function(e){return e.replace(x,(function(e,t){return t?t.toUpperCase():""}))})),M=w((function(e){return e.charAt(0).toUpperCase()+e.slice(1)})),q=/\B([A-Z])/g,k=w((function(e){return e.replace(q,"-$1").toLowerCase()})),A=Function.prototype.bind?function(e,t){return e.bind(t)}:function(e,t){function n(n){var i=arguments.length;return i?i>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n};function C(e,t){t=t||0;for(var n=e.length-t,i=new Array(n);n--;)i[n]=e[n+t];return i}function O(e,t){for(var n in t)e[n]=t[n];return e}function I(e){for(var t={},n=0;n0,Y=V&&V.indexOf("edge/")>0;V&&V.indexOf("android");var X=V&&/iphone|ipad|ipod|ios/.test(V);V&&/chrome\/\d+/.test(V),V&&/phantomjs/.test(V);var Z,ee=V&&V.match(/firefox\/(\d+)/),te={}.watch,ne=!1;if(H)try{var ie={};Object.defineProperty(ie,"passive",{get:function(){ne=!0}}),window.addEventListener("test-passive",null,ie)}catch(e){}var ae=function(){return void 0===Z&&(Z=!H&&void 0!==n.g&&n.g.process&&"server"===n.g.process.env.VUE_ENV),Z},re=H&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function oe(e){return"function"==typeof e&&/native code/.test(e.toString())}var ue,se="undefined"!=typeof Symbol&&oe(Symbol)&&"undefined"!=typeof Reflect&&oe(Reflect.ownKeys);ue="undefined"!=typeof Set&&oe(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var pe=null;function le(e){void 0===e&&(e=null),e||pe&&pe._scope.off(),pe=e,e&&e._scope.on()}var de=function(){function e(e,t,n,i,a,r,o,u){this.tag=e,this.data=t,this.children=n,this.text=i,this.elm=a,this.ns=void 0,this.context=r,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=t&&t.key,this.componentOptions=o,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=u,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1}return Object.defineProperty(e.prototype,"child",{get:function(){return this.componentInstance},enumerable:!1,configurable:!0}),e}(),ce=function(e){void 0===e&&(e="");var t=new de;return t.text=e,t.isComment=!0,t};function ye(e){return new de(void 0,void 0,void 0,String(e))}function me(e){var t=new de(e.tag,e.data,e.children&&e.children.slice(),e.text,e.elm,e.context,e.componentOptions,e.asyncFactory);return t.ns=e.ns,t.isStatic=e.isStatic,t.key=e.key,t.isComment=e.isComment,t.fnContext=e.fnContext,t.fnOptions=e.fnOptions,t.fnScopeId=e.fnScopeId,t.asyncMeta=e.asyncMeta,t.isCloned=!0,t}var fe=0,he=[],ve=function(){function e(){this._pending=!1,this.id=fe++,this.subs=[]}return e.prototype.addSub=function(e){this.subs.push(e)},e.prototype.removeSub=function(e){this.subs[this.subs.indexOf(e)]=null,this._pending||(this._pending=!0,he.push(this))},e.prototype.depend=function(t){e.target&&e.target.addDep(this)},e.prototype.notify=function(e){for(var t=this.subs.filter((function(e){return e})),n=0,i=t.length;n0&&(We((s=Ge(s,"".concat(n||"","_").concat(u)))[0])&&We(l)&&(d[p]=ye(l.text+s[0].text),s.shift()),d.push.apply(d,s)):o(s)?We(l)?d[p]=ye(l.text+s):""!==s&&d.push(ye(s)):We(s)&&We(l)?d[p]=ye(l.text+s.text):(r(e._isVList)&&a(s.tag)&&i(s.key)&&a(n)&&(s.key="__vlist".concat(n,"_").concat(u,"__")),d.push(s)));return d}function Qe(e,n,i,p,l,d){return(t(i)||o(i))&&(l=p,p=i,i=void 0),r(d)&&(l=2),function(e,n,i,r,o){if(a(i)&&a(i.__ob__))return ce();if(a(i)&&a(i.is)&&(n=i.is),!n)return ce();var p,l;if(t(r)&&u(r[0])&&((i=i||{}).scopedSlots={default:r[0]},r.length=0),2===o?r=Ue(r):1===o&&(r=function(e){for(var n=0;n0,u=n?!!n.$stable:!o,s=n&&n.$key;if(n){if(n._normalized)return n._normalized;if(u&&a&&a!==e&&s===a.$key&&!o&&!a.$hasNormal)return a;for(var p in r={},n)n[p]&&"$"!==p[0]&&(r[p]=yt(t,i,p,n[p]))}else r={};for(var l in i)l in r||(r[l]=mt(i,l));return n&&Object.isExtensible(n)&&(n._normalized=r),W(r,"$stable",u),W(r,"$key",s),W(r,"$hasNormal",o),r}function yt(e,n,i,a){var r=function(){var n=pe;le(e);var i=arguments.length?a.apply(null,arguments):a({}),r=(i=i&&"object"==typeof i&&!t(i)?[i]:Ue(i))&&i[0];return le(n),i&&(!r||1===i.length&&r.isComment&&!dt(r))?void 0:i};return a.proxy&&Object.defineProperty(n,i,{get:r,enumerable:!0,configurable:!0}),r}function mt(e,t){return function(){return e[t]}}function ft(e,t,n,i,a){var r=!1;for(var o in t)o in e?t[o]!==n[o]&&(r=!0):(r=!0,ht(e,o,i,a));for(var o in e)o in t||(r=!0,delete e[o]);return r}function ht(e,t,n,i){Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get:function(){return n[i][t]}})}function vt(e,t){for(var n in t)e[n]=t[n];for(var n in e)n in t||delete e[n]}var gt,bt=null;function Tt(e,t){return(e.__esModule||se&&"Module"===e[Symbol.toStringTag])&&(e=e.default),s(e)?t.extend(e):e}function wt(e){if(t(e))for(var n=0;ndocument.createEvent("Event").timeStamp&&(jt=function(){return Nt.now()})}var Dt=function(e,t){if(e.post){if(!t.post)return 1}else if(t.post)return-1;return e.id-t.id};function zt(){var e,t;for(Bt=jt(),Et=!0,St.sort(Dt),$t=0;$t$t&&St[n].id>e.id;)n--;St.splice(n+1,0,e)}else St.push(e);Lt||(Lt=!0,on(zt))}}(this)},e.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||s(e)||this.deep){var t=this.value;if(this.value=e,this.user){var n='callback for watcher "'.concat(this.expression,'"');Ht(this.cb,this.vm,[e,t],this.vm,n)}else this.cb.call(this.vm,e,t)}}},e.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},e.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},e.prototype.teardown=function(){if(this.vm&&!this.vm._isBeingDestroyed&&g(this.vm._scope.effects,this),this.active){for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1,this.onStop&&this.onStop()}},e}(),yn={enumerable:!0,configurable:!0,get:F,set:F};function mn(e,t,n){yn.get=function(){return this[t][n]},yn.set=function(e){this[t][n]=e},Object.defineProperty(e,n,yn)}function fn(n){var i=n.$options;if(i.props&&function(e,t){var n=e.$options.propsData||{},i=e._props=Re({}),a=e.$options._propKeys=[];e.$parent&&ke(!1);var r=function(r){a.push(r);var o=Dn(r,t,n,e);Ie(i,r,o),r in e||mn(e,"_props",r)};for(var o in t)r(o);ke(!0)}(n,i.props),function(t){var n=t.$options,i=n.setup;if(i){var a=t._setupContext=function(t){return{get attrs(){if(!t._attrsProxy){var n=t._attrsProxy={};W(n,"_v_attr_proxy",!0),ft(n,t.$attrs,e,t,"$attrs")}return t._attrsProxy},get listeners(){return t._listenersProxy||ft(t._listenersProxy={},t.$listeners,e,t,"$listeners"),t._listenersProxy},get slots(){return function(e){return e._slotsProxy||vt(e._slotsProxy={},e.$scopedSlots),e._slotsProxy}(t)},emit:A(t.$emit,t),expose:function(e){e&&Object.keys(e).forEach((function(n){return $e(t,e,n)}))}}}(t);le(t),be();var r=Ht(i,null,[t._props||Re({}),a],t,"setup");if(Te(),le(),u(r))n.render=r;else if(s(r))if(t._setupState=r,r.__sfc){var o=t._setupProxy={};for(var p in r)"__sfc"!==p&&$e(o,r,p)}else for(var p in r)U(p)||$e(t,r,p)}}(n),i.methods&&function(e,t){for(var n in e.$options.props,t)e[n]="function"!=typeof t[n]?F:A(t[n],e)}(n,i.methods),i.data)!function(e){var t=e.$options.data;l(t=e._data=u(t)?function(e,t){be();try{return e.call(t,t)}catch(e){return Qt(e,t,"data()"),{}}finally{Te()}}(t,e):t||{})||(t={});for(var n=Object.keys(t),i=e.$options.props,a=(e.$options.methods,n.length);a--;){var r=n[a];i&&T(i,r)||U(r)||mn(e,"_data",r)}var o=Oe(t);o&&o.vmCount++}(n);else{var a=Oe(n._data={});a&&a.vmCount++}i.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),i=ae();for(var a in t){var r=t[a],o=u(r)?r:r.get;i||(n[a]=new cn(e,o||F,F,hn)),a in e||vn(e,a,r)}}(n,i.computed),i.watch&&i.watch!==te&&function(e,n){for(var i in n){var a=n[i];if(t(a))for(var r=0;r-1)if(r&&!T(a,"default"))o=!1;else if(""===o||o===k(e)){var p=Gn(String,a.type);(p<0||s-1:"string"==typeof e?e.split(",").indexOf(n)>-1:(i=e,!("[object RegExp]"!==p.call(i))&&e.test(n));var i}function Kn(e,t){var n=e.cache,i=e.keys,a=e._vnode;for(var r in n){var o=n[r];if(o){var u=o.name;u&&!t(u)&&Jn(n,r,i,a)}}}function Jn(e,t,n,i){var a=e[t];!a||i&&a.tag===i.tag||a.componentInstance.$destroy(),e[t]=null,g(n,t)}!function(t){t.prototype._init=function(t){var n=this;n._uid=xn++,n._isVue=!0,n.__v_skip=!0,n._scope=new Gt(!0),n._scope._vm=!0,t&&t._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),i=t._parentVnode;n.parent=t.parent,n._parentVnode=i;var a=i.componentOptions;n.propsData=a.propsData,n._parentListeners=a.listeners,n._renderChildren=a.children,n._componentTag=a.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(n,t):n.$options=jn(_n(n.constructor),t||{},n),n._renderProxy=n,n._self=n,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._provided=n?n._provided:Object.create(null),e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(n),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&qt(e,t)}(n),function(t){t._vnode=null,t._staticTrees=null;var n=t.$options,i=t.$vnode=n._parentVnode,a=i&&i.context;t.$slots=pt(n._renderChildren,a),t.$scopedSlots=i?ct(t.$parent,i.data.scopedSlots,t.$slots):e,t._c=function(e,n,i,a){return Qe(t,e,n,i,a,!1)},t.$createElement=function(e,n,i,a){return Qe(t,e,n,i,a,!0)};var r=i&&i.data;Ie(t,"$attrs",r&&r.attrs||e,null,!0),Ie(t,"$listeners",n._parentListeners||e,null,!0)}(n),Ft(n,"beforeCreate",void 0,!1),function(e){var t=wn(e.$options.inject,e);t&&(ke(!1),Object.keys(t).forEach((function(n){Ie(e,n,t[n])})),ke(!0))}(n),fn(n),function(e){var t=e.$options.provide;if(t){var n=u(t)?t.call(e):t;if(!s(n))return;for(var i=function(e){var t=e._provided,n=e.$parent&&e.$parent._provided;return n===t?e._provided=Object.create(n):t}(e),a=se?Reflect.ownKeys(n):Object.keys(n),r=0;r1?C(n):n;for(var i=C(arguments,1),a='event handler for "'.concat(e,'"'),r=0,o=n.length;rparseInt(this.max)&&Jn(t,n[0],n,this._vnode),this.vnodeToCache=null}}},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){for(var e in this.cache)Jn(this.cache,e,this.keys)},mounted:function(){var e=this;this.cacheVNode(),this.$watch("include",(function(t){Kn(e,(function(e){return Vn(t,e)}))})),this.$watch("exclude",(function(t){Kn(e,(function(e){return!Vn(t,e)}))}))},updated:function(){this.cacheVNode()},render:function(){var e=this.$slots.default,t=wt(e),n=t&&t.componentOptions;if(n){var i=Hn(n),a=this.include,r=this.exclude;if(a&&(!i||!Vn(a,i))||r&&i&&Vn(r,i))return t;var o=this.cache,u=this.keys,s=null==t.key?n.Ctor.cid+(n.tag?"::".concat(n.tag):""):t.key;o[s]?(t.componentInstance=o[s].componentInstance,g(u,s),u.push(s)):(this.vnodeToCache=t,this.keyToCache=s),t.data.keepAlive=!0}return t||e&&e[0]}}};!function(e){var t={get:function(){return D}};Object.defineProperty(e,"config",t),e.util={warn:Sn,extend:O,mergeOptions:jn,defineReactive:Ie},e.set=Fe,e.delete=Se,e.nextTick=on,e.observable=function(e){return Oe(e),e},e.options=Object.create(null),j.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,O(e.options.components,Xn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=C(arguments,1);return n.unshift(this),u(e.install)?e.install.apply(e,n):u(e)&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=jn(this.options,e),this}}(e),function(e){e.cid=0;var t=1;e.extend=function(e){e=e||{};var n=this,i=n.cid,a=e._Ctor||(e._Ctor={});if(a[i])return a[i];var r=An(e)||An(n.options),o=function(e){this._init(e)};return(o.prototype=Object.create(n.prototype)).constructor=o,o.cid=t++,o.options=jn(n.options,e),o.super=n,o.options.props&&function(e){var t=e.options.props;for(var n in t)mn(e.prototype,"_props",n)}(o),o.options.computed&&function(e){var t=e.options.computed;for(var n in t)vn(e.prototype,n,t[n])}(o),o.extend=n.extend,o.mixin=n.mixin,o.use=n.use,j.forEach((function(e){o[e]=n[e]})),r&&(o.options.components[r]=o),o.superOptions=n.options,o.extendOptions=e,o.sealedOptions=O({},o.options),a[i]=o,o}}(e),function(e){j.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&l(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&u(n)&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)}(Qn),Object.defineProperty(Qn.prototype,"$isServer",{get:ae}),Object.defineProperty(Qn.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(Qn,"FunctionalRenderContext",{value:Mn}),Qn.version="2.7.14";var Zn=f("style,class"),ei=f("input,textarea,option,select,progress"),ti=function(e,t,n){return"value"===n&&ei(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},ni=f("contenteditable,draggable,spellcheck"),ii=f("events,caret,typing,plaintext-only"),ai=f("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,truespeed,typemustmatch,visible"),ri="http://www.w3.org/1999/xlink",oi=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},ui=function(e){return oi(e)?e.slice(6,e.length):""},si=function(e){return null==e||!1===e};function pi(e,t){return{staticClass:li(e.staticClass,t.staticClass),class:a(e.class)?[e.class,t.class]:t.class}}function li(e,t){return e?t?e+" "+t:e:t||""}function di(e){return Array.isArray(e)?function(e){for(var t,n="",i=0,r=e.length;i-1?$i(e,t,n):ai(t)?si(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n)):ni(t)?e.setAttribute(t,function(e,t){return si(t)||"false"===t?"false":"contenteditable"===e&&ii(t)?t:"true"}(t,n)):oi(t)?si(n)?e.removeAttributeNS(ri,ui(t)):e.setAttributeNS(ri,t,n):$i(e,t,n)}function $i(e,t,n){if(si(n))e.removeAttribute(t);else{if(K&&!J&&"TEXTAREA"===e.tagName&&"placeholder"===t&&""!==n&&!e.__ieph){var i=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",i)};e.addEventListener("input",i),e.__ieph=!0}e.setAttribute(t,n)}}var Bi={create:Li,update:Li};function ji(e,t){var n=t.elm,r=t.data,o=e.data;if(!(i(r.staticClass)&&i(r.class)&&(i(o)||i(o.staticClass)&&i(o.class)))){var u=function(e){for(var t=e.data,n=e,i=e;a(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(t=pi(i.data,t));for(;a(n=n.parent);)n&&n.data&&(t=pi(t,n.data));return r=t.staticClass,o=t.class,a(r)||a(o)?li(r,di(o)):"";var r,o}(t),s=n._transitionClasses;a(s)&&(u=li(u,di(s))),u!==n._prevClass&&(n.setAttribute("class",u),n._prevClass=u)}}var Ni,Di,zi,Ui,Wi,Gi,Qi={create:ji,update:ji},Hi=/[\w).+\-_$\]]/;function Vi(e){var t,n,i,a,r,o=!1,u=!1,s=!1,p=!1,l=0,d=0,c=0,y=0;for(i=0;i=0&&" "===(f=e.charAt(m));m--);f&&Hi.test(f)||(p=!0)}}else void 0===a?(y=i+1,a=e.slice(0,i).trim()):h();function h(){(r||(r=[])).push(e.slice(y,i).trim()),y=i+1}if(void 0===a?a=e.slice(0,i).trim():0!==y&&h(),r)for(i=0;i-1?{exp:e.slice(0,Ui),key:'"'+e.slice(Ui+1)+'"'}:{exp:e,key:null};for(Di=e,Ui=Wi=Gi=0;!da();)ca(zi=la())?ma(zi):91===zi&&ya(zi);return{exp:e.slice(0,Wi),key:e.slice(Wi+1,Gi)}}(e);return null===n.key?"".concat(e,"=").concat(t):"$set(".concat(n.exp,", ").concat(n.key,", ").concat(t,")")}function la(){return Di.charCodeAt(++Ui)}function da(){return Ui>=Ni}function ca(e){return 34===e||39===e}function ya(e){var t=1;for(Wi=Ui;!da();)if(ca(e=la()))ma(e);else if(91===e&&t++,93===e&&t--,0===t){Gi=Ui;break}}function ma(e){for(var t=e;!da()&&(e=la())!==t;);}var fa;function ha(e,t,n){var i=fa;return function a(){var r=t.apply(null,arguments);null!==r&&ba(e,a,n,i)}}var va=Yt&&!(ee&&Number(ee[1])<=53);function ga(e,t,n,i){if(va){var a=Bt,r=t;t=r._wrapper=function(e){if(e.target===e.currentTarget||e.timeStamp>=a||e.timeStamp<=0||e.target.ownerDocument!==document)return r.apply(this,arguments)}}fa.addEventListener(e,t,ne?{capture:n,passive:i}:n)}function ba(e,t,n,i){(i||fa).removeEventListener(e,t._wrapper||t,n)}function Ta(e,t){if(!i(e.data.on)||!i(t.data.on)){var n=t.data.on||{},r=e.data.on||{};fa=t.elm||e.elm,function(e){if(a(e.__r)){var t=K?"change":"input";e[t]=[].concat(e.__r,e[t]||[]),delete e.__r}a(e.__c)&&(e.change=[].concat(e.__c,e.change||[]),delete e.__c)}(n),Ne(n,r,ga,ba,ha,t.context),fa=void 0}}var wa,xa={create:Ta,update:Ta,destroy:function(e){return Ta(e,Mi)}};function _a(e,t){if(!i(e.data.domProps)||!i(t.data.domProps)){var n,o,u=t.elm,s=e.data.domProps||{},p=t.data.domProps||{};for(n in(a(p.__ob__)||r(p._v_attr_proxy))&&(p=t.data.domProps=O({},p)),s)n in p||(u[n]="");for(n in p){if(o=p[n],"textContent"===n||"innerHTML"===n){if(t.children&&(t.children.length=0),o===s[n])continue;1===u.childNodes.length&&u.removeChild(u.childNodes[0])}if("value"===n&&"PROGRESS"!==u.tagName){u._value=o;var l=i(o)?"":String(o);Ma(u,l)&&(u.value=l)}else if("innerHTML"===n&&mi(u.tagName)&&i(u.innerHTML)){(wa=wa||document.createElement("div")).innerHTML="".concat(o,"");for(var d=wa.firstChild;u.firstChild;)u.removeChild(u.firstChild);for(;d.firstChild;)u.appendChild(d.firstChild)}else if(o!==s[n])try{u[n]=o}catch(e){}}}}function Ma(e,t){return!e.composing&&("OPTION"===e.tagName||function(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}(e,t)||function(e,t){var n=e.value,i=e._vModifiers;if(a(i)){if(i.number)return m(n)!==m(t);if(i.trim)return n.trim()!==t.trim()}return n!==t}(e,t))}var qa={create:_a,update:_a},ka=w((function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach((function(e){if(e){var i=e.split(n);i.length>1&&(t[i[0].trim()]=i[1].trim())}})),t}));function Aa(e){var t=Ca(e.style);return e.staticStyle?O(e.staticStyle,t):t}function Ca(e){return Array.isArray(e)?I(e):"string"==typeof e?ka(e):e}var Oa,Ia=/^--/,Fa=/\s*!important$/,Sa=function(e,t,n){if(Ia.test(t))e.style.setProperty(t,n);else if(Fa.test(n))e.style.setProperty(k(t),n.replace(Fa,""),"important");else{var i=Ra(t);if(Array.isArray(n))for(var a=0,r=n.length;a-1?t.split($a).forEach((function(t){return e.classList.add(t)})):e.classList.add(t);else{var n=" ".concat(e.getAttribute("class")||""," ");n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function ja(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split($a).forEach((function(t){return e.classList.remove(t)})):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" ".concat(e.getAttribute("class")||""," "),i=" "+t+" ";n.indexOf(i)>=0;)n=n.replace(i," ");(n=n.trim())?e.setAttribute("class",n):e.removeAttribute("class")}}function Na(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&O(t,Da(e.name||"v")),O(t,e),t}return"string"==typeof e?Da(e):void 0}}var Da=w((function(e){return{enterClass:"".concat(e,"-enter"),enterToClass:"".concat(e,"-enter-to"),enterActiveClass:"".concat(e,"-enter-active"),leaveClass:"".concat(e,"-leave"),leaveToClass:"".concat(e,"-leave-to"),leaveActiveClass:"".concat(e,"-leave-active")}})),za=H&&!J,Ua="transition",Wa="animation",Ga="transition",Qa="transitionend",Ha="animation",Va="animationend";za&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(Ga="WebkitTransition",Qa="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(Ha="WebkitAnimation",Va="webkitAnimationEnd"));var Ka=H?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()};function Ja(e){Ka((function(){Ka(e)}))}function Ya(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),Ba(e,t))}function Xa(e,t){e._transitionClasses&&g(e._transitionClasses,t),ja(e,t)}function Za(e,t,n){var i=tr(e,t),a=i.type,r=i.timeout,o=i.propCount;if(!a)return n();var u=a===Ua?Qa:Va,s=0,p=function(){e.removeEventListener(u,l),n()},l=function(t){t.target===e&&++s>=o&&p()};setTimeout((function(){s0&&(n=Ua,l=o,d=r.length):t===Wa?p>0&&(n=Wa,l=p,d=s.length):d=(n=(l=Math.max(o,p))>0?o>p?Ua:Wa:null)?n===Ua?r.length:s.length:0,{type:n,timeout:l,propCount:d,hasTransform:n===Ua&&er.test(i[Ga+"Property"])}}function nr(e,t){for(;e.length1}function sr(e,t){!0!==t.data.show&&ar(t)}var pr=function(e){var n,u,s={},p=e.modules,l=e.nodeOps;for(n=0;nm?T(e,i(n[v+1])?null:n[v+1].elm,n,y,v,r):y>v&&x(t,d,m)}(d,f,h,n,p):a(h)?(a(e.text)&&l.setTextContent(d,""),T(d,null,h,0,h.length-1,n)):a(f)?x(f,0,f.length-1):a(e.text)&&l.setTextContent(d,""):e.text!==t.text&&l.setTextContent(d,t.text),a(m)&&a(y=m.hook)&&a(y=y.postpatch)&&y(e,t)}}}function k(e,t,n){if(r(n)&&a(e.parent))e.parent.data.pendingInsert=t;else for(var i=0;i-1,o.selected!==r&&(o.selected=r);else if(R(mr(o),i))return void(e.selectedIndex!==u&&(e.selectedIndex=u));a||(e.selectedIndex=-1)}}function yr(e,t){return t.every((function(t){return!R(t,e)}))}function mr(e){return"_value"in e?e._value:e.value}function fr(e){e.target.composing=!0}function hr(e){e.target.composing&&(e.target.composing=!1,vr(e.target,"input"))}function vr(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function gr(e){return!e.componentInstance||e.data&&e.data.transition?e:gr(e.componentInstance._vnode)}var br={model:lr,show:{bind:function(e,t,n){var i=t.value,a=(n=gr(n)).data&&n.data.transition,r=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;i&&a?(n.data.show=!0,ar(n,(function(){e.style.display=r}))):e.style.display=i?r:"none"},update:function(e,t,n){var i=t.value;!i!=!t.oldValue&&((n=gr(n)).data&&n.data.transition?(n.data.show=!0,i?ar(n,(function(){e.style.display=e.__vOriginalDisplay})):rr(n,(function(){e.style.display="none"}))):e.style.display=i?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,i,a){a||(e.style.display=e.__vOriginalDisplay)}}},Tr={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function wr(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?wr(wt(t.children)):e}function xr(e){var t={},n=e.$options;for(var i in n.propsData)t[i]=e[i];var a=n._parentListeners;for(var i in a)t[_(i)]=a[i];return t}function _r(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}var Mr=function(e){return e.tag||dt(e)},qr=function(e){return"show"===e.name},kr={name:"transition",props:Tr,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(Mr)).length){var i=this.mode,a=n[0];if(function(e){for(;e=e.parent;)if(e.data.transition)return!0}(this.$vnode))return a;var r=wr(a);if(!r)return a;if(this._leaving)return _r(e,a);var u="__transition-".concat(this._uid,"-");r.key=null==r.key?r.isComment?u+"comment":u+r.tag:o(r.key)?0===String(r.key).indexOf(u)?r.key:u+r.key:r.key;var s=(r.data||(r.data={})).transition=xr(this),p=this._vnode,l=wr(p);if(r.data.directives&&r.data.directives.some(qr)&&(r.data.show=!0),l&&l.data&&!function(e,t){return t.key===e.key&&t.tag===e.tag}(r,l)&&!dt(l)&&(!l.componentInstance||!l.componentInstance._vnode.isComment)){var d=l.data.transition=O({},s);if("out-in"===i)return this._leaving=!0,De(d,"afterLeave",(function(){t._leaving=!1,t.$forceUpdate()})),_r(e,a);if("in-out"===i){if(dt(r))return p;var c,y=function(){c()};De(s,"afterEnter",y),De(s,"enterCancelled",y),De(d,"delayLeave",(function(e){c=e}))}}return a}}},Ar=O({tag:String,moveClass:String},Tr);delete Ar.mode;var Cr={props:Ar,beforeMount:function(){var e=this,t=this._update;this._update=function(n,i){var a=At(e);e.__patch__(e._vnode,e.kept,!1,!0),e._vnode=e.kept,a(),t.call(e,n,i)}},render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),i=this.prevChildren=this.children,a=this.$slots.default||[],r=this.children=[],o=xr(this),u=0;u-1?vi[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:vi[e]=/HTMLUnknownElement/.test(t.toString())},O(Qn.options.directives,br),O(Qn.options.components,Sr),Qn.prototype.__patch__=H?pr:F,Qn.prototype.$mount=function(e,t){return function(e,t,n){var i;e.$el=t,e.$options.render||(e.$options.render=ce),Ft(e,"beforeMount"),i=function(){e._update(e._render(),n)},new cn(e,i,F,{before:function(){e._isMounted&&!e._isDestroyed&&Ft(e,"beforeUpdate")}},!0),n=!1;var a=e._preWatchers;if(a)for(var r=0;r\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Ur=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Wr="[a-zA-Z_][\\-\\.0-9_a-zA-Z".concat(z.source,"]*"),Gr="((?:".concat(Wr,"\\:)?").concat(Wr,")"),Qr=new RegExp("^<".concat(Gr)),Hr=/^\s*(\/?)>/,Vr=new RegExp("^<\\/".concat(Gr,"[^>]*>")),Kr=/^]+>/i,Jr=/^",""":'"',"&":"&"," ":"\n"," ":"\t","'":"'"},to=/&(?:lt|gt|quot|amp|#39);/g,no=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,io=f("pre,textarea",!0),ao=function(e,t){return e&&io(e)&&"\n"===t[0]};function ro(e,t){var n=t?no:to;return e.replace(n,(function(e){return eo[e]}))}var oo,uo,so,po,lo,co,yo,mo,fo=/^@|^v-on:/,ho=/^v-|^@|^:|^#/,vo=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,go=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,bo=/^\(|\)$/g,To=/^\[.*\]$/,wo=/:(.*)$/,xo=/^:|^\.|^v-bind:/,_o=/\.[^.\]]+(?=[^\]]*$)/g,Mo=/^v-slot(:|$)|^#/,qo=/[\r\n]/,ko=/[ \f\t\r\n]+/g,Ao=w((function(e){return(Pr=Pr||document.createElement("div")).innerHTML=e,Pr.textContent})),Co="_empty_";function Oo(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:Eo(t),rawAttrsMap:{},parent:n,children:[]}}function Io(e,t){oo=t.warn||Ji,co=t.isPreTag||S,yo=t.mustUseProp||S,mo=t.getTagNamespace||S;t.isReservedTag;so=Yi(t.modules,"transformNode"),po=Yi(t.modules,"preTransformNode"),lo=Yi(t.modules,"postTransformNode"),uo=t.delimiters;var n,i,a=[],r=!1!==t.preserveWhitespace,o=t.whitespace,u=!1,s=!1;function p(e){if(l(e),u||e.processed||(e=Fo(e,t)),a.length||e===n||n.if&&(e.elseif||e.else)&&Po(n,{exp:e.elseif,block:e}),i&&!e.forbidden)if(e.elseif||e.else)o=e,p=function(e){for(var t=e.length;t--;){if(1===e[t].type)return e[t];e.pop()}}(i.children),p&&p.if&&Po(p,{exp:o.elseif,block:o});else{if(e.slotScope){var r=e.slotTarget||'"default"';(i.scopedSlots||(i.scopedSlots={}))[r]=e}i.children.push(e),e.parent=i}var o,p;e.children=e.children.filter((function(e){return!e.slotScope})),l(e),e.pre&&(u=!1),co(e.tag)&&(s=!1);for(var d=0;d]*>)","i"));x=e.replace(y,(function(e,n,i){return p=i.length,Xr(c)||"noscript"===c||(n=n.replace(//g,"$1").replace(//g,"$1")),ao(c,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""})),s+=e.length-x.length,e=x,d(c,s-p,s)}else{var m=e.indexOf("<");if(0===m){if(Jr.test(e)){var f=e.indexOf("--\x3e");if(f>=0)return t.shouldKeepComment&&t.comment&&t.comment(e.substring(4,f),s,s+f+3),l(f+3),"continue"}if(Yr.test(e)){var h=e.indexOf("]>");if(h>=0)return l(h+2),"continue"}var v=e.match(Kr);if(v)return l(v[0].length),"continue";var g=e.match(Vr);if(g){var b=s;return l(g[0].length),d(g[1],b,s),"continue"}var T=function(){var t=e.match(Qr);if(t){var n={tagName:t[1],attrs:[],start:s};l(t[0].length);for(var i=void 0,a=void 0;!(i=e.match(Hr))&&(a=e.match(Ur)||e.match(zr));)a.start=s,l(a[0].length),a.end=s,n.attrs.push(a);if(i)return n.unarySlash=i[1],l(i[0].length),n.end=s,n}}();if(T)return function(e){var n=e.tagName,s=e.unarySlash;r&&("p"===i&&Dr(n)&&d(i),u(n)&&i===n&&d(n));for(var p=o(n)||!!s,l=e.attrs.length,c=new Array(l),y=0;y=0){for(x=e.slice(m);!(Vr.test(x)||Qr.test(x)||Jr.test(x)||Yr.test(x)||(_=x.indexOf("<",1))<0);)m+=_,x=e.slice(m);w=e.substring(0,m)}m<0&&(w=e),w&&l(w.length),t.chars&&w&&t.chars(w,s-w.length,s)}if(e===n)return t.chars&&t.chars(e),"break"};e&&"break"!==p(););function l(t){s+=t,e=e.substring(t)}function d(e,n,r){var o,u;if(null==n&&(n=s),null==r&&(r=s),e)for(u=e.toLowerCase(),o=a.length-1;o>=0&&a[o].lowerCasedTag!==u;o--);else o=0;if(o>=0){for(var p=a.length-1;p>=o;p--)t.end&&t.end(a[p].tag,n,r);a.length=o,i=o&&a[o-1].tag}else"br"===u?t.start&&t.start(e,[],!0,n,r):"p"===u&&(t.start&&t.start(e,[],!1,n,r),t.end&&t.end(e,n,r))}d()}(e,{warn:oo,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,outputSourceRange:t.outputSourceRange,start:function(e,r,o,l,d){var c=i&&i.ns||mo(e);K&&"svg"===c&&(r=function(e){for(var t=[],n=0;ns&&(u.push(r=e.slice(s,a)),o.push(JSON.stringify(r)));var p=Vi(i[1].trim());o.push("_s(".concat(p,")")),u.push({"@binding":p}),s=a+i[0].length}return s-1")+("true"===r?":(".concat(t,")"):":_q(".concat(t,",").concat(r,")"))),ia(e,"change","var $$a=".concat(t,",")+"$$el=$event.target,"+"$$c=$$el.checked?(".concat(r,"):(").concat(o,");")+"if(Array.isArray($$a)){"+"var $$v=".concat(i?"_n("+a+")":a,",")+"$$i=_i($$a,$$v);"+"if($$el.checked){$$i<0&&(".concat(pa(t,"$$a.concat([$$v])"),")}")+"else{$$i>-1&&(".concat(pa(t,"$$a.slice(0,$$i).concat($$a.slice($$i+1))"),")}")+"}else{".concat(pa(t,"$$c"),"}"),null,!0)}(e,i,a);else if("input"===r&&"radio"===o)!function(e,t,n){var i=n&&n.number,a=aa(e,"value")||"null";a=i?"_n(".concat(a,")"):a,Xi(e,"checked","_q(".concat(t,",").concat(a,")")),ia(e,"change",pa(t,a),null,!0)}(e,i,a);else if("input"===r||"textarea"===r)!function(e,t,n){var i=e.attrsMap.type,a=n||{},r=a.lazy,o=a.number,u=a.trim,s=!r&&"range"!==i,p=r?"change":"range"===i?"__r":"input",l="$event.target.value";u&&(l="$event.target.value.trim()"),o&&(l="_n(".concat(l,")"));var d=pa(t,l);s&&(d="if($event.target.composing)return;".concat(d)),Xi(e,"value","(".concat(t,")")),ia(e,p,d,null,!0),(u||o)&&ia(e,"blur","$forceUpdate()")}(e,i,a);else if(!D.isReservedTag(r))return sa(e,i,a),!1;return!0},text:function(e,t){t.value&&Xi(e,"textContent","_s(".concat(t.value,")"),t)},html:function(e,t){t.value&&Xi(e,"innerHTML","_s(".concat(t.value,")"),t)}},isPreTag:function(e){return"pre"===e},isUnaryTag:jr,mustUseProp:ti,canBeLeftOpenTag:Nr,isReservedTag:fi,getTagNamespace:hi,staticKeys:function(e){return e.reduce((function(e,t){return e.concat(t.staticKeys||[])}),[]).join(",")}(zo)},Wo=w((function(e){return f("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(e?","+e:""))}));function Go(e,t){e&&(No=Wo(t.staticKeys||""),Do=t.isReservedTag||S,Qo(e),Ho(e,!1))}function Qo(e){if(e.static=function(e){return 2!==e.type&&(3===e.type||!(!e.pre&&(e.hasBindings||e.if||e.for||h(e.tag)||!Do(e.tag)||function(e){for(;e.parent;){if("template"!==(e=e.parent).tag)return!1;if(e.for)return!0}return!1}(e)||!Object.keys(e).every(No))))}(e),1===e.type){if(!Do(e.tag)&&"slot"!==e.tag&&null==e.attrsMap["inline-template"])return;for(var t=0,n=e.children.length;t|^function(?:\s+[\w$]+)?\s*\(/,Ko=/\([^)]*?\);*$/,Jo=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,Yo={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Xo={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},Zo=function(e){return"if(".concat(e,")return null;")},eu={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Zo("$event.target !== $event.currentTarget"),ctrl:Zo("!$event.ctrlKey"),shift:Zo("!$event.shiftKey"),alt:Zo("!$event.altKey"),meta:Zo("!$event.metaKey"),left:Zo("'button' in $event && $event.button !== 0"),middle:Zo("'button' in $event && $event.button !== 1"),right:Zo("'button' in $event && $event.button !== 2")};function tu(e,t){var n=t?"nativeOn:":"on:",i="",a="";for(var r in e){var o=nu(e[r]);e[r]&&e[r].dynamic?a+="".concat(r,",").concat(o,","):i+='"'.concat(r,'":').concat(o,",")}return i="{".concat(i.slice(0,-1),"}"),a?n+"_d(".concat(i,",[").concat(a.slice(0,-1),"])"):n+i}function nu(e){if(!e)return"function(){}";if(Array.isArray(e))return"[".concat(e.map((function(e){return nu(e)})).join(","),"]");var t=Jo.test(e.value),n=Vo.test(e.value),i=Jo.test(e.value.replace(Ko,""));if(e.modifiers){var a="",r="",o=[],u=function(t){if(eu[t])r+=eu[t],Yo[t]&&o.push(t);else if("exact"===t){var n=e.modifiers;r+=Zo(["ctrl","shift","alt","meta"].filter((function(e){return!n[e]})).map((function(e){return"$event.".concat(e,"Key")})).join("||"))}else o.push(t)};for(var s in e.modifiers)u(s);o.length&&(a+=function(e){return"if(!$event.type.indexOf('key')&&"+"".concat(e.map(iu).join("&&"),")return null;")}(o)),r&&(a+=r);var p=t?"return ".concat(e.value,".apply(null, arguments)"):n?"return (".concat(e.value,").apply(null, arguments)"):i?"return ".concat(e.value):e.value;return"function($event){".concat(a).concat(p,"}")}return t||n?e.value:"function($event){".concat(i?"return ".concat(e.value):e.value,"}")}function iu(e){var t=parseInt(e,10);if(t)return"$event.keyCode!==".concat(t);var n=Yo[e],i=Xo[e];return"_k($event.keyCode,"+"".concat(JSON.stringify(e),",")+"".concat(JSON.stringify(n),",")+"$event.key,"+"".concat(JSON.stringify(i))+")"}var au={on:function(e,t){e.wrapListeners=function(e){return"_g(".concat(e,",").concat(t.value,")")}},bind:function(e,t){e.wrapData=function(n){return"_b(".concat(n,",'").concat(e.tag,"',").concat(t.value,",").concat(t.modifiers&&t.modifiers.prop?"true":"false").concat(t.modifiers&&t.modifiers.sync?",true":"",")")}},cloak:F},ru=function(e){this.options=e,this.warn=e.warn||Ji,this.transforms=Yi(e.modules,"transformCode"),this.dataGenFns=Yi(e.modules,"genData"),this.directives=O(O({},au),e.directives);var t=e.isReservedTag||S;this.maybeComponent=function(e){return!!e.component||!t(e.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function ou(e,t){var n=new ru(t),i=e?"script"===e.tag?"null":uu(e,n):'_c("div")';return{render:"with(this){return ".concat(i,"}"),staticRenderFns:n.staticRenderFns}}function uu(e,t){if(e.parent&&(e.pre=e.pre||e.parent.pre),e.staticRoot&&!e.staticProcessed)return su(e,t);if(e.once&&!e.onceProcessed)return pu(e,t);if(e.for&&!e.forProcessed)return cu(e,t);if(e.if&&!e.ifProcessed)return lu(e,t);if("template"!==e.tag||e.slotTarget||t.pre){if("slot"===e.tag)return function(e,t){var n=e.slotName||'"default"',i=hu(e,t),a="_t(".concat(n).concat(i?",function(){return ".concat(i,"}"):""),r=e.attrs||e.dynamicAttrs?bu((e.attrs||[]).concat(e.dynamicAttrs||[]).map((function(e){return{name:_(e.name),value:e.value,dynamic:e.dynamic}}))):null,o=e.attrsMap["v-bind"];return!r&&!o||i||(a+=",null"),r&&(a+=",".concat(r)),o&&(a+="".concat(r?"":",null",",").concat(o)),a+")"}(e,t);var n=void 0;if(e.component)n=function(e,t,n){var i=t.inlineTemplate?null:hu(t,n,!0);return"_c(".concat(e,",").concat(yu(t,n)).concat(i?",".concat(i):"",")")}(e.component,e,t);else{var i=void 0,a=t.maybeComponent(e);(!e.plain||e.pre&&a)&&(i=yu(e,t));var r=void 0,o=t.options.bindings;a&&o&&!1!==o.__isScriptSetup&&(r=function(e,t){var n=_(t),i=M(n),a=function(a){return e[t]===a?t:e[n]===a?n:e[i]===a?i:void 0},r=a("setup-const")||a("setup-reactive-const");if(r)return r;var o=a("setup-let")||a("setup-ref")||a("setup-maybe-ref");return o||void 0}(o,e.tag)),r||(r="'".concat(e.tag,"'"));var u=e.inlineTemplate?null:hu(e,t,!0);n="_c(".concat(r).concat(i?",".concat(i):"").concat(u?",".concat(u):"",")")}for(var s=0;s>>0}(o)):"",")")}(e,e.scopedSlots,t),",")),e.model&&(n+="model:{value:".concat(e.model.value,",callback:").concat(e.model.callback,",expression:").concat(e.model.expression,"},")),e.inlineTemplate){var r=function(e,t){var n=e.children[0];if(n&&1===n.type){var i=ou(n,t.options);return"inlineTemplate:{render:function(){".concat(i.render,"},staticRenderFns:[").concat(i.staticRenderFns.map((function(e){return"function(){".concat(e,"}")})).join(","),"]}")}}(e,t);r&&(n+="".concat(r,","))}return n=n.replace(/,$/,"")+"}",e.dynamicAttrs&&(n="_b(".concat(n,',"').concat(e.tag,'",').concat(bu(e.dynamicAttrs),")")),e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function mu(e){return 1===e.type&&("slot"===e.tag||e.children.some(mu))}function fu(e,t){var n=e.attrsMap["slot-scope"];if(e.if&&!e.ifProcessed&&!n)return lu(e,t,fu,"null");if(e.for&&!e.forProcessed)return cu(e,t,fu);var i=e.slotScope===Co?"":String(e.slotScope),a="function(".concat(i,"){")+"return ".concat("template"===e.tag?e.if&&n?"(".concat(e.if,")?").concat(hu(e,t)||"undefined",":undefined"):hu(e,t)||"undefined":uu(e,t),"}"),r=i?"":",proxy:true";return"{key:".concat(e.slotTarget||'"default"',",fn:").concat(a).concat(r,"}")}function hu(e,t,n,i,a){var r=e.children;if(r.length){var o=r[0];if(1===r.length&&o.for&&"template"!==o.tag&&"slot"!==o.tag){var u=n?t.maybeComponent(o)?",1":",0":"";return"".concat((i||uu)(o,t)).concat(u)}var s=n?function(e,t){for(var n=0,i=0;i':'
',Mu.innerHTML.indexOf(" ")>0}var Cu=!!H&&Au(!1),Ou=!!H&&Au(!0),Iu=w((function(e){var t=bi(e);return t&&t.innerHTML})),Fu=Qn.prototype.$mount;function Su(e,t){for(var n in t)e[n]=t[n];return e}Qn.prototype.$mount=function(e,t){if((e=e&&bi(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var i=n.template;if(i)if("string"==typeof i)"#"===i.charAt(0)&&(i=Iu(i));else{if(!i.nodeType)return this;i=i.innerHTML}else e&&(i=function(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}(e));if(i){var a=ku(i,{outputSourceRange:!1,shouldDecodeNewlines:Cu,shouldDecodeNewlinesForHref:Ou,delimiters:n.delimiters,comments:n.comments},this),r=a.render,o=a.staticRenderFns;n.render=r,n.staticRenderFns=o}}return Fu.call(this,e,t)},Qn.compile=ku;var Pu=/[!'()*]/g,Ru=function(e){return"%"+e.charCodeAt(0).toString(16)},Lu=/%2C/g,Eu=function(e){return encodeURIComponent(e).replace(Pu,Ru).replace(Lu,",")};function $u(e){try{return decodeURIComponent(e)}catch(e){}return e}var Bu=function(e){return null==e||"object"==typeof e?e:String(e)};function ju(e){var t={};return(e=e.trim().replace(/^(\?|#|&)/,""))?(e.split("&").forEach((function(e){var n=e.replace(/\+/g," ").split("="),i=$u(n.shift()),a=n.length>0?$u(n.join("=")):null;void 0===t[i]?t[i]=a:Array.isArray(t[i])?t[i].push(a):t[i]=[t[i],a]})),t):t}function Nu(e){var t=e?Object.keys(e).map((function(t){var n=e[t];if(void 0===n)return"";if(null===n)return Eu(t);if(Array.isArray(n)){var i=[];return n.forEach((function(e){void 0!==e&&(null===e?i.push(Eu(t)):i.push(Eu(t)+"="+Eu(e)))})),i.join("&")}return Eu(t)+"="+Eu(n)})).filter((function(e){return e.length>0})).join("&"):null;return t?"?"+t:""}var Du=/\/?$/;function zu(e,t,n,i){var a=i&&i.options.stringifyQuery,r=t.query||{};try{r=Uu(r)}catch(e){}var o={name:t.name||e&&e.name,meta:e&&e.meta||{},path:t.path||"/",hash:t.hash||"",query:r,params:t.params||{},fullPath:Qu(t,a),matched:e?Gu(e):[]};return n&&(o.redirectedFrom=Qu(n,a)),Object.freeze(o)}function Uu(e){if(Array.isArray(e))return e.map(Uu);if(e&&"object"==typeof e){var t={};for(var n in e)t[n]=Uu(e[n]);return t}return e}var Wu=zu(null,{path:"/"});function Gu(e){for(var t=[];e;)t.unshift(e),e=e.parent;return t}function Qu(e,t){var n=e.path,i=e.query;void 0===i&&(i={});var a=e.hash;return void 0===a&&(a=""),(n||"/")+(t||Nu)(i)+a}function Hu(e,t,n){return t===Wu?e===t:!!t&&(e.path&&t.path?e.path.replace(Du,"")===t.path.replace(Du,"")&&(n||e.hash===t.hash&&Vu(e.query,t.query)):!(!e.name||!t.name)&&e.name===t.name&&(n||e.hash===t.hash&&Vu(e.query,t.query)&&Vu(e.params,t.params)))}function Vu(e,t){if(void 0===e&&(e={}),void 0===t&&(t={}),!e||!t)return e===t;var n=Object.keys(e).sort(),i=Object.keys(t).sort();return n.length===i.length&&n.every((function(n,a){var r=e[n];if(i[a]!==n)return!1;var o=t[n];return null==r||null==o?r===o:"object"==typeof r&&"object"==typeof o?Vu(r,o):String(r)===String(o)}))}function Ku(e){for(var t=0;t=0&&(t=e.slice(i),e=e.slice(0,i));var a=e.indexOf("?");return a>=0&&(n=e.slice(a+1),e=e.slice(0,a)),{path:e,query:n,hash:t}}(a.path||""),p=t&&t.path||"/",l=s.path?Xu(s.path,p,n||a.append):p,d=function(e,t,n){void 0===t&&(t={});var i,a=n||ju;try{i=a(e||"")}catch(e){i={}}for(var r in t){var o=t[r];i[r]=Array.isArray(o)?o.map(Bu):Bu(o)}return i}(s.query,a.query,i&&i.options.parseQuery),c=a.hash||s.hash;return c&&"#"!==c.charAt(0)&&(c="#"+c),{_normalized:!0,path:l,query:d,hash:c}}var gs,bs=function(){},Ts={name:"RouterLink",props:{to:{type:[String,Object],required:!0},tag:{type:String,default:"a"},custom:Boolean,exact:Boolean,exactPath:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,ariaCurrentValue:{type:String,default:"page"},event:{type:[String,Array],default:"click"}},render:function(e){var t=this,n=this.$router,i=this.$route,a=n.resolve(this.to,i,this.append),r=a.location,o=a.route,u=a.href,s={},p=n.options.linkActiveClass,l=n.options.linkExactActiveClass,d=null==p?"router-link-active":p,c=null==l?"router-link-exact-active":l,y=null==this.activeClass?d:this.activeClass,m=null==this.exactActiveClass?c:this.exactActiveClass,f=o.redirectedFrom?zu(null,vs(o.redirectedFrom),null,n):o;s[m]=Hu(i,f,this.exactPath),s[y]=this.exact||this.exactPath?s[m]:function(e,t){return 0===e.path.replace(Du,"/").indexOf(t.path.replace(Du,"/"))&&(!t.hash||e.hash===t.hash)&&function(e,t){for(var n in t)if(!(n in e))return!1;return!0}(e.query,t.query)}(i,f);var h=s[m]?this.ariaCurrentValue:null,v=function(e){ws(e)&&(t.replace?n.replace(r,bs):n.push(r,bs))},g={click:ws};Array.isArray(this.event)?this.event.forEach((function(e){g[e]=v})):g[this.event]=v;var b={class:s},T=!this.$scopedSlots.$hasNormal&&this.$scopedSlots.default&&this.$scopedSlots.default({href:u,route:o,navigate:v,isActive:s[y],isExactActive:s[m]});if(T){if(1===T.length)return T[0];if(T.length>1||!T.length)return 0===T.length?e():e("span",{},T)}if("a"===this.tag)b.on=g,b.attrs={href:u,"aria-current":h};else{var w=xs(this.$slots.default);if(w){w.isStatic=!1;var x=w.data=Su({},w.data);for(var _ in x.on=x.on||{},x.on){var M=x.on[_];_ in g&&(x.on[_]=Array.isArray(M)?M:[M])}for(var q in g)q in x.on?x.on[q].push(g[q]):x.on[q]=v;var k=w.data.attrs=Su({},w.data.attrs);k.href=u,k["aria-current"]=h}else b.on=g}return e(this.tag,b,this.$slots.default)}};function ws(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey||e.defaultPrevented||void 0!==e.button&&0!==e.button)){if(e.currentTarget&&e.currentTarget.getAttribute){var t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function xs(e){if(e)for(var t,n=0;n-1&&(s.params[c]=n.params[c]);return s.path=hs(l.path,s.params),u(l,s,o)}if(s.path){s.params={};for(var y=0;y-1}function Zs(e,t){return Xs(e)&&e._isRouter&&(null==t||e.type===t)}function ep(e,t,n){var i=function(a){a>=e.length?n():e[a]?t(e[a],(function(){i(a+1)})):i(a+1)};i(0)}function tp(e,t){return np(e.map((function(e){return Object.keys(e.components).map((function(n){return t(e.components[n],e.instances[n],e,n)}))})))}function np(e){return Array.prototype.concat.apply([],e)}var ip="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;function ap(e){var t=!1;return function(){for(var n=[],i=arguments.length;i--;)n[i]=arguments[i];if(!t)return t=!0,e.apply(this,n)}}var rp=function(e,t){this.router=e,this.base=function(e){if(!e)if(_s){var t=document.querySelector("base");e=(e=t&&t.getAttribute("href")||"/").replace(/^https?:\/\/[^\/]+/,"")}else e="/";return"/"!==e.charAt(0)&&(e="/"+e),e.replace(/\/$/,"")}(t),this.current=Wu,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[],this.listeners=[]};function op(e,t,n,i){var a=tp(e,(function(e,i,a,r){var o=function(e,t){return"function"!=typeof e&&(e=gs.extend(e)),e.options[t]}(e,t);if(o)return Array.isArray(o)?o.map((function(e){return n(e,i,a,r)})):n(o,i,a,r)}));return np(i?a.reverse():a)}function up(e,t){if(t)return function(){return e.apply(t,arguments)}}rp.prototype.listen=function(e){this.cb=e},rp.prototype.onReady=function(e,t){this.ready?e():(this.readyCbs.push(e),t&&this.readyErrorCbs.push(t))},rp.prototype.onError=function(e){this.errorCbs.push(e)},rp.prototype.transitionTo=function(e,t,n){var i,a=this;try{i=this.router.match(e,this.current)}catch(e){throw this.errorCbs.forEach((function(t){t(e)})),e}var r=this.current;this.confirmTransition(i,(function(){a.updateRoute(i),t&&t(i),a.ensureURL(),a.router.afterHooks.forEach((function(e){e&&e(i,r)})),a.ready||(a.ready=!0,a.readyCbs.forEach((function(e){e(i)})))}),(function(e){n&&n(e),e&&!a.ready&&(Zs(e,Vs.redirected)&&r===Wu||(a.ready=!0,a.readyErrorCbs.forEach((function(t){t(e)}))))}))},rp.prototype.confirmTransition=function(e,t,n){var i=this,a=this.current;this.pending=e;var r,o,u=function(e){!Zs(e)&&Xs(e)&&(i.errorCbs.length?i.errorCbs.forEach((function(t){t(e)})):console.error(e)),n&&n(e)},s=e.matched.length-1,p=a.matched.length-1;if(Hu(e,a)&&s===p&&e.matched[s]===a.matched[p])return this.ensureURL(),e.hash&&Es(this.router,a,e,!1),u(((o=Js(r=a,e,Vs.duplicated,'Avoided redundant navigation to current location: "'+r.fullPath+'".')).name="NavigationDuplicated",o));var l,d=function(e,t){var n,i=Math.max(e.length,t.length);for(n=0;n0)){var t=this.router,n=t.options.scrollBehavior,i=Gs&&n;i&&this.listeners.push(Ls());var a=function(){var n=e.current,a=pp(e.base);e.current===Wu&&a===e._startLocation||e.transitionTo(a,(function(e){i&&Es(t,e,n,!0)}))};window.addEventListener("popstate",a),this.listeners.push((function(){window.removeEventListener("popstate",a)}))}},t.prototype.go=function(e){window.history.go(e)},t.prototype.push=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){Qs(Zu(i.base+e.fullPath)),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){Hs(Zu(i.base+e.fullPath)),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.ensureURL=function(e){if(pp(this.base)!==this.current.fullPath){var t=Zu(this.base+this.current.fullPath);e?Qs(t):Hs(t)}},t.prototype.getCurrentLocation=function(){return pp(this.base)},t}(rp);function pp(e){var t=window.location.pathname,n=t.toLowerCase(),i=e.toLowerCase();return!e||n!==i&&0!==n.indexOf(Zu(i+"/"))||(t=t.slice(e.length)),(t||"/")+window.location.search+window.location.hash}var lp=function(e){function t(t,n,i){e.call(this,t,n),i&&function(e){var t=pp(e);if(!/^\/#/.test(t))return window.location.replace(Zu(e+"/#"+t)),!0}(this.base)||dp()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setupListeners=function(){var e=this;if(!(this.listeners.length>0)){var t=this.router.options.scrollBehavior,n=Gs&&t;n&&this.listeners.push(Ls());var i=function(){var t=e.current;dp()&&e.transitionTo(cp(),(function(i){n&&Es(e.router,i,t,!0),Gs||fp(i.fullPath)}))},a=Gs?"popstate":"hashchange";window.addEventListener(a,i),this.listeners.push((function(){window.removeEventListener(a,i)}))}},t.prototype.push=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){mp(e.fullPath),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this,a=this.current;this.transitionTo(e,(function(e){fp(e.fullPath),Es(i.router,e,a,!1),t&&t(e)}),n)},t.prototype.go=function(e){window.history.go(e)},t.prototype.ensureURL=function(e){var t=this.current.fullPath;cp()!==t&&(e?mp(t):fp(t))},t.prototype.getCurrentLocation=function(){return cp()},t}(rp);function dp(){var e=cp();return"/"===e.charAt(0)||(fp("/"+e),!1)}function cp(){var e=window.location.href,t=e.indexOf("#");return t<0?"":e=e.slice(t+1)}function yp(e){var t=window.location.href,n=t.indexOf("#");return(n>=0?t.slice(0,n):t)+"#"+e}function mp(e){Gs?Qs(yp(e)):window.location.hash=e}function fp(e){Gs?Hs(yp(e)):window.location.replace(yp(e))}var hp=function(e){function t(t,n){e.call(this,t,n),this.stack=[],this.index=-1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.push=function(e,t,n){var i=this;this.transitionTo(e,(function(e){i.stack=i.stack.slice(0,i.index+1).concat(e),i.index++,t&&t(e)}),n)},t.prototype.replace=function(e,t,n){var i=this;this.transitionTo(e,(function(e){i.stack=i.stack.slice(0,i.index).concat(e),t&&t(e)}),n)},t.prototype.go=function(e){var t=this,n=this.index+e;if(!(n<0||n>=this.stack.length)){var i=this.stack[n];this.confirmTransition(i,(function(){var e=t.current;t.index=n,t.updateRoute(i),t.router.afterHooks.forEach((function(t){t&&t(i,e)}))}),(function(e){Zs(e,Vs.duplicated)&&(t.index=n)}))}},t.prototype.getCurrentLocation=function(){var e=this.stack[this.stack.length-1];return e?e.fullPath:"/"},t.prototype.ensureURL=function(){},t}(rp),vp=function(e){void 0===e&&(e={}),this.app=null,this.apps=[],this.options=e,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=As(e.routes||[],this);var t=e.mode||"hash";switch(this.fallback="history"===t&&!Gs&&!1!==e.fallback,this.fallback&&(t="hash"),_s||(t="abstract"),this.mode=t,t){case"history":this.history=new sp(this,e.base);break;case"hash":this.history=new lp(this,e.base,this.fallback);break;case"abstract":this.history=new hp(this,e.base)}},gp={currentRoute:{configurable:!0}};vp.prototype.match=function(e,t,n){return this.matcher.match(e,t,n)},gp.currentRoute.get=function(){return this.history&&this.history.current},vp.prototype.init=function(e){var t=this;if(this.apps.push(e),e.$once("hook:destroyed",(function(){var n=t.apps.indexOf(e);n>-1&&t.apps.splice(n,1),t.app===e&&(t.app=t.apps[0]||null),t.app||t.history.teardown()})),!this.app){this.app=e;var n=this.history;if(n instanceof sp||n instanceof lp){var i=function(e){n.setupListeners(),function(e){var i=n.current,a=t.options.scrollBehavior;Gs&&a&&"fullPath"in e&&Es(t,e,i,!1)}(e)};n.transitionTo(n.getCurrentLocation(),i,i)}n.listen((function(e){t.apps.forEach((function(t){t._route=e}))}))}},vp.prototype.beforeEach=function(e){return Tp(this.beforeHooks,e)},vp.prototype.beforeResolve=function(e){return Tp(this.resolveHooks,e)},vp.prototype.afterEach=function(e){return Tp(this.afterHooks,e)},vp.prototype.onReady=function(e,t){this.history.onReady(e,t)},vp.prototype.onError=function(e){this.history.onError(e)},vp.prototype.push=function(e,t,n){var i=this;if(!t&&!n&&"undefined"!=typeof Promise)return new Promise((function(t,n){i.history.push(e,t,n)}));this.history.push(e,t,n)},vp.prototype.replace=function(e,t,n){var i=this;if(!t&&!n&&"undefined"!=typeof Promise)return new Promise((function(t,n){i.history.replace(e,t,n)}));this.history.replace(e,t,n)},vp.prototype.go=function(e){this.history.go(e)},vp.prototype.back=function(){this.go(-1)},vp.prototype.forward=function(){this.go(1)},vp.prototype.getMatchedComponents=function(e){var t=e?e.matched?e:this.resolve(e).route:this.currentRoute;return t?[].concat.apply([],t.matched.map((function(e){return Object.keys(e.components).map((function(t){return e.components[t]}))}))):[]},vp.prototype.resolve=function(e,t,n){var i=vs(e,t=t||this.history.current,n,this),a=this.match(i,t),r=a.redirectedFrom||a.fullPath,o=function(e,t,n){var i="hash"===n?"#"+t:t;return e?Zu(e+"/"+i):i}(this.history.base,r,this.mode);return{location:i,route:a,href:o,normalizedTo:i,resolved:a}},vp.prototype.getRoutes=function(){return this.matcher.getRoutes()},vp.prototype.addRoute=function(e,t){this.matcher.addRoute(e,t),this.history.current!==Wu&&this.history.transitionTo(this.history.getCurrentLocation())},vp.prototype.addRoutes=function(e){this.matcher.addRoutes(e),this.history.current!==Wu&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(vp.prototype,gp);var bp=vp;function Tp(e,t){return e.push(t),function(){var n=e.indexOf(t);n>-1&&e.splice(n,1)}}vp.install=function e(t){if(!e.installed||gs!==t){e.installed=!0,gs=t;var n=function(e){return void 0!==e},i=function(e,t){var i=e.$options._parentVnode;n(i)&&n(i=i.data)&&n(i=i.registerRouteInstance)&&i(e,t)};t.mixin({beforeCreate:function(){n(this.$options.router)?(this._routerRoot=this,this._router=this.$options.router,this._router.init(this),t.util.defineReactive(this,"_route",this._router.history.current)):this._routerRoot=this.$parent&&this.$parent._routerRoot||this,i(this,this)},destroyed:function(){i(this)}}),Object.defineProperty(t.prototype,"$router",{get:function(){return this._routerRoot._router}}),Object.defineProperty(t.prototype,"$route",{get:function(){return this._routerRoot._route}}),t.component("RouterView",Ju),t.component("RouterLink",Ts);var a=t.config.optionMergeStrategies;a.beforeRouteEnter=a.beforeRouteLeave=a.beforeRouteUpdate=a.created}},vp.version="3.6.5",vp.isNavigationFailure=Zs,vp.NavigationFailureType=Vs,vp.START_LOCATION=Wu,_s&&window.Vue&&window.Vue.use(vp);var wp=function(){var e=this._self._c;return e("div",{staticClass:"min-h-screen bg-gray-100 px-4 pt-6"},[e("router-view")],1)};function xp(e,t,n,i,a,r,o,u){var s,p="function"==typeof e?e.options:e;if(t&&(p.render=t,p.staticRenderFns=n,p._compiled=!0),i&&(p.functional=!0),r&&(p._scopeId="data-v-"+r),o?(s=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),a&&a.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(o)},p._ssrRegister=s):a&&(s=u?function(){a.call(this,(p.functional?this.parent:this).$root.$options.shadowRoot)}:a),s)if(p.functional){p._injectStyles=s;var l=p.render;p.render=function(e,t){return s.call(t),l(e,t)}}else{var d=p.beforeCreate;p.beforeCreate=d?[].concat(d,s):[s]}return{exports:e,options:p}}wp._withStripped=!0,n(838);const _p=xp({},wp,[],!1,null,null,null).exports;var Mp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full space-y-10 md:max-w-screen-sm lg:max-w-screen-md mx-auto"},[t("HeaderBar"),e._v(" "),t("div",{staticClass:"pb-32"},[t("div",{staticClass:"space-y-4"},[t("span",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.source)+"\n ")]),e._v(" "),t("h1",{staticClass:"text-xl"},[e._v("\n "+e._s(e.json.name)+"\n ")]),e._v(" "),t("h2",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.title)+"\n ")]),e._v(" "),t("h2",{staticClass:"text-lg"},[e._v("\n "+e._s(e.json.author)+"\n ")]),e._v(" "),t("p",[e._v(e._s(e.json.notice))]),e._v(" "),t("p",[e._v(e._s(e.json.details))])]),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.hasOwnProperty("constructor")?t("Member",{attrs:{json:e.json.constructor}}):e._e()],1),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.receive?t("Member",{attrs:{json:e.json.receive}}):e._e()],1),e._v(" "),t("div",{staticClass:"mt-8"},[e.json.fallback?t("Member",{attrs:{json:e.json.fallback}}):e._e()],1),e._v(" "),e.json.events?t("MemberSet",{attrs:{title:"Events",json:e.json.events}}):e._e(),e._v(" "),e.json.stateVariables?t("MemberSet",{attrs:{title:"State Variables",json:e.json.stateVariables}}):e._e(),e._v(" "),e.json.methods?t("MemberSet",{attrs:{title:"Methods",json:e.json.methods}}):e._e()],1),e._v(" "),t("FooterBar")],1)};Mp._withStripped=!0;var qp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"bg-gray-100 fixed bottom-0 right-0 w-full border-t border-dashed border-gray-300"},[t("div",{staticClass:"w-full text-center py-2 md:max-w-screen-sm lg:max-w-screen-md mx-auto"},[t("button",{staticClass:"py-1 px-2 text-gray-500",on:{click:function(t){return e.openLink(e.repository)}}},[e._v("\n built with "+e._s(e.name)+"\n ")])])])};qp._withStripped=!0;const kp=JSON.parse('{"u2":"hardhat-docgen","cj":"https://github.com/ItsNickBarry/hardhat-docgen"}'),Ap=xp({data:function(){return{repository:kp.cj,name:kp.u2}},methods:{openLink(e){window.open(e,"_blank")}}},qp,[],!1,null,null,null).exports;var Cp=function(){var e=this._self._c;return e("div",{staticClass:"w-full border-b border-dashed py-2 border-gray-300"},[e("router-link",{staticClass:"py-2 text-gray-500",attrs:{to:"/"}},[this._v("\n <- Go back\n ")])],1)};Cp._withStripped=!0;const Op=xp({},Cp,[],!1,null,null,null).exports;var Ip=function(){var e=this,t=e._self._c;return t("div",{staticClass:"border-2 border-gray-400 border-dashed w-full p-2"},[t("h3",{staticClass:"text-lg pb-2 mb-2 border-b-2 border-gray-400 border-dashed"},[e._v("\n "+e._s(e.name)+" "+e._s(e.keywords)+" "+e._s(e.inputSignature)+"\n ")]),e._v(" "),t("div",{staticClass:"space-y-3"},[t("p",[e._v(e._s(e.json.notice))]),e._v(" "),t("p",[e._v(e._s(e.json.details))]),e._v(" "),t("MemberSection",{attrs:{name:"Parameters",items:e.inputs}}),e._v(" "),t("MemberSection",{attrs:{name:"Return Values",items:e.outputs}})],1)])};Ip._withStripped=!0;var Fp=function(){var e=this,t=e._self._c;return e.items.length>0?t("ul",[t("h4",{staticClass:"text-lg"},[e._v("\n "+e._s(e.name)+"\n ")]),e._v(" "),e._l(e.items,(function(n,i){return t("li",{key:i},[t("span",{staticClass:"bg-gray-300"},[e._v(e._s(n.type))]),e._v(" "),t("b",[e._v(e._s(n.name||`_${i}`))]),n.desc?t("span",[e._v(": "),t("i",[e._v(e._s(n.desc))])]):e._e()])}))],2):e._e()};Fp._withStripped=!0;const Sp={components:{MemberSection:xp({props:{name:{type:String,default:""},items:{type:Array,default:()=>new Array}}},Fp,[],!1,null,null,null).exports},props:{json:{type:Object,default:()=>new Object}},computed:{name:function(){return this.json.name||this.json.type},keywords:function(){let e=[];return this.json.stateMutability&&e.push(this.json.stateMutability),"true"===this.json.anonymous&&e.push("anonymous"),e.join(" ")},params:function(){return this.json.params||{}},returns:function(){return this.json.returns||{}},inputs:function(){return(this.json.inputs||[]).map((e=>({...e,desc:this.params[e.name]})))},inputSignature:function(){return`(${this.inputs.map((e=>e.type)).join(",")})`},outputs:function(){return(this.json.outputs||[]).map(((e,t)=>({...e,desc:this.returns[e.name||`_${t}`]})))},outputSignature:function(){return`(${this.outputs.map((e=>e.type)).join(",")})`}}},Pp=xp(Sp,Ip,[],!1,null,null,null).exports;var Rp=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full mt-8"},[t("h2",{staticClass:"text-lg"},[e._v(e._s(e.title))]),e._v(" "),e._l(Object.keys(e.json),(function(n){return t("Member",{key:n,staticClass:"mt-3",attrs:{json:e.json[n]}})}))],2)};Rp._withStripped=!0;var Lp=xp({components:{Member:Pp},props:{title:{type:String,default:""},json:{type:Object,default:()=>new Object}}},Rp,[],!1,null,null,null);const Ep=xp({components:{Member:Pp,MemberSet:Lp.exports,HeaderBar:Op,FooterBar:Ap},props:{json:{type:Object,default:()=>new Object}}},Mp,[],!1,null,null,null).exports;var $p=function(){var e=this,t=e._self._c;return t("div",{staticClass:"w-full space-y-10 md:max-w-screen-sm lg:max-w-screen-md mx-auto pb-32"},[t("Branch",{attrs:{json:e.trees,name:"Sources:"}}),e._v(" "),t("FooterBar",{staticClass:"mt-20"})],1)};$p._withStripped=!0;var Bp=function(){var e=this,t=e._self._c;return t("div",[e._v("\n "+e._s(e.name)+"\n "),Array.isArray(e.json)?t("div",{staticClass:"pl-5"},e._l(e.json,(function(n,i){return t("div",{key:i},[t("router-link",{attrs:{to:`${n.source}:${n.name}`}},[e._v("\n "+e._s(n.name)+"\n ")])],1)})),0):t("div",{staticClass:"pl-5"},e._l(Object.keys(e.json),(function(n){return t("div",{key:n},[t("Branch",{attrs:{json:e.json[n],name:n}})],1)})),0)])};Bp._withStripped=!0;var jp=xp({name:"Branch",props:{name:{type:String,default:null},json:{type:[Object,Array],default:()=>new Object}}},Bp,[],!1,null,null,null);const Np=xp({components:{Branch:jp.exports,FooterBar:Ap},props:{json:{type:Object,default:()=>new Object}},computed:{trees:function(){let e={};for(let t in this.json)t.replace("/","//").split(/\/(?=[^\/])/).reduce(function(e,n){if(!n.includes(":"))return e[n]=e[n]||{},e[n];{let[i]=n.split(":");e[i]=e[i]||[],e[i].push(this.json[t])}}.bind(this),e);return e}}},$p,[],!1,null,null,null).exports;Qn.use(bp);const Dp={"contracts/MatchingEngineAMM.sol:MatchingEngineAMM":{source:"contracts/MatchingEngineAMM.sol",name:"MatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the pip want to calculate",quantity:"the size of base amount"},notice:"implement calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"counterParties(address)":{inputs:[{internalType:"address",name:"",type:"address"}],name:"counterParties",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"The current pip of pair"},notice:"get current pip"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"initialize the sub contract, approve contract",notice:"initialize the contract right after deployonly call once time"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"rangeFindingWordsAmm()":{inputs:[],name:"rangeFindingWordsAmm",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/implement/AutoMarketMakerCore.sol:AutoMarketMakerCore":{source:"contracts/implement/AutoMarketMakerCore.sol",name:"AutoMarketMakerCore",methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function to get current pip"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"}}},"contracts/implement/Block.sol:Block":{source:"contracts/implement/Block.sol",name:"Block"},"contracts/implement/MatchingEngineCore.sol:MatchingEngineCore":{source:"contracts/implement/MatchingEngineCore.sol",name:"MatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"hook function calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get currnet pip"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/interfaces/IAutoMarketMakerCore.sol:IAutoMarketMakerCore":{source:"contracts/interfaces/IAutoMarketMakerCore.sol",name:"IAutoMarketMakerCore",methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load current current index pip range from storage",returns:{_0:"the current index pip range"},notice:"get current index pip range"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"index",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",details:"load data from storage and return",params:{index:"want to get info"},returns:{baseReal:"base real of liquidity of index",feeGrowthBase:"the growth of base",feeGrowthQuote:"the growth of base",indexedPipRange:"index of liquidity info",quoteReal:"quote real of liquidity of index",sqrtK:"sqrt of k=quoteReal*baseReal,",sqrtMaxPip:"sqrt of max pip",sqrtMinPip:"sqrt of min pip"},notice:"get liquidity info of any index pip range"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",details:"load current index pip range from storage",returns:{_0:"The current pip range"},notice:"get current index pip range"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load current tick space from storage",returns:{_0:"the config tick space"},notice:"get the tick space for external generate orderbook"}}},"contracts/interfaces/IFee.sol:IFee":{source:"contracts/interfaces/IFee.sol",name:"IFee",methods:{"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"baseFeeFunding",type:"uint256"},{internalType:"uint256",name:"quoteFeeFunding",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{baseFeeFunding:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"}}},"contracts/interfaces/IGetFeeShareAMM.sol:IGetFeeShareAMM":{source:"contracts/interfaces/IGetFeeShareAMM.sol",name:"IGetFeeShareAMM",methods:{"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",returns:{_0:"the rate share"},notice:"fee share for liquidity provider"},"feeShareAmmWithPair(address)":{inputs:[{internalType:"address",name:"pairManager",type:"address"}],name:"feeShareAmmWithPair",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",params:{pairManager:"the address of pair want to know the pai"},returns:{_0:"the rate share"},notice:"fee share for liquidity provider"}}},"contracts/interfaces/IMatchingEngineAMM.sol:IMatchingEngineAMM":{source:"contracts/interfaces/IMatchingEngineAMM.sol",name:"IMatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load current current index pip range from storage",returns:{_0:"the current index pip range"},notice:"get current index pip range"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"baseFeeFunding",type:"uint256"},{internalType:"uint256",name:"quoteFeeFunding",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{baseFeeFunding:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"save storage the init data",params:{params:"the init params with struct InitParams"},notice:"init the pair right after cloned"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"index",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",details:"load data from storage and return",params:{index:"want to get info"},returns:{baseReal:"base real of liquidity of index",feeGrowthBase:"the growth of base",feeGrowthQuote:"the growth of base",indexedPipRange:"index of liquidity info",quoteReal:"quote real of liquidity of index",sqrtK:"sqrt of k=quoteReal*baseReal,",sqrtMaxPip:"sqrt of max pip",sqrtMinPip:"sqrt of min pip"},notice:"get liquidity info of any index pip range"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",details:"load current index pip range from storage",returns:{_0:"The current pip range"},notice:"get current index pip range"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load current tick space from storage",returns:{_0:"the config tick space"},notice:"get the tick space for external generate orderbook"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/interfaces/IMatchingEngineCore.sol:IMatchingEngineCore":{source:"contracts/interfaces/IMatchingEngineCore.sol",name:"IMatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",params:{isBuy:"fill start pip",orderId:"id of order cancel",pip:"of order",size:"size of order"},notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",params:{isBuy:"fill start pip",orderId:"side of order",pip:"amount filled",size:"fill to pip"},notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",params:{orderId:"id of order",pairManager:"address of pair",pip:"at order",size:"of order"},notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",params:{amount:"amount filled",filledIndex:"number of index filled",isBuy:"side of order",remainingLiquidity:"remaining liquidity in pip",startPip:"fill start pip",toPip:"fill to pip"},notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",params:{newMaxWordRangeForLimitOrder:"new value"},notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",params:{newMaxWordRangeForMarketOrder:"new value"},notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",params:{pip:"pip snap shot",timestamp:"time snap shot"},notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",params:{amount0In:"amount 0 int",amount0Out:"amount 0 out",amount1In:"amount 1 in",amount1Out:"amount 1 out",sender:"address of trader",to:"swap for address"},notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",params:{newMaxFindingWordsIndex:"new value",pairManager:"address of pair"},notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/libraries/amm/CrossPipResult.sol:CrossPipResult":{source:"contracts/libraries/amm/CrossPipResult.sol",name:"CrossPipResult"},"contracts/libraries/amm/Liquidity.sol:Liquidity":{source:"contracts/libraries/amm/Liquidity.sol",name:"Liquidity"},"contracts/libraries/amm/LiquidityMath.sol:LiquidityMath":{source:"contracts/libraries/amm/LiquidityMath.sol",name:"LiquidityMath",title:"All formulas used in the AMM"},"contracts/libraries/exchange/BitMath.sol:BitMath":{source:"contracts/libraries/exchange/BitMath.sol",name:"BitMath",title:"BitMath",details:"This libraries provides functionality for computing bit properties of an unsigned integer"},"contracts/libraries/exchange/LimitOrder.sol:LimitOrder":{source:"contracts/libraries/exchange/LimitOrder.sol",name:"LimitOrder"},"contracts/libraries/exchange/LiquidityBitmap.sol:LiquidityBitmap":{source:"contracts/libraries/exchange/LiquidityBitmap.sol",name:"LiquidityBitmap",methods:{"MAX_UINT256()":{inputs:[],name:"MAX_UINT256",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}}},"contracts/libraries/exchange/SwapState.sol:SwapState":{source:"contracts/libraries/exchange/SwapState.sol",name:"SwapState"},"contracts/libraries/exchange/TickPosition.sol:TickPosition":{source:"contracts/libraries/exchange/TickPosition.sol",name:"TickPosition"},"contracts/libraries/extensions/Fee.sol:Fee":{source:"contracts/libraries/extensions/Fee.sol",name:"Fee",methods:{"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"}}},"contracts/libraries/extensions/ReserveSnapshots.sol:ReserveSnapshots":{source:"contracts/libraries/extensions/ReserveSnapshots.sol",name:"ReserveSnapshots",events:{"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event"}},methods:{"reserveSnapshots(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"reserveSnapshots",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"timestamp",type:"uint64"},{internalType:"uint64",name:"blockNumber",type:"uint64"}],stateMutability:"view",type:"function"}}},"contracts/libraries/helper/Convert.sol:Convert":{source:"contracts/libraries/helper/Convert.sol",name:"Convert"},"contracts/libraries/helper/Errors.sol:Errors":{source:"contracts/libraries/helper/Errors.sol",name:"Errors",notice:"Mapping error code to error message",methods:{"ME_INITIALIZED()":{inputs:[],name:"ME_INITIALIZED",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_INPUT()":{inputs:[],name:"ME_INVALID_INPUT",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_LEVERAGE()":{inputs:[],name:"ME_INVALID_LEVERAGE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_INVALID_SIZE()":{inputs:[],name:"ME_INVALID_SIZE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_LIMIT_OVER_PRICE_NOT_ENOUGH_LIQUIDITY()":{inputs:[],name:"ME_LIMIT_OVER_PRICE_NOT_ENOUGH_LIQUIDITY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MARKET_ORDER_MUST_CLOSE_TO_INDEX_PRICE()":{inputs:[],name:"ME_MARKET_ORDER_MUST_CLOSE_TO_INDEX_PRICE",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MUST_CLOSE_TO_INDEX_PRICE_BUY()":{inputs:[],name:"ME_MUST_CLOSE_TO_INDEX_PRICE_BUY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_MUST_CLOSE_TO_INDEX_PRICE_SELL()":{inputs:[],name:"ME_MUST_CLOSE_TO_INDEX_PRICE_SELL",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_NOT_ENOUGH_LIQUIDITY()":{inputs:[],name:"ME_NOT_ENOUGH_LIQUIDITY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_NOT_PASS_MARKET_MARKER()":{inputs:[],name:"ME_NOT_PASS_MARKET_MARKER",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_ONLY_COUNTERPARTY()":{inputs:[],name:"ME_ONLY_COUNTERPARTY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_ONLY_PENDING_ORDER()":{inputs:[],name:"ME_ONLY_PENDING_ORDER",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},"ME_SETTLE_FUNDING_TOO_EARLY()":{inputs:[],name:"ME_SETTLE_FUNDING_TOO_EARLY",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"}}},"contracts/libraries/helper/FixedPoint128.sol:FixedPoint128":{source:"contracts/libraries/helper/FixedPoint128.sol",name:"FixedPoint128",title:"FixedPoint128",notice:"A library for handling binary fixed point numbers, see https://en.wikipedia.org/wiki/Q_(number_format)"},"contracts/libraries/helper/Math.sol:Math":{source:"contracts/libraries/helper/Math.sol",name:"Math"},"contracts/libraries/helper/Require.sol:Require":{source:"contracts/libraries/helper/Require.sol",name:"Require",notice:"this library is used to reduce size contract when require condition"},"contracts/libraries/helper/TradeConvert.sol:TradeConvert":{source:"contracts/libraries/helper/TradeConvert.sol",name:"TradeConvert"},"contracts/libraries/helper/TransferHelper.sol:TransferHelper":{source:"contracts/libraries/helper/TransferHelper.sol",name:"TransferHelper"},"contracts/libraries/helper/U128Math.sol:U128Math":{source:"contracts/libraries/helper/U128Math.sol",name:"U128Math"},"contracts/libraries/types/AMMCoreStorage.sol:AMMCoreStorage":{source:"contracts/libraries/types/AMMCoreStorage.sol",name:"AMMCoreStorage",stateVariables:{"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"stateVariable",details:"load current current index pip range from storage",return:"the current index pip range",returns:{_0:"the current index pip range"},notice:"the current index pip active"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"stateVariable",details:"load current index pip range from storage",return:"The current pip range",returns:{_0:"The current pip range"},notice:"the range of liquidity"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"stateVariable",return:"the config fee",returns:{_0:"the config fee"},notice:"get spot factory"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"stateVariable",details:"load current tick space from storage",return:"the config tick space",returns:{_0:"the config tick space"},notice:"the tick space of external bulid order book"}},methods:{"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{baseAmount:"base amount receive",liquidityInfo:"newest of liquidity info",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"}}},"contracts/libraries/types/MatchingEngineCoreStorage.sol:MatchingEngineCoreStorage":{source:"contracts/libraries/types/MatchingEngineCoreStorage.sol",name:"MatchingEngineCoreStorage",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},stateVariables:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"stateVariable",return:"the basis point of pair",returns:{_0:"the basis point of pair"},notice:"Get basis point of pair"}},methods:{"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"return the current price"},notice:"Get current price"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/LiquidityBitmapTest.sol:LiquidityBitmapTest":{source:"contracts/test/LiquidityBitmapTest.sol",name:"LiquidityBitmapTest",events:{"GasUse(uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"gas",type:"uint256"}],name:"GasUse",type:"event"}},methods:{"findHasLiquidityInMultipleWords(uint128,uint128,bool)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"maxWords",type:"uint128"},{internalType:"bool",name:"lte",type:"bool"}],name:"findHasLiquidityInMultipleWords",outputs:[{internalType:"uint128",name:"next",type:"uint128"}],stateMutability:"view",type:"function"},"findNextInitializedLiquidity(uint128,bool)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"bool",name:"lte",type:"bool"}],name:"findNextInitializedLiquidity",outputs:[{internalType:"uint128",name:"next",type:"uint128"}],stateMutability:"view",type:"function"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"setBitsInRange(uint128,uint128)":{inputs:[{internalType:"uint128",name:"startPip",type:"uint128"},{internalType:"uint128",name:"toPip",type:"uint128"}],name:"setBitsInRange",outputs:[],stateMutability:"nonpayable",type:"function"},"toggleSingleBit(uint128,bool)":{inputs:[{internalType:"uint128",name:"bit",type:"uint128"},{internalType:"bool",name:"isSet",type:"bool"}],name:"toggleSingleBit",outputs:[],stateMutability:"nonpayable",type:"function"},"unsetBitsRange(uint128,uint128)":{inputs:[{internalType:"uint128",name:"startPip",type:"uint128"},{internalType:"uint128",name:"toPip",type:"uint128"}],name:"unsetBitsRange",outputs:[],stateMutability:"nonpayable",type:"function"}}},"contracts/test/LiquidityMathTest.sol:LiquidityMathTest":{source:"contracts/test/LiquidityMathTest.sol",name:"LiquidityMathTest",methods:{"CURVE_PIP()":{inputs:[],name:"CURVE_PIP",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseByLiquidity(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint128",name:"sqrtPriceMax",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"}],name:"calculateBaseByLiquidity",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseReal(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"maxPip",type:"uint128"},{internalType:"uint128",name:"xVirtual",type:"uint128"},{internalType:"uint128",name:"currentPrice",type:"uint128"}],name:"calculateBaseReal",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseWithPriceWhenBuy(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateBaseWithPriceWhenBuy",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateBaseWithPriceWhenSell(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateBaseWithPriceWhenSell",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateLiquidity(uint128,uint128,bool)":{inputs:[{internalType:"uint128",name:"amountReal",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"},{internalType:"bool",name:"isBase",type:"bool"}],name:"calculateLiquidity",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"calculateQuoteByLiquidity(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint128",name:"sqrtPriceMin",type:"uint128"},{internalType:"uint128",name:"sqrtPrice",type:"uint128"}],name:"calculateQuoteByLiquidity",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateQuoteReal(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"yVirtual",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteReal",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"calculateQuoteWithPriceWhenBuy(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteWithPriceWhenBuy",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"calculateQuoteWithPriceWhenSell(uint128,uint128,uint128)":{inputs:[{internalType:"uint128",name:"sqrtPriceTarget",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"sqrtCurrentPrice",type:"uint128"}],name:"calculateQuoteWithPriceWhenSell",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"}}},"contracts/test/MockMatchingEngineAMM.sol:MockMatchingEngineAMM":{source:"contracts/test/MockMatchingEngineAMM.sol",name:"MockMatchingEngineAMM",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"accumulateClaimableAmount(uint128,uint64,(uint256,uint256,uint256,uint256),uint256,uint16,uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"},{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"exData",type:"tuple"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint16",name:"fee",type:"uint16"},{internalType:"uint128",name:"feeBasis",type:"uint128"}],name:"accumulateClaimableAmount",outputs:[{components:[{internalType:"uint256",name:"baseAmount",type:"uint256"},{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint256",name:"feeQuoteAmount",type:"uint256"},{internalType:"uint256",name:"feeBaseAmount",type:"uint256"}],internalType:"struct IMatchingEngineAMM.ExchangedData",name:"",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate the base and quote from order and pip",params:{basisPoint:"the basis point of price",exData:"the base amount",fee:"the fee percent",feeBasis:"the basis fee froe calculate",orderId:"id of order in pip",pip:"the pip of the order"},returns:{_0:"the Exchanged data"},notice:"get the base and quote amount can claim"},"addLiquidity((uint128,uint128,uint32))":{inputs:[{components:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"}],internalType:"struct IAutoMarketMakerCore.AddLiquidity",name:"params",type:"tuple"}],name:"addLiquidity",outputs:[{internalType:"uint128",name:"baseAmountAdded",type:"uint128"},{internalType:"uint128",name:"quoteAmountAdded",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Depends on data struct with base amount, quote amount and index pip calculate the liquidity and increase liquidity at index pip",params:{params:"Struct AddLiquidity"},returns:{baseAmountAdded:"the base amount will be added",feeGrowthBase:"tracking growth base",feeGrowthQuote:"tracking growth quote",liquidity:"calculate from quote and base amount",quoteAmountAdded:"the quote amount will be added"},notice:"Add liquidity and mint the NFT"},"baseAsset()":{inputs:[],name:"baseAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the pip want to calculate",quantity:"the size of base amount"},notice:"implement calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"counterParties(address)":{inputs:[{internalType:"address",name:"",type:"address"}],name:"counterParties",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},"currentIndexedPipRange()":{inputs:[],name:"currentIndexedPipRange",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"the current index pip active"},"decreaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"decreaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee base funding",params:{baseFee:"will be decreased"},notice:"decrease the fee base"},"decreaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"decreaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"minus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"decrease the fee quote"},"estimateRemoveLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"estimateRemoveLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"},{components:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],internalType:"struct Liquidity.Info",name:"_liquidityInfo",type:"tuple"}],stateMutability:"view",type:"function",details:"calculate amount of quote and base",params:{params:"struct Remove liquidity"},returns:{_liquidityInfo:"newest of liquidity info",baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"estimate amount receive when remove liquidity in index pip"},"feeShareAmm()":{inputs:[],name:"feeShareAmm",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",details:"load config fee from storage",returns:{_0:"the config fee"},notice:"get percent fee will be share when market order fill"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"The current pip of pair"},notice:"get current pip"},"getFee()":{inputs:[],name:"getFee",outputs:[{internalType:"uint256",name:"",type:"uint256"},{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"load amount quote and base",returns:{_0:"and quoteFeeFunding"},notice:"get the fee base funding and fee quote funding"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"increaseBaseFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"}],name:"increaseBaseFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee base funding",params:{baseFee:"will be decreased"},notice:"increase the fee base"},"increaseQuoteFeeFunding(uint256)":{inputs:[{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"increaseQuoteFeeFunding",outputs:[],stateMutability:"nonpayable",type:"function",details:"plus the fee quote funding",params:{quoteFee:"will be decreased"},notice:"increase the fee quote`"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function",details:"initialize the sub contract, approve contract",notice:"initialize the contract right after deployonly call once time"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"liquidityInfo(uint256)":{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"liquidityInfo",outputs:[{internalType:"uint128",name:"sqrtMaxPip",type:"uint128"},{internalType:"uint128",name:"sqrtMinPip",type:"uint128"},{internalType:"uint128",name:"quoteReal",type:"uint128"},{internalType:"uint128",name:"baseReal",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"},{internalType:"uint128",name:"sqrtK",type:"uint128"}],stateMutability:"view",type:"function",notice:"the mapping with index and the liquidity of index"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"pipRange()":{inputs:[],name:"pipRange",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"the range of liquidity"},"quoteAsset()":{inputs:[],name:"quoteAsset",outputs:[{internalType:"contract IERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"rangeFindingWordsAmm()":{inputs:[],name:"rangeFindingWordsAmm",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"removeLiquidity((uint128,uint32,uint256,uint256))":{inputs:[{components:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint32",name:"indexedPipRange",type:"uint32"},{internalType:"uint256",name:"feeGrowthBase",type:"uint256"},{internalType:"uint256",name:"feeGrowthQuote",type:"uint256"}],internalType:"struct IAutoMarketMakerCore.RemoveLiquidity",name:"params",type:"tuple"}],name:"removeLiquidity",outputs:[{internalType:"uint128",name:"baseAmount",type:"uint128"},{internalType:"uint128",name:"quoteAmount",type:"uint128"}],stateMutability:"nonpayable",type:"function",details:"remove liquidity at index pip and decrease the data of liquidity info",params:{params:"Struct Remove liquidity"},returns:{baseAmount:"base amount receive",quoteAmount:"quote amount receive"},notice:"Remove liquidity in index pip of nft"},"resetFee(uint256,uint256)":{inputs:[{internalType:"uint256",name:"baseFee",type:"uint256"},{internalType:"uint256",name:"quoteFee",type:"uint256"}],name:"resetFee",outputs:[],stateMutability:"nonpayable",type:"function",details:"reset baseFee and quoteFee to zero",params:{baseFee:"will be decreased",quoteFee:"will be decreased"},notice:"reset the fee funding to zero when Position claim fee"},"setCounterParty()":{inputs:[],name:"setCounterParty",outputs:[],stateMutability:"nonpayable",type:"function"},"setCurrentPip(uint128)":{inputs:[{internalType:"uint128",name:"currentPip",type:"uint128"}],name:"setCurrentPip",outputs:[],stateMutability:"nonpayable",type:"function"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"spotFactory()":{inputs:[],name:"spotFactory",outputs:[{internalType:"contract IGetFeeShareAMM",name:"",type:"address"}],stateMutability:"view",type:"function",notice:"get spot factory"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"tickSpace()":{inputs:[],name:"tickSpace",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function",notice:"the tick space of external bulid order book"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/MockMatchingEngineCore.sol:MockMatchingEngineCore":{source:"contracts/test/MockMatchingEngineCore.sol",name:"MockMatchingEngineCore",events:{"LimitOrderCancelled(bool,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderCancelled",type:"event",notice:"Emitted limit order cancel"},"LimitOrderCreated(uint64,uint128,uint128,bool)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint128",name:"size",type:"uint128"},{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"}],name:"LimitOrderCreated",type:"event",notice:"Emitted when market order filled"},"LimitOrderUpdated(address,uint64,uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint64",name:"orderId",type:"uint64"},{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"size",type:"uint256"}],name:"LimitOrderUpdated",type:"event",notice:"Emitted when limit order updated"},"MarketFilled(bool,uint256,uint128,uint256,uint128,uint64)":{anonymous:!1,inputs:[{indexed:!1,internalType:"bool",name:"isBuy",type:"bool"},{indexed:!0,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"uint128",name:"toPip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"startPip",type:"uint256"},{indexed:!1,internalType:"uint128",name:"remainingLiquidity",type:"uint128"},{indexed:!1,internalType:"uint64",name:"filledIndex",type:"uint64"}],name:"MarketFilled",type:"event",notice:"Emitted when market order filled"},"MaxWordRangeForLimitOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForLimitOrder",type:"uint128"}],name:"MaxWordRangeForLimitOrderUpdated",type:"event",notice:"Emitted when update max finding word for limit order"},"MaxWordRangeForMarketOrderUpdated(uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"newMaxWordRangeForMarketOrder",type:"uint128"}],name:"MaxWordRangeForMarketOrderUpdated",type:"event",notice:"Emitted when update max finding word for market order"},"ReserveSnapshotted(uint128,uint256)":{anonymous:!1,inputs:[{indexed:!1,internalType:"uint128",name:"pip",type:"uint128"},{indexed:!1,internalType:"uint256",name:"timestamp",type:"uint256"}],name:"ReserveSnapshotted",type:"event",notice:"Emitted when snap shot reserve"},"Swap(address,uint256,uint256,uint256,uint256,address)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"sender",type:"address"},{indexed:!1,internalType:"uint256",name:"amount0In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1In",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount0Out",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount1Out",type:"uint256"},{indexed:!0,internalType:"address",name:"to",type:"address"}],name:"Swap",type:"event",notice:"Emitted when order fill for swap"},"UpdateMaxFindingWordsIndex(address,uint128)":{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"pairManager",type:"address"},{indexed:!1,internalType:"uint128",name:"newMaxFindingWordsIndex",type:"uint128"}],name:"UpdateMaxFindingWordsIndex",type:"event",notice:"Emitted when update max finding word"}},methods:{"basisPoint()":{inputs:[],name:"basisPoint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"Get basis point of pair"},"calculatingQuoteAmount(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quantity",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"calculatingQuoteAmount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",notice:"hook function calculate quote amount"},"cancelLimitOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"cancelLimitOrder",outputs:[{internalType:"uint256",name:"remainingSize",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Cancel the limit order"},"getCurrentPip()":{inputs:[],name:"getCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get currnet pip"},"getLiquidityInCurrentPip()":{inputs:[],name:"getLiquidityInCurrentPip",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",returns:{_0:"the amount liquidity pending"},notice:"Get amount liquidity pending at current price"},"getLiquidityInPipRange(uint128,uint256,bool)":{inputs:[{internalType:"uint128",name:"fromPip",type:"uint128"},{internalType:"uint256",name:"dataLength",type:"uint256"},{internalType:"bool",name:"toHigher",type:"bool"}],name:"getLiquidityInPipRange",outputs:[{components:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint256",name:"liquidity",type:"uint256"}],internalType:"struct IMatchingEngineCore.LiquidityOfEachPip[]",name:"",type:"tuple[]"},{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function",notice:"hook function get liquidity in pip range"},"getPendingOrderDetail(uint128,uint64)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint64",name:"orderId",type:"uint64"}],name:"getPendingOrderDetail",outputs:[{internalType:"bool",name:"isFilled",type:"bool"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"partialFilled",type:"uint256"}],stateMutability:"view",type:"function",details:"Load pending order and calculate the amount of base and quote asset",params:{orderId:"id of order in pip",pip:"the price of order"},returns:{isBuy:"the side of the order",isFilled:"the order is filled",partialFilled:"the amount partial order is filled",size:"the size of order"},notice:"Get detail pending order"},"hasLiquidity(uint128)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"}],name:"hasLiquidity",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function",details:"load and check flag of liquidity",params:{pip:"the price of order"},returns:{_0:"the bool of has liquidity"},notice:"check at this pip has liquidity"},"initialize((address,address,uint256,uint128,uint128,uint128,uint32,address,address,address))":{inputs:[{components:[{internalType:"contract IERC20",name:"quoteAsset",type:"address"},{internalType:"contract IERC20",name:"baseAsset",type:"address"},{internalType:"uint256",name:"basisPoint",type:"uint256"},{internalType:"uint128",name:"maxFindingWordsIndex",type:"uint128"},{internalType:"uint128",name:"initialPip",type:"uint128"},{internalType:"uint128",name:"pipRange",type:"uint128"},{internalType:"uint32",name:"tickSpace",type:"uint32"},{internalType:"address",name:"positionLiquidity",type:"address"},{internalType:"address",name:"spotHouse",type:"address"},{internalType:"address",name:"router",type:"address"}],internalType:"struct IMatchingEngineAMM.InitParams",name:"params",type:"tuple"}],name:"initialize",outputs:[],stateMutability:"nonpayable",type:"function"},"liquidityBitmap(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"liquidityBitmap",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},"maxFindingWordsIndex()":{inputs:[],name:"maxFindingWordsIndex",outputs:[{internalType:"uint128",name:"",type:"uint128"}],stateMutability:"view",type:"function"},"openLimit(uint128,uint128,bool,address,uint256,uint16)":{inputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint128",name:"baseAmountIn",type:"uint128"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint256",name:"quoteAmountIn",type:"uint256"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openLimit",outputs:[{internalType:"uint64",name:"orderId",type:"uint64"},{internalType:"uint256",name:"baseAmountFilled",type:"uint256"},{internalType:"uint256",name:"quoteAmountFilled",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate the order in insert to queue",params:{baseAmountIn:"amount of base asset",feePercent:"fee of the order",isBuy:"side of the limit order",pip:"the price of order",quoteAmountIn:"amount of quote asset",trader:"the owner of the limit order"},returns:{baseAmountFilled:"when can fill market amount has filled",fee:"when can fill market amount has filled",orderId:"id of order in pip",quoteAmountFilled:"when can fill market amount has filled"},notice:"Open limit order with size and price"},"openMarket(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarket",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",size:"the amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"openMarketWithQuoteAsset(uint256,bool,address,uint16)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"bool",name:"isBuy",type:"bool"},{internalType:"address",name:"trader",type:"address"},{internalType:"uint16",name:"feePercent",type:"uint16"}],name:"openMarketWithQuoteAsset",outputs:[{internalType:"uint256",name:"mainSideOut",type:"uint256"},{internalType:"uint256",name:"flipSideOut",type:"uint256"},{internalType:"uint256",name:"fee",type:"uint256"}],stateMutability:"nonpayable",type:"function",details:"Calculate full the market order with limit order in queue",params:{feePercent:"fee of the order",isBuy:"the side of market order",quoteAmount:"the quote amount want to open market order",trader:"the owner of the market order"},returns:{fee:"the amount of fee",flipSideOut:"the amount fill of main asset convert to flip asset",mainSideOut:"the amount fill of main asset"},notice:"Open market order with size is base and price"},"quoteToBase(uint256,uint128)":{inputs:[{internalType:"uint256",name:"quoteAmount",type:"uint256"},{internalType:"uint128",name:"pip",type:"uint128"}],name:"quoteToBase",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",params:{pip:"the price",quoteAmount:"the quote amount"},returns:{_0:"the base converted"},notice:"Calculate the amount of quote asset"},"singleSlot()":{inputs:[],name:"singleSlot",outputs:[{internalType:"uint128",name:"pip",type:"uint128"},{internalType:"uint8",name:"isFullBuy",type:"uint8"}],stateMutability:"view",type:"function"},"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"},"updatePartialFilledOrder(uint128,uint64)":{inputs:[{internalType:"uint128",name:"_pip",type:"uint128"},{internalType:"uint64",name:"_orderId",type:"uint64"}],name:"updatePartialFilledOrder",outputs:[],stateMutability:"nonpayable",type:"function",params:{orderId:"id of order in pip",pip:"the price of order"},notice:"Update the order when partial fill"}}},"contracts/test/MockReflexToken.sol:MockReflexToken":{source:"contracts/test/MockReflexToken.sol",name:"MockReflexToken",constructor:{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"}},methods:{"allowance(address,address)":{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-allowance}."},"approve(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Sets `amount` as the allowance of `spender` over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event."},"balanceOf(address)":{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-balanceOf}."},"decimals()":{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function",details:"Returns the decimals places of the token."},"decreaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"subtractedValue",type:"uint256"}],name:"decreaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},"increaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"addedValue",type:"uint256"}],name:"increaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},"mint(address,uint256)":{inputs:[{internalType:"address",name:"recipient",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},"name()":{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the name of the token."},"symbol()":{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the symbol of the token, usually a shorter version of the name."},"totalSupply()":{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-totalSupply}."},"transfer(address,uint256)":{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Moves `amount` tokens from the caller's account to `to`. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event."},"transferFrom(address,address,uint256)":{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Moves `amount` tokens from `from` to `to` using the allowance mechanism. `amount` is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event."}}},"contracts/test/MockToken.sol:MockToken":{source:"contracts/test/MockToken.sol",name:"MockToken",constructor:{inputs:[{internalType:"string",name:"name",type:"string"},{internalType:"string",name:"symbol",type:"string"}],stateMutability:"nonpayable",type:"constructor"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"}},methods:{"allowance(address,address)":{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-allowance}."},"approve(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-approve}. NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on `transferFrom`. This is semantically equivalent to an infinite approval. Requirements: - `spender` cannot be the zero address."},"balanceOf(address)":{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-balanceOf}."},"decimals()":{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function",details:"Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5.05` (`505 / 10 ** 2`). Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. This is the value {ERC20} uses, unless this function is overridden; NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}."},"decreaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"subtractedValue",type:"uint256"}],name:"decreaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Atomically decreases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`."},"increaseAllowance(address,uint256)":{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"addedValue",type:"uint256"}],name:"increaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"Atomically increases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address."},"mint(address,uint256)":{inputs:[{internalType:"address",name:"recipient",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},"name()":{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the name of the token."},"owner()":{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},"setOwner(address)":{inputs:[{internalType:"address",name:"_owner",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},"symbol()":{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function",details:"Returns the symbol of the token, usually a shorter version of the name."},"totalSupply()":{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function",details:"See {IERC20-totalSupply}."},"transfer(address,uint256)":{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-transfer}. Requirements: - `to` cannot be the zero address. - the caller must have a balance of at least `amount`."},"transferFrom(address,address,uint256)":{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function",details:"See {IERC20-transferFrom}. Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}. NOTE: Does not update the allowance if the current allowance is the maximum `uint256`. Requirements: - `from` and `to` cannot be the zero address. - `from` must have a balance of at least `amount`. - the caller must have allowance for ``from``'s tokens of at least `amount`."}}},"contracts/test/MockWBNB.sol:MockWBNB":{source:"contracts/test/MockWBNB.sol",name:"MockWBNB",fallback:{payable:!0,stateMutability:"payable",type:"fallback"},events:{"Approval(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!0,name:"guy",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Approval",type:"event"},"Transfer(address,address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!0,name:"dst",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Transfer",type:"event"},"Deposit(address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"dst",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Deposit",type:"event"},"Withdrawal(address,uint256)":{anonymous:!1,inputs:[{indexed:!0,name:"src",type:"address"},{indexed:!1,name:"wad",type:"uint256"}],name:"Withdrawal",type:"event"}},methods:{"name()":{constant:!0,inputs:[],name:"name",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},"approve(address,uint256)":{constant:!1,inputs:[{name:"guy",type:"address"},{name:"wad",type:"uint256"}],name:"approve",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"totalSupply()":{constant:!0,inputs:[],name:"totalSupply",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},"transferFrom(address,address,uint256)":{constant:!1,inputs:[{name:"src",type:"address"},{name:"dst",type:"address"},{name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"withdraw(uint256)":{constant:!1,inputs:[{name:"wad",type:"uint256"}],name:"withdraw",outputs:[],payable:!1,stateMutability:"nonpayable",type:"function"},"decimals()":{constant:!0,inputs:[],name:"decimals",outputs:[{name:"",type:"uint8"}],payable:!1,stateMutability:"view",type:"function"},"balanceOf(address)":{constant:!0,inputs:[{name:"",type:"address"}],name:"balanceOf",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},"symbol()":{constant:!0,inputs:[],name:"symbol",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},"transfer(address,uint256)":{constant:!1,inputs:[{name:"dst",type:"address"},{name:"wad",type:"uint256"}],name:"transfer",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},"deposit()":{constant:!1,inputs:[],name:"deposit",outputs:[],payable:!0,stateMutability:"payable",type:"function"},"allowance(address,address)":{constant:!0,inputs:[{name:"",type:"address"},{name:"",type:"address"}],name:"allowance",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"}}},"contracts/test/TickPositionTest.sol:TickPositionTest":{source:"contracts/test/TickPositionTest.sol",name:"TickPositionTest",methods:{"tickPosition(uint128)":{inputs:[{internalType:"uint128",name:"",type:"uint128"}],name:"tickPosition",outputs:[{internalType:"uint128",name:"liquidity",type:"uint128"},{internalType:"uint64",name:"filledIndex",type:"uint64"},{internalType:"uint64",name:"currentIndex",type:"uint64"}],stateMutability:"view",type:"function"}}}};new Qn({el:"#app",router:new bp({routes:[{path:"/",component:Np,props:()=>({json:Dp})},{path:"*",component:Ep,props:e=>({json:Dp[e.path.slice(1)]})}]}),mounted(){document.dispatchEvent(new Event("render-event"))},render:e=>e(_p)})})()})(); \ No newline at end of file From 68083911808b19c1d1cfd81c0988be663335ac4c Mon Sep 17 00:00:00 2001 From: MusketPosition Date: Tue, 28 Feb 2023 17:40:57 +0700 Subject: [PATCH 2/2] get fee share with pair manager --- contracts/interfaces/IGetFeeShareAMM.sol | 1 - 1 file changed, 1 deletion(-) diff --git a/contracts/interfaces/IGetFeeShareAMM.sol b/contracts/interfaces/IGetFeeShareAMM.sol index 9f206db..e375823 100644 --- a/contracts/interfaces/IGetFeeShareAMM.sol +++ b/contracts/interfaces/IGetFeeShareAMM.sol @@ -6,7 +6,6 @@ interface IGetFeeShareAMM { /// @return the rate share function feeShareAmm() external view returns (uint32); - /// @notice fee share for liquidity provider /// @param pairManager the address of pair want to know the pai /// @return the rate share