@nocobase/app 1.2.29-alpha → 1.3.0-alpha

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.
@@ -21,6 +21,6 @@
21
21
  </head>
22
22
  <body>
23
23
  <div id="root"></div>
24
- <script src="/umi.b941fef1.js"></script>
24
+ <script src="/umi.87619022.js"></script>
25
25
 
26
26
  </body></html>
@@ -21,6 +21,6 @@
21
21
  </head>
22
22
  <body>
23
23
  <div id="root"></div>
24
- <script src="/umi.b941fef1.js"></script>
24
+ <script src="/umi.87619022.js"></script>
25
25
 
26
26
  </body></html>
@@ -650,7 +650,7 @@ https://requirejs.org/docs/errors.html#`+ze);return l.requireType=ze,l.requireMo
650
650
  padding: 2px 7px;
651
651
  border-radius: 10px;
652
652
  }
653
- `]))))}));return(0,ne.jsx)(se.BQs,{ellipsis:!0,popoverContent:Et,children:Et})};var qt=(0,l.createContext)([]);qt.displayName="VariableScopeContext";function In(Ft){var Mn=Ft.scope,Ct=Mn===void 0?[]:Mn,hn=Ft.children;return(0,ne.jsx)(qt.Provider,{value:Ct,children:hn})}function un(){return(0,l.useContext)(qt)}function yn(){return null}yn.Input=(0,L.connect)(Ae),yn.TextArea=(0,L.connect)(ut,(0,L.mapReadPretty)(ut.ReadPretty)),yn.RawTextArea=(0,L.connect)(Me),yn.JSON=(0,L.connect)(Ue);var qn=null},88969:function(ze,re,e){"use strict";e.d(re,{m:function(){return u}});var L=e(15009),l=e.n(L),K=e(19632),p=e.n(K),A=e(99289),x=e.n(A),N=e(5574),r=e.n(N),B=e(97133),h=e(38089),I=e(67294),b=e(26793),T=e(60094),t=e(9783),o=e.n(t),d=(0,T.l6)("nb-variable-select",function(j){var F=j.componentCls;return o()({},F,{position:"relative",".ant-select.ant-cascader":{position:"absolute",top:"-1px",right:"-1px",minWidth:"auto",width:"calc(100% + 2px)",height:"calc(100% + 2px)",overflow:"hidden",opacity:0},".variable-btn":{fontStyle:"italic",fontFamily:"'New York', 'Times New Roman', Times, serif"},".Cascader-popupClassName":{".ant-cascader-menu":{marginBottom:0}}})}),R=d,P=e(2876),g=e(85893);function u(j){var F=j.options,z=j.setOptions,y=j.onInsert,E=j.changeOnSelect,C=E===void 0?!1:E,a=j.fieldNames,D=a===void 0?{}:a,c=j.className,v=(0,b.$)(),i=v.t,m=(0,I.useState)([]),f=r()(m,2),O=f[0],n=f[1],U=R(),k=U.wrapSSR,H=U.componentCls,$=U.hashId,V=(0,T.dQ)(),w=V.token;function G(X){return ne.apply(this,arguments)}function ne(){return ne=x()(l()().mark(function X(ae){var oe,ee;return l()().wrap(function(de){for(;;)switch(de.prev=de.next){case 0:if(ee=ae[ae.length-1],!(!((oe=ee.children)!==null&&oe!==void 0&&oe.length)&&!ee.isLeaf&&ee.loadChildren)){de.next=5;break}return de.next=4,ee.loadChildren(ee);case 4:z(function(me){return p()(me)});case 5:case"end":return de.stop()}},X)})),ne.apply(this,arguments)}return k((0,g.jsx)(P.R,{className:(0,B.cx)("x-button",H,$,c),children:(0,g.jsx)(h.Z,{placeholder:i("Select a variable"),value:[],options:F,fieldNames:D,loadData:G,onChange:function(){var ae,oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];if(n(oe),!!oe.length){var W=ee[ee.length-1];(!(W!=null&&(ae=W.children)!==null&&ae!==void 0&&ae.length)&&!(W!=null&&W.loadChildren)||W!=null&&W.isLeaf)&&y(oe)}},changeOnSelect:C,onClick:function(ae){if(!(ae.detail!==2||!C))for(var oe=ae.target;oe&&oe!==ae.currentTarget;oe=oe.parentNode){var ee;Array.from((ee=oe.classList)!==null&&ee!==void 0?ee:[]).includes("ant-cascader-menu-item")&&y(O)}},popupClassName:"Cascader-popupClassName",dropdownRender:C?function(X){return(0,g.jsxs)(g.Fragment,{children:[X,(0,g.jsx)("div",{style:{padding:"0.5em",borderTop:"1px solid ".concat(w.colorBorder),color:w.colorTextDescription},children:i("Double click to choose entire object")})]})}:null})}))}},2876:function(ze,re,e){"use strict";e.d(re,{R:function(){return x}});var L=e(97857),l=e.n(L),K=e(15867),p=e(67294),A=e(85893),x=(0,p.forwardRef)(function(N,r){var B=(0,p.useMemo)(function(){return{fontStyle:"italic",fontFamily:"New York, Times New Roman, Times, serif"}},[]);return(0,A.jsxs)(K.ZP,l()(l()({"aria-label":"variable-button",ref:r,style:B},N),{},{children:["x",N.children]}))});x.displayName="XButton"},72724:function(ze,re,e){"use strict";e.d(re,{L:function(){return T}});var L=e(97857),l=e.n(L),K=e(5574),p=e.n(K),A=e(94697),x=e(94350),N=e(67294),r=e(26793),B=e(21143),h=e(84577),I=e(85893),b=function(o){var d=(0,h.ng)(),R=d.refresh,P=(0,B.useAPIClient)(),g=(0,r.$)(),u=g.t;return(0,N.useCallback)(function(j){var F,z,y,E,C,a,D,c,v=j.active,i=j.over,m=v==null||(F=v.data)===null||F===void 0||(F=F.current)===null||F===void 0?void 0:F.schema,f=i==null||(z=i.data)===null||z===void 0||(z=z.current)===null||z===void 0?void 0:z.schema,O=i==null||(y=i.data)===null||y===void 0||(y=y.current)===null||y===void 0?void 0:y.insertAdjacent,n=i==null||(E=i.data)===null||E===void 0||(E=E.current)===null||E===void 0?void 0:E.breakRemoveOn,U=i==null||(C=i.data)===null||C===void 0||(C=C.current)===null||C===void 0?void 0:C.wrapSchema,k=i==null||(a=i.data)===null||a===void 0||(a=a.current)===null||a===void 0?void 0:a.onSuccess,H=(D=i==null||(c=i.data)===null||c===void 0||(c=c.current)===null||c===void 0?void 0:c.removeParentsIfNoChildren)!==null&&D!==void 0?D:!0;if(!m||!f){o==null||o(j);return}if(m===f){o==null||o(j);return}if(m.parent===f&&O==="beforeEnd"){o==null||o(j);return}var $=(0,h.Pl)({t:u,api:P,refresh:R,current:f});if($.loadAPIClientEvents(),m.parent===f.parent){$.insertBeforeBeginOrAfterEnd(m),o==null||o(j);return}if(O){$.insertAdjacent(O,m,{wrap:U,breakRemoveOn:n,removeParentsIfNoChildren:H,onSuccess:k}),o==null||o(j);return}},[o])},T=(0,x.observer)(function(t){var o=(0,r.$)(),d=o.t,R=(0,N.useState)(!0),P=p()(R,2),g=P[0],u=P[1],j=(0,N.useCallback)(function(z){var y,E=z.active,C=E==null||(y=E.data)===null||y===void 0||(y=y.current)===null||y===void 0?void 0:y.schema;if(u(!!C),t!=null&&t.onDragStart){var a;t==null||(a=t.onDragStart)===null||a===void 0||a.call(t,z)}},[t==null?void 0:t.onDragStart]),F=b(t==null?void 0:t.onDragEnd);return(0,I.jsxs)(A.DndContext,l()(l()({collisionDetection:A.rectIntersection},t),{},{onDragStart:j,onDragEnd:F,children:[(0,I.jsx)(A.DragOverlay,{dropAnimation:{duration:10,easing:"cubic-bezier(0.18, 0.67, 0.6, 1.22)"},children:g&&(0,I.jsx)("span",{style:{whiteSpace:"nowrap"},children:d("Dragging")})}),t.children]}))},{displayName:"DndContext"})},14896:function(ze,re,e){"use strict";e.r(re),e.d(re,{DndContext:function(){return L.L},DragHandler:function(){return l.IW},DraggableContext:function(){return l.LC},ShowFormData:function(){return x},Sortable:function(){return l.bt},SortableContext:function(){return l.Fo},SortableItem:function(){return l.TR},SortableProvider:function(){return l.OR}});var L=e(72724),l=e(20493),K=e(67294),p=e(94350),A=e(85893),x=(0,p.observer)(function(N){var r=N.children,B=(0,p.useForm)();return(0,A.jsxs)(A.Fragment,{children:[(0,A.jsx)("pre",{style:{marginBottom:20},"data-testid":"form-data",children:JSON.stringify(B.values,null,2)}),r]})})},20493:function(ze,re,e){"use strict";e.d(re,{IW:function(){return j},LC:function(){return t},bt:function(){return R},Fo:function(){return o},TR:function(){return u},OR:function(){return d}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(10274),x=e(94697),N=e(97133),r=e(94350),B=e(67294),h=e(60094),I=e(85893),b=["component","overStyle","style","children","openMode"],T=["schema","id","eid","removeParentsIfNoChildren"],t=(0,B.createContext)(null);t.displayName="DraggableContext";var o=(0,B.createContext)(null);o.displayName="SortableContext";var d=function(z){var y=z.id,E=z.data,C=z.children,a=(0,x.useDraggable)({id:y,data:E}),D=(0,x.useDroppable)({id:y,data:E});return(0,I.jsx)(o.Provider,{value:{draggable:a,droppable:D},children:C})},R=function(z){var y,E,C=z.component,a=z.overStyle,D=z.style,c=z.children,v=z.openMode,i=p()(z,b),m=(0,h.dQ)(),f=m.token,O=(0,B.useContext)(o),n=O.draggable,U=O.droppable,k=U.isOver,H=U.setNodeRef,$=l()({},D);return k&&(n==null||(y=n.active)===null||y===void 0?void 0:y.id)!==(U==null||(E=U.over)===null||E===void 0?void 0:E.id)&&($[C==="a"?"color":"background"]=new A.C(f.colorSettings).setAlpha(.15).toHex8String(),Object.assign($,a)),B.createElement(C||"div",l()(l()({role:"none"},i),{},{className:(0,N.cx)("nb-sortable-designer",z.className),ref:H,style:$}),c)},P=function(z){var y=g(z),E=(0,r.useFieldSchema)();return z.schema?l()(l()({},z),{},{id:y}):l()(l()({},z),{},{id:y,schema:E})},g=function(z){var y=(0,r.useField)();return z.id?z.id:y.address.toString()},u=(0,r.observer)(function(F){var z=P(F),y=z.schema,E=z.id,C=z.eid,a=z.removeParentsIfNoChildren,D=p()(z,T),c=(0,B.useMemo)(function(){return{insertAdjacent:"afterEnd",schema:y,removeParentsIfNoChildren:a!=null?a:!0}},[y,a]);return(0,I.jsx)(d,{id:E,data:c,children:(0,I.jsx)(R,l()(l()({id:C},D),{},{children:F.children}))})},{displayName:"SortableItem"}),j=function(z){var y=(0,B.useContext)(o),E=y.draggable,C=E.attributes,a=E.listeners,D=E.setNodeRef;return(0,I.jsx)("div",{style:{display:"inline-block",width:14,height:14,lineHeight:"14px",textAlign:"left"},children:(0,I.jsx)("div",l()(l()(l()({ref:D,style:{position:"relative",zIndex:1,lineHeight:0,fontSize:0,display:"inline-block"}},a),C),{},{role:"none",children:(0,I.jsx)("span",{style:{cursor:"move",fontSize:14},children:z.children})}))})}},34588:function(ze,re,e){"use strict";e.d(re,{jC:function(){return F},od:function(){return g},Rq:function(){return u},e7:function(){return P}});var L=e(15009),l=e.n(L),K=e(9783),p=e.n(K),A=e(5574),x=e.n(A),N=e(99289),r=e.n(N),B=e(52677),h=e.n(B),I=e(96486),b=e.n(I),T=e(76690),t=e(65565),o=e(27484),d=e.n(o);function R(){"use strict";Array.isArray||(Array.isArray=function(D){return Object.prototype.toString.call(D)==="[object Array]"});function y(D){for(var c=[],v=0,i=D.length;v<i;v++)c.indexOf(D[v])===-1&&c.push(D[v]);return c}function E(D,c){return JSON.stringify(D)===JSON.stringify(c)}var C={},a={$is:function(c,v){return c===v},$match:function(c,v){return Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return(i==null?void 0:i.length)===v.length&&(i==null?void 0:i.every(function(m,f){return m===v[f]}))}):JSON.stringify(c)===JSON.stringify(v)},$eq:function(c,v){return Array.isArray(c)&&Array.isArray(v)?E(c,v):Array.isArray(c)?c.includes(v):c===v},$ne:function(c,v){return c!=v},"!==":function(c,v){return c!==v},$gt:function(c,v){return Array.isArray(c)?c.some(function(i){return i>v}):c>v},$gte:function(c,v){return c>=v},$lt:function(c,v,i){return Array.isArray(c)?c.some(function(m){return m<v}):i===void 0?c<v:c<v&&v<i},$lte:function(c,v,i){return i===void 0?c<=v:c<=v&&v<=i},$exists:function(c){return C.truthy(c)},$notEmpty:function(c){return C.truthy(c)},$empty:function(c){return Array.isArray(c)?c.some(function(v){return!C.truthy(v)}):!C.truthy(c)},$notExists:function(c){return!C.truthy(c)},"%":function(c,v){return c%v},log:function(c){return console.log(c),c},$in:function(c,v){return!v||typeof v.indexOf=="undefined"?!1:Array.isArray(c)&&Array.isArray(v)?v.some(function(i){return c.includes(i)}):v.indexOf(c)!==-1},$notIn:function(c,v){return!v||typeof v.indexOf=="undefined"?!1:v.indexOf(c)===-1},$includes:function(c,v){return!c||typeof c.indexOf=="undefined"?!1:Array.isArray(c)?c.some(function(i){return i==null?void 0:i.includes(v)}):c.indexOf(v)!==-1},$notIncludes:function(c,v){return!c||typeof c.indexOf=="undefined"?!1:Array.isArray(c)?!c.some(function(i){return i.includes(v)}):c.indexOf(v)===-1},$anyOf:function(c,v){return c.length===0?!1:Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return i.some(function(m){return v.includes(m)})}):c.some(function(i){return v.includes(i)})},$noneOf:function(c,v){return!c||(c==null?void 0:c.length)===0?!0:Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return i.every(function(m){return!v.some(function(f){return m.includes(f)})})}):v.some(function(i){return!c.includes(i)})},$notMatch:function(c,v){if(c.length!==v.length)return!0;for(var i=0;i<c.length;i++)if(c[i]!==v[i])return!0;return!1},$dateOn:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isBetween(v[0],v[1],null,"[]")&&c[1].isBetween(v[0],v[1],null,"[]"))},$dateBefore:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isBefore(v[0])&&c[1].isBefore(v[0]))},$dateNotBefore:function(c,v){return!a.$dateBefore(c,v)},$dateAfter:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isAfter(v[1])&&c[1].isAfter(v[1]))},$dateNotAfter:function(c,v){return!a.$dateAfter(c,v)},$dateBetween:function(c,v){return a.$dateOn(c,v)},$dateNotOn:function(c,v){return!a.$dateOn(c,v)},$isTruly:function(c){return Array.isArray(c)?c.some(function(v){return v===!0||v===1}):c===!0||c===1},$isFalsy:function(c){return Array.isArray(c)?c.some(function(v){return!C.truthy(v)}):!C.truthy(c)},cat:function(){return Array.prototype.join.call(arguments,"")},substr:function(c,v,i){if(i<0){var m=String(c).substr(v);return m.substr(0,m.length+i)}return String(c).substr(v,i)},"+":function(){return Array.prototype.reduce.call(arguments,function(c,v){return parseFloat(c,10)+parseFloat(v,10)},0)},"*":function(){return Array.prototype.reduce.call(arguments,function(c,v){return parseFloat(c,10)*parseFloat(v,10)})},"-":function(c,v){return v===void 0?-c:c-v},"/":function(c,v){return c/v},min:function(){return Math.min.apply(this,arguments)},max:function(){return Math.max.apply(this,arguments)},merge:function(){return Array.prototype.reduce.call(arguments,function(c,v){return c.concat(v)},[])},var:function(c,v){var i=v===void 0?null:v,m=this;if(typeof c=="undefined"||c===""||c===null)return m;for(var f=String(c).split("."),O=0;O<f.length;O++)if(m==null||(m=m[f[O]],m===void 0))return i;return m},missing:function(){for(var c=[],v=Array.isArray(arguments[0])?arguments[0]:arguments,i=0;i<v.length;i++){var m=v[i],f=C.apply({var:m},this);(f===null||f==="")&&c.push(m)}return c},missing_some:function(c,v){var i=C.apply({missing:v},this);return v.length-i.length>=c?[]:i}};return C.is_logic=function(D){return h()(D)==="object"&&D!==null&&!Array.isArray(D)&&Object.keys(D).length===1},C.truthy=function(D){return Array.isArray(D)&&D.length===0?!1:!!D},C.get_operator=function(D){return Object.keys(D)[0]},C.get_values=function(D){return D[C.get_operator(D)]},C.apply=function(D,c){if(Array.isArray(D))return D.map(function($){return C.apply($,c)});if(!C.is_logic(D))return D;var v=C.get_operator(D),i=D[v],m,f,O,n,U;if(Array.isArray(i)||(i=[i]),v==="if"||v=="?:"){for(m=0;m<i.length-1;m+=2)if(C.truthy(C.apply(i[m],c)))return C.apply(i[m+1],c);return i.length===m+1?C.apply(i[m],c):null}else if(v==="$and"){for(m=0;m<i.length;m+=1)if(f=C.apply(i[m],c),!C.truthy(f))return f;return f}else if(v==="or"){for(m=0;m<i.length;m+=1)if(f=C.apply(i[m],c),C.truthy(f))return f;return f}else{if(v==="filter")return n=C.apply(i[0],c),O=i[1],Array.isArray(n)?n.filter(function($){return C.truthy(C.apply(O,$))}):[];if(v==="map")return n=C.apply(i[0],c),O=i[1],Array.isArray(n)?n.map(function($){return C.apply(O,$)}):[];if(v==="reduce")return n=C.apply(i[0],c),O=i[1],U=typeof i[2]!="undefined"?i[2]:null,Array.isArray(n)?n.reduce(function($,V){return C.apply(O,{current:V,accumulator:$})},U):U;if(v==="all"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!1;for(m=0;m<n.length;m+=1)if(!C.truthy(C.apply(O,n[m])))return!1;return!0}else if(v==="none"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!0;for(m=0;m<n.length;m+=1)if(C.truthy(C.apply(O,n[m])))return!1;return!0}else if(v==="some"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!1;for(m=0;m<n.length;m+=1)if(C.truthy(C.apply(O,n[m])))return!0;return!1}}if(i=i.map(function($){return C.apply($,c)}),a.hasOwnProperty(v)&&typeof a[v]=="function")return a[v].apply(c,i);if(v.indexOf(".")>0){var k=String(v).split("."),H=a;for(m=0;m<k.length;m++){if(!H.hasOwnProperty(k[m]))throw new Error("Unrecognized operation "+v+" (failed at "+k.slice(0,m+1).join(".")+")");H=H[k[m]]}return H.apply(c,i)}throw new Error("Unrecognized operation "+v)},C.uses_data=function(D){var c=[];if(C.is_logic(D)){var v=C.get_operator(D),i=D[v];Array.isArray(i)||(i=[i]),v==="var"?c.push(i[0]):i.forEach(function(m){c.push.apply(c,C.uses_data(m))})}return y(c)},C.add_operation=function(D,c){a[D]=c},C.rm_operation=function(D){delete a[D]},C.rule_like=function(D,c){if(c===D||c==="@")return!0;if(c==="number")return typeof D=="number";if(c==="string")return typeof D=="string";if(c==="array")return Array.isArray(D)&&!C.is_logic(D);if(C.is_logic(c)){if(C.is_logic(D)){var v=C.get_operator(c),i=C.get_operator(D);if(v==="@"||v===i)return C.rule_like(C.get_values(D,!1),C.get_values(c,!1))}return!1}if(Array.isArray(c))if(Array.isArray(D)){if(c.length!==D.length)return!1;for(var m=0;m<c.length;m+=1)if(!C.rule_like(D[m],c[m]))return!1;return!0}else return!1;return!1},C}var P=function(E,C){var a,D=/{{(.*?)}}/,c=E==null||(a=E.match)===null||a===void 0?void 0:a.call(E,D);if(c){var v=b().get(C,c[1]);return b().isFunction(v)?v():v}else return E};function g(y){if(h()(y)!=="object"||y===null)return null;for(var E in y)if(Object.prototype.hasOwnProperty.call(y,E))return Object.prototype.toString.call(y[E])==="[object Object]"&&y[E]!==null?g(y[E]):{key:E,value:y[E]};return null}var u=function(E){var C=j(E),a=(0,I.findIndex)(C,function(c,v,i){if(c.includes("$")&&v>0)return!0}),D=C.slice(0,a);return D};function j(y){var E=[];function C(a){Object.keys(a).sort().forEach(function(D){E.push(D),a[D]&&h()(a[D])==="object"&&C(a[D])})}return C(y),E}var F=function(){var y=r()(l()().mark(function E(C){var a,D,c,v,i,m;return l()().wrap(function(O){for(;;)switch(O.prev=O.next){case 0:return a=C.ruleGroup,D=C.variables,c=C.localVariables,v=Object.keys(a)[0]||"$and",i=a[v],m=i.map(function(){var n=r()(l()().mark(function U(k){var H,$,V,w,G,ne,X,ae,oe,ee,W;return l()().wrap(function(me){for(;;)switch(me.prev=me.next){case 0:if(!("$and"in k||"$or"in k)){me.next=4;break}return me.next=3,F({ruleGroup:k,variables:D,localVariables:c});case 3:return me.abrupt("return",me.sent);case 4:if(H=g(k),$=H==null?void 0:H.key,$){me.next=8;break}return me.abrupt("return",!0);case 8:return V=z(u(k)),w=D.parseVariable(V,c),G=(0,T.cG)(H==null?void 0:H.value)?[D.parseVariable(H==null?void 0:H.value,c),w]:[H==null?void 0:H.value,w],me.prev=11,ne=R(),me.next=15,Promise.all(G);case 15:return X=me.sent,ae=x()(X,2),oe=ae[0],ee=ae[1],me.next=21,D.getCollectionField(V,c);case 21:return W=me.sent,me.abrupt("return",ne.apply(p()({},$,[(0,t.J)(ee,{targetCollectionField:W}),(0,t.J)(oe,{targetCollectionField:W})])));case 25:throw me.prev=25,me.t0=me.catch(11),me.t0;case 28:case"end":return me.stop()}},U,null,[[11,25]])}));return function(U){return n.apply(this,arguments)}}()),O.next=6,Promise.all(m);case 6:if(m=O.sent,v!=="$and"){O.next=11;break}return O.abrupt("return",(0,I.every)(m,function(n){return n}));case 11:return O.abrupt("return",(0,I.some)(m,function(n){return n}));case 12:case"end":return O.stop()}},E)}));return function(C){return y.apply(this,arguments)}}();function z(y){return"{{ $nForm.".concat(y.join(".")," }}")}},61736:function(ze,re,e){"use strict";e.d(re,{D:function(){return l}});var L=e(67294),l=(0,L.createContext)({});l.displayName="SchemaComponentContext.Provider"},44245:function(ze,re,e){"use strict";e.d(re,{R:function(){return t}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(86201),x=e(94350),N=e(67294),r=e(47844),B=e(85893),h=["children","form"],I=["children"],b=function(d){var R=d.children,P=d.form,g=p()(d,h),u=(0,N.useContext)(x.SchemaOptionsContext),j=(0,N.useContext)(x.SchemaExpressionScopeContext),F=l()(l()({},u==null?void 0:u.scope),j),z=l()({},u==null?void 0:u.components);return(0,B.jsx)(x.FormProvider,l()(l()({},g),{},{form:P,children:(0,B.jsx)(r.G,{components:z,scope:F,children:R})}))},T=function(d){var R=d.children,P=p()(d,I),g=(0,N.useContext)(x.SchemaOptionsContext),u=(0,N.useContext)(x.SchemaExpressionScopeContext),j=l()(l()({},g==null?void 0:g.scope),u),F=l()({},g==null?void 0:g.components),z=(0,N.useMemo)(function(){return(0,A.createForm)()},[]);return(0,B.jsx)(x.FormProvider,l()(l()({},P),{},{form:z,children:(0,B.jsx)(r.G,{components:F,scope:j,children:R})}))},t=function(d){return d.form?(0,B.jsx)(b,l()({},d)):(0,B.jsx)(T,l()({},d))}},59480:function(ze,re,e){"use strict";e.d(re,{m:function(){return T}});var L=e(97857),l=e.n(L),K=e(86201),p=e(57953),A=e(67294),x=e(12174),N=e(84577),r=e(44245),B=e(93323),h=e(85893),I=function(o){return o},b=function(o){var d=o.noForm,R=o.onlyRenderProperties,P=o.hidden,g=o.scope,u=o.uid,j=o.components,F=o.onSuccess,z=o.schemaTransform,y=z===void 0?I:z,E=(0,N.Dm)(),C=E.reset,a={url:"/uiSchemas:".concat(R?"getProperties":"getJsonSchema","/").concat(u)},D=(0,A.useMemo)(function(){return(0,K.createForm)()},[u]),c=(0,x.QT)(a,{refreshDeps:[u],onSuccess:function(f){F&&F(f),C&&C()}}),v=c.data,i=c.loading;return i?(0,h.jsx)(p.Z,{}):P?(0,h.jsx)(p.Z,{}):d?(0,h.jsx)(B.n,{components:j,scope:g,schema:y((v==null?void 0:v.data)||{})}):(0,h.jsx)(r.R,{form:D,children:(0,h.jsx)(B.n,{components:j,scope:g,schema:y((v==null?void 0:v.data)||{})})})},T=function(o){return o.uid?(0,h.jsx)(b,l()({},o)):null}},93323:function(ze,re,e){"use strict";e.d(re,{n:function(){return u}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(9783),x=e.n(A),N=e(94350),r=e(90105),B=e(67294),h=e(61736),I=e(47844),b=e(85893),T=["components","scope","schema","distributed"],t=["schema"],o=["memoized"];function d(j){return N.Schema.isSchemaInstance(j)?j:j!=null&&j.name?new N.Schema({type:"object",properties:x()({},j.name,j)}):new N.Schema(j)}var R=function(F){return(0,B.useMemo)(function(){return d(F)},[])},P=function(F){var z=F.components,y=F.scope,E=F.schema,C=F.distributed,a=p()(F,T),D=(0,B.useContext)(h.D),c=(0,B.useMemo)(function(){return d(E)},[E]),v=(0,r.Z)();return(0,b.jsx)(h.D.Provider,{value:l()(l()({},D),{},{distributed:D.distributed==!1?!1:C,refresh:function(){var m;if(v(),D.distributed===!1||C===!1){var f;(f=D.refresh)===null||f===void 0||f.call(D)}(m=F.onChange)===null||m===void 0||m.call(F,c)}}),children:(0,b.jsx)(I.G,{inherit:!0,components:z,scope:y,children:(0,b.jsx)(N.RecursionField,l()(l()({},a),{},{schema:c}))})})},g=function(F){var z=F.schema,y=p()(F,t),E=R(z);return(0,b.jsx)(P,l()(l()({},y),{},{schema:E}))},u=function(F){var z=F.memoized,y=p()(F,o);return z?(0,b.jsx)(g,l()({},y)):(0,b.jsx)(P,l()({},y))}},47844:function(ze,re,e){"use strict";e.d(re,{B:function(){return x},G:function(){return N}});var L=e(97857),l=e.n(L),K=e(94350),p=e(67294),A=e(85893),x=function(){var B=(0,p.useContext)(K.SchemaOptionsContext);return B||{}},N=(0,p.memo)(function(r){var B=r.children,h=x(),I=(0,p.useMemo)(function(){return l()(l()({},h.components),r.components)},[h.components,r.components]),b=(0,p.useMemo)(function(){return l()(l()({},h.scope),r.scope)},[h.scope,r.scope]),T=(0,p.useMemo)(function(){return{scope:b,components:I}},[b,I]);return(0,A.jsx)(K.SchemaOptionsContext.Provider,{value:T,children:(0,A.jsx)(K.SchemaComponentsContext.Provider,{value:I,children:(0,A.jsx)(K.ExpressionScope,{value:b,children:B})})})});N.displayName="SchemaComponentOptions"},70993:function(ze,re,e){"use strict";e.d(re,{_b:function(){return F},RV:function(){return z.R},m1:function(){return y.m},n6:function(){return E.n},G0:function(){return C.G},a$:function(){return w},Tz:function(){return $},Bs:function(){return C.B}});var L=e(15009),l=e.n(L),K=e(99289),p=e.n(K),A=e(12444),x=e.n(A),N=e(72004),r=e.n(N),B=e(31996),h=e.n(B),I=e(26037),b=e.n(I),T=e(51947),t=e(83062),o=e(15867),d=e(67294),R=e(49218),P=e(26793),g=e(56709),u=e(68230),j=e(85893),F=function(){var X=(0,g.ngQ)(),ae=X.designable,oe=X.setDesignable,ee=(0,P.$)(),W=ee.t,de=(0,u.d)(),me=de.token,Q={};return ae&&(Q.backgroundColor="var(--colorSettings)"),(0,R.y1)("Ctrl+Shift+U",function(){return oe(!ae)},[ae]),(0,j.jsx)(t.Z,{title:W("UI Editor"),children:(0,j.jsx)(o.ZP,{"data-testid":"ui-editor-button",icon:(0,j.jsx)(T.Z,{style:{color:me.colorTextHeaderMenu}}),title:W("UI Editor"),style:Q,onClick:function(){oe(!ae)}})})},z=e(44245),y=e(59480),E=e(93323),C=e(47844),a=e(97857),D=e.n(a),c=e(5574),v=e.n(c),i=e(86201),m=e(94350),f=e(73773),O=e(90105),n=e(61736),U=function(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return"".concat(X).concat((0,f.uid)())};m.Schema.silent(!0);var k={},H={silent:!0,compile:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=function(){if(H.silent)try{return new Function("$root","with($root) { return (".concat(X,"); }"))(ae)}catch(W){return"{{".concat(X,"}}")}else return new Function("$root","with($root) { return (".concat(X,"); }"))(ae)};return k[X]?k[X]:X.trim().startsWith("t(")?(k[X]=oe(),k[X]):oe()}};m.Schema.registerCompiler(H.compile);var $=function(X){var ae=X.designable,oe=X.onDesignableChange,ee=X.components,W=X.children,de=(0,d.useContext)(n.D),me=(0,C.B)(),Q=(0,O.Z)(),_e=(0,d.useState)((0,f.uid)()),ye=v()(_e,2),Ae=ye[0],Se=ye[1],he=(0,d.useMemo)(function(){return X.form||(0,i.createForm)()},[Ae]),ve=(0,P.$)(),J=ve.t,Y=(0,d.useMemo)(function(){return D()(D()({},X.scope),{},{t:J,randomString:U})},[X.scope,J,me==null?void 0:me.scope]),ue=(0,d.useState)(ae),xe=v()(ue,2),fe=xe[0],Me=xe[1],Ie=(0,d.useMemo)(function(){return typeof ae=="boolean"?ae:fe},[ae,fe,de.designable]),Ue=(0,d.useMemo)(function(){return function(Oe){typeof Ie!="boolean"&&Me(Oe),oe==null||oe(Oe)}},[Ie,oe]),Ne=(0,d.useCallback)(function(){Se((0,f.uid)())},[]);return(0,j.jsx)(n.D.Provider,{value:{scope:Y,components:ee,reset:Ne,refresh:Q,designable:Ie,setDesignable:Ue},children:(0,j.jsx)(m.FormProvider,{form:he,children:(0,j.jsx)(C.G,{inherit:!0,scope:Y,components:ee,children:W})})})};$.displayName="SchemaComponentProvider";var V=e(31601),w=function(ne){h()(ae,ne);var X=b()(ae);function ae(){return x()(this,ae),X.apply(this,arguments)}return r()(ae,[{key:"load",value:function(){var oe=p()(l()().mark(function W(){return l()().wrap(function(me){for(;;)switch(me.prev=me.next){case 0:this.addComponents();case 1:case"end":return me.stop()}},W,this)}));function ee(){return oe.apply(this,arguments)}return ee}()},{key:"addComponents",value:function(){this.app.addComponents({DesignableSwitch:F})}}]),ae}(V.S),G=null},84577:function(ze,re,e){"use strict";e.d(re,{zz:function(){return N.zz},Pl:function(){return N.Pl},oB:function(){return N.oB},lI:function(){return l},hi:function(){return g.hi},eJ:function(){return K.e},Co:function(){return x},aZ:function(){return g.aZ},ng:function(){return N.ng},et:function(){return r.e},cL:function(){return d},fd:function(){return u},Cl:function(){return I},vH:function(){return R},sR:function(){return N.sR},wN:function(){return P.w},Dm:function(){return T},fM:function(){return g.fM}});var L=e(67294),l=function(F){var z=(0,L.useRef)(null);return(0,L.useEffect)(function(){return z.current&&F!==z.current&&z.current.onUnmount(),z.current=F,F.onMount(),function(){F.onUnmount()}},[F]),F},K=e(96365),p=e(94350),A=e(96486),x=function(F,z){var y=(0,L.useContext)(p.SchemaOptionsContext),E=y.components;return F?typeof F!="string"?F:(0,A.get)(E,F)||z:z},N=e(94516),r=e(98146),B=e(97857),h=e.n(B),I=function(F){var z=(0,L.useContext)(p.SchemaOptionsContext),y=(0,L.useContext)(p.SchemaExpressionScopeContext),E=(0,L.useRef)();return E.current=y,F.toFieldProps(h()(h()({},z),{},{get scope(){return h()(h()({},z.scope),E.current)}}))},b=e(61736);function T(){return(0,L.useContext)(b.D)}var t=e(26793),o=e(6145),d=function(){var F,z=(0,o.useCollectionManager_deprecated)(),y=z.getCollectionJoinField,E=z.getCollection,C=(0,p.useFieldSchema)(),a=(0,o.useCollection_deprecated)(),D=a.getField,c=D(C.name)||y(C["x-collection-field"]),v=(0,t.$)(),i=v.t,m=((F=C["x-component-props"])===null||F===void 0?void 0:F.fieldNames)||{},f=m.label,O=(0,L.useMemo)(function(){if(!(!c||!(c!=null&&c.interface))&&["o2o","oho","obo","o2m","linkTo","m2o","m2m"].includes(c.interface)){var n=E(c.target);if((n==null?void 0:n.template)==="file")return[{label:i("Record picker"),value:"CollectionField"},{label:i("Select"),value:"AssociationSelect"}];switch(c.interface){case"o2m":return[{label:i("Record picker"),value:"CollectionField"},{label:i("Subtable"),value:"TableField"},{label:i("Select"),value:"AssociationSelect"}];case"m2o":case"m2m":case"linkTo":return[{label:i("Record picker"),value:"CollectionField"},{label:i("Select"),value:"AssociationSelect"}];default:return[{label:i("Record picker"),value:"CollectionField"},{label:i("Subform"),value:"FormField"},{label:i("Select"),value:"AssociationSelect"}]}}},[i,c==null?void 0:c.interface,f]);return O},R=function(){var F,z=(0,p.useField)(),y=(0,p.useFieldSchema)(),E=(0,o.useCollection_deprecated)(),C=E.getField,a=(0,o.useCollectionManager_deprecated)(),D=a.getCollectionJoinField,c=C(y.name)||D(y["x-collection-field"]),v=(0,K.e)();(0,L.useEffect)(function(){if(!(z!=null&&z.title)){var i;z.title=v(c==null||(i=c.uiSchema)===null||i===void 0?void 0:i.title)}},[c==null||(F=c.uiSchema)===null||F===void 0?void 0:F.title])},P=e(9780),g=e(18686),u=function(F){var z,y=(0,t.$)(),E=y.t,C=(0,o.useCollectionManager_deprecated)(),a=C.getCollectionJoinField,D=C.getCollection,c=(0,p.useFieldSchema)(),v=(F==null?void 0:F.fieldSchema)||c,i=(0,p.useField)(),m=(0,p.useForm)(),f=(v==null?void 0:v["x-read-pretty"])||i.readPretty||m.readPretty,O=F==null?void 0:F.fieldSchema,n=(0,o.useCollection_deprecated)(),U=n.getField,k=(F==null?void 0:F.collectionField)||U(v.name)||a(v["x-collection-field"]),H=((z=v["x-component-props"])===null||z===void 0?void 0:z.fieldNames)||{},$=H.label,V=(0,L.useMemo)(function(){if(!(!k||!(k!=null&&k.interface))&&["o2o","oho","obo","o2m","linkTo","m2o","m2m","updatedBy","createdBy"].includes(k.interface)){var w=D(k.target);if((w==null?void 0:w.template)==="file")return f?[{label:E("Title"),value:"Select"},{label:E("File manager"),value:"FileManager"},{label:E("Tag"),value:"Tag"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},{label:E("File manager"),value:"FileManager"}];if((w==null?void 0:w.template)==="tree"&&["m2m","o2m","m2o"].includes(k.interface))return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"},!O&&{label:E("Sub-table"),value:"SubTable"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&["m2m","o2m"].includes(k.interface)&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Cascade Select"),value:"CascadeSelect"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];switch(k.interface){case"o2m":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"},!O&&{label:E("Sub-table"),value:"SubTable"}];case"m2m":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"},!O&&{label:E("Sub-table"),value:"SubTable"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];case"m2o":case"linkTo":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];default:return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}]}}},[E,k==null?void 0:k.interface,$]);return(V||[]).filter(Boolean)}},18686:function(ze,re,e){"use strict";e.d(re,{aZ:function(){return j},fM:function(){return z},hi:function(){return F}});var L=e(5574),l=e.n(L),K=e(97857),p=e.n(K),A=e(94350),x=e(83204),N=e(9361),r=e(96486),B=e.n(r),h=e(67294),I=e(56709),b=e(21143),T=e(28561),t=e(10097),o=function(C,a,D,c){return C?c.paddingContentHorizontalLG:D?a?c.controlPaddingHorizontal+3*c.controlPaddingHorizontalSM+22+c.paddingContentHorizontalLG:c.paddingContentHorizontalLG+12:a?c.paddingSM+c.controlHeight+c.marginXS+2*c.controlPaddingHorizontalSM+22+c.paddingContentHorizontalLG:c.controlHeight+c.marginXS+(c.paddingXXS+2)*2+c.paddingContentHorizontalLG},d=function(C){var a=N.Z.useToken(),D=a.token,c=(0,I.ngQ)(),v=c.designable,i=(0,t.useBlockHeightProps)(),m=i.heightProps,f=C||m||{},O=f.disablePageHeader,n=f.enablePageTabs,U=f.hidePageTitle,k=D.sizeXXL-2,H=v?D.controlHeight+2*D.paddingContentHorizontalLG:1*D.paddingContentHorizontalLG,$=o(O,n,U,D);return k+$+H},R=function(){var C=N.Z.useToken(),a=C.token,D=(0,I.ngQ)(),c=D.designable,v=a.paddingContentVerticalLG+a.margin+2*a.paddingContentVertical+24,i=c?a.controlHeight+2*a.paddingContentHorizontalLG:1*a.paddingContentHorizontalLG;return v+i},P=function(C){var a=(0,A.useFieldSchema)(),D=y(a),c=d(C),v=R();return D?v:c},g=["users_jobs","approvals","approvalRecords"],u=function(){var C,a,D=N.Z.useToken(),c=D.token,v=(0,t.useBlockHeightProps)(),i=v.heightProps,m=(0,b.useTableBlockContext)(),f=m.heightProps,O=(0,I.ngQ)(),n=O.designable,U=(0,A.useFieldSchema)(),k=f||i,H=P(k),$=(C=(0,b.useDataBlockRequest)())!==null&&C!==void 0?C:{},V=$.data,w=(0,b.useCollection)(),G=w.name,ne=(V==null?void 0:V.meta)||{},X=ne.count,ae=ne.pageSize,oe=X>ae,ee=k.heightMode,W=k.height,de=k.title;if(!(!(k!=null&&k.heightMode)||ee===T.j.DEFAULT)){var me=Object.keys(((a=U.parent.properties.actions)===null||a===void 0?void 0:a.properties)||{}).length>0,Q=oe?c.controlHeight+c.padding+c.marginLG:c.marginLG,_e=me||n?c.controlHeight+2*c.marginLG:c.marginLG,ye=(n&&!g.includes(G)?c.controlHeight:22)+2*c.padding+1,Ae=de?c.fontSizeLG*c.lineHeightLG+c.padding*2-1:0;return ee===T.j.FULL_HEIGHT?window.innerHeight-H-Ae-ye-_e-Q:W-Ae-_e-ye-Q}},j=function(C){var a=(0,t.useBlockHeightProps)(),D=a.heightProps,c=P(),v=N.Z.useToken(),i=v.token,m=D||{},f=m.heightMode,O=m.height,n=m.title,U=n?i.fontSizeLG*i.lineHeightLG+i.padding*2-1:0;if(!(!(D!=null&&D.heightMode)||f===T.j.DEFAULT)){if(f===T.j.FULL_HEIGHT){var k=window.innerHeight-c;return C!=null&&C.removeBlockHeaderHeight&&(k=k-U),C!=null&&C.innerExtraHeight&&(k=k-C.innerExtraHeight),k}return O}},F=function(){var C=(0,A.useFieldSchema)(),a=(0,h.useMemo)(function(){return(0,t.getPageSchema)(C)},[]),D=(a==null?void 0:a["x-component-props"])||{},c=D.disablePageHeader,v=D.enablePageTabs,i=D.hidePageTitle,m=p()(p()({},C==null?void 0:C["x-component-props"]),{},{disablePageHeader:c,enablePageTabs:v,hidePageTitle:i}),f=P(m),O=m||{},n=O.heightMode,U=O.height;if(!(!(m!=null&&m.heightMode)||n===T.j.DEFAULT))return n===T.j.FULL_HEIGHT?window.innerHeight-f:U},z=function(){var C=(0,h.useState)(),a=l()(C,2),D=a[0],c=a[1],v=(0,h.useRef)(null),i=u(),m=(0,h.useCallback)((0,r.debounce)(function(){var O;if(v.current){var n=v.current.getBoundingClientRect(),U=(O=v.current.querySelector(".ant-table"))===null||O===void 0?void 0:O.getBoundingClientRect();U&&c(n.width)}},100),[i]),f=(0,h.useCallback)(function(O){v.current=O&&O.children?O.children[0]:null,m()},[m]);return(0,x.Z)("resize",m),{height:i,width:D,tableSizeRefCallback:f}},y=function E(C){return C?C["x-component"]==="Action.Container"?!0:E(C.parent):null}},96365:function(ze,re,e){"use strict";e.d(re,{e:function(){return r}});var L=e(97857),l=e.n(L),K=e(52677),p=e.n(K),A=e(94350),x=e(67294),N={},r=function(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{noCache:!1},I=h.noCache,b=(0,x.useContext)(A.SchemaOptionsContext),T=(0,x.useContext)(A.SchemaExpressionScopeContext);return function(t,o){var d=!1,R;if(typeof t=="string"&&t.startsWith("{{")&&(d=!0,R=t),t&&p()(t)==="object"&&!(0,x.isValidElement)(t)&&(d=!0,R=JSON.stringify(t)),Array.isArray(t)&&(d=!0),d){var P=l()(l()(l()({},b.scope),T),o);if(!R)return A.Schema.compile(t,P);try{return I?A.Schema.compile(t,P):(N[R]=N[R]||A.Schema.compile(t,P),N[R])}catch(g){return console.log("useCompile error",t,g),A.Schema.compile(t,P)}}return t}}},94516:function(ze,re,e){"use strict";e.d(re,{zz:function(){return $},Pl:function(){return f},oB:function(){return k},ng:function(){return w},sR:function(){return V}});var L=e(5574),l=e.n(L),K=e(19632),p=e.n(K),A=e(15009),x=e.n(A),N=e(99289),r=e.n(N),B=e(12444),h=e.n(B),I=e(72004),b=e.n(I),T=e(9783),t=e.n(T),o=e(97857),d=e.n(o),R=e(94350),P=e(73773),g=e(45360),u=e(50361),j=e.n(u),F=e(27361),z=e.n(F),y=e(36968),E=e.n(y),C=e(67294),a=e(26793),D=e(12174),c=e(61736);function v(G,ne){if(G)return G["x-app-version"]||(G["x-app-version"]=ne),Object.keys(G.properties||{}).forEach(function(X){var ae;v((ae=G.properties)===null||ae===void 0?void 0:ae[X],ne)}),G}var i=JSON.parse('{"i8":"1.2.29-alpha"}'),m=e(85893);function f(G){return new $(G)}var O=function G(ne){ne&&(ne["x-uid"]||(ne["x-uid"]=(0,P.uid)()),Object.keys(ne.properties||{}).forEach(function(X){G(ne.properties[X])}))},n=function(ne){return ne},U=function(ne,X){if(!(!ne||!X)){for(var ae in X)if(Object.prototype.hasOwnProperty.call(X,ae)){var oe=X[ae];if(oe!==(ne==null?void 0:ne[ae]))return!1}return!0}},k=function(ne,X){if(ne["x-uid"]&&ne["x-uid"]===X["x-uid"])return[null,ne.toJSON()];var ae=ne.toJSON(),oe=d()(d()({},ae),{},{properties:{}}),ee=null,W=function de(me,Q){Object.keys(me||{}).forEach(function(_e){var ye=me[_e];if(ye["x-uid"]===X["x-uid"]){ee=me[_e];return}else Q.properties[_e]=d()(d()({},ye),{},{properties:{}}),de(ye==null?void 0:ye.properties,Q.properties[_e])})};return W(ae.properties,oe),[oe,ee]},H=function(ne){return ne},$=function(){function G(ne){h()(this,G),t()(this,"current",void 0),t()(this,"options",void 0),t()(this,"appVersion",void 0),t()(this,"events",{}),this.options=ne,this.current=ne.current,this.appVersion=ne.appVersion}return b()(G,[{key:"model",get:function(){return this.options.model}},{key:"query",get:function(){return this.options.query}},{key:"loadAPIClientEvents",value:function(){var X=this,ae=this.options,oe=ae.api,ee=ae.t,W=ee===void 0?H:ee;if(oe){var de=function(Q){if(!Q)return[];var _e=Object.values(Q.properties).length,ye=[];return Q.mapProperties(function(Ae){Ae["x-component-props"]=Ae["x-component-props"]||{},Ae["x-component-props"].width=100/_e,Ae["x-uid"]&&ye.push({"x-uid":Ae["x-uid"],"x-component-props":Ae["x-component-props"]})}),Q["x-uid"]&&ye.length?ye:[]};this.on("insertAdjacent",function(){var me=r()(x()().mark(function Q(_e){var ye,Ae,Se,he,ve,J,Y,ue,xe,fe;return x()().wrap(function(Ie){for(;;)switch(Ie.prev=Ie.next){case 0:if(Ae=_e.onSuccess,Se=_e.current,he=_e.position,ve=_e.schema,J=_e.wrap,Y=_e.wrapped,ue=_e.removed,xe=[],(Y==null?void 0:Y["x-component"])==="Grid.Col"&&(xe=xe.concat(de(Y.parent))),(ue==null?void 0:ue["x-component"])==="Grid.Col"&&(xe=xe.concat(de(ue.parent))),X.refresh(),Se["x-uid"]){Ie.next=7;break}return Ie.abrupt("return");case 7:return Ie.next=9,oe.request({url:"/uiSchemas:insertAdjacent/".concat(Se["x-uid"],"?position=").concat(he),method:"post",data:{schema:v(ve,X.appVersion),wrap:J}});case 9:if(fe=Ie.sent,!xe.length){Ie.next=13;break}return Ie.next=13,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:xe});case 13:if(!(ue!=null&&ue["x-uid"])){Ie.next=16;break}return Ie.next=16,oe.request({url:"/uiSchemas:remove/".concat(ue["x-uid"]),method:"post"});case 16:Ae==null||Ae(fe==null||(ye=fe.data)===null||ye===void 0?void 0:ye.data),g.ZP.success(W("Saved successfully"),.2);case 18:case"end":return Ie.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("patch",function(){var me=r()(x()().mark(function Q(_e){var ye;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:if(ye=_e.schema,X.refresh(),ye!=null&&ye["x-uid"]){Se.next=4;break}return Se.abrupt("return");case 4:return Se.next=6,oe.request({url:"/uiSchemas:patch",method:"post",data:d()({},ye)});case 6:g.ZP.success(W("Saved successfully"),.2);case 7:case"end":return Se.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("batchPatch",function(){var me=r()(x()().mark(function Q(_e){var ye;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:return ye=_e.schemas,X.refresh(),Se.next=4,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:ye});case 4:g.ZP.success(W("Saved successfully"),.2);case 5:case"end":return Se.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("remove",function(){var me=r()(x()().mark(function Q(_e){var ye,Ae;return x()().wrap(function(he){for(;;)switch(he.prev=he.next){case 0:if(ye=_e.removed,Ae=[],(ye==null?void 0:ye["x-component"])==="Grid.Col"&&(Ae=de(ye.parent)),X.refresh(),ye!=null&&ye["x-uid"]){he.next=6;break}return he.abrupt("return");case 6:return he.next=8,oe.request({url:"/uiSchemas:remove/".concat(ye["x-uid"]),method:"post"});case 8:if(!Ae.length){he.next=11;break}return he.next=11,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:Ae});case 11:g.ZP.success(W("Saved successfully"),.2);case 12:case"end":return he.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}())}}},{key:"prepareProperty",value:function(X){X.type||(X.type="void"),X.name||(X.name=(0,P.uid)()),this.current["x-uid"]&&O(X)}},{key:"on",value:function(X,ae){this.events[X]||(this.events[X]=[]),this.events[X].push(ae)}},{key:"emit",value:function(){var ne=r()(x()().mark(function ae(oe){var ee=this,W,de,me,Q,_e,ye=arguments;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:if(this.events[oe]){Se.next=2;break}return Se.abrupt("return");case 2:for(W=ye.length,de=new Array(W>1?W-1:0),me=1;me<W;me++)de[me-1]=ye[me];return Q=de[0],_e=de.slice(1),Se.abrupt("return",Promise.all(this.events[oe].map(function(he){return he.bind(ee).apply(void 0,[d()({current:ee.current},Q)].concat(p()(_e)))})));case 5:case"end":return Se.stop()}},ae,this)}));function X(ae){return ne.apply(this,arguments)}return X}()},{key:"parentsIn",value:function(X){if(!X||!R.Schema.isSchemaInstance(X))return!1;for(var ae=this.current;(oe=ae)!==null&&oe!==void 0&&oe.parent;){var oe;if(ae.parent===X)return!0;ae=ae.parent}return!1}},{key:"refresh",value:function(){var X=this.options.refresh;return X==null?void 0:X()}},{key:"deepMerge",value:function(X){var ae=this,oe={title:"title",description:"description",default:"initialValue",readOnly:"readOnly",writeOnly:"editable",enum:"dataSource","x-pattern":"pattern","x-display":"display","x-validator":"validator","x-decorator":"decorator","x-component":"component","x-reactions":"reactions","x-content":"content","x-visible":"visible","x-hidden":"hidden","x-disabled":"disabled","x-editable":"editable","x-read-only":"readOnly"},ee={"x-decorator-props":"decoratorProps","x-component-props":"componentProps","x-data":"data"};Object.keys(X).forEach(function(W){oe[W]?(ae.current[W]=X[W],ae.updateModel(oe[W],X[W])):ee[W]?Object.keys(X[W]).forEach(function(de){E()(ae.current,[W,de],X[W][de]),ae.updateModel([ee[W],de],X[W][de])}):ae.current[W]=X[W]}),this.emit("patch",{schema:X})}},{key:"getSchemaAttribute",value:function(X,ae){return z()(this.current,X,ae)}},{key:"shallowMerge",value:function(X){var ae=this,oe={title:"title",description:"description",default:"initialValue",readOnly:"readOnly",writeOnly:"editable",enum:"dataSource","x-pattern":"pattern","x-display":"display","x-validator":"validator","x-decorator":"decorator","x-component":"component","x-reactions":"reactions","x-content":"content","x-visible":"visible","x-hidden":"hidden","x-disabled":"disabled","x-editable":"editable","x-read-only":"readOnly","x-decorator-props":"decoratorProps","x-component-props":"componentProps","x-data":"data"};Object.keys(X).forEach(function(ee){ae.current[ee]=X[ee],oe[ee]&&ae.updateModel(oe[ee],X[ee])}),this.emit("patch",{schema:X})}},{key:"updateModel",value:function(X,ae){var oe=function(W){E()(W,X,ae)};this.model&&oe(this.model),this.query&&this.query.take(oe)}},{key:"insertAdjacent",value:function(X,ae){var oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};switch(X){case"beforeBegin":return this.insertBeforeBegin(ae,oe);case"afterBegin":return this.insertAfterBegin(ae,oe);case"beforeEnd":return this.insertBeforeEnd(ae,oe);case"afterEnd":return this.insertAfterEnd(ae,oe)}}},{key:"recursiveRemoveIfNoChildren",value:function(X,ae){if(X){for(var oe=X,ee,W=ae==null?void 0:ae.breakRemoveOn;oe;){if(typeof W=="function"){if(W(oe))break}else if(U(oe,W))break;var de=Object.keys(oe.properties||{}).length;if(de>0)break;oe.parent&&(ee=oe.parent.removeProperty(oe.name)),oe=oe.parent}return ee}}},{key:"remove",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=ae.breakRemoveOn,ee=ae.removeParentsIfNoChildren,W=X||this.current,de=W.parent.removeProperty(W.name);if(ee){var me=this.recursiveRemoveIfNoChildren(W.parent,{breakRemoveOn:oe});me&&(de=me)}return this.emit("remove",{removed:de})}},{key:"removeWithoutEmit",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=ae.breakRemoveOn,ee=ae.removeParentsIfNoChildren,W=X||this.current,de=W.parent.removeProperty(W.name);if(ee){var me=this.recursiveRemoveIfNoChildren(W.parent,{breakRemoveOn:oe});me&&(de=me)}return de}},{key:"insertBeforeBeginOrAfterEnd",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)&&R.Schema.isSchemaInstance(X)&&this.current.parent===X.parent){var ee=0,W=0;return this.current.parent.mapProperties(function(de,me,Q){ae.current.name===me&&(W=Q),X.name===me&&(ee=Q)}),ee>W?this.insertBeforeBegin(X,oe):this.insertAfterEnd(X,oe)}}},{key:"insertBeforeBegin",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var ee={onSuccess:oe.onSuccess},W=oe.wrap,de=W===void 0?n:W,me=oe.breakRemoveOn,Q=oe.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),Q&&(ee.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:me}))}else X&&(X=j()(X));var _e={},ye=!1,Ae=0,Se=0;this.current.parent.mapProperties(function(fe,Me){Me===ae.current.name&&(Se=Ae,ye=!0,++Ae),fe["x-index"]=Ae,++Ae,ye&&(_e[Me]=fe,ae.current.parent.removeProperty(Me))}),this.prepareProperty(X);var he=de(X),ve=this.current.parent.addProperty(he.name||(0,P.uid)(),he);ve["x-index"]=Se,ve.parent=this.current.parent,this.current.parent.setProperties(_e);var J=k(ve,X),Y=l()(J,2),ue=Y[0],xe=Y[1];this.emit("insertAdjacent",d()({position:"beforeBegin",schema:xe,wrapped:he,wrap:ue},ee))}}},{key:"insertAfterBegin",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var oe={onSuccess:ae.onSuccess},ee=ae.wrap,W=ee===void 0?n:ee,de=ae.breakRemoveOn,me=ae.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),me&&(oe.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:de}))}else X&&(X=j()(X));var Q={},_e=1;this.current.mapProperties(function(Y,ue){Y["x-index"]=_e,++_e,Q[ue]=Y}),this.current.properties={},this.prepareProperty(X);var ye=W(X),Ae=this.current.addProperty(ye.name||(0,P.uid)(),ye);Ae["x-index"]=0,Ae.parent=this.current,this.current.setProperties(Q);var Se=k(Ae,X),he=l()(Se,2),ve=he[0],J=he[1];this.emit("insertAdjacent",d()({position:"afterBegin",schema:J,wrap:ve,wrapped:ye},oe))}}},{key:"insertBeforeEnd",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){delete X["x-index"];var oe={onSuccess:ae.onSuccess},ee=ae.wrap,W=ee===void 0?n:ee,de=ae.breakRemoveOn,me=ae.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),me&&(oe.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:de}))}else X&&(X=j()(X));this.prepareProperty(X);var Q=W(X),_e=this.current.addProperty(Q.name||(0,P.uid)(),Q);_e.parent=this.current;var ye=k(_e,X),Ae=l()(ye,2),Se=Ae[0],he=Ae[1];return this.emit("insertAdjacent",d()({position:"beforeEnd",schema:he,wrap:Se,wrapped:Q},oe))}}},{key:"insertAfterEnd",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var ee={onSuccess:oe==null?void 0:oe.onSuccess},W=oe.wrap,de=W===void 0?n:W,me=oe.breakRemoveOn,Q=oe.removeParentsIfNoChildren,_e=0,ye=0,Ae=!1,Se={};if(this.current.parent.mapProperties(function(fe,Me){fe["x-index"]=_e,Me===ae.current.name&&(++_e,ye=_e,Ae=!0),++_e,Ae&&Me!==ae.current.name&&(Se[Me]=fe,ae.current.parent.removeProperty(Me))}),R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),Q&&(ee.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:me})),X.parent=null}else X&&(X=j()(X));this.prepareProperty(X);var he=de(X),ve=this.current.parent.addProperty(he.name||(0,P.uid)(),he);ve.parent=this.current.parent,ve["x-index"]=ye,this.current.parent.setProperties(Se);var J=k(ve,X),Y=l()(J,2),ue=Y[0],xe=Y[1];this.emit("insertAdjacent",d()({position:"afterEnd",schema:xe,wrap:ue,wrapped:he},ee))}}}]),G}();function V(){var G=(0,C.useContext)(R.SchemaOptionsContext),ne=(0,C.useMemo)(function(){return(G==null?void 0:G.components)||{}},[G]),X=function(oe){if(!oe)return null;if(typeof oe!="string")return oe;var ee=z()(ne,oe);return ee||console.error('[nocobase]: Component "'.concat(oe,'" not found')),ee};return X}function w(){var G=(0,C.useContext)(c.D),ne=G.designable,X=G.setDesignable,ae=G.refresh,oe=G.reset,ee=(0,C.useContext)(R.SchemaOptionsContext),W=(0,C.useMemo)(function(){return(ee==null?void 0:ee.components)||{}},[ee]),de=(0,C.useMemo)(function(){return function(){return(0,m.jsx)(m.Fragment,{})}},[]),me=(0,R.useField)(),Q=(0,R.useFieldSchema)(),_e=(0,D.LY)(),ye=(0,a.$)(),Ae=ye.t,Se=(0,C.useMemo)(function(){return f({t:Ae,api:_e,refresh:ae,current:Q,model:me,appVersion:i.i8})},[Ae,_e,ae,Q,me]);return(0,C.useEffect)(function(){Se.loadAPIClientEvents()},[Se]),{dn:Se,designable:ne,reset:oe,refresh:ae,setDesignable:X,DesignableBar:de,findComponent:(0,C.useCallback)(function(he){return he?typeof he!="string"?he:z()(W,he):null},[z()]),on:Se.on.bind(Se),patch:(0,C.useCallback)(function(he,ve){var J=function(xe){Object.keys(xe).forEach(function(fe){var Me=xe[fe];fe==="title"&&(me.title=Me,Q.title=Me),fe==="x-decorator-props"&&(me.decoratorProps||(me.decoratorProps={}),Q["x-decorator-props"]||(Q["x-decorator-props"]={}),Object.keys(Me).forEach(function(Ie){me.decoratorProps[Ie]=Me[Ie],Q["x-decorator-props"][Ie]=Me[Ie]})),fe==="x-component-props"&&(me.componentProps||(me.componentProps={}),Q["x-component-props"]||(Q["x-component-props"]={}),Object.keys(Me).forEach(function(Ie){me.componentProps[Ie]=Me[Ie],Q["x-component-props"][Ie]=Me[Ie]}))})};if(typeof he=="string"){var Y={};return E()(Y,he,ve),J(Y)}J(he),ae()},[Se]),shallowMerge:(0,C.useCallback)(function(he){Se.shallowMerge(he)},[Se]),deepMerge:(0,C.useCallback)(function(he){Se.deepMerge(he)},[Se]),remove:(0,C.useCallback)(function(he,ve){Se.remove(he,ve)},[Se]),insertAdjacent:(0,C.useCallback)(function(he,ve,J){Se.insertAdjacent(he,ve,J)},[Se]),insertBeforeBegin:(0,C.useCallback)(function(he){Se.insertBeforeBegin(he)},[Se]),insertAfterBegin:(0,C.useCallback)(function(he){Se.insertAfterBegin(he)},[Se]),insertBeforeEnd:(0,C.useCallback)(function(he){Se.insertBeforeEnd(he)},[Se]),insertAfterEnd:(0,C.useCallback)(function(he){Se.insertAfterEnd(he)},[Se])}}},98146:function(ze,re,e){"use strict";e.d(re,{e:function(){return x}});var L=e(94350),l=e(84577),K=e(67294),p=e(74538),A=function(){return null},x=function(){var r=(0,l.ng)(),B=r.designable,h=(0,L.useFieldSchema)(),I=(0,K.useMemo)(function(){return h["x-designer"]||h["x-toolbar"]?h["x-designer"]||h["x-toolbar"]:h["x-settings"]?p.Mf:A},[h]),b=(0,l.Co)(I);return B&&b||A}},9780:function(ze,re,e){"use strict";e.d(re,{w:function(){return N}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=["useProps"],x=function(){return{}},N=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},h=B.useProps,I=h===void 0?x:h,b=p()(B,A),T=I;typeof I!="function"&&(T=x);var t=T();return l()(l()({},b),t)}},56709:function(ze,re,e){"use strict";e.d(re,{aUM:function(){return F.aU},olz:function(){return F.ol},N0i:function(){return F.N0},fWn:function(){return F.fW},EIK:function(){return F.EI},$Lt:function(){return F.$L},$b8:function(){return F.$b},HTy:function(){return Ro},lkv:function(){return Fo},rDu:function(){return la},eYL:function(){return F.eY},Rat:function(){return oa},$SD:function(){return pi},fUi:function(){return Yo.fU},QcG:function(){return Tl},gOu:function(){return os},jYG:function(){return $a.j},C1I:function(){return F.C1},Ssf:function(){return Rl},vTp:function(){return Ul},XZJ:function(){return da},Tt2:function(){return Vl},zH8:function(){return Hl},Q5L:function(){return Jl},Pok:function(){return fi},Vm0:function(){return ql},xI_:function(){return kl},Lip:function(){return zl},Mtg:function(){return ma.Mt},iNu:function(){return ma.iN},zzt:function(){return Ct.zz},_bl:function(){return g._b},POi:function(){return es},AOY:function(){return Q},LBT:function(){return P.DndContext},IWB:function(){return P.DragHandler},LCt:function(){return P.DraggableContext},FyH:function(){return W.Fy},Nir:function(){return W.Ni},q8U:function(){return W.q8},HGA:function(){return W.HG},QTe:function(){return W.QT},JEX:function(){return W.JE},fAH:function(){return ol},$w$:function(){return W.$w},nBj:function(){return W.nB},Oct:function(){return W.Oc},zdw:function(){return W.zd},CXR:function(){return nl},BQs:function(){return Ao.BQ},Hj5:function(){return ct.H},M0b:function(){return hi},wn$:function(){return Or.wn},GzZ:function(){return Or.Gz},tJZ:function(){return Or.tJ},fox:function(){return Or.fo},VTd:function(){return Or.VT},XsZ:function(){return Or.Xs},AsW:function(){return tr},cLM:function(){return Lo},m__:function(){return Qn},l09:function(){return ae},D_t:function(){return zi.D},WiK:function(){return Ut},xJW:function(){return W.xJ},RVL:function(){return g.RV},Bc8:function(){return hr},hG9:function(){return _i},DCh:function(){return gi},rjZ:function(){return va.rj},Cqo:function(){return Va},jg7:function(){return va.jg},gsn:function(){return Ao.gs},$18:function(){return vs},IIB:function(){return Ao.II},RnZ:function(){return Gi},mX2:function(){return Ao.mX},zDC:function(){return bo.zD},Phs:function(){return Ao.Ph},aVo:function(){return za},UGj:function(){return Ji},yq5:function(){return Yi},v2r:function(){return Ca},HIW:function(){return cu},T3C:function(){return Hr},tlE:function(){return Ts},rop:function(){return Rs},gGi:function(){return Bs},MBS:function(){return Ls.M},pGO:function(){return Ks},Y8K:function(){return yi},iVT:function(){return Ao.iV},ODP:function(){return bo.OD},lbb:function(){return bo.lb},b7w:function(){return bo.b7},sUk:function(){return bo.sU},x1j:function(){return F.x1},m1v:function(){return g.m1},glM:function(){return Ye},xZD:function(){return F.xZ},IuH:function(){return Or.Iu},MkN:function(){return F.Mk},Hof:function(){return Ns},n6:function(){return g.n6},DDd:function(){return Vm.D},G0E:function(){return g.G0},a$w:function(){return g.a$},TzZ:function(){return g.Tz},y00:function(){return F.y0},PhF:function(){return It},Cqv:function(){return P.ShowFormData},cof:function(){return F.co},bts:function(){return P.Sortable},Fop:function(){return P.SortableContext},TRI:function(){return P.SortableItem},ORg:function(){return P.SortableProvider},TaI:function(){return $s},qHe:function(){return mr.q},iA_:function(){return Jo},gvM:function(){return Xs},SnY:function(){return al},ASv:function(){return qs},bwk:function(){return aa},mQc:function(){return Ei},c__:function(){return tu},QZ3:function(){return Pe},L39:function(){return $a.L},jII:function(){return ll},mPs:function(){return lu},tgM:function(){return uu},gqx:function(){return Yo.gq},Qm7:function(){return Yo.Qm},_wD:function(){return Ia._w},rjl:function(){return Ia.rj},Fjw:function(){return F.Fj},SLL:function(){return F.SL},sBv:function(){return F.sB},iTm:function(){return W.iT},Pls:function(){return Ct.Pl},Oxq:function(){return Hn},WLi:function(){return Fe},$9M:function(){return W.$9},nCn:function(){return ka},iNG:function(){return Da},tD8:function(){return Ci},pg9:function(){return kr},Ofb:function(){return W.Of},ibf:function(){return oo},WyG:function(){return ee},l6$:function(){return Bt.l6},WGR:function(){return Pt},C$H:function(){return bo.C$},cNQ:function(){return bo.cN},ZZb:function(){return W.ZZ},elO:function(){return bo.el},_Ko:function(){return po},Mev:function(){return ao},i2K:function(){return yo},WmO:function(){return Or.Wm},oBi:function(){return Ct.oB},igR:function(){return F.ig},DU1:function(){return F.DU},XCj:function(){return F.XC},lIL:function(){return Ct.lI},hi9:function(){return Ct.hi},p27:function(){return F.p2},z9d:function(){return rl.z},eJW:function(){return Ct.eJ},Cor:function(){return Ct.Co},aZq:function(){return Ct.aZ},P1D:function(){return ma.P1},ngQ:function(){return Ct.ng},ett:function(){return Ct.et},ySm:function(){return ct.y},Zd$:function(){return W.Zd},cLh:function(){return Ct.cL},baz:function(){return W.b},fde:function(){return Ct.fd},Xdt:function(){return bo.Xd},Cld:function(){return Ct.Cl},vH8:function(){return Ct.vH},PLH:function(){return Or.PL},V8t:function(){return Or.V8},tMk:function(){return Or.tM},xQm:function(){return Or.xQ},sRe:function(){return Ct.sR},frb:function(){return Wn},$N2:function(){return gn},U1u:function(){return Ee},HS$:function(){return F.HS},vBu:function(){return F.vB},QYZ:function(){return F.QY},t9d:function(){return F.t9},Kgy:function(){return Or.Kg},aJ2:function(){return Or.aJ},n14:function(){return va.n1},DiB:function(){return va.Di},l1O:function(){return W.l1},w5o:function(){return W.w5},p3Q:function(){return W.p3},G5e:function(){return W.G5},xj2:function(){return W.xj},rxY:function(){return W.rx},Ils:function(){return bo.Il},zCB:function(){return F.zC},wNf:function(){return Ct.wN},Dmu:function(){return Ct.Dm},Bsl:function(){return g.Bs},yKv:function(){return Os.y},fMB:function(){return Ct.fM},gCg:function(){return il},eT6:function(){return W.eT},q4O:function(){return W.q4},ymE:function(){return Ia.ym}});var L={};e.r(L),e.d(L,{Action:function(){return F.aU},ActionBar:function(){return F.ol},ActionBarProvider:function(){return F.N0},ActionContext:function(){return F.fW},ActionContextProvider:function(){return F.EI},ActionDesigner:function(){return F.$L},AfterSuccess:function(){return F.$b},AntdSchemaComponentPlugin:function(){return Ro},AntdSchemaComponentProvider:function(){return Fo},AppendsTreeSelect:function(){return la},AssignedFieldValues:function(){return F.eY},AssociationField:function(){return oa},AssociationSelect:function(){return pi},AttachmentList:function(){return Yo.fU},AutoComplete:function(){return Tl},Block:function(){return os},BlockItem:function(){return $a.j},ButtonEditor:function(){return F.C1},CardItem:function(){return Rl},Cascader:function(){return Ul},Checkbox:function(){return da},CollectionSelect:function(){return Vl},ColorPicker:function(){return Hl},ColorSelect:function(){return Jl},Cron:function(){return fi},CronSet:function(){return ql},DataSourceCollectionCascader:function(){return kl},DataSourceSelect:function(){return zl},DatePicker:function(){return ma.Mt},DatePickerProvider:function(){return ma.iN},Details:function(){return es},DetailsDesigner:function(){return Q},EditComponent:function(){return W.Fy},EditDefaultValue:function(){return W.Ni},EditDescription:function(){return W.q8},EditOperator:function(){return W.HG},EditPattern:function(){return W.QT},EditRequired:function(){return W.JE},EditSortField:function(){return ol},EditTitle:function(){return W.$w},EditTitleField:function(){return W.nB},EditTooltip:function(){return W.Oc},EditValidationRules:function(){return W.zd},Editable:function(){return nl},EllipsisWithTooltip:function(){return Ao.BQ},ErrorFallback:function(){return ct.H},Expand:function(){return hi},Filter:function(){return Or.wn},FilterAction:function(){return Or.Gz},FilterActionContext:function(){return Or.tJ},FilterContext:function(){return Or.fo},FilterDynamicComponent:function(){return Or.VT},FilterLogicContext:function(){return Or.Xs},FixedBlock:function(){return tr},FixedBlockDesignerItem:function(){return Lo},FixedBlockWrapper:function(){return Qn},Form:function(){return ae},FormDialog:function(){return zi.D},FormField:function(){return Ut},FormItem:function(){return W.xJ},FormV2:function(){return hr},G2Plot:function(){return _i},G2PlotRenderer:function(){return gi},Grid:function(){return va.rj},GridCard:function(){return Va},GridRowContext:function(){return va.jg},HTMLEncode:function(){return Ao.gs},IconPicker:function(){return vs},Input:function(){return Ao.II},InputNumber:function(){return Gi},InputReadPretty:function(){return Ao.mX},InputRecordPicker:function(){return bo.zD},Json:function(){return Ao.Ph},List:function(){return za},Markdown:function(){return Ji},MarkdownReadPretty:function(){return Yi},Menu:function(){return Ca},NanoIDInput:function(){return cu},Page:function(){return Hr},Pagination:function(){return Ts},Password:function(){return Rs},Percent:function(){return Bs},Preview:function(){return Ls.M},QuickEdit:function(){return Ks},Radio:function(){return yi},ReadPretty:function(){return Ao.iV},ReadPrettyRecordPicker:function(){return bo.OD},RecordPicker:function(){return bo.lb},RecordPickerContext:function(){return bo.b7},RecordPickerProvider:function(){return bo.sU},RefreshDataBlockRequest:function(){return F.x1},RemoteSelect:function(){return Ye},RemoveButton:function(){return F.xZ},RemoveConditionContext:function(){return Or.Iu},RequestSettings:function(){return F.Mk},RichText:function(){return Ns},SecondConFirm:function(){return F.y0},Select:function(){return It},SkipValidation:function(){return F.co},Space:function(){return $s},StablePopover:function(){return mr.q},Table:function(){return Jo},TableBlockDesigner:function(){return Xs},TableField:function(){return al},TableSelectorDesigner:function(){return qs},TableV2:function(){return aa},Tabs:function(){return Ei},TabsContextProvider:function(){return tu},Templates:function(){return Pe},TestDesigner:function(){return $a.L},TimePicker:function(){return ll},TreeSelect:function(){return lu},UnixTimestamp:function(){return uu},Upload:function(){return Yo.gq},Uploader:function(){return Yo.Qm},Variable:function(){return Ia._w},VariableScopeProvider:function(){return Ia.rj},WorkflowConfig:function(){return F.Fj},actionSettings:function(){return F.SL},actionSettingsItems:function(){return F.sB},allowAddNew:function(){return W.iT},defaultFieldNames:function(){return Hn},fetchTemplateData:function(){return Fe},filterFormItemSettings:function(){return W.$9},findByUid:function(){return ka},findKeysByUid:function(){return Da},findMenuItem:function(){return Ci},formDetailsSettings:function(){return kr},formItemSettings:function(){return W.Of},formSettings:function(){return oo},formV1Settings:function(){return ee},genStyleHook:function(){return Bt.l6},getCurrentOptions:function(){return Pt},getDatePickerLabels:function(){return bo.C$},getLabelFormatValue:function(){return bo.cN},isFileCollection:function(){return W.ZZ},isShowFilePicker:function(){return bo.el},pageSettings:function(){return po},pageTabSettings:function(){return ao},readPrettyFormSettings:function(){return yo},removeNullCondition:function(){return Or.Wm},useA:function(){return F.ig},useActionBarContext:function(){return F.DU},useActionContext:function(){return F.XC},useCloseAction:function(){return F.p2},useColumnSchema:function(){return rl.z},useDatePickerContext:function(){return ma.P1},useDownloadLogs:function(){return ct.y},useEnsureOperatorsValid:function(){return W.Zd},useFieldMode:function(){return W.b},useFieldNames:function(){return bo.Xd},useFilterActionProps:function(){return Or.PL},useFilterFieldOptions:function(){return Or.V8},useFilterFieldProps:function(){return Or.tM},useFilterOptions:function(){return Or.xQ},useFixedBlock:function(){return Wn},useFixedSchema:function(){return gn},useFormDataTemplates:function(){return Ee},useGetAriaLabelOfAction:function(){return F.HS},useGetAriaLabelOfDrawer:function(){return F.vB},useGetAriaLabelOfModal:function(){return F.QY},useGetAriaLabelOfPopover:function(){return F.t9},useGetFilterFieldOptions:function(){return Or.Kg},useGetFilterOptions:function(){return Or.aJ},useGridContext:function(){return va.n1},useGridRowContext:function(){return va.Di},useIsAddNewForm:function(){return W.l1},useIsAssociationField:function(){return W.w5},useIsFieldReadPretty:function(){return W.p3},useIsFileField:function(){return W.G5},useIsFormReadPretty:function(){return W.xj},useIsSelectFieldMode:function(){return W.rx},useLabelUiSchema:function(){return bo.Il},useLinkageAction:function(){return F.zC},useStyles:function(){return Os.y},useTabsContext:function(){return il},useTitleFieldOptions:function(){return W.eT},useValidateSchema:function(){return W.q4},useVariableScope:function(){return Ia.ym}});var l=e(15009),K=e.n(l),p=e(99289),A=e.n(p),x=e(12444),N=e.n(x),r=e(72004),B=e.n(r),h=e(31996),I=e.n(h),b=e(26037),T=e.n(b),t=e(97857),o=e.n(t),d=e(67294),R=e(31601),P=e(14896),g=e(70993),u=e(89127),j=function(M){return A()(K()().mark(function q(){var le,ce;return K()().wrap(function(De){for(;;)switch(De.prev=De.next){case 0:return De.prev=0,De.next=3,this.api.request(M);case 3:return ce=De.sent,De.abrupt("return",ce==null||(le=ce.data)===null||le===void 0?void 0:le.data);case 7:return De.prev=7,De.t0=De.catch(0),De.abrupt("return",[]);case 10:case"end":return De.stop()}},q,this,[[0,7]])}))},F=e(76157),z=e(13769),y=e.n(z),E=e(57134),C=e(86201),a=e(94350),D=e(28459),c=e(57953),v=e(12174),i=e(6145),m=e(74538),f=e(64016),O=e(95354),n=e(85893),U=["form","children"],k=["form","children","disabled"],H=["request","effects","initialValue","useValues"],$=function(M){var q=M.form,le=M.children,ce=y()(M,U),be=(0,a.useField)(),De=(0,a.useFieldSchema)(),Ke=(0,Ct.lI)(q.createVoidField(o()(o()({},be.props),{},{basePath:""})));return(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},ce),{},{children:(0,n.jsx)(a.RecursionField,{basePath:Ke.address,schema:De,onlyRenderProperties:!0})}))})})},V=function(M){return M.children},w=function(M){var q=M.form,le=M.children,ce=M.disabled,be=y()(M,k),De=(0,a.useField)(),Ke=(0,a.useFieldSchema)(),We=(0,Ct.lI)(q.createVoidField(o()(o()({},De.props),{},{basePath:""}))),ke=(0,Ct.Co)(Ke["x-component"],V);return(0,d.useEffect)(function(){q.disabled=ce||De.disabled},[ce,De.disabled]),(0,n.jsx)(D.ZP,{componentDisabled:ce,children:(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},be),{},{children:(0,n.jsx)(a.FieldContext.Provider,{value:We,children:(0,n.jsx)(ke,o()(o()({},De.componentProps),{},{children:(0,n.jsx)(a.RecursionField,{basePath:We.address,schema:Ke,onlyRenderProperties:!0})}))})}))})})})},G=function(M){var q=M.request,le=M.initialValue;return q||function(){return Promise.resolve({data:le})}},ne=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(0,v.QT)(G(q),M)},X=(0,d.createContext)(null);X.displayName="FormBlockContext";var ae=(0,a.observer)(function(Z){var M=Z.request,q=Z.effects,le=Z.initialValue,ce=Z.useValues,be=ce===void 0?ne:ce,De=y()(Z,H),Ke=(0,a.useFieldSchema)(),We=(0,a.useField)(),ke=(0,d.useMemo)(function(){return(0,C.createForm)({effects:q})},[]),Ze=be({uid:Ke["x-uid"],onSuccess:function(tt){return A()(K()().mark(function it(){return K()().wrap(function(st){for(;;)switch(st.prev=st.next){case 0:return st.next=2,ke.reset();case 2:ke.setValues(tt==null?void 0:tt.data),ke.setInitialValues(tt==null?void 0:tt.data);case 4:case"end":return st.stop()}},it)}))()}},Z),Je=(0,d.useContext)(X);return(0,n.jsx)(X.Provider,{value:{parent:Je,form:ke,result:Ze,field:We,fieldSchema:Ke},children:(0,n.jsx)(c.Z,{spinning:(Ze==null?void 0:Ze.loading)||!1,children:Ke["x-decorator"]==="Form"?(0,n.jsx)(w,o()({form:ke},De)):(0,n.jsx)($,o()({form:ke},De))})})},{displayName:"Form"});ae.Designer=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsxs)(m.aN,{template:ce,title:le||q,children:[(0,n.jsx)(f.G,{componentName:"Form",collectionName:q}),(0,n.jsx)(m.Z5,{}),(0,n.jsx)(m.qx,{removeParentsIfNoChildren:!0,breakRemoveOn:{"x-component":"Grid"}})]})};var oe=e(5537),ee=new oe.F5({name:"FormV1Settings",items:[{name:"template",Component:f.G,useComponentProps:function(){var M=(0,i.useCollection_deprecated)(),q=M.name;return{componentName:"Form",collectionName:q}}},{name:"divider",type:"divider"},{name:"remove",type:"remove",componentProps:{removeParentsIfNoChildren:!0,breakRemoveOn:{"x-component":"Grid"}}}]}),W=e(54801),de=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"FormSettings",template:ce,title:le||q})},me=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"ReadPrettyFormSettings",template:ce,title:le||q})},Q=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"FormDetailsSettings",template:ce,title:le||q})},_e=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"blockSettings:filterForm",template:ce,title:le||q})},ye=e(7340),Ae=e(15503),Se=e(68230),he=e(9783),ve=e.n(he),J=e(68400),Y=e.n(J),ue=e(97133),xe=e(85667),fe=e(73773),Me=e(68433),Ie=e(9361),Ue=e(96486),Ne=e.n(Ue),Oe=e(31019),pe=e(4595),Ce=e(86406),se=e(90615),S=e(44256),te=e(76690),ge=e(34588),ie=e(9780),Be=e(18686),Xe=e(94804),rt=e(5574),Te=e.n(rt),et=e(42075),Re=e(34041),He=e(26793),ut=e(32268),Bt=e(60094),Yt=e(52677),qt=e.n(Yt),In=e(50888),un=e(66309),yn=e(96074),qn=e(27484),Ft=e.n(qn),Mn=e(87714),Ct=e(84577),hn=e(4340),xn=e(97937),Xt=e(32983),Wt=e(58812),on=e(96695),vn=e.n(on),En=e(19632),Cn=e.n(En),Hn={label:"label",value:"value",color:"color",options:"children"};function Vt(Z,M){var q=[];if(!Array.isArray(Z))return q;for(var le=0;le<Z.length;le++){var ce=Z[le][M.options];Array.isArray(ce)&&q.push.apply(q,Cn()(Vt(ce,M))),q.push(o()({},Z[le]))}return q}function Pt(Z,M,q){var le=Vt(M,q),ce=(0,Ue.castArray)(Z).map(function(De){return(0,Me.isPlainObject)(De)?De[q.value]:De});function be(De){if(!De)return[];var Ke=[],We=vn()(ce),ke;try{var Ze=function(){var pt=ke.value,tt=De.find(function(it){return it[q.value]==pt})||{value:pt,label:pt&&pt.toString()};Ke.push(tt)};for(We.s();!(ke=We.n()).done;)Ze()}catch(Je){We.e(Je)}finally{We.f()}return Ke}return be(le)}var Et=e(67668),gt=(0,a.observer)(function(Z){var M,q=o()(o()({},Hn),Z.fieldNames),le=(0,a.useField)(),ce=(0,Et.Hy)(),be=le.dataSource||Z.options||(ce==null?void 0:ce.uiSchema.enum)||[],De=Pt(le.value,be,q);return!(0,fe.isValid)(Z.value)&&!De.length?(0,n.jsx)("div",{}):(0,C.isArrayField)(le)&&(le==null||(M=le.value)===null||M===void 0?void 0:M.length)===0?(0,n.jsx)("div",{}):(0,n.jsx)("div",{children:(0,n.jsx)(Wt.B,{ellipsis:Z.ellipsis,children:De.map(function(Ke,We){return(0,n.jsx)(un.Z,{color:Ke[q.color],icon:Ke.icon,children:Ke[q.label]},We)})})})},{displayName:"ReadPretty"}),Lt=["value","options","onChange","fieldNames","mode","loading","rawOptions","defaultValue"],en=["objectValue","loading","value","rawOptions","defaultValue"],Bn=function(M){return!(0,fe.isValid)(M)||qt()(M)==="object"&&Object.keys(M).length===0},an=function(M){var q=M.value,le=M.options,ce=M.onChange,be=M.fieldNames,De=M.mode,Ke=M.loading,We=M.rawOptions,ke=M.defaultValue,Ze=y()(M,Lt),Je=function(tt){var it;if(!Bn(tt)){var at=(0,fe.toArr)(tt).filter(function(Mt){return Mt}).map(function(Mt){return(0,Me.isPlainObject)(Mt)?Mt[be.value]:Mt}),st=(it=Pt(at,le,be))===null||it===void 0?void 0:it.map(function(Mt){return{label:Mt[be.label],value:Mt[be.value]}});return["tags","multiple"].includes(De)||M.multiple?st:st.shift()}};return(0,n.jsx)(Re.default,o()({role:"button","data-testid":"select-object-".concat(De||"single"),value:Je(q),defaultValue:Je(ke),allowClear:{clearIcon:(0,n.jsx)(hn.Z,{role:"button","aria-label":"icon-close-select"})},labelInValue:!0,notFoundContent:Ke?(0,n.jsx)(c.Z,{}):(0,n.jsx)(Xt.Z,{image:Xt.Z.PRESENTED_IMAGE_SIMPLE}),options:le,fieldNames:be,showSearch:!0,popupMatchSelectWidth:!1,filterOption:function(tt,it){var at;return((at=it==null?void 0:it[be.label||"label"])!==null&&at!==void 0?at:"").includes(tt)},filterSort:function(tt,it){var at,st;return((at=tt==null?void 0:tt[be.label||"label"])!==null&&at!==void 0?at:"").toLowerCase().localeCompare(((st=it==null?void 0:it[be.label||"label"])!==null&&st!==void 0?st:"").toLowerCase())},onChange:function(tt){var it=Pt((0,fe.toArr)(tt).map(function(at){return at.value}),We||le,be);["tags","multiple"].includes(De)||M.multiple?ce==null||ce(it):ce==null||ce(it.shift()||null)},mode:De,tagRender:function(tt){return(0,n.jsx)(un.Z,o()(o()({role:"button","aria-label":tt.label,closeIcon:(0,n.jsx)(xn.Z,{role:"button","aria-label":"icon-close-tag"})},tt),{},{children:tt.label}))}},Ze))},St=function(M,q){var le;return((le=q==null?void 0:q.label)!==null&&le!==void 0?le:"").toLowerCase().includes((M||"").toLowerCase())},Rt=(0,a.connect)(function(Z){var M=Z.objectValue,q=Z.loading,le=Z.value,ce=Z.rawOptions,be=Z.defaultValue,De=y()(Z,en),Ke=Z.multiple?"multiple":Z.mode;if(Ke&&!["multiple","tags"].includes(Ke)&&(Ke=void 0),M)return(0,n.jsx)(an,o()(o()({rawOptions:ce},De),{},{defaultValue:be,value:le,mode:Ke,loading:q}));var We=function(Ze){return["tags","multiple"].includes(Z.mode)||Z.multiple?Ze?(0,fe.toArr)(Ze):void 0:Ze};return(0,n.jsx)(Re.default,o()(o()({role:"button","data-testid":"select-".concat(Ke||"single"),showSearch:!0,filterOption:St,allowClear:{clearIcon:(0,n.jsx)(hn.Z,{role:"button","aria-label":"icon-close-select"})},popupMatchSelectWidth:!1,notFoundContent:q?(0,n.jsx)(c.Z,{}):(0,n.jsx)(Xt.Z,{image:Xt.Z.PRESENTED_IMAGE_SIMPLE}),value:We(le),defaultValue:We(be),tagRender:function(Ze){return(0,n.jsx)(un.Z,o()(o()({role:"button","aria-label":Ze.label,closeIcon:(0,n.jsx)(xn.Z,{role:"button","aria-label":"icon-close-tag"})},Ze),{},{children:Ze.label}))}},De),{},{onChange:function(Ze){var Je;(Je=Z.onChange)===null||Je===void 0||Je.call(Z,Ze===void 0?null:Ze)},mode:Ke}))},(0,a.mapProps)({dataSource:"options"},function(Z,M){return o()(o()({},Z),{},{fieldNames:o()(o()({},Hn),Z.fieldNames),suffixIcon:M!=null&&M.loading||M!=null&&M.validating?(0,n.jsx)(In.Z,{}):Z.suffixIcon})}),(0,a.mapReadPretty)(gt)),It=Rt;It.ReadPretty=gt;var Jt=It,tn=e(36586),pn=function(M,q){return(0,Ue.castArray)(M).filter(function(le){return le!=null}).map(function(le){return qt()(le)==="object"?le[q.value]:le})},jt=(0,a.observer)(function(Z){var M=o()(o()({},Hn),Z.fieldNames),q=(0,a.useField)(),le=(0,a.useFieldSchema)(),ce=(0,tn.a)(),be=(0,F.XC)(),De=be.snapshot,Ke=(0,v.QT)(De?A()(K()().mark(function ke(){return K()().wrap(function(Je){for(;;)switch(Je.prev=Je.next){case 0:return Je.abrupt("return",{data:ce[le.name]});case 1:case"end":return Je.stop()}},ke)})):o()(o()({action:"list"},Z.service),{},{params:{paginate:!1,filter:ve()({},M.value,{$in:pn(q.value,M)})}}),{refreshDeps:[Z.service,q.value]}),We=Ke.data;return(0,n.jsx)(It.ReadPretty,o()(o()({},Z),{},{options:We==null?void 0:We.data}))},{displayName:"ReadPretty"}),Rn=e(8341),_n=e(44990),Dn=["fieldNames","service","wait","value","defaultValue","objectValue","manual","mapOptions","targetField","CustomDropdownRender","optionFilter","dataSource"],ht="N/A",Ge=(0,a.connect)(function(Z){var M,q,le=Z.fieldNames,ce=le===void 0?{}:le,be=Z.service,De=be===void 0?{}:be,Ke=Z.wait,We=Ke===void 0?300:Ke,ke=Z.value,Ze=Z.defaultValue,Je=Z.objectValue,pt=Z.manual,tt=pt===void 0?!0:pt,it=Z.mapOptions,at=Z.targetField,st=Z.CustomDropdownRender,Mt=Z.optionFilter,yt=Z.dataSource,Ht=y()(Z,Dn),wt=(0,_n.FC)(),Kn=(0,Rn.FE)(yt||wt),cn=(0,d.useState)(!1),Kt=Te()(cn,2),mn=Kt[0],Nn=Kt[1],er=(0,d.useRef)(!1),wn=(0,a.useFieldSchema)(),bn=((M=wn["x-component-props"])===null||M===void 0?void 0:M.addMode)==="quickAdd",nr=(0,i.useCollection_deprecated)(),Pn=nr.getField,yr=(0,d.useRef)(null),Lr=(0,i.useCollectionManager_deprecated)(),jr=Lr.getCollectionJoinField,ar=Lr.getInterface,cr=wn["x-collection-field"]||wn.name,Zn=Pn(cr)||jr(cr),jn=at||(Zn==null?void 0:Zn.target)&&(ce==null?void 0:ce.label)&&jr("".concat(Zn.target,".").concat(ce.label)),Jn=(0,d.useMemo)(function(){if(jn!=null&&jn.interface){var Xr;return((Xr=ar(jn.interface))===null||Xr===void 0||(Xr=Xr.filterable)===null||Xr===void 0?void 0:Xr.operators[0].value)||"$includes"}return"$includes"},[jn]),rr=(0,Ct.eJ)(),Sn=(0,d.useCallback)(function(Xr){try{return Xr.filter(function(ro){return["number","string"].includes(qt()(ro[ce.value]))}).map(function(ro){var Io,To,jo=rr(ro[ce.label]);if(jn!=null&&(Io=jn.uiSchema)!==null&&Io!==void 0&&Io.enum)if(Array.isArray(jo))jo=jo.map(function(Go,xa){var ia=jn.uiSchema.enum.find(function(Di){return Di.value===Go});return ia?(0,n.jsx)(un.Z,{role:"button",color:ia.color,style:{marginRight:3},children:(ia==null?void 0:ia.label)||Go},xa):(0,n.jsx)(un.Z,{role:"button",children:Go},Go)}).reverse();else{var Uo=jn.uiSchema.enum.find(function(Go){return Go.value===jo});Uo&&(jo=(0,n.jsx)(un.Z,{role:"button",color:Uo.color,children:Uo.label}))}if((jn==null?void 0:jn.type)==="date"&&(jo=Ft()(jo).format("YYYY-MM-DD")),it){var Qo;return it((Qo={},ve()(Qo,ce.label,jo||ht),ve()(Qo,ce.value,ro[ce.value]),Qo))}return o()(o()({},ro),{},(To={},ve()(To,ce.label,jo||ht),ve()(To,ce.value,ro[ce.value]),To))}).filter(Boolean)}catch(ro){return console.error(ro),Xr}},[jn==null?void 0:jn.uiSchema,ce]),$n=(0,v.QT)(o()(o()({action:"list"},De),{},{headers:Kn,params:o()(o()({pageSize:200},De==null?void 0:De.params),{},{filter:De==null||(q=De.params)===null||q===void 0?void 0:q.filter})}),{manual:tt,debounceWait:We}),ur=$n.data,fr=$n.run,Sr=$n.loading,Ur=(0,d.useMemo)(function(){return JSON.stringify({service:De,fieldNames:ce})},[De,ce]),vr=(0,d.useCallback)(function(){return yr.current&&st?(0,n.jsx)(st,{search:yr.current,callBack:function(){yr.current=null,Nn(!1)}}):null},[yr.current]);(0,d.useEffect)(function(){er.current&&fr()},[Ur]);var Gr=function(){var Xr=A()(K()().mark(function ro(Io){var To;return K()().wrap(function(Uo){for(;;)switch(Uo.prev=Uo.next){case 0:fr({filter:(0,Mn.EO)([Io?ve()({},ce.label,ve()({},Jn,Io)):{},De==null||(To=De.params)===null||To===void 0?void 0:To.filter])}),yr.current=Io;case 2:case"end":return Uo.stop()}},ro)}));return function(Io){return Xr.apply(this,arguments)}}(),co=(0,d.useMemo)(function(){var Xr,ro=ke||Ze;if(!(ur!=null&&(Xr=ur.data)!==null&&Xr!==void 0&&Xr.length))return ro!=null?Array.isArray(ro)?ro:[ro]:[];var Io=ro!=null&&(Array.isArray(ro)?ro:[o()(o()({},ro),{},ve()({},ce.value,ro[ce.value]||ro))])||[],To=typeof Mt=="function"?ur.data.filter(Mt):ur.data;return(0,Ue.uniqBy)(To.concat(Io!=null?Io:[]),ce.value)},[ke,Ze,ur==null?void 0:ur.data,ce.value,Mt]),Jr=function(ro){Nn(ro),yr.current=null,ro&&fr(),er.current=!0};return(0,n.jsx)(It,o()(o()({open:mn,popupMatchSelectWidth:!1,autoClearSearchValue:!0,filterOption:!1,filterSort:null,fieldNames:ce,onSearch:Gr,onDropdownVisibleChange:Jr,objectValue:Je,value:ke,defaultValue:Ze},Ht),{},{loading:ur?Sr:!0,options:Sn(co),rawOptions:co,dropdownRender:function(ro){var Io=co.some(function(To){return To[ce.label]===yr.current});return(0,n.jsx)(n.Fragment,{children:bn?(0,n.jsxs)(n.Fragment,{children:[!((ur==null?void 0:ur.data.length)===0&&yr!==null&&yr!==void 0&&yr.current)&&ro,(ur==null?void 0:ur.data.length)>0&&(yr==null?void 0:yr.current)&&!Io&&(0,n.jsx)(yn.Z,{style:{margin:0}}),!Io&&(0,n.jsx)(vr,{})]}):ro})}}))},(0,a.mapProps)({dataSource:"options"},function(Z,M){var q,le=(0,a.useFieldSchema)();return o()(o()({},Z),{},{fieldNames:o()(o()(o()(o()({},Hn),Z.fieldNames),M.componentProps.fieldNames),(q=le["x-component-props"])===null||q===void 0?void 0:q.fieldNames),suffixIcon:M!=null&&M.loading||M!=null&&M.validating?(0,n.jsx)(In.Z,{}):Z.suffixIcon})}),(0,a.mapReadPretty)(jt)),Ye=Ge;Ye.ReadPretty=jt;var Qe=null,Ee=function(){var M=(0,a.useFieldSchema)(),q=(0,He.$)(),le=q.t,ce=(0,ye.bz)(),be=ce.duplicateData,De=(0,i.useCollectionManager_deprecated)(),Ke=De.getCollectionJoinField;if(be)return be;var We=Le(M),ke=We.items,Ze=ke===void 0?[]:ke,Je=We.display,pt=Je===void 0?!0:Je;Ze.forEach(function(at){try{var st;at.fields=(st=at.fields)===null||st===void 0?void 0:st.map(function(Mt){var yt=Ke("".concat(at.collection,".").concat(Mt));return yt?Mt:""}).filter(Boolean)}catch(Mt){(0,Me.error)(Mt),at.fields=[]}});var tt=[{key:"none",title:le("None")}].concat(Ze.map(function(at,st){return o()(o()({key:st},at),{},{isLeaf:at.dataId!==null&&at.dataId!==void 0,titleCollectionField:(at==null?void 0:at.titleField)&&Ke("".concat(at.collection,".").concat(at.titleField))})})),it=Ze.find(function(at){return at.default});return{templates:tt,display:pt,defaultTemplate:it,enabled:Ze.length>0&&Ze.every(function(at){return at.dataId||at.dataScope})}},Pe=function(M){var q=M.style,le=q===void 0?{}:q,ce=M.form,be=(0,Bt.dQ)(),De=be.token,Ke=Ee(),We=Ke.templates,ke=Ke.display,Ze=Ke.enabled,Je=Ke.defaultTemplate,pt=(0,i.useCollectionManager_deprecated)(),tt=pt.getCollectionJoinField,it=(0,ut.ss)(We),at=(0,d.useState)((Je==null?void 0:Je.key)||"none"),st=Te()(at,2),Mt=st[0],yt=st[1],Ht=(0,d.useState)(null),wt=Te()(Ht,2),Kn=wt[0],cn=wt[1],Kt=(0,v.LY)(),mn=(0,He.$)(),Nn=mn.t;(0,d.useEffect)(function(){Ze&&Je&&ce&&(ce.__template=!0,Je.key==="duplicate"&&nr(Je.dataId,Je))},[]),(0,d.useEffect)(function(){it!=null&&it.some(function(yr){return yr.key===Mt})||bn("none")},[it]);var er=(0,d.useMemo)(function(){return o()({display:"flex",alignItems:"center",backgroundColor:De.colorFillAlter,padding:De.padding},le)},[le,De.colorFillAlter]),wn=(0,d.useMemo)(function(){return{fontSize:De.fontSize,fontWeight:"bold",whiteSpace:"nowrap",marginRight:De.marginXS}},[De.fontSize,De.marginXS]),bn=(0,d.useCallback)(function(){var yr=A()(K()().mark(function Lr(jr){return K()().wrap(function(cr){for(;;)switch(cr.prev=cr.next){case 0:yt(jr),cn(null),ce==null||ce.reset();case 3:case"end":return cr.stop()}},Lr)}));return function(Lr){return yr.apply(this,arguments)}}(),[]),nr=(0,d.useCallback)(function(){var yr=A()(K()().mark(function Lr(jr,ar){var cr;return K()().wrap(function(jn){for(;;)switch(jn.prev=jn.next){case 0:cr=o()(o()({},ar),{},{dataId:jr}),cn(ar),Fe(Kt,cr,Nn).then(function(Jn){return ce&&Jn&&(ce.reset(),ce.__template=!0,(0,Me.forEach)(Jn,function(rr,Sn){if(rr){var $n;ce.values[Sn]=rr,ce==null||($n=ce.setInitialValuesIn)===null||$n===void 0||$n.call(ce,Sn,rr)}})),Jn}).catch(function(Jn){console.error(Jn)});case 3:case"end":return jn.stop()}},Lr)}));return function(Lr,jr){return yr.apply(this,arguments)}}(),[]);if(!Ze||!ke)return null;var Pn=it==null?void 0:it.find(function(yr){return yr.key===Mt});return(0,n.jsx)("div",{style:er,children:(0,n.jsxs)(et.Z,{wrap:!0,children:[(0,n.jsxs)("label",{style:wn,children:[Nn("Data template"),": "]}),(0,n.jsx)(Re.default,{role:"button","data-testid":"select-form-data-template",popupMatchSelectWidth:!1,options:it,fieldNames:{label:"title",value:"key"},value:Mt,onChange:bn}),Mt!=="none"&&Pn&&(0,n.jsx)(Ye,{style:{width:220},fieldNames:{label:Pn==null?void 0:Pn.titleField,value:"id"},target:Pn==null?void 0:Pn.collection,value:Kn,objectValue:!0,service:{resource:Pn==null?void 0:Pn.collection,params:{filter:Pn==null?void 0:Pn.dataScope}},onChange:function(Lr){return nr(Lr==null?void 0:Lr.id,o()(o()({},Lr),Pn))},targetField:tt("".concat(Pn==null?void 0:Pn.collection,".").concat(Pn.titleField))})]})})};function Le(Z){var M=(0,ye.Fi)(Z);return M?Ne().cloneDeep(M["x-data-templates"])||{}:{}}function Fe(Z,M,q){return $e.apply(this,arguments)}function $e(){return $e=A()(K()().mark(function Z(M,q,le){return K()().wrap(function(be){for(;;)switch(be.prev=be.next){case 0:if(!(q.fields.length===0||!q.dataId)){be.next=2;break}return be.abrupt("return");case 2:return be.abrupt("return",M.resource(q.collection).get({filterByTk:q.dataId,fields:q.fields,isTemplate:!0}).then(function(De){var Ke;return(Ke=De.data)===null||Ke===void 0?void 0:Ke.data}));case 3:case"end":return be.stop()}},Z)})),$e.apply(this,arguments)}var qe=e(3192),_t=function(){var M,q,le=(0,Be.aZ)(),ce=(0,a.useFieldSchema)(),be=Ie.Z.useToken(),De=be.token,Ke=(0,Ct.ng)(),We=Ke.designable,ke=(0,qe.g)()||{},Ze=ke.heightProps,Je=Ze||{},pt=Je.title,tt=Ee(),it=tt.display,at=tt.enabled,st=ce.reduceProperties(function(nr,Pn){return Pn["x-component"]==="ActionBar"?Pn:nr}),Mt=Object.keys((st==null?void 0:st.properties)||{}).length>0,yt=ce==null||(M=ce.parent)===null||M===void 0||(M=M["x-decorator"])===null||M===void 0||(q=M.includes)===null||q===void 0?void 0:q.call(M,"FormBlockProvider"),Ht=Mt||We?De.controlHeight+(yt?1:2)*De.marginLG:De.marginLG,wt=pt?De.fontSizeLG*De.lineHeightLG+De.padding*2-1:0,Kn=(0,Xe.hS)()||{},cn=Kn.data,Kt=(cn==null?void 0:cn.meta)||{},mn=Kt.count,Nn=Kt.pageSize,er=mn>Nn,wn=er?De.controlHeightSM+1*De.paddingLG:0,bn=it&&at?De.controlHeight+2*De.padding+De.margin:0;return le-Ht-De.paddingLG-wt-wn-bn},vt=e(25324),dt,xt,bt=["form","children"],ft=["form","children","disabled"],At=["form","disabled"],Nt=function(M){var q=M.form,le=M.children,ce=y()(M,bt),be=(0,a.useField)(),De=(0,a.useFieldSchema)(),Ke=(0,Ct.lI)(q.createVoidField(o()(o()({},be.props),{},{basePath:""}))),We=_t(),ke=Ie.Z.useToken(),Ze=ke.token,Je=(0,Ct.ng)(),pt=Je.designable;return(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},ce),{},{children:(0,n.jsx)("div",{className:(0,ue.css)(dt||(dt=Y()([`
653
+ `]))))}));return(0,ne.jsx)(se.BQs,{ellipsis:!0,popoverContent:Et,children:Et})};var qt=(0,l.createContext)([]);qt.displayName="VariableScopeContext";function In(Ft){var Mn=Ft.scope,Ct=Mn===void 0?[]:Mn,hn=Ft.children;return(0,ne.jsx)(qt.Provider,{value:Ct,children:hn})}function un(){return(0,l.useContext)(qt)}function yn(){return null}yn.Input=(0,L.connect)(Ae),yn.TextArea=(0,L.connect)(ut,(0,L.mapReadPretty)(ut.ReadPretty)),yn.RawTextArea=(0,L.connect)(Me),yn.JSON=(0,L.connect)(Ue);var qn=null},88969:function(ze,re,e){"use strict";e.d(re,{m:function(){return u}});var L=e(15009),l=e.n(L),K=e(19632),p=e.n(K),A=e(99289),x=e.n(A),N=e(5574),r=e.n(N),B=e(97133),h=e(38089),I=e(67294),b=e(26793),T=e(60094),t=e(9783),o=e.n(t),d=(0,T.l6)("nb-variable-select",function(j){var F=j.componentCls;return o()({},F,{position:"relative",".ant-select.ant-cascader":{position:"absolute",top:"-1px",right:"-1px",minWidth:"auto",width:"calc(100% + 2px)",height:"calc(100% + 2px)",overflow:"hidden",opacity:0},".variable-btn":{fontStyle:"italic",fontFamily:"'New York', 'Times New Roman', Times, serif"},".Cascader-popupClassName":{".ant-cascader-menu":{marginBottom:0}}})}),R=d,P=e(2876),g=e(85893);function u(j){var F=j.options,z=j.setOptions,y=j.onInsert,E=j.changeOnSelect,C=E===void 0?!1:E,a=j.fieldNames,D=a===void 0?{}:a,c=j.className,v=(0,b.$)(),i=v.t,m=(0,I.useState)([]),f=r()(m,2),O=f[0],n=f[1],U=R(),k=U.wrapSSR,H=U.componentCls,$=U.hashId,V=(0,T.dQ)(),w=V.token;function G(X){return ne.apply(this,arguments)}function ne(){return ne=x()(l()().mark(function X(ae){var oe,ee;return l()().wrap(function(de){for(;;)switch(de.prev=de.next){case 0:if(ee=ae[ae.length-1],!(!((oe=ee.children)!==null&&oe!==void 0&&oe.length)&&!ee.isLeaf&&ee.loadChildren)){de.next=5;break}return de.next=4,ee.loadChildren(ee);case 4:z(function(me){return p()(me)});case 5:case"end":return de.stop()}},X)})),ne.apply(this,arguments)}return k((0,g.jsx)(P.R,{className:(0,B.cx)("x-button",H,$,c),children:(0,g.jsx)(h.Z,{placeholder:i("Select a variable"),value:[],options:F,fieldNames:D,loadData:G,onChange:function(){var ae,oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];if(n(oe),!!oe.length){var W=ee[ee.length-1];(!(W!=null&&(ae=W.children)!==null&&ae!==void 0&&ae.length)&&!(W!=null&&W.loadChildren)||W!=null&&W.isLeaf)&&y(oe)}},changeOnSelect:C,onClick:function(ae){if(!(ae.detail!==2||!C))for(var oe=ae.target;oe&&oe!==ae.currentTarget;oe=oe.parentNode){var ee;Array.from((ee=oe.classList)!==null&&ee!==void 0?ee:[]).includes("ant-cascader-menu-item")&&y(O)}},popupClassName:"Cascader-popupClassName",dropdownRender:C?function(X){return(0,g.jsxs)(g.Fragment,{children:[X,(0,g.jsx)("div",{style:{padding:"0.5em",borderTop:"1px solid ".concat(w.colorBorder),color:w.colorTextDescription},children:i("Double click to choose entire object")})]})}:null})}))}},2876:function(ze,re,e){"use strict";e.d(re,{R:function(){return x}});var L=e(97857),l=e.n(L),K=e(15867),p=e(67294),A=e(85893),x=(0,p.forwardRef)(function(N,r){var B=(0,p.useMemo)(function(){return{fontStyle:"italic",fontFamily:"New York, Times New Roman, Times, serif"}},[]);return(0,A.jsxs)(K.ZP,l()(l()({"aria-label":"variable-button",ref:r,style:B},N),{},{children:["x",N.children]}))});x.displayName="XButton"},72724:function(ze,re,e){"use strict";e.d(re,{L:function(){return T}});var L=e(97857),l=e.n(L),K=e(5574),p=e.n(K),A=e(94697),x=e(94350),N=e(67294),r=e(26793),B=e(21143),h=e(84577),I=e(85893),b=function(o){var d=(0,h.ng)(),R=d.refresh,P=(0,B.useAPIClient)(),g=(0,r.$)(),u=g.t;return(0,N.useCallback)(function(j){var F,z,y,E,C,a,D,c,v=j.active,i=j.over,m=v==null||(F=v.data)===null||F===void 0||(F=F.current)===null||F===void 0?void 0:F.schema,f=i==null||(z=i.data)===null||z===void 0||(z=z.current)===null||z===void 0?void 0:z.schema,O=i==null||(y=i.data)===null||y===void 0||(y=y.current)===null||y===void 0?void 0:y.insertAdjacent,n=i==null||(E=i.data)===null||E===void 0||(E=E.current)===null||E===void 0?void 0:E.breakRemoveOn,U=i==null||(C=i.data)===null||C===void 0||(C=C.current)===null||C===void 0?void 0:C.wrapSchema,k=i==null||(a=i.data)===null||a===void 0||(a=a.current)===null||a===void 0?void 0:a.onSuccess,H=(D=i==null||(c=i.data)===null||c===void 0||(c=c.current)===null||c===void 0?void 0:c.removeParentsIfNoChildren)!==null&&D!==void 0?D:!0;if(!m||!f){o==null||o(j);return}if(m===f){o==null||o(j);return}if(m.parent===f&&O==="beforeEnd"){o==null||o(j);return}var $=(0,h.Pl)({t:u,api:P,refresh:R,current:f});if($.loadAPIClientEvents(),m.parent===f.parent){$.insertBeforeBeginOrAfterEnd(m),o==null||o(j);return}if(O){$.insertAdjacent(O,m,{wrap:U,breakRemoveOn:n,removeParentsIfNoChildren:H,onSuccess:k}),o==null||o(j);return}},[o])},T=(0,x.observer)(function(t){var o=(0,r.$)(),d=o.t,R=(0,N.useState)(!0),P=p()(R,2),g=P[0],u=P[1],j=(0,N.useCallback)(function(z){var y,E=z.active,C=E==null||(y=E.data)===null||y===void 0||(y=y.current)===null||y===void 0?void 0:y.schema;if(u(!!C),t!=null&&t.onDragStart){var a;t==null||(a=t.onDragStart)===null||a===void 0||a.call(t,z)}},[t==null?void 0:t.onDragStart]),F=b(t==null?void 0:t.onDragEnd);return(0,I.jsxs)(A.DndContext,l()(l()({collisionDetection:A.rectIntersection},t),{},{onDragStart:j,onDragEnd:F,children:[(0,I.jsx)(A.DragOverlay,{dropAnimation:{duration:10,easing:"cubic-bezier(0.18, 0.67, 0.6, 1.22)"},children:g&&(0,I.jsx)("span",{style:{whiteSpace:"nowrap"},children:d("Dragging")})}),t.children]}))},{displayName:"DndContext"})},14896:function(ze,re,e){"use strict";e.r(re),e.d(re,{DndContext:function(){return L.L},DragHandler:function(){return l.IW},DraggableContext:function(){return l.LC},ShowFormData:function(){return x},Sortable:function(){return l.bt},SortableContext:function(){return l.Fo},SortableItem:function(){return l.TR},SortableProvider:function(){return l.OR}});var L=e(72724),l=e(20493),K=e(67294),p=e(94350),A=e(85893),x=(0,p.observer)(function(N){var r=N.children,B=(0,p.useForm)();return(0,A.jsxs)(A.Fragment,{children:[(0,A.jsx)("pre",{style:{marginBottom:20},"data-testid":"form-data",children:JSON.stringify(B.values,null,2)}),r]})})},20493:function(ze,re,e){"use strict";e.d(re,{IW:function(){return j},LC:function(){return t},bt:function(){return R},Fo:function(){return o},TR:function(){return u},OR:function(){return d}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(10274),x=e(94697),N=e(97133),r=e(94350),B=e(67294),h=e(60094),I=e(85893),b=["component","overStyle","style","children","openMode"],T=["schema","id","eid","removeParentsIfNoChildren"],t=(0,B.createContext)(null);t.displayName="DraggableContext";var o=(0,B.createContext)(null);o.displayName="SortableContext";var d=function(z){var y=z.id,E=z.data,C=z.children,a=(0,x.useDraggable)({id:y,data:E}),D=(0,x.useDroppable)({id:y,data:E});return(0,I.jsx)(o.Provider,{value:{draggable:a,droppable:D},children:C})},R=function(z){var y,E,C=z.component,a=z.overStyle,D=z.style,c=z.children,v=z.openMode,i=p()(z,b),m=(0,h.dQ)(),f=m.token,O=(0,B.useContext)(o),n=O.draggable,U=O.droppable,k=U.isOver,H=U.setNodeRef,$=l()({},D);return k&&(n==null||(y=n.active)===null||y===void 0?void 0:y.id)!==(U==null||(E=U.over)===null||E===void 0?void 0:E.id)&&($[C==="a"?"color":"background"]=new A.C(f.colorSettings).setAlpha(.15).toHex8String(),Object.assign($,a)),B.createElement(C||"div",l()(l()({role:"none"},i),{},{className:(0,N.cx)("nb-sortable-designer",z.className),ref:H,style:$}),c)},P=function(z){var y=g(z),E=(0,r.useFieldSchema)();return z.schema?l()(l()({},z),{},{id:y}):l()(l()({},z),{},{id:y,schema:E})},g=function(z){var y=(0,r.useField)();return z.id?z.id:y.address.toString()},u=(0,r.observer)(function(F){var z=P(F),y=z.schema,E=z.id,C=z.eid,a=z.removeParentsIfNoChildren,D=p()(z,T),c=(0,B.useMemo)(function(){return{insertAdjacent:"afterEnd",schema:y,removeParentsIfNoChildren:a!=null?a:!0}},[y,a]);return(0,I.jsx)(d,{id:E,data:c,children:(0,I.jsx)(R,l()(l()({id:C},D),{},{children:F.children}))})},{displayName:"SortableItem"}),j=function(z){var y=(0,B.useContext)(o),E=y.draggable,C=E.attributes,a=E.listeners,D=E.setNodeRef;return(0,I.jsx)("div",{style:{display:"inline-block",width:14,height:14,lineHeight:"14px",textAlign:"left"},children:(0,I.jsx)("div",l()(l()(l()({ref:D,style:{position:"relative",zIndex:1,lineHeight:0,fontSize:0,display:"inline-block"}},a),C),{},{role:"none",children:(0,I.jsx)("span",{style:{cursor:"move",fontSize:14},children:z.children})}))})}},34588:function(ze,re,e){"use strict";e.d(re,{jC:function(){return F},od:function(){return g},Rq:function(){return u},e7:function(){return P}});var L=e(15009),l=e.n(L),K=e(9783),p=e.n(K),A=e(5574),x=e.n(A),N=e(99289),r=e.n(N),B=e(52677),h=e.n(B),I=e(96486),b=e.n(I),T=e(76690),t=e(65565),o=e(27484),d=e.n(o);function R(){"use strict";Array.isArray||(Array.isArray=function(D){return Object.prototype.toString.call(D)==="[object Array]"});function y(D){for(var c=[],v=0,i=D.length;v<i;v++)c.indexOf(D[v])===-1&&c.push(D[v]);return c}function E(D,c){return JSON.stringify(D)===JSON.stringify(c)}var C={},a={$is:function(c,v){return c===v},$match:function(c,v){return Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return(i==null?void 0:i.length)===v.length&&(i==null?void 0:i.every(function(m,f){return m===v[f]}))}):JSON.stringify(c)===JSON.stringify(v)},$eq:function(c,v){return Array.isArray(c)&&Array.isArray(v)?E(c,v):Array.isArray(c)?c.includes(v):c===v},$ne:function(c,v){return c!=v},"!==":function(c,v){return c!==v},$gt:function(c,v){return Array.isArray(c)?c.some(function(i){return i>v}):c>v},$gte:function(c,v){return c>=v},$lt:function(c,v,i){return Array.isArray(c)?c.some(function(m){return m<v}):i===void 0?c<v:c<v&&v<i},$lte:function(c,v,i){return i===void 0?c<=v:c<=v&&v<=i},$exists:function(c){return C.truthy(c)},$notEmpty:function(c){return C.truthy(c)},$empty:function(c){return Array.isArray(c)?c.some(function(v){return!C.truthy(v)}):!C.truthy(c)},$notExists:function(c){return!C.truthy(c)},"%":function(c,v){return c%v},log:function(c){return console.log(c),c},$in:function(c,v){return!v||typeof v.indexOf=="undefined"?!1:Array.isArray(c)&&Array.isArray(v)?v.some(function(i){return c.includes(i)}):v.indexOf(c)!==-1},$notIn:function(c,v){return!v||typeof v.indexOf=="undefined"?!1:v.indexOf(c)===-1},$includes:function(c,v){return!c||typeof c.indexOf=="undefined"?!1:Array.isArray(c)?c.some(function(i){return i==null?void 0:i.includes(v)}):c.indexOf(v)!==-1},$notIncludes:function(c,v){return!c||typeof c.indexOf=="undefined"?!1:Array.isArray(c)?!c.some(function(i){return i.includes(v)}):c.indexOf(v)===-1},$anyOf:function(c,v){return c.length===0?!1:Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return i.some(function(m){return v.includes(m)})}):c.some(function(i){return v.includes(i)})},$noneOf:function(c,v){return!c||(c==null?void 0:c.length)===0?!0:Array.isArray(c)&&Array.isArray(v)&&c.some(function(i){return Array.isArray(i)})?c.some(function(i){return i.every(function(m){return!v.some(function(f){return m.includes(f)})})}):v.some(function(i){return!c.includes(i)})},$notMatch:function(c,v){if(c.length!==v.length)return!0;for(var i=0;i<c.length;i++)if(c[i]!==v[i])return!0;return!1},$dateOn:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isBetween(v[0],v[1],null,"[]")&&c[1].isBetween(v[0],v[1],null,"[]"))},$dateBefore:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isBefore(v[0])&&c[1].isBefore(v[0]))},$dateNotBefore:function(c,v){return!a.$dateBefore(c,v)},$dateAfter:function(c,v){return!c||!v?!1:(Array.isArray(c)||(c=[c,c]),Array.isArray(v)||(v=[v,v]),c=c.map(function(i){return d()(i)}),v=v.map(function(i){return d()(i)}),c[0].isAfter(v[1])&&c[1].isAfter(v[1]))},$dateNotAfter:function(c,v){return!a.$dateAfter(c,v)},$dateBetween:function(c,v){return a.$dateOn(c,v)},$dateNotOn:function(c,v){return!a.$dateOn(c,v)},$isTruly:function(c){return Array.isArray(c)?c.some(function(v){return v===!0||v===1}):c===!0||c===1},$isFalsy:function(c){return Array.isArray(c)?c.some(function(v){return!C.truthy(v)}):!C.truthy(c)},cat:function(){return Array.prototype.join.call(arguments,"")},substr:function(c,v,i){if(i<0){var m=String(c).substr(v);return m.substr(0,m.length+i)}return String(c).substr(v,i)},"+":function(){return Array.prototype.reduce.call(arguments,function(c,v){return parseFloat(c,10)+parseFloat(v,10)},0)},"*":function(){return Array.prototype.reduce.call(arguments,function(c,v){return parseFloat(c,10)*parseFloat(v,10)})},"-":function(c,v){return v===void 0?-c:c-v},"/":function(c,v){return c/v},min:function(){return Math.min.apply(this,arguments)},max:function(){return Math.max.apply(this,arguments)},merge:function(){return Array.prototype.reduce.call(arguments,function(c,v){return c.concat(v)},[])},var:function(c,v){var i=v===void 0?null:v,m=this;if(typeof c=="undefined"||c===""||c===null)return m;for(var f=String(c).split("."),O=0;O<f.length;O++)if(m==null||(m=m[f[O]],m===void 0))return i;return m},missing:function(){for(var c=[],v=Array.isArray(arguments[0])?arguments[0]:arguments,i=0;i<v.length;i++){var m=v[i],f=C.apply({var:m},this);(f===null||f==="")&&c.push(m)}return c},missing_some:function(c,v){var i=C.apply({missing:v},this);return v.length-i.length>=c?[]:i}};return C.is_logic=function(D){return h()(D)==="object"&&D!==null&&!Array.isArray(D)&&Object.keys(D).length===1},C.truthy=function(D){return Array.isArray(D)&&D.length===0?!1:!!D},C.get_operator=function(D){return Object.keys(D)[0]},C.get_values=function(D){return D[C.get_operator(D)]},C.apply=function(D,c){if(Array.isArray(D))return D.map(function($){return C.apply($,c)});if(!C.is_logic(D))return D;var v=C.get_operator(D),i=D[v],m,f,O,n,U;if(Array.isArray(i)||(i=[i]),v==="if"||v=="?:"){for(m=0;m<i.length-1;m+=2)if(C.truthy(C.apply(i[m],c)))return C.apply(i[m+1],c);return i.length===m+1?C.apply(i[m],c):null}else if(v==="$and"){for(m=0;m<i.length;m+=1)if(f=C.apply(i[m],c),!C.truthy(f))return f;return f}else if(v==="or"){for(m=0;m<i.length;m+=1)if(f=C.apply(i[m],c),C.truthy(f))return f;return f}else{if(v==="filter")return n=C.apply(i[0],c),O=i[1],Array.isArray(n)?n.filter(function($){return C.truthy(C.apply(O,$))}):[];if(v==="map")return n=C.apply(i[0],c),O=i[1],Array.isArray(n)?n.map(function($){return C.apply(O,$)}):[];if(v==="reduce")return n=C.apply(i[0],c),O=i[1],U=typeof i[2]!="undefined"?i[2]:null,Array.isArray(n)?n.reduce(function($,V){return C.apply(O,{current:V,accumulator:$})},U):U;if(v==="all"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!1;for(m=0;m<n.length;m+=1)if(!C.truthy(C.apply(O,n[m])))return!1;return!0}else if(v==="none"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!0;for(m=0;m<n.length;m+=1)if(C.truthy(C.apply(O,n[m])))return!1;return!0}else if(v==="some"){if(n=C.apply(i[0],c),O=i[1],!Array.isArray(n)||!n.length)return!1;for(m=0;m<n.length;m+=1)if(C.truthy(C.apply(O,n[m])))return!0;return!1}}if(i=i.map(function($){return C.apply($,c)}),a.hasOwnProperty(v)&&typeof a[v]=="function")return a[v].apply(c,i);if(v.indexOf(".")>0){var k=String(v).split("."),H=a;for(m=0;m<k.length;m++){if(!H.hasOwnProperty(k[m]))throw new Error("Unrecognized operation "+v+" (failed at "+k.slice(0,m+1).join(".")+")");H=H[k[m]]}return H.apply(c,i)}throw new Error("Unrecognized operation "+v)},C.uses_data=function(D){var c=[];if(C.is_logic(D)){var v=C.get_operator(D),i=D[v];Array.isArray(i)||(i=[i]),v==="var"?c.push(i[0]):i.forEach(function(m){c.push.apply(c,C.uses_data(m))})}return y(c)},C.add_operation=function(D,c){a[D]=c},C.rm_operation=function(D){delete a[D]},C.rule_like=function(D,c){if(c===D||c==="@")return!0;if(c==="number")return typeof D=="number";if(c==="string")return typeof D=="string";if(c==="array")return Array.isArray(D)&&!C.is_logic(D);if(C.is_logic(c)){if(C.is_logic(D)){var v=C.get_operator(c),i=C.get_operator(D);if(v==="@"||v===i)return C.rule_like(C.get_values(D,!1),C.get_values(c,!1))}return!1}if(Array.isArray(c))if(Array.isArray(D)){if(c.length!==D.length)return!1;for(var m=0;m<c.length;m+=1)if(!C.rule_like(D[m],c[m]))return!1;return!0}else return!1;return!1},C}var P=function(E,C){var a,D=/{{(.*?)}}/,c=E==null||(a=E.match)===null||a===void 0?void 0:a.call(E,D);if(c){var v=b().get(C,c[1]);return b().isFunction(v)?v():v}else return E};function g(y){if(h()(y)!=="object"||y===null)return null;for(var E in y)if(Object.prototype.hasOwnProperty.call(y,E))return Object.prototype.toString.call(y[E])==="[object Object]"&&y[E]!==null?g(y[E]):{key:E,value:y[E]};return null}var u=function(E){var C=j(E),a=(0,I.findIndex)(C,function(c,v,i){if(c.includes("$")&&v>0)return!0}),D=C.slice(0,a);return D};function j(y){var E=[];function C(a){Object.keys(a).sort().forEach(function(D){E.push(D),a[D]&&h()(a[D])==="object"&&C(a[D])})}return C(y),E}var F=function(){var y=r()(l()().mark(function E(C){var a,D,c,v,i,m;return l()().wrap(function(O){for(;;)switch(O.prev=O.next){case 0:return a=C.ruleGroup,D=C.variables,c=C.localVariables,v=Object.keys(a)[0]||"$and",i=a[v],m=i.map(function(){var n=r()(l()().mark(function U(k){var H,$,V,w,G,ne,X,ae,oe,ee,W;return l()().wrap(function(me){for(;;)switch(me.prev=me.next){case 0:if(!("$and"in k||"$or"in k)){me.next=4;break}return me.next=3,F({ruleGroup:k,variables:D,localVariables:c});case 3:return me.abrupt("return",me.sent);case 4:if(H=g(k),$=H==null?void 0:H.key,$){me.next=8;break}return me.abrupt("return",!0);case 8:return V=z(u(k)),w=D.parseVariable(V,c),G=(0,T.cG)(H==null?void 0:H.value)?[D.parseVariable(H==null?void 0:H.value,c),w]:[H==null?void 0:H.value,w],me.prev=11,ne=R(),me.next=15,Promise.all(G);case 15:return X=me.sent,ae=x()(X,2),oe=ae[0],ee=ae[1],me.next=21,D.getCollectionField(V,c);case 21:return W=me.sent,me.abrupt("return",ne.apply(p()({},$,[(0,t.J)(ee,{targetCollectionField:W}),(0,t.J)(oe,{targetCollectionField:W})])));case 25:throw me.prev=25,me.t0=me.catch(11),me.t0;case 28:case"end":return me.stop()}},U,null,[[11,25]])}));return function(U){return n.apply(this,arguments)}}()),O.next=6,Promise.all(m);case 6:if(m=O.sent,v!=="$and"){O.next=11;break}return O.abrupt("return",(0,I.every)(m,function(n){return n}));case 11:return O.abrupt("return",(0,I.some)(m,function(n){return n}));case 12:case"end":return O.stop()}},E)}));return function(C){return y.apply(this,arguments)}}();function z(y){return"{{ $nForm.".concat(y.join(".")," }}")}},61736:function(ze,re,e){"use strict";e.d(re,{D:function(){return l}});var L=e(67294),l=(0,L.createContext)({});l.displayName="SchemaComponentContext.Provider"},44245:function(ze,re,e){"use strict";e.d(re,{R:function(){return t}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(86201),x=e(94350),N=e(67294),r=e(47844),B=e(85893),h=["children","form"],I=["children"],b=function(d){var R=d.children,P=d.form,g=p()(d,h),u=(0,N.useContext)(x.SchemaOptionsContext),j=(0,N.useContext)(x.SchemaExpressionScopeContext),F=l()(l()({},u==null?void 0:u.scope),j),z=l()({},u==null?void 0:u.components);return(0,B.jsx)(x.FormProvider,l()(l()({},g),{},{form:P,children:(0,B.jsx)(r.G,{components:z,scope:F,children:R})}))},T=function(d){var R=d.children,P=p()(d,I),g=(0,N.useContext)(x.SchemaOptionsContext),u=(0,N.useContext)(x.SchemaExpressionScopeContext),j=l()(l()({},g==null?void 0:g.scope),u),F=l()({},g==null?void 0:g.components),z=(0,N.useMemo)(function(){return(0,A.createForm)()},[]);return(0,B.jsx)(x.FormProvider,l()(l()({},P),{},{form:z,children:(0,B.jsx)(r.G,{components:F,scope:j,children:R})}))},t=function(d){return d.form?(0,B.jsx)(b,l()({},d)):(0,B.jsx)(T,l()({},d))}},59480:function(ze,re,e){"use strict";e.d(re,{m:function(){return T}});var L=e(97857),l=e.n(L),K=e(86201),p=e(57953),A=e(67294),x=e(12174),N=e(84577),r=e(44245),B=e(93323),h=e(85893),I=function(o){return o},b=function(o){var d=o.noForm,R=o.onlyRenderProperties,P=o.hidden,g=o.scope,u=o.uid,j=o.components,F=o.onSuccess,z=o.schemaTransform,y=z===void 0?I:z,E=(0,N.Dm)(),C=E.reset,a={url:"/uiSchemas:".concat(R?"getProperties":"getJsonSchema","/").concat(u)},D=(0,A.useMemo)(function(){return(0,K.createForm)()},[u]),c=(0,x.QT)(a,{refreshDeps:[u],onSuccess:function(f){F&&F(f),C&&C()}}),v=c.data,i=c.loading;return i?(0,h.jsx)(p.Z,{}):P?(0,h.jsx)(p.Z,{}):d?(0,h.jsx)(B.n,{components:j,scope:g,schema:y((v==null?void 0:v.data)||{})}):(0,h.jsx)(r.R,{form:D,children:(0,h.jsx)(B.n,{components:j,scope:g,schema:y((v==null?void 0:v.data)||{})})})},T=function(o){return o.uid?(0,h.jsx)(b,l()({},o)):null}},93323:function(ze,re,e){"use strict";e.d(re,{n:function(){return u}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=e(9783),x=e.n(A),N=e(94350),r=e(90105),B=e(67294),h=e(61736),I=e(47844),b=e(85893),T=["components","scope","schema","distributed"],t=["schema"],o=["memoized"];function d(j){return N.Schema.isSchemaInstance(j)?j:j!=null&&j.name?new N.Schema({type:"object",properties:x()({},j.name,j)}):new N.Schema(j)}var R=function(F){return(0,B.useMemo)(function(){return d(F)},[])},P=function(F){var z=F.components,y=F.scope,E=F.schema,C=F.distributed,a=p()(F,T),D=(0,B.useContext)(h.D),c=(0,B.useMemo)(function(){return d(E)},[E]),v=(0,r.Z)();return(0,b.jsx)(h.D.Provider,{value:l()(l()({},D),{},{distributed:D.distributed==!1?!1:C,refresh:function(){var m;if(v(),D.distributed===!1||C===!1){var f;(f=D.refresh)===null||f===void 0||f.call(D)}(m=F.onChange)===null||m===void 0||m.call(F,c)}}),children:(0,b.jsx)(I.G,{inherit:!0,components:z,scope:y,children:(0,b.jsx)(N.RecursionField,l()(l()({},a),{},{schema:c}))})})},g=function(F){var z=F.schema,y=p()(F,t),E=R(z);return(0,b.jsx)(P,l()(l()({},y),{},{schema:E}))},u=function(F){var z=F.memoized,y=p()(F,o);return z?(0,b.jsx)(g,l()({},y)):(0,b.jsx)(P,l()({},y))}},47844:function(ze,re,e){"use strict";e.d(re,{B:function(){return x},G:function(){return N}});var L=e(97857),l=e.n(L),K=e(94350),p=e(67294),A=e(85893),x=function(){var B=(0,p.useContext)(K.SchemaOptionsContext);return B||{}},N=(0,p.memo)(function(r){var B=r.children,h=x(),I=(0,p.useMemo)(function(){return l()(l()({},h.components),r.components)},[h.components,r.components]),b=(0,p.useMemo)(function(){return l()(l()({},h.scope),r.scope)},[h.scope,r.scope]),T=(0,p.useMemo)(function(){return{scope:b,components:I}},[b,I]);return(0,A.jsx)(K.SchemaOptionsContext.Provider,{value:T,children:(0,A.jsx)(K.SchemaComponentsContext.Provider,{value:I,children:(0,A.jsx)(K.ExpressionScope,{value:b,children:B})})})});N.displayName="SchemaComponentOptions"},70993:function(ze,re,e){"use strict";e.d(re,{_b:function(){return F},RV:function(){return z.R},m1:function(){return y.m},n6:function(){return E.n},G0:function(){return C.G},a$:function(){return w},Tz:function(){return $},Bs:function(){return C.B}});var L=e(15009),l=e.n(L),K=e(99289),p=e.n(K),A=e(12444),x=e.n(A),N=e(72004),r=e.n(N),B=e(31996),h=e.n(B),I=e(26037),b=e.n(I),T=e(51947),t=e(83062),o=e(15867),d=e(67294),R=e(49218),P=e(26793),g=e(56709),u=e(68230),j=e(85893),F=function(){var X=(0,g.ngQ)(),ae=X.designable,oe=X.setDesignable,ee=(0,P.$)(),W=ee.t,de=(0,u.d)(),me=de.token,Q={};return ae&&(Q.backgroundColor="var(--colorSettings)"),(0,R.y1)("Ctrl+Shift+U",function(){return oe(!ae)},[ae]),(0,j.jsx)(t.Z,{title:W("UI Editor"),children:(0,j.jsx)(o.ZP,{"data-testid":"ui-editor-button",icon:(0,j.jsx)(T.Z,{style:{color:me.colorTextHeaderMenu}}),title:W("UI Editor"),style:Q,onClick:function(){oe(!ae)}})})},z=e(44245),y=e(59480),E=e(93323),C=e(47844),a=e(97857),D=e.n(a),c=e(5574),v=e.n(c),i=e(86201),m=e(94350),f=e(73773),O=e(90105),n=e(61736),U=function(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return"".concat(X).concat((0,f.uid)())};m.Schema.silent(!0);var k={},H={silent:!0,compile:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=function(){if(H.silent)try{return new Function("$root","with($root) { return (".concat(X,"); }"))(ae)}catch(W){return"{{".concat(X,"}}")}else return new Function("$root","with($root) { return (".concat(X,"); }"))(ae)};return k[X]?k[X]:X.trim().startsWith("t(")?(k[X]=oe(),k[X]):oe()}};m.Schema.registerCompiler(H.compile);var $=function(X){var ae=X.designable,oe=X.onDesignableChange,ee=X.components,W=X.children,de=(0,d.useContext)(n.D),me=(0,C.B)(),Q=(0,O.Z)(),_e=(0,d.useState)((0,f.uid)()),ye=v()(_e,2),Ae=ye[0],Se=ye[1],he=(0,d.useMemo)(function(){return X.form||(0,i.createForm)()},[Ae]),ve=(0,P.$)(),J=ve.t,Y=(0,d.useMemo)(function(){return D()(D()({},X.scope),{},{t:J,randomString:U})},[X.scope,J,me==null?void 0:me.scope]),ue=(0,d.useState)(ae),xe=v()(ue,2),fe=xe[0],Me=xe[1],Ie=(0,d.useMemo)(function(){return typeof ae=="boolean"?ae:fe},[ae,fe,de.designable]),Ue=(0,d.useMemo)(function(){return function(Oe){typeof Ie!="boolean"&&Me(Oe),oe==null||oe(Oe)}},[Ie,oe]),Ne=(0,d.useCallback)(function(){Se((0,f.uid)())},[]);return(0,j.jsx)(n.D.Provider,{value:{scope:Y,components:ee,reset:Ne,refresh:Q,designable:Ie,setDesignable:Ue},children:(0,j.jsx)(m.FormProvider,{form:he,children:(0,j.jsx)(C.G,{inherit:!0,scope:Y,components:ee,children:W})})})};$.displayName="SchemaComponentProvider";var V=e(31601),w=function(ne){h()(ae,ne);var X=b()(ae);function ae(){return x()(this,ae),X.apply(this,arguments)}return r()(ae,[{key:"load",value:function(){var oe=p()(l()().mark(function W(){return l()().wrap(function(me){for(;;)switch(me.prev=me.next){case 0:this.addComponents();case 1:case"end":return me.stop()}},W,this)}));function ee(){return oe.apply(this,arguments)}return ee}()},{key:"addComponents",value:function(){this.app.addComponents({DesignableSwitch:F})}}]),ae}(V.S),G=null},84577:function(ze,re,e){"use strict";e.d(re,{zz:function(){return N.zz},Pl:function(){return N.Pl},oB:function(){return N.oB},lI:function(){return l},hi:function(){return g.hi},eJ:function(){return K.e},Co:function(){return x},aZ:function(){return g.aZ},ng:function(){return N.ng},et:function(){return r.e},cL:function(){return d},fd:function(){return u},Cl:function(){return I},vH:function(){return R},sR:function(){return N.sR},wN:function(){return P.w},Dm:function(){return T},fM:function(){return g.fM}});var L=e(67294),l=function(F){var z=(0,L.useRef)(null);return(0,L.useEffect)(function(){return z.current&&F!==z.current&&z.current.onUnmount(),z.current=F,F.onMount(),function(){F.onUnmount()}},[F]),F},K=e(96365),p=e(94350),A=e(96486),x=function(F,z){var y=(0,L.useContext)(p.SchemaOptionsContext),E=y.components;return F?typeof F!="string"?F:(0,A.get)(E,F)||z:z},N=e(94516),r=e(98146),B=e(97857),h=e.n(B),I=function(F){var z=(0,L.useContext)(p.SchemaOptionsContext),y=(0,L.useContext)(p.SchemaExpressionScopeContext),E=(0,L.useRef)();return E.current=y,F.toFieldProps(h()(h()({},z),{},{get scope(){return h()(h()({},z.scope),E.current)}}))},b=e(61736);function T(){return(0,L.useContext)(b.D)}var t=e(26793),o=e(6145),d=function(){var F,z=(0,o.useCollectionManager_deprecated)(),y=z.getCollectionJoinField,E=z.getCollection,C=(0,p.useFieldSchema)(),a=(0,o.useCollection_deprecated)(),D=a.getField,c=D(C.name)||y(C["x-collection-field"]),v=(0,t.$)(),i=v.t,m=((F=C["x-component-props"])===null||F===void 0?void 0:F.fieldNames)||{},f=m.label,O=(0,L.useMemo)(function(){if(!(!c||!(c!=null&&c.interface))&&["o2o","oho","obo","o2m","linkTo","m2o","m2m"].includes(c.interface)){var n=E(c.target);if((n==null?void 0:n.template)==="file")return[{label:i("Record picker"),value:"CollectionField"},{label:i("Select"),value:"AssociationSelect"}];switch(c.interface){case"o2m":return[{label:i("Record picker"),value:"CollectionField"},{label:i("Subtable"),value:"TableField"},{label:i("Select"),value:"AssociationSelect"}];case"m2o":case"m2m":case"linkTo":return[{label:i("Record picker"),value:"CollectionField"},{label:i("Select"),value:"AssociationSelect"}];default:return[{label:i("Record picker"),value:"CollectionField"},{label:i("Subform"),value:"FormField"},{label:i("Select"),value:"AssociationSelect"}]}}},[i,c==null?void 0:c.interface,f]);return O},R=function(){var F,z=(0,p.useField)(),y=(0,p.useFieldSchema)(),E=(0,o.useCollection_deprecated)(),C=E.getField,a=(0,o.useCollectionManager_deprecated)(),D=a.getCollectionJoinField,c=C(y.name)||D(y["x-collection-field"]),v=(0,K.e)();(0,L.useEffect)(function(){if(!(z!=null&&z.title)){var i;z.title=v(c==null||(i=c.uiSchema)===null||i===void 0?void 0:i.title)}},[c==null||(F=c.uiSchema)===null||F===void 0?void 0:F.title])},P=e(9780),g=e(18686),u=function(F){var z,y=(0,t.$)(),E=y.t,C=(0,o.useCollectionManager_deprecated)(),a=C.getCollectionJoinField,D=C.getCollection,c=(0,p.useFieldSchema)(),v=(F==null?void 0:F.fieldSchema)||c,i=(0,p.useField)(),m=(0,p.useForm)(),f=(v==null?void 0:v["x-read-pretty"])||i.readPretty||m.readPretty,O=F==null?void 0:F.fieldSchema,n=(0,o.useCollection_deprecated)(),U=n.getField,k=(F==null?void 0:F.collectionField)||U(v.name)||a(v["x-collection-field"]),H=((z=v["x-component-props"])===null||z===void 0?void 0:z.fieldNames)||{},$=H.label,V=(0,L.useMemo)(function(){if(!(!k||!(k!=null&&k.interface))&&["o2o","oho","obo","o2m","linkTo","m2o","m2m","updatedBy","createdBy"].includes(k.interface)){var w=D(k.target);if((w==null?void 0:w.template)==="file")return f?[{label:E("Title"),value:"Select"},{label:E("File manager"),value:"FileManager"},{label:E("Tag"),value:"Tag"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},{label:E("File manager"),value:"FileManager"}];if((w==null?void 0:w.template)==="tree"&&["m2m","o2m","m2o"].includes(k.interface))return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"},!O&&{label:E("Sub-table"),value:"SubTable"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&["m2m","o2m"].includes(k.interface)&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Cascade Select"),value:"CascadeSelect"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];switch(k.interface){case"o2m":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"},!O&&{label:E("Sub-table"),value:"SubTable"}];case"m2m":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"},!O&&{label:E("Sub-table"),value:"SubTable"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-table"),value:"SubTable"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];case"m2o":case"linkTo":return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}];default:return f?[{label:E("Title"),value:"Select"},{label:E("Tag"),value:"Tag"},!O&&{label:E("Sub-details"),value:"Nester"}]:[{label:E("Select"),value:"Select"},{label:E("Record picker"),value:"Picker"},!O&&{label:E("Sub-form"),value:"Nester"},{label:E("Sub-form(Popover)"),value:"PopoverNester"}]}}},[E,k==null?void 0:k.interface,$]);return(V||[]).filter(Boolean)}},18686:function(ze,re,e){"use strict";e.d(re,{aZ:function(){return j},fM:function(){return z},hi:function(){return F}});var L=e(5574),l=e.n(L),K=e(97857),p=e.n(K),A=e(94350),x=e(83204),N=e(9361),r=e(96486),B=e.n(r),h=e(67294),I=e(56709),b=e(21143),T=e(28561),t=e(10097),o=function(C,a,D,c){return C?c.paddingContentHorizontalLG:D?a?c.controlPaddingHorizontal+3*c.controlPaddingHorizontalSM+22+c.paddingContentHorizontalLG:c.paddingContentHorizontalLG+12:a?c.paddingSM+c.controlHeight+c.marginXS+2*c.controlPaddingHorizontalSM+22+c.paddingContentHorizontalLG:c.controlHeight+c.marginXS+(c.paddingXXS+2)*2+c.paddingContentHorizontalLG},d=function(C){var a=N.Z.useToken(),D=a.token,c=(0,I.ngQ)(),v=c.designable,i=(0,t.useBlockHeightProps)(),m=i.heightProps,f=C||m||{},O=f.disablePageHeader,n=f.enablePageTabs,U=f.hidePageTitle,k=D.sizeXXL-2,H=v?D.controlHeight+2*D.paddingContentHorizontalLG:1*D.paddingContentHorizontalLG,$=o(O,n,U,D);return k+$+H},R=function(){var C=N.Z.useToken(),a=C.token,D=(0,I.ngQ)(),c=D.designable,v=a.paddingContentVerticalLG+a.margin+2*a.paddingContentVertical+24,i=c?a.controlHeight+2*a.paddingContentHorizontalLG:1*a.paddingContentHorizontalLG;return v+i},P=function(C){var a=(0,A.useFieldSchema)(),D=y(a),c=d(C),v=R();return D?v:c},g=["users_jobs","approvals","approvalRecords"],u=function(){var C,a,D=N.Z.useToken(),c=D.token,v=(0,t.useBlockHeightProps)(),i=v.heightProps,m=(0,b.useTableBlockContext)(),f=m.heightProps,O=(0,I.ngQ)(),n=O.designable,U=(0,A.useFieldSchema)(),k=f||i,H=P(k),$=(C=(0,b.useDataBlockRequest)())!==null&&C!==void 0?C:{},V=$.data,w=(0,b.useCollection)(),G=w.name,ne=(V==null?void 0:V.meta)||{},X=ne.count,ae=ne.pageSize,oe=X>ae,ee=k.heightMode,W=k.height,de=k.title;if(!(!(k!=null&&k.heightMode)||ee===T.j.DEFAULT)){var me=Object.keys(((a=U.parent.properties.actions)===null||a===void 0?void 0:a.properties)||{}).length>0,Q=oe?c.controlHeight+c.padding+c.marginLG:c.marginLG,_e=me||n?c.controlHeight+2*c.marginLG:c.marginLG,ye=(n&&!g.includes(G)?c.controlHeight:22)+2*c.padding+1,Ae=de?c.fontSizeLG*c.lineHeightLG+c.padding*2-1:0;return ee===T.j.FULL_HEIGHT?window.innerHeight-H-Ae-ye-_e-Q:W-Ae-_e-ye-Q}},j=function(C){var a=(0,t.useBlockHeightProps)(),D=a.heightProps,c=P(),v=N.Z.useToken(),i=v.token,m=D||{},f=m.heightMode,O=m.height,n=m.title,U=n?i.fontSizeLG*i.lineHeightLG+i.padding*2-1:0;if(!(!(D!=null&&D.heightMode)||f===T.j.DEFAULT)){if(f===T.j.FULL_HEIGHT){var k=window.innerHeight-c;return C!=null&&C.removeBlockHeaderHeight&&(k=k-U),C!=null&&C.innerExtraHeight&&(k=k-C.innerExtraHeight),k}return O}},F=function(){var C=(0,A.useFieldSchema)(),a=(0,h.useMemo)(function(){return(0,t.getPageSchema)(C)},[]),D=(a==null?void 0:a["x-component-props"])||{},c=D.disablePageHeader,v=D.enablePageTabs,i=D.hidePageTitle,m=p()(p()({},C==null?void 0:C["x-component-props"]),{},{disablePageHeader:c,enablePageTabs:v,hidePageTitle:i}),f=P(m),O=m||{},n=O.heightMode,U=O.height;if(!(!(m!=null&&m.heightMode)||n===T.j.DEFAULT))return n===T.j.FULL_HEIGHT?window.innerHeight-f:U},z=function(){var C=(0,h.useState)(),a=l()(C,2),D=a[0],c=a[1],v=(0,h.useRef)(null),i=u(),m=(0,h.useCallback)((0,r.debounce)(function(){var O;if(v.current){var n=v.current.getBoundingClientRect(),U=(O=v.current.querySelector(".ant-table"))===null||O===void 0?void 0:O.getBoundingClientRect();U&&c(n.width)}},100),[i]),f=(0,h.useCallback)(function(O){v.current=O&&O.children?O.children[0]:null,m()},[m]);return(0,x.Z)("resize",m),{height:i,width:D,tableSizeRefCallback:f}},y=function E(C){return C?C["x-component"]==="Action.Container"?!0:E(C.parent):null}},96365:function(ze,re,e){"use strict";e.d(re,{e:function(){return r}});var L=e(97857),l=e.n(L),K=e(52677),p=e.n(K),A=e(94350),x=e(67294),N={},r=function(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{noCache:!1},I=h.noCache,b=(0,x.useContext)(A.SchemaOptionsContext),T=(0,x.useContext)(A.SchemaExpressionScopeContext);return function(t,o){var d=!1,R;if(typeof t=="string"&&t.startsWith("{{")&&(d=!0,R=t),t&&p()(t)==="object"&&!(0,x.isValidElement)(t)&&(d=!0,R=JSON.stringify(t)),Array.isArray(t)&&(d=!0),d){var P=l()(l()(l()({},b.scope),T),o);if(!R)return A.Schema.compile(t,P);try{return I?A.Schema.compile(t,P):(N[R]=N[R]||A.Schema.compile(t,P),N[R])}catch(g){return console.log("useCompile error",t,g),A.Schema.compile(t,P)}}return t}}},94516:function(ze,re,e){"use strict";e.d(re,{zz:function(){return $},Pl:function(){return f},oB:function(){return k},ng:function(){return w},sR:function(){return V}});var L=e(5574),l=e.n(L),K=e(19632),p=e.n(K),A=e(15009),x=e.n(A),N=e(99289),r=e.n(N),B=e(12444),h=e.n(B),I=e(72004),b=e.n(I),T=e(9783),t=e.n(T),o=e(97857),d=e.n(o),R=e(94350),P=e(73773),g=e(45360),u=e(50361),j=e.n(u),F=e(27361),z=e.n(F),y=e(36968),E=e.n(y),C=e(67294),a=e(26793),D=e(12174),c=e(61736);function v(G,ne){if(G)return G["x-app-version"]||(G["x-app-version"]=ne),Object.keys(G.properties||{}).forEach(function(X){var ae;v((ae=G.properties)===null||ae===void 0?void 0:ae[X],ne)}),G}var i={i8:"1.3.0-alpha"},m=e(85893);function f(G){return new $(G)}var O=function G(ne){ne&&(ne["x-uid"]||(ne["x-uid"]=(0,P.uid)()),Object.keys(ne.properties||{}).forEach(function(X){G(ne.properties[X])}))},n=function(ne){return ne},U=function(ne,X){if(!(!ne||!X)){for(var ae in X)if(Object.prototype.hasOwnProperty.call(X,ae)){var oe=X[ae];if(oe!==(ne==null?void 0:ne[ae]))return!1}return!0}},k=function(ne,X){if(ne["x-uid"]&&ne["x-uid"]===X["x-uid"])return[null,ne.toJSON()];var ae=ne.toJSON(),oe=d()(d()({},ae),{},{properties:{}}),ee=null,W=function de(me,Q){Object.keys(me||{}).forEach(function(_e){var ye=me[_e];if(ye["x-uid"]===X["x-uid"]){ee=me[_e];return}else Q.properties[_e]=d()(d()({},ye),{},{properties:{}}),de(ye==null?void 0:ye.properties,Q.properties[_e])})};return W(ae.properties,oe),[oe,ee]},H=function(ne){return ne},$=function(){function G(ne){h()(this,G),t()(this,"current",void 0),t()(this,"options",void 0),t()(this,"appVersion",void 0),t()(this,"events",{}),this.options=ne,this.current=ne.current,this.appVersion=ne.appVersion}return b()(G,[{key:"model",get:function(){return this.options.model}},{key:"query",get:function(){return this.options.query}},{key:"loadAPIClientEvents",value:function(){var X=this,ae=this.options,oe=ae.api,ee=ae.t,W=ee===void 0?H:ee;if(oe){var de=function(Q){if(!Q)return[];var _e=Object.values(Q.properties).length,ye=[];return Q.mapProperties(function(Ae){Ae["x-component-props"]=Ae["x-component-props"]||{},Ae["x-component-props"].width=100/_e,Ae["x-uid"]&&ye.push({"x-uid":Ae["x-uid"],"x-component-props":Ae["x-component-props"]})}),Q["x-uid"]&&ye.length?ye:[]};this.on("insertAdjacent",function(){var me=r()(x()().mark(function Q(_e){var ye,Ae,Se,he,ve,J,Y,ue,xe,fe;return x()().wrap(function(Ie){for(;;)switch(Ie.prev=Ie.next){case 0:if(Ae=_e.onSuccess,Se=_e.current,he=_e.position,ve=_e.schema,J=_e.wrap,Y=_e.wrapped,ue=_e.removed,xe=[],(Y==null?void 0:Y["x-component"])==="Grid.Col"&&(xe=xe.concat(de(Y.parent))),(ue==null?void 0:ue["x-component"])==="Grid.Col"&&(xe=xe.concat(de(ue.parent))),X.refresh(),Se["x-uid"]){Ie.next=7;break}return Ie.abrupt("return");case 7:return Ie.next=9,oe.request({url:"/uiSchemas:insertAdjacent/".concat(Se["x-uid"],"?position=").concat(he),method:"post",data:{schema:v(ve,X.appVersion),wrap:J}});case 9:if(fe=Ie.sent,!xe.length){Ie.next=13;break}return Ie.next=13,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:xe});case 13:if(!(ue!=null&&ue["x-uid"])){Ie.next=16;break}return Ie.next=16,oe.request({url:"/uiSchemas:remove/".concat(ue["x-uid"]),method:"post"});case 16:Ae==null||Ae(fe==null||(ye=fe.data)===null||ye===void 0?void 0:ye.data),g.ZP.success(W("Saved successfully"),.2);case 18:case"end":return Ie.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("patch",function(){var me=r()(x()().mark(function Q(_e){var ye;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:if(ye=_e.schema,X.refresh(),ye!=null&&ye["x-uid"]){Se.next=4;break}return Se.abrupt("return");case 4:return Se.next=6,oe.request({url:"/uiSchemas:patch",method:"post",data:d()({},ye)});case 6:g.ZP.success(W("Saved successfully"),.2);case 7:case"end":return Se.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("batchPatch",function(){var me=r()(x()().mark(function Q(_e){var ye;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:return ye=_e.schemas,X.refresh(),Se.next=4,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:ye});case 4:g.ZP.success(W("Saved successfully"),.2);case 5:case"end":return Se.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}()),this.on("remove",function(){var me=r()(x()().mark(function Q(_e){var ye,Ae;return x()().wrap(function(he){for(;;)switch(he.prev=he.next){case 0:if(ye=_e.removed,Ae=[],(ye==null?void 0:ye["x-component"])==="Grid.Col"&&(Ae=de(ye.parent)),X.refresh(),ye!=null&&ye["x-uid"]){he.next=6;break}return he.abrupt("return");case 6:return he.next=8,oe.request({url:"/uiSchemas:remove/".concat(ye["x-uid"]),method:"post"});case 8:if(!Ae.length){he.next=11;break}return he.next=11,oe.request({url:"/uiSchemas:batchPatch",method:"post",data:Ae});case 11:g.ZP.success(W("Saved successfully"),.2);case 12:case"end":return he.stop()}},Q)}));return function(Q){return me.apply(this,arguments)}}())}}},{key:"prepareProperty",value:function(X){X.type||(X.type="void"),X.name||(X.name=(0,P.uid)()),this.current["x-uid"]&&O(X)}},{key:"on",value:function(X,ae){this.events[X]||(this.events[X]=[]),this.events[X].push(ae)}},{key:"emit",value:function(){var ne=r()(x()().mark(function ae(oe){var ee=this,W,de,me,Q,_e,ye=arguments;return x()().wrap(function(Se){for(;;)switch(Se.prev=Se.next){case 0:if(this.events[oe]){Se.next=2;break}return Se.abrupt("return");case 2:for(W=ye.length,de=new Array(W>1?W-1:0),me=1;me<W;me++)de[me-1]=ye[me];return Q=de[0],_e=de.slice(1),Se.abrupt("return",Promise.all(this.events[oe].map(function(he){return he.bind(ee).apply(void 0,[d()({current:ee.current},Q)].concat(p()(_e)))})));case 5:case"end":return Se.stop()}},ae,this)}));function X(ae){return ne.apply(this,arguments)}return X}()},{key:"parentsIn",value:function(X){if(!X||!R.Schema.isSchemaInstance(X))return!1;for(var ae=this.current;(oe=ae)!==null&&oe!==void 0&&oe.parent;){var oe;if(ae.parent===X)return!0;ae=ae.parent}return!1}},{key:"refresh",value:function(){var X=this.options.refresh;return X==null?void 0:X()}},{key:"deepMerge",value:function(X){var ae=this,oe={title:"title",description:"description",default:"initialValue",readOnly:"readOnly",writeOnly:"editable",enum:"dataSource","x-pattern":"pattern","x-display":"display","x-validator":"validator","x-decorator":"decorator","x-component":"component","x-reactions":"reactions","x-content":"content","x-visible":"visible","x-hidden":"hidden","x-disabled":"disabled","x-editable":"editable","x-read-only":"readOnly"},ee={"x-decorator-props":"decoratorProps","x-component-props":"componentProps","x-data":"data"};Object.keys(X).forEach(function(W){oe[W]?(ae.current[W]=X[W],ae.updateModel(oe[W],X[W])):ee[W]?Object.keys(X[W]).forEach(function(de){E()(ae.current,[W,de],X[W][de]),ae.updateModel([ee[W],de],X[W][de])}):ae.current[W]=X[W]}),this.emit("patch",{schema:X})}},{key:"getSchemaAttribute",value:function(X,ae){return z()(this.current,X,ae)}},{key:"shallowMerge",value:function(X){var ae=this,oe={title:"title",description:"description",default:"initialValue",readOnly:"readOnly",writeOnly:"editable",enum:"dataSource","x-pattern":"pattern","x-display":"display","x-validator":"validator","x-decorator":"decorator","x-component":"component","x-reactions":"reactions","x-content":"content","x-visible":"visible","x-hidden":"hidden","x-disabled":"disabled","x-editable":"editable","x-read-only":"readOnly","x-decorator-props":"decoratorProps","x-component-props":"componentProps","x-data":"data"};Object.keys(X).forEach(function(ee){ae.current[ee]=X[ee],oe[ee]&&ae.updateModel(oe[ee],X[ee])}),this.emit("patch",{schema:X})}},{key:"updateModel",value:function(X,ae){var oe=function(W){E()(W,X,ae)};this.model&&oe(this.model),this.query&&this.query.take(oe)}},{key:"insertAdjacent",value:function(X,ae){var oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};switch(X){case"beforeBegin":return this.insertBeforeBegin(ae,oe);case"afterBegin":return this.insertAfterBegin(ae,oe);case"beforeEnd":return this.insertBeforeEnd(ae,oe);case"afterEnd":return this.insertAfterEnd(ae,oe)}}},{key:"recursiveRemoveIfNoChildren",value:function(X,ae){if(X){for(var oe=X,ee,W=ae==null?void 0:ae.breakRemoveOn;oe;){if(typeof W=="function"){if(W(oe))break}else if(U(oe,W))break;var de=Object.keys(oe.properties||{}).length;if(de>0)break;oe.parent&&(ee=oe.parent.removeProperty(oe.name)),oe=oe.parent}return ee}}},{key:"remove",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=ae.breakRemoveOn,ee=ae.removeParentsIfNoChildren,W=X||this.current,de=W.parent.removeProperty(W.name);if(ee){var me=this.recursiveRemoveIfNoChildren(W.parent,{breakRemoveOn:oe});me&&(de=me)}return this.emit("remove",{removed:de})}},{key:"removeWithoutEmit",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},oe=ae.breakRemoveOn,ee=ae.removeParentsIfNoChildren,W=X||this.current,de=W.parent.removeProperty(W.name);if(ee){var me=this.recursiveRemoveIfNoChildren(W.parent,{breakRemoveOn:oe});me&&(de=me)}return de}},{key:"insertBeforeBeginOrAfterEnd",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)&&R.Schema.isSchemaInstance(X)&&this.current.parent===X.parent){var ee=0,W=0;return this.current.parent.mapProperties(function(de,me,Q){ae.current.name===me&&(W=Q),X.name===me&&(ee=Q)}),ee>W?this.insertBeforeBegin(X,oe):this.insertAfterEnd(X,oe)}}},{key:"insertBeforeBegin",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var ee={onSuccess:oe.onSuccess},W=oe.wrap,de=W===void 0?n:W,me=oe.breakRemoveOn,Q=oe.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),Q&&(ee.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:me}))}else X&&(X=j()(X));var _e={},ye=!1,Ae=0,Se=0;this.current.parent.mapProperties(function(fe,Me){Me===ae.current.name&&(Se=Ae,ye=!0,++Ae),fe["x-index"]=Ae,++Ae,ye&&(_e[Me]=fe,ae.current.parent.removeProperty(Me))}),this.prepareProperty(X);var he=de(X),ve=this.current.parent.addProperty(he.name||(0,P.uid)(),he);ve["x-index"]=Se,ve.parent=this.current.parent,this.current.parent.setProperties(_e);var J=k(ve,X),Y=l()(J,2),ue=Y[0],xe=Y[1];this.emit("insertAdjacent",d()({position:"beforeBegin",schema:xe,wrapped:he,wrap:ue},ee))}}},{key:"insertAfterBegin",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var oe={onSuccess:ae.onSuccess},ee=ae.wrap,W=ee===void 0?n:ee,de=ae.breakRemoveOn,me=ae.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),me&&(oe.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:de}))}else X&&(X=j()(X));var Q={},_e=1;this.current.mapProperties(function(Y,ue){Y["x-index"]=_e,++_e,Q[ue]=Y}),this.current.properties={},this.prepareProperty(X);var ye=W(X),Ae=this.current.addProperty(ye.name||(0,P.uid)(),ye);Ae["x-index"]=0,Ae.parent=this.current,this.current.setProperties(Q);var Se=k(Ae,X),he=l()(Se,2),ve=he[0],J=he[1];this.emit("insertAdjacent",d()({position:"afterBegin",schema:J,wrap:ve,wrapped:ye},oe))}}},{key:"insertBeforeEnd",value:function(X){var ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){delete X["x-index"];var oe={onSuccess:ae.onSuccess},ee=ae.wrap,W=ee===void 0?n:ee,de=ae.breakRemoveOn,me=ae.removeParentsIfNoChildren;if(R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),me&&(oe.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:de}))}else X&&(X=j()(X));this.prepareProperty(X);var Q=W(X),_e=this.current.addProperty(Q.name||(0,P.uid)(),Q);_e.parent=this.current;var ye=k(_e,X),Ae=l()(ye,2),Se=Ae[0],he=Ae[1];return this.emit("insertAdjacent",d()({position:"beforeEnd",schema:he,wrap:Se,wrapped:Q},oe))}}},{key:"insertAfterEnd",value:function(X){var ae=this,oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(R.Schema.isSchemaInstance(this.current)){var ee={onSuccess:oe==null?void 0:oe.onSuccess},W=oe.wrap,de=W===void 0?n:W,me=oe.breakRemoveOn,Q=oe.removeParentsIfNoChildren,_e=0,ye=0,Ae=!1,Se={};if(this.current.parent.mapProperties(function(fe,Me){fe["x-index"]=_e,Me===ae.current.name&&(++_e,ye=_e,Ae=!0),++_e,Ae&&Me!==ae.current.name&&(Se[Me]=fe,ae.current.parent.removeProperty(Me))}),R.Schema.isSchemaInstance(X)){if(this.parentsIn(X)){this.emit("error",{code:"parent_is_not_allowed",schema:X});return}X.parent.removeProperty(X.name),Q&&(ee.removed=this.recursiveRemoveIfNoChildren(X.parent,{breakRemoveOn:me})),X.parent=null}else X&&(X=j()(X));this.prepareProperty(X);var he=de(X),ve=this.current.parent.addProperty(he.name||(0,P.uid)(),he);ve.parent=this.current.parent,ve["x-index"]=ye,this.current.parent.setProperties(Se);var J=k(ve,X),Y=l()(J,2),ue=Y[0],xe=Y[1];this.emit("insertAdjacent",d()({position:"afterEnd",schema:xe,wrap:ue,wrapped:he},ee))}}}]),G}();function V(){var G=(0,C.useContext)(R.SchemaOptionsContext),ne=(0,C.useMemo)(function(){return(G==null?void 0:G.components)||{}},[G]),X=function(oe){if(!oe)return null;if(typeof oe!="string")return oe;var ee=z()(ne,oe);return ee||console.error('[nocobase]: Component "'.concat(oe,'" not found')),ee};return X}function w(){var G=(0,C.useContext)(c.D),ne=G.designable,X=G.setDesignable,ae=G.refresh,oe=G.reset,ee=(0,C.useContext)(R.SchemaOptionsContext),W=(0,C.useMemo)(function(){return(ee==null?void 0:ee.components)||{}},[ee]),de=(0,C.useMemo)(function(){return function(){return(0,m.jsx)(m.Fragment,{})}},[]),me=(0,R.useField)(),Q=(0,R.useFieldSchema)(),_e=(0,D.LY)(),ye=(0,a.$)(),Ae=ye.t,Se=(0,C.useMemo)(function(){return f({t:Ae,api:_e,refresh:ae,current:Q,model:me,appVersion:i.i8})},[Ae,_e,ae,Q,me]);return(0,C.useEffect)(function(){Se.loadAPIClientEvents()},[Se]),{dn:Se,designable:ne,reset:oe,refresh:ae,setDesignable:X,DesignableBar:de,findComponent:(0,C.useCallback)(function(he){return he?typeof he!="string"?he:z()(W,he):null},[z()]),on:Se.on.bind(Se),patch:(0,C.useCallback)(function(he,ve){var J=function(xe){Object.keys(xe).forEach(function(fe){var Me=xe[fe];fe==="title"&&(me.title=Me,Q.title=Me),fe==="x-decorator-props"&&(me.decoratorProps||(me.decoratorProps={}),Q["x-decorator-props"]||(Q["x-decorator-props"]={}),Object.keys(Me).forEach(function(Ie){me.decoratorProps[Ie]=Me[Ie],Q["x-decorator-props"][Ie]=Me[Ie]})),fe==="x-component-props"&&(me.componentProps||(me.componentProps={}),Q["x-component-props"]||(Q["x-component-props"]={}),Object.keys(Me).forEach(function(Ie){me.componentProps[Ie]=Me[Ie],Q["x-component-props"][Ie]=Me[Ie]}))})};if(typeof he=="string"){var Y={};return E()(Y,he,ve),J(Y)}J(he),ae()},[Se]),shallowMerge:(0,C.useCallback)(function(he){Se.shallowMerge(he)},[Se]),deepMerge:(0,C.useCallback)(function(he){Se.deepMerge(he)},[Se]),remove:(0,C.useCallback)(function(he,ve){Se.remove(he,ve)},[Se]),insertAdjacent:(0,C.useCallback)(function(he,ve,J){Se.insertAdjacent(he,ve,J)},[Se]),insertBeforeBegin:(0,C.useCallback)(function(he){Se.insertBeforeBegin(he)},[Se]),insertAfterBegin:(0,C.useCallback)(function(he){Se.insertAfterBegin(he)},[Se]),insertBeforeEnd:(0,C.useCallback)(function(he){Se.insertBeforeEnd(he)},[Se]),insertAfterEnd:(0,C.useCallback)(function(he){Se.insertAfterEnd(he)},[Se])}}},98146:function(ze,re,e){"use strict";e.d(re,{e:function(){return x}});var L=e(94350),l=e(84577),K=e(67294),p=e(74538),A=function(){return null},x=function(){var r=(0,l.ng)(),B=r.designable,h=(0,L.useFieldSchema)(),I=(0,K.useMemo)(function(){return h["x-designer"]||h["x-toolbar"]?h["x-designer"]||h["x-toolbar"]:h["x-settings"]?p.Mf:A},[h]),b=(0,l.Co)(I);return B&&b||A}},9780:function(ze,re,e){"use strict";e.d(re,{w:function(){return N}});var L=e(97857),l=e.n(L),K=e(13769),p=e.n(K),A=["useProps"],x=function(){return{}},N=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},h=B.useProps,I=h===void 0?x:h,b=p()(B,A),T=I;typeof I!="function"&&(T=x);var t=T();return l()(l()({},b),t)}},56709:function(ze,re,e){"use strict";e.d(re,{aUM:function(){return F.aU},olz:function(){return F.ol},N0i:function(){return F.N0},fWn:function(){return F.fW},EIK:function(){return F.EI},$Lt:function(){return F.$L},$b8:function(){return F.$b},HTy:function(){return Ro},lkv:function(){return Fo},rDu:function(){return la},eYL:function(){return F.eY},Rat:function(){return oa},$SD:function(){return pi},fUi:function(){return Yo.fU},QcG:function(){return Tl},gOu:function(){return os},jYG:function(){return $a.j},C1I:function(){return F.C1},Ssf:function(){return Rl},vTp:function(){return Ul},XZJ:function(){return da},Tt2:function(){return Vl},zH8:function(){return Hl},Q5L:function(){return Jl},Pok:function(){return fi},Vm0:function(){return ql},xI_:function(){return kl},Lip:function(){return zl},Mtg:function(){return ma.Mt},iNu:function(){return ma.iN},zzt:function(){return Ct.zz},_bl:function(){return g._b},POi:function(){return es},AOY:function(){return Q},LBT:function(){return P.DndContext},IWB:function(){return P.DragHandler},LCt:function(){return P.DraggableContext},FyH:function(){return W.Fy},Nir:function(){return W.Ni},q8U:function(){return W.q8},HGA:function(){return W.HG},QTe:function(){return W.QT},JEX:function(){return W.JE},fAH:function(){return ol},$w$:function(){return W.$w},nBj:function(){return W.nB},Oct:function(){return W.Oc},zdw:function(){return W.zd},CXR:function(){return nl},BQs:function(){return Ao.BQ},Hj5:function(){return ct.H},M0b:function(){return hi},wn$:function(){return Or.wn},GzZ:function(){return Or.Gz},tJZ:function(){return Or.tJ},fox:function(){return Or.fo},VTd:function(){return Or.VT},XsZ:function(){return Or.Xs},AsW:function(){return tr},cLM:function(){return Lo},m__:function(){return Qn},l09:function(){return ae},D_t:function(){return zi.D},WiK:function(){return Ut},xJW:function(){return W.xJ},RVL:function(){return g.RV},Bc8:function(){return hr},hG9:function(){return _i},DCh:function(){return gi},rjZ:function(){return va.rj},Cqo:function(){return Va},jg7:function(){return va.jg},gsn:function(){return Ao.gs},$18:function(){return vs},IIB:function(){return Ao.II},RnZ:function(){return Gi},mX2:function(){return Ao.mX},zDC:function(){return bo.zD},Phs:function(){return Ao.Ph},aVo:function(){return za},UGj:function(){return Ji},yq5:function(){return Yi},v2r:function(){return Ca},HIW:function(){return cu},T3C:function(){return Hr},tlE:function(){return Ts},rop:function(){return Rs},gGi:function(){return Bs},MBS:function(){return Ls.M},pGO:function(){return Ks},Y8K:function(){return yi},iVT:function(){return Ao.iV},ODP:function(){return bo.OD},lbb:function(){return bo.lb},b7w:function(){return bo.b7},sUk:function(){return bo.sU},x1j:function(){return F.x1},m1v:function(){return g.m1},glM:function(){return Ye},xZD:function(){return F.xZ},IuH:function(){return Or.Iu},MkN:function(){return F.Mk},Hof:function(){return Ns},n6:function(){return g.n6},DDd:function(){return Vm.D},G0E:function(){return g.G0},a$w:function(){return g.a$},TzZ:function(){return g.Tz},y00:function(){return F.y0},PhF:function(){return It},Cqv:function(){return P.ShowFormData},cof:function(){return F.co},bts:function(){return P.Sortable},Fop:function(){return P.SortableContext},TRI:function(){return P.SortableItem},ORg:function(){return P.SortableProvider},TaI:function(){return $s},qHe:function(){return mr.q},iA_:function(){return Jo},gvM:function(){return Xs},SnY:function(){return al},ASv:function(){return qs},bwk:function(){return aa},mQc:function(){return Ei},c__:function(){return tu},QZ3:function(){return Pe},L39:function(){return $a.L},jII:function(){return ll},mPs:function(){return lu},tgM:function(){return uu},gqx:function(){return Yo.gq},Qm7:function(){return Yo.Qm},_wD:function(){return Ia._w},rjl:function(){return Ia.rj},Fjw:function(){return F.Fj},SLL:function(){return F.SL},sBv:function(){return F.sB},iTm:function(){return W.iT},Pls:function(){return Ct.Pl},Oxq:function(){return Hn},WLi:function(){return Fe},$9M:function(){return W.$9},nCn:function(){return ka},iNG:function(){return Da},tD8:function(){return Ci},pg9:function(){return kr},Ofb:function(){return W.Of},ibf:function(){return oo},WyG:function(){return ee},l6$:function(){return Bt.l6},WGR:function(){return Pt},C$H:function(){return bo.C$},cNQ:function(){return bo.cN},ZZb:function(){return W.ZZ},elO:function(){return bo.el},_Ko:function(){return po},Mev:function(){return ao},i2K:function(){return yo},WmO:function(){return Or.Wm},oBi:function(){return Ct.oB},igR:function(){return F.ig},DU1:function(){return F.DU},XCj:function(){return F.XC},lIL:function(){return Ct.lI},hi9:function(){return Ct.hi},p27:function(){return F.p2},z9d:function(){return rl.z},eJW:function(){return Ct.eJ},Cor:function(){return Ct.Co},aZq:function(){return Ct.aZ},P1D:function(){return ma.P1},ngQ:function(){return Ct.ng},ett:function(){return Ct.et},ySm:function(){return ct.y},Zd$:function(){return W.Zd},cLh:function(){return Ct.cL},baz:function(){return W.b},fde:function(){return Ct.fd},Xdt:function(){return bo.Xd},Cld:function(){return Ct.Cl},vH8:function(){return Ct.vH},PLH:function(){return Or.PL},V8t:function(){return Or.V8},tMk:function(){return Or.tM},xQm:function(){return Or.xQ},sRe:function(){return Ct.sR},frb:function(){return Wn},$N2:function(){return gn},U1u:function(){return Ee},HS$:function(){return F.HS},vBu:function(){return F.vB},QYZ:function(){return F.QY},t9d:function(){return F.t9},Kgy:function(){return Or.Kg},aJ2:function(){return Or.aJ},n14:function(){return va.n1},DiB:function(){return va.Di},l1O:function(){return W.l1},w5o:function(){return W.w5},p3Q:function(){return W.p3},G5e:function(){return W.G5},xj2:function(){return W.xj},rxY:function(){return W.rx},Ils:function(){return bo.Il},zCB:function(){return F.zC},wNf:function(){return Ct.wN},Dmu:function(){return Ct.Dm},Bsl:function(){return g.Bs},yKv:function(){return Os.y},fMB:function(){return Ct.fM},gCg:function(){return il},eT6:function(){return W.eT},q4O:function(){return W.q4},ymE:function(){return Ia.ym}});var L={};e.r(L),e.d(L,{Action:function(){return F.aU},ActionBar:function(){return F.ol},ActionBarProvider:function(){return F.N0},ActionContext:function(){return F.fW},ActionContextProvider:function(){return F.EI},ActionDesigner:function(){return F.$L},AfterSuccess:function(){return F.$b},AntdSchemaComponentPlugin:function(){return Ro},AntdSchemaComponentProvider:function(){return Fo},AppendsTreeSelect:function(){return la},AssignedFieldValues:function(){return F.eY},AssociationField:function(){return oa},AssociationSelect:function(){return pi},AttachmentList:function(){return Yo.fU},AutoComplete:function(){return Tl},Block:function(){return os},BlockItem:function(){return $a.j},ButtonEditor:function(){return F.C1},CardItem:function(){return Rl},Cascader:function(){return Ul},Checkbox:function(){return da},CollectionSelect:function(){return Vl},ColorPicker:function(){return Hl},ColorSelect:function(){return Jl},Cron:function(){return fi},CronSet:function(){return ql},DataSourceCollectionCascader:function(){return kl},DataSourceSelect:function(){return zl},DatePicker:function(){return ma.Mt},DatePickerProvider:function(){return ma.iN},Details:function(){return es},DetailsDesigner:function(){return Q},EditComponent:function(){return W.Fy},EditDefaultValue:function(){return W.Ni},EditDescription:function(){return W.q8},EditOperator:function(){return W.HG},EditPattern:function(){return W.QT},EditRequired:function(){return W.JE},EditSortField:function(){return ol},EditTitle:function(){return W.$w},EditTitleField:function(){return W.nB},EditTooltip:function(){return W.Oc},EditValidationRules:function(){return W.zd},Editable:function(){return nl},EllipsisWithTooltip:function(){return Ao.BQ},ErrorFallback:function(){return ct.H},Expand:function(){return hi},Filter:function(){return Or.wn},FilterAction:function(){return Or.Gz},FilterActionContext:function(){return Or.tJ},FilterContext:function(){return Or.fo},FilterDynamicComponent:function(){return Or.VT},FilterLogicContext:function(){return Or.Xs},FixedBlock:function(){return tr},FixedBlockDesignerItem:function(){return Lo},FixedBlockWrapper:function(){return Qn},Form:function(){return ae},FormDialog:function(){return zi.D},FormField:function(){return Ut},FormItem:function(){return W.xJ},FormV2:function(){return hr},G2Plot:function(){return _i},G2PlotRenderer:function(){return gi},Grid:function(){return va.rj},GridCard:function(){return Va},GridRowContext:function(){return va.jg},HTMLEncode:function(){return Ao.gs},IconPicker:function(){return vs},Input:function(){return Ao.II},InputNumber:function(){return Gi},InputReadPretty:function(){return Ao.mX},InputRecordPicker:function(){return bo.zD},Json:function(){return Ao.Ph},List:function(){return za},Markdown:function(){return Ji},MarkdownReadPretty:function(){return Yi},Menu:function(){return Ca},NanoIDInput:function(){return cu},Page:function(){return Hr},Pagination:function(){return Ts},Password:function(){return Rs},Percent:function(){return Bs},Preview:function(){return Ls.M},QuickEdit:function(){return Ks},Radio:function(){return yi},ReadPretty:function(){return Ao.iV},ReadPrettyRecordPicker:function(){return bo.OD},RecordPicker:function(){return bo.lb},RecordPickerContext:function(){return bo.b7},RecordPickerProvider:function(){return bo.sU},RefreshDataBlockRequest:function(){return F.x1},RemoteSelect:function(){return Ye},RemoveButton:function(){return F.xZ},RemoveConditionContext:function(){return Or.Iu},RequestSettings:function(){return F.Mk},RichText:function(){return Ns},SecondConFirm:function(){return F.y0},Select:function(){return It},SkipValidation:function(){return F.co},Space:function(){return $s},StablePopover:function(){return mr.q},Table:function(){return Jo},TableBlockDesigner:function(){return Xs},TableField:function(){return al},TableSelectorDesigner:function(){return qs},TableV2:function(){return aa},Tabs:function(){return Ei},TabsContextProvider:function(){return tu},Templates:function(){return Pe},TestDesigner:function(){return $a.L},TimePicker:function(){return ll},TreeSelect:function(){return lu},UnixTimestamp:function(){return uu},Upload:function(){return Yo.gq},Uploader:function(){return Yo.Qm},Variable:function(){return Ia._w},VariableScopeProvider:function(){return Ia.rj},WorkflowConfig:function(){return F.Fj},actionSettings:function(){return F.SL},actionSettingsItems:function(){return F.sB},allowAddNew:function(){return W.iT},defaultFieldNames:function(){return Hn},fetchTemplateData:function(){return Fe},filterFormItemSettings:function(){return W.$9},findByUid:function(){return ka},findKeysByUid:function(){return Da},findMenuItem:function(){return Ci},formDetailsSettings:function(){return kr},formItemSettings:function(){return W.Of},formSettings:function(){return oo},formV1Settings:function(){return ee},genStyleHook:function(){return Bt.l6},getCurrentOptions:function(){return Pt},getDatePickerLabels:function(){return bo.C$},getLabelFormatValue:function(){return bo.cN},isFileCollection:function(){return W.ZZ},isShowFilePicker:function(){return bo.el},pageSettings:function(){return po},pageTabSettings:function(){return ao},readPrettyFormSettings:function(){return yo},removeNullCondition:function(){return Or.Wm},useA:function(){return F.ig},useActionBarContext:function(){return F.DU},useActionContext:function(){return F.XC},useCloseAction:function(){return F.p2},useColumnSchema:function(){return rl.z},useDatePickerContext:function(){return ma.P1},useDownloadLogs:function(){return ct.y},useEnsureOperatorsValid:function(){return W.Zd},useFieldMode:function(){return W.b},useFieldNames:function(){return bo.Xd},useFilterActionProps:function(){return Or.PL},useFilterFieldOptions:function(){return Or.V8},useFilterFieldProps:function(){return Or.tM},useFilterOptions:function(){return Or.xQ},useFixedBlock:function(){return Wn},useFixedSchema:function(){return gn},useFormDataTemplates:function(){return Ee},useGetAriaLabelOfAction:function(){return F.HS},useGetAriaLabelOfDrawer:function(){return F.vB},useGetAriaLabelOfModal:function(){return F.QY},useGetAriaLabelOfPopover:function(){return F.t9},useGetFilterFieldOptions:function(){return Or.Kg},useGetFilterOptions:function(){return Or.aJ},useGridContext:function(){return va.n1},useGridRowContext:function(){return va.Di},useIsAddNewForm:function(){return W.l1},useIsAssociationField:function(){return W.w5},useIsFieldReadPretty:function(){return W.p3},useIsFileField:function(){return W.G5},useIsFormReadPretty:function(){return W.xj},useIsSelectFieldMode:function(){return W.rx},useLabelUiSchema:function(){return bo.Il},useLinkageAction:function(){return F.zC},useStyles:function(){return Os.y},useTabsContext:function(){return il},useTitleFieldOptions:function(){return W.eT},useValidateSchema:function(){return W.q4},useVariableScope:function(){return Ia.ym}});var l=e(15009),K=e.n(l),p=e(99289),A=e.n(p),x=e(12444),N=e.n(x),r=e(72004),B=e.n(r),h=e(31996),I=e.n(h),b=e(26037),T=e.n(b),t=e(97857),o=e.n(t),d=e(67294),R=e(31601),P=e(14896),g=e(70993),u=e(89127),j=function(M){return A()(K()().mark(function q(){var le,ce;return K()().wrap(function(De){for(;;)switch(De.prev=De.next){case 0:return De.prev=0,De.next=3,this.api.request(M);case 3:return ce=De.sent,De.abrupt("return",ce==null||(le=ce.data)===null||le===void 0?void 0:le.data);case 7:return De.prev=7,De.t0=De.catch(0),De.abrupt("return",[]);case 10:case"end":return De.stop()}},q,this,[[0,7]])}))},F=e(76157),z=e(13769),y=e.n(z),E=e(57134),C=e(86201),a=e(94350),D=e(28459),c=e(57953),v=e(12174),i=e(6145),m=e(74538),f=e(64016),O=e(95354),n=e(85893),U=["form","children"],k=["form","children","disabled"],H=["request","effects","initialValue","useValues"],$=function(M){var q=M.form,le=M.children,ce=y()(M,U),be=(0,a.useField)(),De=(0,a.useFieldSchema)(),Ke=(0,Ct.lI)(q.createVoidField(o()(o()({},be.props),{},{basePath:""})));return(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},ce),{},{children:(0,n.jsx)(a.RecursionField,{basePath:Ke.address,schema:De,onlyRenderProperties:!0})}))})})},V=function(M){return M.children},w=function(M){var q=M.form,le=M.children,ce=M.disabled,be=y()(M,k),De=(0,a.useField)(),Ke=(0,a.useFieldSchema)(),We=(0,Ct.lI)(q.createVoidField(o()(o()({},De.props),{},{basePath:""}))),ke=(0,Ct.Co)(Ke["x-component"],V);return(0,d.useEffect)(function(){q.disabled=ce||De.disabled},[ce,De.disabled]),(0,n.jsx)(D.ZP,{componentDisabled:ce,children:(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},be),{},{children:(0,n.jsx)(a.FieldContext.Provider,{value:We,children:(0,n.jsx)(ke,o()(o()({},De.componentProps),{},{children:(0,n.jsx)(a.RecursionField,{basePath:We.address,schema:Ke,onlyRenderProperties:!0})}))})}))})})})},G=function(M){var q=M.request,le=M.initialValue;return q||function(){return Promise.resolve({data:le})}},ne=function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(0,v.QT)(G(q),M)},X=(0,d.createContext)(null);X.displayName="FormBlockContext";var ae=(0,a.observer)(function(Z){var M=Z.request,q=Z.effects,le=Z.initialValue,ce=Z.useValues,be=ce===void 0?ne:ce,De=y()(Z,H),Ke=(0,a.useFieldSchema)(),We=(0,a.useField)(),ke=(0,d.useMemo)(function(){return(0,C.createForm)({effects:q})},[]),Ze=be({uid:Ke["x-uid"],onSuccess:function(tt){return A()(K()().mark(function it(){return K()().wrap(function(st){for(;;)switch(st.prev=st.next){case 0:return st.next=2,ke.reset();case 2:ke.setValues(tt==null?void 0:tt.data),ke.setInitialValues(tt==null?void 0:tt.data);case 4:case"end":return st.stop()}},it)}))()}},Z),Je=(0,d.useContext)(X);return(0,n.jsx)(X.Provider,{value:{parent:Je,form:ke,result:Ze,field:We,fieldSchema:Ke},children:(0,n.jsx)(c.Z,{spinning:(Ze==null?void 0:Ze.loading)||!1,children:Ke["x-decorator"]==="Form"?(0,n.jsx)(w,o()({form:ke},De)):(0,n.jsx)($,o()({form:ke},De))})})},{displayName:"Form"});ae.Designer=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsxs)(m.aN,{template:ce,title:le||q,children:[(0,n.jsx)(f.G,{componentName:"Form",collectionName:q}),(0,n.jsx)(m.Z5,{}),(0,n.jsx)(m.qx,{removeParentsIfNoChildren:!0,breakRemoveOn:{"x-component":"Grid"}})]})};var oe=e(5537),ee=new oe.F5({name:"FormV1Settings",items:[{name:"template",Component:f.G,useComponentProps:function(){var M=(0,i.useCollection_deprecated)(),q=M.name;return{componentName:"Form",collectionName:q}}},{name:"divider",type:"divider"},{name:"remove",type:"remove",componentProps:{removeParentsIfNoChildren:!0,breakRemoveOn:{"x-component":"Grid"}}}]}),W=e(54801),de=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"FormSettings",template:ce,title:le||q})},me=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"ReadPrettyFormSettings",template:ce,title:le||q})},Q=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"FormDetailsSettings",template:ce,title:le||q})},_e=function(){var M=(0,i.useCollection_deprecated)(),q=M.name,le=M.title,ce=(0,O.zy)();return(0,n.jsx)(m.aN,{schemaSettings:"blockSettings:filterForm",template:ce,title:le||q})},ye=e(7340),Ae=e(15503),Se=e(68230),he=e(9783),ve=e.n(he),J=e(68400),Y=e.n(J),ue=e(97133),xe=e(85667),fe=e(73773),Me=e(68433),Ie=e(9361),Ue=e(96486),Ne=e.n(Ue),Oe=e(31019),pe=e(4595),Ce=e(86406),se=e(90615),S=e(44256),te=e(76690),ge=e(34588),ie=e(9780),Be=e(18686),Xe=e(94804),rt=e(5574),Te=e.n(rt),et=e(42075),Re=e(34041),He=e(26793),ut=e(32268),Bt=e(60094),Yt=e(52677),qt=e.n(Yt),In=e(50888),un=e(66309),yn=e(96074),qn=e(27484),Ft=e.n(qn),Mn=e(87714),Ct=e(84577),hn=e(4340),xn=e(97937),Xt=e(32983),Wt=e(58812),on=e(96695),vn=e.n(on),En=e(19632),Cn=e.n(En),Hn={label:"label",value:"value",color:"color",options:"children"};function Vt(Z,M){var q=[];if(!Array.isArray(Z))return q;for(var le=0;le<Z.length;le++){var ce=Z[le][M.options];Array.isArray(ce)&&q.push.apply(q,Cn()(Vt(ce,M))),q.push(o()({},Z[le]))}return q}function Pt(Z,M,q){var le=Vt(M,q),ce=(0,Ue.castArray)(Z).map(function(De){return(0,Me.isPlainObject)(De)?De[q.value]:De});function be(De){if(!De)return[];var Ke=[],We=vn()(ce),ke;try{var Ze=function(){var pt=ke.value,tt=De.find(function(it){return it[q.value]==pt})||{value:pt,label:pt&&pt.toString()};Ke.push(tt)};for(We.s();!(ke=We.n()).done;)Ze()}catch(Je){We.e(Je)}finally{We.f()}return Ke}return be(le)}var Et=e(67668),gt=(0,a.observer)(function(Z){var M,q=o()(o()({},Hn),Z.fieldNames),le=(0,a.useField)(),ce=(0,Et.Hy)(),be=le.dataSource||Z.options||(ce==null?void 0:ce.uiSchema.enum)||[],De=Pt(le.value,be,q);return!(0,fe.isValid)(Z.value)&&!De.length?(0,n.jsx)("div",{}):(0,C.isArrayField)(le)&&(le==null||(M=le.value)===null||M===void 0?void 0:M.length)===0?(0,n.jsx)("div",{}):(0,n.jsx)("div",{children:(0,n.jsx)(Wt.B,{ellipsis:Z.ellipsis,children:De.map(function(Ke,We){return(0,n.jsx)(un.Z,{color:Ke[q.color],icon:Ke.icon,children:Ke[q.label]},We)})})})},{displayName:"ReadPretty"}),Lt=["value","options","onChange","fieldNames","mode","loading","rawOptions","defaultValue"],en=["objectValue","loading","value","rawOptions","defaultValue"],Bn=function(M){return!(0,fe.isValid)(M)||qt()(M)==="object"&&Object.keys(M).length===0},an=function(M){var q=M.value,le=M.options,ce=M.onChange,be=M.fieldNames,De=M.mode,Ke=M.loading,We=M.rawOptions,ke=M.defaultValue,Ze=y()(M,Lt),Je=function(tt){var it;if(!Bn(tt)){var at=(0,fe.toArr)(tt).filter(function(Mt){return Mt}).map(function(Mt){return(0,Me.isPlainObject)(Mt)?Mt[be.value]:Mt}),st=(it=Pt(at,le,be))===null||it===void 0?void 0:it.map(function(Mt){return{label:Mt[be.label],value:Mt[be.value]}});return["tags","multiple"].includes(De)||M.multiple?st:st.shift()}};return(0,n.jsx)(Re.default,o()({role:"button","data-testid":"select-object-".concat(De||"single"),value:Je(q),defaultValue:Je(ke),allowClear:{clearIcon:(0,n.jsx)(hn.Z,{role:"button","aria-label":"icon-close-select"})},labelInValue:!0,notFoundContent:Ke?(0,n.jsx)(c.Z,{}):(0,n.jsx)(Xt.Z,{image:Xt.Z.PRESENTED_IMAGE_SIMPLE}),options:le,fieldNames:be,showSearch:!0,popupMatchSelectWidth:!1,filterOption:function(tt,it){var at;return((at=it==null?void 0:it[be.label||"label"])!==null&&at!==void 0?at:"").includes(tt)},filterSort:function(tt,it){var at,st;return((at=tt==null?void 0:tt[be.label||"label"])!==null&&at!==void 0?at:"").toLowerCase().localeCompare(((st=it==null?void 0:it[be.label||"label"])!==null&&st!==void 0?st:"").toLowerCase())},onChange:function(tt){var it=Pt((0,fe.toArr)(tt).map(function(at){return at.value}),We||le,be);["tags","multiple"].includes(De)||M.multiple?ce==null||ce(it):ce==null||ce(it.shift()||null)},mode:De,tagRender:function(tt){return(0,n.jsx)(un.Z,o()(o()({role:"button","aria-label":tt.label,closeIcon:(0,n.jsx)(xn.Z,{role:"button","aria-label":"icon-close-tag"})},tt),{},{children:tt.label}))}},Ze))},St=function(M,q){var le;return((le=q==null?void 0:q.label)!==null&&le!==void 0?le:"").toLowerCase().includes((M||"").toLowerCase())},Rt=(0,a.connect)(function(Z){var M=Z.objectValue,q=Z.loading,le=Z.value,ce=Z.rawOptions,be=Z.defaultValue,De=y()(Z,en),Ke=Z.multiple?"multiple":Z.mode;if(Ke&&!["multiple","tags"].includes(Ke)&&(Ke=void 0),M)return(0,n.jsx)(an,o()(o()({rawOptions:ce},De),{},{defaultValue:be,value:le,mode:Ke,loading:q}));var We=function(Ze){return["tags","multiple"].includes(Z.mode)||Z.multiple?Ze?(0,fe.toArr)(Ze):void 0:Ze};return(0,n.jsx)(Re.default,o()(o()({role:"button","data-testid":"select-".concat(Ke||"single"),showSearch:!0,filterOption:St,allowClear:{clearIcon:(0,n.jsx)(hn.Z,{role:"button","aria-label":"icon-close-select"})},popupMatchSelectWidth:!1,notFoundContent:q?(0,n.jsx)(c.Z,{}):(0,n.jsx)(Xt.Z,{image:Xt.Z.PRESENTED_IMAGE_SIMPLE}),value:We(le),defaultValue:We(be),tagRender:function(Ze){return(0,n.jsx)(un.Z,o()(o()({role:"button","aria-label":Ze.label,closeIcon:(0,n.jsx)(xn.Z,{role:"button","aria-label":"icon-close-tag"})},Ze),{},{children:Ze.label}))}},De),{},{onChange:function(Ze){var Je;(Je=Z.onChange)===null||Je===void 0||Je.call(Z,Ze===void 0?null:Ze)},mode:Ke}))},(0,a.mapProps)({dataSource:"options"},function(Z,M){return o()(o()({},Z),{},{fieldNames:o()(o()({},Hn),Z.fieldNames),suffixIcon:M!=null&&M.loading||M!=null&&M.validating?(0,n.jsx)(In.Z,{}):Z.suffixIcon})}),(0,a.mapReadPretty)(gt)),It=Rt;It.ReadPretty=gt;var Jt=It,tn=e(36586),pn=function(M,q){return(0,Ue.castArray)(M).filter(function(le){return le!=null}).map(function(le){return qt()(le)==="object"?le[q.value]:le})},jt=(0,a.observer)(function(Z){var M=o()(o()({},Hn),Z.fieldNames),q=(0,a.useField)(),le=(0,a.useFieldSchema)(),ce=(0,tn.a)(),be=(0,F.XC)(),De=be.snapshot,Ke=(0,v.QT)(De?A()(K()().mark(function ke(){return K()().wrap(function(Je){for(;;)switch(Je.prev=Je.next){case 0:return Je.abrupt("return",{data:ce[le.name]});case 1:case"end":return Je.stop()}},ke)})):o()(o()({action:"list"},Z.service),{},{params:{paginate:!1,filter:ve()({},M.value,{$in:pn(q.value,M)})}}),{refreshDeps:[Z.service,q.value]}),We=Ke.data;return(0,n.jsx)(It.ReadPretty,o()(o()({},Z),{},{options:We==null?void 0:We.data}))},{displayName:"ReadPretty"}),Rn=e(8341),_n=e(44990),Dn=["fieldNames","service","wait","value","defaultValue","objectValue","manual","mapOptions","targetField","CustomDropdownRender","optionFilter","dataSource"],ht="N/A",Ge=(0,a.connect)(function(Z){var M,q,le=Z.fieldNames,ce=le===void 0?{}:le,be=Z.service,De=be===void 0?{}:be,Ke=Z.wait,We=Ke===void 0?300:Ke,ke=Z.value,Ze=Z.defaultValue,Je=Z.objectValue,pt=Z.manual,tt=pt===void 0?!0:pt,it=Z.mapOptions,at=Z.targetField,st=Z.CustomDropdownRender,Mt=Z.optionFilter,yt=Z.dataSource,Ht=y()(Z,Dn),wt=(0,_n.FC)(),Kn=(0,Rn.FE)(yt||wt),cn=(0,d.useState)(!1),Kt=Te()(cn,2),mn=Kt[0],Nn=Kt[1],er=(0,d.useRef)(!1),wn=(0,a.useFieldSchema)(),bn=((M=wn["x-component-props"])===null||M===void 0?void 0:M.addMode)==="quickAdd",nr=(0,i.useCollection_deprecated)(),Pn=nr.getField,yr=(0,d.useRef)(null),Lr=(0,i.useCollectionManager_deprecated)(),jr=Lr.getCollectionJoinField,ar=Lr.getInterface,cr=wn["x-collection-field"]||wn.name,Zn=Pn(cr)||jr(cr),jn=at||(Zn==null?void 0:Zn.target)&&(ce==null?void 0:ce.label)&&jr("".concat(Zn.target,".").concat(ce.label)),Jn=(0,d.useMemo)(function(){if(jn!=null&&jn.interface){var Xr;return((Xr=ar(jn.interface))===null||Xr===void 0||(Xr=Xr.filterable)===null||Xr===void 0?void 0:Xr.operators[0].value)||"$includes"}return"$includes"},[jn]),rr=(0,Ct.eJ)(),Sn=(0,d.useCallback)(function(Xr){try{return Xr.filter(function(ro){return["number","string"].includes(qt()(ro[ce.value]))}).map(function(ro){var Io,To,jo=rr(ro[ce.label]);if(jn!=null&&(Io=jn.uiSchema)!==null&&Io!==void 0&&Io.enum)if(Array.isArray(jo))jo=jo.map(function(Go,xa){var ia=jn.uiSchema.enum.find(function(Di){return Di.value===Go});return ia?(0,n.jsx)(un.Z,{role:"button",color:ia.color,style:{marginRight:3},children:(ia==null?void 0:ia.label)||Go},xa):(0,n.jsx)(un.Z,{role:"button",children:Go},Go)}).reverse();else{var Uo=jn.uiSchema.enum.find(function(Go){return Go.value===jo});Uo&&(jo=(0,n.jsx)(un.Z,{role:"button",color:Uo.color,children:Uo.label}))}if((jn==null?void 0:jn.type)==="date"&&(jo=Ft()(jo).format("YYYY-MM-DD")),it){var Qo;return it((Qo={},ve()(Qo,ce.label,jo||ht),ve()(Qo,ce.value,ro[ce.value]),Qo))}return o()(o()({},ro),{},(To={},ve()(To,ce.label,jo||ht),ve()(To,ce.value,ro[ce.value]),To))}).filter(Boolean)}catch(ro){return console.error(ro),Xr}},[jn==null?void 0:jn.uiSchema,ce]),$n=(0,v.QT)(o()(o()({action:"list"},De),{},{headers:Kn,params:o()(o()({pageSize:200},De==null?void 0:De.params),{},{filter:De==null||(q=De.params)===null||q===void 0?void 0:q.filter})}),{manual:tt,debounceWait:We}),ur=$n.data,fr=$n.run,Sr=$n.loading,Ur=(0,d.useMemo)(function(){return JSON.stringify({service:De,fieldNames:ce})},[De,ce]),vr=(0,d.useCallback)(function(){return yr.current&&st?(0,n.jsx)(st,{search:yr.current,callBack:function(){yr.current=null,Nn(!1)}}):null},[yr.current]);(0,d.useEffect)(function(){er.current&&fr()},[Ur]);var Gr=function(){var Xr=A()(K()().mark(function ro(Io){var To;return K()().wrap(function(Uo){for(;;)switch(Uo.prev=Uo.next){case 0:fr({filter:(0,Mn.EO)([Io?ve()({},ce.label,ve()({},Jn,Io)):{},De==null||(To=De.params)===null||To===void 0?void 0:To.filter])}),yr.current=Io;case 2:case"end":return Uo.stop()}},ro)}));return function(Io){return Xr.apply(this,arguments)}}(),co=(0,d.useMemo)(function(){var Xr,ro=ke||Ze;if(!(ur!=null&&(Xr=ur.data)!==null&&Xr!==void 0&&Xr.length))return ro!=null?Array.isArray(ro)?ro:[ro]:[];var Io=ro!=null&&(Array.isArray(ro)?ro:[o()(o()({},ro),{},ve()({},ce.value,ro[ce.value]||ro))])||[],To=typeof Mt=="function"?ur.data.filter(Mt):ur.data;return(0,Ue.uniqBy)(To.concat(Io!=null?Io:[]),ce.value)},[ke,Ze,ur==null?void 0:ur.data,ce.value,Mt]),Jr=function(ro){Nn(ro),yr.current=null,ro&&fr(),er.current=!0};return(0,n.jsx)(It,o()(o()({open:mn,popupMatchSelectWidth:!1,autoClearSearchValue:!0,filterOption:!1,filterSort:null,fieldNames:ce,onSearch:Gr,onDropdownVisibleChange:Jr,objectValue:Je,value:ke,defaultValue:Ze},Ht),{},{loading:ur?Sr:!0,options:Sn(co),rawOptions:co,dropdownRender:function(ro){var Io=co.some(function(To){return To[ce.label]===yr.current});return(0,n.jsx)(n.Fragment,{children:bn?(0,n.jsxs)(n.Fragment,{children:[!((ur==null?void 0:ur.data.length)===0&&yr!==null&&yr!==void 0&&yr.current)&&ro,(ur==null?void 0:ur.data.length)>0&&(yr==null?void 0:yr.current)&&!Io&&(0,n.jsx)(yn.Z,{style:{margin:0}}),!Io&&(0,n.jsx)(vr,{})]}):ro})}}))},(0,a.mapProps)({dataSource:"options"},function(Z,M){var q,le=(0,a.useFieldSchema)();return o()(o()({},Z),{},{fieldNames:o()(o()(o()(o()({},Hn),Z.fieldNames),M.componentProps.fieldNames),(q=le["x-component-props"])===null||q===void 0?void 0:q.fieldNames),suffixIcon:M!=null&&M.loading||M!=null&&M.validating?(0,n.jsx)(In.Z,{}):Z.suffixIcon})}),(0,a.mapReadPretty)(jt)),Ye=Ge;Ye.ReadPretty=jt;var Qe=null,Ee=function(){var M=(0,a.useFieldSchema)(),q=(0,He.$)(),le=q.t,ce=(0,ye.bz)(),be=ce.duplicateData,De=(0,i.useCollectionManager_deprecated)(),Ke=De.getCollectionJoinField;if(be)return be;var We=Le(M),ke=We.items,Ze=ke===void 0?[]:ke,Je=We.display,pt=Je===void 0?!0:Je;Ze.forEach(function(at){try{var st;at.fields=(st=at.fields)===null||st===void 0?void 0:st.map(function(Mt){var yt=Ke("".concat(at.collection,".").concat(Mt));return yt?Mt:""}).filter(Boolean)}catch(Mt){(0,Me.error)(Mt),at.fields=[]}});var tt=[{key:"none",title:le("None")}].concat(Ze.map(function(at,st){return o()(o()({key:st},at),{},{isLeaf:at.dataId!==null&&at.dataId!==void 0,titleCollectionField:(at==null?void 0:at.titleField)&&Ke("".concat(at.collection,".").concat(at.titleField))})})),it=Ze.find(function(at){return at.default});return{templates:tt,display:pt,defaultTemplate:it,enabled:Ze.length>0&&Ze.every(function(at){return at.dataId||at.dataScope})}},Pe=function(M){var q=M.style,le=q===void 0?{}:q,ce=M.form,be=(0,Bt.dQ)(),De=be.token,Ke=Ee(),We=Ke.templates,ke=Ke.display,Ze=Ke.enabled,Je=Ke.defaultTemplate,pt=(0,i.useCollectionManager_deprecated)(),tt=pt.getCollectionJoinField,it=(0,ut.ss)(We),at=(0,d.useState)((Je==null?void 0:Je.key)||"none"),st=Te()(at,2),Mt=st[0],yt=st[1],Ht=(0,d.useState)(null),wt=Te()(Ht,2),Kn=wt[0],cn=wt[1],Kt=(0,v.LY)(),mn=(0,He.$)(),Nn=mn.t;(0,d.useEffect)(function(){Ze&&Je&&ce&&(ce.__template=!0,Je.key==="duplicate"&&nr(Je.dataId,Je))},[]),(0,d.useEffect)(function(){it!=null&&it.some(function(yr){return yr.key===Mt})||bn("none")},[it]);var er=(0,d.useMemo)(function(){return o()({display:"flex",alignItems:"center",backgroundColor:De.colorFillAlter,padding:De.padding},le)},[le,De.colorFillAlter]),wn=(0,d.useMemo)(function(){return{fontSize:De.fontSize,fontWeight:"bold",whiteSpace:"nowrap",marginRight:De.marginXS}},[De.fontSize,De.marginXS]),bn=(0,d.useCallback)(function(){var yr=A()(K()().mark(function Lr(jr){return K()().wrap(function(cr){for(;;)switch(cr.prev=cr.next){case 0:yt(jr),cn(null),ce==null||ce.reset();case 3:case"end":return cr.stop()}},Lr)}));return function(Lr){return yr.apply(this,arguments)}}(),[]),nr=(0,d.useCallback)(function(){var yr=A()(K()().mark(function Lr(jr,ar){var cr;return K()().wrap(function(jn){for(;;)switch(jn.prev=jn.next){case 0:cr=o()(o()({},ar),{},{dataId:jr}),cn(ar),Fe(Kt,cr,Nn).then(function(Jn){return ce&&Jn&&(ce.reset(),ce.__template=!0,(0,Me.forEach)(Jn,function(rr,Sn){if(rr){var $n;ce.values[Sn]=rr,ce==null||($n=ce.setInitialValuesIn)===null||$n===void 0||$n.call(ce,Sn,rr)}})),Jn}).catch(function(Jn){console.error(Jn)});case 3:case"end":return jn.stop()}},Lr)}));return function(Lr,jr){return yr.apply(this,arguments)}}(),[]);if(!Ze||!ke)return null;var Pn=it==null?void 0:it.find(function(yr){return yr.key===Mt});return(0,n.jsx)("div",{style:er,children:(0,n.jsxs)(et.Z,{wrap:!0,children:[(0,n.jsxs)("label",{style:wn,children:[Nn("Data template"),": "]}),(0,n.jsx)(Re.default,{role:"button","data-testid":"select-form-data-template",popupMatchSelectWidth:!1,options:it,fieldNames:{label:"title",value:"key"},value:Mt,onChange:bn}),Mt!=="none"&&Pn&&(0,n.jsx)(Ye,{style:{width:220},fieldNames:{label:Pn==null?void 0:Pn.titleField,value:"id"},target:Pn==null?void 0:Pn.collection,value:Kn,objectValue:!0,service:{resource:Pn==null?void 0:Pn.collection,params:{filter:Pn==null?void 0:Pn.dataScope}},onChange:function(Lr){return nr(Lr==null?void 0:Lr.id,o()(o()({},Lr),Pn))},targetField:tt("".concat(Pn==null?void 0:Pn.collection,".").concat(Pn.titleField))})]})})};function Le(Z){var M=(0,ye.Fi)(Z);return M?Ne().cloneDeep(M["x-data-templates"])||{}:{}}function Fe(Z,M,q){return $e.apply(this,arguments)}function $e(){return $e=A()(K()().mark(function Z(M,q,le){return K()().wrap(function(be){for(;;)switch(be.prev=be.next){case 0:if(!(q.fields.length===0||!q.dataId)){be.next=2;break}return be.abrupt("return");case 2:return be.abrupt("return",M.resource(q.collection).get({filterByTk:q.dataId,fields:q.fields,isTemplate:!0}).then(function(De){var Ke;return(Ke=De.data)===null||Ke===void 0?void 0:Ke.data}));case 3:case"end":return be.stop()}},Z)})),$e.apply(this,arguments)}var qe=e(3192),_t=function(){var M,q,le=(0,Be.aZ)(),ce=(0,a.useFieldSchema)(),be=Ie.Z.useToken(),De=be.token,Ke=(0,Ct.ng)(),We=Ke.designable,ke=(0,qe.g)()||{},Ze=ke.heightProps,Je=Ze||{},pt=Je.title,tt=Ee(),it=tt.display,at=tt.enabled,st=ce.reduceProperties(function(nr,Pn){return Pn["x-component"]==="ActionBar"?Pn:nr}),Mt=Object.keys((st==null?void 0:st.properties)||{}).length>0,yt=ce==null||(M=ce.parent)===null||M===void 0||(M=M["x-decorator"])===null||M===void 0||(q=M.includes)===null||q===void 0?void 0:q.call(M,"FormBlockProvider"),Ht=Mt||We?De.controlHeight+(yt?1:2)*De.marginLG:De.marginLG,wt=pt?De.fontSizeLG*De.lineHeightLG+De.padding*2-1:0,Kn=(0,Xe.hS)()||{},cn=Kn.data,Kt=(cn==null?void 0:cn.meta)||{},mn=Kt.count,Nn=Kt.pageSize,er=mn>Nn,wn=er?De.controlHeightSM+1*De.paddingLG:0,bn=it&&at?De.controlHeight+2*De.padding+De.margin:0;return le-Ht-De.paddingLG-wt-wn-bn},vt=e(25324),dt,xt,bt=["form","children"],ft=["form","children","disabled"],At=["form","disabled"],Nt=function(M){var q=M.form,le=M.children,ce=y()(M,bt),be=(0,a.useField)(),De=(0,a.useFieldSchema)(),Ke=(0,Ct.lI)(q.createVoidField(o()(o()({},be.props),{},{basePath:""}))),We=_t(),ke=Ie.Z.useToken(),Ze=ke.token,Je=(0,Ct.ng)(),pt=Je.designable;return(0,n.jsx)(a.FieldContext.Provider,{value:void 0,children:(0,n.jsx)(a.FormContext.Provider,{value:q,children:(0,n.jsx)(E.FormLayout,o()(o()({layout:"vertical"},ce),{},{children:(0,n.jsx)("div",{className:(0,ue.css)(dt||(dt=Y()([`
654
654
  .nb-grid-container {
655
655
  height: `,`;
656
656
  overflow-y: auto;