@zhijiancloud/bpm 1.0.29 → 1.0.31

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.
Files changed (45) hide show
  1. package/dist/141.umd.js +1 -0
  2. package/dist/204.umd.js +1 -0
  3. package/dist/557.umd.js +2 -0
  4. package/dist/557.umd.js.LICENSE.txt +283 -0
  5. package/dist/559.umd.js +1 -0
  6. package/dist/584.umd.js +1 -0
  7. package/dist/997.umd.js +1 -0
  8. package/dist/bpmAppointment.umd.js +1 -1
  9. package/dist/bpmArea.umd.js +1 -1
  10. package/dist/bpmAreaElevation.umd.js +1 -1
  11. package/dist/bpmAudit.umd.js +1 -1
  12. package/dist/bpmDateTime.umd.js +1 -1
  13. package/dist/bpmExternalFormLink.umd.js +1 -0
  14. package/dist/bpmField.umd.js +5 -5
  15. package/dist/bpmFieldsFilter.umd.js +3 -3
  16. package/dist/bpmFormField.umd.js +5 -5
  17. package/dist/bpmMapLocation.umd.js +1 -1
  18. package/dist/bpmMulFile.umd.js +1 -1
  19. package/dist/bpmMulImage.umd.js +1 -1
  20. package/dist/bpmNumber.umd.js +1 -1
  21. package/dist/bpmOverTime.umd.js +1 -1
  22. package/dist/bpmRating.umd.js +1 -1
  23. package/dist/bpmRichText.umd.js +1 -1
  24. package/dist/bpmSelect.umd.js +1 -1
  25. package/dist/bpmSelectCheckItem.umd.js +1 -1
  26. package/dist/bpmSelectEntranceForm.umd.js +3 -3
  27. package/dist/bpmSelectFromField.umd.js +1 -1
  28. package/dist/bpmSelectFromForm.umd.js +1 -1
  29. package/dist/bpmSelectFromId.umd.js +1 -1
  30. package/dist/bpmSelectFromMulForm.umd.js +1 -1
  31. package/dist/bpmSelectHouseOwner.umd.js +1 -1
  32. package/dist/bpmSelectIssue.umd.js +1 -1
  33. package/dist/bpmSelectUser.umd.js +1 -1
  34. package/dist/bpmSignature.umd.js +1 -1
  35. package/dist/bpmSpliter.umd.js +1 -1
  36. package/dist/bpmSubForm.umd.js +1 -1
  37. package/dist/bpmSubFormField.umd.js +5 -5
  38. package/dist/bpmText.umd.js +1 -1
  39. package/dist/bpmTime.umd.js +1 -1
  40. package/dist/bpmVideo.umd.js +1 -0
  41. package/dist/bpmVideo.umd.js.LICENSE.txt +283 -0
  42. package/dist/css/bpmExternalFormLink.css +1 -0
  43. package/dist/css/index.css +1 -1
  44. package/dist/index.umd.js +5 -5
  45. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs"),require("@antv/g6")):"function"==typeof define&&define.amd?define(["lodash","qs","@antv/g6"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs"),require("@antv/g6")):e.bpm2=t(e.lodash,e.qs,e["@antv/g6"])}(self,(function(e,t,r){return function(){"use strict";var s={5281:function(e,t,r){r.d(t,{A:function(){return d}});var s=r(9795),a=r(6773),o=r.n(a),n=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return o().get(t,"0")}loads(...e){return new Promise(((t,r)=>{this._queue.push({keys:e,resolve:t,reject:r}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};o().each(e,(e=>{o().each(e.keys,(e=>t[e]=null))}));let r=o().keys(t);this._fnBatchLoad(r).then((s=>{o().each(r,((e,r)=>{t[e]=s[r]})),o().each(e,(({keys:e,resolve:r})=>{r(o().map(e,(e=>t[e])))}))})).catch((t=>{o().each(e,(({reject:e})=>e(t)))}))}};const i=async(e,t,r)=>{if(t.setNetworking(!0),t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,r),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,s.Fr)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let a=_.cloneDeep(e);if(a.can_custom_org_params){let e=_.cloneDeep(_.get(t,"orgInfo",{}));console.log("bpm3_orgInfo",e),e.custom_page_level&&(a.params.page_level=e.custom_page_level),e.custom_group_id&&(a.params.group_id=e.custom_group_id),e.custom_team_id&&(a.params.team_id=e.custom_team_id),e.custom_project_id&&(a.params.project_id=e.custom_project_id)}console.log("bpm3_orgInfo_reqArgs",a);let o=await zj.net.request(a);return t.setNetworking(!1),o},c={},l={};var d={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a}){return i({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_definition/`,method:"GET"},e,s)},getOptions(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return i({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_search/`,method:"GET",params:o},e,s)},getListSelected(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return i({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_selected/`,method:"GET",params:o},e,s)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:r,orgInfo:s,uniqueId:a}){const o=`${t}/${r}`,l=c[o]||new n((async o=>{let n=`/app_flow/v1/papi/assist_field/${t}/${r}/list_title/`;const c=await i({url:n,method:"GET",params:{values:JSON.stringify(o)}},e,s),l=_.get(c,"data.data.data",{});let d=[];return _.map(o,(e=>{a?(e=JSON.parse(e),e=_.get(e,`${a}`),d=_.concat(d,l[e])):d=_.concat(d,l[e])})),d}));return c[o]=l,l},getTitle(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return i({url:`/app_flow/v1/papi/assist_field/${t}/${r}/list_title/`,method:"GET",params:{values:JSON.stringify(o)}},e,s)},async searchSelectOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){n&&(o.q=n);let c=a?`/app_flow/v1/papi/dm/assist_field/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${r}/search_title/`,d=`${t}/${r}/${n}/${JSON.stringify(s)}/${JSON.stringify(o)}`,u={};return l[d]&&"loading"==l[d]?(console.log("有缓存,返回"),await this.waitCacheMapData(d)):(!l[d]||(new Date).getTime()-l[d].last_time>6e4?(l[d]="loading",u=await i({url:c,method:a?"GET":"POST",data:o,can_custom_org_params:!0},e,s),l[d]={last_time:(new Date).getTime(),result:u}):(console.log("有缓存"),l[d].result&&(u=l[d].result)),u)},waitCacheMapData(e){return new Promise((t=>{let r=setInterval((()=>{l[e]&&"loading"!=l[e]&&l[e].result&&(clearInterval(r),t(l[e].result))}),100)}))},selectFromMulFormSearchOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),i({url:a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/search_title/`,method:"GET",params:o},e,s)},selectFromMulFormListTitleLoader(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a}){const o=`${t}/${r}`,l=c[o]||new n((async o=>{let n=a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/list_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/list_title/`;const c=await i({url:n,method:"GET",params:{values:JSON.stringify(o)}},e,s),l=_.get(c.data,"data.items",[]),d={};l.forEach((e=>{Object.keys(e.data).forEach((t=>{let r=e.data[t];d[t]={form_def_id:_.get(e,"definition.form.id"),form_title:_.get(e,"definition.form.name"),label:r}}))}));let u=[];return o.forEach((e=>{u.push(d[e])})),u}));return c[o]=l,l},selectFromMulFormListTitle(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return i({url:a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/list_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/list_title/`,method:"GET",params:{values:JSON.stringify(o)}},e,s)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),i({url:a?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${r}/search_title/`,method:"GET",params:o,can_custom_org_params:!0},e,s)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),i({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${r}/search_title/`,method:"GET",params:o},e,s)}}}},9795:function(e,t,r){function s(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),r=!1,s=0,a=e.length;s<a;s++)-1!=t.indexOf(e[s])&&(r=!0);return r}r.d(t,{Fr:function(){return s}}),r(6773),r(5360)},3282:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const s=r(4042),a=r(6144),o=r(6653),n=r(2079),i=["/properties"],c="http://json-schema.org/draft-07/schema";class l extends s.default{_addVocabularies(){super._addVocabularies(),a.default.forEach((e=>this.addVocabulary(e))),this.opts.discriminator&&this.addKeyword(o.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const e=this.opts.$data?this.$dataMetaSchema(n,i):n;this.addMetaSchema(e,c,!1),this.refs["http://json-schema.org/schema"]=c}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(c)?c:void 0)}}t.Ajv=l,e.exports=t=l,e.exports.Ajv=l,Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var d=r(2586);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return d.KeywordCxt}});var u=r(9029);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return u._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return u.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return u.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return u.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return u.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return u.CodeGen}});var f=r(3558);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return f.default}});var h=r(4551);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return h.default}})},1520:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class r{}t._CodeOrName=r,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class s extends r{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=s;class a extends r{constructor(e){super(),this._items="string"==typeof e?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const e=this._items[0];return""===e||'""'===e}get str(){var e;return null!==(e=this._str)&&void 0!==e?e:this._str=this._items.reduce(((e,t)=>`${e}${t}`),"")}get names(){var e;return null!==(e=this._names)&&void 0!==e?e:this._names=this._items.reduce(((e,t)=>(t instanceof s&&(e[t.str]=(e[t.str]||0)+1),e)),{})}}function o(e,...t){const r=[e[0]];let s=0;for(;s<t.length;)c(r,t[s]),r.push(e[++s]);return new a(r)}t._Code=a,t.nil=new a(""),t._=o;const n=new a("+");function i(e,...t){const r=[d(e[0])];let s=0;for(;s<t.length;)r.push(n),c(r,t[s]),r.push(n,d(e[++s]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===n){const r=l(e[t-1],e[t+1]);if(void 0!==r){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}(r),new a(r)}function c(e,t){var r;t instanceof a?e.push(...t._items):t instanceof s?e.push(t):e.push("number"==typeof(r=t)||"boolean"==typeof r||null===r?r:d(Array.isArray(r)?r.join(","):r))}function l(e,t){if('""'===t)return e;if('""'===e)return t;if("string"==typeof e){if(t instanceof s||'"'!==e[e.length-1])return;return"string"!=typeof t?`${e.slice(0,-1)}${t}"`:'"'===t[0]?e.slice(0,-1)+t.slice(1):void 0}return"string"!=typeof t||'"'!==t[0]||e instanceof s?void 0:`"${e}${t.slice(1)}`}function d(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=i,t.addCodeArg=c,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:i`${e}${t}`},t.stringify=function(e){return new a(d(e))},t.safeStringify=d,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new a(`.${e}`):o`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new a(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new a(e.toString())}},9029:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;const s=r(1520),a=r(7845);var o=r(1520);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return o._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return o.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return o.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return o.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return o.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return o.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return o.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return o.Name}});var n=r(7845);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return n.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return n.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return n.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return n.varKinds}}),t.operators={GT:new s._Code(">"),GTE:new s._Code(">="),LT:new s._Code("<"),LTE:new s._Code("<="),EQ:new s._Code("==="),NEQ:new s._Code("!=="),NOT:new s._Code("!"),OR:new s._Code("||"),AND:new s._Code("&&"),ADD:new s._Code("+")};class i{optimizeNodes(){return this}optimizeNames(e,t){return this}}class c extends i{constructor(e,t,r){super(),this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){const r=e?a.varKinds.var:this.varKind,s=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${s};`+t}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=C(this.rhs,e,t)),this}get names(){return this.rhs instanceof s._CodeOrName?this.rhs.names:{}}}class l extends i{constructor(e,t,r){super(),this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof s.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=C(this.rhs,e,t),this}get names(){return x(this.lhs instanceof s.Name?{}:{...this.lhs.names},this.rhs)}}class d extends l{constructor(e,t,r,s){super(e,r,s),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class u extends i{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class f extends i{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class h extends i{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class m extends i{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=C(this.code,e,t),this}get names(){return this.code instanceof s._CodeOrName?this.code.names:{}}}class p extends i{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce(((t,r)=>t+r.render(e)),"")}optimizeNodes(){const{nodes:e}=this;let t=e.length;for(;t--;){const r=e[t].optimizeNodes();Array.isArray(r)?e.splice(t,1,...r):r?e[t]=r:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){const{nodes:r}=this;let s=r.length;for(;s--;){const a=r[s];a.optimizeNames(e,t)||(O(e,a.names),r.splice(s,1))}return r.length>0?this:void 0}get names(){return this.nodes.reduce(((e,t)=>j(e,t.names)),{})}}class y extends p{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class g extends p{}class v extends y{}v.kind="else";class _ extends y{constructor(e,t){super(t),this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);return this.else&&(t+="else "+this.else.render(e)),t}optimizeNodes(){super.optimizeNodes();const e=this.condition;if(!0===e)return this.nodes;let t=this.else;if(t){const e=t.optimizeNodes();t=this.else=Array.isArray(e)?new v(e):e}return t?!1===e?t instanceof _?t:t.nodes:this.nodes.length?this:new _(T(e),t instanceof _?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var r;if(this.else=null===(r=this.else)||void 0===r?void 0:r.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=C(this.condition,e,t),this}get names(){const e=super.names;return x(e,this.condition),this.else&&j(e,this.else.names),e}}_.kind="if";class $ extends y{}$.kind="for";class w extends ${constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iteration=C(this.iteration,e,t),this}get names(){return j(super.names,this.iteration.names)}}class b extends ${constructor(e,t,r,s){super(),this.varKind=e,this.name=t,this.from=r,this.to=s}render(e){const t=e.es5?a.varKinds.var:this.varKind,{name:r,from:s,to:o}=this;return`for(${t} ${r}=${s}; ${r}<${o}; ${r}++)`+super.render(e)}get names(){const e=x(super.names,this.from);return x(e,this.to)}}class S extends ${constructor(e,t,r,s){super(),this.loop=e,this.varKind=t,this.name=r,this.iterable=s}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iterable=C(this.iterable,e,t),this}get names(){return j(super.names,this.iterable.names)}}class P extends y{constructor(e,t,r){super(),this.name=e,this.args=t,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}P.kind="func";class E extends p{render(e){return"return "+super.render(e)}}E.kind="return";class k extends y{render(e){let t="try"+super.render(e);return this.catch&&(t+=this.catch.render(e)),this.finally&&(t+=this.finally.render(e)),t}optimizeNodes(){var e,t;return super.optimizeNodes(),null===(e=this.catch)||void 0===e||e.optimizeNodes(),null===(t=this.finally)||void 0===t||t.optimizeNodes(),this}optimizeNames(e,t){var r,s;return super.optimizeNames(e,t),null===(r=this.catch)||void 0===r||r.optimizeNames(e,t),null===(s=this.finally)||void 0===s||s.optimizeNames(e,t),this}get names(){const e=super.names;return this.catch&&j(e,this.catch.names),this.finally&&j(e,this.finally.names),e}}class I extends y{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}I.kind="catch";class N extends y{render(e){return"finally"+super.render(e)}}function j(e,t){for(const r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function x(e,t){return t instanceof s._CodeOrName?j(e,t.names):e}function C(e,t,r){return e instanceof s.Name?o(e):(a=e)instanceof s._Code&&a._items.some((e=>e instanceof s.Name&&1===t[e.str]&&void 0!==r[e.str]))?new s._Code(e._items.reduce(((e,t)=>(t instanceof s.Name&&(t=o(t)),t instanceof s._Code?e.push(...t._items):e.push(t),e)),[])):e;var a;function o(e){const s=r[e.str];return void 0===s||1!==t[e.str]?e:(delete t[e.str],s)}}function O(e,t){for(const r in t)e[r]=(e[r]||0)-(t[r]||0)}function T(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:s._`!${M(e)}`}N.kind="finally",t.CodeGen=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new a.Scope({parent:e}),this._nodes=[new g]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){const r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,r,s){const a=this._scope.toName(t);return void 0!==r&&s&&(this._constants[a.str]=r),this._leafNode(new c(e,a,r)),a}const(e,t,r){return this._def(a.varKinds.const,e,t,r)}let(e,t,r){return this._def(a.varKinds.let,e,t,r)}var(e,t,r){return this._def(a.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new l(e,t,r))}add(e,r){return this._leafNode(new d(e,t.operators.ADD,r))}code(e){return"function"==typeof e?e():e!==s.nil&&this._leafNode(new m(e)),this}object(...e){const t=["{"];for(const[r,a]of e)t.length>1&&t.push(","),t.push(r),(r!==a||this.opts.es5)&&(t.push(":"),(0,s.addCodeArg)(t,a));return t.push("}"),new s._Code(t)}if(e,t,r){if(this._blockNode(new _(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new _(e))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(_,v)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new w(e),t)}forRange(e,t,r,s,o=(this.opts.es5?a.varKinds.var:a.varKinds.let)){const n=this._scope.toName(e);return this._for(new b(o,n,t,r),(()=>s(n)))}forOf(e,t,r,o=a.varKinds.const){const n=this._scope.toName(e);if(this.opts.es5){const e=t instanceof s.Name?t:this.var("_arr",t);return this.forRange("_i",0,s._`${e}.length`,(t=>{this.var(n,s._`${e}[${t}]`),r(n)}))}return this._for(new S("of",o,n,t),(()=>r(n)))}forIn(e,t,r,o=(this.opts.es5?a.varKinds.var:a.varKinds.const)){if(this.opts.ownProperties)return this.forOf(e,s._`Object.keys(${t})`,r);const n=this._scope.toName(e);return this._for(new S("in",o,n,t),(()=>r(n)))}endFor(){return this._endBlockNode($)}label(e){return this._leafNode(new u(e))}break(e){return this._leafNode(new f(e))}return(e){const t=new E;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(E)}try(e,t,r){if(!t&&!r)throw new Error('CodeGen: "try" without "catch" and "finally"');const s=new k;if(this._blockNode(s),this.code(e),t){const e=this.name("e");this._currNode=s.catch=new I(e),t(e)}return r&&(this._currNode=s.finally=new N,this.code(r)),this._endBlockNode(I,N)}throw(e){return this._leafNode(new h(e))}block(e,t){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(t),this}endBlock(e){const t=this._blockStarts.pop();if(void 0===t)throw new Error("CodeGen: not in self-balancing block");const r=this._nodes.length-t;if(r<0||void 0!==e&&r!==e)throw new Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=s.nil,r,a){return this._blockNode(new P(e,t,r)),a&&this.code(a).endFunc(),this}endFunc(){return this._endBlockNode(P)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){const r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){const t=this._currNode;if(!(t instanceof _))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){const e=this._nodes;return e[e.length-1]}set _currNode(e){const t=this._nodes;t[t.length-1]=e}},t.not=T;const D=A(t.operators.AND);t.and=function(...e){return e.reduce(D)};const R=A(t.operators.OR);function A(e){return(t,r)=>t===s.nil?r:r===s.nil?t:s._`${M(t)} ${e} ${M(r)}`}function M(e){return e instanceof s.Name?e:s._`(${e})`}t.or=function(...e){return e.reduce(R)}},7845:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;const s=r(1520);class a extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}var o;!function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"}(o||(t.UsedValueState=o={})),t.varKinds={const:new s.Name("const"),let:new s.Name("let"),var:new s.Name("var")};class n{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof s.Name?e:this.name(e)}name(e){return new s.Name(this._newName(e))}_newName(e){return`${e}${(this._names[e]||this._nameGroup(e)).index++}`}_nameGroup(e){var t,r;if((null===(r=null===(t=this._parent)||void 0===t?void 0:t._prefixes)||void 0===r?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=n;class i extends s.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=s._`.${new s.Name(t)}[${r}]`}}t.ValueScopeName=i;const c=s._`\n`;t.ValueScope=class extends n{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?c:s.nil}}get(){return this._scope}name(e){return new i(e,this._newName(e))}value(e,t){var r;if(void 0===t.ref)throw new Error("CodeGen: ref must be passed in value");const s=this.toName(e),{prefix:a}=s,o=null!==(r=t.key)&&void 0!==r?r:t.ref;let n=this._values[a];if(n){const e=n.get(o);if(e)return e}else n=this._values[a]=new Map;n.set(o,s);const i=this._scope[a]||(this._scope[a]=[]),c=i.length;return i[c]=t.ref,s.setValue(t,{property:a,itemIndex:c}),s}getValue(e,t){const r=this._values[e];if(r)return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,(t=>{if(void 0===t.scopePath)throw new Error(`CodeGen: name "${t}" has no value`);return s._`${e}${t.scopePath}`}))}scopeCode(e=this._values,t,r){return this._reduceValues(e,(e=>{if(void 0===e.value)throw new Error(`CodeGen: name "${e}" has no value`);return e.value.code}),t,r)}_reduceValues(e,r,n={},i){let c=s.nil;for(const l in e){const d=e[l];if(!d)continue;const u=n[l]=n[l]||new Map;d.forEach((e=>{if(u.has(e))return;u.set(e,o.Started);let n=r(e);if(n){const r=this.opts.es5?t.varKinds.var:t.varKinds.const;c=s._`${c}${r} ${e} = ${n};${this.opts._n}`}else{if(!(n=null==i?void 0:i(e)))throw new a(e);c=s._`${c}${n}${this.opts._n}`}u.set(e,o.Completed)}))}return c}}},8708:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;const s=r(9029),a=r(4227),o=r(2023);function n(e,t){const r=e.const("err",t);e.if(s._`${o.default.vErrors} === null`,(()=>e.assign(o.default.vErrors,s._`[${r}]`)),s._`${o.default.vErrors}.push(${r})`),e.code(s._`${o.default.errors}++`)}function i(e,t){const{gen:r,validateName:a,schemaEnv:o}=e;o.$async?r.throw(s._`new ${e.ValidationError}(${t})`):(r.assign(s._`${a}.errors`,t),r.return(!1))}t.keywordError={message:({keyword:e})=>s.str`must pass "${e}" keyword validation`},t.keyword$DataError={message:({keyword:e,schemaType:t})=>t?s.str`"${e}" keyword must be ${t} ($data)`:s.str`"${e}" keyword is invalid ($data)`},t.reportError=function(e,r=t.keywordError,a,o){const{it:c}=e,{gen:d,compositeRule:u,allErrors:f}=c,h=l(e,r,a);(null!=o?o:u||f)?n(d,h):i(c,s._`[${h}]`)},t.reportExtraError=function(e,r=t.keywordError,s){const{it:a}=e,{gen:c,compositeRule:d,allErrors:u}=a;n(c,l(e,r,s)),d||u||i(a,o.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(o.default.errors,t),e.if(s._`${o.default.vErrors} !== null`,(()=>e.if(t,(()=>e.assign(s._`${o.default.vErrors}.length`,t)),(()=>e.assign(o.default.vErrors,null)))))},t.extendErrors=function({gen:e,keyword:t,schemaValue:r,data:a,errsCount:n,it:i}){if(void 0===n)throw new Error("ajv implementation error");const c=e.name("err");e.forRange("i",n,o.default.errors,(n=>{e.const(c,s._`${o.default.vErrors}[${n}]`),e.if(s._`${c}.instancePath === undefined`,(()=>e.assign(s._`${c}.instancePath`,(0,s.strConcat)(o.default.instancePath,i.errorPath)))),e.assign(s._`${c}.schemaPath`,s.str`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign(s._`${c}.schema`,r),e.assign(s._`${c}.data`,a))}))};const c={keyword:new s.Name("keyword"),schemaPath:new s.Name("schemaPath"),params:new s.Name("params"),propertyName:new s.Name("propertyName"),message:new s.Name("message"),schema:new s.Name("schema"),parentSchema:new s.Name("parentSchema")};function l(e,t,r){const{createErrors:a}=e.it;return!1===a?s._`{}`:function(e,t,r={}){const{gen:a,it:n}=e,i=[d(n,r),u(e,r)];return function(e,{params:t,message:r},a){const{keyword:n,data:i,schemaValue:l,it:d}=e,{opts:u,propertyName:f,topSchemaRef:h,schemaPath:m}=d;a.push([c.keyword,n],[c.params,"function"==typeof t?t(e):t||s._`{}`]),u.messages&&a.push([c.message,"function"==typeof r?r(e):r]),u.verbose&&a.push([c.schema,l],[c.parentSchema,s._`${h}${m}`],[o.default.data,i]),f&&a.push([c.propertyName,f])}(e,t,i),a.object(...i)}(e,t,r)}function d({errorPath:e},{instancePath:t}){const r=t?s.str`${e}${(0,a.getErrorPath)(t,a.Type.Str)}`:e;return[o.default.instancePath,(0,s.strConcat)(o.default.instancePath,r)]}function u({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:s.str`${t}/${e}`;return r&&(n=s.str`${n}${(0,a.getErrorPath)(r,a.Type.Str)}`),[c.schemaPath,n]}},3835:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;const s=r(9029),a=r(3558),o=r(2023),n=r(6939),i=r(4227),c=r(2586);class l{constructor(e){var t;let r;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(r=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!==(t=e.baseId)&&void 0!==t?t:(0,n.normalizeId)(null==r?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null==r?void 0:r.$async,this.refs={}}}function d(e){const t=f.call(this,e);if(t)return t;const r=(0,n.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:i,lines:l}=this.opts.code,{ownProperties:d}=this.opts,u=new s.CodeGen(this.scope,{es5:i,lines:l,ownProperties:d});let h;e.$async&&(h=u.scopeValue("Error",{ref:a.default,code:s._`require("ajv/dist/runtime/validation_error").default`}));const m=u.scopeName("validate");e.validateName=m;const p={gen:u,allErrors:this.opts.allErrors,data:o.default.data,parentData:o.default.parentData,parentDataProperty:o.default.parentDataProperty,dataNames:[o.default.data],dataPathArr:[s.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:u.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,s.stringify)(e.schema)}:{ref:e.schema}),validateName:m,ValidationError:h,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:s.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:s._`""`,opts:this.opts,self:this};let y;try{this._compilations.add(e),(0,c.validateFunctionCode)(p),u.optimize(this.opts.code.optimize);const t=u.toString();y=`${u.scopeRefs(o.default.scope)}return ${t}`,this.opts.code.process&&(y=this.opts.code.process(y,e));const r=new Function(`${o.default.self}`,`${o.default.scope}`,y)(this,this.scope.get());if(this.scope.value(m,{ref:r}),r.errors=null,r.schema=e.schema,r.schemaEnv=e,e.$async&&(r.$async=!0),!0===this.opts.code.source&&(r.source={validateName:m,validateCode:t,scopeValues:u._values}),this.opts.unevaluated){const{props:e,items:t}=p;r.evaluated={props:e instanceof s.Name?void 0:e,items:t instanceof s.Name?void 0:t,dynamicProps:e instanceof s.Name,dynamicItems:t instanceof s.Name},r.source&&(r.source.evaluated=(0,s.stringify)(r.evaluated))}return e.validate=r,e}catch(t){throw delete e.validate,delete e.validateName,y&&this.logger.error("Error compiling schema, function code:",y),t}finally{this._compilations.delete(e)}}function u(e){return(0,n.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:d.call(this,e)}function f(e){for(const s of this._compilations)if(r=e,(t=s).schema===r.schema&&t.root===r.root&&t.baseId===r.baseId)return s;var t,r}function h(e,t){let r;for(;"string"==typeof(r=this.refs[t]);)t=r;return r||this.schemas[t]||m.call(this,e,t)}function m(e,t){const r=this.opts.uriResolver.parse(t),s=(0,n._getFullPath)(this.opts.uriResolver,r);let a=(0,n.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&s===a)return y.call(this,r,e);const o=(0,n.normalizeId)(s),i=this.refs[o]||this.schemas[o];if("string"==typeof i){const t=m.call(this,e,i);if("object"!=typeof(null==t?void 0:t.schema))return;return y.call(this,r,t)}if("object"==typeof(null==i?void 0:i.schema)){if(i.validate||d.call(this,i),o===(0,n.normalizeId)(t)){const{schema:t}=i,{schemaId:r}=this.opts,s=t[r];return s&&(a=(0,n.resolveUrl)(this.opts.uriResolver,a,s)),new l({schema:t,schemaId:r,root:e,baseId:a})}return y.call(this,r,i)}}t.SchemaEnv=l,t.compileSchema=d,t.resolveRef=function(e,t,r){var s;r=(0,n.resolveUrl)(this.opts.uriResolver,t,r);const a=e.refs[r];if(a)return a;let o=h.call(this,e,r);if(void 0===o){const a=null===(s=e.localRefs)||void 0===s?void 0:s[r],{schemaId:n}=this.opts;a&&(o=new l({schema:a,schemaId:n,root:e,baseId:t}))}return void 0!==o?e.refs[r]=u.call(this,o):void 0},t.getCompilingSchema=f,t.resolveSchema=m;const p=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function y(e,{baseId:t,schema:r,root:s}){var a;if("/"!==(null===(a=e.fragment)||void 0===a?void 0:a[0]))return;for(const s of e.fragment.slice(1).split("/")){if("boolean"==typeof r)return;const e=r[(0,i.unescapeFragment)(s)];if(void 0===e)return;const a="object"==typeof(r=e)&&r[this.opts.schemaId];!p.has(s)&&a&&(t=(0,n.resolveUrl)(this.opts.uriResolver,t,a))}let o;if("boolean"!=typeof r&&r.$ref&&!(0,i.schemaHasRulesButRef)(r,this.RULES)){const e=(0,n.resolveUrl)(this.opts.uriResolver,t,r.$ref);o=m.call(this,s,e)}const{schemaId:c}=this.opts;return o=o||new l({schema:r,schemaId:c,root:s,baseId:t}),o.schema!==o.root.schema?o:void 0}},2023:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={data:new s.Name("data"),valCxt:new s.Name("valCxt"),instancePath:new s.Name("instancePath"),parentData:new s.Name("parentData"),parentDataProperty:new s.Name("parentDataProperty"),rootData:new s.Name("rootData"),dynamicAnchors:new s.Name("dynamicAnchors"),vErrors:new s.Name("vErrors"),errors:new s.Name("errors"),this:new s.Name("this"),self:new s.Name("self"),scope:new s.Name("scope"),json:new s.Name("json"),jsonPos:new s.Name("jsonPos"),jsonLen:new s.Name("jsonLen"),jsonPart:new s.Name("jsonPart")};t.default=a},4551:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(6939);class a extends Error{constructor(e,t,r,a){super(a||`can't resolve reference ${r} from id ${t}`),this.missingRef=(0,s.resolveUrl)(e,t,r),this.missingSchema=(0,s.normalizeId)((0,s.getFullPath)(e,this.missingRef))}}t.default=a},6939:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;const s=r(4227),a=r(2017),o=r(7106),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e,t=!0){return"boolean"==typeof e||(!0===t?!c(e):!!t&&l(e)<=t)};const i=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function c(e){for(const t in e){if(i.has(t))return!0;const r=e[t];if(Array.isArray(r)&&r.some(c))return!0;if("object"==typeof r&&c(r))return!0}return!1}function l(e){let t=0;for(const r in e){if("$ref"===r)return 1/0;if(t++,!n.has(r)&&("object"==typeof e[r]&&(0,s.eachItem)(e[r],(e=>t+=l(e))),t===1/0))return 1/0}return t}function d(e,t="",r){!1!==r&&(t=h(t));const s=e.parse(t);return u(e,s)}function u(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=d,t._getFullPath=u;const f=/#\/?$/;function h(e){return e?e.replace(f,""):""}t.normalizeId=h,t.resolveUrl=function(e,t,r){return r=h(r),e.resolve(t,r)};const m=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};const{schemaId:r,uriResolver:s}=this.opts,n=h(e[r]||t),i={"":n},c=d(s,n,!1),l={},u=new Set;return o(e,{allKeys:!0},((e,t,s,a)=>{if(void 0===a)return;const o=c+t;let n=i[a];function d(t){const r=this.opts.uriResolver.resolve;if(t=h(n?r(n,t):t),u.has(t))throw p(t);u.add(t);let s=this.refs[t];return"string"==typeof s&&(s=this.refs[s]),"object"==typeof s?f(e,s.schema,t):t!==h(o)&&("#"===t[0]?(f(e,l[t],t),l[t]=e):this.refs[t]=o),t}function y(e){if("string"==typeof e){if(!m.test(e))throw new Error(`invalid anchor "${e}"`);d.call(this,`#${e}`)}}"string"==typeof e[r]&&(n=d.call(this,e[r])),y.call(this,e.$anchor),y.call(this,e.$dynamicAnchor),i[t]=n})),l;function f(e,t,r){if(void 0!==t&&!a(e,t))throw p(r)}function p(e){return new Error(`reference "${e}" resolves to more than one schema`)}}},396:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;const r=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&r.has(e)},t.getRules=function(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},4227:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;const s=r(9029),a=r(1520);function o(e,t=e.schema){const{opts:r,self:s}=e;if(!r.strictSchema)return;if("boolean"==typeof t)return;const a=s.RULES.keywords;for(const r in t)a[r]||m(e,`unknown keyword: "${r}"`)}function n(e,t){if("boolean"==typeof e)return!e;for(const r in e)if(t[r])return!0;return!1}function i(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function c(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function l({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:a}){return(o,n,i,c)=>{const l=void 0===i?n:i instanceof s.Name?(n instanceof s.Name?e(o,n,i):t(o,n,i),i):n instanceof s.Name?(t(o,i,n),n):r(n,i);return c!==s.Name||l instanceof s.Name?l:a(o,l)}}function d(e,t){if(!0===t)return e.var("props",!0);const r=e.var("props",s._`{}`);return void 0!==t&&u(e,r,t),r}function u(e,t,r){Object.keys(r).forEach((r=>e.assign(s._`${t}${(0,s.getProperty)(r)}`,!0)))}t.toHash=function(e){const t={};for(const r of e)t[r]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(o(e,t),!n(t,e.self.RULES.all))},t.checkUnknownRules=o,t.schemaHasRules=n,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(const r in e)if("$ref"!==r&&t.all[r])return!0;return!1},t.schemaRefOrVal=function({topSchemaRef:e,schemaPath:t},r,a,o){if(!o){if("number"==typeof r||"boolean"==typeof r)return r;if("string"==typeof r)return s._`${r}`}return s._`${e}${t}${(0,s.getProperty)(a)}`},t.unescapeFragment=function(e){return c(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(i(e))},t.escapeJsonPointer=i,t.unescapeJsonPointer=c,t.eachItem=function(e,t){if(Array.isArray(e))for(const r of e)t(r);else t(e)},t.mergeEvaluated={props:l({mergeNames:(e,t,r)=>e.if(s._`${r} !== true && ${t} !== undefined`,(()=>{e.if(s._`${t} === true`,(()=>e.assign(r,!0)),(()=>e.assign(r,s._`${r} || {}`).code(s._`Object.assign(${r}, ${t})`)))})),mergeToName:(e,t,r)=>e.if(s._`${r} !== true`,(()=>{!0===t?e.assign(r,!0):(e.assign(r,s._`${r} || {}`),u(e,r,t))})),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:d}),items:l({mergeNames:(e,t,r)=>e.if(s._`${r} !== true && ${t} !== undefined`,(()=>e.assign(r,s._`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`))),mergeToName:(e,t,r)=>e.if(s._`${r} !== true`,(()=>e.assign(r,!0===t||s._`${r} > ${t} ? ${r} : ${t}`))),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=d,t.setEvaluated=u;const f={};var h;function m(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,!0===r)throw new Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:f[t.code]||(f[t.code]=new a._Code(t.code))})},function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"}(h||(t.Type=h={})),t.getErrorPath=function(e,t,r){if(e instanceof s.Name){const a=t===h.Num;return r?a?s._`"[" + ${e} + "]"`:s._`"['" + ${e} + "']"`:a?s._`"/" + ${e}`:s._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,s.getProperty)(e).toString():"/"+i(e)},t.checkStrictMode=m},7887:function(e,t){function r(e,t){return t.rules.some((t=>s(e,t)))}function s(e,t){var r;return void 0!==e[t.keyword]||(null===(r=t.definition.implements)||void 0===r?void 0:r.some((t=>void 0!==e[t])))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function({schema:e,self:t},s){const a=t.RULES.types[s];return a&&!0!==a&&r(e,a)},t.shouldUseGroup=r,t.shouldUseRule=s},8727:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;const s=r(8708),a=r(9029),o=r(2023),n={message:"boolean schema is false"};function i(e,t){const{gen:r,data:a}=e,o={gen:r,keyword:"false schema",data:a,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,s.reportError)(o,n,void 0,t)}t.topBoolOrEmptySchema=function(e){const{gen:t,schema:r,validateName:s}=e;!1===r?i(e,!1):"object"==typeof r&&!0===r.$async?t.return(o.default.data):(t.assign(a._`${s}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){const{gen:r,schema:s}=e;!1===s?(r.var(t,!1),i(e)):r.var(t,!0)}},208:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;const s=r(396),a=r(7887),o=r(8708),n=r(9029),i=r(4227);var c;function l(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(s.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}!function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"}(c||(t.DataType=c={})),t.getSchemaTypes=function(e){const t=l(e.type);if(t.includes("null")){if(!1===e.nullable)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw new Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=l,t.coerceAndCheckDataType=function(e,t){const{gen:r,data:s,opts:o}=e,i=function(e,t){return t?e.filter((e=>d.has(e)||"array"===t&&"array"===e)):[]}(t,o.coerceTypes),l=t.length>0&&!(0===i.length&&1===t.length&&(0,a.schemaHasRulesForType)(e,t[0]));if(l){const a=f(t,s,o.strictNumbers,c.Wrong);r.if(a,(()=>{i.length?function(e,t,r){const{gen:s,data:a,opts:o}=e,i=s.let("dataType",n._`typeof ${a}`),c=s.let("coerced",n._`undefined`);"array"===o.coerceTypes&&s.if(n._`${i} == 'object' && Array.isArray(${a}) && ${a}.length == 1`,(()=>s.assign(a,n._`${a}[0]`).assign(i,n._`typeof ${a}`).if(f(t,a,o.strictNumbers),(()=>s.assign(c,a))))),s.if(n._`${c} !== undefined`);for(const e of r)(d.has(e)||"array"===e&&"array"===o.coerceTypes)&&l(e);function l(e){switch(e){case"string":return void s.elseIf(n._`${i} == "number" || ${i} == "boolean"`).assign(c,n._`"" + ${a}`).elseIf(n._`${a} === null`).assign(c,n._`""`);case"number":return void s.elseIf(n._`${i} == "boolean" || ${a} === null
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs"),require("@antv/g6")):"function"==typeof define&&define.amd?define(["lodash","qs","@antv/g6"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs"),require("@antv/g6")):e.bpm2=t(e.lodash,e.qs,e["@antv/g6"])}(self,(function(e,t,r){return function(){"use strict";var s={117:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2586),a=r(5765),o=r(4227),n=r(8660),i={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,parentSchema:i,data:c,it:l}=e;"all"===l.opts.removeAdditional&&void 0===i.additionalProperties&&n.default.code(new s.KeywordCxt(l,n.default,"additionalProperties"));const d=(0,a.allSchemaProperties)(r);for(const e of d)l.definedProperties.add(e);l.opts.unevaluated&&d.length&&!0!==l.props&&(l.props=o.mergeEvaluated.props(t,(0,o.toHash)(d),l.props));const u=d.filter((e=>!(0,o.alwaysValidSchema)(l,r[e])));if(0===u.length)return;const f=t.name("valid");for(const r of u)h(r)?m(r):(t.if((0,a.propertyInData)(t,c,r,l.opts.ownProperties)),m(r),l.allErrors||t.else().var(f,!0),t.endIf()),e.it.definedProperties.add(r),e.ok(f);function h(e){return l.opts.useDefaults&&!l.compositeRule&&void 0!==r[e].default}function m(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},f)}}};t.default=i},208:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;const s=r(396),a=r(7887),o=r(8708),n=r(9029),i=r(4227);var c;function l(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(s.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}!function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"}(c||(t.DataType=c={})),t.getSchemaTypes=function(e){const t=l(e.type);if(t.includes("null")){if(!1===e.nullable)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw new Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=l,t.coerceAndCheckDataType=function(e,t){const{gen:r,data:s,opts:o}=e,i=function(e,t){return t?e.filter((e=>d.has(e)||"array"===t&&"array"===e)):[]}(t,o.coerceTypes),l=t.length>0&&!(0===i.length&&1===t.length&&(0,a.schemaHasRulesForType)(e,t[0]));if(l){const a=f(t,s,o.strictNumbers,c.Wrong);r.if(a,(()=>{i.length?function(e,t,r){const{gen:s,data:a,opts:o}=e,i=s.let("dataType",n._`typeof ${a}`),c=s.let("coerced",n._`undefined`);"array"===o.coerceTypes&&s.if(n._`${i} == 'object' && Array.isArray(${a}) && ${a}.length == 1`,(()=>s.assign(a,n._`${a}[0]`).assign(i,n._`typeof ${a}`).if(f(t,a,o.strictNumbers),(()=>s.assign(c,a))))),s.if(n._`${c} !== undefined`);for(const e of r)(d.has(e)||"array"===e&&"array"===o.coerceTypes)&&l(e);function l(e){switch(e){case"string":return void s.elseIf(n._`${i} == "number" || ${i} == "boolean"`).assign(c,n._`"" + ${a}`).elseIf(n._`${a} === null`).assign(c,n._`""`);case"number":return void s.elseIf(n._`${i} == "boolean" || ${a} === null
2
2
  || (${i} == "string" && ${a} && ${a} == +${a})`).assign(c,n._`+${a}`);case"integer":return void s.elseIf(n._`${i} === "boolean" || ${a} === null
3
3
  || (${i} === "string" && ${a} && ${a} == +${a} && !(${a} % 1))`).assign(c,n._`+${a}`);case"boolean":return void s.elseIf(n._`${a} === "false" || ${a} === 0 || ${a} === null`).assign(c,!1).elseIf(n._`${a} === "true" || ${a} === 1`).assign(c,!0);case"null":return s.elseIf(n._`${a} === "" || ${a} === 0 || ${a} === false`),void s.assign(c,null);case"array":s.elseIf(n._`${i} === "string" || ${i} === "number"
4
- || ${i} === "boolean" || ${a} === null`).assign(c,n._`[${a}]`)}}s.else(),m(e),s.endIf(),s.if(n._`${c} !== undefined`,(()=>{s.assign(a,c),function({gen:e,parentData:t,parentDataProperty:r},s){e.if(n._`${t} !== undefined`,(()=>e.assign(n._`${t}[${r}]`,s)))}(e,c)}))}(e,t,i):m(e)}))}return l};const d=new Set(["string","number","integer","boolean","null"]);function u(e,t,r,s=c.Correct){const a=s===c.Correct?n.operators.EQ:n.operators.NEQ;let o;switch(e){case"null":return n._`${t} ${a} null`;case"array":o=n._`Array.isArray(${t})`;break;case"object":o=n._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":o=i(n._`!(${t} % 1) && !isNaN(${t})`);break;case"number":o=i();break;default:return n._`typeof ${t} ${a} ${e}`}return s===c.Correct?o:(0,n.not)(o);function i(e=n.nil){return(0,n.and)(n._`typeof ${t} == "number"`,e,r?n._`isFinite(${t})`:n.nil)}}function f(e,t,r,s){if(1===e.length)return u(e[0],t,r,s);let a;const o=(0,i.toHash)(e);if(o.array&&o.object){const e=n._`typeof ${t} != "object"`;a=o.null?e:n._`!${t} || ${e}`,delete o.null,delete o.array,delete o.object}else a=n.nil;o.number&&delete o.integer;for(const e in o)a=(0,n.and)(a,u(e,t,r,s));return a}t.checkDataType=u,t.checkDataTypes=f;const h={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>"string"==typeof e?n._`{type: ${e}}`:n._`{type: ${t}}`};function m(e){const t=function(e){const{gen:t,data:r,schema:s}=e,a=(0,i.schemaRefOrVal)(e,s,"type");return{gen:t,keyword:"type",data:r,schema:s.type,schemaCode:a,schemaValue:a,parentSchema:s,params:{},it:e}}(e);(0,o.reportError)(t,h)}t.reportTypeError=m},7870:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;const s=r(9029),a=r(4227);function o(e,t,r){const{gen:o,compositeRule:n,data:i,opts:c}=e;if(void 0===r)return;const l=s._`${i}${(0,s.getProperty)(t)}`;if(n)return void(0,a.checkStrictMode)(e,`default is ignored for: ${l}`);let d=s._`${l} === undefined`;"empty"===c.useDefaults&&(d=s._`${d} || ${l} === null || ${l} === ""`),o.if(d,s._`${l} = ${(0,s.stringify)(r)}`)}t.assignDefaults=function(e,t){const{properties:r,items:s}=e.schema;if("object"===t&&r)for(const t in r)o(e,t,r[t].default);else"array"===t&&Array.isArray(s)&&s.forEach(((t,r)=>o(e,r,t.default)))}},2586:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;const s=r(8727),a=r(208),o=r(7887),n=r(208),i=r(7870),c=r(3673),l=r(4495),d=r(9029),u=r(2023),f=r(6939),h=r(4227),m=r(8708);function p({gen:e,validateName:t,schema:r,schemaEnv:s,opts:a},o){a.code.es5?e.func(t,d._`${u.default.data}, ${u.default.valCxt}`,s.$async,(()=>{e.code(d._`"use strict"; ${y(r,a)}`),function(e,t){e.if(u.default.valCxt,(()=>{e.var(u.default.instancePath,d._`${u.default.valCxt}.${u.default.instancePath}`),e.var(u.default.parentData,d._`${u.default.valCxt}.${u.default.parentData}`),e.var(u.default.parentDataProperty,d._`${u.default.valCxt}.${u.default.parentDataProperty}`),e.var(u.default.rootData,d._`${u.default.valCxt}.${u.default.rootData}`),t.dynamicRef&&e.var(u.default.dynamicAnchors,d._`${u.default.valCxt}.${u.default.dynamicAnchors}`)}),(()=>{e.var(u.default.instancePath,d._`""`),e.var(u.default.parentData,d._`undefined`),e.var(u.default.parentDataProperty,d._`undefined`),e.var(u.default.rootData,u.default.data),t.dynamicRef&&e.var(u.default.dynamicAnchors,d._`{}`)}))}(e,a),e.code(o)})):e.func(t,d._`${u.default.data}, ${function(e){return d._`{${u.default.instancePath}="", ${u.default.parentData}, ${u.default.parentDataProperty}, ${u.default.rootData}=${u.default.data}${e.dynamicRef?d._`, ${u.default.dynamicAnchors}={}`:d.nil}}={}`}(a)}`,s.$async,(()=>e.code(y(r,a)).code(o)))}function y(e,t){const r="object"==typeof e&&e[t.schemaId];return r&&(t.code.source||t.code.process)?d._`/*# sourceURL=${r} */`:d.nil}function g({schema:e,self:t}){if("boolean"==typeof e)return!e;for(const r in e)if(t.RULES.all[r])return!0;return!1}function v(e){return"boolean"!=typeof e.schema}function _(e){(0,h.checkUnknownRules)(e),function(e){const{schema:t,errSchemaPath:r,opts:s,self:a}=e;t.$ref&&s.ignoreKeywordsWithRef&&(0,h.schemaHasRulesButRef)(t,a.RULES)&&a.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}(e)}function $(e,t){if(e.opts.jtd)return b(e,[],!1,t);const r=(0,a.getSchemaTypes)(e.schema);b(e,r,!(0,a.coerceAndCheckDataType)(e,r),t)}function w({gen:e,schemaEnv:t,schema:r,errSchemaPath:s,opts:a}){const o=r.$comment;if(!0===a.$comment)e.code(d._`${u.default.self}.logger.log(${o})`);else if("function"==typeof a.$comment){const r=d.str`${s}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(d._`${u.default.self}.opts.$comment(${o}, ${r}, ${a}.schema)`)}}function b(e,t,r,s){const{gen:a,schema:i,data:c,allErrors:l,opts:f,self:m}=e,{RULES:p}=m;function y(h){(0,o.shouldUseGroup)(i,h)&&(h.type?(a.if((0,n.checkDataType)(h.type,c,f.strictNumbers)),S(e,h),1===t.length&&t[0]===h.type&&r&&(a.else(),(0,n.reportTypeError)(e)),a.endIf()):S(e,h),l||a.if(d._`${u.default.errors} === ${s||0}`))}!i.$ref||!f.ignoreKeywordsWithRef&&(0,h.schemaHasRulesButRef)(i,p)?(f.jtd||function(e,t){!e.schemaEnv.meta&&e.opts.strictTypes&&(function(e,t){t.length&&(e.dataTypes.length?(t.forEach((t=>{P(e.dataTypes,t)||E(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)})),function(e,t){const r=[];for(const s of e.dataTypes)P(t,s)?r.push(s):t.includes("integer")&&"number"===s&&r.push("integer");e.dataTypes=r}(e,t)):e.dataTypes=t)}(e,t),e.opts.allowUnionTypes||function(e,t){t.length>1&&(2!==t.length||!t.includes("null"))&&E(e,"use allowUnionTypes to allow union type keyword")}(e,t),function(e,t){const r=e.self.RULES.all;for(const s in r){const a=r[s];if("object"==typeof a&&(0,o.shouldUseRule)(e.schema,a)){const{type:r}=a.definition;r.length&&!r.some((e=>{return s=e,(r=t).includes(s)||"number"===s&&r.includes("integer");var r,s}))&&E(e,`missing type "${r.join(",")}" for keyword "${s}"`)}}}(e,e.dataTypes))}(e,t),a.block((()=>{for(const e of p.rules)y(e);y(p.post)}))):a.block((()=>I(e,"$ref",p.all.$ref.definition)))}function S(e,t){const{gen:r,schema:s,opts:{useDefaults:a}}=e;a&&(0,i.assignDefaults)(e,t.type),r.block((()=>{for(const r of t.rules)(0,o.shouldUseRule)(s,r)&&I(e,r.keyword,r.definition,t.type)}))}function P(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function E(e,t){t+=` at "${e.schemaEnv.baseId+e.errSchemaPath}" (strictTypes)`,(0,h.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){v(e)&&(_(e),g(e))?function(e){const{schema:t,opts:r,gen:s}=e;p(e,(()=>{r.$comment&&t.$comment&&w(e),function(e){const{schema:t,opts:r}=e;void 0!==t.default&&r.useDefaults&&r.strictSchema&&(0,h.checkStrictMode)(e,"default is ignored in the schema root")}(e),s.let(u.default.vErrors,null),s.let(u.default.errors,0),r.unevaluated&&function(e){const{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",d._`${r}.evaluated`),t.if(d._`${e.evaluated}.dynamicProps`,(()=>t.assign(d._`${e.evaluated}.props`,d._`undefined`))),t.if(d._`${e.evaluated}.dynamicItems`,(()=>t.assign(d._`${e.evaluated}.items`,d._`undefined`)))}(e),$(e),function(e){const{gen:t,schemaEnv:r,validateName:s,ValidationError:a,opts:o}=e;r.$async?t.if(d._`${u.default.errors} === 0`,(()=>t.return(u.default.data)),(()=>t.throw(d._`new ${a}(${u.default.vErrors})`))):(t.assign(d._`${s}.errors`,u.default.vErrors),o.unevaluated&&function({gen:e,evaluated:t,props:r,items:s}){r instanceof d.Name&&e.assign(d._`${t}.props`,r),s instanceof d.Name&&e.assign(d._`${t}.items`,s)}(e),t.return(d._`${u.default.errors} === 0`))}(e)}))}(e):p(e,(()=>(0,s.topBoolOrEmptySchema)(e)))};class k{constructor(e,t,r){if((0,c.validateKeywordUsage)(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,h.schemaRefOrVal)(e,this.schema,r,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",x(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,c.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw new Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",u.default.errors))}result(e,t,r){this.failResult((0,d.not)(e),t,r)}failResult(e,t,r){this.gen.if(e),r?r():this.error(),t?(this.gen.else(),t(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,t){this.failResult((0,d.not)(e),void 0,t)}fail(e){if(void 0===e)return this.error(),void(this.allErrors||this.gen.if(!1));this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);const{schemaCode:t}=this;this.fail(d._`${t} !== undefined && (${(0,d.or)(this.invalid$data(),e)})`)}error(e,t,r){if(t)return this.setParams(t),this._error(e,r),void this.setParams({});this._error(e,r)}_error(e,t){(e?m.reportExtraError:m.reportError)(this,this.def.error,t)}$dataError(){(0,m.reportError)(this,this.def.$dataError||m.keyword$DataError)}reset(){if(void 0===this.errsCount)throw new Error('add "trackErrors" to keyword definition');(0,m.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,t){t?Object.assign(this.params,e):this.params=e}block$data(e,t,r=d.nil){this.gen.block((()=>{this.check$data(e,r),t()}))}check$data(e=d.nil,t=d.nil){if(!this.$data)return;const{gen:r,schemaCode:s,schemaType:a,def:o}=this;r.if((0,d.or)(d._`${s} === undefined`,t)),e!==d.nil&&r.assign(e,!0),(a.length||o.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),e!==d.nil&&r.assign(e,!1)),r.else()}invalid$data(){const{gen:e,schemaCode:t,schemaType:r,def:s,it:a}=this;return(0,d.or)(function(){if(r.length){if(!(t instanceof d.Name))throw new Error("ajv implementation error");const e=Array.isArray(r)?r:[r];return d._`${(0,n.checkDataTypes)(e,t,a.opts.strictNumbers,n.DataType.Wrong)}`}return d.nil}(),function(){if(s.validateSchema){const r=e.scopeValue("validate$data",{ref:s.validateSchema});return d._`!${r}(${t})`}return d.nil}())}subschema(e,t){const r=(0,l.getSubschema)(this.it,e);(0,l.extendSubschemaData)(r,this.it,e),(0,l.extendSubschemaMode)(r,e);const a={...this.it,...r,items:void 0,props:void 0};return function(e,t){v(e)&&(_(e),g(e))?function(e,t){const{schema:r,gen:s,opts:a}=e;a.$comment&&r.$comment&&w(e),function(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,f.resolveUrl)(e.opts.uriResolver,e.baseId,t))}(e),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}(e);const o=s.const("_errs",u.default.errors);$(e,o),s.var(t,d._`${o} === ${u.default.errors}`)}(e,t):(0,s.boolOrEmptySchema)(e,t)}(a,t),a}mergeEvaluated(e,t){const{it:r,gen:s}=this;r.opts.unevaluated&&(!0!==r.props&&void 0!==e.props&&(r.props=h.mergeEvaluated.props(s,e.props,r.props,t)),!0!==r.items&&void 0!==e.items&&(r.items=h.mergeEvaluated.items(s,e.items,r.items,t)))}mergeValidEvaluated(e,t){const{it:r,gen:s}=this;if(r.opts.unevaluated&&(!0!==r.props||!0!==r.items))return s.if(t,(()=>this.mergeEvaluated(e,d.Name))),!0}}function I(e,t,r,s){const a=new k(e,r,t);"code"in r?r.code(a,s):a.$data&&r.validate?(0,c.funcKeywordCode)(a,r):"macro"in r?(0,c.macroKeywordCode)(a,r):(r.compile||r.validate)&&(0,c.funcKeywordCode)(a,r)}t.KeywordCxt=k;const N=/^\/(?:[^~]|~0|~1)*$/,j=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function x(e,{dataLevel:t,dataNames:r,dataPathArr:s}){let a,o;if(""===e)return u.default.rootData;if("/"===e[0]){if(!N.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);a=e,o=u.default.rootData}else{const n=j.exec(e);if(!n)throw new Error(`Invalid JSON-pointer: ${e}`);const i=+n[1];if(a=n[2],"#"===a){if(i>=t)throw new Error(c("property/index",i));return s[t-i]}if(i>t)throw new Error(c("data",i));if(o=r[t-i],!a)return o}let n=o;const i=a.split("/");for(const e of i)e&&(o=d._`${o}${(0,d.getProperty)((0,h.unescapeJsonPointer)(e))}`,n=d._`${n} && ${o}`);return n;function c(e,r){return`Cannot access ${e} ${r} levels up, current level is ${t}`}}t.getData=x},3673:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;const s=r(9029),a=r(2023),o=r(5765),n=r(8708);function i(e){const{gen:t,data:r,it:a}=e;t.if(a.parentData,(()=>t.assign(r,s._`${a.parentData}[${a.parentDataProperty}]`)))}function c(e,t,r){if(void 0===r)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof r?{ref:r}:{ref:r,code:(0,s.stringify)(r)})}t.macroKeywordCode=function(e,t){const{gen:r,keyword:a,schema:o,parentSchema:n,it:i}=e,l=t.macro.call(i.self,o,n,i),d=c(r,a,l);!1!==i.opts.validateSchema&&i.self.validateSchema(l,!0);const u=r.name("valid");e.subschema({schema:l,schemaPath:s.nil,errSchemaPath:`${i.errSchemaPath}/${a}`,topSchemaRef:d,compositeRule:!0},u),e.pass(u,(()=>e.error(!0)))},t.funcKeywordCode=function(e,t){var r;const{gen:l,keyword:d,schema:u,parentSchema:f,$data:h,it:m}=e;!function({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}(m,t);const p=!h&&t.compile?t.compile.call(m.self,u,f,m):t.validate,y=c(l,d,p),g=l.let("valid");function v(r=(t.async?s._`await `:s.nil)){const n=m.opts.passContext?a.default.this:a.default.self,i=!("compile"in t&&!h||!1===t.schema);l.assign(g,s._`${r}${(0,o.callValidateCode)(e,y,n,i)}`,t.modifying)}function _(e){var r;l.if((0,s.not)(null!==(r=t.valid)&&void 0!==r?r:g),e)}e.block$data(g,(function(){if(!1===t.errors)v(),t.modifying&&i(e),_((()=>e.error()));else{const r=t.async?function(){const e=l.let("ruleErrs",null);return l.try((()=>v(s._`await `)),(t=>l.assign(g,!1).if(s._`${t} instanceof ${m.ValidationError}`,(()=>l.assign(e,s._`${t}.errors`)),(()=>l.throw(t))))),e}():function(){const e=s._`${y}.errors`;return l.assign(e,null),v(s.nil),e}();t.modifying&&i(e),_((()=>function(e,t){const{gen:r}=e;r.if(s._`Array.isArray(${t})`,(()=>{r.assign(a.default.vErrors,s._`${a.default.vErrors} === null ? ${t} : ${a.default.vErrors}.concat(${t})`).assign(a.default.errors,s._`${a.default.vErrors}.length`),(0,n.extendErrors)(e)}),(()=>e.error()))}(e,r)))}})),e.ok(null!==(r=t.valid)&&void 0!==r?r:g)},t.validSchemaType=function(e,t,r=!1){return!t.length||t.some((t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||r&&void 0===e))},t.validateKeywordUsage=function({schema:e,opts:t,self:r,errSchemaPath:s},a,o){if(Array.isArray(a.keyword)?!a.keyword.includes(o):a.keyword!==o)throw new Error("ajv implementation error");const n=a.dependencies;if(null==n?void 0:n.some((t=>!Object.prototype.hasOwnProperty.call(e,t))))throw new Error(`parent schema must have dependencies of ${o}: ${n.join(",")}`);if(a.validateSchema&&!a.validateSchema(e[o])){const e=`keyword "${o}" value is invalid at path "${s}": `+r.errorsText(a.validateSchema.errors);if("log"!==t.validateSchema)throw new Error(e);r.logger.error(e)}}},4495:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;const s=r(9029),a=r(4227);t.getSubschema=function(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:c}){if(void 0!==t&&void 0!==o)throw new Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==t){const o=e.schema[t];return void 0===r?{schema:o,schemaPath:s._`${e.schemaPath}${(0,s.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:o[r],schemaPath:s._`${e.schemaPath}${(0,s.getProperty)(t)}${(0,s.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,a.escapeFragment)(r)}`}}if(void 0!==o){if(void 0===n||void 0===i||void 0===c)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:c,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:c}){if(void 0!==n&&void 0!==r)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:l}=t;if(void 0!==r){const{errorPath:n,dataPathArr:i,opts:c}=t;d(l.let("data",s._`${t.data}${(0,s.getProperty)(r)}`,!0)),e.errorPath=s.str`${n}${(0,a.getErrorPath)(r,o,c.jsPropertySyntax)}`,e.parentDataProperty=s._`${r}`,e.dataPathArr=[...i,e.parentDataProperty]}function d(r){e.data=r,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,r]}void 0!==n&&(d(n instanceof s.Name?n:l.let("data",n,!0)),void 0!==c&&(e.propertyName=c)),i&&(e.dataTypes=i)},t.extendSubschemaMode=function(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:s,createErrors:a,allErrors:o}){void 0!==s&&(e.compositeRule=s),void 0!==a&&(e.createErrors=a),void 0!==o&&(e.allErrors=o),e.jtdDiscriminator=t,e.jtdMetadata=r}},4042:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var s=r(2586);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return s.KeywordCxt}});var a=r(9029);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return a._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return a.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return a.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return a.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return a.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return a.CodeGen}});const o=r(3558),n=r(4551),i=r(396),c=r(3835),l=r(9029),d=r(6939),u=r(208),f=r(4227),h=r(3837),m=r(5944),p=(e,t)=>new RegExp(e,t);p.code="new RegExp";const y=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};function $(e){var t,r,s,a,o,n,i,c,l,d,u,f,h,y,g,v,_,$,w,b,S,P,E,k,I;const N=e.strict,j=null===(t=e.code)||void 0===t?void 0:t.optimize,x=!0===j||void 0===j?1:j||0,C=null!==(s=null===(r=e.code)||void 0===r?void 0:r.regExp)&&void 0!==s?s:p,O=null!==(a=e.uriResolver)&&void 0!==a?a:m.default;return{strictSchema:null===(n=null!==(o=e.strictSchema)&&void 0!==o?o:N)||void 0===n||n,strictNumbers:null===(c=null!==(i=e.strictNumbers)&&void 0!==i?i:N)||void 0===c||c,strictTypes:null!==(d=null!==(l=e.strictTypes)&&void 0!==l?l:N)&&void 0!==d?d:"log",strictTuples:null!==(f=null!==(u=e.strictTuples)&&void 0!==u?u:N)&&void 0!==f?f:"log",strictRequired:null!==(y=null!==(h=e.strictRequired)&&void 0!==h?h:N)&&void 0!==y&&y,code:e.code?{...e.code,optimize:x,regExp:C}:{optimize:x,regExp:C},loopRequired:null!==(g=e.loopRequired)&&void 0!==g?g:200,loopEnum:null!==(v=e.loopEnum)&&void 0!==v?v:200,meta:null===(_=e.meta)||void 0===_||_,messages:null===($=e.messages)||void 0===$||$,inlineRefs:null===(w=e.inlineRefs)||void 0===w||w,schemaId:null!==(b=e.schemaId)&&void 0!==b?b:"$id",addUsedSchema:null===(S=e.addUsedSchema)||void 0===S||S,validateSchema:null===(P=e.validateSchema)||void 0===P||P,validateFormats:null===(E=e.validateFormats)||void 0===E||E,unicodeRegExp:null===(k=e.unicodeRegExp)||void 0===k||k,int32range:null===(I=e.int32range)||void 0===I||I,uriResolver:O}}class w{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...$(e)};const{es5:t,lines:r}=this.opts.code;this.scope=new l.ValueScope({scope:{},prefixes:g,es5:t,lines:r}),this.logger=function(e){if(!1===e)return N;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}(e.logger);const s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,i.getRules)(),b.call(this,v,e,"NOT SUPPORTED"),b.call(this,_,e,"DEPRECATED","warn"),this._metaOpts=I.call(this),e.formats&&E.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&k.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),P.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:e,meta:t,schemaId:r}=this.opts;let s=h;"id"===r&&(s={...h},s.id=s.$id,delete s.$id),t&&e&&this.addMetaSchema(s,s[r],!1)}defaultMeta(){const{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let r;if("string"==typeof e){if(r=this.getSchema(e),!r)throw new Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);const s=r(t);return"$async"in r||(this.errors=r.errors),s}compile(e,t){const r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw new Error("options.loadSchema should be a function");const{loadSchema:r}=this.opts;return s.call(this,e,t);async function s(e,t){await a.call(this,e.$schema);const r=this._addSchema(e,t);return r.validate||o.call(this,r)}async function a(e){e&&!this.getSchema(e)&&await s.call(this,{$ref:e},!0)}async function o(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof n.default))throw t;return i.call(this,t),await c.call(this,t.missingSchema),o.call(this,e)}}function i({missingSchema:e,missingRef:t}){if(this.refs[e])throw new Error(`AnySchema ${e} is loaded but ${t} cannot be resolved`)}async function c(e){const r=await l.call(this,e);this.refs[e]||await a.call(this,r.$schema),this.refs[e]||this.addSchema(r,e,t)}async function l(e){const t=this._loading[e];if(t)return t;try{return await(this._loading[e]=r(e))}finally{delete this._loading[e]}}}addSchema(e,t,r,s=this.opts.validateSchema){if(Array.isArray(e)){for(const t of e)this.addSchema(t,void 0,r,s);return this}let a;if("object"==typeof e){const{schemaId:t}=this.opts;if(a=e[t],void 0!==a&&"string"!=typeof a)throw new Error(`schema ${t} must be string`)}return t=(0,d.normalizeId)(t||a),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,s,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){if("boolean"==typeof e)return!0;let r;if(r=e.$schema,void 0!==r&&"string"!=typeof r)throw new Error("$schema must be a string");if(r=r||this.opts.defaultMeta||this.defaultMeta(),!r)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const s=this.validate(r,e);if(!s&&t){const e="schema is invalid: "+this.errorsText();if("log"!==this.opts.validateSchema)throw new Error(e);this.logger.error(e)}return s}getSchema(e){let t;for(;"string"==typeof(t=S.call(this,e));)e=t;if(void 0===t){const{schemaId:r}=this.opts,s=new c.SchemaEnv({schema:{},schemaId:r});if(t=c.resolveSchema.call(this,s,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const t=S.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{const t=e;this._cache.delete(t);let r=e[this.opts.schemaId];return r&&(r=(0,d.normalizeId)(r),delete this.schemas[r],delete this.refs[r]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(const t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if("string"==typeof e)r=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r);else{if("object"!=typeof e||void 0!==t)throw new Error("invalid addKeywords parameters");if(r=(t=e).keyword,Array.isArray(r)&&!r.length)throw new Error("addKeywords: keyword must be string or non-empty array")}if(x.call(this,r,t),!t)return(0,f.eachItem)(r,(e=>C.call(this,e))),this;T.call(this,t);const s={...t,type:(0,u.getJSONTypes)(t.type),schemaType:(0,u.getJSONTypes)(t.schemaType)};return(0,f.eachItem)(r,0===s.type.length?e=>C.call(this,e,s):e=>s.type.forEach((t=>C.call(this,e,s,t)))),this}getKeyword(e){const t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){const{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(const r of t.rules){const t=r.rules.findIndex((t=>t.keyword===e));t>=0&&r.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){return e&&0!==e.length?e.map((e=>`${r}${e.instancePath} ${e.message}`)).reduce(((e,r)=>e+t+r)):"No errors"}$dataMetaSchema(e,t){const r=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(const s of t){const t=s.split("/").slice(1);let a=e;for(const e of t)a=a[e];for(const e in r){const t=r[e];if("object"!=typeof t)continue;const{$data:s}=t.definition,o=a[e];s&&o&&(a[e]=R(o))}}return e}_removeAllSchemas(e,t){for(const r in e){const s=e[r];t&&!t.test(r)||("string"==typeof s?delete e[r]:s&&!s.meta&&(this._cache.delete(s.schema),delete e[r]))}}_addSchema(e,t,r,s=this.opts.validateSchema,a=this.opts.addUsedSchema){let o;const{schemaId:n}=this.opts;if("object"==typeof e)o=e[n];else{if(this.opts.jtd)throw new Error("schema must be object");if("boolean"!=typeof e)throw new Error("schema must be object or boolean")}let i=this._cache.get(e);if(void 0!==i)return i;r=(0,d.normalizeId)(o||r);const l=d.getSchemaRefs.call(this,e,r);return i=new c.SchemaEnv({schema:e,schemaId:n,meta:t,baseId:r,localRefs:l}),this._cache.set(i.schema,i),a&&!r.startsWith("#")&&(r&&this._checkUnique(r),this.refs[r]=i),s&&this.validateSchema(e,!0),i}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):c.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){const t=this.opts;this.opts=this._metaOpts;try{c.compileSchema.call(this,e)}finally{this.opts=t}}}function b(e,t,r,s="error"){for(const a in e){const o=a;o in t&&this.logger[s](`${r}: option ${a}. ${e[o]}`)}}function S(e){return e=(0,d.normalizeId)(e),this.schemas[e]||this.refs[e]}function P(){const e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(const t in e)this.addSchema(e[t],t)}function E(){for(const e in this.opts.formats){const t=this.opts.formats[e];t&&this.addFormat(e,t)}}function k(e){if(Array.isArray(e))this.addVocabulary(e);else{this.logger.warn("keywords option as map is deprecated, pass array");for(const t in e){const r=e[t];r.keyword||(r.keyword=t),this.addKeyword(r)}}}function I(){const e={...this.opts};for(const t of y)delete e[t];return e}w.ValidationError=o.default,w.MissingRefError=n.default,t.default=w;const N={log(){},warn(){},error(){}},j=/^[a-z_$][a-z0-9_$:-]*$/i;function x(e,t){const{RULES:r}=this;if((0,f.eachItem)(e,(e=>{if(r.keywords[e])throw new Error(`Keyword ${e} is already defined`);if(!j.test(e))throw new Error(`Keyword ${e} has invalid name`)})),t&&t.$data&&!("code"in t)&&!("validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function C(e,t,r){var s;const a=null==t?void 0:t.post;if(r&&a)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:o}=this;let n=a?o.post:o.rules.find((({type:e})=>e===r));if(n||(n={type:r,rules:[]},o.rules.push(n)),o.keywords[e]=!0,!t)return;const i={keyword:e,definition:{...t,type:(0,u.getJSONTypes)(t.type),schemaType:(0,u.getJSONTypes)(t.schemaType)}};t.before?O.call(this,n,i,t.before):n.rules.push(i),o.all[e]=i,null===(s=t.implements)||void 0===s||s.forEach((e=>this.addKeyword(e)))}function O(e,t,r){const s=e.rules.findIndex((e=>e.keyword===r));s>=0?e.rules.splice(s,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function T(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=R(t)),e.validateSchema=this.compile(t,!0))}const D={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function R(e){return{anyOf:[e,D]}}},6250:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2017);s.code='require("ajv/dist/runtime/equal").default',t.default=s},3853:function(e,t){function r(e){const t=e.length;let r,s=0,a=0;for(;a<t;)s++,r=e.charCodeAt(a++),r>=55296&&r<=56319&&a<t&&(r=e.charCodeAt(a),56320==(64512&r)&&a++);return s}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.code='require("ajv/dist/runtime/ucs2length").default'},5944:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(8343);s.code='require("ajv/dist/runtime/uri").default',t.default=s},3558:function(e,t){Object.defineProperty(t,"__esModule",{value:!0});class r extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}t.default=r},5457:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;const s=r(9029),a=r(4227),o={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:e}})=>s.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>s._`{limit: ${e}}`},code(e){const{parentSchema:t,it:r}=e,{items:s}=t;Array.isArray(s)?n(e,s):(0,a.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas')}};function n(e,t){const{gen:r,schema:o,data:n,keyword:i,it:c}=e;c.items=!0;const l=r.const("len",s._`${n}.length`);if(!1===o)e.setParams({len:t.length}),e.pass(s._`${l} <= ${t.length}`);else if("object"==typeof o&&!(0,a.alwaysValidSchema)(c,o)){const o=r.var("valid",s._`${l} <= ${t.length}`);r.if((0,s.not)(o),(()=>function(o){r.forRange("i",t.length,l,(t=>{e.subschema({keyword:i,dataProp:t,dataPropType:a.Type.Num},o),c.allErrors||r.if((0,s.not)(o),(()=>r.break()))}))}(o))),e.ok(o)}}t.validateAdditionalItems=n,t.default=o},8660:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(2023),n=r(4227),i={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:e})=>a._`{additionalProperty: ${e.additionalProperty}}`},code(e){const{gen:t,schema:r,parentSchema:i,data:c,errsCount:l,it:d}=e;if(!l)throw new Error("ajv implementation error");const{allErrors:u,opts:f}=d;if(d.props=!0,"all"!==f.removeAdditional&&(0,n.alwaysValidSchema)(d,r))return;const h=(0,s.allSchemaProperties)(i.properties),m=(0,s.allSchemaProperties)(i.patternProperties);function p(e){t.code(a._`delete ${c}[${e}]`)}function y(s){if("all"===f.removeAdditional||f.removeAdditional&&!1===r)p(s);else{if(!1===r)return e.setParams({additionalProperty:s}),e.error(),void(u||t.break());if("object"==typeof r&&!(0,n.alwaysValidSchema)(d,r)){const r=t.name("valid");"failing"===f.removeAdditional?(g(s,r,!1),t.if((0,a.not)(r),(()=>{e.reset(),p(s)}))):(g(s,r),u||t.if((0,a.not)(r),(()=>t.break())))}}}function g(t,r,s){const a={keyword:"additionalProperties",dataProp:t,dataPropType:n.Type.Str};!1===s&&Object.assign(a,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(a,r)}t.forIn("key",c,(r=>{h.length||m.length?t.if(function(r){let o;if(h.length>8){const e=(0,n.schemaRefOrVal)(d,i.properties,"properties");o=(0,s.isOwnProperty)(t,e,r)}else o=h.length?(0,a.or)(...h.map((e=>a._`${r} === ${e}`))):a.nil;return m.length&&(o=(0,a.or)(o,...m.map((t=>a._`${(0,s.usePattern)(e,t)}.test(${r})`)))),(0,a.not)(o)}(r),(()=>y(r))):y(r)})),e.ok(a._`${l} === ${o.default.errors}`)}};t.default=i},5844:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:r,it:a}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");const o=t.name("valid");r.forEach(((t,r)=>{if((0,s.alwaysValidSchema)(a,t))return;const n=e.subschema({keyword:"allOf",schemaProp:r},o);e.ok(o),e.mergeEvaluated(n)}))}};t.default=a},6505:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:r(5765).validateUnion,error:{message:"must match a schema in anyOf"}};t.default=s},2661:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:e,max:t}})=>void 0===t?s.str`must contain at least ${e} valid item(s)`:s.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>void 0===t?s._`{minContains: ${e}}`:s._`{minContains: ${e}, maxContains: ${t}}`},code(e){const{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;let c,l;const{minContains:d,maxContains:u}=o;i.opts.next?(c=void 0===d?1:d,l=u):c=1;const f=t.const("len",s._`${n}.length`);if(e.setParams({min:c,max:l}),void 0===l&&0===c)return void(0,a.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==l&&c>l)return(0,a.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),void e.fail();if((0,a.alwaysValidSchema)(i,r)){let t=s._`${f} >= ${c}`;return void 0!==l&&(t=s._`${t} && ${f} <= ${l}`),void e.pass(t)}i.items=!0;const h=t.name("valid");function m(){const e=t.name("_valid"),r=t.let("count",0);p(e,(()=>t.if(e,(()=>function(e){t.code(s._`${e}++`),void 0===l?t.if(s._`${e} >= ${c}`,(()=>t.assign(h,!0).break())):(t.if(s._`${e} > ${l}`,(()=>t.assign(h,!1).break())),1===c?t.assign(h,!0):t.if(s._`${e} >= ${c}`,(()=>t.assign(h,!0))))}(r)))))}function p(r,s){t.forRange("i",0,f,(t=>{e.subschema({keyword:"contains",dataProp:t,dataPropType:a.Type.Num,compositeRule:!0},r),s()}))}void 0===l&&1===c?p(h,(()=>t.if(h,(()=>t.break())))):0===c?(t.let(h,!0),void 0!==l&&t.if(s._`${n}.length > 0`,m)):(t.let(h,!1),m()),e.result(h,(()=>e.reset()))}};t.default=o},3025:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;const s=r(9029),a=r(4227),o=r(5765);t.error={message:({params:{property:e,depsCount:t,deps:r}})=>{const a=1===t?"property":"properties";return s.str`must have ${a} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:a}})=>s._`{property: ${e},
4
+ || ${i} === "boolean" || ${a} === null`).assign(c,n._`[${a}]`)}}s.else(),m(e),s.endIf(),s.if(n._`${c} !== undefined`,(()=>{s.assign(a,c),function({gen:e,parentData:t,parentDataProperty:r},s){e.if(n._`${t} !== undefined`,(()=>e.assign(n._`${t}[${r}]`,s)))}(e,c)}))}(e,t,i):m(e)}))}return l};const d=new Set(["string","number","integer","boolean","null"]);function u(e,t,r,s=c.Correct){const a=s===c.Correct?n.operators.EQ:n.operators.NEQ;let o;switch(e){case"null":return n._`${t} ${a} null`;case"array":o=n._`Array.isArray(${t})`;break;case"object":o=n._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":o=i(n._`!(${t} % 1) && !isNaN(${t})`);break;case"number":o=i();break;default:return n._`typeof ${t} ${a} ${e}`}return s===c.Correct?o:(0,n.not)(o);function i(e=n.nil){return(0,n.and)(n._`typeof ${t} == "number"`,e,r?n._`isFinite(${t})`:n.nil)}}function f(e,t,r,s){if(1===e.length)return u(e[0],t,r,s);let a;const o=(0,i.toHash)(e);if(o.array&&o.object){const e=n._`typeof ${t} != "object"`;a=o.null?e:n._`!${t} || ${e}`,delete o.null,delete o.array,delete o.object}else a=n.nil;o.number&&delete o.integer;for(const e in o)a=(0,n.and)(a,u(e,t,r,s));return a}t.checkDataType=u,t.checkDataTypes=f;const h={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>"string"==typeof e?n._`{type: ${e}}`:n._`{type: ${t}}`};function m(e){const t=function(e){const{gen:t,data:r,schema:s}=e,a=(0,i.schemaRefOrVal)(e,s,"type");return{gen:t,keyword:"type",data:r,schema:s.type,schemaCode:a,schemaValue:a,parentSchema:s,params:{},it:e}}(e);(0,o.reportError)(t,h)}t.reportTypeError=m},343:function(e){const t=/^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu,r=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function s(e){return"boolean"==typeof e.secure?e.secure:"wss"===String(e.scheme).toLowerCase()}function a(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function o(e){const t="https"===String(e.scheme).toLowerCase();return e.port!==(t?443:80)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}const n={scheme:"http",domainHost:!0,parse:a,serialize:o},i={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=s(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if(e.port!==(s(e)?443:80)&&""!==e.port||(e.port=void 0),"boolean"==typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,r]=e.resourceName.split("?");e.path=t&&"/"!==t?t:void 0,e.query=r,e.resourceName=void 0}return e.fragment=void 0,e}},c={http:n,https:{scheme:"https",domainHost:n.domainHost,parse:a,serialize:o},ws:i,wss:{scheme:"wss",domainHost:i.domainHost,parse:i.parse,serialize:i.serialize},urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;const s=e.path.match(r);if(s){const r=t.scheme||e.scheme||"urn";e.nid=s[1].toLowerCase(),e.nss=s[2];const a=`${r}:${t.nid||e.nid}`,o=c[a];e.path=void 0,o&&(e=o.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){const r=t.scheme||e.scheme||"urn",s=e.nid.toLowerCase(),a=`${r}:${t.nid||s}`,o=c[a];o&&(e=o.serialize(e,t));const n=e,i=e.nss;return n.path=`${s||t.nid}:${i}`,t.skipEscape=!0,n},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,r){const s=e;return s.uuid=s.nss,s.nss=void 0,r.tolerant||s.uuid&&t.test(s.uuid)||(s.error=s.error||"UUID is not valid."),s},serialize:function(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t},skipNormalize:!0}};e.exports=c},396:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;const r=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&r.has(e)},t.getRules=function(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},422:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>a.str`must match pattern "${e}"`,params:({schemaCode:e})=>a._`{pattern: ${e}}`},code(e){const{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,c=i.opts.unicodeRegExp?"u":"",l=r?a._`(new RegExp(${n}, ${c}))`:(0,s.usePattern)(e,o);e.fail$data(a._`!${l}.test(${t})`)}};t.default=o},494:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;const s=r(9029),a=r(4227),o=r(5765),n={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:r}=e;if(Array.isArray(t))return i(e,"additionalItems",t);r.items=!0,(0,a.alwaysValidSchema)(r,t)||e.ok((0,o.validateArray)(e))}};function i(e,t,r=e.schema){const{gen:o,parentSchema:n,data:i,keyword:c,it:l}=e;!function(e){const{opts:s,errSchemaPath:o}=l,n=r.length,i=n===e.minItems&&(n===e.maxItems||!1===e[t]);if(s.strictTuples&&!i){const e=`"${c}" is ${n}-tuple, but minItems or maxItems/${t} are not specified or different at path "${o}"`;(0,a.checkStrictMode)(l,e,s.strictTuples)}}(n),l.opts.unevaluated&&r.length&&!0!==l.items&&(l.items=a.mergeEvaluated.items(o,r.length,l.items));const d=o.name("valid"),u=o.const("len",s._`${i}.length`);r.forEach(((t,r)=>{(0,a.alwaysValidSchema)(l,t)||(o.if(s._`${u} > ${r}`,(()=>e.subschema({keyword:c,schemaProp:r,dataProp:r},d))),e.ok(d))}))}t.validateTuple=i,t.default=n},555:function(e,t,r){r.d(t,{A:function(){return l}});var s=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"search-board"},[r("el-form",{ref:"form",attrs:{"label-width":"150px",inline:!1}},[e._l(e.pElements,(function(t){return r("el-form-item",{key:t.id,attrs:{label:t.name}},[r("bpm-field",{attrs:{type:t.type,"field-conf":t,"form-name":e.formDefId,"form-def-id":e.formDefId,orgInfo:e.orgInfo,mode:"edit","ui-type":"search"},model:{value:e.formData[t.id],callback:function(r){e.$set(e.formData,t.id,r)},expression:"formData[searchField.id]"}})],1)})),e._v(" "),e._l(e.gridElements,(function(t){return[r("el-form-item",{directives:[{name:"show",rawName:"v-show",value:e.showAllSearchItem||e.index<e.showDefaultCount,expression:"showAllSearchItem || index < showDefaultCount"}],key:t.id,attrs:{label:t.name}},[r("bpm-field",{attrs:{type:t.type,"field-conf":t,"form-name":e.formDefId,"form-def-id":e.formDefId,orgInfo:e.orgInfo,mode:"edit","ui-type":"search"},model:{value:e.formData[t.id],callback:function(r){e.$set(e.formData,t.id,r)},expression:"formData[searchField.id]"}})],1)]}))],2),e._v(" "),e._t("default")],2)};s._withStripped=!0;var a=r(4419),o=r(3282);const n=new(r.n(o)())({useDefaults:!0,coerceTypes:!0,allErrors:!0,jsonPointers:!0,errorDataPath:!0});var i={name:"BpmFieldsFilter",props:{searchSchema:{type:Object,default(){return{elements:[]}}},verifySchema:{type:Object,default(){return{}}},orgInfo:{type:Object,default(){return{}}},formDefId:{type:String,default:""},showAll:{type:Boolean,default:!1},showDefaultCount:{type:Number,default:6},queryExclude:{type:Boolean,default:!1}},data(){return{formData:{},formErrors:{},elementIdList:[],eleMap:{},relyGraphData:{nodes:[],edges:[]}}},computed:{formatedSchema(){const e=this.searchSchema||{},t=this.verifySchema;let r=null;try{r=n.compile(t)}catch(e){console.error("构建VerifySchema出错",e)}return{elements:e.elements||[],verifySchema:r}},enableSearchText(){const e=this.searchSchema||{},t=!!e.elements&&_.find(e.elements,{id:"q__contains"});return e.enable_search_text&&t},gridElements(){const e=this.searchSchema||{};return e.elements?e.elements.filter((e=>!("MulSelect"===e.type&&"button"===e.style||this.queryExclude&&"q__contains"===e.id))):[]},pElements(){const e=this.searchSchema||{};return e.elements?e.elements.filter((e=>"MulSelect"===e.type&&"button"===e.style)):[]},showAllSearchItem:{get(){return this.showAll},set(){}}},mounted(){this.$emit("beforeDataLoad"),this.penetrationZList=[],this.relyArr=[],this.addStackArr(this.searchSchema.elements),this.createTopoGraph(this.searchSchema.elements),_.each(this.penetrationZList,(e=>{this.relyGraphData.edges.push({source:"bpmListSearch",target:e})})),this.$emit("dataLoaded");let{relyHandleList:e,firstId:t}=this.getRelyHandleList("bpmListSearch");this.relyHandleList=e,_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this),t&&this.$bpm.$emit("handeInitRely",{id:t})},methods:{reset(){this.formData={}},search(){this.submit()},async submit(){let e=await this.$bpm.handleVerifySchema({mode:"list",data:this.formData,verifySchema:this.formatedSchema.verifySchema});if(this.formErrors=e,console.log("errors",e),e)return;let t=this.formData;return t=_.pickBy(t,((e,t)=>""!=e)),this.$emit("search",t),t},handleNextRely(e){this.relyHandleList.shift(),_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this);let t=_.head(this.relyHandleList);t&&this.$bpm.$emit("handeInitRely",{id:t,rowIndex:e})},handleRelyById(e,t){let{relyHandleList:r,firstId:s}=this.getRelyHandleList(e);this.relyHandleList=r,s&&this.$bpm.$emit("handeRelyById",{id:s,rowIndex:t})},handleNextRelyById(e){this.relyHandleList.shift(),_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this);let t=_.head(this.relyHandleList);t&&this.$bpm.$emit("handeRelyById",{id:t,rowIndex:e})},getRelyHandleList(e){let t=[];const{breadthFirstSearch:r}=a.Algorithm;let s=null;return r(this.relyGraphData,e,{enter:({current:e,previous:t})=>{},leave:({current:r,previous:a})=>{s||r==e||(s=r),r!=e&&t.push(r)}}),{relyHandleList:t,firstId:s}},addStackArr(e,t){_.each(e,(e=>{t&&_.set(e,"parentId",t),_.set(this.eleMap,e.id,e),this.elementIdList.push(e.id);let r=_.get(e,"linkage.depends",[]),s=_.get(e,"scope.depends",[]),a=_.get(e,"range_remote.depends",[]),o=_.concat(r,s);o=_.concat(o,a),t||(this.penetrationZList=_.concat(this.penetrationZList,o)),e.elements&&this.addStackArr(e.elements,e.id)}))},createTopoGraph(e){_.each(e,(e=>{let t=_.get(e,"linkage.depends",[]),r=_.get(e,"scope.depends",[]),s=_.get(e,"range_remote.depends",[]),a=_.concat(t,r);a=_.concat(a,s);let o=_.cloneDeep(a),n=_.get(this.eleMap,e.id);if(_.each(o,(e=>{_.get(this.eleMap,e)||(_.pullAll(a,[e]),a=_.cloneDeep(a))})),a.length||n.parentId){let t=_.pullAll(this.penetrationZList,[e.id]);this.penetrationZList=_.cloneDeep(t)}_.each(a,(t=>{if(t&&e.id&&_.includes(this.elementIdList,t)){let r=_.get(this.eleMap,t);if(!r)return;r.parentId&&!n.parentId&&(t=r.parentId);let s=n.parentId&&!r.parentId?n.parentId:n.id;if(r.parentId&&n.parentId)return;this.relyArr.push([t,s]),this.relyGraphData.nodes.push(e),this.relyGraphData.nodes.push(r),this.relyGraphData.edges.push({source:t,target:s})}})),e.elements&&this.createTopoGraph(e.elements)}))}}},c=(0,r(4486).A)(i,s,[],!1,null,"3743a4b0",null);c.options.__file="components/lib/bpmFieldsFilter/src/main.vue";var l=c.exports},617:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(208),a=r(9029),o=r(4227),n=r(6250),i={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:e,j:t}})=>a.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>a._`{i: ${e}, j: ${t}}`},code(e){const{gen:t,data:r,$data:i,schema:c,parentSchema:l,schemaCode:d,it:u}=e;if(!i&&!c)return;const f=t.let("valid"),h=l.items?(0,s.getSchemaTypes)(l.items):[];function m(o,n){const i=t.name("item"),c=(0,s.checkDataTypes)(h,i,u.opts.strictNumbers,s.DataType.Wrong),l=t.const("indices",a._`{}`);t.for(a._`;${o}--;`,(()=>{t.let(i,a._`${r}[${o}]`),t.if(c,a._`continue`),h.length>1&&t.if(a._`typeof ${i} == "string"`,a._`${i} += "_"`),t.if(a._`typeof ${l}[${i}] == "number"`,(()=>{t.assign(n,a._`${l}[${i}]`),e.error(),t.assign(f,!1).break()})).code(a._`${l}[${i}] = ${o}`)}))}function p(s,i){const c=(0,o.useFunc)(t,n.default),l=t.name("outer");t.label(l).for(a._`;${s}--;`,(()=>t.for(a._`${i} = ${s}; ${i}--;`,(()=>t.if(a._`${c}(${r}[${s}], ${r}[${i}])`,(()=>{e.error(),t.assign(f,!1).break(l)}))))))}e.block$data(f,(function(){const s=t.let("i",a._`${r}.length`),o=t.let("j");e.setParams({i:s,j:o}),t.assign(f,!0),t.if(a._`${s} > 1`,(()=>(h.length>0&&!h.some((e=>"object"===e||"array"===e))?m:p)(s,o)))}),a._`${d} === false`),e.ok(f)}};t.default=i},1163:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxItems"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:a}=e,o="maxItems"===t?s.operators.GT:s.operators.LT;e.fail$data(s._`${r}.length ${o} ${a}`)}};t.default=a},1239:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:e})=>s.str`must match "${e.ifClause}" schema`,params:({params:e})=>s._`{failingKeyword: ${e.ifClause}}`},code(e){const{gen:t,parentSchema:r,it:o}=e;void 0===r.then&&void 0===r.else&&(0,a.checkStrictMode)(o,'"if" without "then" and "else" is ignored');const i=n(o,"then"),c=n(o,"else");if(!i&&!c)return;const l=t.let("valid",!0),d=t.name("_valid");if(function(){const t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},d);e.mergeEvaluated(t)}(),e.reset(),i&&c){const r=t.let("ifClause");e.setParams({ifClause:r}),t.if(d,u("then",r),u("else",r))}else i?t.if(d,u("then")):t.if((0,s.not)(d),u("else"));function u(r,a){return()=>{const o=e.subschema({keyword:r},d);t.assign(l,d),e.mergeValidEvaluated(o,l),a?t.assign(a,s._`${r}`):e.setParams({ifClause:r})}}e.pass(l,(()=>e.error(!0)))}};function n(e,t){const r=e.schema[t];return void 0!==r&&!(0,a.alwaysValidSchema)(e,r)}t.default=o},1520:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class r{}t._CodeOrName=r,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class s extends r{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=s;class a extends r{constructor(e){super(),this._items="string"==typeof e?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const e=this._items[0];return""===e||'""'===e}get str(){var e;return null!==(e=this._str)&&void 0!==e?e:this._str=this._items.reduce(((e,t)=>`${e}${t}`),"")}get names(){var e;return null!==(e=this._names)&&void 0!==e?e:this._names=this._items.reduce(((e,t)=>(t instanceof s&&(e[t.str]=(e[t.str]||0)+1),e)),{})}}function o(e,...t){const r=[e[0]];let s=0;for(;s<t.length;)c(r,t[s]),r.push(e[++s]);return new a(r)}t._Code=a,t.nil=new a(""),t._=o;const n=new a("+");function i(e,...t){const r=[d(e[0])];let s=0;for(;s<t.length;)r.push(n),c(r,t[s]),r.push(n,d(e[++s]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===n){const r=l(e[t-1],e[t+1]);if(void 0!==r){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}(r),new a(r)}function c(e,t){var r;t instanceof a?e.push(...t._items):t instanceof s?e.push(t):e.push("number"==typeof(r=t)||"boolean"==typeof r||null===r?r:d(Array.isArray(r)?r.join(","):r))}function l(e,t){if('""'===t)return e;if('""'===e)return t;if("string"==typeof e){if(t instanceof s||'"'!==e[e.length-1])return;return"string"!=typeof t?`${e.slice(0,-1)}${t}"`:'"'===t[0]?e.slice(0,-1)+t.slice(1):void 0}return"string"!=typeof t||'"'!==t[0]||e instanceof s?void 0:`"${e}${t.slice(1)}`}function d(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=i,t.addCodeArg=c,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:i`${e}${t}`},t.stringify=function(e){return new a(d(e))},t.safeStringify=d,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new a(`.${e}`):o`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new a(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new a(e.toString())}},2017:function(e){e.exports=function e(t,r){if(t===r)return!0;if(t&&r&&"object"==typeof t&&"object"==typeof r){if(t.constructor!==r.constructor)return!1;var s,a,o;if(Array.isArray(t)){if((s=t.length)!=r.length)return!1;for(a=s;0!=a--;)if(!e(t[a],r[a]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((s=(o=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(a=s;0!=a--;)if(!Object.prototype.hasOwnProperty.call(r,o[a]))return!1;for(a=s;0!=a--;){var n=o[a];if(!e(t[n],r[n]))return!1}return!0}return t!=t&&r!=r}},2023:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={data:new s.Name("data"),valCxt:new s.Name("valCxt"),instancePath:new s.Name("instancePath"),parentData:new s.Name("parentData"),parentDataProperty:new s.Name("parentDataProperty"),rootData:new s.Name("rootData"),dynamicAnchors:new s.Name("dynamicAnchors"),vErrors:new s.Name("vErrors"),errors:new s.Name("errors"),this:new s.Name("this"),self:new s.Name("self"),scope:new s.Name("scope"),json:new s.Name("json"),jsonPos:new s.Name("jsonPos"),jsonLen:new s.Name("jsonLen"),jsonPart:new s.Name("jsonPart")};t.default=a},2079:function(e){e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')},2105:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxProperties"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:a}=e,o="maxProperties"===t?s.operators.GT:s.operators.LT;e.fail$data(s._`Object.keys(${r}).length ${o} ${a}`)}};t.default=a},2128:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(3463),a=r(3693),o=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",s.default,a.default];t.default=o},2586:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;const s=r(8727),a=r(208),o=r(7887),n=r(208),i=r(7870),c=r(3673),l=r(4495),d=r(9029),u=r(2023),f=r(6939),h=r(4227),m=r(8708);function p({gen:e,validateName:t,schema:r,schemaEnv:s,opts:a},o){a.code.es5?e.func(t,d._`${u.default.data}, ${u.default.valCxt}`,s.$async,(()=>{e.code(d._`"use strict"; ${y(r,a)}`),function(e,t){e.if(u.default.valCxt,(()=>{e.var(u.default.instancePath,d._`${u.default.valCxt}.${u.default.instancePath}`),e.var(u.default.parentData,d._`${u.default.valCxt}.${u.default.parentData}`),e.var(u.default.parentDataProperty,d._`${u.default.valCxt}.${u.default.parentDataProperty}`),e.var(u.default.rootData,d._`${u.default.valCxt}.${u.default.rootData}`),t.dynamicRef&&e.var(u.default.dynamicAnchors,d._`${u.default.valCxt}.${u.default.dynamicAnchors}`)}),(()=>{e.var(u.default.instancePath,d._`""`),e.var(u.default.parentData,d._`undefined`),e.var(u.default.parentDataProperty,d._`undefined`),e.var(u.default.rootData,u.default.data),t.dynamicRef&&e.var(u.default.dynamicAnchors,d._`{}`)}))}(e,a),e.code(o)})):e.func(t,d._`${u.default.data}, ${function(e){return d._`{${u.default.instancePath}="", ${u.default.parentData}, ${u.default.parentDataProperty}, ${u.default.rootData}=${u.default.data}${e.dynamicRef?d._`, ${u.default.dynamicAnchors}={}`:d.nil}}={}`}(a)}`,s.$async,(()=>e.code(y(r,a)).code(o)))}function y(e,t){const r="object"==typeof e&&e[t.schemaId];return r&&(t.code.source||t.code.process)?d._`/*# sourceURL=${r} */`:d.nil}function g({schema:e,self:t}){if("boolean"==typeof e)return!e;for(const r in e)if(t.RULES.all[r])return!0;return!1}function v(e){return"boolean"!=typeof e.schema}function _(e){(0,h.checkUnknownRules)(e),function(e){const{schema:t,errSchemaPath:r,opts:s,self:a}=e;t.$ref&&s.ignoreKeywordsWithRef&&(0,h.schemaHasRulesButRef)(t,a.RULES)&&a.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}(e)}function $(e,t){if(e.opts.jtd)return b(e,[],!1,t);const r=(0,a.getSchemaTypes)(e.schema);b(e,r,!(0,a.coerceAndCheckDataType)(e,r),t)}function w({gen:e,schemaEnv:t,schema:r,errSchemaPath:s,opts:a}){const o=r.$comment;if(!0===a.$comment)e.code(d._`${u.default.self}.logger.log(${o})`);else if("function"==typeof a.$comment){const r=d.str`${s}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(d._`${u.default.self}.opts.$comment(${o}, ${r}, ${a}.schema)`)}}function b(e,t,r,s){const{gen:a,schema:i,data:c,allErrors:l,opts:f,self:m}=e,{RULES:p}=m;function y(h){(0,o.shouldUseGroup)(i,h)&&(h.type?(a.if((0,n.checkDataType)(h.type,c,f.strictNumbers)),S(e,h),1===t.length&&t[0]===h.type&&r&&(a.else(),(0,n.reportTypeError)(e)),a.endIf()):S(e,h),l||a.if(d._`${u.default.errors} === ${s||0}`))}!i.$ref||!f.ignoreKeywordsWithRef&&(0,h.schemaHasRulesButRef)(i,p)?(f.jtd||function(e,t){!e.schemaEnv.meta&&e.opts.strictTypes&&(function(e,t){t.length&&(e.dataTypes.length?(t.forEach((t=>{P(e.dataTypes,t)||E(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)})),function(e,t){const r=[];for(const s of e.dataTypes)P(t,s)?r.push(s):t.includes("integer")&&"number"===s&&r.push("integer");e.dataTypes=r}(e,t)):e.dataTypes=t)}(e,t),e.opts.allowUnionTypes||function(e,t){t.length>1&&(2!==t.length||!t.includes("null"))&&E(e,"use allowUnionTypes to allow union type keyword")}(e,t),function(e,t){const r=e.self.RULES.all;for(const s in r){const a=r[s];if("object"==typeof a&&(0,o.shouldUseRule)(e.schema,a)){const{type:r}=a.definition;r.length&&!r.some((e=>{return s=e,(r=t).includes(s)||"number"===s&&r.includes("integer");var r,s}))&&E(e,`missing type "${r.join(",")}" for keyword "${s}"`)}}}(e,e.dataTypes))}(e,t),a.block((()=>{for(const e of p.rules)y(e);y(p.post)}))):a.block((()=>I(e,"$ref",p.all.$ref.definition)))}function S(e,t){const{gen:r,schema:s,opts:{useDefaults:a}}=e;a&&(0,i.assignDefaults)(e,t.type),r.block((()=>{for(const r of t.rules)(0,o.shouldUseRule)(s,r)&&I(e,r.keyword,r.definition,t.type)}))}function P(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function E(e,t){t+=` at "${e.schemaEnv.baseId+e.errSchemaPath}" (strictTypes)`,(0,h.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){v(e)&&(_(e),g(e))?function(e){const{schema:t,opts:r,gen:s}=e;p(e,(()=>{r.$comment&&t.$comment&&w(e),function(e){const{schema:t,opts:r}=e;void 0!==t.default&&r.useDefaults&&r.strictSchema&&(0,h.checkStrictMode)(e,"default is ignored in the schema root")}(e),s.let(u.default.vErrors,null),s.let(u.default.errors,0),r.unevaluated&&function(e){const{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",d._`${r}.evaluated`),t.if(d._`${e.evaluated}.dynamicProps`,(()=>t.assign(d._`${e.evaluated}.props`,d._`undefined`))),t.if(d._`${e.evaluated}.dynamicItems`,(()=>t.assign(d._`${e.evaluated}.items`,d._`undefined`)))}(e),$(e),function(e){const{gen:t,schemaEnv:r,validateName:s,ValidationError:a,opts:o}=e;r.$async?t.if(d._`${u.default.errors} === 0`,(()=>t.return(u.default.data)),(()=>t.throw(d._`new ${a}(${u.default.vErrors})`))):(t.assign(d._`${s}.errors`,u.default.vErrors),o.unevaluated&&function({gen:e,evaluated:t,props:r,items:s}){r instanceof d.Name&&e.assign(d._`${t}.props`,r),s instanceof d.Name&&e.assign(d._`${t}.items`,s)}(e),t.return(d._`${u.default.errors} === 0`))}(e)}))}(e):p(e,(()=>(0,s.topBoolOrEmptySchema)(e)))};class k{constructor(e,t,r){if((0,c.validateKeywordUsage)(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,h.schemaRefOrVal)(e,this.schema,r,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",x(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,c.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw new Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",u.default.errors))}result(e,t,r){this.failResult((0,d.not)(e),t,r)}failResult(e,t,r){this.gen.if(e),r?r():this.error(),t?(this.gen.else(),t(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,t){this.failResult((0,d.not)(e),void 0,t)}fail(e){if(void 0===e)return this.error(),void(this.allErrors||this.gen.if(!1));this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);const{schemaCode:t}=this;this.fail(d._`${t} !== undefined && (${(0,d.or)(this.invalid$data(),e)})`)}error(e,t,r){if(t)return this.setParams(t),this._error(e,r),void this.setParams({});this._error(e,r)}_error(e,t){(e?m.reportExtraError:m.reportError)(this,this.def.error,t)}$dataError(){(0,m.reportError)(this,this.def.$dataError||m.keyword$DataError)}reset(){if(void 0===this.errsCount)throw new Error('add "trackErrors" to keyword definition');(0,m.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,t){t?Object.assign(this.params,e):this.params=e}block$data(e,t,r=d.nil){this.gen.block((()=>{this.check$data(e,r),t()}))}check$data(e=d.nil,t=d.nil){if(!this.$data)return;const{gen:r,schemaCode:s,schemaType:a,def:o}=this;r.if((0,d.or)(d._`${s} === undefined`,t)),e!==d.nil&&r.assign(e,!0),(a.length||o.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),e!==d.nil&&r.assign(e,!1)),r.else()}invalid$data(){const{gen:e,schemaCode:t,schemaType:r,def:s,it:a}=this;return(0,d.or)(function(){if(r.length){if(!(t instanceof d.Name))throw new Error("ajv implementation error");const e=Array.isArray(r)?r:[r];return d._`${(0,n.checkDataTypes)(e,t,a.opts.strictNumbers,n.DataType.Wrong)}`}return d.nil}(),function(){if(s.validateSchema){const r=e.scopeValue("validate$data",{ref:s.validateSchema});return d._`!${r}(${t})`}return d.nil}())}subschema(e,t){const r=(0,l.getSubschema)(this.it,e);(0,l.extendSubschemaData)(r,this.it,e),(0,l.extendSubschemaMode)(r,e);const a={...this.it,...r,items:void 0,props:void 0};return function(e,t){v(e)&&(_(e),g(e))?function(e,t){const{schema:r,gen:s,opts:a}=e;a.$comment&&r.$comment&&w(e),function(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,f.resolveUrl)(e.opts.uriResolver,e.baseId,t))}(e),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}(e);const o=s.const("_errs",u.default.errors);$(e,o),s.var(t,d._`${o} === ${u.default.errors}`)}(e,t):(0,s.boolOrEmptySchema)(e,t)}(a,t),a}mergeEvaluated(e,t){const{it:r,gen:s}=this;r.opts.unevaluated&&(!0!==r.props&&void 0!==e.props&&(r.props=h.mergeEvaluated.props(s,e.props,r.props,t)),!0!==r.items&&void 0!==e.items&&(r.items=h.mergeEvaluated.items(s,e.items,r.items,t)))}mergeValidEvaluated(e,t){const{it:r,gen:s}=this;if(r.opts.unevaluated&&(!0!==r.props||!0!==r.items))return s.if(t,(()=>this.mergeEvaluated(e,d.Name))),!0}}function I(e,t,r,s){const a=new k(e,r,t);"code"in r?r.code(a,s):a.$data&&r.validate?(0,c.funcKeywordCode)(a,r):"macro"in r?(0,c.macroKeywordCode)(a,r):(r.compile||r.validate)&&(0,c.funcKeywordCode)(a,r)}t.KeywordCxt=k;const j=/^\/(?:[^~]|~0|~1)*$/,N=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function x(e,{dataLevel:t,dataNames:r,dataPathArr:s}){let a,o;if(""===e)return u.default.rootData;if("/"===e[0]){if(!j.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);a=e,o=u.default.rootData}else{const n=N.exec(e);if(!n)throw new Error(`Invalid JSON-pointer: ${e}`);const i=+n[1];if(a=n[2],"#"===a){if(i>=t)throw new Error(c("property/index",i));return s[t-i]}if(i>t)throw new Error(c("data",i));if(o=r[t-i],!a)return o}let n=o;const i=a.split("/");for(const e of i)e&&(o=d._`${o}${(0,d.getProperty)((0,h.unescapeJsonPointer)(e))}`,n=d._`${n} && ${o}`);return n;function c(e,r){return`Cannot access ${e} ${r} levels up, current level is ${t}`}}t.getData=x},2661:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:e,max:t}})=>void 0===t?s.str`must contain at least ${e} valid item(s)`:s.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>void 0===t?s._`{minContains: ${e}}`:s._`{minContains: ${e}, maxContains: ${t}}`},code(e){const{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;let c,l;const{minContains:d,maxContains:u}=o;i.opts.next?(c=void 0===d?1:d,l=u):c=1;const f=t.const("len",s._`${n}.length`);if(e.setParams({min:c,max:l}),void 0===l&&0===c)return void(0,a.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==l&&c>l)return(0,a.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),void e.fail();if((0,a.alwaysValidSchema)(i,r)){let t=s._`${f} >= ${c}`;return void 0!==l&&(t=s._`${t} && ${f} <= ${l}`),void e.pass(t)}i.items=!0;const h=t.name("valid");function m(){const e=t.name("_valid"),r=t.let("count",0);p(e,(()=>t.if(e,(()=>function(e){t.code(s._`${e}++`),void 0===l?t.if(s._`${e} >= ${c}`,(()=>t.assign(h,!0).break())):(t.if(s._`${e} > ${l}`,(()=>t.assign(h,!1).break())),1===c?t.assign(h,!0):t.if(s._`${e} >= ${c}`,(()=>t.assign(h,!0))))}(r)))))}function p(r,s){t.forRange("i",0,f,(t=>{e.subschema({keyword:"contains",dataProp:t,dataPropType:a.Type.Num,compositeRule:!0},r),s()}))}void 0===l&&1===c?p(h,(()=>t.if(h,(()=>t.break())))):0===c?(t.let(h,!0),void 0!==l&&t.if(s._`${n}.length > 0`,m)):(t.let(h,!1),m()),e.result(h,(()=>e.reset()))}};t.default=o},3025:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;const s=r(9029),a=r(4227),o=r(5765);t.error={message:({params:{property:e,depsCount:t,deps:r}})=>{const a=1===t?"property":"properties";return s.str`must have ${a} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:a}})=>s._`{property: ${e},
5
5
  missingProperty: ${a},
6
6
  depsCount: ${t},
7
- deps: ${r}}`};const n={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){const[t,r]=function({schema:e}){const t={},r={};for(const s in e)"__proto__"!==s&&((Array.isArray(e[s])?t:r)[s]=e[s]);return[t,r]}(e);i(e,t),c(e,r)}};function i(e,t=e.schema){const{gen:r,data:a,it:n}=e;if(0===Object.keys(t).length)return;const i=r.let("missing");for(const c in t){const l=t[c];if(0===l.length)continue;const d=(0,o.propertyInData)(r,a,c,n.opts.ownProperties);e.setParams({property:c,depsCount:l.length,deps:l.join(", ")}),n.allErrors?r.if(d,(()=>{for(const t of l)(0,o.checkReportMissingProp)(e,t)})):(r.if(s._`${d} && (${(0,o.checkMissingProp)(e,l,i)})`),(0,o.reportMissingProp)(e,i),r.else())}}function c(e,t=e.schema){const{gen:r,data:s,keyword:n,it:i}=e,c=r.name("valid");for(const l in t)(0,a.alwaysValidSchema)(i,t[l])||(r.if((0,o.propertyInData)(r,s,l,i.opts.ownProperties),(()=>{const t=e.subschema({keyword:n,schemaProp:l},c);e.mergeValidEvaluated(t,c)}),(()=>r.var(c,!0))),e.ok(c))}t.validatePropertyDeps=i,t.validateSchemaDeps=c,t.default=n},1239:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:e})=>s.str`must match "${e.ifClause}" schema`,params:({params:e})=>s._`{failingKeyword: ${e.ifClause}}`},code(e){const{gen:t,parentSchema:r,it:o}=e;void 0===r.then&&void 0===r.else&&(0,a.checkStrictMode)(o,'"if" without "then" and "else" is ignored');const i=n(o,"then"),c=n(o,"else");if(!i&&!c)return;const l=t.let("valid",!0),d=t.name("_valid");if(function(){const t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},d);e.mergeEvaluated(t)}(),e.reset(),i&&c){const r=t.let("ifClause");e.setParams({ifClause:r}),t.if(d,u("then",r),u("else",r))}else i?t.if(d,u("then")):t.if((0,s.not)(d),u("else"));function u(r,a){return()=>{const o=e.subschema({keyword:r},d);t.assign(l,d),e.mergeValidEvaluated(o,l),a?t.assign(a,s._`${r}`):e.setParams({ifClause:r})}}e.pass(l,(()=>e.error(!0)))}};function n(e,t){const r=e.schema[t];return void 0!==r&&!(0,a.alwaysValidSchema)(e,r)}t.default=o},6378:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5457),a=r(5354),o=r(494),n=r(3966),i=r(2661),c=r(3025),l=r(9713),d=r(8660),u=r(117),f=r(5333),h=r(7923),m=r(6505),p=r(6163),y=r(5844),g=r(1239),v=r(4426);t.default=function(e=!1){const t=[h.default,m.default,p.default,y.default,g.default,v.default,l.default,d.default,c.default,u.default,f.default];return e?t.push(a.default,n.default):t.push(s.default,o.default),t.push(i.default),t}},494:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;const s=r(9029),a=r(4227),o=r(5765),n={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:r}=e;if(Array.isArray(t))return i(e,"additionalItems",t);r.items=!0,(0,a.alwaysValidSchema)(r,t)||e.ok((0,o.validateArray)(e))}};function i(e,t,r=e.schema){const{gen:o,parentSchema:n,data:i,keyword:c,it:l}=e;!function(e){const{opts:s,errSchemaPath:o}=l,n=r.length,i=n===e.minItems&&(n===e.maxItems||!1===e[t]);if(s.strictTuples&&!i){const e=`"${c}" is ${n}-tuple, but minItems or maxItems/${t} are not specified or different at path "${o}"`;(0,a.checkStrictMode)(l,e,s.strictTuples)}}(n),l.opts.unevaluated&&r.length&&!0!==l.items&&(l.items=a.mergeEvaluated.items(o,r.length,l.items));const d=o.name("valid"),u=o.const("len",s._`${i}.length`);r.forEach(((t,r)=>{(0,a.alwaysValidSchema)(l,t)||(o.if(s._`${u} > ${r}`,(()=>e.subschema({keyword:c,schemaProp:r,dataProp:r},d))),e.ok(d))}))}t.validateTuple=i,t.default=n},3966:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(5765),n=r(5457),i={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:e}})=>s.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>s._`{limit: ${e}}`},code(e){const{schema:t,parentSchema:r,it:s}=e,{prefixItems:i}=r;s.items=!0,(0,a.alwaysValidSchema)(s,t)||(i?(0,n.validateAdditionalItems)(e,i):e.ok((0,o.validateArray)(e)))}};t.default=i},7923:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:r,it:a}=e;if((0,s.alwaysValidSchema)(a,r))return void e.fail();const o=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},o),e.failResult(o,(()=>e.reset()),(()=>e.error()))},error:{message:"must NOT be valid"}};t.default=a},6163:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:e})=>s._`{passingSchemas: ${e.passing}}`},code(e){const{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.discriminator)return;const i=r,c=t.let("valid",!1),l=t.let("passing",null),d=t.name("_valid");e.setParams({passing:l}),t.block((function(){i.forEach(((r,o)=>{let i;(0,a.alwaysValidSchema)(n,r)?t.var(d,!0):i=e.subschema({keyword:"oneOf",schemaProp:o,compositeRule:!0},d),o>0&&t.if(s._`${d} && ${c}`).assign(c,!1).assign(l,s._`[${l}, ${o}]`).else(),t.if(d,(()=>{t.assign(c,!0),t.assign(l,o),i&&e.mergeEvaluated(i,s.Name)}))}))})),e.result(c,(()=>e.reset()),(()=>e.error(!0)))}};t.default=o},5333:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(4227),n=r(4227),i={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,data:i,parentSchema:c,it:l}=e,{opts:d}=l,u=(0,s.allSchemaProperties)(r),f=u.filter((e=>(0,o.alwaysValidSchema)(l,r[e])));if(0===u.length||f.length===u.length&&(!l.opts.unevaluated||!0===l.props))return;const h=d.strictSchema&&!d.allowMatchingProperties&&c.properties,m=t.name("valid");!0===l.props||l.props instanceof a.Name||(l.props=(0,n.evaluatedPropsToName)(t,l.props));const{props:p}=l;function y(e){for(const t in h)new RegExp(e).test(t)&&(0,o.checkStrictMode)(l,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}function g(r){t.forIn("key",i,(o=>{t.if(a._`${(0,s.usePattern)(e,r)}.test(${o})`,(()=>{const s=f.includes(r);s||e.subschema({keyword:"patternProperties",schemaProp:r,dataProp:o,dataPropType:n.Type.Str},m),l.opts.unevaluated&&!0!==p?t.assign(a._`${p}[${o}]`,!0):s||l.allErrors||t.if((0,a.not)(m),(()=>t.break()))}))}))}!function(){for(const e of u)h&&y(e),l.allErrors?g(e):(t.var(m,!0),g(e),t.if(m))}()}};t.default=i},5354:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(494),a={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,s.validateTuple)(e,"items")};t.default=a},117:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2586),a=r(5765),o=r(4227),n=r(8660),i={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,parentSchema:i,data:c,it:l}=e;"all"===l.opts.removeAdditional&&void 0===i.additionalProperties&&n.default.code(new s.KeywordCxt(l,n.default,"additionalProperties"));const d=(0,a.allSchemaProperties)(r);for(const e of d)l.definedProperties.add(e);l.opts.unevaluated&&d.length&&!0!==l.props&&(l.props=o.mergeEvaluated.props(t,(0,o.toHash)(d),l.props));const u=d.filter((e=>!(0,o.alwaysValidSchema)(l,r[e])));if(0===u.length)return;const f=t.name("valid");for(const r of u)h(r)?m(r):(t.if((0,a.propertyInData)(t,c,r,l.opts.ownProperties)),m(r),l.allErrors||t.else().var(f,!0),t.endIf()),e.it.definedProperties.add(r),e.ok(f);function h(e){return l.opts.useDefaults&&!l.compositeRule&&void 0!==r[e].default}function m(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},f)}}};t.default=i},9713:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:e})=>s._`{propertyName: ${e.propertyName}}`},code(e){const{gen:t,schema:r,data:o,it:n}=e;if((0,a.alwaysValidSchema)(n,r))return;const i=t.name("valid");t.forIn("key",o,(r=>{e.setParams({propertyName:r}),e.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},i),t.if((0,s.not)(i),(()=>{e.error(!0),n.allErrors||t.break()}))})),e.ok(i)}};t.default=o},4426:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){void 0===t.if&&(0,s.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};t.default=a},5765:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;const s=r(9029),a=r(4227),o=r(2023),n=r(4227);function i(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:s._`Object.prototype.hasOwnProperty`})}function c(e,t,r){return s._`${i(e)}.call(${t}, ${r})`}function l(e,t,r,a){const o=s._`${t}${(0,s.getProperty)(r)} === undefined`;return a?(0,s.or)(o,(0,s.not)(c(e,t,r))):o}function d(e){return e?Object.keys(e).filter((e=>"__proto__"!==e)):[]}t.checkReportMissingProp=function(e,t){const{gen:r,data:a,it:o}=e;r.if(l(r,a,t,o.opts.ownProperties),(()=>{e.setParams({missingProperty:s._`${t}`},!0),e.error()}))},t.checkMissingProp=function({gen:e,data:t,it:{opts:r}},a,o){return(0,s.or)(...a.map((a=>(0,s.and)(l(e,t,a,r.ownProperties),s._`${o} = ${a}`))))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=i,t.isOwnProperty=c,t.propertyInData=function(e,t,r,a){const o=s._`${t}${(0,s.getProperty)(r)} !== undefined`;return a?s._`${o} && ${c(e,t,r)}`:o},t.noPropertyInData=l,t.allSchemaProperties=d,t.schemaProperties=function(e,t){return d(t).filter((r=>!(0,a.alwaysValidSchema)(e,t[r])))},t.callValidateCode=function({schemaCode:e,data:t,it:{gen:r,topSchemaRef:a,schemaPath:n,errorPath:i},it:c},l,d,u){const f=u?s._`${e}, ${t}, ${a}${n}`:t,h=[[o.default.instancePath,(0,s.strConcat)(o.default.instancePath,i)],[o.default.parentData,c.parentData],[o.default.parentDataProperty,c.parentDataProperty],[o.default.rootData,o.default.rootData]];c.opts.dynamicRef&&h.push([o.default.dynamicAnchors,o.default.dynamicAnchors]);const m=s._`${f}, ${r.object(...h)}`;return d!==s.nil?s._`${l}.call(${d}, ${m})`:s._`${l}(${m})`};const u=s._`new RegExp`;t.usePattern=function({gen:e,it:{opts:t}},r){const a=t.unicodeRegExp?"u":"",{regExp:o}=t.code,i=o(r,a);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:s._`${"new RegExp"===o.code?u:(0,n.useFunc)(e,o)}(${r}, ${a})`})},t.validateArray=function(e){const{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.allErrors){const e=t.let("valid",!0);return c((()=>t.assign(e,!1))),e}return t.var(i,!0),c((()=>t.break())),i;function c(n){const c=t.const("len",s._`${r}.length`);t.forRange("i",0,c,(r=>{e.subschema({keyword:o,dataProp:r,dataPropType:a.Type.Num},i),t.if((0,s.not)(i),n)}))}},t.validateUnion=function(e){const{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some((e=>(0,a.alwaysValidSchema)(n,e)))&&!n.opts.unevaluated)return;const i=t.let("valid",!1),c=t.name("_valid");t.block((()=>r.forEach(((r,a)=>{const n=e.subschema({keyword:o,schemaProp:a,compositeRule:!0},c);t.assign(i,s._`${i} || ${c}`),e.mergeValidEvaluated(n,c)||t.if((0,s.not)(i))})))),e.result(i,(()=>e.reset()),(()=>e.error(!0)))}},3463:function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};t.default=r},2128:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(3463),a=r(3693),o=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",s.default,a.default];t.default=o},3693:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;const s=r(4551),a=r(5765),o=r(9029),n=r(2023),i=r(3835),c=r(4227),l={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:r,it:a}=e,{baseId:n,schemaEnv:c,validateName:l,opts:f,self:h}=a,{root:m}=c;if(("#"===r||"#/"===r)&&n===m.baseId)return function(){if(c===m)return u(e,l,c,c.$async);const r=t.scopeValue("root",{ref:m});return u(e,o._`${r}.validate`,m,m.$async)}();const p=i.resolveRef.call(h,m,n,r);if(void 0===p)throw new s.default(a.opts.uriResolver,n,r);return p instanceof i.SchemaEnv?function(t){const r=d(e,t);u(e,r,t,t.$async)}(p):function(s){const a=t.scopeValue("schema",!0===f.code.source?{ref:s,code:(0,o.stringify)(s)}:{ref:s}),n=t.name("valid"),i=e.subschema({schema:s,dataTypes:[],schemaPath:o.nil,topSchemaRef:a,errSchemaPath:r},n);e.mergeEvaluated(i),e.ok(n)}(p)}};function d(e,t){const{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):o._`${r.scopeValue("wrapper",{ref:t})}.validate`}function u(e,t,r,s){const{gen:i,it:l}=e,{allErrors:d,schemaEnv:u,opts:f}=l,h=f.passContext?n.default.this:o.nil;function m(e){const t=o._`${e}.errors`;i.assign(n.default.vErrors,o._`${n.default.vErrors} === null ? ${t} : ${n.default.vErrors}.concat(${t})`),i.assign(n.default.errors,o._`${n.default.vErrors}.length`)}function p(e){var t;if(!l.opts.unevaluated)return;const s=null===(t=null==r?void 0:r.validate)||void 0===t?void 0:t.evaluated;if(!0!==l.props)if(s&&!s.dynamicProps)void 0!==s.props&&(l.props=c.mergeEvaluated.props(i,s.props,l.props));else{const t=i.var("props",o._`${e}.evaluated.props`);l.props=c.mergeEvaluated.props(i,t,l.props,o.Name)}if(!0!==l.items)if(s&&!s.dynamicItems)void 0!==s.items&&(l.items=c.mergeEvaluated.items(i,s.items,l.items));else{const t=i.var("items",o._`${e}.evaluated.items`);l.items=c.mergeEvaluated.items(i,t,l.items,o.Name)}}s?function(){if(!u.$async)throw new Error("async schema referenced by sync schema");const r=i.let("valid");i.try((()=>{i.code(o._`await ${(0,a.callValidateCode)(e,t,h)}`),p(t),d||i.assign(r,!0)}),(e=>{i.if(o._`!(${e} instanceof ${l.ValidationError})`,(()=>i.throw(e))),m(e),d||i.assign(r,!1)})),e.ok(r)}():e.result((0,a.callValidateCode)(e,t,h),(()=>p(t)),(()=>m(t)))}t.getValidate=d,t.callRef=u,t.default=l},6653:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(7652),o=r(3835),n=r(4551),i=r(4227),c={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:e,tagName:t}})=>e===a.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>s._`{error: ${e}, tag: ${r}, tagValue: ${t}}`},code(e){const{gen:t,data:r,schema:c,parentSchema:l,it:d}=e,{oneOf:u}=l;if(!d.opts.discriminator)throw new Error("discriminator: requires discriminator option");const f=c.propertyName;if("string"!=typeof f)throw new Error("discriminator: requires propertyName");if(c.mapping)throw new Error("discriminator: mapping is not supported");if(!u)throw new Error("discriminator: requires oneOf keyword");const h=t.let("valid",!1),m=t.const("tag",s._`${r}${(0,s.getProperty)(f)}`);function p(r){const a=t.name("valid"),o=e.subschema({keyword:"oneOf",schemaProp:r},a);return e.mergeEvaluated(o,s.Name),a}t.if(s._`typeof ${m} == "string"`,(()=>function(){const r=function(){var e;const t={},r=a(l);let s=!0;for(let t=0;t<u.length;t++){let l=u[t];if((null==l?void 0:l.$ref)&&!(0,i.schemaHasRulesButRef)(l,d.self.RULES)){const e=l.$ref;if(l=o.resolveRef.call(d.self,d.schemaEnv.root,d.baseId,e),l instanceof o.SchemaEnv&&(l=l.schema),void 0===l)throw new n.default(d.opts.uriResolver,d.baseId,e)}const h=null===(e=null==l?void 0:l.properties)||void 0===e?void 0:e[f];if("object"!=typeof h)throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${f}"`);s=s&&(r||a(l)),c(h,t)}if(!s)throw new Error(`discriminator: "${f}" must be required`);return t;function a({required:e}){return Array.isArray(e)&&e.includes(f)}function c(e,t){if(e.const)h(e.const,t);else{if(!e.enum)throw new Error(`discriminator: "properties/${f}" must have "const" or "enum"`);for(const r of e.enum)h(r,t)}}function h(e,r){if("string"!=typeof e||e in t)throw new Error(`discriminator: "${f}" values must be unique strings`);t[e]=r}}();t.if(!1);for(const e in r)t.elseIf(s._`${m} === ${e}`),t.assign(h,p(r[e]));t.else(),e.error(!1,{discrError:a.DiscrError.Mapping,tag:m,tagName:f}),t.endIf()}()),(()=>e.error(!1,{discrError:a.DiscrError.Tag,tag:m,tagName:f}))),e.ok(h)}};t.default=c},7652:function(e,t){var r;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,function(e){e.Tag="tag",e.Mapping="mapping"}(r||(t.DiscrError=r={}))},6144:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2128),a=r(7060),o=r(6378),n=r(7532),i=r(9857),c=[s.default,a.default,(0,o.default)(),n.default,i.metadataVocabulary,i.contentVocabulary];t.default=c},4737:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>s.str`must match format "${e}"`,params:({schemaCode:e})=>s._`{format: ${e}}`},code(e,t){const{gen:r,data:a,$data:o,schema:n,schemaCode:i,it:c}=e,{opts:l,errSchemaPath:d,schemaEnv:u,self:f}=c;l.validateFormats&&(o?function(){const o=r.scopeValue("formats",{ref:f.formats,code:l.code.formats}),n=r.const("fDef",s._`${o}[${i}]`),c=r.let("fType"),d=r.let("format");r.if(s._`typeof ${n} == "object" && !(${n} instanceof RegExp)`,(()=>r.assign(c,s._`${n}.type || "string"`).assign(d,s._`${n}.validate`)),(()=>r.assign(c,s._`"string"`).assign(d,n))),e.fail$data((0,s.or)(!1===l.strictSchema?s.nil:s._`${i} && !${d}`,function(){const e=u.$async?s._`(${n}.async ? await ${d}(${a}) : ${d}(${a}))`:s._`${d}(${a})`,r=s._`(typeof ${d} == "function" ? ${e} : ${d}.test(${a}))`;return s._`${d} && ${d} !== true && ${c} === ${t} && !${r}`}()))}():function(){const o=f.formats[n];if(!o)return void function(){if(!1!==l.strictSchema)throw new Error(e());function e(){return`unknown format "${n}" ignored in schema at path "${d}"`}f.logger.warn(e())}();if(!0===o)return;const[i,c,h]=function(e){const t=e instanceof RegExp?(0,s.regexpCode)(e):l.code.formats?s._`${l.code.formats}${(0,s.getProperty)(n)}`:void 0,a=r.scopeValue("formats",{key:n,ref:e,code:t});return"object"!=typeof e||e instanceof RegExp?["string",e,a]:[e.type||"string",e.validate,s._`${a}.validate`]}(o);i===t&&e.pass(function(){if("object"==typeof o&&!(o instanceof RegExp)&&o.async){if(!u.$async)throw new Error("async format in sync schema");return s._`await ${h}(${a})`}return"function"==typeof c?s._`${h}(${a})`:s._`${h}.test(${a})`}())}())}};t.default=a},7532:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=[r(4737).default];t.default=s},9857:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},7935:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(6250),n={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:e})=>s._`{allowedValue: ${e}}`},code(e){const{gen:t,data:r,$data:n,schemaCode:i,schema:c}=e;n||c&&"object"==typeof c?e.fail$data(s._`!${(0,a.useFunc)(t,o.default)}(${r}, ${i})`):e.fail(s._`${c} !== ${r}`)}};t.default=n},8643:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(6250),n={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:e})=>s._`{allowedValues: ${e}}`},code(e){const{gen:t,data:r,$data:n,schema:i,schemaCode:c,it:l}=e;if(!n&&0===i.length)throw new Error("enum must have non-empty array");const d=i.length>=l.opts.loopEnum;let u;const f=()=>null!=u?u:u=(0,a.useFunc)(t,o.default);let h;if(d||n)h=t.let("valid"),e.block$data(h,(function(){t.assign(h,!1),t.forOf("v",c,(e=>t.if(s._`${f()}(${r}, ${e})`,(()=>t.assign(h,!0).break()))))}));else{if(!Array.isArray(i))throw new Error("ajv implementation error");const e=t.const("vSchema",c);h=(0,s.or)(...i.map(((t,a)=>function(e,t){const a=i[t];return"object"==typeof a&&null!==a?s._`${f()}(${r}, ${e}[${t}])`:s._`${r} === ${a}`}(e,a))))}e.pass(h)}};t.default=n},7060:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5882),a=r(3439),o=r(7307),n=r(422),i=r(2105),c=r(4003),l=r(1163),d=r(617),u=r(7935),f=r(8643),h=[s.default,a.default,o.default,n.default,i.default,c.default,l.default,d.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},u.default,f.default];t.default=h},1163:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxItems"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:a}=e,o="maxItems"===t?s.operators.GT:s.operators.LT;e.fail$data(s._`${r}.length ${o} ${a}`)}};t.default=a},7307:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(3853),n={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxLength"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:n,it:i}=e,c="maxLength"===t?s.operators.GT:s.operators.LT,l=!1===i.opts.unicode?s._`${r}.length`:s._`${(0,a.useFunc)(e.gen,o.default)}(${r})`;e.fail$data(s._`${l} ${c} ${n}`)}};t.default=n},5882:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=s.operators,o={maximum:{okStr:"<=",ok:a.LTE,fail:a.GT},minimum:{okStr:">=",ok:a.GTE,fail:a.LT},exclusiveMaximum:{okStr:"<",ok:a.LT,fail:a.GTE},exclusiveMinimum:{okStr:">",ok:a.GT,fail:a.LTE}},n={message:({keyword:e,schemaCode:t})=>s.str`must be ${o[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>s._`{comparison: ${o[e].okStr}, limit: ${t}}`},i={keyword:Object.keys(o),type:"number",schemaType:"number",$data:!0,error:n,code(e){const{keyword:t,data:r,schemaCode:a}=e;e.fail$data(s._`${r} ${o[t].fail} ${a} || isNaN(${r})`)}};t.default=i},2105:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxProperties"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:a}=e,o="maxProperties"===t?s.operators.GT:s.operators.LT;e.fail$data(s._`Object.keys(${r}).length ${o} ${a}`)}};t.default=a},3439:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:e})=>s.str`must be multiple of ${e}`,params:({schemaCode:e})=>s._`{multipleOf: ${e}}`},code(e){const{gen:t,data:r,schemaCode:a,it:o}=e,n=o.opts.multipleOfPrecision,i=t.let("res"),c=n?s._`Math.abs(Math.round(${i}) - ${i}) > 1e-${n}`:s._`${i} !== parseInt(${i})`;e.fail$data(s._`(${a} === 0 || (${i} = ${r}/${a}, ${c}))`)}};t.default=a},422:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>a.str`must match pattern "${e}"`,params:({schemaCode:e})=>a._`{pattern: ${e}}`},code(e){const{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,c=i.opts.unicodeRegExp?"u":"",l=r?a._`(new RegExp(${n}, ${c}))`:(0,s.usePattern)(e,o);e.fail$data(a._`!${l}.test(${t})`)}};t.default=o},4003:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(4227),n={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:e}})=>a.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>a._`{missingProperty: ${e}}`},code(e){const{gen:t,schema:r,schemaCode:n,data:i,$data:c,it:l}=e,{opts:d}=l;if(!c&&0===r.length)return;const u=r.length>=d.loopRequired;if(l.allErrors?function(){if(u||c)e.block$data(a.nil,f);else for(const t of r)(0,s.checkReportMissingProp)(e,t)}():function(){const o=t.let("missing");if(u||c){const r=t.let("valid",!0);e.block$data(r,(()=>function(r,o){e.setParams({missingProperty:r}),t.forOf(r,n,(()=>{t.assign(o,(0,s.propertyInData)(t,i,r,d.ownProperties)),t.if((0,a.not)(o),(()=>{e.error(),t.break()}))}),a.nil)}(o,r))),e.ok(r)}else t.if((0,s.checkMissingProp)(e,r,o)),(0,s.reportMissingProp)(e,o),t.else()}(),d.strictRequired){const t=e.parentSchema.properties,{definedProperties:s}=e.it;for(const e of r)if(void 0===(null==t?void 0:t[e])&&!s.has(e)){const t=`required property "${e}" is not defined at "${l.schemaEnv.baseId+l.errSchemaPath}" (strictRequired)`;(0,o.checkStrictMode)(l,t,l.opts.strictRequired)}}function f(){t.forOf("prop",n,(r=>{e.setParams({missingProperty:r}),t.if((0,s.noPropertyInData)(t,i,r,d.ownProperties),(()=>e.error()))}))}}};t.default=n},617:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(208),a=r(9029),o=r(4227),n=r(6250),i={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:e,j:t}})=>a.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>a._`{i: ${e}, j: ${t}}`},code(e){const{gen:t,data:r,$data:i,schema:c,parentSchema:l,schemaCode:d,it:u}=e;if(!i&&!c)return;const f=t.let("valid"),h=l.items?(0,s.getSchemaTypes)(l.items):[];function m(o,n){const i=t.name("item"),c=(0,s.checkDataTypes)(h,i,u.opts.strictNumbers,s.DataType.Wrong),l=t.const("indices",a._`{}`);t.for(a._`;${o}--;`,(()=>{t.let(i,a._`${r}[${o}]`),t.if(c,a._`continue`),h.length>1&&t.if(a._`typeof ${i} == "string"`,a._`${i} += "_"`),t.if(a._`typeof ${l}[${i}] == "number"`,(()=>{t.assign(n,a._`${l}[${i}]`),e.error(),t.assign(f,!1).break()})).code(a._`${l}[${i}] = ${o}`)}))}function p(s,i){const c=(0,o.useFunc)(t,n.default),l=t.name("outer");t.label(l).for(a._`;${s}--;`,(()=>t.for(a._`${i} = ${s}; ${i}--;`,(()=>t.if(a._`${c}(${r}[${s}], ${r}[${i}])`,(()=>{e.error(),t.assign(f,!1).break(l)}))))))}e.block$data(f,(function(){const s=t.let("i",a._`${r}.length`),o=t.let("j");e.setParams({i:s,j:o}),t.assign(f,!0),t.if(a._`${s} > 1`,(()=>(h.length>0&&!h.some((e=>"object"===e||"array"===e))?m:p)(s,o)))}),a._`${d} === false`),e.ok(f)}};t.default=i},2017:function(e){e.exports=function e(t,r){if(t===r)return!0;if(t&&r&&"object"==typeof t&&"object"==typeof r){if(t.constructor!==r.constructor)return!1;var s,a,o;if(Array.isArray(t)){if((s=t.length)!=r.length)return!1;for(a=s;0!=a--;)if(!e(t[a],r[a]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((s=(o=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(a=s;0!=a--;)if(!Object.prototype.hasOwnProperty.call(r,o[a]))return!1;for(a=s;0!=a--;){var n=o[a];if(!e(t[n],r[n]))return!1}return!0}return t!=t&&r!=r}},7106:function(e){var t=e.exports=function(e,t,s){"function"==typeof t&&(s=t,t={}),r(t,"function"==typeof(s=t.cb||s)?s:s.pre||function(){},s.post||function(){},e,"",e)};function r(e,s,a,o,n,i,c,l,d,u){if(o&&"object"==typeof o&&!Array.isArray(o)){for(var f in s(o,n,i,c,l,d,u),o){var h=o[f];if(Array.isArray(h)){if(f in t.arrayKeywords)for(var m=0;m<h.length;m++)r(e,s,a,h[m],n+"/"+f+"/"+m,i,n,f,o,m)}else if(f in t.propsKeywords){if(h&&"object"==typeof h)for(var p in h)r(e,s,a,h[p],n+"/"+f+"/"+p.replace(/~/g,"~0").replace(/\//g,"~1"),i,n,f,o,p)}else(f in t.keywords||e.allKeys&&!(f in t.skipKeywords))&&r(e,s,a,h,n+"/"+f,i,n,f,o)}a(o,n,i,c,l,d,u)}}t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},555:function(e,t,r){r.d(t,{A:function(){return l}});var s=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"search-board"},[r("el-form",{ref:"form",attrs:{"label-width":"150px",inline:!1}},[e._l(e.pElements,(function(t){return r("el-form-item",{key:t.id,attrs:{label:t.name}},[r("bpm-field",{attrs:{type:t.type,"field-conf":t,"form-name":e.formDefId,"form-def-id":e.formDefId,orgInfo:e.orgInfo,mode:"edit","ui-type":"search"},model:{value:e.formData[t.id],callback:function(r){e.$set(e.formData,t.id,r)},expression:"formData[searchField.id]"}})],1)})),e._v(" "),e._l(e.gridElements,(function(t){return[r("el-form-item",{directives:[{name:"show",rawName:"v-show",value:e.showAllSearchItem||e.index<e.showDefaultCount,expression:"showAllSearchItem || index < showDefaultCount"}],key:t.id,attrs:{label:t.name}},[r("bpm-field",{attrs:{type:t.type,"field-conf":t,"form-name":e.formDefId,"form-def-id":e.formDefId,orgInfo:e.orgInfo,mode:"edit","ui-type":"search"},model:{value:e.formData[t.id],callback:function(r){e.$set(e.formData,t.id,r)},expression:"formData[searchField.id]"}})],1)]}))],2),e._v(" "),e._t("default")],2)};s._withStripped=!0;var a=r(4419),o=r(3282);const n=new(r.n(o)())({useDefaults:!0,coerceTypes:!0,allErrors:!0,jsonPointers:!0,errorDataPath:!0});var i={name:"BpmFieldsFilter",props:{searchSchema:{type:Object,default(){return{elements:[]}}},verifySchema:{type:Object,default(){return{}}},orgInfo:{type:Object,default(){return{}}},formDefId:{type:String,default:""},showAll:{type:Boolean,default:!1},showDefaultCount:{type:Number,default:6},queryExclude:{type:Boolean,default:!1}},data(){return{formData:{},formErrors:{},elementIdList:[],eleMap:{},relyGraphData:{nodes:[],edges:[]}}},computed:{formatedSchema(){const e=this.searchSchema||{},t=this.verifySchema;let r=null;try{r=n.compile(t)}catch(e){console.error("构建VerifySchema出错",e)}return{elements:e.elements||[],verifySchema:r}},enableSearchText(){const e=this.searchSchema||{},t=!!e.elements&&_.find(e.elements,{id:"q__contains"});return e.enable_search_text&&t},gridElements(){const e=this.searchSchema||{};return e.elements?e.elements.filter((e=>!("MulSelect"===e.type&&"button"===e.style||this.queryExclude&&"q__contains"===e.id))):[]},pElements(){const e=this.searchSchema||{};return e.elements?e.elements.filter((e=>"MulSelect"===e.type&&"button"===e.style)):[]},showAllSearchItem:{get(){return this.showAll},set(){}}},mounted(){this.$emit("beforeDataLoad"),this.penetrationZList=[],this.relyArr=[],this.addStackArr(this.searchSchema.elements),this.createTopoGraph(this.searchSchema.elements),_.each(this.penetrationZList,(e=>{this.relyGraphData.edges.push({source:"bpmListSearch",target:e})})),this.$emit("dataLoaded");let{relyHandleList:e,firstId:t}=this.getRelyHandleList("bpmListSearch");this.relyHandleList=e,_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this),t&&this.$bpm.$emit("handeInitRely",{id:t})},methods:{reset(){this.formData={}},search(){this.submit()},async submit(){let e=await this.$bpm.handleVerifySchema({mode:"list",data:this.formData,verifySchema:this.formatedSchema.verifySchema});if(this.formErrors=e,console.log("errors",e),e)return;let t=this.formData;return t=_.pickBy(t,((e,t)=>""!=e)),this.$emit("search",t),t},handleNextRely(e){this.relyHandleList.shift(),_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this);let t=_.head(this.relyHandleList);t&&this.$bpm.$emit("handeInitRely",{id:t,rowIndex:e})},handleRelyById(e,t){let{relyHandleList:r,firstId:s}=this.getRelyHandleList(e);this.relyHandleList=r,s&&this.$bpm.$emit("handeRelyById",{id:s,rowIndex:t})},handleNextRelyById(e){this.relyHandleList.shift(),_.isEmpty(this.relyHandleList)&&this.$bpm.$emit("initRelyComplete",this);let t=_.head(this.relyHandleList);t&&this.$bpm.$emit("handeRelyById",{id:t,rowIndex:e})},getRelyHandleList(e){let t=[];const{breadthFirstSearch:r}=a.Algorithm;let s=null;return r(this.relyGraphData,e,{enter:({current:e,previous:t})=>{},leave:({current:r,previous:a})=>{s||r==e||(s=r),r!=e&&t.push(r)}}),{relyHandleList:t,firstId:s}},addStackArr(e,t){_.each(e,(e=>{t&&_.set(e,"parentId",t),_.set(this.eleMap,e.id,e),this.elementIdList.push(e.id);let r=_.get(e,"linkage.depends",[]),s=_.get(e,"scope.depends",[]),a=_.get(e,"range_remote.depends",[]),o=_.concat(r,s);o=_.concat(o,a),t||(this.penetrationZList=_.concat(this.penetrationZList,o)),e.elements&&this.addStackArr(e.elements,e.id)}))},createTopoGraph(e){_.each(e,(e=>{let t=_.get(e,"linkage.depends",[]),r=_.get(e,"scope.depends",[]),s=_.get(e,"range_remote.depends",[]),a=_.concat(t,r);a=_.concat(a,s);let o=_.cloneDeep(a),n=_.get(this.eleMap,e.id);if(_.each(o,(e=>{_.get(this.eleMap,e)||(_.pullAll(a,[e]),a=_.cloneDeep(a))})),a.length||n.parentId){let t=_.pullAll(this.penetrationZList,[e.id]);this.penetrationZList=_.cloneDeep(t)}_.each(a,(t=>{if(t&&e.id&&_.includes(this.elementIdList,t)){let r=_.get(this.eleMap,t);if(!r)return;r.parentId&&!n.parentId&&(t=r.parentId);let s=n.parentId&&!r.parentId?n.parentId:n.id;if(r.parentId&&n.parentId)return;this.relyArr.push([t,s]),this.relyGraphData.nodes.push(e),this.relyGraphData.nodes.push(r),this.relyGraphData.edges.push({source:t,target:s})}})),e.elements&&this.createTopoGraph(e.elements)}))}}},c=(0,r(4486).A)(i,s,[],!1,null,"3743a4b0",null);c.options.__file="components/lib/bpmFieldsFilter/src/main.vue";var l=c.exports},4486:function(e,t,r){function s(e,t,r,s,a,o,n,i){var c,l="function"==typeof e?e.options:e;if(t&&(l.render=t,l.staticRenderFns=r,l._compiled=!0),s&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),n?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),a&&a.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(n)},l._ssrRegister=c):a&&(c=i?function(){a.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:a),c)if(l.functional){l._injectStyles=c;var d=l.render;l.render=function(e,t){return c.call(t),d(e,t)}}else{var u=l.beforeCreate;l.beforeCreate=u?[].concat(u,c):[c]}return{exports:e,options:l}}r.d(t,{A:function(){return s}})},4419:function(e){e.exports=r},6773:function(t){t.exports=e},5360:function(e){e.exports=t},8343:function(e,t,r){const{normalizeIPv6:s,normalizeIPv4:a,removeDotSegments:o,recomposeAuthority:n,normalizeComponentEncoding:i}=r(4834),c=r(343);function l(e,t,r,s){const a={};return s||(e=h(d(e,r),r),t=h(d(t,r),r)),!(r=r||{}).tolerant&&t.scheme?(a.scheme=t.scheme,a.userinfo=t.userinfo,a.host=t.host,a.port=t.port,a.path=o(t.path||""),a.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(a.userinfo=t.userinfo,a.host=t.host,a.port=t.port,a.path=o(t.path||""),a.query=t.query):(t.path?("/"===t.path.charAt(0)?a.path=o(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?a.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:a.path=t.path:a.path="/"+t.path,a.path=o(a.path)),a.query=t.query):(a.path=e.path,void 0!==t.query?a.query=t.query:a.query=e.query),a.userinfo=e.userinfo,a.host=e.host,a.port=e.port),a.scheme=e.scheme),a.fragment=t.fragment,a}function d(e,t){const r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},s=Object.assign({},t),a=[],i=c[(s.scheme||r.scheme||"").toLowerCase()];i&&i.serialize&&i.serialize(r,s),void 0!==r.path&&(s.skipEscape?r.path=unescape(r.path):(r.path=escape(r.path),void 0!==r.scheme&&(r.path=r.path.split("%3A").join(":")))),"suffix"!==s.reference&&r.scheme&&a.push(r.scheme,":");const l=n(r,s);if(void 0!==l&&("suffix"!==s.reference&&a.push("//"),a.push(l),r.path&&"/"!==r.path.charAt(0)&&a.push("/")),void 0!==r.path){let e=r.path;s.absolutePath||i&&i.absolutePath||(e=o(e)),void 0===l&&(e=e.replace(/^\/\//u,"/%2F")),a.push(e)}return void 0!==r.query&&a.push("?",r.query),void 0!==r.fragment&&a.push("#",r.fragment),a.join("")}const u=Array.from({length:127},((e,t)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(t)))),f=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function h(e,t){const r=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},n=-1!==e.indexOf("%");let i=!1;"suffix"===r.reference&&(e=(r.scheme?r.scheme+":":"")+"//"+e);const l=e.match(f);if(l){if(o.scheme=l[1],o.userinfo=l[3],o.host=l[4],o.port=parseInt(l[5],10),o.path=l[6]||"",o.query=l[7],o.fragment=l[8],isNaN(o.port)&&(o.port=l[5]),o.host){const e=a(o.host);if(!1===e.isIPV4){const t=s(e.host,{isIPV4:!1});o.host=t.host.toLowerCase(),i=t.isIPV6}else o.host=e.host,i=!0}void 0!==o.scheme||void 0!==o.userinfo||void 0!==o.host||void 0!==o.port||o.path||void 0!==o.query?void 0===o.scheme?o.reference="relative":void 0===o.fragment?o.reference="absolute":o.reference="uri":o.reference="same-document",r.reference&&"suffix"!==r.reference&&r.reference!==o.reference&&(o.error=o.error||"URI is not a "+r.reference+" reference.");const e=c[(r.scheme||o.scheme||"").toLowerCase()];if(!(r.unicodeSupport||e&&e.unicodeSupport)&&o.host&&(r.domainHost||e&&e.domainHost)&&!1===i&&function(e){let t=0;for(let r=0,s=e.length;r<s;++r)if(t=e.charCodeAt(r),t>126||u[t])return!0;return!1}(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(e){o.error=o.error||"Host's domain name can not be converted to ASCII: "+e}(!e||e&&!e.skipNormalize)&&(n&&void 0!==o.scheme&&(o.scheme=unescape(o.scheme)),n&&void 0!==o.host&&(o.host=unescape(o.host)),void 0!==o.path&&o.path.length&&(o.path=escape(unescape(o.path))),void 0!==o.fragment&&o.fragment.length&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),e&&e.parse&&e.parse(o,r)}else o.error=o.error||"URI can not be parsed.";return o}const m={SCHEMES:c,normalize:function(e,t){return"string"==typeof e?e=d(h(e,t),t):"object"==typeof e&&(e=h(d(e,t),t)),e},resolve:function(e,t,r){const s=Object.assign({scheme:"null"},r);return d(l(h(e,s),h(t,s),s,!0),{...s,skipEscape:!0})},resolveComponents:l,equal:function(e,t,r){return"string"==typeof e?(e=unescape(e),e=d(i(h(e,r),!0),{...r,skipEscape:!0})):"object"==typeof e&&(e=d(i(e,!0),{...r,skipEscape:!0})),"string"==typeof t?(t=unescape(t),t=d(i(h(t,r),!0),{...r,skipEscape:!0})):"object"==typeof t&&(t=d(i(t,!0),{...r,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()},serialize:d,parse:h};e.exports=m,e.exports.default=m,e.exports.fastUri=m},343:function(e){const t=/^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu,r=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function s(e){return"boolean"==typeof e.secure?e.secure:"wss"===String(e.scheme).toLowerCase()}function a(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function o(e){const t="https"===String(e.scheme).toLowerCase();return e.port!==(t?443:80)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}const n={scheme:"http",domainHost:!0,parse:a,serialize:o},i={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=s(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if(e.port!==(s(e)?443:80)&&""!==e.port||(e.port=void 0),"boolean"==typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,r]=e.resourceName.split("?");e.path=t&&"/"!==t?t:void 0,e.query=r,e.resourceName=void 0}return e.fragment=void 0,e}},c={http:n,https:{scheme:"https",domainHost:n.domainHost,parse:a,serialize:o},ws:i,wss:{scheme:"wss",domainHost:i.domainHost,parse:i.parse,serialize:i.serialize},urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;const s=e.path.match(r);if(s){const r=t.scheme||e.scheme||"urn";e.nid=s[1].toLowerCase(),e.nss=s[2];const a=`${r}:${t.nid||e.nid}`,o=c[a];e.path=void 0,o&&(e=o.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){const r=t.scheme||e.scheme||"urn",s=e.nid.toLowerCase(),a=`${r}:${t.nid||s}`,o=c[a];o&&(e=o.serialize(e,t));const n=e,i=e.nss;return n.path=`${s||t.nid}:${i}`,t.skipEscape=!0,n},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,r){const s=e;return s.uuid=s.nss,s.nss=void 0,r.tolerant||s.uuid&&t.test(s.uuid)||(s.error=s.error||"UUID is not valid."),s},serialize:function(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t},skipNormalize:!0}};e.exports=c},4914:function(e){e.exports={HEX:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15}}},4834:function(e,t,r){const{HEX:s}=r(4914);function a(e){if(c(e,".")<3)return{host:e,isIPV4:!1};const t=e.match(/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/u)||[],[r]=t;return r?{host:i(r,"."),isIPV4:!0}:{host:e,isIPV4:!1}}function o(e,t=!1){let r="",a=!0;for(const t of e){if(void 0===s[t])return;"0"!==t&&!0===a&&(a=!1),a||(r+=t)}return t&&0===r.length&&(r="0"),r}function n(e,t={}){if(c(e,":")<2)return{host:e,isIPV6:!1};const r=function(e){let t=0;const r={error:!1,address:"",zone:""},s=[],a=[];let n=!1,i=!1,c=!1;function l(){if(a.length){if(!1===n){const e=o(a);if(void 0===e)return r.error=!0,!1;s.push(e)}a.length=0}return!0}for(let o=0;o<e.length;o++){const d=e[o];if("["!==d&&"]"!==d)if(":"!==d)if("%"===d){if(!l())break;n=!0}else a.push(d);else{if(!0===i&&(c=!0),!l())break;if(t++,s.push(":"),t>7){r.error=!0;break}o-1>=0&&":"===e[o-1]&&(i=!0)}}return a.length&&(n?r.zone=a.join(""):c?s.push(a.join("")):s.push(o(a))),r.address=s.join(""),r}(e);if(r.error)return{host:e,isIPV6:!1};{let e=r.address,t=r.address;return r.zone&&(e+="%"+r.zone,t+="%25"+r.zone),{host:e,escapedHost:t,isIPV6:!0}}}function i(e,t){let r="",s=!0;const a=e.length;for(let o=0;o<a;o++){const n=e[o];"0"===n&&s?(o+1<=a&&e[o+1]===t||o+1===a)&&(r+=n,s=!1):(s=n===t,r+=n)}return r}function c(e,t){let r=0;for(let s=0;s<e.length;s++)e[s]===t&&r++;return r}const l=/^\.\.?\//u,d=/^\/\.(?:\/|$)/u,u=/^\/\.\.(?:\/|$)/u,f=/^\/?(?:.|\n)*?(?=\/|$)/u;e.exports={recomposeAuthority:function(e,t){const r=[];if(void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host){let t=unescape(e.host);const s=a(t);if(s.isIPV4)t=s.host;else{const r=n(s.host,{isIPV4:!1});t=!0===r.isIPV6?`[${r.escapedHost}]`:e.host}r.push(t)}return"number"!=typeof e.port&&"string"!=typeof e.port||(r.push(":"),r.push(String(e.port))),r.length?r.join(""):void 0},normalizeComponentEncoding:function(e,t){const r=!0!==t?escape:unescape;return void 0!==e.scheme&&(e.scheme=r(e.scheme)),void 0!==e.userinfo&&(e.userinfo=r(e.userinfo)),void 0!==e.host&&(e.host=r(e.host)),void 0!==e.path&&(e.path=r(e.path)),void 0!==e.query&&(e.query=r(e.query)),void 0!==e.fragment&&(e.fragment=r(e.fragment)),e},removeDotSegments:function(e){const t=[];for(;e.length;)if(e.match(l))e=e.replace(l,"");else if(e.match(d))e=e.replace(d,"/");else if(e.match(u))e=e.replace(u,"/"),t.pop();else if("."===e||".."===e)e="";else{const r=e.match(f);if(!r)throw new Error("Unexpected dot segment condition");{const s=r[0];e=e.slice(s.length),t.push(s)}}return t.join("")},normalizeIPv4:a,normalizeIPv6:n,stringArrayToHexStripped:o}},3837:function(e){e.exports=JSON.parse('{"$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON AnySchema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},2079:function(e){e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')}},a={};function o(e){var t=a[e];if(void 0!==t)return t.exports;var r=a[e]={exports:{}};return s[e](r,r.exports,o),r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};o.r(n),o.d(n,{default:function(){return p}});var i=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",["view"===e.mode?r("div",{staticStyle:{display:"flex","max-width":"360px",cursor:"pointer"},attrs:{title:e.value},on:{click:e.openOptionsModal}},[r("span",{staticStyle:{flex:"1"}},[e._v("\n "+e._s(e.label||"--")+"\n ")]),e._v(" "),r("i",{staticClass:"fa fa-angle-right",attrs:{"aria-hidden":"true"}})]):r("div",{staticStyle:{display:"flex","max-width":"360px",cursor:"pointer"},attrs:{title:e.value},on:{click:e.openOptionsModal}},[r("span",{staticStyle:{flex:"1"}},[e._v("\n "+e._s(e.label||(e.loading?""+e.$z("加载中","c.loading"):""+e.$z("请选择","c.please_select")+e.fieldConf.name+"(多选)"))+"\n "),r("span",{directives:[{name:"show",rawName:"v-show",value:e.loading,expression:"loading"}],staticClass:"typing_loader"})]),e._v(" "),r("i",{staticClass:"fa fa-angle-right",attrs:{"aria-hidden":"true"}})]),e._v(" "),r("el-dialog",{attrs:{title:e.fieldConf.name,visible:e.optionsModalShow,width:"50%",top:"10vh","custom-class":"bpm-select-entrance-form"},on:{"update:visible":function(t){e.optionsModalShow=t},close:e.handleClose}},[r("div",{staticClass:"main-wrap",style:{maxHeight:"70vh",overflow:"auto"}},["view"===e.mode?e._l(e.items,(function(t){return r("el-card",{key:t.form_id,staticClass:"select-option-card",attrs:{shadow:"hover","body-style":{padding:"10px 20px"}}},[r("div",{attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.title))])]),e._v(" "),r("div",{staticClass:"card-body-content"},[r("div",[r("span",{staticClass:"bpm-status_tag-status",style:{background:e.getStatus(t.f_fields[e.statusField.id],"color")}},[e._v(e._s(e.getStatus(t.f_fields[e.statusField.id],"label")))])]),e._v(" "),e._l(e.descFields,(function(s){return r("div",{key:s.id},[r("label",{staticClass:"label"},[e._v(e._s(s.name))]),e._v(" "),r("span",[e._v(e._s(t.f_fields[s.id]))])])}))],2)])})):[r("div",{staticClass:"search-wrap"},[e.enableSearchText?r("el-input",{attrs:{placeholder:e.$z("搜索","c.search_tip")},on:{input:e.debounceSearch},model:{value:e.keyword,callback:function(t){e.keyword=t},expression:"keyword"}},[r("i",{staticClass:"el-input__icon el-icon-search",staticStyle:{cursor:"pointer"},attrs:{slot:"suffix"},on:{click:e.debounceSearch},slot:"suffix"})]):e._e(),e._v(" "),r("el-button",{staticStyle:{"margin-left":"10px"},on:{click:function(t){e.filterModalShow=!0}}},[r("i",{staticClass:"fa fa-filter",attrs:{"aria-hidden":"true"}})])],1),e._v(" "),r("ul",{directives:[{name:"infinite-scroll",rawName:"v-infinite-scroll",value:e.loadMore,expression:"loadMore"}],staticClass:"edit-list"},[r("el-checkbox-group",{model:{value:e.selectedVals,callback:function(t){e.selectedVals=t},expression:"selectedVals"}},e._l(e.items,(function(t){return r("li",{key:t.form_id,staticClass:"edit-list-item"},[r("el-checkbox",{staticClass:"checkbox",attrs:{label:t.id}},[e._v(e._s())]),e._v(" "),r("el-card",{key:t.form_id,staticClass:"select-option-card",attrs:{shadow:"hover","body-style":{padding:"10px 20px"}}},[r("div",{attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.title))])]),e._v(" "),r("div",{staticClass:"card-body-content"},[r("div",[r("span",{staticClass:"bpm-status_tag-status",style:{background:e.getStatus(t.f_fields[e.statusField.id],"color")}},[e._v(e._s(e.getStatus(t.f_fields[e.statusField.id],"label")))])]),e._v(" "),e._l(e.descFields,(function(s){return r("div",{key:s.id},[r("label",{staticClass:"label"},[e._v(e._s(s.name))]),e._v(" "),r("span",[e._v(e._s(t.f_fields[s.id]))])])}))],2)])],1)})),0)],1)],e._v(" "),r("div",{directives:[{name:"show",rawName:"v-show",value:e.optionsLoading,expression:"optionsLoading"}],staticStyle:{"text-align":"center",margin:"46px auto"}},[r("span",{staticClass:"typing_loader"})]),e._v(" "),e.optionsLoading||e.items.length?e._e():r("div",[e._v("\n "+e._s(e.$z("暂无记录信息","c.no_record"))+"\n ")])],2),e._v(" "),"edit"===e.mode?r("footer",{staticClass:"footer",attrs:{slot:"footer"},slot:"footer"},[r("div",[r("el-checkbox",{attrs:{label:e.$z("全选","c.select_all")},on:{change:e.handleCheckAll},model:{value:e.checkAll,callback:function(t){e.checkAll=t},expression:"checkAll"}}),e._v(" "),e.selectedLabel?r("span",{staticClass:"subtext"},[e._v(e._s(e.selectedLabel))]):e._e()],1),e._v(" "),r("el-button",{staticClass:"width-button",attrs:{type:"primary",disabled:!e.selectedVals.length},on:{click:e.onSubmit}},[e._v(e._s(e.$z("保存","c.save")))])],1):e._e()]),e._v(" "),r("el-dialog",{attrs:{title:e.$z("数据筛选","b2.common.data_filter"),visible:e.filterModalShow,width:"50%","custom-class":"bpm-select-entrance-form"},on:{"update:visible":function(t){e.filterModalShow=t},close:function(t){e.filterModalShow=!1}}},[r("div",{staticStyle:{"max-height":"70vh",overflow:"auto"}},[r("BpmFieldsFilter",{ref:"searchForm",attrs:{searchSchema:e.searchSchema,verifySchema:e.verifySchema,orgInfo:e.orgInfo,formDefId:e.formSchema.id,showAll:!0,queryExclude:!0},on:{search:e.handleFilterReady}})],1),e._v(" "),r("span",{attrs:{slot:"footer"},slot:"footer"},[r("el-button",{staticClass:"width-button",on:{click:e.handleResetFilter}},[e._v(e._s(e.$z("重置","c.reset")))]),e._v(" "),r("el-button",{staticClass:"width-button",attrs:{type:"primary"},on:{click:e.handleSubmitFilter}},[e._v(e._s(e.$z("查询","c.query")))])],1)])],1)};i._withStripped=!0;var c=o(5281),l=o(9795),d=o(555);const u=["Area","MulArea"];var f={name:"BpmSelectEntranceForm",components:{BpmFieldsFilter:d.A},props:{value:{type:Array,default(){return[]}},type:{type:String,default:"MulSelectEntranceForm"},fieldConf:{type:Object,default(){return{}}},mode:{type:String,default:"view"},uiType:{type:String,default:"default"},formDefId:{type:String,default:""},orgInfo:{type:Object,default(){return{level:"group",level_id:0,group_id:0}}},formId:{type:String,default:""},dm:{type:Boolean,default(){return!1}},isMultiple:{type:Boolean,default(){return!0}}},data(){return{loading:!1,optionsModalShow:!1,items:[],selectedItems:[],selectedVals:[],optionsLoading:!1,statusField:{},descFields:[],shouldTransLabelKeys:[],formSchema:{},pagination:{action:"first",lastAt:null,total:0},checkAll:!1,filterModalShow:!1,searchSchema:{elements:[]},verifySchema:{},enableSearchText:!0,debounceSearch:_.debounce(_.bind(this.loadData,this),300,{trailing:!0,leading:!1}),keyword:"",filterParams:{}}},computed:{isMobile(){return(0,l.Fr)()},label(){const e=this.value;if(!e||!e.length)return"";let t=zj.z("已选择N条","c.number_is_selected");return _.template(t)({count:e.length})},selectedLabel(){if(!this.selectedVals.length)return"";let e=zj.z("选中N条","c.number_is_selected_2");return _.template(e)({count:this.selectedVals.length})}},methods:{getStatus(e,t){return((this.statusField.rangeEnumMap||{})[e]||{})[t]},async openOptionsModal(){this.optionsModalShow=!0,this.formSchema.id||await this.loadSchema(),this.value&&this.value.length&&await this.loadListSelected(),"edit"===this.mode&&(this.pagination.lastAt||(this.handleResetFilter(),this.loadData()),this.selectedVals=this.value||[])},handleClose(){this.optionsModalShow=!1,"edit"===this.mode&&(this.checkAll=!1,this.selectedVals=[])},handleResetFilter(){this.$refs.searchForm&&this.$refs.searchForm.reset()},handleSubmitFilter(){this.$refs.searchForm&&this.$refs.searchForm.submit()},handleFilterReady(e){this.filterParams=e||{},this.filterModalShow=!1,this.loadData()},handleCheckAll(e){this.selectedVals=e?_.map(this.items,(e=>e.id)):[]},onSubmit(){const e=_.cloneDeep(this.selectedVals);this.$emit("input",e),this.$emit("change",e),this.handleClose()},loadMore(){this.items.length<this.pagination.total&&this.loadData("next")},async loadData(e="first"){let t=this.formDefId;const r=this.fieldConf.id;e=["first","next","last","prev"].includes(e)?e:"first";let s=this.filterParams;this.keyword&&(s.q__contains=this.keyword),this.optionsLoading=!0;const a=(await c.A.assistSelectEntranceForm.getOptions(this.$bpm,{formDefId:t,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},{action:e,limit:20,last_at:"first"===e?null:this.pagination.lastAt,fields:JSON.stringify(s)})).data.data;console.log("assist_select_entrance_form data: ",a);const o=_.map(a.data,(e=>(_.each(e.f_fields,(async(t,r)=>{if(this.shouldTransLabelKeys.includes(r))if(_.isArray(t)){const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.loads(...t);e.f_fields[r]=a.join(zj.z(",","c.comma"))}else{const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.load(t);e.f_fields[r]=a}})),{title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:_.map(e.f_fields,((e,t)=>({key:t,value:e})))})));let n=o;if(this.selectedItems.length){let e=_.map(this.selectedItems,(e=>e.id));n=_.filter(o,(t=>!e.includes(t.id)))}this.items="next"===e?_.concat(this.items,n):_.concat(this.selectedItems,n),this.pagination.action=e,this.pagination.lastAt=a.last_at,this.pagination.total=a.count,this.optionsLoading=!1},async loadListSelected(){let e=this.formId;e=encodeURIComponent(e);let t=this.formDefId;const r=this.fieldConf.id;this.optionsLoading=!0;try{const s=(await c.A.assistSelectEntranceForm.getListSelected(this.$bpm,{formDefId:t,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},{form_id:e})).data.data;console.log("assist_select_entrance_form list_selected: ",s);const a=_.map(s.data,(e=>(_.each(e.f_fields,(async(t,r)=>{if(this.shouldTransLabelKeys.includes(r))if(_.isArray(t)){const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.loads(...t);e.f_fields[r]=a.join(zj.z(",","c.comma"))}else{const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.load(t);e.f_fields[r]=a}})),{title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:_.map(e.f_fields,((e,t)=>({key:t,value:e})))})));this.selectedItems=a,"view"===this.mode&&(this.items=a)}finally{this.optionsLoading=!1}},async loadSchema(){let e=this.formDefId;const t=this.fieldConf.id,r=(await c.A.assistSelectEntranceForm.getListDefinition(this.$bpm,{formDefId:e,fieldDefId:t,orgInfo:this.orgInfo,isDm:this.dm})).data.data;console.log("assist_select_entrance_form definition: ",r);let s={},a=[],o=[];_.each(r.definition.form.elements,(e=>{if("Status"!==e.type)a.push({id:e.id,name:e.name,value_type:e.value_type,type:e.type});else{let t={};e.range_enum.forEach((e=>{t[e[0]]={value:e[0],label:e[1],color:e[2]}})),s={id:e.id,name:e.name,value_type:e.value_type,type:e.type,rangeEnumMap:t}}(u.includes(e.type)||e.type.indexOf("Select")>-1)&&o.push(e.id)})),this.descFields=a,this.statusField=s,this.shouldTransLabelKeys=o,this.formSchema=r.definition.form,this.searchSchema=_.get(r,"definition.search",{elements:[]}),this.verifySchema=_.get(r,"schema.search",{});const n=!!this.searchSchema.elements&&_.find(this.searchSchema.elements,{id:"q__contains"});this.enableSearchText=this.searchSchema.enable_search_text&&n}}},h=(0,o(4486).A)(f,i,[],!1,null,null,null);h.options.__file="components/lib/bpmSelectEntranceForm/src/main.vue";var m=h.exports;m.install=function(e){e.component(m.name,m)};var p=m;return n}()}));
7
+ deps: ${r}}`};const n={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){const[t,r]=function({schema:e}){const t={},r={};for(const s in e)"__proto__"!==s&&((Array.isArray(e[s])?t:r)[s]=e[s]);return[t,r]}(e);i(e,t),c(e,r)}};function i(e,t=e.schema){const{gen:r,data:a,it:n}=e;if(0===Object.keys(t).length)return;const i=r.let("missing");for(const c in t){const l=t[c];if(0===l.length)continue;const d=(0,o.propertyInData)(r,a,c,n.opts.ownProperties);e.setParams({property:c,depsCount:l.length,deps:l.join(", ")}),n.allErrors?r.if(d,(()=>{for(const t of l)(0,o.checkReportMissingProp)(e,t)})):(r.if(s._`${d} && (${(0,o.checkMissingProp)(e,l,i)})`),(0,o.reportMissingProp)(e,i),r.else())}}function c(e,t=e.schema){const{gen:r,data:s,keyword:n,it:i}=e,c=r.name("valid");for(const l in t)(0,a.alwaysValidSchema)(i,t[l])||(r.if((0,o.propertyInData)(r,s,l,i.opts.ownProperties),(()=>{const t=e.subschema({keyword:n,schemaProp:l},c);e.mergeValidEvaluated(t,c)}),(()=>r.var(c,!0))),e.ok(c))}t.validatePropertyDeps=i,t.validateSchemaDeps=c,t.default=n},3282:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const s=r(4042),a=r(6144),o=r(6653),n=r(2079),i=["/properties"],c="http://json-schema.org/draft-07/schema";class l extends s.default{_addVocabularies(){super._addVocabularies(),a.default.forEach((e=>this.addVocabulary(e))),this.opts.discriminator&&this.addKeyword(o.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const e=this.opts.$data?this.$dataMetaSchema(n,i):n;this.addMetaSchema(e,c,!1),this.refs["http://json-schema.org/schema"]=c}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(c)?c:void 0)}}t.Ajv=l,e.exports=t=l,e.exports.Ajv=l,Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var d=r(2586);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return d.KeywordCxt}});var u=r(9029);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return u._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return u.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return u.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return u.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return u.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return u.CodeGen}});var f=r(3558);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return f.default}});var h=r(4551);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return h.default}})},3439:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:e})=>s.str`must be multiple of ${e}`,params:({schemaCode:e})=>s._`{multipleOf: ${e}}`},code(e){const{gen:t,data:r,schemaCode:a,it:o}=e,n=o.opts.multipleOfPrecision,i=t.let("res"),c=n?s._`Math.abs(Math.round(${i}) - ${i}) > 1e-${n}`:s._`${i} !== parseInt(${i})`;e.fail$data(s._`(${a} === 0 || (${i} = ${r}/${a}, ${c}))`)}};t.default=a},3463:function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};t.default=r},3558:function(e,t){Object.defineProperty(t,"__esModule",{value:!0});class r extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}t.default=r},3673:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;const s=r(9029),a=r(2023),o=r(5765),n=r(8708);function i(e){const{gen:t,data:r,it:a}=e;t.if(a.parentData,(()=>t.assign(r,s._`${a.parentData}[${a.parentDataProperty}]`)))}function c(e,t,r){if(void 0===r)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof r?{ref:r}:{ref:r,code:(0,s.stringify)(r)})}t.macroKeywordCode=function(e,t){const{gen:r,keyword:a,schema:o,parentSchema:n,it:i}=e,l=t.macro.call(i.self,o,n,i),d=c(r,a,l);!1!==i.opts.validateSchema&&i.self.validateSchema(l,!0);const u=r.name("valid");e.subschema({schema:l,schemaPath:s.nil,errSchemaPath:`${i.errSchemaPath}/${a}`,topSchemaRef:d,compositeRule:!0},u),e.pass(u,(()=>e.error(!0)))},t.funcKeywordCode=function(e,t){var r;const{gen:l,keyword:d,schema:u,parentSchema:f,$data:h,it:m}=e;!function({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}(m,t);const p=!h&&t.compile?t.compile.call(m.self,u,f,m):t.validate,y=c(l,d,p),g=l.let("valid");function v(r=(t.async?s._`await `:s.nil)){const n=m.opts.passContext?a.default.this:a.default.self,i=!("compile"in t&&!h||!1===t.schema);l.assign(g,s._`${r}${(0,o.callValidateCode)(e,y,n,i)}`,t.modifying)}function _(e){var r;l.if((0,s.not)(null!==(r=t.valid)&&void 0!==r?r:g),e)}e.block$data(g,(function(){if(!1===t.errors)v(),t.modifying&&i(e),_((()=>e.error()));else{const r=t.async?function(){const e=l.let("ruleErrs",null);return l.try((()=>v(s._`await `)),(t=>l.assign(g,!1).if(s._`${t} instanceof ${m.ValidationError}`,(()=>l.assign(e,s._`${t}.errors`)),(()=>l.throw(t))))),e}():function(){const e=s._`${y}.errors`;return l.assign(e,null),v(s.nil),e}();t.modifying&&i(e),_((()=>function(e,t){const{gen:r}=e;r.if(s._`Array.isArray(${t})`,(()=>{r.assign(a.default.vErrors,s._`${a.default.vErrors} === null ? ${t} : ${a.default.vErrors}.concat(${t})`).assign(a.default.errors,s._`${a.default.vErrors}.length`),(0,n.extendErrors)(e)}),(()=>e.error()))}(e,r)))}})),e.ok(null!==(r=t.valid)&&void 0!==r?r:g)},t.validSchemaType=function(e,t,r=!1){return!t.length||t.some((t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||r&&void 0===e))},t.validateKeywordUsage=function({schema:e,opts:t,self:r,errSchemaPath:s},a,o){if(Array.isArray(a.keyword)?!a.keyword.includes(o):a.keyword!==o)throw new Error("ajv implementation error");const n=a.dependencies;if(null==n?void 0:n.some((t=>!Object.prototype.hasOwnProperty.call(e,t))))throw new Error(`parent schema must have dependencies of ${o}: ${n.join(",")}`);if(a.validateSchema&&!a.validateSchema(e[o])){const e=`keyword "${o}" value is invalid at path "${s}": `+r.errorsText(a.validateSchema.errors);if("log"!==t.validateSchema)throw new Error(e);r.logger.error(e)}}},3693:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;const s=r(4551),a=r(5765),o=r(9029),n=r(2023),i=r(3835),c=r(4227),l={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:r,it:a}=e,{baseId:n,schemaEnv:c,validateName:l,opts:f,self:h}=a,{root:m}=c;if(("#"===r||"#/"===r)&&n===m.baseId)return function(){if(c===m)return u(e,l,c,c.$async);const r=t.scopeValue("root",{ref:m});return u(e,o._`${r}.validate`,m,m.$async)}();const p=i.resolveRef.call(h,m,n,r);if(void 0===p)throw new s.default(a.opts.uriResolver,n,r);return p instanceof i.SchemaEnv?function(t){const r=d(e,t);u(e,r,t,t.$async)}(p):function(s){const a=t.scopeValue("schema",!0===f.code.source?{ref:s,code:(0,o.stringify)(s)}:{ref:s}),n=t.name("valid"),i=e.subschema({schema:s,dataTypes:[],schemaPath:o.nil,topSchemaRef:a,errSchemaPath:r},n);e.mergeEvaluated(i),e.ok(n)}(p)}};function d(e,t){const{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):o._`${r.scopeValue("wrapper",{ref:t})}.validate`}function u(e,t,r,s){const{gen:i,it:l}=e,{allErrors:d,schemaEnv:u,opts:f}=l,h=f.passContext?n.default.this:o.nil;function m(e){const t=o._`${e}.errors`;i.assign(n.default.vErrors,o._`${n.default.vErrors} === null ? ${t} : ${n.default.vErrors}.concat(${t})`),i.assign(n.default.errors,o._`${n.default.vErrors}.length`)}function p(e){var t;if(!l.opts.unevaluated)return;const s=null===(t=null==r?void 0:r.validate)||void 0===t?void 0:t.evaluated;if(!0!==l.props)if(s&&!s.dynamicProps)void 0!==s.props&&(l.props=c.mergeEvaluated.props(i,s.props,l.props));else{const t=i.var("props",o._`${e}.evaluated.props`);l.props=c.mergeEvaluated.props(i,t,l.props,o.Name)}if(!0!==l.items)if(s&&!s.dynamicItems)void 0!==s.items&&(l.items=c.mergeEvaluated.items(i,s.items,l.items));else{const t=i.var("items",o._`${e}.evaluated.items`);l.items=c.mergeEvaluated.items(i,t,l.items,o.Name)}}s?function(){if(!u.$async)throw new Error("async schema referenced by sync schema");const r=i.let("valid");i.try((()=>{i.code(o._`await ${(0,a.callValidateCode)(e,t,h)}`),p(t),d||i.assign(r,!0)}),(e=>{i.if(o._`!(${e} instanceof ${l.ValidationError})`,(()=>i.throw(e))),m(e),d||i.assign(r,!1)})),e.ok(r)}():e.result((0,a.callValidateCode)(e,t,h),(()=>p(t)),(()=>m(t)))}t.getValidate=d,t.callRef=u,t.default=l},3835:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;const s=r(9029),a=r(3558),o=r(2023),n=r(6939),i=r(4227),c=r(2586);class l{constructor(e){var t;let r;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(r=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!==(t=e.baseId)&&void 0!==t?t:(0,n.normalizeId)(null==r?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null==r?void 0:r.$async,this.refs={}}}function d(e){const t=f.call(this,e);if(t)return t;const r=(0,n.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:i,lines:l}=this.opts.code,{ownProperties:d}=this.opts,u=new s.CodeGen(this.scope,{es5:i,lines:l,ownProperties:d});let h;e.$async&&(h=u.scopeValue("Error",{ref:a.default,code:s._`require("ajv/dist/runtime/validation_error").default`}));const m=u.scopeName("validate");e.validateName=m;const p={gen:u,allErrors:this.opts.allErrors,data:o.default.data,parentData:o.default.parentData,parentDataProperty:o.default.parentDataProperty,dataNames:[o.default.data],dataPathArr:[s.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:u.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,s.stringify)(e.schema)}:{ref:e.schema}),validateName:m,ValidationError:h,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:s.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:s._`""`,opts:this.opts,self:this};let y;try{this._compilations.add(e),(0,c.validateFunctionCode)(p),u.optimize(this.opts.code.optimize);const t=u.toString();y=`${u.scopeRefs(o.default.scope)}return ${t}`,this.opts.code.process&&(y=this.opts.code.process(y,e));const r=new Function(`${o.default.self}`,`${o.default.scope}`,y)(this,this.scope.get());if(this.scope.value(m,{ref:r}),r.errors=null,r.schema=e.schema,r.schemaEnv=e,e.$async&&(r.$async=!0),!0===this.opts.code.source&&(r.source={validateName:m,validateCode:t,scopeValues:u._values}),this.opts.unevaluated){const{props:e,items:t}=p;r.evaluated={props:e instanceof s.Name?void 0:e,items:t instanceof s.Name?void 0:t,dynamicProps:e instanceof s.Name,dynamicItems:t instanceof s.Name},r.source&&(r.source.evaluated=(0,s.stringify)(r.evaluated))}return e.validate=r,e}catch(t){throw delete e.validate,delete e.validateName,y&&this.logger.error("Error compiling schema, function code:",y),t}finally{this._compilations.delete(e)}}function u(e){return(0,n.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:d.call(this,e)}function f(e){for(const s of this._compilations)if(r=e,(t=s).schema===r.schema&&t.root===r.root&&t.baseId===r.baseId)return s;var t,r}function h(e,t){let r;for(;"string"==typeof(r=this.refs[t]);)t=r;return r||this.schemas[t]||m.call(this,e,t)}function m(e,t){const r=this.opts.uriResolver.parse(t),s=(0,n._getFullPath)(this.opts.uriResolver,r);let a=(0,n.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&s===a)return y.call(this,r,e);const o=(0,n.normalizeId)(s),i=this.refs[o]||this.schemas[o];if("string"==typeof i){const t=m.call(this,e,i);if("object"!=typeof(null==t?void 0:t.schema))return;return y.call(this,r,t)}if("object"==typeof(null==i?void 0:i.schema)){if(i.validate||d.call(this,i),o===(0,n.normalizeId)(t)){const{schema:t}=i,{schemaId:r}=this.opts,s=t[r];return s&&(a=(0,n.resolveUrl)(this.opts.uriResolver,a,s)),new l({schema:t,schemaId:r,root:e,baseId:a})}return y.call(this,r,i)}}t.SchemaEnv=l,t.compileSchema=d,t.resolveRef=function(e,t,r){var s;r=(0,n.resolveUrl)(this.opts.uriResolver,t,r);const a=e.refs[r];if(a)return a;let o=h.call(this,e,r);if(void 0===o){const a=null===(s=e.localRefs)||void 0===s?void 0:s[r],{schemaId:n}=this.opts;a&&(o=new l({schema:a,schemaId:n,root:e,baseId:t}))}return void 0!==o?e.refs[r]=u.call(this,o):void 0},t.getCompilingSchema=f,t.resolveSchema=m;const p=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function y(e,{baseId:t,schema:r,root:s}){var a;if("/"!==(null===(a=e.fragment)||void 0===a?void 0:a[0]))return;for(const s of e.fragment.slice(1).split("/")){if("boolean"==typeof r)return;const e=r[(0,i.unescapeFragment)(s)];if(void 0===e)return;const a="object"==typeof(r=e)&&r[this.opts.schemaId];!p.has(s)&&a&&(t=(0,n.resolveUrl)(this.opts.uriResolver,t,a))}let o;if("boolean"!=typeof r&&r.$ref&&!(0,i.schemaHasRulesButRef)(r,this.RULES)){const e=(0,n.resolveUrl)(this.opts.uriResolver,t,r.$ref);o=m.call(this,s,e)}const{schemaId:c}=this.opts;return o=o||new l({schema:r,schemaId:c,root:s,baseId:t}),o.schema!==o.root.schema?o:void 0}},3837:function(e){e.exports=JSON.parse('{"$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON AnySchema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},3853:function(e,t){function r(e){const t=e.length;let r,s=0,a=0;for(;a<t;)s++,r=e.charCodeAt(a++),r>=55296&&r<=56319&&a<t&&(r=e.charCodeAt(a),56320==(64512&r)&&a++);return s}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.code='require("ajv/dist/runtime/ucs2length").default'},3966:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(5765),n=r(5457),i={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:e}})=>s.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>s._`{limit: ${e}}`},code(e){const{schema:t,parentSchema:r,it:s}=e,{prefixItems:i}=r;s.items=!0,(0,a.alwaysValidSchema)(s,t)||(i?(0,n.validateAdditionalItems)(e,i):e.ok((0,o.validateArray)(e)))}};t.default=i},4003:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(4227),n={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:e}})=>a.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>a._`{missingProperty: ${e}}`},code(e){const{gen:t,schema:r,schemaCode:n,data:i,$data:c,it:l}=e,{opts:d}=l;if(!c&&0===r.length)return;const u=r.length>=d.loopRequired;if(l.allErrors?function(){if(u||c)e.block$data(a.nil,f);else for(const t of r)(0,s.checkReportMissingProp)(e,t)}():function(){const o=t.let("missing");if(u||c){const r=t.let("valid",!0);e.block$data(r,(()=>function(r,o){e.setParams({missingProperty:r}),t.forOf(r,n,(()=>{t.assign(o,(0,s.propertyInData)(t,i,r,d.ownProperties)),t.if((0,a.not)(o),(()=>{e.error(),t.break()}))}),a.nil)}(o,r))),e.ok(r)}else t.if((0,s.checkMissingProp)(e,r,o)),(0,s.reportMissingProp)(e,o),t.else()}(),d.strictRequired){const t=e.parentSchema.properties,{definedProperties:s}=e.it;for(const e of r)if(void 0===(null==t?void 0:t[e])&&!s.has(e)){const t=`required property "${e}" is not defined at "${l.schemaEnv.baseId+l.errSchemaPath}" (strictRequired)`;(0,o.checkStrictMode)(l,t,l.opts.strictRequired)}}function f(){t.forOf("prop",n,(r=>{e.setParams({missingProperty:r}),t.if((0,s.noPropertyInData)(t,i,r,d.ownProperties),(()=>e.error()))}))}}};t.default=n},4042:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var s=r(2586);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return s.KeywordCxt}});var a=r(9029);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return a._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return a.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return a.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return a.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return a.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return a.CodeGen}});const o=r(3558),n=r(4551),i=r(396),c=r(3835),l=r(9029),d=r(6939),u=r(208),f=r(4227),h=r(3837),m=r(5944),p=(e,t)=>new RegExp(e,t);p.code="new RegExp";const y=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};function $(e){var t,r,s,a,o,n,i,c,l,d,u,f,h,y,g,v,_,$,w,b,S,P,E,k,I;const j=e.strict,N=null===(t=e.code)||void 0===t?void 0:t.optimize,x=!0===N||void 0===N?1:N||0,C=null!==(s=null===(r=e.code)||void 0===r?void 0:r.regExp)&&void 0!==s?s:p,O=null!==(a=e.uriResolver)&&void 0!==a?a:m.default;return{strictSchema:null===(n=null!==(o=e.strictSchema)&&void 0!==o?o:j)||void 0===n||n,strictNumbers:null===(c=null!==(i=e.strictNumbers)&&void 0!==i?i:j)||void 0===c||c,strictTypes:null!==(d=null!==(l=e.strictTypes)&&void 0!==l?l:j)&&void 0!==d?d:"log",strictTuples:null!==(f=null!==(u=e.strictTuples)&&void 0!==u?u:j)&&void 0!==f?f:"log",strictRequired:null!==(y=null!==(h=e.strictRequired)&&void 0!==h?h:j)&&void 0!==y&&y,code:e.code?{...e.code,optimize:x,regExp:C}:{optimize:x,regExp:C},loopRequired:null!==(g=e.loopRequired)&&void 0!==g?g:200,loopEnum:null!==(v=e.loopEnum)&&void 0!==v?v:200,meta:null===(_=e.meta)||void 0===_||_,messages:null===($=e.messages)||void 0===$||$,inlineRefs:null===(w=e.inlineRefs)||void 0===w||w,schemaId:null!==(b=e.schemaId)&&void 0!==b?b:"$id",addUsedSchema:null===(S=e.addUsedSchema)||void 0===S||S,validateSchema:null===(P=e.validateSchema)||void 0===P||P,validateFormats:null===(E=e.validateFormats)||void 0===E||E,unicodeRegExp:null===(k=e.unicodeRegExp)||void 0===k||k,int32range:null===(I=e.int32range)||void 0===I||I,uriResolver:O}}class w{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...$(e)};const{es5:t,lines:r}=this.opts.code;this.scope=new l.ValueScope({scope:{},prefixes:g,es5:t,lines:r}),this.logger=function(e){if(!1===e)return j;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}(e.logger);const s=e.validateFormats;e.validateFormats=!1,this.RULES=(0,i.getRules)(),b.call(this,v,e,"NOT SUPPORTED"),b.call(this,_,e,"DEPRECATED","warn"),this._metaOpts=I.call(this),e.formats&&E.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&k.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),P.call(this),e.validateFormats=s}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:e,meta:t,schemaId:r}=this.opts;let s=h;"id"===r&&(s={...h},s.id=s.$id,delete s.$id),t&&e&&this.addMetaSchema(s,s[r],!1)}defaultMeta(){const{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let r;if("string"==typeof e){if(r=this.getSchema(e),!r)throw new Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);const s=r(t);return"$async"in r||(this.errors=r.errors),s}compile(e,t){const r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw new Error("options.loadSchema should be a function");const{loadSchema:r}=this.opts;return s.call(this,e,t);async function s(e,t){await a.call(this,e.$schema);const r=this._addSchema(e,t);return r.validate||o.call(this,r)}async function a(e){e&&!this.getSchema(e)&&await s.call(this,{$ref:e},!0)}async function o(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof n.default))throw t;return i.call(this,t),await c.call(this,t.missingSchema),o.call(this,e)}}function i({missingSchema:e,missingRef:t}){if(this.refs[e])throw new Error(`AnySchema ${e} is loaded but ${t} cannot be resolved`)}async function c(e){const r=await l.call(this,e);this.refs[e]||await a.call(this,r.$schema),this.refs[e]||this.addSchema(r,e,t)}async function l(e){const t=this._loading[e];if(t)return t;try{return await(this._loading[e]=r(e))}finally{delete this._loading[e]}}}addSchema(e,t,r,s=this.opts.validateSchema){if(Array.isArray(e)){for(const t of e)this.addSchema(t,void 0,r,s);return this}let a;if("object"==typeof e){const{schemaId:t}=this.opts;if(a=e[t],void 0!==a&&"string"!=typeof a)throw new Error(`schema ${t} must be string`)}return t=(0,d.normalizeId)(t||a),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,s,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){if("boolean"==typeof e)return!0;let r;if(r=e.$schema,void 0!==r&&"string"!=typeof r)throw new Error("$schema must be a string");if(r=r||this.opts.defaultMeta||this.defaultMeta(),!r)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const s=this.validate(r,e);if(!s&&t){const e="schema is invalid: "+this.errorsText();if("log"!==this.opts.validateSchema)throw new Error(e);this.logger.error(e)}return s}getSchema(e){let t;for(;"string"==typeof(t=S.call(this,e));)e=t;if(void 0===t){const{schemaId:r}=this.opts,s=new c.SchemaEnv({schema:{},schemaId:r});if(t=c.resolveSchema.call(this,s,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const t=S.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{const t=e;this._cache.delete(t);let r=e[this.opts.schemaId];return r&&(r=(0,d.normalizeId)(r),delete this.schemas[r],delete this.refs[r]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(const t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if("string"==typeof e)r=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r);else{if("object"!=typeof e||void 0!==t)throw new Error("invalid addKeywords parameters");if(r=(t=e).keyword,Array.isArray(r)&&!r.length)throw new Error("addKeywords: keyword must be string or non-empty array")}if(x.call(this,r,t),!t)return(0,f.eachItem)(r,(e=>C.call(this,e))),this;T.call(this,t);const s={...t,type:(0,u.getJSONTypes)(t.type),schemaType:(0,u.getJSONTypes)(t.schemaType)};return(0,f.eachItem)(r,0===s.type.length?e=>C.call(this,e,s):e=>s.type.forEach((t=>C.call(this,e,s,t)))),this}getKeyword(e){const t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){const{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(const r of t.rules){const t=r.rules.findIndex((t=>t.keyword===e));t>=0&&r.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){return e&&0!==e.length?e.map((e=>`${r}${e.instancePath} ${e.message}`)).reduce(((e,r)=>e+t+r)):"No errors"}$dataMetaSchema(e,t){const r=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(const s of t){const t=s.split("/").slice(1);let a=e;for(const e of t)a=a[e];for(const e in r){const t=r[e];if("object"!=typeof t)continue;const{$data:s}=t.definition,o=a[e];s&&o&&(a[e]=R(o))}}return e}_removeAllSchemas(e,t){for(const r in e){const s=e[r];t&&!t.test(r)||("string"==typeof s?delete e[r]:s&&!s.meta&&(this._cache.delete(s.schema),delete e[r]))}}_addSchema(e,t,r,s=this.opts.validateSchema,a=this.opts.addUsedSchema){let o;const{schemaId:n}=this.opts;if("object"==typeof e)o=e[n];else{if(this.opts.jtd)throw new Error("schema must be object");if("boolean"!=typeof e)throw new Error("schema must be object or boolean")}let i=this._cache.get(e);if(void 0!==i)return i;r=(0,d.normalizeId)(o||r);const l=d.getSchemaRefs.call(this,e,r);return i=new c.SchemaEnv({schema:e,schemaId:n,meta:t,baseId:r,localRefs:l}),this._cache.set(i.schema,i),a&&!r.startsWith("#")&&(r&&this._checkUnique(r),this.refs[r]=i),s&&this.validateSchema(e,!0),i}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):c.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){const t=this.opts;this.opts=this._metaOpts;try{c.compileSchema.call(this,e)}finally{this.opts=t}}}function b(e,t,r,s="error"){for(const a in e){const o=a;o in t&&this.logger[s](`${r}: option ${a}. ${e[o]}`)}}function S(e){return e=(0,d.normalizeId)(e),this.schemas[e]||this.refs[e]}function P(){const e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(const t in e)this.addSchema(e[t],t)}function E(){for(const e in this.opts.formats){const t=this.opts.formats[e];t&&this.addFormat(e,t)}}function k(e){if(Array.isArray(e))this.addVocabulary(e);else{this.logger.warn("keywords option as map is deprecated, pass array");for(const t in e){const r=e[t];r.keyword||(r.keyword=t),this.addKeyword(r)}}}function I(){const e={...this.opts};for(const t of y)delete e[t];return e}w.ValidationError=o.default,w.MissingRefError=n.default,t.default=w;const j={log(){},warn(){},error(){}},N=/^[a-z_$][a-z0-9_$:-]*$/i;function x(e,t){const{RULES:r}=this;if((0,f.eachItem)(e,(e=>{if(r.keywords[e])throw new Error(`Keyword ${e} is already defined`);if(!N.test(e))throw new Error(`Keyword ${e} has invalid name`)})),t&&t.$data&&!("code"in t)&&!("validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function C(e,t,r){var s;const a=null==t?void 0:t.post;if(r&&a)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:o}=this;let n=a?o.post:o.rules.find((({type:e})=>e===r));if(n||(n={type:r,rules:[]},o.rules.push(n)),o.keywords[e]=!0,!t)return;const i={keyword:e,definition:{...t,type:(0,u.getJSONTypes)(t.type),schemaType:(0,u.getJSONTypes)(t.schemaType)}};t.before?O.call(this,n,i,t.before):n.rules.push(i),o.all[e]=i,null===(s=t.implements)||void 0===s||s.forEach((e=>this.addKeyword(e)))}function O(e,t,r){const s=e.rules.findIndex((e=>e.keyword===r));s>=0?e.rules.splice(s,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function T(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=R(t)),e.validateSchema=this.compile(t,!0))}const D={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function R(e){return{anyOf:[e,D]}}},4227:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;const s=r(9029),a=r(1520);function o(e,t=e.schema){const{opts:r,self:s}=e;if(!r.strictSchema)return;if("boolean"==typeof t)return;const a=s.RULES.keywords;for(const r in t)a[r]||m(e,`unknown keyword: "${r}"`)}function n(e,t){if("boolean"==typeof e)return!e;for(const r in e)if(t[r])return!0;return!1}function i(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function c(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function l({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:a}){return(o,n,i,c)=>{const l=void 0===i?n:i instanceof s.Name?(n instanceof s.Name?e(o,n,i):t(o,n,i),i):n instanceof s.Name?(t(o,i,n),n):r(n,i);return c!==s.Name||l instanceof s.Name?l:a(o,l)}}function d(e,t){if(!0===t)return e.var("props",!0);const r=e.var("props",s._`{}`);return void 0!==t&&u(e,r,t),r}function u(e,t,r){Object.keys(r).forEach((r=>e.assign(s._`${t}${(0,s.getProperty)(r)}`,!0)))}t.toHash=function(e){const t={};for(const r of e)t[r]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(o(e,t),!n(t,e.self.RULES.all))},t.checkUnknownRules=o,t.schemaHasRules=n,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(const r in e)if("$ref"!==r&&t.all[r])return!0;return!1},t.schemaRefOrVal=function({topSchemaRef:e,schemaPath:t},r,a,o){if(!o){if("number"==typeof r||"boolean"==typeof r)return r;if("string"==typeof r)return s._`${r}`}return s._`${e}${t}${(0,s.getProperty)(a)}`},t.unescapeFragment=function(e){return c(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(i(e))},t.escapeJsonPointer=i,t.unescapeJsonPointer=c,t.eachItem=function(e,t){if(Array.isArray(e))for(const r of e)t(r);else t(e)},t.mergeEvaluated={props:l({mergeNames:(e,t,r)=>e.if(s._`${r} !== true && ${t} !== undefined`,(()=>{e.if(s._`${t} === true`,(()=>e.assign(r,!0)),(()=>e.assign(r,s._`${r} || {}`).code(s._`Object.assign(${r}, ${t})`)))})),mergeToName:(e,t,r)=>e.if(s._`${r} !== true`,(()=>{!0===t?e.assign(r,!0):(e.assign(r,s._`${r} || {}`),u(e,r,t))})),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:d}),items:l({mergeNames:(e,t,r)=>e.if(s._`${r} !== true && ${t} !== undefined`,(()=>e.assign(r,s._`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`))),mergeToName:(e,t,r)=>e.if(s._`${r} !== true`,(()=>e.assign(r,!0===t||s._`${r} > ${t} ? ${r} : ${t}`))),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=d,t.setEvaluated=u;const f={};var h;function m(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,!0===r)throw new Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:f[t.code]||(f[t.code]=new a._Code(t.code))})},function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"}(h||(t.Type=h={})),t.getErrorPath=function(e,t,r){if(e instanceof s.Name){const a=t===h.Num;return r?a?s._`"[" + ${e} + "]"`:s._`"['" + ${e} + "']"`:a?s._`"/" + ${e}`:s._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,s.getProperty)(e).toString():"/"+i(e)},t.checkStrictMode=m},4419:function(e){e.exports=r},4426:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){void 0===t.if&&(0,s.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};t.default=a},4486:function(e,t,r){function s(e,t,r,s,a,o,n,i){var c,l="function"==typeof e?e.options:e;if(t&&(l.render=t,l.staticRenderFns=r,l._compiled=!0),s&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),n?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),a&&a.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(n)},l._ssrRegister=c):a&&(c=i?function(){a.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:a),c)if(l.functional){l._injectStyles=c;var d=l.render;l.render=function(e,t){return c.call(t),d(e,t)}}else{var u=l.beforeCreate;l.beforeCreate=u?[].concat(u,c):[c]}return{exports:e,options:l}}r.d(t,{A:function(){return s}})},4495:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;const s=r(9029),a=r(4227);t.getSubschema=function(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:c}){if(void 0!==t&&void 0!==o)throw new Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==t){const o=e.schema[t];return void 0===r?{schema:o,schemaPath:s._`${e.schemaPath}${(0,s.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:o[r],schemaPath:s._`${e.schemaPath}${(0,s.getProperty)(t)}${(0,s.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,a.escapeFragment)(r)}`}}if(void 0!==o){if(void 0===n||void 0===i||void 0===c)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:c,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:c}){if(void 0!==n&&void 0!==r)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:l}=t;if(void 0!==r){const{errorPath:n,dataPathArr:i,opts:c}=t;d(l.let("data",s._`${t.data}${(0,s.getProperty)(r)}`,!0)),e.errorPath=s.str`${n}${(0,a.getErrorPath)(r,o,c.jsPropertySyntax)}`,e.parentDataProperty=s._`${r}`,e.dataPathArr=[...i,e.parentDataProperty]}function d(r){e.data=r,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,r]}void 0!==n&&(d(n instanceof s.Name?n:l.let("data",n,!0)),void 0!==c&&(e.propertyName=c)),i&&(e.dataTypes=i)},t.extendSubschemaMode=function(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:s,createErrors:a,allErrors:o}){void 0!==s&&(e.compositeRule=s),void 0!==a&&(e.createErrors=a),void 0!==o&&(e.allErrors=o),e.jtdDiscriminator=t,e.jtdMetadata=r}},4551:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(6939);class a extends Error{constructor(e,t,r,a){super(a||`can't resolve reference ${r} from id ${t}`),this.missingRef=(0,s.resolveUrl)(e,t,r),this.missingSchema=(0,s.normalizeId)((0,s.getFullPath)(e,this.missingRef))}}t.default=a},4737:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>s.str`must match format "${e}"`,params:({schemaCode:e})=>s._`{format: ${e}}`},code(e,t){const{gen:r,data:a,$data:o,schema:n,schemaCode:i,it:c}=e,{opts:l,errSchemaPath:d,schemaEnv:u,self:f}=c;l.validateFormats&&(o?function(){const o=r.scopeValue("formats",{ref:f.formats,code:l.code.formats}),n=r.const("fDef",s._`${o}[${i}]`),c=r.let("fType"),d=r.let("format");r.if(s._`typeof ${n} == "object" && !(${n} instanceof RegExp)`,(()=>r.assign(c,s._`${n}.type || "string"`).assign(d,s._`${n}.validate`)),(()=>r.assign(c,s._`"string"`).assign(d,n))),e.fail$data((0,s.or)(!1===l.strictSchema?s.nil:s._`${i} && !${d}`,function(){const e=u.$async?s._`(${n}.async ? await ${d}(${a}) : ${d}(${a}))`:s._`${d}(${a})`,r=s._`(typeof ${d} == "function" ? ${e} : ${d}.test(${a}))`;return s._`${d} && ${d} !== true && ${c} === ${t} && !${r}`}()))}():function(){const o=f.formats[n];if(!o)return void function(){if(!1!==l.strictSchema)throw new Error(e());function e(){return`unknown format "${n}" ignored in schema at path "${d}"`}f.logger.warn(e())}();if(!0===o)return;const[i,c,h]=function(e){const t=e instanceof RegExp?(0,s.regexpCode)(e):l.code.formats?s._`${l.code.formats}${(0,s.getProperty)(n)}`:void 0,a=r.scopeValue("formats",{key:n,ref:e,code:t});return"object"!=typeof e||e instanceof RegExp?["string",e,a]:[e.type||"string",e.validate,s._`${a}.validate`]}(o);i===t&&e.pass(function(){if("object"==typeof o&&!(o instanceof RegExp)&&o.async){if(!u.$async)throw new Error("async format in sync schema");return s._`await ${h}(${a})`}return"function"==typeof c?s._`${h}(${a})`:s._`${h}.test(${a})`}())}())}};t.default=a},4834:function(e,t,r){const{HEX:s}=r(4914);function a(e){if(c(e,".")<3)return{host:e,isIPV4:!1};const t=e.match(/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/u)||[],[r]=t;return r?{host:i(r,"."),isIPV4:!0}:{host:e,isIPV4:!1}}function o(e,t=!1){let r="",a=!0;for(const t of e){if(void 0===s[t])return;"0"!==t&&!0===a&&(a=!1),a||(r+=t)}return t&&0===r.length&&(r="0"),r}function n(e,t={}){if(c(e,":")<2)return{host:e,isIPV6:!1};const r=function(e){let t=0;const r={error:!1,address:"",zone:""},s=[],a=[];let n=!1,i=!1,c=!1;function l(){if(a.length){if(!1===n){const e=o(a);if(void 0===e)return r.error=!0,!1;s.push(e)}a.length=0}return!0}for(let o=0;o<e.length;o++){const d=e[o];if("["!==d&&"]"!==d)if(":"!==d)if("%"===d){if(!l())break;n=!0}else a.push(d);else{if(!0===i&&(c=!0),!l())break;if(t++,s.push(":"),t>7){r.error=!0;break}o-1>=0&&":"===e[o-1]&&(i=!0)}}return a.length&&(n?r.zone=a.join(""):c?s.push(a.join("")):s.push(o(a))),r.address=s.join(""),r}(e);if(r.error)return{host:e,isIPV6:!1};{let e=r.address,t=r.address;return r.zone&&(e+="%"+r.zone,t+="%25"+r.zone),{host:e,escapedHost:t,isIPV6:!0}}}function i(e,t){let r="",s=!0;const a=e.length;for(let o=0;o<a;o++){const n=e[o];"0"===n&&s?(o+1<=a&&e[o+1]===t||o+1===a)&&(r+=n,s=!1):(s=n===t,r+=n)}return r}function c(e,t){let r=0;for(let s=0;s<e.length;s++)e[s]===t&&r++;return r}const l=/^\.\.?\//u,d=/^\/\.(?:\/|$)/u,u=/^\/\.\.(?:\/|$)/u,f=/^\/?(?:.|\n)*?(?=\/|$)/u;e.exports={recomposeAuthority:function(e,t){const r=[];if(void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host){let t=unescape(e.host);const s=a(t);if(s.isIPV4)t=s.host;else{const r=n(s.host,{isIPV4:!1});t=!0===r.isIPV6?`[${r.escapedHost}]`:e.host}r.push(t)}return"number"!=typeof e.port&&"string"!=typeof e.port||(r.push(":"),r.push(String(e.port))),r.length?r.join(""):void 0},normalizeComponentEncoding:function(e,t){const r=!0!==t?escape:unescape;return void 0!==e.scheme&&(e.scheme=r(e.scheme)),void 0!==e.userinfo&&(e.userinfo=r(e.userinfo)),void 0!==e.host&&(e.host=r(e.host)),void 0!==e.path&&(e.path=r(e.path)),void 0!==e.query&&(e.query=r(e.query)),void 0!==e.fragment&&(e.fragment=r(e.fragment)),e},removeDotSegments:function(e){const t=[];for(;e.length;)if(e.match(l))e=e.replace(l,"");else if(e.match(d))e=e.replace(d,"/");else if(e.match(u))e=e.replace(u,"/"),t.pop();else if("."===e||".."===e)e="";else{const r=e.match(f);if(!r)throw new Error("Unexpected dot segment condition");{const s=r[0];e=e.slice(s.length),t.push(s)}}return t.join("")},normalizeIPv4:a,normalizeIPv6:n,stringArrayToHexStripped:o}},4914:function(e){e.exports={HEX:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15}}},5281:function(e,t,r){r.d(t,{A:function(){return f}});var s=r(9795),a=r(6773),o=r.n(a),n=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return o().get(t,"0")}loads(...e){return new Promise(((t,r)=>{this._queue.push({keys:e,resolve:t,reject:r}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};o().each(e,(e=>{o().each(e.keys,(e=>t[e]=null))}));let r=o().keys(t);this._fnBatchLoad(r).then((s=>{o().each(r,((e,r)=>{t[e]=s[r]})),o().each(e,(({keys:e,resolve:r})=>{r(o().map(e,(e=>t[e])))}))})).catch((t=>{o().each(e,(({reject:e})=>e(t)))}))}},i=r(5360),c=r.n(i);const l=async(e,t,r)=>{if(t.setNetworking(!0),t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,r),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,s.Fr)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let a=_.cloneDeep(e);if(a.can_custom_org_params){let e=_.cloneDeep(_.get(t,"orgInfo",{}));console.log("bpm3_orgInfo",e),e.custom_page_level&&(a.params.page_level=e.custom_page_level),e.custom_group_id&&(a.params.group_id=e.custom_group_id),e.custom_team_id&&(a.params.team_id=e.custom_team_id),e.custom_project_id&&(a.params.project_id=e.custom_project_id)}console.log("bpm3_orgInfo_reqArgs",a);let o=await zj.net.request(a);return t.setNetworking(!1),o},d={},u={};var f={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a}){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_definition/`,method:"GET"},e,s)},getOptions(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_search/`,method:"GET",params:o},e,s)},getListSelected(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${r}/list_selected/`,method:"GET",params:o},e,s)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:r,orgInfo:s,uniqueId:a}){const o=`${t}/${r}`,i=d[o]||new n((async o=>{let n=`/app_flow/v1/papi/assist_field/${t}/${r}/list_title/`;const i=await l({url:n,method:"GET",params:{values:JSON.stringify(o)}},e,s),c=_.get(i,"data.data.data",{});let d=[];return _.map(o,(e=>{a?(e=JSON.parse(e),e=_.get(e,`${a}`),d=_.concat(d,c[e])):d=_.concat(d,c[e])})),d}));return d[o]=i,i},getTitle(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return l({url:`/app_flow/v1/papi/assist_field/${t}/${r}/list_title/`,method:"GET",params:{values:JSON.stringify(o)}},e,s)},async searchSelectOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){n&&(o.q=n);let i=a?`/app_flow/v1/papi/dm/assist_field/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${r}/search_title/`,c=`${t}/${r}/${n}/${JSON.stringify(s)}/${JSON.stringify(o)}`,d={};return u[c]&&"loading"==u[c]?(console.log("有缓存,返回"),await this.waitCacheMapData(c)):(!u[c]||(new Date).getTime()-u[c].last_time>6e4?(u[c]="loading",d=await l({url:i,method:a?"GET":"POST",data:o,can_custom_org_params:!0},e,s),u[c]={last_time:(new Date).getTime(),result:d}):(console.log("有缓存"),u[c].result&&(d=u[c].result)),d)},waitCacheMapData(e){return new Promise((t=>{let r=setInterval((()=>{u[e]&&"loading"!=u[e]&&u[e].result&&(clearInterval(r),t(u[e].result))}),100)}))},selectFromMulFormSearchOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),l({url:a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/search_title/`,method:"GET",params:o},e,s)},selectFromMulFormListTitleLoader(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a}){const o=`${t}/${r}`,i=d[o]||new n((async o=>{let n=a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/list_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/list_title/`;const i=await l({url:n,method:"GET",params:{values:JSON.stringify(o)}},e,s),c=_.get(i.data,"data.items",[]),d={};c.forEach((e=>{Object.keys(e.data).forEach((t=>{let r=e.data[t];d[t]={form_def_id:_.get(e,"definition.form.id"),form_title:_.get(e,"definition.form.name"),label:r}}))}));let u=[];return o.forEach((e=>{u.push(d[e])})),u}));return d[o]=i,i},selectFromMulFormListTitle(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o){return l({url:a?`/app_flow/v1/papi/dm/assist_field/select_form_mul_form/${t}/${r}/list_title/`:`/app_flow/v1/papi/assist_field/select_form_mul_form/${t}/${r}/list_title/`,method:"GET",params:{values:JSON.stringify(o)}},e,s)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),l({url:a?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${r}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${r}/search_title/`,method:"GET",params:o,can_custom_org_params:!0},e,s)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:r,orgInfo:s,isDm:a},o={},n=""){return n&&(o.q=n),l({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${r}/search_title/`,method:"GET",params:o},e,s)}},OCR:{getCreatedTaskList(e){return zj.net.w.noapi({url:"/base_srv_module/v2/gapi/task/async_notify_list",method:"POST",data:c().stringify({group_id:zj.pageParam().group_id||0,file_md5:e})})},getTaskId(e){return zj.net.w.noapi({url:"/base_srv_module/v2/gapi/task/async_notify_submit",method:"POST",data:c().stringify({group_id:zj.pageParam().group_id||0,name:"OCR识别MD5_"+e,vendor_code:"csmart",enable_notify:0,task_type:1,creator:zj.app.accessInfo.user_id,file_md5:e})})},getOcrResult(e){return zj.net.w.noapi({url:"/base_srv_module/v2/gapi/task/detail",method:"POST",data:c().stringify(e)})},ocrCreateForm(e,t){return zj.net.w.noapi.json({url:"/app_flow/v1/papi/ocr_create/submit",method:"POST",params:t,data:e})}}}},5333:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(4227),n=r(4227),i={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,data:i,parentSchema:c,it:l}=e,{opts:d}=l,u=(0,s.allSchemaProperties)(r),f=u.filter((e=>(0,o.alwaysValidSchema)(l,r[e])));if(0===u.length||f.length===u.length&&(!l.opts.unevaluated||!0===l.props))return;const h=d.strictSchema&&!d.allowMatchingProperties&&c.properties,m=t.name("valid");!0===l.props||l.props instanceof a.Name||(l.props=(0,n.evaluatedPropsToName)(t,l.props));const{props:p}=l;function y(e){for(const t in h)new RegExp(e).test(t)&&(0,o.checkStrictMode)(l,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}function g(r){t.forIn("key",i,(o=>{t.if(a._`${(0,s.usePattern)(e,r)}.test(${o})`,(()=>{const s=f.includes(r);s||e.subschema({keyword:"patternProperties",schemaProp:r,dataProp:o,dataPropType:n.Type.Str},m),l.opts.unevaluated&&!0!==p?t.assign(a._`${p}[${o}]`,!0):s||l.allErrors||t.if((0,a.not)(m),(()=>t.break()))}))}))}!function(){for(const e of u)h&&y(e),l.allErrors?g(e):(t.var(m,!0),g(e),t.if(m))}()}};t.default=i},5354:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(494),a={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,s.validateTuple)(e,"items")};t.default=a},5360:function(e){e.exports=t},5457:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;const s=r(9029),a=r(4227),o={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:e}})=>s.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>s._`{limit: ${e}}`},code(e){const{parentSchema:t,it:r}=e,{items:s}=t;Array.isArray(s)?n(e,s):(0,a.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas')}};function n(e,t){const{gen:r,schema:o,data:n,keyword:i,it:c}=e;c.items=!0;const l=r.const("len",s._`${n}.length`);if(!1===o)e.setParams({len:t.length}),e.pass(s._`${l} <= ${t.length}`);else if("object"==typeof o&&!(0,a.alwaysValidSchema)(c,o)){const o=r.var("valid",s._`${l} <= ${t.length}`);r.if((0,s.not)(o),(()=>function(o){r.forRange("i",t.length,l,(t=>{e.subschema({keyword:i,dataProp:t,dataPropType:a.Type.Num},o),c.allErrors||r.if((0,s.not)(o),(()=>r.break()))}))}(o))),e.ok(o)}}t.validateAdditionalItems=n,t.default=o},5765:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;const s=r(9029),a=r(4227),o=r(2023),n=r(4227);function i(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:s._`Object.prototype.hasOwnProperty`})}function c(e,t,r){return s._`${i(e)}.call(${t}, ${r})`}function l(e,t,r,a){const o=s._`${t}${(0,s.getProperty)(r)} === undefined`;return a?(0,s.or)(o,(0,s.not)(c(e,t,r))):o}function d(e){return e?Object.keys(e).filter((e=>"__proto__"!==e)):[]}t.checkReportMissingProp=function(e,t){const{gen:r,data:a,it:o}=e;r.if(l(r,a,t,o.opts.ownProperties),(()=>{e.setParams({missingProperty:s._`${t}`},!0),e.error()}))},t.checkMissingProp=function({gen:e,data:t,it:{opts:r}},a,o){return(0,s.or)(...a.map((a=>(0,s.and)(l(e,t,a,r.ownProperties),s._`${o} = ${a}`))))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=i,t.isOwnProperty=c,t.propertyInData=function(e,t,r,a){const o=s._`${t}${(0,s.getProperty)(r)} !== undefined`;return a?s._`${o} && ${c(e,t,r)}`:o},t.noPropertyInData=l,t.allSchemaProperties=d,t.schemaProperties=function(e,t){return d(t).filter((r=>!(0,a.alwaysValidSchema)(e,t[r])))},t.callValidateCode=function({schemaCode:e,data:t,it:{gen:r,topSchemaRef:a,schemaPath:n,errorPath:i},it:c},l,d,u){const f=u?s._`${e}, ${t}, ${a}${n}`:t,h=[[o.default.instancePath,(0,s.strConcat)(o.default.instancePath,i)],[o.default.parentData,c.parentData],[o.default.parentDataProperty,c.parentDataProperty],[o.default.rootData,o.default.rootData]];c.opts.dynamicRef&&h.push([o.default.dynamicAnchors,o.default.dynamicAnchors]);const m=s._`${f}, ${r.object(...h)}`;return d!==s.nil?s._`${l}.call(${d}, ${m})`:s._`${l}(${m})`};const u=s._`new RegExp`;t.usePattern=function({gen:e,it:{opts:t}},r){const a=t.unicodeRegExp?"u":"",{regExp:o}=t.code,i=o(r,a);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:s._`${"new RegExp"===o.code?u:(0,n.useFunc)(e,o)}(${r}, ${a})`})},t.validateArray=function(e){const{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.allErrors){const e=t.let("valid",!0);return c((()=>t.assign(e,!1))),e}return t.var(i,!0),c((()=>t.break())),i;function c(n){const c=t.const("len",s._`${r}.length`);t.forRange("i",0,c,(r=>{e.subschema({keyword:o,dataProp:r,dataPropType:a.Type.Num},i),t.if((0,s.not)(i),n)}))}},t.validateUnion=function(e){const{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some((e=>(0,a.alwaysValidSchema)(n,e)))&&!n.opts.unevaluated)return;const i=t.let("valid",!1),c=t.name("_valid");t.block((()=>r.forEach(((r,a)=>{const n=e.subschema({keyword:o,schemaProp:a,compositeRule:!0},c);t.assign(i,s._`${i} || ${c}`),e.mergeValidEvaluated(n,c)||t.if((0,s.not)(i))})))),e.result(i,(()=>e.reset()),(()=>e.error(!0)))}},5844:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:r,it:a}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");const o=t.name("valid");r.forEach(((t,r)=>{if((0,s.alwaysValidSchema)(a,t))return;const n=e.subschema({keyword:"allOf",schemaProp:r},o);e.ok(o),e.mergeEvaluated(n)}))}};t.default=a},5882:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=s.operators,o={maximum:{okStr:"<=",ok:a.LTE,fail:a.GT},minimum:{okStr:">=",ok:a.GTE,fail:a.LT},exclusiveMaximum:{okStr:"<",ok:a.LT,fail:a.GTE},exclusiveMinimum:{okStr:">",ok:a.GT,fail:a.LTE}},n={message:({keyword:e,schemaCode:t})=>s.str`must be ${o[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>s._`{comparison: ${o[e].okStr}, limit: ${t}}`},i={keyword:Object.keys(o),type:"number",schemaType:"number",$data:!0,error:n,code(e){const{keyword:t,data:r,schemaCode:a}=e;e.fail$data(s._`${r} ${o[t].fail} ${a} || isNaN(${r})`)}};t.default=i},5944:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(8343);s.code='require("ajv/dist/runtime/uri").default',t.default=s},6144:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2128),a=r(7060),o=r(6378),n=r(7532),i=r(9857),c=[s.default,a.default,(0,o.default)(),n.default,i.metadataVocabulary,i.contentVocabulary];t.default=c},6163:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:e})=>s._`{passingSchemas: ${e.passing}}`},code(e){const{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.discriminator)return;const i=r,c=t.let("valid",!1),l=t.let("passing",null),d=t.name("_valid");e.setParams({passing:l}),t.block((function(){i.forEach(((r,o)=>{let i;(0,a.alwaysValidSchema)(n,r)?t.var(d,!0):i=e.subschema({keyword:"oneOf",schemaProp:o,compositeRule:!0},d),o>0&&t.if(s._`${d} && ${c}`).assign(c,!1).assign(l,s._`[${l}, ${o}]`).else(),t.if(d,(()=>{t.assign(c,!0),t.assign(l,o),i&&e.mergeEvaluated(i,s.Name)}))}))})),e.result(c,(()=>e.reset()),(()=>e.error(!0)))}};t.default=o},6250:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(2017);s.code='require("ajv/dist/runtime/equal").default',t.default=s},6378:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5457),a=r(5354),o=r(494),n=r(3966),i=r(2661),c=r(3025),l=r(9713),d=r(8660),u=r(117),f=r(5333),h=r(7923),m=r(6505),p=r(6163),y=r(5844),g=r(1239),v=r(4426);t.default=function(e=!1){const t=[h.default,m.default,p.default,y.default,g.default,v.default,l.default,d.default,c.default,u.default,f.default];return e?t.push(a.default,n.default):t.push(s.default,o.default),t.push(i.default),t}},6505:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:r(5765).validateUnion,error:{message:"must match a schema in anyOf"}};t.default=s},6653:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(7652),o=r(3835),n=r(4551),i=r(4227),c={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:e,tagName:t}})=>e===a.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>s._`{error: ${e}, tag: ${r}, tagValue: ${t}}`},code(e){const{gen:t,data:r,schema:c,parentSchema:l,it:d}=e,{oneOf:u}=l;if(!d.opts.discriminator)throw new Error("discriminator: requires discriminator option");const f=c.propertyName;if("string"!=typeof f)throw new Error("discriminator: requires propertyName");if(c.mapping)throw new Error("discriminator: mapping is not supported");if(!u)throw new Error("discriminator: requires oneOf keyword");const h=t.let("valid",!1),m=t.const("tag",s._`${r}${(0,s.getProperty)(f)}`);function p(r){const a=t.name("valid"),o=e.subschema({keyword:"oneOf",schemaProp:r},a);return e.mergeEvaluated(o,s.Name),a}t.if(s._`typeof ${m} == "string"`,(()=>function(){const r=function(){var e;const t={},r=a(l);let s=!0;for(let t=0;t<u.length;t++){let l=u[t];if((null==l?void 0:l.$ref)&&!(0,i.schemaHasRulesButRef)(l,d.self.RULES)){const e=l.$ref;if(l=o.resolveRef.call(d.self,d.schemaEnv.root,d.baseId,e),l instanceof o.SchemaEnv&&(l=l.schema),void 0===l)throw new n.default(d.opts.uriResolver,d.baseId,e)}const h=null===(e=null==l?void 0:l.properties)||void 0===e?void 0:e[f];if("object"!=typeof h)throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${f}"`);s=s&&(r||a(l)),c(h,t)}if(!s)throw new Error(`discriminator: "${f}" must be required`);return t;function a({required:e}){return Array.isArray(e)&&e.includes(f)}function c(e,t){if(e.const)h(e.const,t);else{if(!e.enum)throw new Error(`discriminator: "properties/${f}" must have "const" or "enum"`);for(const r of e.enum)h(r,t)}}function h(e,r){if("string"!=typeof e||e in t)throw new Error(`discriminator: "${f}" values must be unique strings`);t[e]=r}}();t.if(!1);for(const e in r)t.elseIf(s._`${m} === ${e}`),t.assign(h,p(r[e]));t.else(),e.error(!1,{discrError:a.DiscrError.Mapping,tag:m,tagName:f}),t.endIf()}()),(()=>e.error(!1,{discrError:a.DiscrError.Tag,tag:m,tagName:f}))),e.ok(h)}};t.default=c},6773:function(t){t.exports=e},6939:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;const s=r(4227),a=r(2017),o=r(7106),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e,t=!0){return"boolean"==typeof e||(!0===t?!c(e):!!t&&l(e)<=t)};const i=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function c(e){for(const t in e){if(i.has(t))return!0;const r=e[t];if(Array.isArray(r)&&r.some(c))return!0;if("object"==typeof r&&c(r))return!0}return!1}function l(e){let t=0;for(const r in e){if("$ref"===r)return 1/0;if(t++,!n.has(r)&&("object"==typeof e[r]&&(0,s.eachItem)(e[r],(e=>t+=l(e))),t===1/0))return 1/0}return t}function d(e,t="",r){!1!==r&&(t=h(t));const s=e.parse(t);return u(e,s)}function u(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=d,t._getFullPath=u;const f=/#\/?$/;function h(e){return e?e.replace(f,""):""}t.normalizeId=h,t.resolveUrl=function(e,t,r){return r=h(r),e.resolve(t,r)};const m=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};const{schemaId:r,uriResolver:s}=this.opts,n=h(e[r]||t),i={"":n},c=d(s,n,!1),l={},u=new Set;return o(e,{allKeys:!0},((e,t,s,a)=>{if(void 0===a)return;const o=c+t;let n=i[a];function d(t){const r=this.opts.uriResolver.resolve;if(t=h(n?r(n,t):t),u.has(t))throw p(t);u.add(t);let s=this.refs[t];return"string"==typeof s&&(s=this.refs[s]),"object"==typeof s?f(e,s.schema,t):t!==h(o)&&("#"===t[0]?(f(e,l[t],t),l[t]=e):this.refs[t]=o),t}function y(e){if("string"==typeof e){if(!m.test(e))throw new Error(`invalid anchor "${e}"`);d.call(this,`#${e}`)}}"string"==typeof e[r]&&(n=d.call(this,e[r])),y.call(this,e.$anchor),y.call(this,e.$dynamicAnchor),i[t]=n})),l;function f(e,t,r){if(void 0!==t&&!a(e,t))throw p(r)}function p(e){return new Error(`reference "${e}" resolves to more than one schema`)}}},7060:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5882),a=r(3439),o=r(7307),n=r(422),i=r(2105),c=r(4003),l=r(1163),d=r(617),u=r(7935),f=r(8643),h=[s.default,a.default,o.default,n.default,i.default,c.default,l.default,d.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},u.default,f.default];t.default=h},7106:function(e){var t=e.exports=function(e,t,s){"function"==typeof t&&(s=t,t={}),r(t,"function"==typeof(s=t.cb||s)?s:s.pre||function(){},s.post||function(){},e,"",e)};function r(e,s,a,o,n,i,c,l,d,u){if(o&&"object"==typeof o&&!Array.isArray(o)){for(var f in s(o,n,i,c,l,d,u),o){var h=o[f];if(Array.isArray(h)){if(f in t.arrayKeywords)for(var m=0;m<h.length;m++)r(e,s,a,h[m],n+"/"+f+"/"+m,i,n,f,o,m)}else if(f in t.propsKeywords){if(h&&"object"==typeof h)for(var p in h)r(e,s,a,h[p],n+"/"+f+"/"+p.replace(/~/g,"~0").replace(/\//g,"~1"),i,n,f,o,p)}else(f in t.keywords||e.allKeys&&!(f in t.skipKeywords))&&r(e,s,a,h,n+"/"+f,i,n,f,o)}a(o,n,i,c,l,d,u)}}t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},7307:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(3853),n={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const r="maxLength"===e?"more":"fewer";return s.str`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>s._`{limit: ${e}}`},code(e){const{keyword:t,data:r,schemaCode:n,it:i}=e,c="maxLength"===t?s.operators.GT:s.operators.LT,l=!1===i.opts.unicode?s._`${r}.length`:s._`${(0,a.useFunc)(e.gen,o.default)}(${r})`;e.fail$data(s._`${l} ${c} ${n}`)}};t.default=n},7532:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=[r(4737).default];t.default=s},7652:function(e,t){var r;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,function(e){e.Tag="tag",e.Mapping="mapping"}(r||(t.DiscrError=r={}))},7845:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;const s=r(1520);class a extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}var o;!function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"}(o||(t.UsedValueState=o={})),t.varKinds={const:new s.Name("const"),let:new s.Name("let"),var:new s.Name("var")};class n{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof s.Name?e:this.name(e)}name(e){return new s.Name(this._newName(e))}_newName(e){return`${e}${(this._names[e]||this._nameGroup(e)).index++}`}_nameGroup(e){var t,r;if((null===(r=null===(t=this._parent)||void 0===t?void 0:t._prefixes)||void 0===r?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=n;class i extends s.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=s._`.${new s.Name(t)}[${r}]`}}t.ValueScopeName=i;const c=s._`\n`;t.ValueScope=class extends n{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?c:s.nil}}get(){return this._scope}name(e){return new i(e,this._newName(e))}value(e,t){var r;if(void 0===t.ref)throw new Error("CodeGen: ref must be passed in value");const s=this.toName(e),{prefix:a}=s,o=null!==(r=t.key)&&void 0!==r?r:t.ref;let n=this._values[a];if(n){const e=n.get(o);if(e)return e}else n=this._values[a]=new Map;n.set(o,s);const i=this._scope[a]||(this._scope[a]=[]),c=i.length;return i[c]=t.ref,s.setValue(t,{property:a,itemIndex:c}),s}getValue(e,t){const r=this._values[e];if(r)return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,(t=>{if(void 0===t.scopePath)throw new Error(`CodeGen: name "${t}" has no value`);return s._`${e}${t.scopePath}`}))}scopeCode(e=this._values,t,r){return this._reduceValues(e,(e=>{if(void 0===e.value)throw new Error(`CodeGen: name "${e}" has no value`);return e.value.code}),t,r)}_reduceValues(e,r,n={},i){let c=s.nil;for(const l in e){const d=e[l];if(!d)continue;const u=n[l]=n[l]||new Map;d.forEach((e=>{if(u.has(e))return;u.set(e,o.Started);let n=r(e);if(n){const r=this.opts.es5?t.varKinds.var:t.varKinds.const;c=s._`${c}${r} ${e} = ${n};${this.opts._n}`}else{if(!(n=null==i?void 0:i(e)))throw new a(e);c=s._`${c}${n}${this.opts._n}`}u.set(e,o.Completed)}))}return c}}},7870:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;const s=r(9029),a=r(4227);function o(e,t,r){const{gen:o,compositeRule:n,data:i,opts:c}=e;if(void 0===r)return;const l=s._`${i}${(0,s.getProperty)(t)}`;if(n)return void(0,a.checkStrictMode)(e,`default is ignored for: ${l}`);let d=s._`${l} === undefined`;"empty"===c.useDefaults&&(d=s._`${d} || ${l} === null || ${l} === ""`),o.if(d,s._`${l} = ${(0,s.stringify)(r)}`)}t.assignDefaults=function(e,t){const{properties:r,items:s}=e.schema;if("object"===t&&r)for(const t in r)o(e,t,r[t].default);else"array"===t&&Array.isArray(s)&&s.forEach(((t,r)=>o(e,r,t.default)))}},7887:function(e,t){function r(e,t){return t.rules.some((t=>s(e,t)))}function s(e,t){var r;return void 0!==e[t.keyword]||(null===(r=t.definition.implements)||void 0===r?void 0:r.some((t=>void 0!==e[t])))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function({schema:e,self:t},s){const a=t.RULES.types[s];return a&&!0!==a&&r(e,a)},t.shouldUseGroup=r,t.shouldUseRule=s},7923:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(4227),a={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:r,it:a}=e;if((0,s.alwaysValidSchema)(a,r))return void e.fail();const o=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},o),e.failResult(o,(()=>e.reset()),(()=>e.error()))},error:{message:"must NOT be valid"}};t.default=a},7935:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(6250),n={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:e})=>s._`{allowedValue: ${e}}`},code(e){const{gen:t,data:r,$data:n,schemaCode:i,schema:c}=e;n||c&&"object"==typeof c?e.fail$data(s._`!${(0,a.useFunc)(t,o.default)}(${r}, ${i})`):e.fail(s._`${c} !== ${r}`)}};t.default=n},8343:function(e,t,r){const{normalizeIPv6:s,normalizeIPv4:a,removeDotSegments:o,recomposeAuthority:n,normalizeComponentEncoding:i}=r(4834),c=r(343);function l(e,t,r,s){const a={};return s||(e=h(d(e,r),r),t=h(d(t,r),r)),!(r=r||{}).tolerant&&t.scheme?(a.scheme=t.scheme,a.userinfo=t.userinfo,a.host=t.host,a.port=t.port,a.path=o(t.path||""),a.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(a.userinfo=t.userinfo,a.host=t.host,a.port=t.port,a.path=o(t.path||""),a.query=t.query):(t.path?("/"===t.path.charAt(0)?a.path=o(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?a.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:a.path=t.path:a.path="/"+t.path,a.path=o(a.path)),a.query=t.query):(a.path=e.path,void 0!==t.query?a.query=t.query:a.query=e.query),a.userinfo=e.userinfo,a.host=e.host,a.port=e.port),a.scheme=e.scheme),a.fragment=t.fragment,a}function d(e,t){const r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},s=Object.assign({},t),a=[],i=c[(s.scheme||r.scheme||"").toLowerCase()];i&&i.serialize&&i.serialize(r,s),void 0!==r.path&&(s.skipEscape?r.path=unescape(r.path):(r.path=escape(r.path),void 0!==r.scheme&&(r.path=r.path.split("%3A").join(":")))),"suffix"!==s.reference&&r.scheme&&a.push(r.scheme,":");const l=n(r,s);if(void 0!==l&&("suffix"!==s.reference&&a.push("//"),a.push(l),r.path&&"/"!==r.path.charAt(0)&&a.push("/")),void 0!==r.path){let e=r.path;s.absolutePath||i&&i.absolutePath||(e=o(e)),void 0===l&&(e=e.replace(/^\/\//u,"/%2F")),a.push(e)}return void 0!==r.query&&a.push("?",r.query),void 0!==r.fragment&&a.push("#",r.fragment),a.join("")}const u=Array.from({length:127},((e,t)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(t)))),f=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function h(e,t){const r=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},n=-1!==e.indexOf("%");let i=!1;"suffix"===r.reference&&(e=(r.scheme?r.scheme+":":"")+"//"+e);const l=e.match(f);if(l){if(o.scheme=l[1],o.userinfo=l[3],o.host=l[4],o.port=parseInt(l[5],10),o.path=l[6]||"",o.query=l[7],o.fragment=l[8],isNaN(o.port)&&(o.port=l[5]),o.host){const e=a(o.host);if(!1===e.isIPV4){const t=s(e.host,{isIPV4:!1});o.host=t.host.toLowerCase(),i=t.isIPV6}else o.host=e.host,i=!0}void 0!==o.scheme||void 0!==o.userinfo||void 0!==o.host||void 0!==o.port||o.path||void 0!==o.query?void 0===o.scheme?o.reference="relative":void 0===o.fragment?o.reference="absolute":o.reference="uri":o.reference="same-document",r.reference&&"suffix"!==r.reference&&r.reference!==o.reference&&(o.error=o.error||"URI is not a "+r.reference+" reference.");const e=c[(r.scheme||o.scheme||"").toLowerCase()];if(!(r.unicodeSupport||e&&e.unicodeSupport)&&o.host&&(r.domainHost||e&&e.domainHost)&&!1===i&&function(e){let t=0;for(let r=0,s=e.length;r<s;++r)if(t=e.charCodeAt(r),t>126||u[t])return!0;return!1}(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(e){o.error=o.error||"Host's domain name can not be converted to ASCII: "+e}(!e||e&&!e.skipNormalize)&&(n&&void 0!==o.scheme&&(o.scheme=unescape(o.scheme)),n&&void 0!==o.host&&(o.host=unescape(o.host)),void 0!==o.path&&o.path.length&&(o.path=escape(unescape(o.path))),void 0!==o.fragment&&o.fragment.length&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),e&&e.parse&&e.parse(o,r)}else o.error=o.error||"URI can not be parsed.";return o}const m={SCHEMES:c,normalize:function(e,t){return"string"==typeof e?e=d(h(e,t),t):"object"==typeof e&&(e=h(d(e,t),t)),e},resolve:function(e,t,r){const s=Object.assign({scheme:"null"},r);return d(l(h(e,s),h(t,s),s,!0),{...s,skipEscape:!0})},resolveComponents:l,equal:function(e,t,r){return"string"==typeof e?(e=unescape(e),e=d(i(h(e,r),!0),{...r,skipEscape:!0})):"object"==typeof e&&(e=d(i(e,!0),{...r,skipEscape:!0})),"string"==typeof t?(t=unescape(t),t=d(i(h(t,r),!0),{...r,skipEscape:!0})):"object"==typeof t&&(t=d(i(t,!0),{...r,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()},serialize:d,parse:h};e.exports=m,e.exports.default=m,e.exports.fastUri=m},8643:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o=r(6250),n={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:e})=>s._`{allowedValues: ${e}}`},code(e){const{gen:t,data:r,$data:n,schema:i,schemaCode:c,it:l}=e;if(!n&&0===i.length)throw new Error("enum must have non-empty array");const d=i.length>=l.opts.loopEnum;let u;const f=()=>null!=u?u:u=(0,a.useFunc)(t,o.default);let h;if(d||n)h=t.let("valid"),e.block$data(h,(function(){t.assign(h,!1),t.forOf("v",c,(e=>t.if(s._`${f()}(${r}, ${e})`,(()=>t.assign(h,!0).break()))))}));else{if(!Array.isArray(i))throw new Error("ajv implementation error");const e=t.const("vSchema",c);h=(0,s.or)(...i.map(((t,a)=>function(e,t){const a=i[t];return"object"==typeof a&&null!==a?s._`${f()}(${r}, ${e}[${t}])`:s._`${r} === ${a}`}(e,a))))}e.pass(h)}};t.default=n},8660:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(5765),a=r(9029),o=r(2023),n=r(4227),i={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:e})=>a._`{additionalProperty: ${e.additionalProperty}}`},code(e){const{gen:t,schema:r,parentSchema:i,data:c,errsCount:l,it:d}=e;if(!l)throw new Error("ajv implementation error");const{allErrors:u,opts:f}=d;if(d.props=!0,"all"!==f.removeAdditional&&(0,n.alwaysValidSchema)(d,r))return;const h=(0,s.allSchemaProperties)(i.properties),m=(0,s.allSchemaProperties)(i.patternProperties);function p(e){t.code(a._`delete ${c}[${e}]`)}function y(s){if("all"===f.removeAdditional||f.removeAdditional&&!1===r)p(s);else{if(!1===r)return e.setParams({additionalProperty:s}),e.error(),void(u||t.break());if("object"==typeof r&&!(0,n.alwaysValidSchema)(d,r)){const r=t.name("valid");"failing"===f.removeAdditional?(g(s,r,!1),t.if((0,a.not)(r),(()=>{e.reset(),p(s)}))):(g(s,r),u||t.if((0,a.not)(r),(()=>t.break())))}}}function g(t,r,s){const a={keyword:"additionalProperties",dataProp:t,dataPropType:n.Type.Str};!1===s&&Object.assign(a,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(a,r)}t.forIn("key",c,(r=>{h.length||m.length?t.if(function(r){let o;if(h.length>8){const e=(0,n.schemaRefOrVal)(d,i.properties,"properties");o=(0,s.isOwnProperty)(t,e,r)}else o=h.length?(0,a.or)(...h.map((e=>a._`${r} === ${e}`))):a.nil;return m.length&&(o=(0,a.or)(o,...m.map((t=>a._`${(0,s.usePattern)(e,t)}.test(${r})`)))),(0,a.not)(o)}(r),(()=>y(r))):y(r)})),e.ok(a._`${l} === ${o.default.errors}`)}};t.default=i},8708:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;const s=r(9029),a=r(4227),o=r(2023);function n(e,t){const r=e.const("err",t);e.if(s._`${o.default.vErrors} === null`,(()=>e.assign(o.default.vErrors,s._`[${r}]`)),s._`${o.default.vErrors}.push(${r})`),e.code(s._`${o.default.errors}++`)}function i(e,t){const{gen:r,validateName:a,schemaEnv:o}=e;o.$async?r.throw(s._`new ${e.ValidationError}(${t})`):(r.assign(s._`${a}.errors`,t),r.return(!1))}t.keywordError={message:({keyword:e})=>s.str`must pass "${e}" keyword validation`},t.keyword$DataError={message:({keyword:e,schemaType:t})=>t?s.str`"${e}" keyword must be ${t} ($data)`:s.str`"${e}" keyword is invalid ($data)`},t.reportError=function(e,r=t.keywordError,a,o){const{it:c}=e,{gen:d,compositeRule:u,allErrors:f}=c,h=l(e,r,a);(null!=o?o:u||f)?n(d,h):i(c,s._`[${h}]`)},t.reportExtraError=function(e,r=t.keywordError,s){const{it:a}=e,{gen:c,compositeRule:d,allErrors:u}=a;n(c,l(e,r,s)),d||u||i(a,o.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(o.default.errors,t),e.if(s._`${o.default.vErrors} !== null`,(()=>e.if(t,(()=>e.assign(s._`${o.default.vErrors}.length`,t)),(()=>e.assign(o.default.vErrors,null)))))},t.extendErrors=function({gen:e,keyword:t,schemaValue:r,data:a,errsCount:n,it:i}){if(void 0===n)throw new Error("ajv implementation error");const c=e.name("err");e.forRange("i",n,o.default.errors,(n=>{e.const(c,s._`${o.default.vErrors}[${n}]`),e.if(s._`${c}.instancePath === undefined`,(()=>e.assign(s._`${c}.instancePath`,(0,s.strConcat)(o.default.instancePath,i.errorPath)))),e.assign(s._`${c}.schemaPath`,s.str`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign(s._`${c}.schema`,r),e.assign(s._`${c}.data`,a))}))};const c={keyword:new s.Name("keyword"),schemaPath:new s.Name("schemaPath"),params:new s.Name("params"),propertyName:new s.Name("propertyName"),message:new s.Name("message"),schema:new s.Name("schema"),parentSchema:new s.Name("parentSchema")};function l(e,t,r){const{createErrors:a}=e.it;return!1===a?s._`{}`:function(e,t,r={}){const{gen:a,it:n}=e,i=[d(n,r),u(e,r)];return function(e,{params:t,message:r},a){const{keyword:n,data:i,schemaValue:l,it:d}=e,{opts:u,propertyName:f,topSchemaRef:h,schemaPath:m}=d;a.push([c.keyword,n],[c.params,"function"==typeof t?t(e):t||s._`{}`]),u.messages&&a.push([c.message,"function"==typeof r?r(e):r]),u.verbose&&a.push([c.schema,l],[c.parentSchema,s._`${h}${m}`],[o.default.data,i]),f&&a.push([c.propertyName,f])}(e,t,i),a.object(...i)}(e,t,r)}function d({errorPath:e},{instancePath:t}){const r=t?s.str`${e}${(0,a.getErrorPath)(t,a.Type.Str)}`:e;return[o.default.instancePath,(0,s.strConcat)(o.default.instancePath,r)]}function u({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:s.str`${t}/${e}`;return r&&(n=s.str`${n}${(0,a.getErrorPath)(r,a.Type.Str)}`),[c.schemaPath,n]}},8727:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;const s=r(8708),a=r(9029),o=r(2023),n={message:"boolean schema is false"};function i(e,t){const{gen:r,data:a}=e,o={gen:r,keyword:"false schema",data:a,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,s.reportError)(o,n,void 0,t)}t.topBoolOrEmptySchema=function(e){const{gen:t,schema:r,validateName:s}=e;!1===r?i(e,!1):"object"==typeof r&&!0===r.$async?t.return(o.default.data):(t.assign(a._`${s}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){const{gen:r,schema:s}=e;!1===s?(r.var(t,!1),i(e)):r.var(t,!0)}},9029:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;const s=r(1520),a=r(7845);var o=r(1520);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return o._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return o.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return o.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return o.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return o.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return o.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return o.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return o.Name}});var n=r(7845);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return n.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return n.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return n.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return n.varKinds}}),t.operators={GT:new s._Code(">"),GTE:new s._Code(">="),LT:new s._Code("<"),LTE:new s._Code("<="),EQ:new s._Code("==="),NEQ:new s._Code("!=="),NOT:new s._Code("!"),OR:new s._Code("||"),AND:new s._Code("&&"),ADD:new s._Code("+")};class i{optimizeNodes(){return this}optimizeNames(e,t){return this}}class c extends i{constructor(e,t,r){super(),this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){const r=e?a.varKinds.var:this.varKind,s=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${s};`+t}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=C(this.rhs,e,t)),this}get names(){return this.rhs instanceof s._CodeOrName?this.rhs.names:{}}}class l extends i{constructor(e,t,r){super(),this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof s.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=C(this.rhs,e,t),this}get names(){return x(this.lhs instanceof s.Name?{}:{...this.lhs.names},this.rhs)}}class d extends l{constructor(e,t,r,s){super(e,r,s),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class u extends i{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class f extends i{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class h extends i{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class m extends i{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=C(this.code,e,t),this}get names(){return this.code instanceof s._CodeOrName?this.code.names:{}}}class p extends i{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce(((t,r)=>t+r.render(e)),"")}optimizeNodes(){const{nodes:e}=this;let t=e.length;for(;t--;){const r=e[t].optimizeNodes();Array.isArray(r)?e.splice(t,1,...r):r?e[t]=r:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){const{nodes:r}=this;let s=r.length;for(;s--;){const a=r[s];a.optimizeNames(e,t)||(O(e,a.names),r.splice(s,1))}return r.length>0?this:void 0}get names(){return this.nodes.reduce(((e,t)=>N(e,t.names)),{})}}class y extends p{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class g extends p{}class v extends y{}v.kind="else";class _ extends y{constructor(e,t){super(t),this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);return this.else&&(t+="else "+this.else.render(e)),t}optimizeNodes(){super.optimizeNodes();const e=this.condition;if(!0===e)return this.nodes;let t=this.else;if(t){const e=t.optimizeNodes();t=this.else=Array.isArray(e)?new v(e):e}return t?!1===e?t instanceof _?t:t.nodes:this.nodes.length?this:new _(T(e),t instanceof _?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var r;if(this.else=null===(r=this.else)||void 0===r?void 0:r.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=C(this.condition,e,t),this}get names(){const e=super.names;return x(e,this.condition),this.else&&N(e,this.else.names),e}}_.kind="if";class $ extends y{}$.kind="for";class w extends ${constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iteration=C(this.iteration,e,t),this}get names(){return N(super.names,this.iteration.names)}}class b extends ${constructor(e,t,r,s){super(),this.varKind=e,this.name=t,this.from=r,this.to=s}render(e){const t=e.es5?a.varKinds.var:this.varKind,{name:r,from:s,to:o}=this;return`for(${t} ${r}=${s}; ${r}<${o}; ${r}++)`+super.render(e)}get names(){const e=x(super.names,this.from);return x(e,this.to)}}class S extends ${constructor(e,t,r,s){super(),this.loop=e,this.varKind=t,this.name=r,this.iterable=s}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iterable=C(this.iterable,e,t),this}get names(){return N(super.names,this.iterable.names)}}class P extends y{constructor(e,t,r){super(),this.name=e,this.args=t,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}P.kind="func";class E extends p{render(e){return"return "+super.render(e)}}E.kind="return";class k extends y{render(e){let t="try"+super.render(e);return this.catch&&(t+=this.catch.render(e)),this.finally&&(t+=this.finally.render(e)),t}optimizeNodes(){var e,t;return super.optimizeNodes(),null===(e=this.catch)||void 0===e||e.optimizeNodes(),null===(t=this.finally)||void 0===t||t.optimizeNodes(),this}optimizeNames(e,t){var r,s;return super.optimizeNames(e,t),null===(r=this.catch)||void 0===r||r.optimizeNames(e,t),null===(s=this.finally)||void 0===s||s.optimizeNames(e,t),this}get names(){const e=super.names;return this.catch&&N(e,this.catch.names),this.finally&&N(e,this.finally.names),e}}class I extends y{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}I.kind="catch";class j extends y{render(e){return"finally"+super.render(e)}}function N(e,t){for(const r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function x(e,t){return t instanceof s._CodeOrName?N(e,t.names):e}function C(e,t,r){return e instanceof s.Name?o(e):(a=e)instanceof s._Code&&a._items.some((e=>e instanceof s.Name&&1===t[e.str]&&void 0!==r[e.str]))?new s._Code(e._items.reduce(((e,t)=>(t instanceof s.Name&&(t=o(t)),t instanceof s._Code?e.push(...t._items):e.push(t),e)),[])):e;var a;function o(e){const s=r[e.str];return void 0===s||1!==t[e.str]?e:(delete t[e.str],s)}}function O(e,t){for(const r in t)e[r]=(e[r]||0)-(t[r]||0)}function T(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:s._`!${M(e)}`}j.kind="finally",t.CodeGen=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new a.Scope({parent:e}),this._nodes=[new g]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){const r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,r,s){const a=this._scope.toName(t);return void 0!==r&&s&&(this._constants[a.str]=r),this._leafNode(new c(e,a,r)),a}const(e,t,r){return this._def(a.varKinds.const,e,t,r)}let(e,t,r){return this._def(a.varKinds.let,e,t,r)}var(e,t,r){return this._def(a.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new l(e,t,r))}add(e,r){return this._leafNode(new d(e,t.operators.ADD,r))}code(e){return"function"==typeof e?e():e!==s.nil&&this._leafNode(new m(e)),this}object(...e){const t=["{"];for(const[r,a]of e)t.length>1&&t.push(","),t.push(r),(r!==a||this.opts.es5)&&(t.push(":"),(0,s.addCodeArg)(t,a));return t.push("}"),new s._Code(t)}if(e,t,r){if(this._blockNode(new _(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new _(e))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(_,v)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new w(e),t)}forRange(e,t,r,s,o=(this.opts.es5?a.varKinds.var:a.varKinds.let)){const n=this._scope.toName(e);return this._for(new b(o,n,t,r),(()=>s(n)))}forOf(e,t,r,o=a.varKinds.const){const n=this._scope.toName(e);if(this.opts.es5){const e=t instanceof s.Name?t:this.var("_arr",t);return this.forRange("_i",0,s._`${e}.length`,(t=>{this.var(n,s._`${e}[${t}]`),r(n)}))}return this._for(new S("of",o,n,t),(()=>r(n)))}forIn(e,t,r,o=(this.opts.es5?a.varKinds.var:a.varKinds.const)){if(this.opts.ownProperties)return this.forOf(e,s._`Object.keys(${t})`,r);const n=this._scope.toName(e);return this._for(new S("in",o,n,t),(()=>r(n)))}endFor(){return this._endBlockNode($)}label(e){return this._leafNode(new u(e))}break(e){return this._leafNode(new f(e))}return(e){const t=new E;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(E)}try(e,t,r){if(!t&&!r)throw new Error('CodeGen: "try" without "catch" and "finally"');const s=new k;if(this._blockNode(s),this.code(e),t){const e=this.name("e");this._currNode=s.catch=new I(e),t(e)}return r&&(this._currNode=s.finally=new j,this.code(r)),this._endBlockNode(I,j)}throw(e){return this._leafNode(new h(e))}block(e,t){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(t),this}endBlock(e){const t=this._blockStarts.pop();if(void 0===t)throw new Error("CodeGen: not in self-balancing block");const r=this._nodes.length-t;if(r<0||void 0!==e&&r!==e)throw new Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=s.nil,r,a){return this._blockNode(new P(e,t,r)),a&&this.code(a).endFunc(),this}endFunc(){return this._endBlockNode(P)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){const r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){const t=this._currNode;if(!(t instanceof _))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){const e=this._nodes;return e[e.length-1]}set _currNode(e){const t=this._nodes;t[t.length-1]=e}},t.not=T;const D=A(t.operators.AND);t.and=function(...e){return e.reduce(D)};const R=A(t.operators.OR);function A(e){return(t,r)=>t===s.nil?r:r===s.nil?t:s._`${M(t)} ${e} ${M(r)}`}function M(e){return e instanceof s.Name?e:s._`(${e})`}t.or=function(...e){return e.reduce(R)}},9713:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});const s=r(9029),a=r(4227),o={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:e})=>s._`{propertyName: ${e.propertyName}}`},code(e){const{gen:t,schema:r,data:o,it:n}=e;if((0,a.alwaysValidSchema)(n,r))return;const i=t.name("valid");t.forIn("key",o,(r=>{e.setParams({propertyName:r}),e.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},i),t.if((0,s.not)(i),(()=>{e.error(!0),n.allErrors||t.break()}))})),e.ok(i)}};t.default=o},9795:function(e,t,r){function s(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),r=!1,s=0,a=e.length;s<a;s++)-1!=t.indexOf(e[s])&&(r=!0);return r}r.d(t,{Fr:function(){return s}}),r(6773),r(5360)},9857:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]}},a={};function o(e){var t=a[e];if(void 0!==t)return t.exports;var r=a[e]={exports:{}};return s[e](r,r.exports,o),r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};o.r(n),o.d(n,{default:function(){return p}});var i=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",["view"===e.mode?r("div",{staticStyle:{display:"flex","max-width":"360px",cursor:"pointer"},attrs:{title:e.value},on:{click:e.openOptionsModal}},[r("span",{staticStyle:{flex:"1"}},[e._v("\n "+e._s(e.label||"--")+"\n ")]),e._v(" "),r("i",{staticClass:"fa fa-angle-right",attrs:{"aria-hidden":"true"}})]):r("div",{staticStyle:{display:"flex","max-width":"360px",cursor:"pointer"},attrs:{title:e.value},on:{click:e.openOptionsModal}},[r("span",{staticStyle:{flex:"1"}},[e._v("\n "+e._s(e.label||(e.loading?""+e.$z("加载中","c.loading"):""+e.$z("请选择","c.please_select")+e.fieldConf.name+"(多选)"))+"\n "),r("span",{directives:[{name:"show",rawName:"v-show",value:e.loading,expression:"loading"}],staticClass:"typing_loader"})]),e._v(" "),r("i",{staticClass:"fa fa-angle-right",attrs:{"aria-hidden":"true"}})]),e._v(" "),r("el-dialog",{attrs:{title:e.fieldConf.name,visible:e.optionsModalShow,width:"50%",top:"10vh","custom-class":"bpm-select-entrance-form"},on:{"update:visible":function(t){e.optionsModalShow=t},close:e.handleClose}},[r("div",{staticClass:"main-wrap",style:{maxHeight:"70vh",overflow:"auto"}},["view"===e.mode?e._l(e.items,(function(t){return r("el-card",{key:t.form_id,staticClass:"select-option-card",attrs:{shadow:"hover","body-style":{padding:"10px 20px"}}},[r("div",{attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.title))])]),e._v(" "),r("div",{staticClass:"card-body-content"},[r("div",[r("span",{staticClass:"bpm-status_tag-status",style:{background:e.getStatus(t.f_fields[e.statusField.id],"color")}},[e._v(e._s(e.getStatus(t.f_fields[e.statusField.id],"label")))])]),e._v(" "),e._l(e.descFields,(function(s){return r("div",{key:s.id},[r("label",{staticClass:"label"},[e._v(e._s(s.name))]),e._v(" "),r("span",[e._v(e._s(t.f_fields[s.id]))])])}))],2)])})):[r("div",{staticClass:"search-wrap"},[e.enableSearchText?r("el-input",{attrs:{placeholder:e.$z("搜索","c.search_tip")},on:{input:e.debounceSearch},model:{value:e.keyword,callback:function(t){e.keyword=t},expression:"keyword"}},[r("i",{staticClass:"el-input__icon el-icon-search",staticStyle:{cursor:"pointer"},attrs:{slot:"suffix"},on:{click:e.debounceSearch},slot:"suffix"})]):e._e(),e._v(" "),r("el-button",{staticStyle:{"margin-left":"10px"},on:{click:function(t){e.filterModalShow=!0}}},[r("i",{staticClass:"fa fa-filter",attrs:{"aria-hidden":"true"}})])],1),e._v(" "),r("ul",{directives:[{name:"infinite-scroll",rawName:"v-infinite-scroll",value:e.loadMore,expression:"loadMore"}],staticClass:"edit-list"},[r("el-checkbox-group",{model:{value:e.selectedVals,callback:function(t){e.selectedVals=t},expression:"selectedVals"}},e._l(e.items,(function(t){return r("li",{key:t.form_id,staticClass:"edit-list-item"},[r("el-checkbox",{staticClass:"checkbox",attrs:{label:t.id}},[e._v(e._s())]),e._v(" "),r("el-card",{key:t.form_id,staticClass:"select-option-card",attrs:{shadow:"hover","body-style":{padding:"10px 20px"}}},[r("div",{attrs:{slot:"header"},slot:"header"},[r("span",[e._v(e._s(t.title))])]),e._v(" "),r("div",{staticClass:"card-body-content"},[r("div",[r("span",{staticClass:"bpm-status_tag-status",style:{background:e.getStatus(t.f_fields[e.statusField.id],"color")}},[e._v(e._s(e.getStatus(t.f_fields[e.statusField.id],"label")))])]),e._v(" "),e._l(e.descFields,(function(s){return r("div",{key:s.id},[r("label",{staticClass:"label"},[e._v(e._s(s.name))]),e._v(" "),r("span",[e._v(e._s(t.f_fields[s.id]))])])}))],2)])],1)})),0)],1)],e._v(" "),r("div",{directives:[{name:"show",rawName:"v-show",value:e.optionsLoading,expression:"optionsLoading"}],staticStyle:{"text-align":"center",margin:"46px auto"}},[r("span",{staticClass:"typing_loader"})]),e._v(" "),e.optionsLoading||e.items.length?e._e():r("div",[e._v("\n "+e._s(e.$z("暂无记录信息","c.no_record"))+"\n ")])],2),e._v(" "),"edit"===e.mode?r("footer",{staticClass:"footer",attrs:{slot:"footer"},slot:"footer"},[r("div",[r("el-checkbox",{attrs:{label:e.$z("全选","c.select_all")},on:{change:e.handleCheckAll},model:{value:e.checkAll,callback:function(t){e.checkAll=t},expression:"checkAll"}}),e._v(" "),e.selectedLabel?r("span",{staticClass:"subtext"},[e._v(e._s(e.selectedLabel))]):e._e()],1),e._v(" "),r("el-button",{staticClass:"width-button",attrs:{type:"primary",disabled:!e.selectedVals.length},on:{click:e.onSubmit}},[e._v(e._s(e.$z("保存","c.save")))])],1):e._e()]),e._v(" "),r("el-dialog",{attrs:{title:e.$z("数据筛选","b2.common.data_filter"),visible:e.filterModalShow,width:"50%","custom-class":"bpm-select-entrance-form"},on:{"update:visible":function(t){e.filterModalShow=t},close:function(t){e.filterModalShow=!1}}},[r("div",{staticStyle:{"max-height":"70vh",overflow:"auto"}},[r("BpmFieldsFilter",{ref:"searchForm",attrs:{searchSchema:e.searchSchema,verifySchema:e.verifySchema,orgInfo:e.orgInfo,formDefId:e.formSchema.id,showAll:!0,queryExclude:!0},on:{search:e.handleFilterReady}})],1),e._v(" "),r("span",{attrs:{slot:"footer"},slot:"footer"},[r("el-button",{staticClass:"width-button",on:{click:e.handleResetFilter}},[e._v(e._s(e.$z("重置","c.reset")))]),e._v(" "),r("el-button",{staticClass:"width-button",attrs:{type:"primary"},on:{click:e.handleSubmitFilter}},[e._v(e._s(e.$z("查询","c.query")))])],1)])],1)};i._withStripped=!0;var c=o(5281),l=o(9795),d=o(555);const u=["Area","MulArea"];var f={name:"BpmSelectEntranceForm",components:{BpmFieldsFilter:d.A},props:{value:{type:Array,default(){return[]}},type:{type:String,default:"MulSelectEntranceForm"},fieldConf:{type:Object,default(){return{}}},mode:{type:String,default:"view"},uiType:{type:String,default:"default"},formDefId:{type:String,default:""},orgInfo:{type:Object,default(){return{level:"group",level_id:0,group_id:0}}},formId:{type:String,default:""},dm:{type:Boolean,default(){return!1}},isMultiple:{type:Boolean,default(){return!0}}},data(){return{loading:!1,optionsModalShow:!1,items:[],selectedItems:[],selectedVals:[],optionsLoading:!1,statusField:{},descFields:[],shouldTransLabelKeys:[],formSchema:{},pagination:{action:"first",lastAt:null,total:0},checkAll:!1,filterModalShow:!1,searchSchema:{elements:[]},verifySchema:{},enableSearchText:!0,debounceSearch:_.debounce(_.bind(this.loadData,this),300,{trailing:!0,leading:!1}),keyword:"",filterParams:{}}},computed:{isMobile(){return(0,l.Fr)()},label(){const e=this.value;if(!e||!e.length)return"";let t=zj.z("已选择N条","c.number_is_selected");return _.template(t)({count:e.length})},selectedLabel(){if(!this.selectedVals.length)return"";let e=zj.z("选中N条","c.number_is_selected_2");return _.template(e)({count:this.selectedVals.length})}},methods:{getStatus(e,t){return((this.statusField.rangeEnumMap||{})[e]||{})[t]},async openOptionsModal(){this.optionsModalShow=!0,this.formSchema.id||await this.loadSchema(),this.value&&this.value.length&&await this.loadListSelected(),"edit"===this.mode&&(this.pagination.lastAt||(this.handleResetFilter(),this.loadData()),this.selectedVals=this.value||[])},handleClose(){this.optionsModalShow=!1,"edit"===this.mode&&(this.checkAll=!1,this.selectedVals=[])},handleResetFilter(){this.$refs.searchForm&&this.$refs.searchForm.reset()},handleSubmitFilter(){this.$refs.searchForm&&this.$refs.searchForm.submit()},handleFilterReady(e){this.filterParams=e||{},this.filterModalShow=!1,this.loadData()},handleCheckAll(e){this.selectedVals=e?_.map(this.items,(e=>e.id)):[]},onSubmit(){const e=_.cloneDeep(this.selectedVals);this.$emit("input",e),this.$emit("change",e),this.handleClose()},loadMore(){this.items.length<this.pagination.total&&this.loadData("next")},async loadData(e="first"){let t=this.formDefId;const r=this.fieldConf.id;e=["first","next","last","prev"].includes(e)?e:"first";let s=this.filterParams;this.keyword&&(s.q__contains=this.keyword),this.optionsLoading=!0;const a=(await c.A.assistSelectEntranceForm.getOptions(this.$bpm,{formDefId:t,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},{action:e,limit:20,last_at:"first"===e?null:this.pagination.lastAt,fields:JSON.stringify(s)})).data.data;console.log("assist_select_entrance_form data: ",a);const o=_.map(a.data,(e=>(_.each(e.f_fields,(async(t,r)=>{if(this.shouldTransLabelKeys.includes(r))if(_.isArray(t)){const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.loads(...t);e.f_fields[r]=a.join(zj.z(",","c.comma"))}else{const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.load(t);e.f_fields[r]=a}})),{title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:_.map(e.f_fields,((e,t)=>({key:t,value:e})))})));let n=o;if(this.selectedItems.length){let e=_.map(this.selectedItems,(e=>e.id));n=_.filter(o,(t=>!e.includes(t.id)))}this.items="next"===e?_.concat(this.items,n):_.concat(this.selectedItems,n),this.pagination.action=e,this.pagination.lastAt=a.last_at,this.pagination.total=a.count,this.optionsLoading=!1},async loadListSelected(){let e=this.formId;e=encodeURIComponent(e);let t=this.formDefId;const r=this.fieldConf.id;this.optionsLoading=!0;try{const s=(await c.A.assistSelectEntranceForm.getListSelected(this.$bpm,{formDefId:t,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},{form_id:e})).data.data;console.log("assist_select_entrance_form list_selected: ",s);const a=_.map(s.data,(e=>(_.each(e.f_fields,(async(t,r)=>{if(this.shouldTransLabelKeys.includes(r))if(_.isArray(t)){const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.loads(...t);e.f_fields[r]=a.join(zj.z(",","c.comma"))}else{const s=c.A.assistField.getBatchLoader(this.$bpm,{formDefId:this.formSchema.id,fieldDefId:r,orgInfo:this.orgInfo});let a=await s.load(t);e.f_fields[r]=a}})),{title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:_.map(e.f_fields,((e,t)=>({key:t,value:e})))})));this.selectedItems=a,"view"===this.mode&&(this.items=a)}finally{this.optionsLoading=!1}},async loadSchema(){let e=this.formDefId;const t=this.fieldConf.id,r=(await c.A.assistSelectEntranceForm.getListDefinition(this.$bpm,{formDefId:e,fieldDefId:t,orgInfo:this.orgInfo,isDm:this.dm})).data.data;console.log("assist_select_entrance_form definition: ",r);let s={},a=[],o=[];_.each(r.definition.form.elements,(e=>{if("Status"!==e.type)a.push({id:e.id,name:e.name,value_type:e.value_type,type:e.type});else{let t={};e.range_enum.forEach((e=>{t[e[0]]={value:e[0],label:e[1],color:e[2]}})),s={id:e.id,name:e.name,value_type:e.value_type,type:e.type,rangeEnumMap:t}}(u.includes(e.type)||e.type.indexOf("Select")>-1)&&o.push(e.id)})),this.descFields=a,this.statusField=s,this.shouldTransLabelKeys=o,this.formSchema=r.definition.form,this.searchSchema=_.get(r,"definition.search",{elements:[]}),this.verifySchema=_.get(r,"schema.search",{});const n=!!this.searchSchema.elements&&_.find(this.searchSchema.elements,{id:"q__contains"});this.enableSearchText=this.searchSchema.enable_search_text&&n}}},h=(0,o(4486).A)(f,i,[],!1,null,null,null);h.options.__file="components/lib/bpmSelectEntranceForm/src/main.vue";var m=h.exports;m.install=function(e){e.component(m.name,m)};var p=m;return n}()}));