text: define(["exports"],(function(e){"use strict";
  /*! *****************************************************************************
      Copyright (c) Microsoft Corporation. All rights reserved.
      Licensed under the Apache License, Version 2.0 (the "License"); you may not use
      this file except in compliance with the License. You may obtain a copy of the
      License at http://www.apache.org/licenses/LICENSE-2.0
  
      THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
      KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
      WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
      MERCHANTABLITY OR NON-INFRINGEMENT.
  
      See the Apache Version 2.0 License for specific language governing permissions
      and limitations under the License.
      ***************************************************************************** */var r=function(){return(r=Object.assign||function(e){for(var r,t=1,n=arguments.length;t<n;t++)for(var a in r=arguments[t])Object.prototype.hasOwnProperty.call(r,a)&&(e[a]=r[a]);return e}).apply(this,arguments)};function t(e,r,t,n){return new(t||(t=Promise))((function(a,o){function i(e){try{l(n.next(e))}catch(e){o(e)}}function u(e){try{l(n.throw(e))}catch(e){o(e)}}function l(e){var r;e.done?a(e.value):(r=e.value,r instanceof t?r:new t((function(e){e(r)}))).then(i,u)}l((n=n.apply(e,r||[])).next())}))}function n(e,r){var t,n,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(o){return function(u){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;i;)try{if(t=1,n&&(a=2&o[0]?n.return:o[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,o[1])).done)return a;switch(n=0,a&&(o=[2&o[0],a.value]),o[0]){case 0:case 1:a=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,n=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==o[0]&&2!==o[0])){i=0;continue}if(3===o[0]&&(!a||o[1]>a[0]&&o[1]<a[3])){i.label=o[1];break}if(6===o[0]&&i.label<a[1]){i.label=a[1],a=o;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(o);break}a[2]&&i.ops.pop(),i.trys.pop();continue}o=r.call(e,i)}catch(e){o=[6,e],n=0}finally{t=a=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,u])}}}function a(e){return Object.prototype.toString.call(e)}function o(e){return"[object Object]"===a(e)}function i(e){return"[object Array]"===a(e)}function u(e){return"function"==typeof e}function l(e){return null!==e&&"object"==typeof e&&u(e.then)}function c(e,r){return e.hasOwnProperty(r)}function s(e,r){if(0===r.length)return e;var t=e;return r.slice(0,-1).forEach((function(e){t=t[e]})),t[r[r.length-1]]}function f(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r]}var v="__form_validation__",h="__form_validation_reactive",d="__form_validation_collected",p=function(e,r,t){var n;(o(e)||i(e))&&Object.defineProperty(e,h,{enumerable:!1,configurable:!0,value:e}),(o(r)||i(r))&&(Object.defineProperty(r,h,{enumerable:!1,configurable:!0,value:r}),Object.defineProperty(r,v,{enumerable:!1,configurable:!0,value:r[v]||(n={},n.path=t,n)}),Object.defineProperty(r,"$v",{enumerable:!1,configurable:!0,value:r.$v||{}}))},$=function(e,r){var t;if(!1!==o(e)||!1!==i(e))for(var n in(t=e[v].path).splice.apply(t,function(){for(var e=0,r=0,t=arguments.length;r<t;r++)e+=arguments[r].length;var n=Array(e),a=0;for(r=0;r<t;r++)for(var o=arguments[r],i=0,u=o.length;i<u;i++,a++)n[a]=o[i];return n}([0,r.length],r)),e)$(e[n],r.concat(n))},m=new Set(["shift","unshift","reverse","splice"]),y=function(e){var r=e.object,t=e.clone,n=e.path,a=void 0===n?[]:n,u=e.wrap,l=void 0===u?p:u,s=e.callback,f=void 0===s?function(){}:s;if(l(r,t,a),(o(t)||i(t))&&f(t),!1===o(r)&&!1===i(r))return r;for(var h=0,b=Object.keys(r);h<b.length;h++){var g=b[h];Reflect.set(t,g,t[g]||(i(r[g])?[]:{})),Reflect.set(r,g,y({object:r[g],clone:t[g],path:a.concat(g),wrap:l,callback:f}))}for(var g in t)!1===c(r,g)&&delete t[g];var j=null,O=0,P=0,k=[],w=[],_=[];return new Proxy(r,{deleteProperty:function(e,r){return Reflect.deleteProperty(t,r),Reflect.deleteProperty(e,r)},set:function(e,r,n){var o=Reflect.set(e,r,n);if(!1===c(e,r))return o;if(i(e))if("shift"===j){if("length"===r){k.reverse(),k.pop(),t.length=0;for(var u=0;u<k.length;){var s=k[u];s[v].path=s[v].path.slice(0,-1).concat(k.length-u-1+""),t.push(s),++u}for(var h in t.reverse(),j=null,$(t,t[v].path),t)f(t[h]);return o}/^\d+$/.test(r)&&(t[r]=i(n)?[]:{})}else if("unshift"===j){if("length"===r){t.length=0;for(var d=0;d<k.length;){var p=k[d];p[v].path=p[v].path.slice(0,-1).concat(k.length-d-1+""),t.push(p),++d}for(var m in t.reverse(),j=null,$(t,t[v].path),t)f(t[m]);return o}/^\d+$/.test(r)&&(t[r]=i(n)?[]:{},"0"===r&&k.push(t[0]))}else if("reverse"===j){if(/^\d+$/.test(r)){var b=k.pop();if(b[v].path=b[v].path.slice(0,-1).concat(r),t[r]=b,++P===O){for(var g in $(t,t[v].path),t)f(t[g]);j=null}return o}}else if("splice"===j){if("length"===r){for(var _ in j=null,t[r]=n,w){var x=w[_],R=x.method,I=x.key,S=x.value,z=parseInt(_,10)-1;"set"===R&&(z>=0&&"get"===w[z].method?t[I]=w[z].value:t[I]=S)}for(var D in $(t,t[v].path),t)t[D][v].path=t[D][v].path.slice(0,-1).concat(D+""),f(t[D]);return o}/^\d+$/.test(r)&&(t[r]=i(n)?[]:{},w.push({method:"set",key:r,value:t[r]}))}else if("length"===r)return t.length=n,o;return i(n)?(t[r]=t[r]||[],t[r].length=n.length):t[r]=t[r]||{},Reflect.set(e,r,y({object:n,clone:t[r],path:a.concat(r),wrap:l,callback:f}))},get:function(e,r){var n=Reflect.get(e,r);if(i(e))if(m.has(r))for(var a in j=r,P=0,k.length=0,w.length=0,_.length=0,t)delete t[a][d];else null!==j&&("shift"===j||"unshift"===j?/^\d+$/.test(r)&&t[r]&&void 0===t[r][d]&&(Object.defineProperty(t[r],d,{enumerable:!1,configurable:!0,value:t[r]}),k.push(t[r])):"reverse"===j?"length"===r?e[r]<=1?(j=null,O=0):O=n%2==0?n:n-1:/^\d+$/.test(r)&&t[r]&&void 0===t[r][d]&&(Object.defineProperty(t[r],d,{enumerable:!1,configurable:!0,value:t[r]}),k.push(t[r])):"splice"===j&&/^\d+$/.test(r)&&t[r]&&void 0===t[r][d]&&(Object.defineProperty(t[r],d,{enumerable:!1,configurable:!0,value:t[r]}),w.push({method:"get",key:r,value:t[r]})));return n}})},b=function(e){var r=e.rootSchema,t=e.validator,n=e.path,a=e.startIndex;if(a===n.length){try{var i=s(r,n);if(g(i))return o(i.$params)&&(t[v].schema.$params=i.$params),u(i.$normalizer)&&(t[v].schema.$normalizer=i.$normalizer),o(i.$rules)&&(t[v].schema.$rules=i.$rules),o(i.$errors)&&(t[v].schema.$errors=i.$errors),!0}catch(e){}return!1}if(b({rootSchema:r,validator:t,path:n,startIndex:a+1}))return!0;var l=n[a];return n[a]="$iter",!!b({rootSchema:r,validator:t,path:n,startIndex:a+1})||(n[a]=l,!1)},g=function(e){return void 0!==e&&(void 0!==e.$params||(void 0!==e.$normalizer||(void 0!==e.$rules||void 0!==e.$errors)))};var j=function(e){return function(r){e[v].validated=r}},O=function(e){return function(r){e[v].invalid=r}},P=function(e){return function(r){e[v].dirty=r}},k=function(e){return function(r){e[v].pending+=!0===r?1:-1}},w=function(e){return function(){e[v].pending=0}},_=function(e){return 0!==e[v].pending||D(e).some((function(e){return e.$v.pending}))},x=function(e){return e[v].invalid&&0===e[v].pending||D(e).some((function(e){return e.$v.invalid}))},R=function(e){return e[v].dirty||0!==D(e).length&&D(e).every((function(e){return e.$v.dirty}))},I=function(e){return e[v].dirty||D(e).some((function(e){return e.$v.anyDirty}))},S=function(e){return e[v].dirty&&e[v].invalid&&0===e[v].pending},z=function(e){return e[v].dirty&&e[v].invalid&&0===e[v].pending||D(e).some((function(e){return e.$v.anyError}))},D=function(e){return Object.keys(e).filter((function(e){return e!==v&&"$v"!==e})).map((function(r){return e[r]}))},E=function(e,a){var o=a[v].schema;a.$v.validate=function(){a[v].setValidated(!0),a[v].setInvalid(!1),a[v].resetPending(),a.$v.errors={},a[v].previousResult={};var i=function(e){for(var a,o,i=e.rootForm,u=e.validator,c=r(((a={}).$rules={},a),u[v].schema.$params),f=u[v].schema.$normalizer,h=u[v].schema.$rules,d=u[v].schema.$errors,p=i,$=u[v].path,m=0===$.length?void 0:s(i,$.slice(0,-1)),y=0===$.length?void 0:$[$.length-1],b=f({value:0===$.length?i:s(i,$),key:y,parent:m,path:$,root:p,params:c}),g=((o={}).$rules={},o),j=function(e){var r={value:b,key:y,parent:m,path:$,root:p,params:c},a=h[e](r);g.$rules[e]=a,r.params.$rules[e]=a,g[e]=void 0,l(a)?a.finally((function(){return t(void 0,void 0,void 0,(function(){return n(this,(function(t){switch(t.label){case 0:return[4,a];case 1:return void 0!==t.sent()&&(g[e]=d[e](r)),[2]}}))}))})):void 0!==a&&(g[e]=d[e](r))},O=0,P=Object.keys(h);O<P.length;O++){j(P[O])}return g}({rootForm:e,validator:a});a[v].previousResult=i.$rules,i.$rules=a[v].previousResult;for(var u=function(e){l(i.$rules[e])?(a[v].setPending(!0),i.$rules[e].finally((function(){return t(void 0,void 0,void 0,(function(){var r,t;return n(this,(function(n){switch(n.label){case 0:return a[v].previousResult!==i.$rules?[2]:[4,i.$rules[e]];case 1:return void 0===n.sent()?[3,3]:(a[v].setInvalid(!0),r=a.$v.errors,t=e,[4,i[e]]);case 2:r[t]=n.sent(),n.label=3;case 3:return a[v].setPending(!1),[2]}}))}))}))):void 0!==i.$rules[e]&&(a[v].setInvalid(!0),a.$v.errors[e]=i[e])},c=0,f=Object.keys(o.$rules);c<f.length;c++){u(f[c])}for(var h={},d=0,p=Object.keys(a).filter((function(e){return"$v"!==e&&e!==v}));d<p.length;d++){var $=p[d];h[$]=a[$].$v.validate()}return Promise.all(Object.values(i.$rules)).then((function(){return Promise.all(Object.values(h))})).then((function(){}))},a.$v.reset=function(){a[v].setValidated(!1),a[v].setInvalid(!1),a[v].setDirty(!1),a[v].resetPending(),a[v].previousResult={},a.$v.errors={};for(var e=0,r=Object.keys(a).filter((function(e){return"$v"!==e&&e!==v}));e<r.length;e++){var t=r[e];a[t].$v.reset()}},a.$v.touch=function(){a[v].setDirty(!0);for(var e=0,r=Object.keys(a).filter((function(e){return"$v"!==e&&e!==v}));e<r.length;e++){var t=r[e];a[t].$v.touch()}}};e.proxy=function(e){var r=e.form,t=e.schema,n=e.validator;return y({object:r,clone:n,callback:function(e){!function(e){var r=e;void 0===r[v].invalid&&(r[v].invalid=!1,r[v].validated=!1,r[v].pending=0,r[v].dirty=!1,r[v].setValidated=j(r),r[v].setInvalid=O(r),r[v].setDirty=P(r),r[v].setPending=k(r),r[v].resetPending=w(r),Object.defineProperty(r.$v,"pending",{enumerable:!0,get:function(){return _(r)}}),Object.defineProperty(r.$v,"invalid",{enumerable:!0,get:function(){return x(r)}}),Object.defineProperty(r.$v,"dirty",{enumerable:!0,get:function(){return R(r)}}),Object.defineProperty(r.$v,"anyDirty",{enumerable:!0,get:function(){return I(r)}}),Object.defineProperty(r.$v,"error",{enumerable:!0,get:function(){return S(r)}}),Object.defineProperty(r.$v,"anyError",{enumerable:!0,get:function(){return z(r)}}),r.$v.errors={})}(e),function(e){var r=e.rootSchema,t=e.validator,n=t[v].path,a={$params:{},$normalizer:function(e){return e.value},$rules:{},$errors:{}};for(var o in t[v].schema=t[v].schema||{},t[v].schema.$params=a.$params,t[v].schema.$normalizer=a.$normalizer,t[v].schema.$rules=a.$rules,t[v].schema.$errors=a.$errors,b({rootSchema:r,validator:t,path:n.slice(),startIndex:0}),t[v].schema.$rules)void 0===t[v].schema.$errors[o]&&(t[v].schema.$errors[o]=f)}({rootSchema:t,validator:e}),E(r,e),e[v].validated&&e.$v.validate()}})},Object.defineProperty(e,"__esModule",{value:!0})}));
  