@gisce/ooui 0.20.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Time.d.ts +9 -0
- package/dist/Time.d.ts.map +1 -0
- package/dist/Tree.d.ts +2 -0
- package/dist/Tree.d.ts.map +1 -1
- package/dist/WidgetFactory.d.ts.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/ooui.es.js +474 -462
- package/dist/ooui.es.js.map +1 -1
- package/dist/ooui.umd.js +5 -5
- package/dist/ooui.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/Time.ts +12 -0
- package/src/Tree.ts +9 -0
- package/src/WidgetFactory.ts +4 -0
- package/src/index.ts +2 -0
- package/src/spec/Tree.spec.ts +3 -1
- package/src/spec/WidgetFactory.spec.ts +10 -1
package/dist/ooui.umd.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
(function(S,Oe){typeof exports=="object"&&typeof module<"u"?Oe(exports,require("html-entities"),require("moment")):typeof define=="function"&&define.amd?define(["exports","html-entities","moment"],Oe):(S=typeof globalThis<"u"?globalThis:S||self,Oe(S.ooui={},S.htmlEntities,S.moment))})(this,function(S,Oe,sn){"use strict";const De=(t=>t&&typeof t=="object"&&"default"in t?t:{default:t})(sn),We=class{constructor(t){if(this._type="",this._parsedWidgetProps={},this._colspan=We._defaultColspan,this._readOnly=!1,this._invisible=!1,t){if(t.colspan&&(this._colspan=+t.colspan),t.readonly&&(t.readonly==="1"||t.readonly===1||t.readonly===!0)&&(this._readOnly=!0),t.invisible&&(t.invisible===1||t.invisible==="1"||t.invisible===!0)&&(this._invisible=!0),t.type&&(this._type=t.type),t.context&&(this._context=t.context),t.domain&&(typeof t.domain!="string"?this._domain=JSON.stringify(t.domain):this._domain=t.domain),t.widget_props)try{this._parsedWidgetProps=JSON.parse(t.widget_props.replace(/'/g,'"'))}catch{throw new Error("Error parsing widget_props")}t.key&&(this._key=t.key)}}static get defaultColspan(){return We._defaultColspan}static set defaultColspan(t){We._defaultColspan=t}get readOnly(){return this._readOnly}set readOnly(t){this._readOnly=t}get colspan(){return this._colspan}set colspan(t){this._colspan=+t}get invisible(){return this._invisible}set invisible(t){this._invisible=t}get type(){return this._type}set type(t){this._type=t}get context(){return this._context}set context(t){this._context=t}get domain(){return this._domain}set domain(t){this._domain=t}get key(){return this._key}set key(t){this._key=t}get parsedWidgetProps(){return this._parsedWidgetProps}set parsedWidgetProps(t){this._parsedWidgetProps=t}};let he=We;he._defaultColspan=1;const on=({entry:t,values:e,fields:r})=>{const[i,n,s]=t;if(r[i]===void 0||e[i]===void 0&&r[i].type!=="boolean"&&r[i].type!=="many2one")return!1;let a=s,u=r[i].type==="boolean"?!!e[i]:e[i];switch(r[i].type==="many2one"&&s===!1&&e[i]===void 0?a=void 0:(u=u===void 0?!1:u,u=u===null?!1:u),r[i].type==="many2one"&&Array.isArray(u)&&u[0]===void 0&&(u=!1),r[i].type==="boolean"&&(s===0||s===1)&&(a=s!==0),n.toLowerCase()){case"=":case"==":return u==a;case"<>":case"!=":return u!=a;case">":return u>a;case">=":return u>=a;case"<":return u<a;case"<=":return u<=a;case"in":return a.includes(u);case"not in":return!a.includes(u);default:return!1}},G=t=>Oe.decode(t,{level:"xml"}),ln=({attrs:t,values:e,fields:r})=>{const u=t.replace(/\(/g,"[").replace(/\)/g,"]").replace(/\'/g,'"').replace(/True/g,"true").replace(/False/g,"false"),f=G(u),g=JSON.parse(f),w={};for(const b of Object.keys(g))g[b].map(T=>on({entry:T,values:e,fields:r})).every(T=>T===!0)&&(w[b]=!0);return w},un=({tagAttributes:t,values:e,fields:r})=>{const i=t.attrs?ln({attrs:t.attrs,values:e,fields:r}):{};return{...t,...i,attrs:void 0}};class L extends he{constructor(e){super(e),this._id="",this._label="",this._nolabel=!1,this._required=!1,this._activated=!0,this._selectionValues=new Map([]),this._activated=!0,e&&(e.name&&(this._id=e.name),e.activated&&(this._activated=e.activated),e.string&&(this._label=G(e.string)),e.help&&(this._tooltip=G(e.help)),e.nolabel&&(e.nolabel==="1"||typeof e.nolabel=="boolean"&&e.nolabel===!0)&&(this._nolabel=!0),e.required&&(e.required==="1"||e.required===!0||e.required==="True")&&(this._required=!0),e.sum&&(this._sum=e.sum),e.selection&&(this._selectionValues=new Map(e.selection)))}get id(){return this._id}set id(e){this._id=e}get label(){return this._label}set label(e){this._label=e}get nolabel(){return this._nolabel}set nolabel(e){this._nolabel=e}get required(){return this._required}set required(e){this._required=e}get tooltip(){return this._tooltip}set tooltip(e){this._tooltip=e}get activated(){return this._activated}set activated(e){this._activated=e}get sum(){return this._sum}set sum(e){this._sum=e}get selectionValues(){return this._selectionValues}set selectionValues(e){this._selectionValues=e}findById(e){let r=null;return this._id===e&&(r=this),r}}class hr extends L{}class bt extends he{findById(e){return null}}class wt extends L{constructor(e){super({...e,nolabel:!0}),this._text="",this._align="left",this._labelType="default",this._labelSize=void 0,this._fieldForLabel=null,e!=null&&e.fieldForLabel&&(this._fieldForLabel=e.fieldForLabel),e.widget_props&&(this.parsedWidgetProps.label_type&&(this.labelType=this.parsedWidgetProps.label_type),this.parsedWidgetProps.label_size&&(this.labelSize=this.parsedWidgetProps.label_size))}get text(){return this._text}set text(e){this._text=e}get align(){return this._align}set align(e){this._align=e}get labelType(){return this._labelType}set labelType(e){this._labelType=e}get labelSize(){return this._labelSize}set labelSize(e){this._labelSize=e}get fieldForLabel(){return this._fieldForLabel}set fieldForLabel(e){this._fieldForLabel=e}}class Me{get columns(){return this._columns}set columns(e){this._columns=e}get colspan(){return this._colspan}set colspan(e){this._colspan=e}get rows(){return this._rows}set rows(e){this._rows=e}get index(){return this._index}get readOnly(){return this._readOnly}set readOnly(e){this._readOnly=e}get key(){return this._key}set key(e){this._key=e}constructor(e=4,r=6,i=!1,n=void 0){this._columns=e,this._colspan=r,this._rows=[[]],this._index=0,this._readOnly=i,this._key=n}freePosition(){const e=this._rows[this._index].filter(r=>!r.invisible).reduce((r,i)=>r+i.colspan,0);return this._columns-e}addWidget(e,r){const i=[],n=r?r.addLabel:!0;if(e instanceof bt){this._rows.push([]),this._index++;return}if(e.colspan>this._columns&&(e.colspan=this._columns),e.readOnly=e.readOnly||this.readOnly,n&&e instanceof L&&!e.nolabel){e.colspan>1&&(e.colspan-=1);const a=new wt({name:e.id+"_label",string:e.label,invisible:e.invisible,help:e.tooltip,fieldForLabel:e.id,key:e.key+"-label"});a.type="label",i.push(a),i.push(e)}else i.push(e);i.reduce((a,u)=>a+u.colspan,0)>this.freePosition()&&(this._rows.push([]),this._index++),this._rows[this._index]=this._rows[this._index].concat(i)}findById(e){let r=null;return this._rows&&this._rows.length&&this._rows.forEach(i=>{r||i&&i.length&&i.forEach(n=>{r||n&&(r=n.findById(e))})}),r}}const je=class extends he{constructor(t){super(t),this._id="",this._mustExpand=!1,this._label="",this._container=new Me(t&&t.col,je._defaultColspan,this.readOnly,t&&t.key),t&&(t.name&&(this._id=t.name),t.colspan?this._container.colspan=+t.colspan:this._mustExpand=!0,t.string&&(this._label=G(t.string)))}get id(){return this._id}set id(t){this._id=t}static get defaultColspan(){return je._defaultColspan}static set defaultColspan(t){je._defaultColspan=t}get container(){return this._container}set container(t){this._container=t}get colspan(){return this._container.colspan}set colspan(t){this._container.colspan=+t}get mustExpand(){return this._mustExpand}set mustExpand(t){this._mustExpand=t}get label(){return this._label}set label(t){this._label=t}findById(t){return t===this.id?this:this.container.findById(t)}};let de=je;de._defaultColspan=6;const Ye=class extends de{constructor(t){super(t),this._tabPosition="top",this._pages=[],this.colspan=Ye._defaultColspan,t&&(t.colspan&&(this.colspan=t.colspan),t.tabpos&&(this._tabPosition=t.tabpos))}static get defaultColspan(){return Ye._defaultColspan}static set defaultColspan(t){Ye._defaultColspan=t}get tabPosition(){return this._tabPosition}set tabPosition(t){this._tabPosition=t}get pages(){return[].concat.apply([],this._container.rows)}};let mt=Ye;mt._defaultColspan=3;class dr extends de{constructor(e){super(e),this._icon=null,e.icon&&(this._icon=e.icon)}get icon(){return this._icon}set icon(e){this._icon=e}}class gr extends de{constructor(e){super(e),this._icon=null,e&&e.icon&&(this._icon=e.icon)}get icon(){return this._icon}set icon(e){this._icon=e}}class _r extends L{constructor(e){if(super({...e,nolabel:(e==null?void 0:e.nolabel)!==void 0?e.nolabel:!0}),this._buttonType="workflow",this._caption="",this._confirmMessage="",this._primary=!1,this._danger=!1,e){if(e.string&&(this._caption=G(e.string)),e.buttonType&&(this._buttonType=e.buttonType),e.confirm&&(this._confirmMessage=G(e.confirm)),e.special&&e.special==="cancel"&&(this._buttonType="cancel"),e.icon&&(this._icon=e.icon),e.primary){const r=e.primary;(r==="1"||r===1||r===!0)&&(this._primary=!0)}if(e.danger){const r=e.danger;(r==="1"||r===1||r===!0)&&(this._danger=!0)}}}get buttonType(){return this._buttonType}set buttonType(e){this._buttonType=e}get caption(){return this._caption}set caption(e){this._caption=e}get icon(){return this._icon}set icon(e){this._icon=e}get confirmMessage(){return this._confirmMessage}set confirm(e){this._confirmMessage=e}get primary(){return this._primary}set primary(e){this._primary=e}get danger(){return this._danger}set danger(e){this._danger=e}}class pr extends de{constructor(e){super(e),this._defaultName="",e.default&&(this._defaultName=e.default)}get defaultName(){return this._defaultName}get defaultButton(){const e=this.buttons.find(r=>r.id===this.defaultName);return e||this.buttons[0]}get secondaryButtons(){return this.buttons.filter(r=>{var i;return r.id!==((i=this.defaultButton)==null?void 0:i.id)})}get buttons(){return this._container.rows[0].filter(e=>!e.invisible)}}class ze extends L{constructor(e){super(e),this._placeholder="",this._isPassword=!1,this._translatable=!1,e&&(e.size&&(this._size=e.size),e.password&&(this.isPassword=e.password==="True"),e.translate&&(this.translatable=e.translate==="True"||e.translate===!0))}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e}get size(){return this._size}set size(e){this._size=e}get isPassword(){return this._isPassword}set isPassword(e){this._isPassword=e}get translatable(){return this._translatable}set translatable(e){this._translatable=e}}class qe extends L{constructor(e){if(super(e),this._placeholder="",this._mustExpand=!1,this._translatable=!1,e){if(e.placeholder&&(this._placeholder=G(e.placeholder)),e.colspan||(this._mustExpand=!0),e.height)try{this._height=parseInt(e.height)}catch{this._height=void 0}e.translate&&(this.translatable=e.translate==="True"||e.translate===!0)}}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}get height(){return this._height}set height(e){this._height=e}get translatable(){return this._translatable}set translatable(e){this._translatable=e}}class ve extends L{constructor(e){super(e),this._size=150,e&&e.size&&(this._size=e.size)}get size(){return this._size}set size(e){this._size=e}}class yr extends L{constructor(e){super(e),this._size=150,this._relation="",e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}}class br extends qe{}class vt extends L{constructor(e){super(e)}}class wr extends L{constructor(e){super(e)}}class $e extends L{constructor(e){if(super(e),this._integerDigits=16,this._decimalDigits=2,e!=null&&e.digits){const[r,i]=e.digits;this._integerDigits=r,this._decimalDigits=i}}get integerDigits(){return this._integerDigits}set integerDigits(e){this._integerDigits=e}get decimalDigits(){return this._decimalDigits}set decimalDigits(e){this._decimalDigits=e}}class mr extends $e{}class vr extends $e{}class Er extends L{constructor(e){super(e)}}class xr extends L{constructor(e){super(e)}}class Rr extends L{constructor(e){super(e),this._size=150,this._relation="",this._mustExpand=!1,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.colspan||(this._mustExpand=!0))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}}class Et extends L{constructor(e){super(e),this._size=150,this._relation="",this._views=null,this._mode=[],this._mustExpand=!1,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.mode&&(this._mode=e.mode.split(",")),e.views&&(this._views=e.views),e.colspan?this.colspan=e.colspan:this._mustExpand=!0,e.inv_field&&(this._inv_field=e.inv_field))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get inv_field(){return this._inv_field}set inv_field(e){this._inv_field=e}get views(){return this._views}set views(e){this._views=e}get mode(){return this._mode}set mode(e){this._mode=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}}class Tr extends he{constructor(e){super(e),this._label="",this._icon=null,e&&(e.string&&(this._label=G(e.string)),e.icon&&(this._icon=e.icon))}get label(){return this._label}set label(e){this._label=e}get icon(){return this._icon}set icon(e){this._icon=e}findById(e){return null}}class Sr extends ve{}class Cr extends L{constructor(e){super(e),this._filenameField="",e&&e.filename&&(this._filenameField=e.filename)}get filenameField(){return this._filenameField}set filenameField(e){this._filenameField=e}}class Ar extends L{}class fn extends L{constructor(e){super(e)}}class Fr extends Et{constructor(e){super(e),this._titleField="",this._summaryField="",this._parsedWidgetProps&&(this._titleField=this._parsedWidgetProps.titleField,this._summaryField=this.parsedWidgetProps.summaryField)}get titleField(){return this._titleField}set titleField(e){this._titleField=e}get summaryField(){return this._summaryField}set summaryField(e){this._summaryField=e}get iconField(){return this.parsedWidgetProps.iconField}get colorField(){return this.parsedWidgetProps.colorField}}class Or extends ve{constructor(e){super(e),this._nolabel=!0,this._card=!1,this._icon="",this._suffix="",this._parsedWidgetProps&&(this._card=this._parsedWidgetProps.card||!1,this._icon=this._parsedWidgetProps.icon||"",this._suffix=this._parsedWidgetProps.suffix||"")}get card(){return this._card}set card(e){this._card=e}get icon(){return this._icon}set icon(e){this._icon=e}get suffix(){return this._suffix}set suffix(e){this._suffix=e}}class xt extends L{constructor(e){super(e),this._size=150,this._relation="",this._field="name",this._columns=4,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.inv_field&&(this._inv_field=e.inv_field),this.parsedWidgetProps.hasOwnProperty("field")&&(this._field=this.parsedWidgetProps.field),this.parsedWidgetProps.columns&&(this._columns=this.parsedWidgetProps.columns))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get inv_field(){return this._inv_field}set inv_field(e){this._inv_field=e}get field(){return this._field}set field(e){this._field=e}get columns(){return this._columns}set columns(e){this._columns=e}}class Dr extends xt{}class Mr extends ve{get colors(){return this._parsedWidgetProps.colors||{}}}class kr extends ve{constructor(e){super(e),this._direction="horizontal",e&&this.parsedWidgetProps.hasOwnProperty("direction")&&(this._direction=this.parsedWidgetProps.direction)}get direction(){return this._direction}set direction(e){this._direction=e}}class Pr extends vt{}class Nr extends L{constructor(e){super(e),this._relation="",this._errorField=null,e&&(e.relation&&(this._relation=e.relation),this.parsedWidgetProps.hasOwnProperty("error_field")&&(this._errorField=this.parsedWidgetProps.error_field))}get relation(){return this._relation}set relation(e){this._relation=e}get errorField(){return this._errorField}set errorField(e){this._errorField=e}}class Ir extends qe{constructor(e){super(e),this._lang=null,e&&this.parsedWidgetProps.lang&&(this._lang=this.parsedWidgetProps.lang)}get lang(){return this._lang}set lang(e){this._lang=e}}class Rt{setWidgetClass(e){switch(e){case"notebook":this._widgetClass=mt;break;case"page":this._widgetClass=dr;break;case"group":this._widgetClass=gr;break;case"label":this._widgetClass=wt;break;case"char":this._widgetClass=ze;break;case"text":this._widgetClass=qe;break;case"button":this._widgetClass=_r;break;case"buttonGroup":this._widgetClass=pr;break;case"selection":this._widgetClass=ve;break;case"many2one":this._widgetClass=yr;break;case"boolean":this._widgetClass=vt;break;case"integer":this._widgetClass=wr;break;case"float":this._widgetClass=$e;break;case"float_time":this._widgetClass=mr;break;case"date":this._widgetClass=Er;break;case"datetime":this._widgetClass=xr;break;case"progressbar":this._widgetClass=vr;break;case"many2many":this._widgetClass=Rr;break;case"markdown":this._widgetClass=br;break;case"one2many":case"one2many_list":this._widgetClass=Et;break;case"newline":this._widgetClass=bt;break;case"separator":this._widgetClass=Tr;break;case"url":this._widgetClass=ze;break;case"email":this._widgetClass=ze;break;case"reference":this._widgetClass=Sr;break;case"binary":this._widgetClass=Cr;break;case"image":this._widgetClass=Ar;break;case"fiber_grid":this._widgetClass=fn;break;case"timeline":this._widgetClass=Fr;break;case"indicator":this._widgetClass=Or;break;case"tags":this._widgetClass=Dr;break;case"tag":this._widgetClass=Mr;break;case"avatar":this._widgetClass=hr;break;case"radio":this._widgetClass=kr;break;case"multicheckbox":this._widgetClass=xt;break;case"switch":this._widgetClass=Pr;break;case"steps":this._widgetClass=Nr;break;case"codeeditor":this._widgetClass=Ir;break}}createWidget(e,r){let i=e;switch(this.setWidgetClass(e),this._widgetClass===void 0&&(i=r.fieldsWidgetType,this.setWidgetClass(r.fieldsWidgetType)),this._widgetClass===void 0&&(this._widgetClass=he),e){case"notebook":case"page":case"group":return new this._widgetClass({...r,type:i});case"button":return new this._widgetClass({...r,type:e,buttonType:r.type});default:return new this._widgetClass({...r,type:i})}}}const cn=({fieldName:t,values:e,fields:r})=>{var i;if(!t)return{};const n=(i=r[t])==null?void 0:i.states;if(!n)return{};const s={},a={};for(const u of Object.keys(n))if(e.state===u){const f=n[u];for(const g of f){const[w,b]=g;a[w]||(a[w]=[]),a[w].push(b)}}for(const u of Object.keys(a)){const f=a[u];s[u]=f.some(g=>g===!0)}return s},hn=({states:t,values:e})=>{if(!(e!=null&&e.state))return{};const r=t.split(",");return r.length===0?{}:r.includes(e.state)?{}:{invisible:!0}};function dn({values:t={},fieldName:e,fields:r={}}){var i;const n=((i=r[e])==null?void 0:i.type)||"passthrough";return n==="many2one"?t[e]?t[e][0]||null:!1:n==="one2many"||n==="many2many"?t[e].map(s=>s.id):t!=null&&t[e]?t==null?void 0:t[e]:e.indexOf("'")!==-1?e:parseInt(e)}const Br=({context:t,values:e,fields:r})=>{try{if(!t)return;if(_n(t)||typeof t!="string")return t;const s=gn(t);if(s!==null)return s;if(t.trim().length===0)return;var i=t.replace(/\"/g,"'").replace(/\s/g,"").replace(/True/g,"true"),n=i.replace(/False/g,"false");const b=n.replace(/\{/g,"").replace(/\}/g,"").split(",").map(m=>m.split(":")),_={};return b.forEach(m=>{const E=m[1];if(m[1].indexOf("'")===-1&&m[1]!=="true"&&m[1]!=="false"){const T=dn({values:e,fields:r,fieldName:E==="active_id"?"id":E});_[m[0].replace(/'/g,"")]=T||void 0}else m[1]==="true"?_[m[0].replace(/'/g,"")]=!0:m[1]==="false"?_[m[0].replace(/'/g,"")]=!1:_[m[0].replace(/'/g,"")]=m[1].replace(/'/g,"")}),_}catch{return}};function gn(t){try{return JSON.parse(t)}catch{return null}}function _n(t){return typeof t=="object"&&t!==null&&typeof t!="string"}const pn=t=>{const e=t.trim().replace(")","").split("("),r=e[0],n=e[1].split(",").map(s=>s.trim());return{method:r,args:n}};function Ge(t,e){e=e||{};var r=e.pos||0,i=!!e.keepComments,n=!!e.keepWhitespace,s="<",a="<".charCodeAt(0),u=">",f=">".charCodeAt(0),g="-".charCodeAt(0),w="/".charCodeAt(0),b="!".charCodeAt(0),_="'".charCodeAt(0),m='"'.charCodeAt(0),E="[".charCodeAt(0),T="]".charCodeAt(0);function O(F){for(var U=[];t[r];)if(t.charCodeAt(r)==a){if(t.charCodeAt(r+1)===w){var V=r+2;r=t.indexOf(u,r);var ne=t.substring(V,r);if(ne.indexOf(F)==-1){var X=t.substring(0,r).split(`
|
|
1
|
+
(function(S,Oe){typeof exports=="object"&&typeof module<"u"?Oe(exports,require("html-entities"),require("moment")):typeof define=="function"&&define.amd?define(["exports","html-entities","moment"],Oe):(S=typeof globalThis<"u"?globalThis:S||self,Oe(S.ooui={},S.htmlEntities,S.moment))})(this,function(S,Oe,on){"use strict";const De=(t=>t&&typeof t=="object"&&"default"in t?t:{default:t})(on),We=class{constructor(t){if(this._type="",this._parsedWidgetProps={},this._colspan=We._defaultColspan,this._readOnly=!1,this._invisible=!1,t){if(t.colspan&&(this._colspan=+t.colspan),t.readonly&&(t.readonly==="1"||t.readonly===1||t.readonly===!0)&&(this._readOnly=!0),t.invisible&&(t.invisible===1||t.invisible==="1"||t.invisible===!0)&&(this._invisible=!0),t.type&&(this._type=t.type),t.context&&(this._context=t.context),t.domain&&(typeof t.domain!="string"?this._domain=JSON.stringify(t.domain):this._domain=t.domain),t.widget_props)try{this._parsedWidgetProps=JSON.parse(t.widget_props.replace(/'/g,'"'))}catch{throw new Error("Error parsing widget_props")}t.key&&(this._key=t.key)}}static get defaultColspan(){return We._defaultColspan}static set defaultColspan(t){We._defaultColspan=t}get readOnly(){return this._readOnly}set readOnly(t){this._readOnly=t}get colspan(){return this._colspan}set colspan(t){this._colspan=+t}get invisible(){return this._invisible}set invisible(t){this._invisible=t}get type(){return this._type}set type(t){this._type=t}get context(){return this._context}set context(t){this._context=t}get domain(){return this._domain}set domain(t){this._domain=t}get key(){return this._key}set key(t){this._key=t}get parsedWidgetProps(){return this._parsedWidgetProps}set parsedWidgetProps(t){this._parsedWidgetProps=t}};let he=We;he._defaultColspan=1;const ln=({entry:t,values:e,fields:r})=>{const[i,n,s]=t;if(r[i]===void 0||e[i]===void 0&&r[i].type!=="boolean"&&r[i].type!=="many2one")return!1;let a=s,u=r[i].type==="boolean"?!!e[i]:e[i];switch(r[i].type==="many2one"&&s===!1&&e[i]===void 0?a=void 0:(u=u===void 0?!1:u,u=u===null?!1:u),r[i].type==="many2one"&&Array.isArray(u)&&u[0]===void 0&&(u=!1),r[i].type==="boolean"&&(s===0||s===1)&&(a=s!==0),n.toLowerCase()){case"=":case"==":return u==a;case"<>":case"!=":return u!=a;case">":return u>a;case">=":return u>=a;case"<":return u<a;case"<=":return u<=a;case"in":return a.includes(u);case"not in":return!a.includes(u);default:return!1}},$=t=>Oe.decode(t,{level:"xml"}),un=({attrs:t,values:e,fields:r})=>{const u=t.replace(/\(/g,"[").replace(/\)/g,"]").replace(/\'/g,'"').replace(/True/g,"true").replace(/False/g,"false"),f=$(u),g=JSON.parse(f),w={};for(const b of Object.keys(g))g[b].map(T=>ln({entry:T,values:e,fields:r})).every(T=>T===!0)&&(w[b]=!0);return w},fn=({tagAttributes:t,values:e,fields:r})=>{const i=t.attrs?un({attrs:t.attrs,values:e,fields:r}):{};return{...t,...i,attrs:void 0}};class L extends he{constructor(e){super(e),this._id="",this._label="",this._nolabel=!1,this._required=!1,this._activated=!0,this._selectionValues=new Map([]),this._activated=!0,e&&(e.name&&(this._id=e.name),e.activated&&(this._activated=e.activated),e.string&&(this._label=$(e.string)),e.help&&(this._tooltip=$(e.help)),e.nolabel&&(e.nolabel==="1"||typeof e.nolabel=="boolean"&&e.nolabel===!0)&&(this._nolabel=!0),e.required&&(e.required==="1"||e.required===!0||e.required==="True")&&(this._required=!0),e.sum&&(this._sum=e.sum),e.selection&&(this._selectionValues=new Map(e.selection)))}get id(){return this._id}set id(e){this._id=e}get label(){return this._label}set label(e){this._label=e}get nolabel(){return this._nolabel}set nolabel(e){this._nolabel=e}get required(){return this._required}set required(e){this._required=e}get tooltip(){return this._tooltip}set tooltip(e){this._tooltip=e}get activated(){return this._activated}set activated(e){this._activated=e}get sum(){return this._sum}set sum(e){this._sum=e}get selectionValues(){return this._selectionValues}set selectionValues(e){this._selectionValues=e}findById(e){let r=null;return this._id===e&&(r=this),r}}class hr extends L{}class bt extends he{findById(e){return null}}class wt extends L{constructor(e){super({...e,nolabel:!0}),this._text="",this._align="left",this._labelType="default",this._labelSize=void 0,this._fieldForLabel=null,e!=null&&e.fieldForLabel&&(this._fieldForLabel=e.fieldForLabel),e.widget_props&&(this.parsedWidgetProps.label_type&&(this.labelType=this.parsedWidgetProps.label_type),this.parsedWidgetProps.label_size&&(this.labelSize=this.parsedWidgetProps.label_size))}get text(){return this._text}set text(e){this._text=e}get align(){return this._align}set align(e){this._align=e}get labelType(){return this._labelType}set labelType(e){this._labelType=e}get labelSize(){return this._labelSize}set labelSize(e){this._labelSize=e}get fieldForLabel(){return this._fieldForLabel}set fieldForLabel(e){this._fieldForLabel=e}}class Me{get columns(){return this._columns}set columns(e){this._columns=e}get colspan(){return this._colspan}set colspan(e){this._colspan=e}get rows(){return this._rows}set rows(e){this._rows=e}get index(){return this._index}get readOnly(){return this._readOnly}set readOnly(e){this._readOnly=e}get key(){return this._key}set key(e){this._key=e}constructor(e=4,r=6,i=!1,n=void 0){this._columns=e,this._colspan=r,this._rows=[[]],this._index=0,this._readOnly=i,this._key=n}freePosition(){const e=this._rows[this._index].filter(r=>!r.invisible).reduce((r,i)=>r+i.colspan,0);return this._columns-e}addWidget(e,r){const i=[],n=r?r.addLabel:!0;if(e instanceof bt){this._rows.push([]),this._index++;return}if(e.colspan>this._columns&&(e.colspan=this._columns),e.readOnly=e.readOnly||this.readOnly,n&&e instanceof L&&!e.nolabel){e.colspan>1&&(e.colspan-=1);const a=new wt({name:e.id+"_label",string:e.label,invisible:e.invisible,help:e.tooltip,fieldForLabel:e.id,key:e.key+"-label"});a.type="label",i.push(a),i.push(e)}else i.push(e);i.reduce((a,u)=>a+u.colspan,0)>this.freePosition()&&(this._rows.push([]),this._index++),this._rows[this._index]=this._rows[this._index].concat(i)}findById(e){let r=null;return this._rows&&this._rows.length&&this._rows.forEach(i=>{r||i&&i.length&&i.forEach(n=>{r||n&&(r=n.findById(e))})}),r}}const je=class extends he{constructor(t){super(t),this._id="",this._mustExpand=!1,this._label="",this._container=new Me(t&&t.col,je._defaultColspan,this.readOnly,t&&t.key),t&&(t.name&&(this._id=t.name),t.colspan?this._container.colspan=+t.colspan:this._mustExpand=!0,t.string&&(this._label=$(t.string)))}get id(){return this._id}set id(t){this._id=t}static get defaultColspan(){return je._defaultColspan}static set defaultColspan(t){je._defaultColspan=t}get container(){return this._container}set container(t){this._container=t}get colspan(){return this._container.colspan}set colspan(t){this._container.colspan=+t}get mustExpand(){return this._mustExpand}set mustExpand(t){this._mustExpand=t}get label(){return this._label}set label(t){this._label=t}findById(t){return t===this.id?this:this.container.findById(t)}};let de=je;de._defaultColspan=6;const Ye=class extends de{constructor(t){super(t),this._tabPosition="top",this._pages=[],this.colspan=Ye._defaultColspan,t&&(t.colspan&&(this.colspan=t.colspan),t.tabpos&&(this._tabPosition=t.tabpos))}static get defaultColspan(){return Ye._defaultColspan}static set defaultColspan(t){Ye._defaultColspan=t}get tabPosition(){return this._tabPosition}set tabPosition(t){this._tabPosition=t}get pages(){return[].concat.apply([],this._container.rows)}};let mt=Ye;mt._defaultColspan=3;class dr extends de{constructor(e){super(e),this._icon=null,e.icon&&(this._icon=e.icon)}get icon(){return this._icon}set icon(e){this._icon=e}}class gr extends de{constructor(e){super(e),this._icon=null,e&&e.icon&&(this._icon=e.icon)}get icon(){return this._icon}set icon(e){this._icon=e}}class _r extends L{constructor(e){if(super({...e,nolabel:(e==null?void 0:e.nolabel)!==void 0?e.nolabel:!0}),this._buttonType="workflow",this._caption="",this._confirmMessage="",this._primary=!1,this._danger=!1,e){if(e.string&&(this._caption=$(e.string)),e.buttonType&&(this._buttonType=e.buttonType),e.confirm&&(this._confirmMessage=$(e.confirm)),e.special&&e.special==="cancel"&&(this._buttonType="cancel"),e.icon&&(this._icon=e.icon),e.primary){const r=e.primary;(r==="1"||r===1||r===!0)&&(this._primary=!0)}if(e.danger){const r=e.danger;(r==="1"||r===1||r===!0)&&(this._danger=!0)}}}get buttonType(){return this._buttonType}set buttonType(e){this._buttonType=e}get caption(){return this._caption}set caption(e){this._caption=e}get icon(){return this._icon}set icon(e){this._icon=e}get confirmMessage(){return this._confirmMessage}set confirm(e){this._confirmMessage=e}get primary(){return this._primary}set primary(e){this._primary=e}get danger(){return this._danger}set danger(e){this._danger=e}}class pr extends de{constructor(e){super(e),this._defaultName="",e.default&&(this._defaultName=e.default)}get defaultName(){return this._defaultName}get defaultButton(){const e=this.buttons.find(r=>r.id===this.defaultName);return e||this.buttons[0]}get secondaryButtons(){return this.buttons.filter(r=>{var i;return r.id!==((i=this.defaultButton)==null?void 0:i.id)})}get buttons(){return this._container.rows[0].filter(e=>!e.invisible)}}class ze extends L{constructor(e){super(e),this._placeholder="",this._isPassword=!1,this._translatable=!1,e&&(e.size&&(this._size=e.size),e.password&&(this.isPassword=e.password==="True"),e.translate&&(this.translatable=e.translate==="True"||e.translate===!0))}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e}get size(){return this._size}set size(e){this._size=e}get isPassword(){return this._isPassword}set isPassword(e){this._isPassword=e}get translatable(){return this._translatable}set translatable(e){this._translatable=e}}class qe extends L{constructor(e){if(super(e),this._placeholder="",this._mustExpand=!1,this._translatable=!1,e){if(e.placeholder&&(this._placeholder=$(e.placeholder)),e.colspan||(this._mustExpand=!0),e.height)try{this._height=parseInt(e.height)}catch{this._height=void 0}e.translate&&(this.translatable=e.translate==="True"||e.translate===!0)}}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}get height(){return this._height}set height(e){this._height=e}get translatable(){return this._translatable}set translatable(e){this._translatable=e}}class ve extends L{constructor(e){super(e),this._size=150,e&&e.size&&(this._size=e.size)}get size(){return this._size}set size(e){this._size=e}}class yr extends L{constructor(e){super(e),this._size=150,this._relation="",e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}}class br extends qe{}class vt extends L{constructor(e){super(e)}}class wr extends L{constructor(e){super(e)}}class $e extends L{constructor(e){if(super(e),this._integerDigits=16,this._decimalDigits=2,e!=null&&e.digits){const[r,i]=e.digits;this._integerDigits=r,this._decimalDigits=i}}get integerDigits(){return this._integerDigits}set integerDigits(e){this._integerDigits=e}get decimalDigits(){return this._decimalDigits}set decimalDigits(e){this._decimalDigits=e}}class mr extends $e{}class vr extends $e{}class Er extends L{constructor(e){super(e)}}class xr extends L{constructor(e){super(e)}}class Rr extends L{constructor(e){super(e),this._size=150,this._relation="",this._mustExpand=!1,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.colspan||(this._mustExpand=!0))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}}class Et extends L{constructor(e){super(e),this._size=150,this._relation="",this._views=null,this._mode=[],this._mustExpand=!1,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.mode&&(this._mode=e.mode.split(",")),e.views&&(this._views=e.views),e.colspan?this.colspan=e.colspan:this._mustExpand=!0,e.inv_field&&(this._inv_field=e.inv_field))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get inv_field(){return this._inv_field}set inv_field(e){this._inv_field=e}get views(){return this._views}set views(e){this._views=e}get mode(){return this._mode}set mode(e){this._mode=e}get mustExpand(){return this._mustExpand}set mustExpand(e){this._mustExpand=e}}class Tr extends he{constructor(e){super(e),this._label="",this._icon=null,e&&(e.string&&(this._label=$(e.string)),e.icon&&(this._icon=e.icon))}get label(){return this._label}set label(e){this._label=e}get icon(){return this._icon}set icon(e){this._icon=e}findById(e){return null}}class Sr extends ve{}class Cr extends L{constructor(e){super(e),this._filenameField="",e&&e.filename&&(this._filenameField=e.filename)}get filenameField(){return this._filenameField}set filenameField(e){this._filenameField=e}}class Ar extends L{}class cn extends L{constructor(e){super(e)}}class Fr extends Et{constructor(e){super(e),this._titleField="",this._summaryField="",this._parsedWidgetProps&&(this._titleField=this._parsedWidgetProps.titleField,this._summaryField=this.parsedWidgetProps.summaryField)}get titleField(){return this._titleField}set titleField(e){this._titleField=e}get summaryField(){return this._summaryField}set summaryField(e){this._summaryField=e}get iconField(){return this.parsedWidgetProps.iconField}get colorField(){return this.parsedWidgetProps.colorField}}class Or extends ve{constructor(e){super(e),this._nolabel=!0,this._card=!1,this._icon="",this._suffix="",this._parsedWidgetProps&&(this._card=this._parsedWidgetProps.card||!1,this._icon=this._parsedWidgetProps.icon||"",this._suffix=this._parsedWidgetProps.suffix||"")}get card(){return this._card}set card(e){this._card=e}get icon(){return this._icon}set icon(e){this._icon=e}get suffix(){return this._suffix}set suffix(e){this._suffix=e}}class xt extends L{constructor(e){super(e),this._size=150,this._relation="",this._field="name",this._columns=4,e&&(e.size&&(this._size=e.size),e.relation&&(this._relation=e.relation),e.inv_field&&(this._inv_field=e.inv_field),this.parsedWidgetProps.hasOwnProperty("field")&&(this._field=this.parsedWidgetProps.field),this.parsedWidgetProps.columns&&(this._columns=this.parsedWidgetProps.columns))}get size(){return this._size}set size(e){this._size=e}get relation(){return this._relation}set relation(e){this._relation=e}get inv_field(){return this._inv_field}set inv_field(e){this._inv_field=e}get field(){return this._field}set field(e){this._field=e}get columns(){return this._columns}set columns(e){this._columns=e}}class Dr extends xt{}class Mr extends ve{get colors(){return this._parsedWidgetProps.colors||{}}}class kr extends ve{constructor(e){super(e),this._direction="horizontal",e&&this.parsedWidgetProps.hasOwnProperty("direction")&&(this._direction=this.parsedWidgetProps.direction)}get direction(){return this._direction}set direction(e){this._direction=e}}class Pr extends vt{}class Nr extends L{constructor(e){super(e),this._relation="",this._errorField=null,e&&(e.relation&&(this._relation=e.relation),this.parsedWidgetProps.hasOwnProperty("error_field")&&(this._errorField=this.parsedWidgetProps.error_field))}get relation(){return this._relation}set relation(e){this._relation=e}get errorField(){return this._errorField}set errorField(e){this._errorField=e}}class Ir extends qe{constructor(e){super(e),this._lang=null,e&&this.parsedWidgetProps.lang&&(this._lang=this.parsedWidgetProps.lang)}get lang(){return this._lang}set lang(e){this._lang=e}}class Br extends L{constructor(e){super(e)}}class Rt{setWidgetClass(e){switch(e){case"notebook":this._widgetClass=mt;break;case"page":this._widgetClass=dr;break;case"group":this._widgetClass=gr;break;case"label":this._widgetClass=wt;break;case"char":this._widgetClass=ze;break;case"text":this._widgetClass=qe;break;case"button":this._widgetClass=_r;break;case"buttonGroup":this._widgetClass=pr;break;case"selection":this._widgetClass=ve;break;case"many2one":this._widgetClass=yr;break;case"boolean":this._widgetClass=vt;break;case"integer":this._widgetClass=wr;break;case"float":this._widgetClass=$e;break;case"float_time":this._widgetClass=mr;break;case"date":this._widgetClass=Er;break;case"datetime":this._widgetClass=xr;break;case"progressbar":this._widgetClass=vr;break;case"many2many":this._widgetClass=Rr;break;case"markdown":this._widgetClass=br;break;case"one2many":case"one2many_list":this._widgetClass=Et;break;case"newline":this._widgetClass=bt;break;case"separator":this._widgetClass=Tr;break;case"url":this._widgetClass=ze;break;case"email":this._widgetClass=ze;break;case"reference":this._widgetClass=Sr;break;case"binary":this._widgetClass=Cr;break;case"image":this._widgetClass=Ar;break;case"fiber_grid":this._widgetClass=cn;break;case"timeline":this._widgetClass=Fr;break;case"indicator":this._widgetClass=Or;break;case"tags":this._widgetClass=Dr;break;case"tag":this._widgetClass=Mr;break;case"avatar":this._widgetClass=hr;break;case"radio":this._widgetClass=kr;break;case"multicheckbox":this._widgetClass=xt;break;case"switch":this._widgetClass=Pr;break;case"steps":this._widgetClass=Nr;break;case"codeeditor":this._widgetClass=Ir;break;case"time":this._widgetClass=Br;break}}createWidget(e,r){let i=e;switch(this.setWidgetClass(e),this._widgetClass===void 0&&(i=r.fieldsWidgetType,this.setWidgetClass(r.fieldsWidgetType)),this._widgetClass===void 0&&(this._widgetClass=he),e){case"notebook":case"page":case"group":return new this._widgetClass({...r,type:i});case"button":return new this._widgetClass({...r,type:e,buttonType:r.type});default:return new this._widgetClass({...r,type:i})}}}const hn=({fieldName:t,values:e,fields:r})=>{var i;if(!t)return{};const n=(i=r[t])==null?void 0:i.states;if(!n)return{};const s={},a={};for(const u of Object.keys(n))if(e.state===u){const f=n[u];for(const g of f){const[w,b]=g;a[w]||(a[w]=[]),a[w].push(b)}}for(const u of Object.keys(a)){const f=a[u];s[u]=f.some(g=>g===!0)}return s},dn=({states:t,values:e})=>{if(!(e!=null&&e.state))return{};const r=t.split(",");return r.length===0?{}:r.includes(e.state)?{}:{invisible:!0}};function gn({values:t={},fieldName:e,fields:r={}}){var i;const n=((i=r[e])==null?void 0:i.type)||"passthrough";return n==="many2one"?t[e]?t[e][0]||null:!1:n==="one2many"||n==="many2many"?t[e].map(s=>s.id):t!=null&&t[e]?t==null?void 0:t[e]:e.indexOf("'")!==-1?e:parseInt(e)}const Lr=({context:t,values:e,fields:r})=>{try{if(!t)return;if(pn(t)||typeof t!="string")return t;const s=_n(t);if(s!==null)return s;if(t.trim().length===0)return;var i=t.replace(/\"/g,"'").replace(/\s/g,"").replace(/True/g,"true"),n=i.replace(/False/g,"false");const b=n.replace(/\{/g,"").replace(/\}/g,"").split(",").map(m=>m.split(":")),_={};return b.forEach(m=>{const E=m[1];if(m[1].indexOf("'")===-1&&m[1]!=="true"&&m[1]!=="false"){const T=gn({values:e,fields:r,fieldName:E==="active_id"?"id":E});_[m[0].replace(/'/g,"")]=T||void 0}else m[1]==="true"?_[m[0].replace(/'/g,"")]=!0:m[1]==="false"?_[m[0].replace(/'/g,"")]=!1:_[m[0].replace(/'/g,"")]=m[1].replace(/'/g,"")}),_}catch{return}};function _n(t){try{return JSON.parse(t)}catch{return null}}function pn(t){return typeof t=="object"&&t!==null&&typeof t!="string"}const yn=t=>{const e=t.trim().replace(")","").split("("),r=e[0],n=e[1].split(",").map(s=>s.trim());return{method:r,args:n}};function Ge(t,e){e=e||{};var r=e.pos||0,i=!!e.keepComments,n=!!e.keepWhitespace,s="<",a="<".charCodeAt(0),u=">",f=">".charCodeAt(0),g="-".charCodeAt(0),w="/".charCodeAt(0),b="!".charCodeAt(0),_="'".charCodeAt(0),m='"'.charCodeAt(0),E="[".charCodeAt(0),T="]".charCodeAt(0);function O(F){for(var U=[];t[r];)if(t.charCodeAt(r)==a){if(t.charCodeAt(r+1)===w){var V=r+2;r=t.indexOf(u,r);var ne=t.substring(V,r);if(ne.indexOf(F)==-1){var X=t.substring(0,r).split(`
|
|
2
2
|
`);throw new Error(`Unexpected close tag
|
|
3
3
|
Line: `+(X.length-1)+`
|
|
4
4
|
Column: `+(X[X.length-1].length+1)+`
|
|
5
5
|
Char: `+t[r])}return r+1&&(r+=1),U}else if(t.charCodeAt(r+1)===b){if(t.charCodeAt(r+2)==g){const ae=r;for(;r!==-1&&!(t.charCodeAt(r)===f&&t.charCodeAt(r-1)==g&&t.charCodeAt(r-2)==g&&r!=-1);)r=t.indexOf(u,r+1);r===-1&&(r=t.length),i&&U.push(t.substring(ae,r+1))}else if(t.charCodeAt(r+2)===E&&t.charCodeAt(r+8)===E&&t.substr(r+3,5).toLowerCase()==="cdata"){var Y=t.indexOf("]]>",r);Y==-1?(U.push(t.substr(r+9)),r=t.length):(U.push(t.substring(r+9,Y)),r=Y+3);continue}else{const ae=r+1;r+=2;for(var K=!1;(t.charCodeAt(r)!==f||K===!0)&&t[r];)t.charCodeAt(r)===E?K=!0:K===!0&&t.charCodeAt(r)===T&&(K=!1),r++;U.push(t.substring(ae,r))}r++;continue}var Q=M();U.push(Q),Q.tagName[0]==="?"&&(U.push(...Q.children),Q.children=[])}else{var Z=c();if(n)Z.length>0&&U.push(Z);else{var we=Z.trim();we.length>0&&U.push(we)}r++}return U}function c(){var F=r;return r=t.indexOf(s,r)-1,r===-2&&(r=t.length),t.slice(F,r+1)}var p=`\r
|
|
6
|
-
>/= `;function R(){for(var F=r;p.indexOf(t[r])===-1&&t[r];)r++;return t.slice(F,r)}var A=e.noChildNodes||["img","br","input","meta","link","hr"];function M(){r++;const F=R(),U={};let V=[];for(;t.charCodeAt(r)!==f&&t[r];){var ne=t.charCodeAt(r);if(ne>64&&ne<91||ne>96&&ne<123){for(var X=R(),Y=t.charCodeAt(r);Y&&Y!==_&&Y!==m&&!(Y>64&&Y<91||Y>96&&Y<123)&&Y!==f;)r++,Y=t.charCodeAt(r);if(Y===_||Y===m){var K=j();if(r===-1)return{tagName:F,attributes:U,children:V}}else K=null,r--;U[X]=K}r++}if(t.charCodeAt(r-1)!==w)if(F=="script"){var Q=r+1;r=t.indexOf("<\/script>",r),V=[t.slice(Q,r)],r+=9}else if(F=="style"){var Q=r+1;r=t.indexOf("</style>",r),V=[t.slice(Q,r)],r+=8}else A.indexOf(F)===-1?(r++,V=O(F)):r++;else r++;return{tagName:F,attributes:U,children:V}}function j(){var F=t[r],U=r+1;return r=t.indexOf(F,U),t.slice(U,r)}function q(){var F=new RegExp("\\s"+e.attrName+`\\s*=['"]`+e.attrValue+`['"]`).exec(t);return F?F.index:-1}var k=null;if(e.attrValue!==void 0){e.attrName=e.attrName||"id";for(var k=[];(r=q())!==-1;)r=t.lastIndexOf("<",r),r!==-1&&k.push(M()),t=t.substr(r),r=0}else e.parseNode?k=M():k=O("");return e.filter&&(k=
|
|
6
|
+
>/= `;function R(){for(var F=r;p.indexOf(t[r])===-1&&t[r];)r++;return t.slice(F,r)}var A=e.noChildNodes||["img","br","input","meta","link","hr"];function M(){r++;const F=R(),U={};let V=[];for(;t.charCodeAt(r)!==f&&t[r];){var ne=t.charCodeAt(r);if(ne>64&&ne<91||ne>96&&ne<123){for(var X=R(),Y=t.charCodeAt(r);Y&&Y!==_&&Y!==m&&!(Y>64&&Y<91||Y>96&&Y<123)&&Y!==f;)r++,Y=t.charCodeAt(r);if(Y===_||Y===m){var K=j();if(r===-1)return{tagName:F,attributes:U,children:V}}else K=null,r--;U[X]=K}r++}if(t.charCodeAt(r-1)!==w)if(F=="script"){var Q=r+1;r=t.indexOf("<\/script>",r),V=[t.slice(Q,r)],r+=9}else if(F=="style"){var Q=r+1;r=t.indexOf("</style>",r),V=[t.slice(Q,r)],r+=8}else A.indexOf(F)===-1?(r++,V=O(F)):r++;else r++;return{tagName:F,attributes:U,children:V}}function j(){var F=t[r],U=r+1;return r=t.indexOf(F,U),t.slice(U,r)}function q(){var F=new RegExp("\\s"+e.attrName+`\\s*=['"]`+e.attrValue+`['"]`).exec(t);return F?F.index:-1}var k=null;if(e.attrValue!==void 0){e.attrName=e.attrName||"id";for(var k=[];(r=q())!==-1;)r=t.lastIndexOf("<",r),r!==-1&&k.push(M()),t=t.substr(r),r=0}else e.parseNode?k=M():k=O("");return e.filter&&(k=Wr(k,e.filter)),e.simplify?Ur(Array.isArray(k)?k:[k]):(e.setPos&&(k.pos=r),k)}function Ur(t){var e={};if(!t.length)return"";if(t.length===1&&typeof t[0]=="string")return t[0];t.forEach(function(i){if(typeof i=="object"){e[i.tagName]||(e[i.tagName]=[]);var n=Ur(i.children);e[i.tagName].push(n),Object.keys(i.attributes).length&&typeof n!="string"&&(n._attributes=i.attributes)}});for(var r in e)e[r].length==1&&(e[r]=e[r][0]);return e}function Wr(t,e,r=0,i=""){var n=[];return t.forEach(function(s,a){if(typeof s=="object"&&e(s,a,r,i)&&n.push(s),s.children){var u=Wr(s.children,e,r+1,(i?i+".":"")+a+"."+s.tagName);n=n.concat(u)}}),n}const Ee=typeof global<"u"?global:typeof self<"u"?self:typeof window<"u"?window:{};function jr(){throw new Error("setTimeout has not been defined")}function Yr(){throw new Error("clearTimeout has not been defined")}var ue=jr,fe=Yr;typeof Ee.setTimeout=="function"&&(ue=setTimeout),typeof Ee.clearTimeout=="function"&&(fe=clearTimeout);function zr(t){if(ue===setTimeout)return setTimeout(t,0);if((ue===jr||!ue)&&setTimeout)return ue=setTimeout,setTimeout(t,0);try{return ue(t,0)}catch{try{return ue.call(null,t,0)}catch{return ue.call(this,t,0)}}}function bn(t){if(fe===clearTimeout)return clearTimeout(t);if((fe===Yr||!fe)&&clearTimeout)return fe=clearTimeout,clearTimeout(t);try{return fe(t)}catch{try{return fe.call(null,t)}catch{return fe.call(this,t)}}}var se=[],xe=!1,ge,Ve=-1;function wn(){!xe||!ge||(xe=!1,ge.length?se=ge.concat(se):Ve=-1,se.length&&qr())}function qr(){if(!xe){var t=zr(wn);xe=!0;for(var e=se.length;e;){for(ge=se,se=[];++Ve<e;)ge&&ge[Ve].run();Ve=-1,e=se.length}ge=null,xe=!1,bn(t)}}function mn(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];se.push(new $r(t,e)),se.length===1&&!xe&&zr(qr)}function $r(t,e){this.fun=t,this.array=e}$r.prototype.run=function(){this.fun.apply(null,this.array)};var vn="browser",En="browser",xn=!0,Rn={},Tn=[],Sn="",Cn={},An={},Fn={};function _e(){}var On=_e,Dn=_e,Mn=_e,kn=_e,Pn=_e,Nn=_e,In=_e;function Bn(t){throw new Error("process.binding is not supported")}function Ln(){return"/"}function Un(t){throw new Error("process.chdir is not supported")}function Wn(){return 0}var Re=Ee.performance||{},jn=Re.now||Re.mozNow||Re.msNow||Re.oNow||Re.webkitNow||function(){return new Date().getTime()};function Yn(t){var e=jn.call(Re)*.001,r=Math.floor(e),i=Math.floor(e%1*1e9);return t&&(r=r-t[0],i=i-t[1],i<0&&(r--,i+=1e9)),[r,i]}var zn=new Date;function qn(){var t=new Date,e=t-zn;return e/1e3}var I={nextTick:mn,title:vn,browser:xn,env:Rn,argv:Tn,version:Sn,versions:Cn,on:On,addListener:Dn,once:Mn,off:kn,removeListener:Pn,removeAllListeners:Nn,emit:In,binding:Bn,cwd:Ln,chdir:Un,umask:Wn,hrtime:Yn,platform:En,release:An,config:Fn,uptime:qn},He=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Tt(t){var e=t.default;if(typeof e=="function"){var r=function(){return e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(i){var n=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(r,i,n.get?n:{enumerable:!0,get:function(){return t[i]}})}),r}var St={exports:{}},Ct={exports:{}};const Gr=Tt(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var Vr=Gr.EventEmitter,ee=[],H=[],$n=typeof Uint8Array<"u"?Uint8Array:Array,At=!1;function Hr(){At=!0;for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e=0,r=t.length;e<r;++e)ee[e]=t[e],H[t.charCodeAt(e)]=e;H["-".charCodeAt(0)]=62,H["_".charCodeAt(0)]=63}function Gn(t){At||Hr();var e,r,i,n,s,a,u=t.length;if(u%4>0)throw new Error("Invalid string. Length must be a multiple of 4");s=t[u-2]==="="?2:t[u-1]==="="?1:0,a=new $n(u*3/4-s),i=s>0?u-4:u;var f=0;for(e=0,r=0;e<i;e+=4,r+=3)n=H[t.charCodeAt(e)]<<18|H[t.charCodeAt(e+1)]<<12|H[t.charCodeAt(e+2)]<<6|H[t.charCodeAt(e+3)],a[f++]=n>>16&255,a[f++]=n>>8&255,a[f++]=n&255;return s===2?(n=H[t.charCodeAt(e)]<<2|H[t.charCodeAt(e+1)]>>4,a[f++]=n&255):s===1&&(n=H[t.charCodeAt(e)]<<10|H[t.charCodeAt(e+1)]<<4|H[t.charCodeAt(e+2)]>>2,a[f++]=n>>8&255,a[f++]=n&255),a}function Vn(t){return ee[t>>18&63]+ee[t>>12&63]+ee[t>>6&63]+ee[t&63]}function Hn(t,e,r){for(var i,n=[],s=e;s<r;s+=3)i=(t[s]<<16)+(t[s+1]<<8)+t[s+2],n.push(Vn(i));return n.join("")}function Jr(t){At||Hr();for(var e,r=t.length,i=r%3,n="",s=[],a=16383,u=0,f=r-i;u<f;u+=a)s.push(Hn(t,u,u+a>f?f:u+a));return i===1?(e=t[r-1],n+=ee[e>>2],n+=ee[e<<4&63],n+="=="):i===2&&(e=(t[r-2]<<8)+t[r-1],n+=ee[e>>10],n+=ee[e>>4&63],n+=ee[e<<2&63],n+="="),s.push(n),s.join("")}function Je(t,e,r,i,n){var s,a,u=n*8-i-1,f=(1<<u)-1,g=f>>1,w=-7,b=r?n-1:0,_=r?-1:1,m=t[e+b];for(b+=_,s=m&(1<<-w)-1,m>>=-w,w+=u;w>0;s=s*256+t[e+b],b+=_,w-=8);for(a=s&(1<<-w)-1,s>>=-w,w+=i;w>0;a=a*256+t[e+b],b+=_,w-=8);if(s===0)s=1-g;else{if(s===f)return a?NaN:(m?-1:1)*(1/0);a=a+Math.pow(2,i),s=s-g}return(m?-1:1)*a*Math.pow(2,s-i)}function Xr(t,e,r,i,n,s){var a,u,f,g=s*8-n-1,w=(1<<g)-1,b=w>>1,_=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,m=i?0:s-1,E=i?1:-1,T=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(u=isNaN(e)?1:0,a=w):(a=Math.floor(Math.log(e)/Math.LN2),e*(f=Math.pow(2,-a))<1&&(a--,f*=2),a+b>=1?e+=_/f:e+=_*Math.pow(2,1-b),e*f>=2&&(a++,f/=2),a+b>=w?(u=0,a=w):a+b>=1?(u=(e*f-1)*Math.pow(2,n),a=a+b):(u=e*Math.pow(2,b-1)*Math.pow(2,n),a=0));n>=8;t[r+m]=u&255,m+=E,u/=256,n-=8);for(a=a<<n|u,g+=n;g>0;t[r+m]=a&255,m+=E,a/=256,g-=8);t[r+m-E]|=T*128}var Jn={}.toString,Kr=Array.isArray||function(t){return Jn.call(t)=="[object Array]"};/*!
|
|
7
7
|
* The buffer module from node.js, for the browser.
|
|
8
8
|
*
|
|
9
9
|
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
|
|
10
10
|
* @license MIT
|
|
11
|
-
*/var Kr=50;y.TYPED_ARRAY_SUPPORT=Ee.TYPED_ARRAY_SUPPORT!==void 0?Ee.TYPED_ARRAY_SUPPORT:!0;var Jn=Xe();function Xe(){return y.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function oe(t,e){if(Xe()<e)throw new RangeError("Invalid typed array length");return y.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e),t.__proto__=y.prototype):(t===null&&(t=new y(e)),t.length=e),t}function y(t,e,r){if(!y.TYPED_ARRAY_SUPPORT&&!(this instanceof y))return new y(t,e,r);if(typeof t=="number"){if(typeof e=="string")throw new Error("If encoding is specified then the first argument must be a string");return Ft(this,t)}return Qr(this,t,e,r)}y.poolSize=8192,y._augment=function(t){return t.__proto__=y.prototype,t};function Qr(t,e,r,i){if(typeof e=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer?Qn(t,e,r,i):typeof e=="string"?Kn(t,e,r):Zn(t,e)}y.from=function(t,e,r){return Qr(null,t,e,r)},y.TYPED_ARRAY_SUPPORT&&(y.prototype.__proto__=Uint8Array.prototype,y.__proto__=Uint8Array);function Zr(t){if(typeof t!="number")throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function Xn(t,e,r,i){return Zr(e),e<=0?oe(t,e):r!==void 0?typeof i=="string"?oe(t,e).fill(r,i):oe(t,e).fill(r):oe(t,e)}y.alloc=function(t,e,r){return Xn(null,t,e,r)};function Ft(t,e){if(Zr(e),t=oe(t,e<0?0:Dt(e)|0),!y.TYPED_ARRAY_SUPPORT)for(var r=0;r<e;++r)t[r]=0;return t}y.allocUnsafe=function(t){return Ft(null,t)},y.allocUnsafeSlow=function(t){return Ft(null,t)};function Kn(t,e,r){if((typeof r!="string"||r==="")&&(r="utf8"),!y.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var i=ei(e,r)|0;t=oe(t,i);var n=t.write(e,r);return n!==i&&(t=t.slice(0,n)),t}function Ot(t,e){var r=e.length<0?0:Dt(e.length)|0;t=oe(t,r);for(var i=0;i<r;i+=1)t[i]=e[i]&255;return t}function Qn(t,e,r,i){if(e.byteLength,r<0||e.byteLength<r)throw new RangeError("'offset' is out of bounds");if(e.byteLength<r+(i||0))throw new RangeError("'length' is out of bounds");return r===void 0&&i===void 0?e=new Uint8Array(e):i===void 0?e=new Uint8Array(e,r):e=new Uint8Array(e,r,i),y.TYPED_ARRAY_SUPPORT?(t=e,t.__proto__=y.prototype):t=Ot(t,e),t}function Zn(t,e){if(te(e)){var r=Dt(e.length)|0;return t=oe(t,r),t.length===0||e.copy(t,0,0,r),t}if(e){if(typeof ArrayBuffer<"u"&&e.buffer instanceof ArrayBuffer||"length"in e)return typeof e.length!="number"||wa(e.length)?oe(t,0):Ot(t,e);if(e.type==="Buffer"&&Xr(e.data))return Ot(t,e.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function Dt(t){if(t>=Xe())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Xe().toString(16)+" bytes");return t|0}function ea(t){return+t!=t&&(t=0),y.alloc(+t)}y.isBuffer=fi;function te(t){return!!(t!=null&&t._isBuffer)}y.compare=function(e,r){if(!te(e)||!te(r))throw new TypeError("Arguments must be Buffers");if(e===r)return 0;for(var i=e.length,n=r.length,s=0,a=Math.min(i,n);s<a;++s)if(e[s]!==r[s]){i=e[s],n=r[s];break}return i<n?-1:n<i?1:0},y.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},y.concat=function(e,r){if(!Xr(e))throw new TypeError('"list" argument must be an Array of Buffers');if(e.length===0)return y.alloc(0);var i;if(r===void 0)for(r=0,i=0;i<e.length;++i)r+=e[i].length;var n=y.allocUnsafe(r),s=0;for(i=0;i<e.length;++i){var a=e[i];if(!te(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(n,s),s+=a.length}return n};function ei(t,e){if(te(t))return t.length;if(typeof ArrayBuffer<"u"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;typeof t!="string"&&(t=""+t);var r=t.length;if(r===0)return 0;for(var i=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return Ze(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return r*2;case"hex":return r>>>1;case"base64":return ui(t).length;default:if(i)return Ze(t).length;e=(""+e).toLowerCase(),i=!0}}y.byteLength=ei;function ta(t,e,r){var i=!1;if((e===void 0||e<0)&&(e=0),e>this.length||((r===void 0||r>this.length)&&(r=this.length),r<=0)||(r>>>=0,e>>>=0,r<=e))return"";for(t||(t="utf8");;)switch(t){case"hex":return ca(this,e,r);case"utf8":case"utf-8":return ni(this,e,r);case"ascii":return ua(this,e,r);case"latin1":case"binary":return fa(this,e,r);case"base64":return oa(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ha(this,e,r);default:if(i)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),i=!0}}y.prototype._isBuffer=!0;function pe(t,e,r){var i=t[e];t[e]=t[r],t[r]=i}y.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var r=0;r<e;r+=2)pe(this,r,r+1);return this},y.prototype.swap32=function(){var e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var r=0;r<e;r+=4)pe(this,r,r+3),pe(this,r+1,r+2);return this},y.prototype.swap64=function(){var e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var r=0;r<e;r+=8)pe(this,r,r+7),pe(this,r+1,r+6),pe(this,r+2,r+5),pe(this,r+3,r+4);return this},y.prototype.toString=function(){var e=this.length|0;return e===0?"":arguments.length===0?ni(this,0,e):ta.apply(this,arguments)},y.prototype.equals=function(e){if(!te(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:y.compare(this,e)===0},y.prototype.inspect=function(){var e="",r=Kr;return this.length>0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),"<Buffer "+e+">"},y.prototype.compare=function(e,r,i,n,s){if(!te(e))throw new TypeError("Argument must be a Buffer");if(r===void 0&&(r=0),i===void 0&&(i=e?e.length:0),n===void 0&&(n=0),s===void 0&&(s=this.length),r<0||i>e.length||n<0||s>this.length)throw new RangeError("out of range index");if(n>=s&&r>=i)return 0;if(n>=s)return-1;if(r>=i)return 1;if(r>>>=0,i>>>=0,n>>>=0,s>>>=0,this===e)return 0;for(var a=s-n,u=i-r,f=Math.min(a,u),g=this.slice(n,s),w=e.slice(r,i),b=0;b<f;++b)if(g[b]!==w[b]){a=g[b],u=w[b];break}return a<u?-1:u<a?1:0};function ti(t,e,r,i,n){if(t.length===0)return-1;if(typeof r=="string"?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=n?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(n)return-1;r=t.length-1}else if(r<0)if(n)r=0;else return-1;if(typeof e=="string"&&(e=y.from(e,i)),te(e))return e.length===0?-1:ri(t,e,r,i,n);if(typeof e=="number")return e=e&255,y.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?n?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):ri(t,[e],r,i,n);throw new TypeError("val must be string, number or Buffer")}function ri(t,e,r,i,n){var s=1,a=t.length,u=e.length;if(i!==void 0&&(i=String(i).toLowerCase(),i==="ucs2"||i==="ucs-2"||i==="utf16le"||i==="utf-16le")){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}function f(m,E){return s===1?m[E]:m.readUInt16BE(E*s)}var g;if(n){var w=-1;for(g=r;g<a;g++)if(f(t,g)===f(e,w===-1?0:g-w)){if(w===-1&&(w=g),g-w+1===u)return w*s}else w!==-1&&(g-=g-w),w=-1}else for(r+u>a&&(r=a-u),g=r;g>=0;g--){for(var b=!0,_=0;_<u;_++)if(f(t,g+_)!==f(e,_)){b=!1;break}if(b)return g}return-1}y.prototype.includes=function(e,r,i){return this.indexOf(e,r,i)!==-1},y.prototype.indexOf=function(e,r,i){return ti(this,e,r,i,!0)},y.prototype.lastIndexOf=function(e,r,i){return ti(this,e,r,i,!1)};function ra(t,e,r,i){r=Number(r)||0;var n=t.length-r;i?(i=Number(i),i>n&&(i=n)):i=n;var s=e.length;if(s%2!==0)throw new TypeError("Invalid hex string");i>s/2&&(i=s/2);for(var a=0;a<i;++a){var u=parseInt(e.substr(a*2,2),16);if(isNaN(u))return a;t[r+a]=u}return a}function ia(t,e,r,i){return et(Ze(e,t.length-r),t,r,i)}function ii(t,e,r,i){return et(ya(e),t,r,i)}function na(t,e,r,i){return ii(t,e,r,i)}function aa(t,e,r,i){return et(ui(e),t,r,i)}function sa(t,e,r,i){return et(ba(e,t.length-r),t,r,i)}y.prototype.write=function(e,r,i,n){if(r===void 0)n="utf8",i=this.length,r=0;else if(i===void 0&&typeof r=="string")n=r,i=this.length,r=0;else if(isFinite(r))r=r|0,isFinite(i)?(i=i|0,n===void 0&&(n="utf8")):(n=i,i=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var s=this.length-r;if((i===void 0||i>s)&&(i=s),e.length>0&&(i<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var a=!1;;)switch(n){case"hex":return ra(this,e,r,i);case"utf8":case"utf-8":return ia(this,e,r,i);case"ascii":return ii(this,e,r,i);case"latin1":case"binary":return na(this,e,r,i);case"base64":return aa(this,e,r,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return sa(this,e,r,i);default:if(a)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),a=!0}},y.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function oa(t,e,r){return e===0&&r===t.length?Hr(t):Hr(t.slice(e,r))}function ni(t,e,r){r=Math.min(t.length,r);for(var i=[],n=e;n<r;){var s=t[n],a=null,u=s>239?4:s>223?3:s>191?2:1;if(n+u<=r){var f,g,w,b;switch(u){case 1:s<128&&(a=s);break;case 2:f=t[n+1],(f&192)===128&&(b=(s&31)<<6|f&63,b>127&&(a=b));break;case 3:f=t[n+1],g=t[n+2],(f&192)===128&&(g&192)===128&&(b=(s&15)<<12|(f&63)<<6|g&63,b>2047&&(b<55296||b>57343)&&(a=b));break;case 4:f=t[n+1],g=t[n+2],w=t[n+3],(f&192)===128&&(g&192)===128&&(w&192)===128&&(b=(s&15)<<18|(f&63)<<12|(g&63)<<6|w&63,b>65535&&b<1114112&&(a=b))}}a===null?(a=65533,u=1):a>65535&&(a-=65536,i.push(a>>>10&1023|55296),a=56320|a&1023),i.push(a),n+=u}return la(i)}var ai=4096;function la(t){var e=t.length;if(e<=ai)return String.fromCharCode.apply(String,t);for(var r="",i=0;i<e;)r+=String.fromCharCode.apply(String,t.slice(i,i+=ai));return r}function ua(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;n<r;++n)i+=String.fromCharCode(t[n]&127);return i}function fa(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;n<r;++n)i+=String.fromCharCode(t[n]);return i}function ca(t,e,r){var i=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>i)&&(r=i);for(var n="",s=e;s<r;++s)n+=pa(t[s]);return n}function ha(t,e,r){for(var i=t.slice(e,r),n="",s=0;s<i.length;s+=2)n+=String.fromCharCode(i[s]+i[s+1]*256);return n}y.prototype.slice=function(e,r){var i=this.length;e=~~e,r=r===void 0?i:~~r,e<0?(e+=i,e<0&&(e=0)):e>i&&(e=i),r<0?(r+=i,r<0&&(r=0)):r>i&&(r=i),r<e&&(r=e);var n;if(y.TYPED_ARRAY_SUPPORT)n=this.subarray(e,r),n.__proto__=y.prototype;else{var s=r-e;n=new y(s,void 0);for(var a=0;a<s;++a)n[a]=this[a+e]}return n};function z(t,e,r){if(t%1!==0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}y.prototype.readUIntLE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e],s=1,a=0;++a<r&&(s*=256);)n+=this[e+a]*s;return n},y.prototype.readUIntBE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e+--r],s=1;r>0&&(s*=256);)n+=this[e+--r]*s;return n},y.prototype.readUInt8=function(e,r){return r||z(e,1,this.length),this[e]},y.prototype.readUInt16LE=function(e,r){return r||z(e,2,this.length),this[e]|this[e+1]<<8},y.prototype.readUInt16BE=function(e,r){return r||z(e,2,this.length),this[e]<<8|this[e+1]},y.prototype.readUInt32LE=function(e,r){return r||z(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},y.prototype.readUInt32BE=function(e,r){return r||z(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},y.prototype.readIntLE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e],s=1,a=0;++a<r&&(s*=256);)n+=this[e+a]*s;return s*=128,n>=s&&(n-=Math.pow(2,8*r)),n},y.prototype.readIntBE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=r,s=1,a=this[e+--n];n>0&&(s*=256);)a+=this[e+--n]*s;return s*=128,a>=s&&(a-=Math.pow(2,8*r)),a},y.prototype.readInt8=function(e,r){return r||z(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},y.prototype.readInt16LE=function(e,r){r||z(e,2,this.length);var i=this[e]|this[e+1]<<8;return i&32768?i|4294901760:i},y.prototype.readInt16BE=function(e,r){r||z(e,2,this.length);var i=this[e+1]|this[e]<<8;return i&32768?i|4294901760:i},y.prototype.readInt32LE=function(e,r){return r||z(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},y.prototype.readInt32BE=function(e,r){return r||z(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},y.prototype.readFloatLE=function(e,r){return r||z(e,4,this.length),Je(this,e,!0,23,4)},y.prototype.readFloatBE=function(e,r){return r||z(e,4,this.length),Je(this,e,!1,23,4)},y.prototype.readDoubleLE=function(e,r){return r||z(e,8,this.length),Je(this,e,!0,52,8)},y.prototype.readDoubleBE=function(e,r){return r||z(e,8,this.length),Je(this,e,!1,52,8)};function $(t,e,r,i,n,s){if(!te(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>n||e<s)throw new RangeError('"value" argument is out of bounds');if(r+i>t.length)throw new RangeError("Index out of range")}y.prototype.writeUIntLE=function(e,r,i,n){if(e=+e,r=r|0,i=i|0,!n){var s=Math.pow(2,8*i)-1;$(this,e,r,i,s,0)}var a=1,u=0;for(this[r]=e&255;++u<i&&(a*=256);)this[r+u]=e/a&255;return r+i},y.prototype.writeUIntBE=function(e,r,i,n){if(e=+e,r=r|0,i=i|0,!n){var s=Math.pow(2,8*i)-1;$(this,e,r,i,s,0)}var a=i-1,u=1;for(this[r+a]=e&255;--a>=0&&(u*=256);)this[r+a]=e/u&255;return r+i},y.prototype.writeUInt8=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,1,255,0),y.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[r]=e&255,r+1};function Ke(t,e,r,i){e<0&&(e=65535+e+1);for(var n=0,s=Math.min(t.length-r,2);n<s;++n)t[r+n]=(e&255<<8*(i?n:1-n))>>>(i?n:1-n)*8}y.prototype.writeUInt16LE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,2,65535,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8):Ke(this,e,r,!0),r+2},y.prototype.writeUInt16BE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,2,65535,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>8,this[r+1]=e&255):Ke(this,e,r,!1),r+2};function Qe(t,e,r,i){e<0&&(e=4294967295+e+1);for(var n=0,s=Math.min(t.length-r,4);n<s;++n)t[r+n]=e>>>(i?n:3-n)*8&255}y.prototype.writeUInt32LE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,4,4294967295,0),y.TYPED_ARRAY_SUPPORT?(this[r+3]=e>>>24,this[r+2]=e>>>16,this[r+1]=e>>>8,this[r]=e&255):Qe(this,e,r,!0),r+4},y.prototype.writeUInt32BE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,4,4294967295,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255):Qe(this,e,r,!1),r+4},y.prototype.writeIntLE=function(e,r,i,n){if(e=+e,r=r|0,!n){var s=Math.pow(2,8*i-1);$(this,e,r,i,s-1,-s)}var a=0,u=1,f=0;for(this[r]=e&255;++a<i&&(u*=256);)e<0&&f===0&&this[r+a-1]!==0&&(f=1),this[r+a]=(e/u>>0)-f&255;return r+i},y.prototype.writeIntBE=function(e,r,i,n){if(e=+e,r=r|0,!n){var s=Math.pow(2,8*i-1);$(this,e,r,i,s-1,-s)}var a=i-1,u=1,f=0;for(this[r+a]=e&255;--a>=0&&(u*=256);)e<0&&f===0&&this[r+a+1]!==0&&(f=1),this[r+a]=(e/u>>0)-f&255;return r+i},y.prototype.writeInt8=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,1,127,-128),y.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[r]=e&255,r+1},y.prototype.writeInt16LE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,2,32767,-32768),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8):Ke(this,e,r,!0),r+2},y.prototype.writeInt16BE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,2,32767,-32768),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>8,this[r+1]=e&255):Ke(this,e,r,!1),r+2},y.prototype.writeInt32LE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,4,2147483647,-2147483648),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8,this[r+2]=e>>>16,this[r+3]=e>>>24):Qe(this,e,r,!0),r+4},y.prototype.writeInt32BE=function(e,r,i){return e=+e,r=r|0,i||$(this,e,r,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255):Qe(this,e,r,!1),r+4};function si(t,e,r,i,n,s){if(r+i>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function oi(t,e,r,i,n){return n||si(t,e,r,4),Jr(t,e,r,i,23,4),r+4}y.prototype.writeFloatLE=function(e,r,i){return oi(this,e,r,!0,i)},y.prototype.writeFloatBE=function(e,r,i){return oi(this,e,r,!1,i)};function li(t,e,r,i,n){return n||si(t,e,r,8),Jr(t,e,r,i,52,8),r+8}y.prototype.writeDoubleLE=function(e,r,i){return li(this,e,r,!0,i)},y.prototype.writeDoubleBE=function(e,r,i){return li(this,e,r,!1,i)},y.prototype.copy=function(e,r,i,n){if(i||(i=0),!n&&n!==0&&(n=this.length),r>=e.length&&(r=e.length),r||(r=0),n>0&&n<i&&(n=i),n===i||e.length===0||this.length===0)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-r<n-i&&(n=e.length-r+i);var s=n-i,a;if(this===e&&i<r&&r<n)for(a=s-1;a>=0;--a)e[a+r]=this[a+i];else if(s<1e3||!y.TYPED_ARRAY_SUPPORT)for(a=0;a<s;++a)e[a+r]=this[a+i];else Uint8Array.prototype.set.call(e,this.subarray(i,i+s),r);return s},y.prototype.fill=function(e,r,i,n){if(typeof e=="string"){if(typeof r=="string"?(n=r,r=0,i=this.length):typeof i=="string"&&(n=i,i=this.length),e.length===1){var s=e.charCodeAt(0);s<256&&(e=s)}if(n!==void 0&&typeof n!="string")throw new TypeError("encoding must be a string");if(typeof n=="string"&&!y.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else typeof e=="number"&&(e=e&255);if(r<0||this.length<r||this.length<i)throw new RangeError("Out of range index");if(i<=r)return this;r=r>>>0,i=i===void 0?this.length:i>>>0,e||(e=0);var a;if(typeof e=="number")for(a=r;a<i;++a)this[a]=e;else{var u=te(e)?e:Ze(new y(e,n).toString()),f=u.length;for(a=0;a<i-r;++a)this[a+r]=u[a%f]}return this};var da=/[^+\/0-9A-Za-z-_]/g;function ga(t){if(t=_a(t).replace(da,""),t.length<2)return"";for(;t.length%4!==0;)t=t+"=";return t}function _a(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function pa(t){return t<16?"0"+t.toString(16):t.toString(16)}function Ze(t,e){e=e||1/0;for(var r,i=t.length,n=null,s=[],a=0;a<i;++a){if(r=t.charCodeAt(a),r>55295&&r<57344){if(!n){if(r>56319){(e-=3)>-1&&s.push(239,191,189);continue}else if(a+1===i){(e-=3)>-1&&s.push(239,191,189);continue}n=r;continue}if(r<56320){(e-=3)>-1&&s.push(239,191,189),n=r;continue}r=(n-55296<<10|r-56320)+65536}else n&&(e-=3)>-1&&s.push(239,191,189);if(n=null,r<128){if((e-=1)<0)break;s.push(r)}else if(r<2048){if((e-=2)<0)break;s.push(r>>6|192,r&63|128)}else if(r<65536){if((e-=3)<0)break;s.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((e-=4)<0)break;s.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else throw new Error("Invalid code point")}return s}function ya(t){for(var e=[],r=0;r<t.length;++r)e.push(t.charCodeAt(r)&255);return e}function ba(t,e){for(var r,i,n,s=[],a=0;a<t.length&&!((e-=2)<0);++a)r=t.charCodeAt(a),i=r>>8,n=r%256,s.push(n),s.push(i);return s}function ui(t){return $n(ga(t))}function et(t,e,r,i){for(var n=0;n<i&&!(n+r>=e.length||n>=t.length);++n)e[n+r]=t[n];return n}function wa(t){return t!==t}function fi(t){return t!=null&&(!!t._isBuffer||ci(t)||ma(t))}function ci(t){return!!t.constructor&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)}function ma(t){return typeof t.readFloatLE=="function"&&typeof t.slice=="function"&&ci(t.slice(0,0))}const tt=Tt(Object.freeze(Object.defineProperty({__proto__:null,Buffer:y,INSPECT_MAX_BYTES:Kr,SlowBuffer:ea,isBuffer:fi,kMaxLength:Jn},Symbol.toStringTag,{value:"Module"})));var Mt;typeof Object.create=="function"?Mt=function(e,r){e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:Mt=function(e,r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e};const hi=Mt;var va=/%[sdj%]/g;function rt(t){if(!Pe(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(re(arguments[r]));return e.join(" ")}for(var r=1,i=arguments,n=i.length,s=String(t).replace(va,function(u){if(u==="%%")return"%";if(r>=n)return u;switch(u){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch{return"[Circular]"}default:return u}}),a=i[r];r<n;a=i[++r])ke(a)||!ye(a)?s+=" "+a:s+=" "+re(a);return s}function kt(t,e){if(ie(Ee.process))return function(){return kt(t,e).apply(this,arguments)};if(I.noDeprecation===!0)return t;var r=!1;function i(){if(!r){if(I.throwDeprecation)throw new Error(e);I.traceDeprecation?console.trace(e):console.error(e),r=!0}return t.apply(this,arguments)}return i}var it={},Pt;function di(t){if(ie(Pt)&&(Pt=I.env.NODE_DEBUG||""),t=t.toUpperCase(),!it[t])if(new RegExp("\\b"+t+"\\b","i").test(Pt)){var e=0;it[t]=function(){var r=rt.apply(null,arguments);console.error("%s %d: %s",t,e,r)}}else it[t]=function(){};return it[t]}function re(t,e){var r={seen:[],stylize:xa};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),at(e)?r.showHidden=e:e&&jt(r,e),ie(r.showHidden)&&(r.showHidden=!1),ie(r.depth)&&(r.depth=2),ie(r.colors)&&(r.colors=!1),ie(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=Ea),nt(r,t,r.depth)}re.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},re.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function Ea(t,e){var r=re.styles[e];return r?"\x1B["+re.colors[r][0]+"m"+t+"\x1B["+re.colors[r][1]+"m":t}function xa(t,e){return t}function Ra(t){var e={};return t.forEach(function(r,i){e[r]=!0}),e}function nt(t,e,r){if(t.customInspect&&e&&Be(e.inspect)&&e.inspect!==re&&!(e.constructor&&e.constructor.prototype===e)){var i=e.inspect(r,t);return Pe(i)||(i=nt(t,i,r)),i}var n=Ta(t,e);if(n)return n;var s=Object.keys(e),a=Ra(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(e)),Ie(e)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return Nt(e);if(s.length===0){if(Be(e)){var u=e.name?": "+e.name:"";return t.stylize("[Function"+u+"]","special")}if(Ne(e))return t.stylize(RegExp.prototype.toString.call(e),"regexp");if(st(e))return t.stylize(Date.prototype.toString.call(e),"date");if(Ie(e))return Nt(e)}var f="",g=!1,w=["{","}"];if(Bt(e)&&(g=!0,w=["[","]"]),Be(e)){var b=e.name?": "+e.name:"";f=" [Function"+b+"]"}if(Ne(e)&&(f=" "+RegExp.prototype.toString.call(e)),st(e)&&(f=" "+Date.prototype.toUTCString.call(e)),Ie(e)&&(f=" "+Nt(e)),s.length===0&&(!g||e.length==0))return w[0]+f+w[1];if(r<0)return Ne(e)?t.stylize(RegExp.prototype.toString.call(e),"regexp"):t.stylize("[Object]","special");t.seen.push(e);var _;return g?_=Sa(t,e,r,a,s):_=s.map(function(m){return It(t,e,r,a,m,g)}),t.seen.pop(),Ca(_,f,w)}function Ta(t,e){if(ie(e))return t.stylize("undefined","undefined");if(Pe(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}if(Lt(e))return t.stylize(""+e,"number");if(at(e))return t.stylize(""+e,"boolean");if(ke(e))return t.stylize("null","null")}function Nt(t){return"["+Error.prototype.toString.call(t)+"]"}function Sa(t,e,r,i,n){for(var s=[],a=0,u=e.length;a<u;++a)wi(e,String(a))?s.push(It(t,e,r,i,String(a),!0)):s.push("");return n.forEach(function(f){f.match(/^\d+$/)||s.push(It(t,e,r,i,f,!0))}),s}function It(t,e,r,i,n,s){var a,u,f;if(f=Object.getOwnPropertyDescriptor(e,n)||{value:e[n]},f.get?f.set?u=t.stylize("[Getter/Setter]","special"):u=t.stylize("[Getter]","special"):f.set&&(u=t.stylize("[Setter]","special")),wi(i,n)||(a="["+n+"]"),u||(t.seen.indexOf(f.value)<0?(ke(r)?u=nt(t,f.value,null):u=nt(t,f.value,r-1),u.indexOf(`
|
|
11
|
+
*/var Qr=50;y.TYPED_ARRAY_SUPPORT=Ee.TYPED_ARRAY_SUPPORT!==void 0?Ee.TYPED_ARRAY_SUPPORT:!0;var Xn=Xe();function Xe(){return y.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function oe(t,e){if(Xe()<e)throw new RangeError("Invalid typed array length");return y.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e),t.__proto__=y.prototype):(t===null&&(t=new y(e)),t.length=e),t}function y(t,e,r){if(!y.TYPED_ARRAY_SUPPORT&&!(this instanceof y))return new y(t,e,r);if(typeof t=="number"){if(typeof e=="string")throw new Error("If encoding is specified then the first argument must be a string");return Ft(this,t)}return Zr(this,t,e,r)}y.poolSize=8192,y._augment=function(t){return t.__proto__=y.prototype,t};function Zr(t,e,r,i){if(typeof e=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer?Zn(t,e,r,i):typeof e=="string"?Qn(t,e,r):ea(t,e)}y.from=function(t,e,r){return Zr(null,t,e,r)},y.TYPED_ARRAY_SUPPORT&&(y.prototype.__proto__=Uint8Array.prototype,y.__proto__=Uint8Array);function ei(t){if(typeof t!="number")throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function Kn(t,e,r,i){return ei(e),e<=0?oe(t,e):r!==void 0?typeof i=="string"?oe(t,e).fill(r,i):oe(t,e).fill(r):oe(t,e)}y.alloc=function(t,e,r){return Kn(null,t,e,r)};function Ft(t,e){if(ei(e),t=oe(t,e<0?0:Dt(e)|0),!y.TYPED_ARRAY_SUPPORT)for(var r=0;r<e;++r)t[r]=0;return t}y.allocUnsafe=function(t){return Ft(null,t)},y.allocUnsafeSlow=function(t){return Ft(null,t)};function Qn(t,e,r){if((typeof r!="string"||r==="")&&(r="utf8"),!y.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var i=ti(e,r)|0;t=oe(t,i);var n=t.write(e,r);return n!==i&&(t=t.slice(0,n)),t}function Ot(t,e){var r=e.length<0?0:Dt(e.length)|0;t=oe(t,r);for(var i=0;i<r;i+=1)t[i]=e[i]&255;return t}function Zn(t,e,r,i){if(e.byteLength,r<0||e.byteLength<r)throw new RangeError("'offset' is out of bounds");if(e.byteLength<r+(i||0))throw new RangeError("'length' is out of bounds");return r===void 0&&i===void 0?e=new Uint8Array(e):i===void 0?e=new Uint8Array(e,r):e=new Uint8Array(e,r,i),y.TYPED_ARRAY_SUPPORT?(t=e,t.__proto__=y.prototype):t=Ot(t,e),t}function ea(t,e){if(te(e)){var r=Dt(e.length)|0;return t=oe(t,r),t.length===0||e.copy(t,0,0,r),t}if(e){if(typeof ArrayBuffer<"u"&&e.buffer instanceof ArrayBuffer||"length"in e)return typeof e.length!="number"||ma(e.length)?oe(t,0):Ot(t,e);if(e.type==="Buffer"&&Kr(e.data))return Ot(t,e.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function Dt(t){if(t>=Xe())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Xe().toString(16)+" bytes");return t|0}function ta(t){return+t!=t&&(t=0),y.alloc(+t)}y.isBuffer=ci;function te(t){return!!(t!=null&&t._isBuffer)}y.compare=function(e,r){if(!te(e)||!te(r))throw new TypeError("Arguments must be Buffers");if(e===r)return 0;for(var i=e.length,n=r.length,s=0,a=Math.min(i,n);s<a;++s)if(e[s]!==r[s]){i=e[s],n=r[s];break}return i<n?-1:n<i?1:0},y.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},y.concat=function(e,r){if(!Kr(e))throw new TypeError('"list" argument must be an Array of Buffers');if(e.length===0)return y.alloc(0);var i;if(r===void 0)for(r=0,i=0;i<e.length;++i)r+=e[i].length;var n=y.allocUnsafe(r),s=0;for(i=0;i<e.length;++i){var a=e[i];if(!te(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(n,s),s+=a.length}return n};function ti(t,e){if(te(t))return t.length;if(typeof ArrayBuffer<"u"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;typeof t!="string"&&(t=""+t);var r=t.length;if(r===0)return 0;for(var i=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return Ze(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return r*2;case"hex":return r>>>1;case"base64":return fi(t).length;default:if(i)return Ze(t).length;e=(""+e).toLowerCase(),i=!0}}y.byteLength=ti;function ra(t,e,r){var i=!1;if((e===void 0||e<0)&&(e=0),e>this.length||((r===void 0||r>this.length)&&(r=this.length),r<=0)||(r>>>=0,e>>>=0,r<=e))return"";for(t||(t="utf8");;)switch(t){case"hex":return ha(this,e,r);case"utf8":case"utf-8":return ai(this,e,r);case"ascii":return fa(this,e,r);case"latin1":case"binary":return ca(this,e,r);case"base64":return la(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return da(this,e,r);default:if(i)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),i=!0}}y.prototype._isBuffer=!0;function pe(t,e,r){var i=t[e];t[e]=t[r],t[r]=i}y.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var r=0;r<e;r+=2)pe(this,r,r+1);return this},y.prototype.swap32=function(){var e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var r=0;r<e;r+=4)pe(this,r,r+3),pe(this,r+1,r+2);return this},y.prototype.swap64=function(){var e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var r=0;r<e;r+=8)pe(this,r,r+7),pe(this,r+1,r+6),pe(this,r+2,r+5),pe(this,r+3,r+4);return this},y.prototype.toString=function(){var e=this.length|0;return e===0?"":arguments.length===0?ai(this,0,e):ra.apply(this,arguments)},y.prototype.equals=function(e){if(!te(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:y.compare(this,e)===0},y.prototype.inspect=function(){var e="",r=Qr;return this.length>0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),"<Buffer "+e+">"},y.prototype.compare=function(e,r,i,n,s){if(!te(e))throw new TypeError("Argument must be a Buffer");if(r===void 0&&(r=0),i===void 0&&(i=e?e.length:0),n===void 0&&(n=0),s===void 0&&(s=this.length),r<0||i>e.length||n<0||s>this.length)throw new RangeError("out of range index");if(n>=s&&r>=i)return 0;if(n>=s)return-1;if(r>=i)return 1;if(r>>>=0,i>>>=0,n>>>=0,s>>>=0,this===e)return 0;for(var a=s-n,u=i-r,f=Math.min(a,u),g=this.slice(n,s),w=e.slice(r,i),b=0;b<f;++b)if(g[b]!==w[b]){a=g[b],u=w[b];break}return a<u?-1:u<a?1:0};function ri(t,e,r,i,n){if(t.length===0)return-1;if(typeof r=="string"?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=n?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(n)return-1;r=t.length-1}else if(r<0)if(n)r=0;else return-1;if(typeof e=="string"&&(e=y.from(e,i)),te(e))return e.length===0?-1:ii(t,e,r,i,n);if(typeof e=="number")return e=e&255,y.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?n?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):ii(t,[e],r,i,n);throw new TypeError("val must be string, number or Buffer")}function ii(t,e,r,i,n){var s=1,a=t.length,u=e.length;if(i!==void 0&&(i=String(i).toLowerCase(),i==="ucs2"||i==="ucs-2"||i==="utf16le"||i==="utf-16le")){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}function f(m,E){return s===1?m[E]:m.readUInt16BE(E*s)}var g;if(n){var w=-1;for(g=r;g<a;g++)if(f(t,g)===f(e,w===-1?0:g-w)){if(w===-1&&(w=g),g-w+1===u)return w*s}else w!==-1&&(g-=g-w),w=-1}else for(r+u>a&&(r=a-u),g=r;g>=0;g--){for(var b=!0,_=0;_<u;_++)if(f(t,g+_)!==f(e,_)){b=!1;break}if(b)return g}return-1}y.prototype.includes=function(e,r,i){return this.indexOf(e,r,i)!==-1},y.prototype.indexOf=function(e,r,i){return ri(this,e,r,i,!0)},y.prototype.lastIndexOf=function(e,r,i){return ri(this,e,r,i,!1)};function ia(t,e,r,i){r=Number(r)||0;var n=t.length-r;i?(i=Number(i),i>n&&(i=n)):i=n;var s=e.length;if(s%2!==0)throw new TypeError("Invalid hex string");i>s/2&&(i=s/2);for(var a=0;a<i;++a){var u=parseInt(e.substr(a*2,2),16);if(isNaN(u))return a;t[r+a]=u}return a}function na(t,e,r,i){return et(Ze(e,t.length-r),t,r,i)}function ni(t,e,r,i){return et(ba(e),t,r,i)}function aa(t,e,r,i){return ni(t,e,r,i)}function sa(t,e,r,i){return et(fi(e),t,r,i)}function oa(t,e,r,i){return et(wa(e,t.length-r),t,r,i)}y.prototype.write=function(e,r,i,n){if(r===void 0)n="utf8",i=this.length,r=0;else if(i===void 0&&typeof r=="string")n=r,i=this.length,r=0;else if(isFinite(r))r=r|0,isFinite(i)?(i=i|0,n===void 0&&(n="utf8")):(n=i,i=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var s=this.length-r;if((i===void 0||i>s)&&(i=s),e.length>0&&(i<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var a=!1;;)switch(n){case"hex":return ia(this,e,r,i);case"utf8":case"utf-8":return na(this,e,r,i);case"ascii":return ni(this,e,r,i);case"latin1":case"binary":return aa(this,e,r,i);case"base64":return sa(this,e,r,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return oa(this,e,r,i);default:if(a)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),a=!0}},y.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function la(t,e,r){return e===0&&r===t.length?Jr(t):Jr(t.slice(e,r))}function ai(t,e,r){r=Math.min(t.length,r);for(var i=[],n=e;n<r;){var s=t[n],a=null,u=s>239?4:s>223?3:s>191?2:1;if(n+u<=r){var f,g,w,b;switch(u){case 1:s<128&&(a=s);break;case 2:f=t[n+1],(f&192)===128&&(b=(s&31)<<6|f&63,b>127&&(a=b));break;case 3:f=t[n+1],g=t[n+2],(f&192)===128&&(g&192)===128&&(b=(s&15)<<12|(f&63)<<6|g&63,b>2047&&(b<55296||b>57343)&&(a=b));break;case 4:f=t[n+1],g=t[n+2],w=t[n+3],(f&192)===128&&(g&192)===128&&(w&192)===128&&(b=(s&15)<<18|(f&63)<<12|(g&63)<<6|w&63,b>65535&&b<1114112&&(a=b))}}a===null?(a=65533,u=1):a>65535&&(a-=65536,i.push(a>>>10&1023|55296),a=56320|a&1023),i.push(a),n+=u}return ua(i)}var si=4096;function ua(t){var e=t.length;if(e<=si)return String.fromCharCode.apply(String,t);for(var r="",i=0;i<e;)r+=String.fromCharCode.apply(String,t.slice(i,i+=si));return r}function fa(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;n<r;++n)i+=String.fromCharCode(t[n]&127);return i}function ca(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;n<r;++n)i+=String.fromCharCode(t[n]);return i}function ha(t,e,r){var i=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>i)&&(r=i);for(var n="",s=e;s<r;++s)n+=ya(t[s]);return n}function da(t,e,r){for(var i=t.slice(e,r),n="",s=0;s<i.length;s+=2)n+=String.fromCharCode(i[s]+i[s+1]*256);return n}y.prototype.slice=function(e,r){var i=this.length;e=~~e,r=r===void 0?i:~~r,e<0?(e+=i,e<0&&(e=0)):e>i&&(e=i),r<0?(r+=i,r<0&&(r=0)):r>i&&(r=i),r<e&&(r=e);var n;if(y.TYPED_ARRAY_SUPPORT)n=this.subarray(e,r),n.__proto__=y.prototype;else{var s=r-e;n=new y(s,void 0);for(var a=0;a<s;++a)n[a]=this[a+e]}return n};function z(t,e,r){if(t%1!==0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}y.prototype.readUIntLE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e],s=1,a=0;++a<r&&(s*=256);)n+=this[e+a]*s;return n},y.prototype.readUIntBE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e+--r],s=1;r>0&&(s*=256);)n+=this[e+--r]*s;return n},y.prototype.readUInt8=function(e,r){return r||z(e,1,this.length),this[e]},y.prototype.readUInt16LE=function(e,r){return r||z(e,2,this.length),this[e]|this[e+1]<<8},y.prototype.readUInt16BE=function(e,r){return r||z(e,2,this.length),this[e]<<8|this[e+1]},y.prototype.readUInt32LE=function(e,r){return r||z(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},y.prototype.readUInt32BE=function(e,r){return r||z(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},y.prototype.readIntLE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=this[e],s=1,a=0;++a<r&&(s*=256);)n+=this[e+a]*s;return s*=128,n>=s&&(n-=Math.pow(2,8*r)),n},y.prototype.readIntBE=function(e,r,i){e=e|0,r=r|0,i||z(e,r,this.length);for(var n=r,s=1,a=this[e+--n];n>0&&(s*=256);)a+=this[e+--n]*s;return s*=128,a>=s&&(a-=Math.pow(2,8*r)),a},y.prototype.readInt8=function(e,r){return r||z(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},y.prototype.readInt16LE=function(e,r){r||z(e,2,this.length);var i=this[e]|this[e+1]<<8;return i&32768?i|4294901760:i},y.prototype.readInt16BE=function(e,r){r||z(e,2,this.length);var i=this[e+1]|this[e]<<8;return i&32768?i|4294901760:i},y.prototype.readInt32LE=function(e,r){return r||z(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},y.prototype.readInt32BE=function(e,r){return r||z(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},y.prototype.readFloatLE=function(e,r){return r||z(e,4,this.length),Je(this,e,!0,23,4)},y.prototype.readFloatBE=function(e,r){return r||z(e,4,this.length),Je(this,e,!1,23,4)},y.prototype.readDoubleLE=function(e,r){return r||z(e,8,this.length),Je(this,e,!0,52,8)},y.prototype.readDoubleBE=function(e,r){return r||z(e,8,this.length),Je(this,e,!1,52,8)};function G(t,e,r,i,n,s){if(!te(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>n||e<s)throw new RangeError('"value" argument is out of bounds');if(r+i>t.length)throw new RangeError("Index out of range")}y.prototype.writeUIntLE=function(e,r,i,n){if(e=+e,r=r|0,i=i|0,!n){var s=Math.pow(2,8*i)-1;G(this,e,r,i,s,0)}var a=1,u=0;for(this[r]=e&255;++u<i&&(a*=256);)this[r+u]=e/a&255;return r+i},y.prototype.writeUIntBE=function(e,r,i,n){if(e=+e,r=r|0,i=i|0,!n){var s=Math.pow(2,8*i)-1;G(this,e,r,i,s,0)}var a=i-1,u=1;for(this[r+a]=e&255;--a>=0&&(u*=256);)this[r+a]=e/u&255;return r+i},y.prototype.writeUInt8=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,1,255,0),y.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[r]=e&255,r+1};function Ke(t,e,r,i){e<0&&(e=65535+e+1);for(var n=0,s=Math.min(t.length-r,2);n<s;++n)t[r+n]=(e&255<<8*(i?n:1-n))>>>(i?n:1-n)*8}y.prototype.writeUInt16LE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,2,65535,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8):Ke(this,e,r,!0),r+2},y.prototype.writeUInt16BE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,2,65535,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>8,this[r+1]=e&255):Ke(this,e,r,!1),r+2};function Qe(t,e,r,i){e<0&&(e=4294967295+e+1);for(var n=0,s=Math.min(t.length-r,4);n<s;++n)t[r+n]=e>>>(i?n:3-n)*8&255}y.prototype.writeUInt32LE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,4,4294967295,0),y.TYPED_ARRAY_SUPPORT?(this[r+3]=e>>>24,this[r+2]=e>>>16,this[r+1]=e>>>8,this[r]=e&255):Qe(this,e,r,!0),r+4},y.prototype.writeUInt32BE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,4,4294967295,0),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255):Qe(this,e,r,!1),r+4},y.prototype.writeIntLE=function(e,r,i,n){if(e=+e,r=r|0,!n){var s=Math.pow(2,8*i-1);G(this,e,r,i,s-1,-s)}var a=0,u=1,f=0;for(this[r]=e&255;++a<i&&(u*=256);)e<0&&f===0&&this[r+a-1]!==0&&(f=1),this[r+a]=(e/u>>0)-f&255;return r+i},y.prototype.writeIntBE=function(e,r,i,n){if(e=+e,r=r|0,!n){var s=Math.pow(2,8*i-1);G(this,e,r,i,s-1,-s)}var a=i-1,u=1,f=0;for(this[r+a]=e&255;--a>=0&&(u*=256);)e<0&&f===0&&this[r+a+1]!==0&&(f=1),this[r+a]=(e/u>>0)-f&255;return r+i},y.prototype.writeInt8=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,1,127,-128),y.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[r]=e&255,r+1},y.prototype.writeInt16LE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,2,32767,-32768),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8):Ke(this,e,r,!0),r+2},y.prototype.writeInt16BE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,2,32767,-32768),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>8,this[r+1]=e&255):Ke(this,e,r,!1),r+2},y.prototype.writeInt32LE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,4,2147483647,-2147483648),y.TYPED_ARRAY_SUPPORT?(this[r]=e&255,this[r+1]=e>>>8,this[r+2]=e>>>16,this[r+3]=e>>>24):Qe(this,e,r,!0),r+4},y.prototype.writeInt32BE=function(e,r,i){return e=+e,r=r|0,i||G(this,e,r,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),y.TYPED_ARRAY_SUPPORT?(this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255):Qe(this,e,r,!1),r+4};function oi(t,e,r,i,n,s){if(r+i>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function li(t,e,r,i,n){return n||oi(t,e,r,4),Xr(t,e,r,i,23,4),r+4}y.prototype.writeFloatLE=function(e,r,i){return li(this,e,r,!0,i)},y.prototype.writeFloatBE=function(e,r,i){return li(this,e,r,!1,i)};function ui(t,e,r,i,n){return n||oi(t,e,r,8),Xr(t,e,r,i,52,8),r+8}y.prototype.writeDoubleLE=function(e,r,i){return ui(this,e,r,!0,i)},y.prototype.writeDoubleBE=function(e,r,i){return ui(this,e,r,!1,i)},y.prototype.copy=function(e,r,i,n){if(i||(i=0),!n&&n!==0&&(n=this.length),r>=e.length&&(r=e.length),r||(r=0),n>0&&n<i&&(n=i),n===i||e.length===0||this.length===0)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-r<n-i&&(n=e.length-r+i);var s=n-i,a;if(this===e&&i<r&&r<n)for(a=s-1;a>=0;--a)e[a+r]=this[a+i];else if(s<1e3||!y.TYPED_ARRAY_SUPPORT)for(a=0;a<s;++a)e[a+r]=this[a+i];else Uint8Array.prototype.set.call(e,this.subarray(i,i+s),r);return s},y.prototype.fill=function(e,r,i,n){if(typeof e=="string"){if(typeof r=="string"?(n=r,r=0,i=this.length):typeof i=="string"&&(n=i,i=this.length),e.length===1){var s=e.charCodeAt(0);s<256&&(e=s)}if(n!==void 0&&typeof n!="string")throw new TypeError("encoding must be a string");if(typeof n=="string"&&!y.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else typeof e=="number"&&(e=e&255);if(r<0||this.length<r||this.length<i)throw new RangeError("Out of range index");if(i<=r)return this;r=r>>>0,i=i===void 0?this.length:i>>>0,e||(e=0);var a;if(typeof e=="number")for(a=r;a<i;++a)this[a]=e;else{var u=te(e)?e:Ze(new y(e,n).toString()),f=u.length;for(a=0;a<i-r;++a)this[a+r]=u[a%f]}return this};var ga=/[^+\/0-9A-Za-z-_]/g;function _a(t){if(t=pa(t).replace(ga,""),t.length<2)return"";for(;t.length%4!==0;)t=t+"=";return t}function pa(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function ya(t){return t<16?"0"+t.toString(16):t.toString(16)}function Ze(t,e){e=e||1/0;for(var r,i=t.length,n=null,s=[],a=0;a<i;++a){if(r=t.charCodeAt(a),r>55295&&r<57344){if(!n){if(r>56319){(e-=3)>-1&&s.push(239,191,189);continue}else if(a+1===i){(e-=3)>-1&&s.push(239,191,189);continue}n=r;continue}if(r<56320){(e-=3)>-1&&s.push(239,191,189),n=r;continue}r=(n-55296<<10|r-56320)+65536}else n&&(e-=3)>-1&&s.push(239,191,189);if(n=null,r<128){if((e-=1)<0)break;s.push(r)}else if(r<2048){if((e-=2)<0)break;s.push(r>>6|192,r&63|128)}else if(r<65536){if((e-=3)<0)break;s.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((e-=4)<0)break;s.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else throw new Error("Invalid code point")}return s}function ba(t){for(var e=[],r=0;r<t.length;++r)e.push(t.charCodeAt(r)&255);return e}function wa(t,e){for(var r,i,n,s=[],a=0;a<t.length&&!((e-=2)<0);++a)r=t.charCodeAt(a),i=r>>8,n=r%256,s.push(n),s.push(i);return s}function fi(t){return Gn(_a(t))}function et(t,e,r,i){for(var n=0;n<i&&!(n+r>=e.length||n>=t.length);++n)e[n+r]=t[n];return n}function ma(t){return t!==t}function ci(t){return t!=null&&(!!t._isBuffer||hi(t)||va(t))}function hi(t){return!!t.constructor&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)}function va(t){return typeof t.readFloatLE=="function"&&typeof t.slice=="function"&&hi(t.slice(0,0))}const tt=Tt(Object.freeze(Object.defineProperty({__proto__:null,Buffer:y,INSPECT_MAX_BYTES:Qr,SlowBuffer:ta,isBuffer:ci,kMaxLength:Xn},Symbol.toStringTag,{value:"Module"})));var Mt;typeof Object.create=="function"?Mt=function(e,r){e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:Mt=function(e,r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e};const di=Mt;var Ea=/%[sdj%]/g;function rt(t){if(!Pe(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(re(arguments[r]));return e.join(" ")}for(var r=1,i=arguments,n=i.length,s=String(t).replace(Ea,function(u){if(u==="%%")return"%";if(r>=n)return u;switch(u){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch{return"[Circular]"}default:return u}}),a=i[r];r<n;a=i[++r])ke(a)||!ye(a)?s+=" "+a:s+=" "+re(a);return s}function kt(t,e){if(ie(Ee.process))return function(){return kt(t,e).apply(this,arguments)};if(I.noDeprecation===!0)return t;var r=!1;function i(){if(!r){if(I.throwDeprecation)throw new Error(e);I.traceDeprecation?console.trace(e):console.error(e),r=!0}return t.apply(this,arguments)}return i}var it={},Pt;function gi(t){if(ie(Pt)&&(Pt=I.env.NODE_DEBUG||""),t=t.toUpperCase(),!it[t])if(new RegExp("\\b"+t+"\\b","i").test(Pt)){var e=0;it[t]=function(){var r=rt.apply(null,arguments);console.error("%s %d: %s",t,e,r)}}else it[t]=function(){};return it[t]}function re(t,e){var r={seen:[],stylize:Ra};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),at(e)?r.showHidden=e:e&&jt(r,e),ie(r.showHidden)&&(r.showHidden=!1),ie(r.depth)&&(r.depth=2),ie(r.colors)&&(r.colors=!1),ie(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=xa),nt(r,t,r.depth)}re.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},re.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function xa(t,e){var r=re.styles[e];return r?"\x1B["+re.colors[r][0]+"m"+t+"\x1B["+re.colors[r][1]+"m":t}function Ra(t,e){return t}function Ta(t){var e={};return t.forEach(function(r,i){e[r]=!0}),e}function nt(t,e,r){if(t.customInspect&&e&&Be(e.inspect)&&e.inspect!==re&&!(e.constructor&&e.constructor.prototype===e)){var i=e.inspect(r,t);return Pe(i)||(i=nt(t,i,r)),i}var n=Sa(t,e);if(n)return n;var s=Object.keys(e),a=Ta(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(e)),Ie(e)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return Nt(e);if(s.length===0){if(Be(e)){var u=e.name?": "+e.name:"";return t.stylize("[Function"+u+"]","special")}if(Ne(e))return t.stylize(RegExp.prototype.toString.call(e),"regexp");if(st(e))return t.stylize(Date.prototype.toString.call(e),"date");if(Ie(e))return Nt(e)}var f="",g=!1,w=["{","}"];if(Bt(e)&&(g=!0,w=["[","]"]),Be(e)){var b=e.name?": "+e.name:"";f=" [Function"+b+"]"}if(Ne(e)&&(f=" "+RegExp.prototype.toString.call(e)),st(e)&&(f=" "+Date.prototype.toUTCString.call(e)),Ie(e)&&(f=" "+Nt(e)),s.length===0&&(!g||e.length==0))return w[0]+f+w[1];if(r<0)return Ne(e)?t.stylize(RegExp.prototype.toString.call(e),"regexp"):t.stylize("[Object]","special");t.seen.push(e);var _;return g?_=Ca(t,e,r,a,s):_=s.map(function(m){return It(t,e,r,a,m,g)}),t.seen.pop(),Aa(_,f,w)}function Sa(t,e){if(ie(e))return t.stylize("undefined","undefined");if(Pe(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}if(Lt(e))return t.stylize(""+e,"number");if(at(e))return t.stylize(""+e,"boolean");if(ke(e))return t.stylize("null","null")}function Nt(t){return"["+Error.prototype.toString.call(t)+"]"}function Ca(t,e,r,i,n){for(var s=[],a=0,u=e.length;a<u;++a)mi(e,String(a))?s.push(It(t,e,r,i,String(a),!0)):s.push("");return n.forEach(function(f){f.match(/^\d+$/)||s.push(It(t,e,r,i,f,!0))}),s}function It(t,e,r,i,n,s){var a,u,f;if(f=Object.getOwnPropertyDescriptor(e,n)||{value:e[n]},f.get?f.set?u=t.stylize("[Getter/Setter]","special"):u=t.stylize("[Getter]","special"):f.set&&(u=t.stylize("[Setter]","special")),mi(i,n)||(a="["+n+"]"),u||(t.seen.indexOf(f.value)<0?(ke(r)?u=nt(t,f.value,null):u=nt(t,f.value,r-1),u.indexOf(`
|
|
12
12
|
`)>-1&&(s?u=u.split(`
|
|
13
13
|
`).map(function(g){return" "+g}).join(`
|
|
14
14
|
`).substr(2):u=`
|
|
15
15
|
`+u.split(`
|
|
16
16
|
`).map(function(g){return" "+g}).join(`
|
|
17
|
-
`))):u=t.stylize("[Circular]","special")),ie(a)){if(s&&n.match(/^\d+$/))return u;a=JSON.stringify(""+n),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=t.stylize(a,"string"))}return a+": "+u}function
|
|
17
|
+
`))):u=t.stylize("[Circular]","special")),ie(a)){if(s&&n.match(/^\d+$/))return u;a=JSON.stringify(""+n),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=t.stylize(a,"string"))}return a+": "+u}function Aa(t,e,r){var i=t.reduce(function(n,s){return s.indexOf(`
|
|
18
18
|
`)>=0,n+s.replace(/\u001b\[\d\d?m/g,"").length+1},0);return i>60?r[0]+(e===""?"":e+`
|
|
19
19
|
`)+" "+t.join(`,
|
|
20
|
-
`)+" "+r[1]:r[0]+e+" "+t.join(", ")+" "+r[1]}function Bt(t){return Array.isArray(t)}function at(t){return typeof t=="boolean"}function ke(t){return t===null}function gi(t){return t==null}function Lt(t){return typeof t=="number"}function Pe(t){return typeof t=="string"}function _i(t){return typeof t=="symbol"}function ie(t){return t===void 0}function Ne(t){return ye(t)&&Ut(t)==="[object RegExp]"}function ye(t){return typeof t=="object"&&t!==null}function st(t){return ye(t)&&Ut(t)==="[object Date]"}function Ie(t){return ye(t)&&(Ut(t)==="[object Error]"||t instanceof Error)}function Be(t){return typeof t=="function"}function pi(t){return t===null||typeof t=="boolean"||typeof t=="number"||typeof t=="string"||typeof t=="symbol"||typeof t>"u"}function yi(t){return y.isBuffer(t)}function Ut(t){return Object.prototype.toString.call(t)}function Wt(t){return t<10?"0"+t.toString(10):t.toString(10)}var Aa=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Fa(){var t=new Date,e=[Wt(t.getHours()),Wt(t.getMinutes()),Wt(t.getSeconds())].join(":");return[t.getDate(),Aa[t.getMonth()],e].join(" ")}function bi(){console.log("%s - %s",Fa(),rt.apply(null,arguments))}function jt(t,e){if(!e||!ye(e))return t;for(var r=Object.keys(e),i=r.length;i--;)t[r[i]]=e[r[i]];return t}function wi(t,e){return Object.prototype.hasOwnProperty.call(t,e)}const mi=Tt(Object.freeze(Object.defineProperty({__proto__:null,format:rt,deprecate:kt,debuglog:di,inspect:re,isArray:Bt,isBoolean:at,isNull:ke,isNullOrUndefined:gi,isNumber:Lt,isString:Pe,isSymbol:_i,isUndefined:ie,isRegExp:Ne,isObject:ye,isDate:st,isError:Ie,isFunction:Be,isPrimitive:pi,isBuffer:yi,log:bi,inherits:hi,_extend:jt,default:{inherits:hi,_extend:jt,log:bi,isBuffer:yi,isPrimitive:pi,isFunction:Be,isError:Ie,isDate:st,isObject:ye,isRegExp:Ne,isUndefined:ie,isSymbol:_i,isString:Pe,isNumber:Lt,isNullOrUndefined:gi,isNull:ke,isBoolean:at,isArray:Bt,inspect:re,deprecate:kt,format:rt,debuglog:di}},Symbol.toStringTag,{value:"Module"})));var Yt,vi;function Oa(){if(vi)return Yt;vi=1;function t(_,m){var E=Object.keys(_);if(Object.getOwnPropertySymbols){var T=Object.getOwnPropertySymbols(_);m&&(T=T.filter(function(O){return Object.getOwnPropertyDescriptor(_,O).enumerable})),E.push.apply(E,T)}return E}function e(_){for(var m=1;m<arguments.length;m++){var E=arguments[m]!=null?arguments[m]:{};m%2?t(Object(E),!0).forEach(function(T){r(_,T,E[T])}):Object.getOwnPropertyDescriptors?Object.defineProperties(_,Object.getOwnPropertyDescriptors(E)):t(Object(E)).forEach(function(T){Object.defineProperty(_,T,Object.getOwnPropertyDescriptor(E,T))})}return _}function r(_,m,E){return m in _?Object.defineProperty(_,m,{value:E,enumerable:!0,configurable:!0,writable:!0}):_[m]=E,_}function i(_,m){if(!(_ instanceof m))throw new TypeError("Cannot call a class as a function")}function n(_,m){for(var E=0;E<m.length;E++){var T=m[E];T.enumerable=T.enumerable||!1,T.configurable=!0,"value"in T&&(T.writable=!0),Object.defineProperty(_,T.key,T)}}function s(_,m,E){return m&&n(_.prototype,m),E&&n(_,E),_}var a=tt,u=a.Buffer,f=mi,g=f.inspect,w=g&&g.custom||"inspect";function b(_,m,E){u.prototype.copy.call(_,m,E)}return Yt=function(){function _(){i(this,_),this.head=null,this.tail=null,this.length=0}return s(_,[{key:"push",value:function(E){var T={data:E,next:null};this.length>0?this.tail.next=T:this.head=T,this.tail=T,++this.length}},{key:"unshift",value:function(E){var T={data:E,next:this.head};this.length===0&&(this.tail=T),this.head=T,++this.length}},{key:"shift",value:function(){if(this.length!==0){var E=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,E}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(E){if(this.length===0)return"";for(var T=this.head,O=""+T.data;T=T.next;)O+=E+T.data;return O}},{key:"concat",value:function(E){if(this.length===0)return u.alloc(0);for(var T=u.allocUnsafe(E>>>0),O=this.head,c=0;O;)b(O.data,T,c),c+=O.data.length,O=O.next;return T}},{key:"consume",value:function(E,T){var O;return E<this.head.data.length?(O=this.head.data.slice(0,E),this.head.data=this.head.data.slice(E)):E===this.head.data.length?O=this.shift():O=T?this._getString(E):this._getBuffer(E),O}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(E){var T=this.head,O=1,c=T.data;for(E-=c.length;T=T.next;){var p=T.data,R=E>p.length?p.length:E;if(R===p.length?c+=p:c+=p.slice(0,E),E-=R,E===0){R===p.length?(++O,T.next?this.head=T.next:this.head=this.tail=null):(this.head=T,T.data=p.slice(R));break}++O}return this.length-=O,c}},{key:"_getBuffer",value:function(E){var T=u.allocUnsafe(E),O=this.head,c=1;for(O.data.copy(T),E-=O.data.length;O=O.next;){var p=O.data,R=E>p.length?p.length:E;if(p.copy(T,T.length-E,0,R),E-=R,E===0){R===p.length?(++c,O.next?this.head=O.next:this.head=this.tail=null):(this.head=O,O.data=p.slice(R));break}++c}return this.length-=c,T}},{key:w,value:function(E,T){return g(this,e({},T,{depth:0,customInspect:!1}))}}]),_}(),Yt}function Da(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,I.nextTick(zt,this,t)):I.nextTick(zt,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?I.nextTick(ot,r):(r._writableState.errorEmitted=!0,I.nextTick(Ei,r,s)):I.nextTick(Ei,r,s):e?(I.nextTick(ot,r),e(s)):I.nextTick(ot,r)}),this)}function Ei(t,e){zt(t,e),ot(t)}function ot(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function Ma(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function zt(t,e){t.emit("error",e)}function ka(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}var xi={destroy:Da,undestroy:Ma,errorOrDestroy:ka},be={};function Pa(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var Ri={};function J(t,e,r){r||(r=Error);function i(s,a,u){return typeof e=="string"?e:e(s,a,u)}var n=function(s){Pa(a,s);function a(u,f,g){return s.call(this,i(u,f,g))||this}return a}(r);n.prototype.name=r.name,n.prototype.code=t,Ri[t]=n}function Ti(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(i){return String(i)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:r===2?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}else return"of ".concat(e," ").concat(String(t))}function Na(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function Ia(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function Ba(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}J("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),J("ERR_INVALID_ARG_TYPE",function(t,e,r){var i;typeof e=="string"&&Na(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";var n;if(Ia(t," argument"))n="The ".concat(t," ").concat(i," ").concat(Ti(e,"type"));else{var s=Ba(t,".")?"property":"argument";n='The "'.concat(t,'" ').concat(s," ").concat(i," ").concat(Ti(e,"type"))}return n+=". Received type ".concat(typeof r),n},TypeError),J("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),J("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),J("ERR_STREAM_PREMATURE_CLOSE","Premature close"),J("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),J("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),J("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),J("ERR_STREAM_WRITE_AFTER_END","write after end"),J("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),J("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),J("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),be.codes=Ri;var La=be.codes.ERR_INVALID_OPT_VALUE;function Ua(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function Wa(t,e,r,i){var n=Ua(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new La(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}var Si={getHighWaterMark:Wa},ce={exports:{}};typeof Object.create=="function"?ce.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:ce.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}};var ja=Ya;function Ya(t,e){if(qt("noDeprecation"))return t;var r=!1;function i(){if(!r){if(qt("throwDeprecation"))throw new Error(e);qt("traceDeprecation")?console.trace(e):console.warn(e),r=!0}return t.apply(this,arguments)}return i}function qt(t){try{if(!He.localStorage)return!1}catch{return!1}var e=He.localStorage[t];return e==null?!1:String(e).toLowerCase()==="true"}var $t,Ci;function Ai(){if(Ci)return $t;Ci=1,$t=k;function t(d){var h=this;this.next=null,this.entry=null,this.finish=function(){lr(h,d)}}var e;k.WritableState=j;var r={deprecate:ja},i=Gr,n=tt.Buffer,s=He.Uint8Array||function(){};function a(d){return n.from(d)}function u(d){return n.isBuffer(d)||d instanceof s}var f=xi,g=Si,w=g.getHighWaterMark,b=be.codes,_=b.ERR_INVALID_ARG_TYPE,m=b.ERR_METHOD_NOT_IMPLEMENTED,E=b.ERR_MULTIPLE_CALLBACK,T=b.ERR_STREAM_CANNOT_PIPE,O=b.ERR_STREAM_DESTROYED,c=b.ERR_STREAM_NULL_VALUES,p=b.ERR_STREAM_WRITE_AFTER_END,R=b.ERR_UNKNOWN_ENCODING,A=f.errorOrDestroy;ce.exports(k,i);function M(){}function j(d,h,x){e=e||Te(),d=d||{},typeof x!="boolean"&&(x=h instanceof e),this.objectMode=!!d.objectMode,x&&(this.objectMode=this.objectMode||!!d.writableObjectMode),this.highWaterMark=w(this,d,"writableHighWaterMark",x),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var D=d.decodeStrings===!1;this.decodeStrings=!D,this.defaultEncoding=d.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(N){Q(h,N)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=d.emitClose!==!1,this.autoDestroy=!!d.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}j.prototype.getBuffer=function(){for(var h=this.bufferedRequest,x=[];h;)x.push(h),h=h.next;return x},function(){try{Object.defineProperty(j.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var q;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(q=Function.prototype[Symbol.hasInstance],Object.defineProperty(k,Symbol.hasInstance,{value:function(h){return q.call(this,h)?!0:this!==k?!1:h&&h._writableState instanceof j}})):q=function(h){return h instanceof this};function k(d){e=e||Te();var h=this instanceof e;if(!h&&!q.call(k,this))return new k(d);this._writableState=new j(d,this,h),this.writable=!0,d&&(typeof d.write=="function"&&(this._write=d.write),typeof d.writev=="function"&&(this._writev=d.writev),typeof d.destroy=="function"&&(this._destroy=d.destroy),typeof d.final=="function"&&(this._final=d.final)),i.call(this)}k.prototype.pipe=function(){A(this,new T)};function F(d,h){var x=new p;A(d,x),I.nextTick(h,x)}function U(d,h,x,D){var N;return x===null?N=new c:typeof x!="string"&&!h.objectMode&&(N=new _("chunk",["string","Buffer"],x)),N?(A(d,N),I.nextTick(D,N),!1):!0}k.prototype.write=function(d,h,x){var D=this._writableState,N=!1,o=!D.objectMode&&u(d);return o&&!n.isBuffer(d)&&(d=a(d)),typeof h=="function"&&(x=h,h=null),o?h="buffer":h||(h=D.defaultEncoding),typeof x!="function"&&(x=M),D.ending?F(this,x):(o||U(this,D,d,x))&&(D.pendingcb++,N=ne(this,D,o,d,h,x)),N},k.prototype.cork=function(){this._writableState.corked++},k.prototype.uncork=function(){var d=this._writableState;d.corked&&(d.corked--,!d.writing&&!d.corked&&!d.bufferProcessing&&d.bufferedRequest&&ae(this,d))},k.prototype.setDefaultEncoding=function(h){if(typeof h=="string"&&(h=h.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((h+"").toLowerCase())>-1))throw new R(h);return this._writableState.defaultEncoding=h,this},Object.defineProperty(k.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function V(d,h,x){return!d.objectMode&&d.decodeStrings!==!1&&typeof h=="string"&&(h=n.from(h,x)),h}Object.defineProperty(k.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function ne(d,h,x,D,N,o){if(!x){var l=V(h,D,N);D!==l&&(x=!0,N="buffer",D=l)}var v=h.objectMode?1:D.length;h.length+=v;var C=h.length<h.highWaterMark;if(C||(h.needDrain=!0),h.writing||h.corked){var W=h.lastBufferedRequest;h.lastBufferedRequest={chunk:D,encoding:N,isBuf:x,callback:o,next:null},W?W.next=h.lastBufferedRequest:h.bufferedRequest=h.lastBufferedRequest,h.bufferedRequestCount+=1}else X(d,h,!1,v,D,N,o);return C}function X(d,h,x,D,N,o,l){h.writelen=D,h.writecb=l,h.writing=!0,h.sync=!0,h.destroyed?h.onwrite(new O("write")):x?d._writev(N,h.onwrite):d._write(N,o,h.onwrite),h.sync=!1}function Y(d,h,x,D,N){--h.pendingcb,x?(I.nextTick(N,D),I.nextTick(me,d,h),d._writableState.errorEmitted=!0,A(d,D)):(N(D),d._writableState.errorEmitted=!0,A(d,D),me(d,h))}function K(d){d.writing=!1,d.writecb=null,d.length-=d.writelen,d.writelen=0}function Q(d,h){var x=d._writableState,D=x.sync,N=x.writecb;if(typeof N!="function")throw new E;if(K(x),h)Y(d,x,D,h,N);else{var o=_t(x)||d.destroyed;!o&&!x.corked&&!x.bufferProcessing&&x.bufferedRequest&&ae(d,x),D?I.nextTick(Z,d,x,o,N):Z(d,x,o,N)}}function Z(d,h,x,D){x||we(d,h),h.pendingcb--,D(),me(d,h)}function we(d,h){h.length===0&&h.needDrain&&(h.needDrain=!1,d.emit("drain"))}function ae(d,h){h.bufferProcessing=!0;var x=h.bufferedRequest;if(d._writev&&x&&x.next){var D=h.bufferedRequestCount,N=new Array(D),o=h.corkedRequestsFree;o.entry=x;for(var l=0,v=!0;x;)N[l]=x,x.isBuf||(v=!1),x=x.next,l+=1;N.allBuffers=v,X(d,h,!0,h.length,N,"",o.finish),h.pendingcb++,h.lastBufferedRequest=null,o.next?(h.corkedRequestsFree=o.next,o.next=null):h.corkedRequestsFree=new t(h),h.bufferedRequestCount=0}else{for(;x;){var C=x.chunk,W=x.encoding,P=x.callback,B=h.objectMode?1:C.length;if(X(d,h,!1,B,C,W,P),x=x.next,h.bufferedRequestCount--,h.writing)break}x===null&&(h.lastBufferedRequest=null)}h.bufferedRequest=x,h.bufferProcessing=!1}k.prototype._write=function(d,h,x){x(new m("_write()"))},k.prototype._writev=null,k.prototype.end=function(d,h,x){var D=this._writableState;return typeof d=="function"?(x=d,d=null,h=null):typeof h=="function"&&(x=h,h=null),d!=null&&this.write(d,h),D.corked&&(D.corked=1,this.uncork()),D.ending||or(this,D,x),this},Object.defineProperty(k.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function _t(d){return d.ending&&d.length===0&&d.bufferedRequest===null&&!d.finished&&!d.writing}function sr(d,h){d._final(function(x){h.pendingcb--,x&&A(d,x),h.prefinished=!0,d.emit("prefinish"),me(d,h)})}function pt(d,h){!h.prefinished&&!h.finalCalled&&(typeof d._final=="function"&&!h.destroyed?(h.pendingcb++,h.finalCalled=!0,I.nextTick(sr,d,h)):(h.prefinished=!0,d.emit("prefinish")))}function me(d,h){var x=_t(h);if(x&&(pt(d,h),h.pendingcb===0&&(h.finished=!0,d.emit("finish"),h.autoDestroy))){var D=d._readableState;(!D||D.autoDestroy&&D.endEmitted)&&d.destroy()}return x}function or(d,h,x){h.ending=!0,me(d,h),x&&(h.finished?I.nextTick(x):d.once("finish",x)),h.ended=!0,d.writable=!1}function lr(d,h,x){var D=d.entry;for(d.entry=null;D;){var N=D.callback;h.pendingcb--,N(x),D=D.next}h.corkedRequestsFree.next=d}return Object.defineProperty(k.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(h){!this._writableState||(this._writableState.destroyed=h)}}),k.prototype.destroy=f.destroy,k.prototype._undestroy=f.undestroy,k.prototype._destroy=function(d,h){h(d)},$t}var Gt,Fi;function Te(){if(Fi)return Gt;Fi=1;var t=Object.keys||function(g){var w=[];for(var b in g)w.push(b);return w};Gt=a;var e=Li(),r=Ai();ce.exports(a,e);for(var i=t(r.prototype),n=0;n<i.length;n++){var s=i[n];a.prototype[s]||(a.prototype[s]=r.prototype[s])}function a(g){if(!(this instanceof a))return new a(g);e.call(this,g),r.call(this,g),this.allowHalfOpen=!0,g&&(g.readable===!1&&(this.readable=!1),g.writable===!1&&(this.writable=!1),g.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",u)))}Object.defineProperty(a.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(a.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(a.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function u(){this._writableState.ended||I.nextTick(f,this)}function f(g){g.end()}return Object.defineProperty(a.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(w){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=w,this._writableState.destroyed=w)}}),Gt}var Vt={},lt={exports:{}},Oi;function za(){return Oi||(Oi=1,function(t,e){var r=tt,i=r.Buffer;function n(a,u){for(var f in a)u[f]=a[f]}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?t.exports=r:(n(r,e),e.Buffer=s);function s(a,u,f){return i(a,u,f)}n(i,s),s.from=function(a,u,f){if(typeof a=="number")throw new TypeError("Argument must not be a number");return i(a,u,f)},s.alloc=function(a,u,f){if(typeof a!="number")throw new TypeError("Argument must be a number");var g=i(a);return u!==void 0?typeof f=="string"?g.fill(u,f):g.fill(u):g.fill(0),g},s.allocUnsafe=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return i(a)},s.allocUnsafeSlow=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(a)}}(lt,lt.exports)),lt.exports}var Di;function Mi(){if(Di)return Vt;Di=1;var t=za().Buffer,e=t.isEncoding||function(c){switch(c=""+c,c&&c.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(c){if(!c)return"utf8";for(var p;;)switch(c){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return c;default:if(p)return;c=(""+c).toLowerCase(),p=!0}}function i(c){var p=r(c);if(typeof p!="string"&&(t.isEncoding===e||!e(c)))throw new Error("Unknown encoding: "+c);return p||c}Vt.StringDecoder=n;function n(c){this.encoding=i(c);var p;switch(this.encoding){case"utf16le":this.text=b,this.end=_,p=4;break;case"utf8":this.fillLast=f,p=4;break;case"base64":this.text=m,this.end=E,p=3;break;default:this.write=T,this.end=O;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(p)}n.prototype.write=function(c){if(c.length===0)return"";var p,R;if(this.lastNeed){if(p=this.fillLast(c),p===void 0)return"";R=this.lastNeed,this.lastNeed=0}else R=0;return R<c.length?p?p+this.text(c,R):this.text(c,R):p||""},n.prototype.end=w,n.prototype.text=g,n.prototype.fillLast=function(c){if(this.lastNeed<=c.length)return c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,c.length),this.lastNeed-=c.length};function s(c){return c<=127?0:c>>5===6?2:c>>4===14?3:c>>3===30?4:c>>6===2?-1:-2}function a(c,p,R){var A=p.length-1;if(A<R)return 0;var M=s(p[A]);return M>=0?(M>0&&(c.lastNeed=M-1),M):--A<R||M===-2?0:(M=s(p[A]),M>=0?(M>0&&(c.lastNeed=M-2),M):--A<R||M===-2?0:(M=s(p[A]),M>=0?(M>0&&(M===2?M=0:c.lastNeed=M-3),M):0))}function u(c,p,R){if((p[0]&192)!==128)return c.lastNeed=0,"\uFFFD";if(c.lastNeed>1&&p.length>1){if((p[1]&192)!==128)return c.lastNeed=1,"\uFFFD";if(c.lastNeed>2&&p.length>2&&(p[2]&192)!==128)return c.lastNeed=2,"\uFFFD"}}function f(c){var p=this.lastTotal-this.lastNeed,R=u(this,c);if(R!==void 0)return R;if(this.lastNeed<=c.length)return c.copy(this.lastChar,p,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,p,0,c.length),this.lastNeed-=c.length}function g(c,p){var R=a(this,c,p);if(!this.lastNeed)return c.toString("utf8",p);this.lastTotal=R;var A=c.length-(R-this.lastNeed);return c.copy(this.lastChar,0,A),c.toString("utf8",p,A)}function w(c){var p=c&&c.length?this.write(c):"";return this.lastNeed?p+"\uFFFD":p}function b(c,p){if((c.length-p)%2===0){var R=c.toString("utf16le",p);if(R){var A=R.charCodeAt(R.length-1);if(A>=55296&&A<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1],R.slice(0,-1)}return R}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=c[c.length-1],c.toString("utf16le",p,c.length-1)}function _(c){var p=c&&c.length?this.write(c):"";if(this.lastNeed){var R=this.lastTotal-this.lastNeed;return p+this.lastChar.toString("utf16le",0,R)}return p}function m(c,p){var R=(c.length-p)%3;return R===0?c.toString("base64",p):(this.lastNeed=3-R,this.lastTotal=3,R===1?this.lastChar[0]=c[c.length-1]:(this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1]),c.toString("base64",p,c.length-R))}function E(c){var p=c&&c.length?this.write(c):"";return this.lastNeed?p+this.lastChar.toString("base64",0,3-this.lastNeed):p}function T(c){return c.toString(this.encoding)}function O(c){return c&&c.length?this.write(c):""}return Vt}var ki=be.codes.ERR_STREAM_PREMATURE_CLOSE;function qa(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n<r;n++)i[n]=arguments[n];t.apply(this,i)}}}function $a(){}function Ga(t){return t.setHeader&&typeof t.abort=="function"}function Pi(t,e,r){if(typeof e=="function")return Pi(t,null,e);e||(e={}),r=qa(r||$a);var i=e.readable||e.readable!==!1&&t.readable,n=e.writable||e.writable!==!1&&t.writable,s=function(){t.writable||u()},a=t._writableState&&t._writableState.finished,u=function(){n=!1,a=!0,i||r.call(t)},f=t._readableState&&t._readableState.endEmitted,g=function(){i=!1,f=!0,n||r.call(t)},w=function(E){r.call(t,E)},b=function(){var E;if(i&&!f)return(!t._readableState||!t._readableState.ended)&&(E=new ki),r.call(t,E);if(n&&!a)return(!t._writableState||!t._writableState.ended)&&(E=new ki),r.call(t,E)},_=function(){t.req.on("finish",u)};return Ga(t)?(t.on("complete",u),t.on("abort",b),t.req?_():t.on("request",_)):n&&!t._writableState&&(t.on("end",s),t.on("close",s)),t.on("end",g),t.on("finish",u),e.error!==!1&&t.on("error",w),t.on("close",b),function(){t.removeListener("complete",u),t.removeListener("abort",b),t.removeListener("request",_),t.req&&t.req.removeListener("finish",u),t.removeListener("end",s),t.removeListener("close",s),t.removeListener("finish",u),t.removeListener("end",g),t.removeListener("error",w),t.removeListener("close",b)}}var Ht=Pi,Jt,Ni;function Va(){if(Ni)return Jt;Ni=1;var t;function e(c,p,R){return p in c?Object.defineProperty(c,p,{value:R,enumerable:!0,configurable:!0,writable:!0}):c[p]=R,c}var r=Ht,i=Symbol("lastResolve"),n=Symbol("lastReject"),s=Symbol("error"),a=Symbol("ended"),u=Symbol("lastPromise"),f=Symbol("handlePromise"),g=Symbol("stream");function w(c,p){return{value:c,done:p}}function b(c){var p=c[i];if(p!==null){var R=c[g].read();R!==null&&(c[u]=null,c[i]=null,c[n]=null,p(w(R,!1)))}}function _(c){I.nextTick(b,c)}function m(c,p){return function(R,A){c.then(function(){if(p[a]){R(w(void 0,!0));return}p[f](R,A)},A)}}var E=Object.getPrototypeOf(function(){}),T=Object.setPrototypeOf((t={get stream(){return this[g]},next:function(){var p=this,R=this[s];if(R!==null)return Promise.reject(R);if(this[a])return Promise.resolve(w(void 0,!0));if(this[g].destroyed)return new Promise(function(q,k){I.nextTick(function(){p[s]?k(p[s]):q(w(void 0,!0))})});var A=this[u],M;if(A)M=new Promise(m(A,this));else{var j=this[g].read();if(j!==null)return Promise.resolve(w(j,!1));M=new Promise(this[f])}return this[u]=M,M}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var p=this;return new Promise(function(R,A){p[g].destroy(null,function(M){if(M){A(M);return}R(w(void 0,!0))})})}),t),E),O=function(p){var R,A=Object.create(T,(R={},e(R,g,{value:p,writable:!0}),e(R,i,{value:null,writable:!0}),e(R,n,{value:null,writable:!0}),e(R,s,{value:null,writable:!0}),e(R,a,{value:p._readableState.endEmitted,writable:!0}),e(R,f,{value:function(j,q){var k=A[g].read();k?(A[u]=null,A[i]=null,A[n]=null,j(w(k,!1))):(A[i]=j,A[n]=q)},writable:!0}),R));return A[u]=null,r(p,function(M){if(M&&M.code!=="ERR_STREAM_PREMATURE_CLOSE"){var j=A[n];j!==null&&(A[u]=null,A[i]=null,A[n]=null,j(M)),A[s]=M;return}var q=A[i];q!==null&&(A[u]=null,A[i]=null,A[n]=null,q(w(void 0,!0))),A[a]=!0}),p.on("readable",_.bind(null,A)),A};return Jt=O,Jt}var Xt,Ii;function Ha(){return Ii||(Ii=1,Xt=function(){throw new Error("Readable.from is not available in the browser")}),Xt}var Kt,Bi;function Li(){if(Bi)return Kt;Bi=1,Kt=F;var t;F.ReadableState=k,$r.EventEmitter;var e=function(l,v){return l.listeners(v).length},r=Gr,i=tt.Buffer,n=He.Uint8Array||function(){};function s(o){return i.from(o)}function a(o){return i.isBuffer(o)||o instanceof n}var u=mi,f;u&&u.debuglog?f=u.debuglog("stream"):f=function(){};var g=Oa(),w=xi,b=Si,_=b.getHighWaterMark,m=be.codes,E=m.ERR_INVALID_ARG_TYPE,T=m.ERR_STREAM_PUSH_AFTER_EOF,O=m.ERR_METHOD_NOT_IMPLEMENTED,c=m.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,p,R,A;ce.exports(F,r);var M=w.errorOrDestroy,j=["error","close","destroy","pause","resume"];function q(o,l,v){if(typeof o.prependListener=="function")return o.prependListener(l,v);!o._events||!o._events[l]?o.on(l,v):Array.isArray(o._events[l])?o._events[l].unshift(v):o._events[l]=[v,o._events[l]]}function k(o,l,v){t=t||Te(),o=o||{},typeof v!="boolean"&&(v=l instanceof t),this.objectMode=!!o.objectMode,v&&(this.objectMode=this.objectMode||!!o.readableObjectMode),this.highWaterMark=_(this,o,"readableHighWaterMark",v),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=o.emitClose!==!1,this.autoDestroy=!!o.autoDestroy,this.destroyed=!1,this.defaultEncoding=o.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,o.encoding&&(p||(p=Mi().StringDecoder),this.decoder=new p(o.encoding),this.encoding=o.encoding)}function F(o){if(t=t||Te(),!(this instanceof F))return new F(o);var l=this instanceof t;this._readableState=new k(o,this,l),this.readable=!0,o&&(typeof o.read=="function"&&(this._read=o.read),typeof o.destroy=="function"&&(this._destroy=o.destroy)),r.call(this)}Object.defineProperty(F.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(l){!this._readableState||(this._readableState.destroyed=l)}}),F.prototype.destroy=w.destroy,F.prototype._undestroy=w.undestroy,F.prototype._destroy=function(o,l){l(o)},F.prototype.push=function(o,l){var v=this._readableState,C;return v.objectMode?C=!0:typeof o=="string"&&(l=l||v.defaultEncoding,l!==v.encoding&&(o=i.from(o,l),l=""),C=!0),U(this,o,l,!1,C)},F.prototype.unshift=function(o){return U(this,o,null,!0,!1)};function U(o,l,v,C,W){f("readableAddChunk",l);var P=o._readableState;if(l===null)P.reading=!1,Q(o,P);else{var B;if(W||(B=ne(P,l)),B)M(o,B);else if(P.objectMode||l&&l.length>0)if(typeof l!="string"&&!P.objectMode&&Object.getPrototypeOf(l)!==i.prototype&&(l=s(l)),C)P.endEmitted?M(o,new c):V(o,P,l,!0);else if(P.ended)M(o,new T);else{if(P.destroyed)return!1;P.reading=!1,P.decoder&&!v?(l=P.decoder.write(l),P.objectMode||l.length!==0?V(o,P,l,!1):ae(o,P)):V(o,P,l,!1)}else C||(P.reading=!1,ae(o,P))}return!P.ended&&(P.length<P.highWaterMark||P.length===0)}function V(o,l,v,C){l.flowing&&l.length===0&&!l.sync?(l.awaitDrain=0,o.emit("data",v)):(l.length+=l.objectMode?1:v.length,C?l.buffer.unshift(v):l.buffer.push(v),l.needReadable&&Z(o)),ae(o,l)}function ne(o,l){var v;return!a(l)&&typeof l!="string"&&l!==void 0&&!o.objectMode&&(v=new E("chunk",["string","Buffer","Uint8Array"],l)),v}F.prototype.isPaused=function(){return this._readableState.flowing===!1},F.prototype.setEncoding=function(o){p||(p=Mi().StringDecoder);var l=new p(o);this._readableState.decoder=l,this._readableState.encoding=this._readableState.decoder.encoding;for(var v=this._readableState.buffer.head,C="";v!==null;)C+=l.write(v.data),v=v.next;return this._readableState.buffer.clear(),C!==""&&this._readableState.buffer.push(C),this._readableState.length=C.length,this};var X=1073741824;function Y(o){return o>=X?o=X:(o--,o|=o>>>1,o|=o>>>2,o|=o>>>4,o|=o>>>8,o|=o>>>16,o++),o}function K(o,l){return o<=0||l.length===0&&l.ended?0:l.objectMode?1:o!==o?l.flowing&&l.length?l.buffer.head.data.length:l.length:(o>l.highWaterMark&&(l.highWaterMark=Y(o)),o<=l.length?o:l.ended?l.length:(l.needReadable=!0,0))}F.prototype.read=function(o){f("read",o),o=parseInt(o,10);var l=this._readableState,v=o;if(o!==0&&(l.emittedReadable=!1),o===0&&l.needReadable&&((l.highWaterMark!==0?l.length>=l.highWaterMark:l.length>0)||l.ended))return f("read: emitReadable",l.length,l.ended),l.length===0&&l.ended?x(this):Z(this),null;if(o=K(o,l),o===0&&l.ended)return l.length===0&&x(this),null;var C=l.needReadable;f("need readable",C),(l.length===0||l.length-o<l.highWaterMark)&&(C=!0,f("length less than watermark",C)),l.ended||l.reading?(C=!1,f("reading or ended",C)):C&&(f("do read"),l.reading=!0,l.sync=!0,l.length===0&&(l.needReadable=!0),this._read(l.highWaterMark),l.sync=!1,l.reading||(o=K(v,l)));var W;return o>0?W=h(o,l):W=null,W===null?(l.needReadable=l.length<=l.highWaterMark,o=0):(l.length-=o,l.awaitDrain=0),l.length===0&&(l.ended||(l.needReadable=!0),v!==o&&l.ended&&x(this)),W!==null&&this.emit("data",W),W};function Q(o,l){if(f("onEofChunk"),!l.ended){if(l.decoder){var v=l.decoder.end();v&&v.length&&(l.buffer.push(v),l.length+=l.objectMode?1:v.length)}l.ended=!0,l.sync?Z(o):(l.needReadable=!1,l.emittedReadable||(l.emittedReadable=!0,we(o)))}}function Z(o){var l=o._readableState;f("emitReadable",l.needReadable,l.emittedReadable),l.needReadable=!1,l.emittedReadable||(f("emitReadable",l.flowing),l.emittedReadable=!0,I.nextTick(we,o))}function we(o){var l=o._readableState;f("emitReadable_",l.destroyed,l.length,l.ended),!l.destroyed&&(l.length||l.ended)&&(o.emit("readable"),l.emittedReadable=!1),l.needReadable=!l.flowing&&!l.ended&&l.length<=l.highWaterMark,d(o)}function ae(o,l){l.readingMore||(l.readingMore=!0,I.nextTick(_t,o,l))}function _t(o,l){for(;!l.reading&&!l.ended&&(l.length<l.highWaterMark||l.flowing&&l.length===0);){var v=l.length;if(f("maybeReadMore read 0"),o.read(0),v===l.length)break}l.readingMore=!1}F.prototype._read=function(o){M(this,new O("_read()"))},F.prototype.pipe=function(o,l){var v=this,C=this._readableState;switch(C.pipesCount){case 0:C.pipes=o;break;case 1:C.pipes=[C.pipes,o];break;default:C.pipes.push(o);break}C.pipesCount+=1,f("pipe count=%d opts=%j",C.pipesCount,l);var W=(!l||l.end!==!1)&&o!==I.stdout&&o!==I.stderr,P=W?Ce:Ue;C.endEmitted?I.nextTick(P):v.once("end",P),o.on("unpipe",B);function B(Ae,Fe){f("onunpipe"),Ae===v&&Fe&&Fe.hasUnpiped===!1&&(Fe.hasUnpiped=!0,ks())}function Ce(){f("onend"),o.end()}var yt=sr(v);o.on("drain",yt);var nn=!1;function ks(){f("cleanup"),o.removeListener("close",fr),o.removeListener("finish",cr),o.removeListener("drain",yt),o.removeListener("error",ur),o.removeListener("unpipe",B),v.removeListener("end",Ce),v.removeListener("end",Ue),v.removeListener("data",an),nn=!0,C.awaitDrain&&(!o._writableState||o._writableState.needDrain)&&yt()}v.on("data",an);function an(Ae){f("ondata");var Fe=o.write(Ae);f("dest.write",Fe),Fe===!1&&((C.pipesCount===1&&C.pipes===o||C.pipesCount>1&&N(C.pipes,o)!==-1)&&!nn&&(f("false write response, pause",C.awaitDrain),C.awaitDrain++),v.pause())}function ur(Ae){f("onerror",Ae),Ue(),o.removeListener("error",ur),e(o,"error")===0&&M(o,Ae)}q(o,"error",ur);function fr(){o.removeListener("finish",cr),Ue()}o.once("close",fr);function cr(){f("onfinish"),o.removeListener("close",fr),Ue()}o.once("finish",cr);function Ue(){f("unpipe"),v.unpipe(o)}return o.emit("pipe",v),C.flowing||(f("pipe resume"),v.resume()),o};function sr(o){return function(){var v=o._readableState;f("pipeOnDrain",v.awaitDrain),v.awaitDrain&&v.awaitDrain--,v.awaitDrain===0&&e(o,"data")&&(v.flowing=!0,d(o))}}F.prototype.unpipe=function(o){var l=this._readableState,v={hasUnpiped:!1};if(l.pipesCount===0)return this;if(l.pipesCount===1)return o&&o!==l.pipes?this:(o||(o=l.pipes),l.pipes=null,l.pipesCount=0,l.flowing=!1,o&&o.emit("unpipe",this,v),this);if(!o){var C=l.pipes,W=l.pipesCount;l.pipes=null,l.pipesCount=0,l.flowing=!1;for(var P=0;P<W;P++)C[P].emit("unpipe",this,{hasUnpiped:!1});return this}var B=N(l.pipes,o);return B===-1?this:(l.pipes.splice(B,1),l.pipesCount-=1,l.pipesCount===1&&(l.pipes=l.pipes[0]),o.emit("unpipe",this,v),this)},F.prototype.on=function(o,l){var v=r.prototype.on.call(this,o,l),C=this._readableState;return o==="data"?(C.readableListening=this.listenerCount("readable")>0,C.flowing!==!1&&this.resume()):o==="readable"&&!C.endEmitted&&!C.readableListening&&(C.readableListening=C.needReadable=!0,C.flowing=!1,C.emittedReadable=!1,f("on readable",C.length,C.reading),C.length?Z(this):C.reading||I.nextTick(me,this)),v},F.prototype.addListener=F.prototype.on,F.prototype.removeListener=function(o,l){var v=r.prototype.removeListener.call(this,o,l);return o==="readable"&&I.nextTick(pt,this),v},F.prototype.removeAllListeners=function(o){var l=r.prototype.removeAllListeners.apply(this,arguments);return(o==="readable"||o===void 0)&&I.nextTick(pt,this),l};function pt(o){var l=o._readableState;l.readableListening=o.listenerCount("readable")>0,l.resumeScheduled&&!l.paused?l.flowing=!0:o.listenerCount("data")>0&&o.resume()}function me(o){f("readable nexttick read 0"),o.read(0)}F.prototype.resume=function(){var o=this._readableState;return o.flowing||(f("resume"),o.flowing=!o.readableListening,or(this,o)),o.paused=!1,this};function or(o,l){l.resumeScheduled||(l.resumeScheduled=!0,I.nextTick(lr,o,l))}function lr(o,l){f("resume",l.reading),l.reading||o.read(0),l.resumeScheduled=!1,o.emit("resume"),d(o),l.flowing&&!l.reading&&o.read(0)}F.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function d(o){var l=o._readableState;for(f("flow",l.flowing);l.flowing&&o.read()!==null;);}F.prototype.wrap=function(o){var l=this,v=this._readableState,C=!1;o.on("end",function(){if(f("wrapped end"),v.decoder&&!v.ended){var B=v.decoder.end();B&&B.length&&l.push(B)}l.push(null)}),o.on("data",function(B){if(f("wrapped data"),v.decoder&&(B=v.decoder.write(B)),!(v.objectMode&&B==null)&&!(!v.objectMode&&(!B||!B.length))){var Ce=l.push(B);Ce||(C=!0,o.pause())}});for(var W in o)this[W]===void 0&&typeof o[W]=="function"&&(this[W]=function(Ce){return function(){return o[Ce].apply(o,arguments)}}(W));for(var P=0;P<j.length;P++)o.on(j[P],this.emit.bind(this,j[P]));return this._read=function(B){f("wrapped _read",B),C&&(C=!1,o.resume())},this},typeof Symbol=="function"&&(F.prototype[Symbol.asyncIterator]=function(){return R===void 0&&(R=Va()),R(this)}),Object.defineProperty(F.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(F.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(F.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(l){this._readableState&&(this._readableState.flowing=l)}}),F._fromList=h,Object.defineProperty(F.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function h(o,l){if(l.length===0)return null;var v;return l.objectMode?v=l.buffer.shift():!o||o>=l.length?(l.decoder?v=l.buffer.join(""):l.buffer.length===1?v=l.buffer.first():v=l.buffer.concat(l.length),l.buffer.clear()):v=l.buffer.consume(o,l.decoder),v}function x(o){var l=o._readableState;f("endReadable",l.endEmitted),l.endEmitted||(l.ended=!0,I.nextTick(D,l,o))}function D(o,l){if(f("endReadableNT",o.endEmitted,o.length),!o.endEmitted&&o.length===0&&(o.endEmitted=!0,l.readable=!1,l.emit("end"),o.autoDestroy)){var v=l._writableState;(!v||v.autoDestroy&&v.finished)&&l.destroy()}}typeof Symbol=="function"&&(F.from=function(o,l){return A===void 0&&(A=Ha()),A(F,o,l)});function N(o,l){for(var v=0,C=o.length;v<C;v++)if(o[v]===l)return v;return-1}return Kt}var Ui=le,ut=be.codes,Ja=ut.ERR_METHOD_NOT_IMPLEMENTED,Xa=ut.ERR_MULTIPLE_CALLBACK,Ka=ut.ERR_TRANSFORM_ALREADY_TRANSFORMING,Qa=ut.ERR_TRANSFORM_WITH_LENGTH_0,ft=Te();ce.exports(le,ft);function Za(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new Xa);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}function le(t){if(!(this instanceof le))return new le(t);ft.call(this,t),this._transformState={afterTransform:Za.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",es)}function es(){var t=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(e,r){Wi(t,e,r)}):Wi(this,null,null)}le.prototype.push=function(t,e){return this._transformState.needTransform=!1,ft.prototype.push.call(this,t,e)},le.prototype._transform=function(t,e,r){r(new Ja("_transform()"))},le.prototype._write=function(t,e,r){var i=this._transformState;if(i.writecb=r,i.writechunk=t,i.writeencoding=e,!i.transforming){var n=this._readableState;(i.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}},le.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0},le.prototype._destroy=function(t,e){ft.prototype._destroy.call(this,t,function(r){e(r)})};function Wi(t,e,r){if(e)return t.emit("error",e);if(r!=null&&t.push(r),t._writableState.length)throw new Qa;if(t._transformState.transforming)throw new Ka;return t.push(null)}var ts=Le,ji=Ui;ce.exports(Le,ji);function Le(t){if(!(this instanceof Le))return new Le(t);ji.call(this,t)}Le.prototype._transform=function(t,e,r){r(null,t)};var Qt;function rs(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Yi=be.codes,is=Yi.ERR_MISSING_ARGS,ns=Yi.ERR_STREAM_DESTROYED;function zi(t){if(t)throw t}function as(t){return t.setHeader&&typeof t.abort=="function"}function ss(t,e,r,i){i=rs(i);var n=!1;t.on("close",function(){n=!0}),Qt===void 0&&(Qt=Ht),Qt(t,{readable:e,writable:r},function(a){if(a)return i(a);n=!0,i()});var s=!1;return function(a){if(!n&&!s){if(s=!0,as(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(a||new ns("pipe"))}}}function qi(t){t()}function os(t,e){return t.pipe(e)}function ls(t){return!t.length||typeof t[t.length-1]!="function"?zi:t.pop()}function us(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var i=ls(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new is("streams");var n,s=e.map(function(a,u){var f=u<e.length-1,g=u>0;return ss(a,f,g,function(w){n||(n=w),w&&s.forEach(qi),!f&&(s.forEach(qi),i(n))})});return e.reduce(os)}var fs=us;(function(t,e){e=t.exports=Li(),e.Stream=e,e.Readable=e,e.Writable=Ai(),e.Duplex=Te(),e.Transform=Ui,e.PassThrough=ts,e.finished=Ht,e.pipeline=fs})(Ct,Ct.exports);var $i=Ct.exports.Transform,Gi=ce.exports;function Se(t){$i.call(this,t),this._destroyed=!1}Gi(Se,$i),Se.prototype.destroy=function(t){if(!this._destroyed){this._destroyed=!0;var e=this;I.nextTick(function(){t&&e.emit("error",t),e.emit("close")})}};function cs(t,e,r){r(null,t)}function Zt(t){return function(e,r,i){return typeof e=="function"&&(i=r,r=e,e={}),typeof r!="function"&&(r=cs),typeof i!="function"&&(i=null),t(e,r,i)}}St.exports=Zt(function(t,e,r){var i=new Se(t);return i._transform=e,r&&(i._flush=r),i}),St.exports.ctor=Zt(function(t,e,r){function i(n){if(!(this instanceof i))return new i(n);this.options=Object.assign({},t,n),Se.call(this,this.options)}return Gi(i,Se),i.prototype._transform=e,r&&(i.prototype._flush=r),i}),St.exports.obj=Zt(function(t,e,r){var i=new Se(Object.assign({objectMode:!0,highWaterMark:16},t));return i._transform=e,r&&(i._flush=r),i});class Vi{constructor(e,r=4){this._string=null,this._type="form",this._readOnly=!1,this._context={},this._onChangeFields={},this._keyIdx=0,this._invisibleFields=[],this._fields=e,this._container=new Me(r,6,!1,"root")}get fields(){return this._fields}get container(){return this._container}get string(){return this._string}get type(){return this._type}get readOnly(){return this._readOnly}set readOnly(e){this._readOnly=e}get context(){return this._context}set context(e){this._context=e}get onChangeFields(){return this._onChangeFields}set onChangeFields(e){this._onChangeFields=e}get keyIdx(){return this._keyIdx}set keyIdx(e){this._keyIdx=e}get invisibleFields(){return this._invisibleFields}set invisibleFields(e){this._invisibleFields=e}parse(e,r){var i;const{values:n={},readOnly:s=!1}=r||{},a=Ge(e).filter(u=>u.tagName==="form")[0];this._string=((i=a.attributes)==null?void 0:i.string)||null,this._string&&(this._string=G(this._string)),this._readOnly=s,this._context=n.id?{active_id:n.id,active_ids:[n.id]}:{},this._invisibleFields=[],this.parseNode({fields:a.children,container:this._container,values:n})}parseNode({fields:e,container:r,values:i}){const n=new Rt;e.filter(s=>typeof s=="object").forEach(s=>{var a,u;const{tagName:f,attributes:g,children:w}=s;let b=f,_=g;if(f==="field"){const{name:R,widget:A}=g;if(A)b=A;else if(R){if(!this._fields[R])throw new Error(`Field ${R} doesn't exist in fields defintion`);b=this._fields[R].type}_={...this._fields[R],...g,fieldsWidgetType:this._fields[R].type}}const m=un({tagAttributes:_,values:i,fields:this._fields});let E;f==="button"&&_.states?E=hn({states:_.states,values:i}):E=cn({fieldName:_.name,values:i,fields:this._fields});const T=Br({context:_.context||((a=this._fields[_.name])==null?void 0:a.context),values:i,fields:this._fields});_.on_change&&(this._onChangeFields[_.name]=pn(_.on_change));let O;Hi(_.domain)&&(O=_.domain),Hi((u=this._fields[_.name])==null?void 0:u.domain)&&(O=this._fields[_.name].domain),this._keyIdx=this._keyIdx+1;const c={...m,...E,context:T,domain:O,key:`${this._keyIdx}`},p=n.createWidget(b,c);p.invisible&&p instanceof L&&this._invisibleFields.push(c.name),p instanceof de&&this.parseNode({fields:w,container:p.container,values:i}),p.readOnly=p.readOnly||this.readOnly,r.addWidget(p)})}findById(e){return this.container.findById(e)}}function Hi(t){return t?Array.isArray(t)&&t.length>0?!0:typeof t=="string"&&t!==""&&t!=="[]":!1}class hs{constructor(e){this._columns=[],this._string=null,this._type="tree",this._colors=null,this._editable=null,this._fields=e}get fields(){return this._fields}get columns(){return this._columns}get string(){return this._string}get type(){return this._type}get colors(){return this._colors}get editable(){return this._editable}parse(e){const r=Ge(e).filter(n=>n.tagName==="tree")[0];this._string=r.attributes.string||null,this._string&&(this._string=G(this._string)),this._colors=r.attributes.colors||null,this._colors&&(this._colors=G(this._colors)),this._editable=r.attributes.editable||null;const i=new Rt;r.children.forEach(n=>{const{tagName:s,attributes:a}=n;let u=null;if(s==="field"){const{name:f,widget:g}=a;let w=a;if(f){if(!this._fields[f])throw new Error(`Field ${f} doesn't exist in fields defintion`);const b=this._fields[f];u=b.type,(Array.isArray(b==null?void 0:b.domain)&&(b==null?void 0:b.domain.length)===0||(b==null?void 0:b.domain)===!1)&&a.domain&&a.domain.length>0&&delete b.domain,w={...b,...a,fieldsWidgetType:b==null?void 0:b.type}}if(g&&(u=g),!w.invisible){const b=i.createWidget(u,w);this._columns.push(b)}}})}findById(e){return this._columns.find(r=>{if(r.findById)return r.findById(e)})}}const Ji={text:"text",many2one:"many2one",char:"char",boolean:"boolean",selection:"selection",float:"float",float_time:"float_time",progressbar:"progressbar",integer:"integer",date:"date",datetime:"datetime"};class ds{get searchFields(){return this._searchFields}get fields(){return this._fields}get simpleSearchContainer(){return this._simpleSearchContainer}get advancedSearchContainer(){return this._advancedSearchContainer}get formXml(){return this._formXml}constructor(e,r,i,n=8){this._searchFields=e,this._fields=r,this._formXml=i,this._simpleSearchContainer=new Me(n),this._advancedSearchContainer=new Me(n)}parse(){const e=new Rt,r=new Vi(this.fields);r.parse(this.formXml),this.parseFields(this.searchFields.primary,e,r).forEach(s=>{this.simpleSearchContainer.addWidget(s,{addLabel:!1}),this.advancedSearchContainer.addWidget(s,{addLabel:!1})}),this.parseFields(this.searchFields.secondary,e,r).forEach(s=>{this.advancedSearchContainer.addWidget(s,{addLabel:!1})})}parseFields(e,r,i){return e.map(n=>{var s,a;const u={...this.fields[n],name:n,colspan:2},{type:f}=u;let g=(a=(s=i.findById(n))==null?void 0:s.type)!=null?a:f;return Ji[g]===void 0&&(g=f),r.createWidget(g,u)})}findById(e){return this.advancedSearchContainer.findById(e)}}const gs=({domain:t,widgetFieldName:e})=>{const r=[];return t.forEach(i=>{if(!Array.isArray(i))return;const[n,s,a]=i;let u,f;n.indexOf(".")!==-1?(u=n.substr(0,n.indexOf(".")),f=n.substr(n.indexOf(".")+1,n.length-1)):(u=n,f="id"),u===e&&r.push([f,s,a])}),r};class Xi{constructor(e){this._action_id=null,this._position=null,e.action_id&&(this._action_id=e.action_id),e.position&&(this._position=e.position)}get action_id(){return this._action_id}get position(){return this._position}}class _s{constructor(e){this._string=null,this._items=[];const r=Ge(e).filter(n=>n.tagName==="dashboard")[0];this._string=r.attributes.string||null;const{children:i}=r;i.forEach(n=>{n.tagName==="dashboard_item"&&this._items.push(new Xi(n.attributes))})}get string(){return this._string}get items(){return this._items}}class er{constructor(e){this._string=null,this._timerange=null,this._string=e.attributes.string||null,this._timerange=e.attributes.timerange||null}get string(){return this._string}get type(){return this._type}get timerange(){return this._timerange}}const ps=t=>t===1||t==="1"||t===!0||t==="True";class tr extends er{constructor(e,r){super(r),this._color=null,this._icon=null,this._totalDomain=null,this._showPercent=!1,this._suffix=null,this._type=e,this._color=r.attributes.color||null,this._color&&(this._color=G(this._color)),this._icon=r.attributes.icon||null,this._icon&&(this._icon=G(this._icon)),this._suffix=r.attributes.suffix||null,this._totalDomain=r.attributes.totalDomain||null,this._showPercent=ps(r.attributes.showPercent)}get color(){return this._color}get icon(){return this._icon}get totalDomain(){return this._totalDomain}get showPercent(){return this._showPercent}get suffix(){return this._suffix}}class Ki extends tr{constructor(e,r){super(e,r);const{children:i}=r;i.forEach(n=>{if(n.tagName==="field"){const s=n.attributes.name,a=n.attributes.operator;this._field=s||void 0,this._operator=a}})}get field(){return this._field}get operator(){return this._operator}}const ys=t=>{const e=[];let r;if(t.forEach(i=>{if(i.tagName==="field"){const n=i.attributes.axis,s=i.attributes.operator,a=i.attributes.name,u=i.attributes.label||void 0,f=i.attributes.stacked||void 0;if(!n)throw new Error(`Field ${a} doesn't have an axis`);if(!a)throw new Error("Missing name attribute for field");n==="x"?r=new Zi({name:a}):n==="y"&&e.push(new Qi({name:a,operator:s,label:u,stacked:f}))}}),!r)throw new Error("No x axis found");if(!e.length)throw new Error("No y axis found. At least we need one y axis");return{x:r,y:e}};class ct extends er{constructor(e,r){super(r),this._type=e;const i=ys(r.children);this._x=i.x,this._y=i.y}get x(){return this._x}get y(){return this._y}}const bs={indicator:tr,indicatorField:Ki,line:ct,bar:ct,pie:ct},ws=t=>{const e=Ge(t).filter(n=>n.tagName==="graph")[0],r=e.attributes.type;if(!r)throw new Error(`${r} is not a valid graph`);const i=bs[r];if(!i)throw new Error(`${r} not found as a GraphModel`);return new i(r,e)};class rr{get name(){return this._name}get axis(){return this._axis}constructor({name:e,axis:r}){this._name=e,this._axis=r}}class Qi extends rr{constructor({name:e,operator:r,label:i,stacked:n}){super({name:e,axis:"y"}),this._operator=r,this._label=i,this._stacked=n}get operator(){return this._operator}get label(){return this._label}get stacked(){return this._stacked}}class Zi extends rr{constructor({name:e}){super({name:e,axis:"x"})}}const ms=({ooui:t})=>{const r=[t.x.name];return t.y?(t.y.forEach(i=>{i.operator!=="count"&&!r.includes(i.name)&&r.push(i.name),i.label&&!r.includes(i.label)&&r.push(i.label)}),r):[]};function ir({fields:t,values:e,fieldName:r}){const i=t[r],n=e[r];if(!i)throw new Error(`Field ${r} not found`);if(i.type==="many2one")return n?{value:n[0],label:n[1]}:{value:!1,label:void 0};if(i.type==="selection"){const a=i.selection.find(u=>u[0]===n);return a?{value:n,label:a[1]}:{value:!1,label:void 0}}return{value:n,label:n}}const vs=Object.freeze(Object.defineProperty({__proto__:null,getFieldsToRetrieve:ms,getValueAndLabelForField:ir},Symbol.toStringTag,{value:"Module"}));function Es({values:t,timerange:e}){const r=Ts({values:t,timerange:e});return xs({values:r,timerange:e})}function xs({values:t,timerange:e}){let r=[];const i=tn({values:t,groupBy:"type-stacked"}),n=`${e}s`;return Object.keys(i).forEach(a=>{const u=i[a];for(let f=0;f<u.length;f++){const g=u[f];if(r.push(g),f===u.length-1)return;const w=g.x,b=u[f+1].x;if(!en([w,b],n)){const _=Rs({dates:[w,b],timerange:e});r=r.concat(_.map(m=>({x:m,value:0,type:g.type,stacked:g.stacked})))}}}),r.sort((a,u)=>a.x<u.x?-1:a.x>u.x?1:0)}function Rs({dates:t,timerange:e}){const r=[],i=`${e}s`;if(t.length===1)return t;const n=t.sort((s,a)=>s<a?-1:s>a?1:0);for(let s=0;s<n.length-1;s++){const a=n[s],u=n[s+1];if(!en([a,u],i)){let f=De.default(a,ht(i)).add(1,i),g=De.default(u,ht(i));for(;f.isBefore(g);)r.push(f.format(ht(i))),f.add(1,i)}}return r}function Ts({values:t,timerange:e}){const r=Ss({values:t,timerange:e});let i=[];const n=tn({values:r,groupBy:"all"});return Object.keys(n).forEach(s=>{const a=n[s],u=a[0].operator==="count"?"+":a[0].operator,f=dt({values:a.map(g=>g.value),operator:u});i.push({...a[0],value:f})}),i}function Ss({values:t,timerange:e}){return t.map(r=>({...r,x:Cs({date:r.x,timerange:e})}))}function Cs({date:t,timerange:e}){let r=As(t);const i=De.default(t,r);switch(e){case"hour":{r="YYYY-MM-DD HH:00";break}case"day":{r="YYYY-MM-DD";break}case"week":{r="YYYY-WW";break}case"month":{r="YYYY-MM";break}case"year":{r="YYYY";break}}return i.format(r)}function As(t){return t.indexOf(":")?"YYYY-MM-DD HH:mm:ss":"YYYY-MM-DD"}function en(t,e){let r=!1;const i=ht(e);if(t.length===0)return!1;if(t.length===1)return!0;for(let n=0;n<t.length-1;n++){const s=De.default(t[n],i),u=De.default(t[n+1],i).diff(s,e);Math.abs(u)===1?r=!0:r=!1}return r}function tn({values:t,groupBy:e}){const r={};return t.forEach(i=>{const n=i.x,s=i.type,a=i.stacked,u=e==="all"?`${n}-${s}-${a}`:`${s}-${a}`;r[u]||(r[u]=[]),r[u].push(i)}),r}function ht(t){switch(t){default:case"hours":return"YYYY-MM-DD HH:mm";case"days":return"YYYY-MM-DD";case"weeks":return"YYYY-WW";case"months":return"YYYY-MM";case"years":return"YYYY"}}const Fs={count:"count","+":"sum","-":"subtract","*":"multiply",avg:"average",min:"min",max:"max"},Os=({ooui:t,values:e,fields:r,options:i})=>{const n=ar({fieldName:t.x.name,values:e,fields:r}),s=[];t.y.forEach(_=>{Object.keys(n).forEach(m=>{const E=n[m].label,T=n[m].entries;if(_.label){const O=ar({fieldName:_.label,values:T,fields:r});Object.keys(O).forEach(c=>{const p=O[c].entries,R=O[c].label,A=nr({entries:p,fields:r,fieldName:_.name}),M=dt({values:A,operator:_.operator});s.push({x:E||!1,value:M,type:R,operator:_.operator,stacked:_.stacked})})}else{const O=nr({entries:T,fields:r,fieldName:_.name}),c=dt({values:O,operator:_.operator});s.push({x:E||!1,value:c,type:rn({yAxis:_,fields:r}),operator:_.operator,stacked:_.stacked})}})});const a=t.y.some(_=>_.label!==void 0),u=t.y.some(_=>_.stacked!==void 0);let g=[...s.sort((_,m)=>_.x<m.x?-1:_.x>m.x?1:0)];u&&t.y.filter(_=>_.stacked!==void 0).length>1&&(g=g.map(_=>({..._,type:`${_.type} - ${_.stacked}`})));let w=[...g];t.type==="pie"&&w.some(_=>_.x===!1)?w=w.map(_=>_.x===!1?{..._,x:(i==null?void 0:i.uninformedString)||"Not informed"}:_):g.some(_=>_.x===!1)&&(w=w.filter(_=>_.x!==!1));let b=w;return t.timerange?b=Es({values:b,timerange:t.timerange}):t.type=="pie"&&(b=w.sort((_,m)=>m.value-_.value)),{data:b,isGroup:u||a,isStack:u}};function nr({entries:t,fieldName:e,fields:r}){return t.map(i=>ir({fieldName:e,values:i,fields:r})).map(({value:i,label:n})=>n)}function dt({operator:t,values:e}){switch(t){case"count":return e.length;case"+":return gt(e.reduce(function(r,i){return r+i}));case"-":return gt(e.reduce(function(r,i){return r-i}));case"*":return gt(e.reduce(function(r,i){return r*i}));case"avg":{const i=e.reduce((n,s)=>n+s,0)/e.length||0;return gt(i)}case"min":return Math.min(...e);case"max":return Math.max(...e)}}function gt(t){return Math.round((t+Number.EPSILON)*100)/100}function ar({fieldName:t,fields:e,values:r}){const i={};return r.forEach(n=>{const{value:s,label:a}=ir({fields:e,values:n,fieldName:t});i[s]||(i[s]={label:a,entries:[]}),i[s].entries.push(n)}),i}function Ds(t){let e=[];return Object.keys(t).forEach(r=>{const i=t[r];e=e.concat(i.entries)}),e}function rn({yAxis:t,fields:e}){const r=e[t.name];return r&&r.string?r.string:t.name}const Ms=Object.freeze(Object.defineProperty({__proto__:null,labelsForOperator:Fs,processGraphData:Os,getValuesForYField:nr,getValueForOperator:dt,getValuesGroupedByField:ar,getAllObjectsInGroupedValues:Ds,getYAxisFieldname:rn},Symbol.toStringTag,{value:"Module"}));S.Avatar=hr,S.Binary=Cr,S.Boolean=vt,S.Button=_r,S.ButtonGroup=pr,S.Char=ze,S.CodeEditor=Ir,S.Container=Me,S.ContainerWidget=de,S.Dashboard=_s,S.DashboardItem=Xi,S.Date=Er,S.DateTime=xr,S.Field=L,S.Float=$e,S.FloatTime=mr,S.Form=Vi,S.Graph=er,S.GraphAxis=rr,S.GraphChart=ct,S.GraphIndicator=tr,S.GraphIndicatorField=Ki,S.GraphXAxis=Zi,S.GraphYAxis=Qi,S.Group=gr,S.Image=Ar,S.Indicator=Or,S.Integer=wr,S.Label=wt,S.Many2many=Rr,S.Many2one=yr,S.Markdown=br,S.MultiCheckbox=xt,S.NewLine=bt,S.Notebook=mt,S.One2many=Et,S.Page=dr,S.ProgressBar=vr,S.Radio=kr,S.Reference=Sr,S.SearchFieldTypes=Ji,S.SearchFilter=ds,S.Selection=ve,S.Separator=Tr,S.Steps=Nr,S.Switch=Pr,S.Tag=Mr,S.Tags=Dr,S.Text=qe,S.Timeline=Fr,S.Tree=hs,S.Widget=he,S.graphFieldUtils=vs,S.graphProcessor=Ms,S.parseContext=Br,S.parseGraph=ws,S.transformDomainForChildWidget=gs,Object.defineProperties(S,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
20
|
+
`)+" "+r[1]:r[0]+e+" "+t.join(", ")+" "+r[1]}function Bt(t){return Array.isArray(t)}function at(t){return typeof t=="boolean"}function ke(t){return t===null}function _i(t){return t==null}function Lt(t){return typeof t=="number"}function Pe(t){return typeof t=="string"}function pi(t){return typeof t=="symbol"}function ie(t){return t===void 0}function Ne(t){return ye(t)&&Ut(t)==="[object RegExp]"}function ye(t){return typeof t=="object"&&t!==null}function st(t){return ye(t)&&Ut(t)==="[object Date]"}function Ie(t){return ye(t)&&(Ut(t)==="[object Error]"||t instanceof Error)}function Be(t){return typeof t=="function"}function yi(t){return t===null||typeof t=="boolean"||typeof t=="number"||typeof t=="string"||typeof t=="symbol"||typeof t>"u"}function bi(t){return y.isBuffer(t)}function Ut(t){return Object.prototype.toString.call(t)}function Wt(t){return t<10?"0"+t.toString(10):t.toString(10)}var Fa=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Oa(){var t=new Date,e=[Wt(t.getHours()),Wt(t.getMinutes()),Wt(t.getSeconds())].join(":");return[t.getDate(),Fa[t.getMonth()],e].join(" ")}function wi(){console.log("%s - %s",Oa(),rt.apply(null,arguments))}function jt(t,e){if(!e||!ye(e))return t;for(var r=Object.keys(e),i=r.length;i--;)t[r[i]]=e[r[i]];return t}function mi(t,e){return Object.prototype.hasOwnProperty.call(t,e)}const vi=Tt(Object.freeze(Object.defineProperty({__proto__:null,format:rt,deprecate:kt,debuglog:gi,inspect:re,isArray:Bt,isBoolean:at,isNull:ke,isNullOrUndefined:_i,isNumber:Lt,isString:Pe,isSymbol:pi,isUndefined:ie,isRegExp:Ne,isObject:ye,isDate:st,isError:Ie,isFunction:Be,isPrimitive:yi,isBuffer:bi,log:wi,inherits:di,_extend:jt,default:{inherits:di,_extend:jt,log:wi,isBuffer:bi,isPrimitive:yi,isFunction:Be,isError:Ie,isDate:st,isObject:ye,isRegExp:Ne,isUndefined:ie,isSymbol:pi,isString:Pe,isNumber:Lt,isNullOrUndefined:_i,isNull:ke,isBoolean:at,isArray:Bt,inspect:re,deprecate:kt,format:rt,debuglog:gi}},Symbol.toStringTag,{value:"Module"})));var Yt,Ei;function Da(){if(Ei)return Yt;Ei=1;function t(_,m){var E=Object.keys(_);if(Object.getOwnPropertySymbols){var T=Object.getOwnPropertySymbols(_);m&&(T=T.filter(function(O){return Object.getOwnPropertyDescriptor(_,O).enumerable})),E.push.apply(E,T)}return E}function e(_){for(var m=1;m<arguments.length;m++){var E=arguments[m]!=null?arguments[m]:{};m%2?t(Object(E),!0).forEach(function(T){r(_,T,E[T])}):Object.getOwnPropertyDescriptors?Object.defineProperties(_,Object.getOwnPropertyDescriptors(E)):t(Object(E)).forEach(function(T){Object.defineProperty(_,T,Object.getOwnPropertyDescriptor(E,T))})}return _}function r(_,m,E){return m in _?Object.defineProperty(_,m,{value:E,enumerable:!0,configurable:!0,writable:!0}):_[m]=E,_}function i(_,m){if(!(_ instanceof m))throw new TypeError("Cannot call a class as a function")}function n(_,m){for(var E=0;E<m.length;E++){var T=m[E];T.enumerable=T.enumerable||!1,T.configurable=!0,"value"in T&&(T.writable=!0),Object.defineProperty(_,T.key,T)}}function s(_,m,E){return m&&n(_.prototype,m),E&&n(_,E),_}var a=tt,u=a.Buffer,f=vi,g=f.inspect,w=g&&g.custom||"inspect";function b(_,m,E){u.prototype.copy.call(_,m,E)}return Yt=function(){function _(){i(this,_),this.head=null,this.tail=null,this.length=0}return s(_,[{key:"push",value:function(E){var T={data:E,next:null};this.length>0?this.tail.next=T:this.head=T,this.tail=T,++this.length}},{key:"unshift",value:function(E){var T={data:E,next:this.head};this.length===0&&(this.tail=T),this.head=T,++this.length}},{key:"shift",value:function(){if(this.length!==0){var E=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,E}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(E){if(this.length===0)return"";for(var T=this.head,O=""+T.data;T=T.next;)O+=E+T.data;return O}},{key:"concat",value:function(E){if(this.length===0)return u.alloc(0);for(var T=u.allocUnsafe(E>>>0),O=this.head,c=0;O;)b(O.data,T,c),c+=O.data.length,O=O.next;return T}},{key:"consume",value:function(E,T){var O;return E<this.head.data.length?(O=this.head.data.slice(0,E),this.head.data=this.head.data.slice(E)):E===this.head.data.length?O=this.shift():O=T?this._getString(E):this._getBuffer(E),O}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(E){var T=this.head,O=1,c=T.data;for(E-=c.length;T=T.next;){var p=T.data,R=E>p.length?p.length:E;if(R===p.length?c+=p:c+=p.slice(0,E),E-=R,E===0){R===p.length?(++O,T.next?this.head=T.next:this.head=this.tail=null):(this.head=T,T.data=p.slice(R));break}++O}return this.length-=O,c}},{key:"_getBuffer",value:function(E){var T=u.allocUnsafe(E),O=this.head,c=1;for(O.data.copy(T),E-=O.data.length;O=O.next;){var p=O.data,R=E>p.length?p.length:E;if(p.copy(T,T.length-E,0,R),E-=R,E===0){R===p.length?(++c,O.next?this.head=O.next:this.head=this.tail=null):(this.head=O,O.data=p.slice(R));break}++c}return this.length-=c,T}},{key:w,value:function(E,T){return g(this,e({},T,{depth:0,customInspect:!1}))}}]),_}(),Yt}function Ma(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,I.nextTick(zt,this,t)):I.nextTick(zt,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?I.nextTick(ot,r):(r._writableState.errorEmitted=!0,I.nextTick(xi,r,s)):I.nextTick(xi,r,s):e?(I.nextTick(ot,r),e(s)):I.nextTick(ot,r)}),this)}function xi(t,e){zt(t,e),ot(t)}function ot(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function ka(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function zt(t,e){t.emit("error",e)}function Pa(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}var Ri={destroy:Ma,undestroy:ka,errorOrDestroy:Pa},be={};function Na(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var Ti={};function J(t,e,r){r||(r=Error);function i(s,a,u){return typeof e=="string"?e:e(s,a,u)}var n=function(s){Na(a,s);function a(u,f,g){return s.call(this,i(u,f,g))||this}return a}(r);n.prototype.name=r.name,n.prototype.code=t,Ti[t]=n}function Si(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(i){return String(i)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:r===2?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}else return"of ".concat(e," ").concat(String(t))}function Ia(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function Ba(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function La(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}J("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),J("ERR_INVALID_ARG_TYPE",function(t,e,r){var i;typeof e=="string"&&Ia(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";var n;if(Ba(t," argument"))n="The ".concat(t," ").concat(i," ").concat(Si(e,"type"));else{var s=La(t,".")?"property":"argument";n='The "'.concat(t,'" ').concat(s," ").concat(i," ").concat(Si(e,"type"))}return n+=". Received type ".concat(typeof r),n},TypeError),J("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),J("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),J("ERR_STREAM_PREMATURE_CLOSE","Premature close"),J("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),J("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),J("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),J("ERR_STREAM_WRITE_AFTER_END","write after end"),J("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),J("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),J("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),be.codes=Ti;var Ua=be.codes.ERR_INVALID_OPT_VALUE;function Wa(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function ja(t,e,r,i){var n=Wa(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new Ua(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}var Ci={getHighWaterMark:ja},ce={exports:{}};typeof Object.create=="function"?ce.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:ce.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}};var Ya=za;function za(t,e){if(qt("noDeprecation"))return t;var r=!1;function i(){if(!r){if(qt("throwDeprecation"))throw new Error(e);qt("traceDeprecation")?console.trace(e):console.warn(e),r=!0}return t.apply(this,arguments)}return i}function qt(t){try{if(!He.localStorage)return!1}catch{return!1}var e=He.localStorage[t];return e==null?!1:String(e).toLowerCase()==="true"}var $t,Ai;function Fi(){if(Ai)return $t;Ai=1,$t=k;function t(d){var h=this;this.next=null,this.entry=null,this.finish=function(){lr(h,d)}}var e;k.WritableState=j;var r={deprecate:Ya},i=Vr,n=tt.Buffer,s=He.Uint8Array||function(){};function a(d){return n.from(d)}function u(d){return n.isBuffer(d)||d instanceof s}var f=Ri,g=Ci,w=g.getHighWaterMark,b=be.codes,_=b.ERR_INVALID_ARG_TYPE,m=b.ERR_METHOD_NOT_IMPLEMENTED,E=b.ERR_MULTIPLE_CALLBACK,T=b.ERR_STREAM_CANNOT_PIPE,O=b.ERR_STREAM_DESTROYED,c=b.ERR_STREAM_NULL_VALUES,p=b.ERR_STREAM_WRITE_AFTER_END,R=b.ERR_UNKNOWN_ENCODING,A=f.errorOrDestroy;ce.exports(k,i);function M(){}function j(d,h,x){e=e||Te(),d=d||{},typeof x!="boolean"&&(x=h instanceof e),this.objectMode=!!d.objectMode,x&&(this.objectMode=this.objectMode||!!d.writableObjectMode),this.highWaterMark=w(this,d,"writableHighWaterMark",x),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var D=d.decodeStrings===!1;this.decodeStrings=!D,this.defaultEncoding=d.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(N){Q(h,N)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=d.emitClose!==!1,this.autoDestroy=!!d.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}j.prototype.getBuffer=function(){for(var h=this.bufferedRequest,x=[];h;)x.push(h),h=h.next;return x},function(){try{Object.defineProperty(j.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var q;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(q=Function.prototype[Symbol.hasInstance],Object.defineProperty(k,Symbol.hasInstance,{value:function(h){return q.call(this,h)?!0:this!==k?!1:h&&h._writableState instanceof j}})):q=function(h){return h instanceof this};function k(d){e=e||Te();var h=this instanceof e;if(!h&&!q.call(k,this))return new k(d);this._writableState=new j(d,this,h),this.writable=!0,d&&(typeof d.write=="function"&&(this._write=d.write),typeof d.writev=="function"&&(this._writev=d.writev),typeof d.destroy=="function"&&(this._destroy=d.destroy),typeof d.final=="function"&&(this._final=d.final)),i.call(this)}k.prototype.pipe=function(){A(this,new T)};function F(d,h){var x=new p;A(d,x),I.nextTick(h,x)}function U(d,h,x,D){var N;return x===null?N=new c:typeof x!="string"&&!h.objectMode&&(N=new _("chunk",["string","Buffer"],x)),N?(A(d,N),I.nextTick(D,N),!1):!0}k.prototype.write=function(d,h,x){var D=this._writableState,N=!1,o=!D.objectMode&&u(d);return o&&!n.isBuffer(d)&&(d=a(d)),typeof h=="function"&&(x=h,h=null),o?h="buffer":h||(h=D.defaultEncoding),typeof x!="function"&&(x=M),D.ending?F(this,x):(o||U(this,D,d,x))&&(D.pendingcb++,N=ne(this,D,o,d,h,x)),N},k.prototype.cork=function(){this._writableState.corked++},k.prototype.uncork=function(){var d=this._writableState;d.corked&&(d.corked--,!d.writing&&!d.corked&&!d.bufferProcessing&&d.bufferedRequest&&ae(this,d))},k.prototype.setDefaultEncoding=function(h){if(typeof h=="string"&&(h=h.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((h+"").toLowerCase())>-1))throw new R(h);return this._writableState.defaultEncoding=h,this},Object.defineProperty(k.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function V(d,h,x){return!d.objectMode&&d.decodeStrings!==!1&&typeof h=="string"&&(h=n.from(h,x)),h}Object.defineProperty(k.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function ne(d,h,x,D,N,o){if(!x){var l=V(h,D,N);D!==l&&(x=!0,N="buffer",D=l)}var v=h.objectMode?1:D.length;h.length+=v;var C=h.length<h.highWaterMark;if(C||(h.needDrain=!0),h.writing||h.corked){var W=h.lastBufferedRequest;h.lastBufferedRequest={chunk:D,encoding:N,isBuf:x,callback:o,next:null},W?W.next=h.lastBufferedRequest:h.bufferedRequest=h.lastBufferedRequest,h.bufferedRequestCount+=1}else X(d,h,!1,v,D,N,o);return C}function X(d,h,x,D,N,o,l){h.writelen=D,h.writecb=l,h.writing=!0,h.sync=!0,h.destroyed?h.onwrite(new O("write")):x?d._writev(N,h.onwrite):d._write(N,o,h.onwrite),h.sync=!1}function Y(d,h,x,D,N){--h.pendingcb,x?(I.nextTick(N,D),I.nextTick(me,d,h),d._writableState.errorEmitted=!0,A(d,D)):(N(D),d._writableState.errorEmitted=!0,A(d,D),me(d,h))}function K(d){d.writing=!1,d.writecb=null,d.length-=d.writelen,d.writelen=0}function Q(d,h){var x=d._writableState,D=x.sync,N=x.writecb;if(typeof N!="function")throw new E;if(K(x),h)Y(d,x,D,h,N);else{var o=_t(x)||d.destroyed;!o&&!x.corked&&!x.bufferProcessing&&x.bufferedRequest&&ae(d,x),D?I.nextTick(Z,d,x,o,N):Z(d,x,o,N)}}function Z(d,h,x,D){x||we(d,h),h.pendingcb--,D(),me(d,h)}function we(d,h){h.length===0&&h.needDrain&&(h.needDrain=!1,d.emit("drain"))}function ae(d,h){h.bufferProcessing=!0;var x=h.bufferedRequest;if(d._writev&&x&&x.next){var D=h.bufferedRequestCount,N=new Array(D),o=h.corkedRequestsFree;o.entry=x;for(var l=0,v=!0;x;)N[l]=x,x.isBuf||(v=!1),x=x.next,l+=1;N.allBuffers=v,X(d,h,!0,h.length,N,"",o.finish),h.pendingcb++,h.lastBufferedRequest=null,o.next?(h.corkedRequestsFree=o.next,o.next=null):h.corkedRequestsFree=new t(h),h.bufferedRequestCount=0}else{for(;x;){var C=x.chunk,W=x.encoding,P=x.callback,B=h.objectMode?1:C.length;if(X(d,h,!1,B,C,W,P),x=x.next,h.bufferedRequestCount--,h.writing)break}x===null&&(h.lastBufferedRequest=null)}h.bufferedRequest=x,h.bufferProcessing=!1}k.prototype._write=function(d,h,x){x(new m("_write()"))},k.prototype._writev=null,k.prototype.end=function(d,h,x){var D=this._writableState;return typeof d=="function"?(x=d,d=null,h=null):typeof h=="function"&&(x=h,h=null),d!=null&&this.write(d,h),D.corked&&(D.corked=1,this.uncork()),D.ending||or(this,D,x),this},Object.defineProperty(k.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function _t(d){return d.ending&&d.length===0&&d.bufferedRequest===null&&!d.finished&&!d.writing}function sr(d,h){d._final(function(x){h.pendingcb--,x&&A(d,x),h.prefinished=!0,d.emit("prefinish"),me(d,h)})}function pt(d,h){!h.prefinished&&!h.finalCalled&&(typeof d._final=="function"&&!h.destroyed?(h.pendingcb++,h.finalCalled=!0,I.nextTick(sr,d,h)):(h.prefinished=!0,d.emit("prefinish")))}function me(d,h){var x=_t(h);if(x&&(pt(d,h),h.pendingcb===0&&(h.finished=!0,d.emit("finish"),h.autoDestroy))){var D=d._readableState;(!D||D.autoDestroy&&D.endEmitted)&&d.destroy()}return x}function or(d,h,x){h.ending=!0,me(d,h),x&&(h.finished?I.nextTick(x):d.once("finish",x)),h.ended=!0,d.writable=!1}function lr(d,h,x){var D=d.entry;for(d.entry=null;D;){var N=D.callback;h.pendingcb--,N(x),D=D.next}h.corkedRequestsFree.next=d}return Object.defineProperty(k.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(h){!this._writableState||(this._writableState.destroyed=h)}}),k.prototype.destroy=f.destroy,k.prototype._undestroy=f.undestroy,k.prototype._destroy=function(d,h){h(d)},$t}var Gt,Oi;function Te(){if(Oi)return Gt;Oi=1;var t=Object.keys||function(g){var w=[];for(var b in g)w.push(b);return w};Gt=a;var e=Ui(),r=Fi();ce.exports(a,e);for(var i=t(r.prototype),n=0;n<i.length;n++){var s=i[n];a.prototype[s]||(a.prototype[s]=r.prototype[s])}function a(g){if(!(this instanceof a))return new a(g);e.call(this,g),r.call(this,g),this.allowHalfOpen=!0,g&&(g.readable===!1&&(this.readable=!1),g.writable===!1&&(this.writable=!1),g.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",u)))}Object.defineProperty(a.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(a.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(a.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function u(){this._writableState.ended||I.nextTick(f,this)}function f(g){g.end()}return Object.defineProperty(a.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(w){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=w,this._writableState.destroyed=w)}}),Gt}var Vt={},lt={exports:{}},Di;function qa(){return Di||(Di=1,function(t,e){var r=tt,i=r.Buffer;function n(a,u){for(var f in a)u[f]=a[f]}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?t.exports=r:(n(r,e),e.Buffer=s);function s(a,u,f){return i(a,u,f)}n(i,s),s.from=function(a,u,f){if(typeof a=="number")throw new TypeError("Argument must not be a number");return i(a,u,f)},s.alloc=function(a,u,f){if(typeof a!="number")throw new TypeError("Argument must be a number");var g=i(a);return u!==void 0?typeof f=="string"?g.fill(u,f):g.fill(u):g.fill(0),g},s.allocUnsafe=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return i(a)},s.allocUnsafeSlow=function(a){if(typeof a!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(a)}}(lt,lt.exports)),lt.exports}var Mi;function ki(){if(Mi)return Vt;Mi=1;var t=qa().Buffer,e=t.isEncoding||function(c){switch(c=""+c,c&&c.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function r(c){if(!c)return"utf8";for(var p;;)switch(c){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return c;default:if(p)return;c=(""+c).toLowerCase(),p=!0}}function i(c){var p=r(c);if(typeof p!="string"&&(t.isEncoding===e||!e(c)))throw new Error("Unknown encoding: "+c);return p||c}Vt.StringDecoder=n;function n(c){this.encoding=i(c);var p;switch(this.encoding){case"utf16le":this.text=b,this.end=_,p=4;break;case"utf8":this.fillLast=f,p=4;break;case"base64":this.text=m,this.end=E,p=3;break;default:this.write=T,this.end=O;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(p)}n.prototype.write=function(c){if(c.length===0)return"";var p,R;if(this.lastNeed){if(p=this.fillLast(c),p===void 0)return"";R=this.lastNeed,this.lastNeed=0}else R=0;return R<c.length?p?p+this.text(c,R):this.text(c,R):p||""},n.prototype.end=w,n.prototype.text=g,n.prototype.fillLast=function(c){if(this.lastNeed<=c.length)return c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,c.length),this.lastNeed-=c.length};function s(c){return c<=127?0:c>>5===6?2:c>>4===14?3:c>>3===30?4:c>>6===2?-1:-2}function a(c,p,R){var A=p.length-1;if(A<R)return 0;var M=s(p[A]);return M>=0?(M>0&&(c.lastNeed=M-1),M):--A<R||M===-2?0:(M=s(p[A]),M>=0?(M>0&&(c.lastNeed=M-2),M):--A<R||M===-2?0:(M=s(p[A]),M>=0?(M>0&&(M===2?M=0:c.lastNeed=M-3),M):0))}function u(c,p,R){if((p[0]&192)!==128)return c.lastNeed=0,"\uFFFD";if(c.lastNeed>1&&p.length>1){if((p[1]&192)!==128)return c.lastNeed=1,"\uFFFD";if(c.lastNeed>2&&p.length>2&&(p[2]&192)!==128)return c.lastNeed=2,"\uFFFD"}}function f(c){var p=this.lastTotal-this.lastNeed,R=u(this,c);if(R!==void 0)return R;if(this.lastNeed<=c.length)return c.copy(this.lastChar,p,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,p,0,c.length),this.lastNeed-=c.length}function g(c,p){var R=a(this,c,p);if(!this.lastNeed)return c.toString("utf8",p);this.lastTotal=R;var A=c.length-(R-this.lastNeed);return c.copy(this.lastChar,0,A),c.toString("utf8",p,A)}function w(c){var p=c&&c.length?this.write(c):"";return this.lastNeed?p+"\uFFFD":p}function b(c,p){if((c.length-p)%2===0){var R=c.toString("utf16le",p);if(R){var A=R.charCodeAt(R.length-1);if(A>=55296&&A<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1],R.slice(0,-1)}return R}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=c[c.length-1],c.toString("utf16le",p,c.length-1)}function _(c){var p=c&&c.length?this.write(c):"";if(this.lastNeed){var R=this.lastTotal-this.lastNeed;return p+this.lastChar.toString("utf16le",0,R)}return p}function m(c,p){var R=(c.length-p)%3;return R===0?c.toString("base64",p):(this.lastNeed=3-R,this.lastTotal=3,R===1?this.lastChar[0]=c[c.length-1]:(this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1]),c.toString("base64",p,c.length-R))}function E(c){var p=c&&c.length?this.write(c):"";return this.lastNeed?p+this.lastChar.toString("base64",0,3-this.lastNeed):p}function T(c){return c.toString(this.encoding)}function O(c){return c&&c.length?this.write(c):""}return Vt}var Pi=be.codes.ERR_STREAM_PREMATURE_CLOSE;function $a(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n<r;n++)i[n]=arguments[n];t.apply(this,i)}}}function Ga(){}function Va(t){return t.setHeader&&typeof t.abort=="function"}function Ni(t,e,r){if(typeof e=="function")return Ni(t,null,e);e||(e={}),r=$a(r||Ga);var i=e.readable||e.readable!==!1&&t.readable,n=e.writable||e.writable!==!1&&t.writable,s=function(){t.writable||u()},a=t._writableState&&t._writableState.finished,u=function(){n=!1,a=!0,i||r.call(t)},f=t._readableState&&t._readableState.endEmitted,g=function(){i=!1,f=!0,n||r.call(t)},w=function(E){r.call(t,E)},b=function(){var E;if(i&&!f)return(!t._readableState||!t._readableState.ended)&&(E=new Pi),r.call(t,E);if(n&&!a)return(!t._writableState||!t._writableState.ended)&&(E=new Pi),r.call(t,E)},_=function(){t.req.on("finish",u)};return Va(t)?(t.on("complete",u),t.on("abort",b),t.req?_():t.on("request",_)):n&&!t._writableState&&(t.on("end",s),t.on("close",s)),t.on("end",g),t.on("finish",u),e.error!==!1&&t.on("error",w),t.on("close",b),function(){t.removeListener("complete",u),t.removeListener("abort",b),t.removeListener("request",_),t.req&&t.req.removeListener("finish",u),t.removeListener("end",s),t.removeListener("close",s),t.removeListener("finish",u),t.removeListener("end",g),t.removeListener("error",w),t.removeListener("close",b)}}var Ht=Ni,Jt,Ii;function Ha(){if(Ii)return Jt;Ii=1;var t;function e(c,p,R){return p in c?Object.defineProperty(c,p,{value:R,enumerable:!0,configurable:!0,writable:!0}):c[p]=R,c}var r=Ht,i=Symbol("lastResolve"),n=Symbol("lastReject"),s=Symbol("error"),a=Symbol("ended"),u=Symbol("lastPromise"),f=Symbol("handlePromise"),g=Symbol("stream");function w(c,p){return{value:c,done:p}}function b(c){var p=c[i];if(p!==null){var R=c[g].read();R!==null&&(c[u]=null,c[i]=null,c[n]=null,p(w(R,!1)))}}function _(c){I.nextTick(b,c)}function m(c,p){return function(R,A){c.then(function(){if(p[a]){R(w(void 0,!0));return}p[f](R,A)},A)}}var E=Object.getPrototypeOf(function(){}),T=Object.setPrototypeOf((t={get stream(){return this[g]},next:function(){var p=this,R=this[s];if(R!==null)return Promise.reject(R);if(this[a])return Promise.resolve(w(void 0,!0));if(this[g].destroyed)return new Promise(function(q,k){I.nextTick(function(){p[s]?k(p[s]):q(w(void 0,!0))})});var A=this[u],M;if(A)M=new Promise(m(A,this));else{var j=this[g].read();if(j!==null)return Promise.resolve(w(j,!1));M=new Promise(this[f])}return this[u]=M,M}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var p=this;return new Promise(function(R,A){p[g].destroy(null,function(M){if(M){A(M);return}R(w(void 0,!0))})})}),t),E),O=function(p){var R,A=Object.create(T,(R={},e(R,g,{value:p,writable:!0}),e(R,i,{value:null,writable:!0}),e(R,n,{value:null,writable:!0}),e(R,s,{value:null,writable:!0}),e(R,a,{value:p._readableState.endEmitted,writable:!0}),e(R,f,{value:function(j,q){var k=A[g].read();k?(A[u]=null,A[i]=null,A[n]=null,j(w(k,!1))):(A[i]=j,A[n]=q)},writable:!0}),R));return A[u]=null,r(p,function(M){if(M&&M.code!=="ERR_STREAM_PREMATURE_CLOSE"){var j=A[n];j!==null&&(A[u]=null,A[i]=null,A[n]=null,j(M)),A[s]=M;return}var q=A[i];q!==null&&(A[u]=null,A[i]=null,A[n]=null,q(w(void 0,!0))),A[a]=!0}),p.on("readable",_.bind(null,A)),A};return Jt=O,Jt}var Xt,Bi;function Ja(){return Bi||(Bi=1,Xt=function(){throw new Error("Readable.from is not available in the browser")}),Xt}var Kt,Li;function Ui(){if(Li)return Kt;Li=1,Kt=F;var t;F.ReadableState=k,Gr.EventEmitter;var e=function(l,v){return l.listeners(v).length},r=Vr,i=tt.Buffer,n=He.Uint8Array||function(){};function s(o){return i.from(o)}function a(o){return i.isBuffer(o)||o instanceof n}var u=vi,f;u&&u.debuglog?f=u.debuglog("stream"):f=function(){};var g=Da(),w=Ri,b=Ci,_=b.getHighWaterMark,m=be.codes,E=m.ERR_INVALID_ARG_TYPE,T=m.ERR_STREAM_PUSH_AFTER_EOF,O=m.ERR_METHOD_NOT_IMPLEMENTED,c=m.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,p,R,A;ce.exports(F,r);var M=w.errorOrDestroy,j=["error","close","destroy","pause","resume"];function q(o,l,v){if(typeof o.prependListener=="function")return o.prependListener(l,v);!o._events||!o._events[l]?o.on(l,v):Array.isArray(o._events[l])?o._events[l].unshift(v):o._events[l]=[v,o._events[l]]}function k(o,l,v){t=t||Te(),o=o||{},typeof v!="boolean"&&(v=l instanceof t),this.objectMode=!!o.objectMode,v&&(this.objectMode=this.objectMode||!!o.readableObjectMode),this.highWaterMark=_(this,o,"readableHighWaterMark",v),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=o.emitClose!==!1,this.autoDestroy=!!o.autoDestroy,this.destroyed=!1,this.defaultEncoding=o.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,o.encoding&&(p||(p=ki().StringDecoder),this.decoder=new p(o.encoding),this.encoding=o.encoding)}function F(o){if(t=t||Te(),!(this instanceof F))return new F(o);var l=this instanceof t;this._readableState=new k(o,this,l),this.readable=!0,o&&(typeof o.read=="function"&&(this._read=o.read),typeof o.destroy=="function"&&(this._destroy=o.destroy)),r.call(this)}Object.defineProperty(F.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(l){!this._readableState||(this._readableState.destroyed=l)}}),F.prototype.destroy=w.destroy,F.prototype._undestroy=w.undestroy,F.prototype._destroy=function(o,l){l(o)},F.prototype.push=function(o,l){var v=this._readableState,C;return v.objectMode?C=!0:typeof o=="string"&&(l=l||v.defaultEncoding,l!==v.encoding&&(o=i.from(o,l),l=""),C=!0),U(this,o,l,!1,C)},F.prototype.unshift=function(o){return U(this,o,null,!0,!1)};function U(o,l,v,C,W){f("readableAddChunk",l);var P=o._readableState;if(l===null)P.reading=!1,Q(o,P);else{var B;if(W||(B=ne(P,l)),B)M(o,B);else if(P.objectMode||l&&l.length>0)if(typeof l!="string"&&!P.objectMode&&Object.getPrototypeOf(l)!==i.prototype&&(l=s(l)),C)P.endEmitted?M(o,new c):V(o,P,l,!0);else if(P.ended)M(o,new T);else{if(P.destroyed)return!1;P.reading=!1,P.decoder&&!v?(l=P.decoder.write(l),P.objectMode||l.length!==0?V(o,P,l,!1):ae(o,P)):V(o,P,l,!1)}else C||(P.reading=!1,ae(o,P))}return!P.ended&&(P.length<P.highWaterMark||P.length===0)}function V(o,l,v,C){l.flowing&&l.length===0&&!l.sync?(l.awaitDrain=0,o.emit("data",v)):(l.length+=l.objectMode?1:v.length,C?l.buffer.unshift(v):l.buffer.push(v),l.needReadable&&Z(o)),ae(o,l)}function ne(o,l){var v;return!a(l)&&typeof l!="string"&&l!==void 0&&!o.objectMode&&(v=new E("chunk",["string","Buffer","Uint8Array"],l)),v}F.prototype.isPaused=function(){return this._readableState.flowing===!1},F.prototype.setEncoding=function(o){p||(p=ki().StringDecoder);var l=new p(o);this._readableState.decoder=l,this._readableState.encoding=this._readableState.decoder.encoding;for(var v=this._readableState.buffer.head,C="";v!==null;)C+=l.write(v.data),v=v.next;return this._readableState.buffer.clear(),C!==""&&this._readableState.buffer.push(C),this._readableState.length=C.length,this};var X=1073741824;function Y(o){return o>=X?o=X:(o--,o|=o>>>1,o|=o>>>2,o|=o>>>4,o|=o>>>8,o|=o>>>16,o++),o}function K(o,l){return o<=0||l.length===0&&l.ended?0:l.objectMode?1:o!==o?l.flowing&&l.length?l.buffer.head.data.length:l.length:(o>l.highWaterMark&&(l.highWaterMark=Y(o)),o<=l.length?o:l.ended?l.length:(l.needReadable=!0,0))}F.prototype.read=function(o){f("read",o),o=parseInt(o,10);var l=this._readableState,v=o;if(o!==0&&(l.emittedReadable=!1),o===0&&l.needReadable&&((l.highWaterMark!==0?l.length>=l.highWaterMark:l.length>0)||l.ended))return f("read: emitReadable",l.length,l.ended),l.length===0&&l.ended?x(this):Z(this),null;if(o=K(o,l),o===0&&l.ended)return l.length===0&&x(this),null;var C=l.needReadable;f("need readable",C),(l.length===0||l.length-o<l.highWaterMark)&&(C=!0,f("length less than watermark",C)),l.ended||l.reading?(C=!1,f("reading or ended",C)):C&&(f("do read"),l.reading=!0,l.sync=!0,l.length===0&&(l.needReadable=!0),this._read(l.highWaterMark),l.sync=!1,l.reading||(o=K(v,l)));var W;return o>0?W=h(o,l):W=null,W===null?(l.needReadable=l.length<=l.highWaterMark,o=0):(l.length-=o,l.awaitDrain=0),l.length===0&&(l.ended||(l.needReadable=!0),v!==o&&l.ended&&x(this)),W!==null&&this.emit("data",W),W};function Q(o,l){if(f("onEofChunk"),!l.ended){if(l.decoder){var v=l.decoder.end();v&&v.length&&(l.buffer.push(v),l.length+=l.objectMode?1:v.length)}l.ended=!0,l.sync?Z(o):(l.needReadable=!1,l.emittedReadable||(l.emittedReadable=!0,we(o)))}}function Z(o){var l=o._readableState;f("emitReadable",l.needReadable,l.emittedReadable),l.needReadable=!1,l.emittedReadable||(f("emitReadable",l.flowing),l.emittedReadable=!0,I.nextTick(we,o))}function we(o){var l=o._readableState;f("emitReadable_",l.destroyed,l.length,l.ended),!l.destroyed&&(l.length||l.ended)&&(o.emit("readable"),l.emittedReadable=!1),l.needReadable=!l.flowing&&!l.ended&&l.length<=l.highWaterMark,d(o)}function ae(o,l){l.readingMore||(l.readingMore=!0,I.nextTick(_t,o,l))}function _t(o,l){for(;!l.reading&&!l.ended&&(l.length<l.highWaterMark||l.flowing&&l.length===0);){var v=l.length;if(f("maybeReadMore read 0"),o.read(0),v===l.length)break}l.readingMore=!1}F.prototype._read=function(o){M(this,new O("_read()"))},F.prototype.pipe=function(o,l){var v=this,C=this._readableState;switch(C.pipesCount){case 0:C.pipes=o;break;case 1:C.pipes=[C.pipes,o];break;default:C.pipes.push(o);break}C.pipesCount+=1,f("pipe count=%d opts=%j",C.pipesCount,l);var W=(!l||l.end!==!1)&&o!==I.stdout&&o!==I.stderr,P=W?Ce:Ue;C.endEmitted?I.nextTick(P):v.once("end",P),o.on("unpipe",B);function B(Ae,Fe){f("onunpipe"),Ae===v&&Fe&&Fe.hasUnpiped===!1&&(Fe.hasUnpiped=!0,Ps())}function Ce(){f("onend"),o.end()}var yt=sr(v);o.on("drain",yt);var an=!1;function Ps(){f("cleanup"),o.removeListener("close",fr),o.removeListener("finish",cr),o.removeListener("drain",yt),o.removeListener("error",ur),o.removeListener("unpipe",B),v.removeListener("end",Ce),v.removeListener("end",Ue),v.removeListener("data",sn),an=!0,C.awaitDrain&&(!o._writableState||o._writableState.needDrain)&&yt()}v.on("data",sn);function sn(Ae){f("ondata");var Fe=o.write(Ae);f("dest.write",Fe),Fe===!1&&((C.pipesCount===1&&C.pipes===o||C.pipesCount>1&&N(C.pipes,o)!==-1)&&!an&&(f("false write response, pause",C.awaitDrain),C.awaitDrain++),v.pause())}function ur(Ae){f("onerror",Ae),Ue(),o.removeListener("error",ur),e(o,"error")===0&&M(o,Ae)}q(o,"error",ur);function fr(){o.removeListener("finish",cr),Ue()}o.once("close",fr);function cr(){f("onfinish"),o.removeListener("close",fr),Ue()}o.once("finish",cr);function Ue(){f("unpipe"),v.unpipe(o)}return o.emit("pipe",v),C.flowing||(f("pipe resume"),v.resume()),o};function sr(o){return function(){var v=o._readableState;f("pipeOnDrain",v.awaitDrain),v.awaitDrain&&v.awaitDrain--,v.awaitDrain===0&&e(o,"data")&&(v.flowing=!0,d(o))}}F.prototype.unpipe=function(o){var l=this._readableState,v={hasUnpiped:!1};if(l.pipesCount===0)return this;if(l.pipesCount===1)return o&&o!==l.pipes?this:(o||(o=l.pipes),l.pipes=null,l.pipesCount=0,l.flowing=!1,o&&o.emit("unpipe",this,v),this);if(!o){var C=l.pipes,W=l.pipesCount;l.pipes=null,l.pipesCount=0,l.flowing=!1;for(var P=0;P<W;P++)C[P].emit("unpipe",this,{hasUnpiped:!1});return this}var B=N(l.pipes,o);return B===-1?this:(l.pipes.splice(B,1),l.pipesCount-=1,l.pipesCount===1&&(l.pipes=l.pipes[0]),o.emit("unpipe",this,v),this)},F.prototype.on=function(o,l){var v=r.prototype.on.call(this,o,l),C=this._readableState;return o==="data"?(C.readableListening=this.listenerCount("readable")>0,C.flowing!==!1&&this.resume()):o==="readable"&&!C.endEmitted&&!C.readableListening&&(C.readableListening=C.needReadable=!0,C.flowing=!1,C.emittedReadable=!1,f("on readable",C.length,C.reading),C.length?Z(this):C.reading||I.nextTick(me,this)),v},F.prototype.addListener=F.prototype.on,F.prototype.removeListener=function(o,l){var v=r.prototype.removeListener.call(this,o,l);return o==="readable"&&I.nextTick(pt,this),v},F.prototype.removeAllListeners=function(o){var l=r.prototype.removeAllListeners.apply(this,arguments);return(o==="readable"||o===void 0)&&I.nextTick(pt,this),l};function pt(o){var l=o._readableState;l.readableListening=o.listenerCount("readable")>0,l.resumeScheduled&&!l.paused?l.flowing=!0:o.listenerCount("data")>0&&o.resume()}function me(o){f("readable nexttick read 0"),o.read(0)}F.prototype.resume=function(){var o=this._readableState;return o.flowing||(f("resume"),o.flowing=!o.readableListening,or(this,o)),o.paused=!1,this};function or(o,l){l.resumeScheduled||(l.resumeScheduled=!0,I.nextTick(lr,o,l))}function lr(o,l){f("resume",l.reading),l.reading||o.read(0),l.resumeScheduled=!1,o.emit("resume"),d(o),l.flowing&&!l.reading&&o.read(0)}F.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function d(o){var l=o._readableState;for(f("flow",l.flowing);l.flowing&&o.read()!==null;);}F.prototype.wrap=function(o){var l=this,v=this._readableState,C=!1;o.on("end",function(){if(f("wrapped end"),v.decoder&&!v.ended){var B=v.decoder.end();B&&B.length&&l.push(B)}l.push(null)}),o.on("data",function(B){if(f("wrapped data"),v.decoder&&(B=v.decoder.write(B)),!(v.objectMode&&B==null)&&!(!v.objectMode&&(!B||!B.length))){var Ce=l.push(B);Ce||(C=!0,o.pause())}});for(var W in o)this[W]===void 0&&typeof o[W]=="function"&&(this[W]=function(Ce){return function(){return o[Ce].apply(o,arguments)}}(W));for(var P=0;P<j.length;P++)o.on(j[P],this.emit.bind(this,j[P]));return this._read=function(B){f("wrapped _read",B),C&&(C=!1,o.resume())},this},typeof Symbol=="function"&&(F.prototype[Symbol.asyncIterator]=function(){return R===void 0&&(R=Ha()),R(this)}),Object.defineProperty(F.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(F.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(F.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(l){this._readableState&&(this._readableState.flowing=l)}}),F._fromList=h,Object.defineProperty(F.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function h(o,l){if(l.length===0)return null;var v;return l.objectMode?v=l.buffer.shift():!o||o>=l.length?(l.decoder?v=l.buffer.join(""):l.buffer.length===1?v=l.buffer.first():v=l.buffer.concat(l.length),l.buffer.clear()):v=l.buffer.consume(o,l.decoder),v}function x(o){var l=o._readableState;f("endReadable",l.endEmitted),l.endEmitted||(l.ended=!0,I.nextTick(D,l,o))}function D(o,l){if(f("endReadableNT",o.endEmitted,o.length),!o.endEmitted&&o.length===0&&(o.endEmitted=!0,l.readable=!1,l.emit("end"),o.autoDestroy)){var v=l._writableState;(!v||v.autoDestroy&&v.finished)&&l.destroy()}}typeof Symbol=="function"&&(F.from=function(o,l){return A===void 0&&(A=Ja()),A(F,o,l)});function N(o,l){for(var v=0,C=o.length;v<C;v++)if(o[v]===l)return v;return-1}return Kt}var Wi=le,ut=be.codes,Xa=ut.ERR_METHOD_NOT_IMPLEMENTED,Ka=ut.ERR_MULTIPLE_CALLBACK,Qa=ut.ERR_TRANSFORM_ALREADY_TRANSFORMING,Za=ut.ERR_TRANSFORM_WITH_LENGTH_0,ft=Te();ce.exports(le,ft);function es(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new Ka);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}function le(t){if(!(this instanceof le))return new le(t);ft.call(this,t),this._transformState={afterTransform:es.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",ts)}function ts(){var t=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(e,r){ji(t,e,r)}):ji(this,null,null)}le.prototype.push=function(t,e){return this._transformState.needTransform=!1,ft.prototype.push.call(this,t,e)},le.prototype._transform=function(t,e,r){r(new Xa("_transform()"))},le.prototype._write=function(t,e,r){var i=this._transformState;if(i.writecb=r,i.writechunk=t,i.writeencoding=e,!i.transforming){var n=this._readableState;(i.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}},le.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0},le.prototype._destroy=function(t,e){ft.prototype._destroy.call(this,t,function(r){e(r)})};function ji(t,e,r){if(e)return t.emit("error",e);if(r!=null&&t.push(r),t._writableState.length)throw new Za;if(t._transformState.transforming)throw new Qa;return t.push(null)}var rs=Le,Yi=Wi;ce.exports(Le,Yi);function Le(t){if(!(this instanceof Le))return new Le(t);Yi.call(this,t)}Le.prototype._transform=function(t,e,r){r(null,t)};var Qt;function is(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var zi=be.codes,ns=zi.ERR_MISSING_ARGS,as=zi.ERR_STREAM_DESTROYED;function qi(t){if(t)throw t}function ss(t){return t.setHeader&&typeof t.abort=="function"}function os(t,e,r,i){i=is(i);var n=!1;t.on("close",function(){n=!0}),Qt===void 0&&(Qt=Ht),Qt(t,{readable:e,writable:r},function(a){if(a)return i(a);n=!0,i()});var s=!1;return function(a){if(!n&&!s){if(s=!0,ss(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(a||new as("pipe"))}}}function $i(t){t()}function ls(t,e){return t.pipe(e)}function us(t){return!t.length||typeof t[t.length-1]!="function"?qi:t.pop()}function fs(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var i=us(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new ns("streams");var n,s=e.map(function(a,u){var f=u<e.length-1,g=u>0;return os(a,f,g,function(w){n||(n=w),w&&s.forEach($i),!f&&(s.forEach($i),i(n))})});return e.reduce(ls)}var cs=fs;(function(t,e){e=t.exports=Ui(),e.Stream=e,e.Readable=e,e.Writable=Fi(),e.Duplex=Te(),e.Transform=Wi,e.PassThrough=rs,e.finished=Ht,e.pipeline=cs})(Ct,Ct.exports);var Gi=Ct.exports.Transform,Vi=ce.exports;function Se(t){Gi.call(this,t),this._destroyed=!1}Vi(Se,Gi),Se.prototype.destroy=function(t){if(!this._destroyed){this._destroyed=!0;var e=this;I.nextTick(function(){t&&e.emit("error",t),e.emit("close")})}};function hs(t,e,r){r(null,t)}function Zt(t){return function(e,r,i){return typeof e=="function"&&(i=r,r=e,e={}),typeof r!="function"&&(r=hs),typeof i!="function"&&(i=null),t(e,r,i)}}St.exports=Zt(function(t,e,r){var i=new Se(t);return i._transform=e,r&&(i._flush=r),i}),St.exports.ctor=Zt(function(t,e,r){function i(n){if(!(this instanceof i))return new i(n);this.options=Object.assign({},t,n),Se.call(this,this.options)}return Vi(i,Se),i.prototype._transform=e,r&&(i.prototype._flush=r),i}),St.exports.obj=Zt(function(t,e,r){var i=new Se(Object.assign({objectMode:!0,highWaterMark:16},t));return i._transform=e,r&&(i._flush=r),i});class Hi{constructor(e,r=4){this._string=null,this._type="form",this._readOnly=!1,this._context={},this._onChangeFields={},this._keyIdx=0,this._invisibleFields=[],this._fields=e,this._container=new Me(r,6,!1,"root")}get fields(){return this._fields}get container(){return this._container}get string(){return this._string}get type(){return this._type}get readOnly(){return this._readOnly}set readOnly(e){this._readOnly=e}get context(){return this._context}set context(e){this._context=e}get onChangeFields(){return this._onChangeFields}set onChangeFields(e){this._onChangeFields=e}get keyIdx(){return this._keyIdx}set keyIdx(e){this._keyIdx=e}get invisibleFields(){return this._invisibleFields}set invisibleFields(e){this._invisibleFields=e}parse(e,r){var i;const{values:n={},readOnly:s=!1}=r||{},a=Ge(e).filter(u=>u.tagName==="form")[0];this._string=((i=a.attributes)==null?void 0:i.string)||null,this._string&&(this._string=$(this._string)),this._readOnly=s,this._context=n.id?{active_id:n.id,active_ids:[n.id]}:{},this._invisibleFields=[],this.parseNode({fields:a.children,container:this._container,values:n})}parseNode({fields:e,container:r,values:i}){const n=new Rt;e.filter(s=>typeof s=="object").forEach(s=>{var a,u;const{tagName:f,attributes:g,children:w}=s;let b=f,_=g;if(f==="field"){const{name:R,widget:A}=g;if(A)b=A;else if(R){if(!this._fields[R])throw new Error(`Field ${R} doesn't exist in fields defintion`);b=this._fields[R].type}_={...this._fields[R],...g,fieldsWidgetType:this._fields[R].type}}const m=fn({tagAttributes:_,values:i,fields:this._fields});let E;f==="button"&&_.states?E=dn({states:_.states,values:i}):E=hn({fieldName:_.name,values:i,fields:this._fields});const T=Lr({context:_.context||((a=this._fields[_.name])==null?void 0:a.context),values:i,fields:this._fields});_.on_change&&(this._onChangeFields[_.name]=yn(_.on_change));let O;Ji(_.domain)&&(O=_.domain),Ji((u=this._fields[_.name])==null?void 0:u.domain)&&(O=this._fields[_.name].domain),this._keyIdx=this._keyIdx+1;const c={...m,...E,context:T,domain:O,key:`${this._keyIdx}`},p=n.createWidget(b,c);p.invisible&&p instanceof L&&this._invisibleFields.push(c.name),p instanceof de&&this.parseNode({fields:w,container:p.container,values:i}),p.readOnly=p.readOnly||this.readOnly,r.addWidget(p)})}findById(e){return this.container.findById(e)}}function Ji(t){return t?Array.isArray(t)&&t.length>0?!0:typeof t=="string"&&t!==""&&t!=="[]":!1}class ds{constructor(e){this._columns=[],this._string=null,this._type="tree",this._colors=null,this._status=null,this._editable=null,this._fields=e}get fields(){return this._fields}get columns(){return this._columns}get string(){return this._string}get type(){return this._type}get colors(){return this._colors}get status(){return this._status}get editable(){return this._editable}parse(e){const r=Ge(e).filter(n=>n.tagName==="tree")[0];this._string=r.attributes.string||null,this._string&&(this._string=$(this._string)),this._colors=r.attributes.colors||null,this._colors&&(this._colors=$(this._colors)),this._status=r.attributes.status||null,this._status&&(this._status=$(this._status)),this._editable=r.attributes.editable||null;const i=new Rt;r.children.forEach(n=>{const{tagName:s,attributes:a}=n;let u=null;if(s==="field"){const{name:f,widget:g}=a;let w=a;if(f){if(!this._fields[f])throw new Error(`Field ${f} doesn't exist in fields defintion`);const b=this._fields[f];u=b.type,(Array.isArray(b==null?void 0:b.domain)&&(b==null?void 0:b.domain.length)===0||(b==null?void 0:b.domain)===!1)&&a.domain&&a.domain.length>0&&delete b.domain,w={...b,...a,fieldsWidgetType:b==null?void 0:b.type}}if(g&&(u=g),!w.invisible){const b=i.createWidget(u,w);this._columns.push(b)}}})}findById(e){return this._columns.find(r=>{if(r.findById)return r.findById(e)})}}const Xi={text:"text",many2one:"many2one",char:"char",boolean:"boolean",selection:"selection",float:"float",float_time:"float_time",progressbar:"progressbar",integer:"integer",date:"date",datetime:"datetime"};class gs{get searchFields(){return this._searchFields}get fields(){return this._fields}get simpleSearchContainer(){return this._simpleSearchContainer}get advancedSearchContainer(){return this._advancedSearchContainer}get formXml(){return this._formXml}constructor(e,r,i,n=8){this._searchFields=e,this._fields=r,this._formXml=i,this._simpleSearchContainer=new Me(n),this._advancedSearchContainer=new Me(n)}parse(){const e=new Rt,r=new Hi(this.fields);r.parse(this.formXml),this.parseFields(this.searchFields.primary,e,r).forEach(s=>{this.simpleSearchContainer.addWidget(s,{addLabel:!1}),this.advancedSearchContainer.addWidget(s,{addLabel:!1})}),this.parseFields(this.searchFields.secondary,e,r).forEach(s=>{this.advancedSearchContainer.addWidget(s,{addLabel:!1})})}parseFields(e,r,i){return e.map(n=>{var s,a;const u={...this.fields[n],name:n,colspan:2},{type:f}=u;let g=(a=(s=i.findById(n))==null?void 0:s.type)!=null?a:f;return Xi[g]===void 0&&(g=f),r.createWidget(g,u)})}findById(e){return this.advancedSearchContainer.findById(e)}}const _s=({domain:t,widgetFieldName:e})=>{const r=[];return t.forEach(i=>{if(!Array.isArray(i))return;const[n,s,a]=i;let u,f;n.indexOf(".")!==-1?(u=n.substr(0,n.indexOf(".")),f=n.substr(n.indexOf(".")+1,n.length-1)):(u=n,f="id"),u===e&&r.push([f,s,a])}),r};class Ki{constructor(e){this._action_id=null,this._position=null,e.action_id&&(this._action_id=e.action_id),e.position&&(this._position=e.position)}get action_id(){return this._action_id}get position(){return this._position}}class ps{constructor(e){this._string=null,this._items=[];const r=Ge(e).filter(n=>n.tagName==="dashboard")[0];this._string=r.attributes.string||null;const{children:i}=r;i.forEach(n=>{n.tagName==="dashboard_item"&&this._items.push(new Ki(n.attributes))})}get string(){return this._string}get items(){return this._items}}class er{constructor(e){this._string=null,this._timerange=null,this._string=e.attributes.string||null,this._timerange=e.attributes.timerange||null}get string(){return this._string}get type(){return this._type}get timerange(){return this._timerange}}const ys=t=>t===1||t==="1"||t===!0||t==="True";class tr extends er{constructor(e,r){super(r),this._color=null,this._icon=null,this._totalDomain=null,this._showPercent=!1,this._suffix=null,this._type=e,this._color=r.attributes.color||null,this._color&&(this._color=$(this._color)),this._icon=r.attributes.icon||null,this._icon&&(this._icon=$(this._icon)),this._suffix=r.attributes.suffix||null,this._totalDomain=r.attributes.totalDomain||null,this._showPercent=ys(r.attributes.showPercent)}get color(){return this._color}get icon(){return this._icon}get totalDomain(){return this._totalDomain}get showPercent(){return this._showPercent}get suffix(){return this._suffix}}class Qi extends tr{constructor(e,r){super(e,r);const{children:i}=r;i.forEach(n=>{if(n.tagName==="field"){const s=n.attributes.name,a=n.attributes.operator;this._field=s||void 0,this._operator=a}})}get field(){return this._field}get operator(){return this._operator}}const bs=t=>{const e=[];let r;if(t.forEach(i=>{if(i.tagName==="field"){const n=i.attributes.axis,s=i.attributes.operator,a=i.attributes.name,u=i.attributes.label||void 0,f=i.attributes.stacked||void 0;if(!n)throw new Error(`Field ${a} doesn't have an axis`);if(!a)throw new Error("Missing name attribute for field");n==="x"?r=new en({name:a}):n==="y"&&e.push(new Zi({name:a,operator:s,label:u,stacked:f}))}}),!r)throw new Error("No x axis found");if(!e.length)throw new Error("No y axis found. At least we need one y axis");return{x:r,y:e}};class ct extends er{constructor(e,r){super(r),this._type=e;const i=bs(r.children);this._x=i.x,this._y=i.y}get x(){return this._x}get y(){return this._y}}const ws={indicator:tr,indicatorField:Qi,line:ct,bar:ct,pie:ct},ms=t=>{const e=Ge(t).filter(n=>n.tagName==="graph")[0],r=e.attributes.type;if(!r)throw new Error(`${r} is not a valid graph`);const i=ws[r];if(!i)throw new Error(`${r} not found as a GraphModel`);return new i(r,e)};class rr{get name(){return this._name}get axis(){return this._axis}constructor({name:e,axis:r}){this._name=e,this._axis=r}}class Zi extends rr{constructor({name:e,operator:r,label:i,stacked:n}){super({name:e,axis:"y"}),this._operator=r,this._label=i,this._stacked=n}get operator(){return this._operator}get label(){return this._label}get stacked(){return this._stacked}}class en extends rr{constructor({name:e}){super({name:e,axis:"x"})}}const vs=({ooui:t})=>{const r=[t.x.name];return t.y?(t.y.forEach(i=>{i.operator!=="count"&&!r.includes(i.name)&&r.push(i.name),i.label&&!r.includes(i.label)&&r.push(i.label)}),r):[]};function ir({fields:t,values:e,fieldName:r}){const i=t[r],n=e[r];if(!i)throw new Error(`Field ${r} not found`);if(i.type==="many2one")return n?{value:n[0],label:n[1]}:{value:!1,label:void 0};if(i.type==="selection"){const a=i.selection.find(u=>u[0]===n);return a?{value:n,label:a[1]}:{value:!1,label:void 0}}return{value:n,label:n}}const Es=Object.freeze(Object.defineProperty({__proto__:null,getFieldsToRetrieve:vs,getValueAndLabelForField:ir},Symbol.toStringTag,{value:"Module"}));function xs({values:t,timerange:e}){const r=Ss({values:t,timerange:e});return Rs({values:r,timerange:e})}function Rs({values:t,timerange:e}){let r=[];const i=rn({values:t,groupBy:"type-stacked"}),n=`${e}s`;return Object.keys(i).forEach(a=>{const u=i[a];for(let f=0;f<u.length;f++){const g=u[f];if(r.push(g),f===u.length-1)return;const w=g.x,b=u[f+1].x;if(!tn([w,b],n)){const _=Ts({dates:[w,b],timerange:e});r=r.concat(_.map(m=>({x:m,value:0,type:g.type,stacked:g.stacked})))}}}),r.sort((a,u)=>a.x<u.x?-1:a.x>u.x?1:0)}function Ts({dates:t,timerange:e}){const r=[],i=`${e}s`;if(t.length===1)return t;const n=t.sort((s,a)=>s<a?-1:s>a?1:0);for(let s=0;s<n.length-1;s++){const a=n[s],u=n[s+1];if(!tn([a,u],i)){let f=De.default(a,ht(i)).add(1,i),g=De.default(u,ht(i));for(;f.isBefore(g);)r.push(f.format(ht(i))),f.add(1,i)}}return r}function Ss({values:t,timerange:e}){const r=Cs({values:t,timerange:e});let i=[];const n=rn({values:r,groupBy:"all"});return Object.keys(n).forEach(s=>{const a=n[s],u=a[0].operator==="count"?"+":a[0].operator,f=dt({values:a.map(g=>g.value),operator:u});i.push({...a[0],value:f})}),i}function Cs({values:t,timerange:e}){return t.map(r=>({...r,x:As({date:r.x,timerange:e})}))}function As({date:t,timerange:e}){let r=Fs(t);const i=De.default(t,r);switch(e){case"hour":{r="YYYY-MM-DD HH:00";break}case"day":{r="YYYY-MM-DD";break}case"week":{r="YYYY-WW";break}case"month":{r="YYYY-MM";break}case"year":{r="YYYY";break}}return i.format(r)}function Fs(t){return t.indexOf(":")?"YYYY-MM-DD HH:mm:ss":"YYYY-MM-DD"}function tn(t,e){let r=!1;const i=ht(e);if(t.length===0)return!1;if(t.length===1)return!0;for(let n=0;n<t.length-1;n++){const s=De.default(t[n],i),u=De.default(t[n+1],i).diff(s,e);Math.abs(u)===1?r=!0:r=!1}return r}function rn({values:t,groupBy:e}){const r={};return t.forEach(i=>{const n=i.x,s=i.type,a=i.stacked,u=e==="all"?`${n}-${s}-${a}`:`${s}-${a}`;r[u]||(r[u]=[]),r[u].push(i)}),r}function ht(t){switch(t){default:case"hours":return"YYYY-MM-DD HH:mm";case"days":return"YYYY-MM-DD";case"weeks":return"YYYY-WW";case"months":return"YYYY-MM";case"years":return"YYYY"}}const Os={count:"count","+":"sum","-":"subtract","*":"multiply",avg:"average",min:"min",max:"max"},Ds=({ooui:t,values:e,fields:r,options:i})=>{const n=ar({fieldName:t.x.name,values:e,fields:r}),s=[];t.y.forEach(_=>{Object.keys(n).forEach(m=>{const E=n[m].label,T=n[m].entries;if(_.label){const O=ar({fieldName:_.label,values:T,fields:r});Object.keys(O).forEach(c=>{const p=O[c].entries,R=O[c].label,A=nr({entries:p,fields:r,fieldName:_.name}),M=dt({values:A,operator:_.operator});s.push({x:E||!1,value:M,type:R,operator:_.operator,stacked:_.stacked})})}else{const O=nr({entries:T,fields:r,fieldName:_.name}),c=dt({values:O,operator:_.operator});s.push({x:E||!1,value:c,type:nn({yAxis:_,fields:r}),operator:_.operator,stacked:_.stacked})}})});const a=t.y.some(_=>_.label!==void 0),u=t.y.some(_=>_.stacked!==void 0);let g=[...s.sort((_,m)=>_.x<m.x?-1:_.x>m.x?1:0)];u&&t.y.filter(_=>_.stacked!==void 0).length>1&&(g=g.map(_=>({..._,type:`${_.type} - ${_.stacked}`})));let w=[...g];t.type==="pie"&&w.some(_=>_.x===!1)?w=w.map(_=>_.x===!1?{..._,x:(i==null?void 0:i.uninformedString)||"Not informed"}:_):g.some(_=>_.x===!1)&&(w=w.filter(_=>_.x!==!1));let b=w;return t.timerange?b=xs({values:b,timerange:t.timerange}):t.type=="pie"&&(b=w.sort((_,m)=>m.value-_.value)),{data:b,isGroup:u||a,isStack:u}};function nr({entries:t,fieldName:e,fields:r}){return t.map(i=>ir({fieldName:e,values:i,fields:r})).map(({value:i,label:n})=>n)}function dt({operator:t,values:e}){switch(t){case"count":return e.length;case"+":return gt(e.reduce(function(r,i){return r+i}));case"-":return gt(e.reduce(function(r,i){return r-i}));case"*":return gt(e.reduce(function(r,i){return r*i}));case"avg":{const i=e.reduce((n,s)=>n+s,0)/e.length||0;return gt(i)}case"min":return Math.min(...e);case"max":return Math.max(...e)}}function gt(t){return Math.round((t+Number.EPSILON)*100)/100}function ar({fieldName:t,fields:e,values:r}){const i={};return r.forEach(n=>{const{value:s,label:a}=ir({fields:e,values:n,fieldName:t});i[s]||(i[s]={label:a,entries:[]}),i[s].entries.push(n)}),i}function Ms(t){let e=[];return Object.keys(t).forEach(r=>{const i=t[r];e=e.concat(i.entries)}),e}function nn({yAxis:t,fields:e}){const r=e[t.name];return r&&r.string?r.string:t.name}const ks=Object.freeze(Object.defineProperty({__proto__:null,labelsForOperator:Os,processGraphData:Ds,getValuesForYField:nr,getValueForOperator:dt,getValuesGroupedByField:ar,getAllObjectsInGroupedValues:Ms,getYAxisFieldname:nn},Symbol.toStringTag,{value:"Module"}));S.Avatar=hr,S.Binary=Cr,S.Boolean=vt,S.Button=_r,S.ButtonGroup=pr,S.Char=ze,S.CodeEditor=Ir,S.Container=Me,S.ContainerWidget=de,S.Dashboard=ps,S.DashboardItem=Ki,S.Date=Er,S.DateTime=xr,S.Field=L,S.Float=$e,S.FloatTime=mr,S.Form=Hi,S.Graph=er,S.GraphAxis=rr,S.GraphChart=ct,S.GraphIndicator=tr,S.GraphIndicatorField=Qi,S.GraphXAxis=en,S.GraphYAxis=Zi,S.Group=gr,S.Image=Ar,S.Indicator=Or,S.Integer=wr,S.Label=wt,S.Many2many=Rr,S.Many2one=yr,S.Markdown=br,S.MultiCheckbox=xt,S.NewLine=bt,S.Notebook=mt,S.One2many=Et,S.Page=dr,S.ProgressBar=vr,S.Radio=kr,S.Reference=Sr,S.SearchFieldTypes=Xi,S.SearchFilter=gs,S.Selection=ve,S.Separator=Tr,S.Steps=Nr,S.Switch=Pr,S.Tag=Mr,S.Tags=Dr,S.Text=qe,S.Time=Br,S.Timeline=Fr,S.Tree=ds,S.Widget=he,S.graphFieldUtils=Es,S.graphProcessor=ks,S.parseContext=Lr,S.parseGraph=ms,S.transformDomainForChildWidget=_s,Object.defineProperties(S,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
21
21
|
//# sourceMappingURL=ooui.umd.js.map
|