Local modifications to ClusterLabs/Anvil by Alteeve
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

1 lines
22 KiB

"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[903],{7504:function(n,e,t){var r=t(5893),o=t(7294),i=t(6886),u=t(7357);function l(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function a(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function c(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})))),r.forEach((function(e){a(n,e,t[e])}))}return n}function s(n,e){if(null==n)return{};var t,r,o=function(n,e){if(null==n)return{};var t,r,o={},i=Object.keys(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||(o[t]=n[t]);return o}(n,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}function f(n,e){return function(n){if(Array.isArray(n))return n}(n)||function(n,e){var t=null==n?null:"undefined"!==typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=t){var r,o,i=[],u=!0,l=!1;try{for(t=t.call(n);!(u=(r=t.next()).done)&&(i.push(r.value),!e||i.length!==e);u=!0);}catch(a){l=!0,o=a}finally{try{u||null==t.return||t.return()}finally{if(l)throw o}}return i}}(n,e)||function(n,e){if(!n)return;if("string"===typeof n)return l(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return l(n,e)}(n,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}e.Z=function(n){var e=n.calculateItemBreakpoints,t=void 0===e?function(){return{xs:1}}:e,l=n.layout,a=n.wrapperBoxProps,d=s(n,["calculateItemBreakpoints","layout","wrapperBoxProps"]),p=(0,o.useMemo)((function(){return Object.entries(l).map((function(n,e){var r=f(n,2),u=r[0],l=r[1],a=u;return l?(0,o.createElement)(i.ZP,c({},t(e,a),{key:a,item:!0},l)):void 0}))}),[t,l]);return(0,r.jsx)(u.Z,c({},a,{children:(0,r.jsx)(i.ZP,c({container:!0},d,{children:p}))}))}},5521:function(n,e,t){t.d(e,{Z:function(){return H}});var r=t(5893),o=t(1113),i=t(1496),u=t(2293),l=t(7357),a=t(2992),c=t(4799),s=t(7294),f=t(7169),d=t(4433),p=t(9029),v=t(7533),y=t(8462),m=t(7212),b=t(8619),g=[{text:"Anvil",image:"/pngs/anvil_icon_on.png",uri:"/manage-element"},{text:"Files",image:"/pngs/files_on.png",uri:"/file-manager"},{text:"Configure",image:"/pngs/configure_icon_on.png",uri:"/config"},{text:"Help",image:"/pngs/help_icon_on.png",uri:"https://alteeve.com/w/Support"}],h={width:"40em",height:"40em"},j=t(4390),O=t(582),S=t(4690),w=t(1770),x=t(7750),A=t(1081);function k(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function P(n,e){return function(n){if(Array.isArray(n))return n}(n)||function(n,e){var t=null==n?null:"undefined"!==typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=t){var r,o,i=[],u=!0,l=!1;try{for(t=t.call(n);!(u=(r=t.next()).done)&&(i.push(r.value),!e||i.length!==e);u=!0);}catch(a){l=!0,o=a}finally{try{u||null==t.return||t.return()}finally{if(l)throw o}}return i}}(n,e)||function(n,e){if(!n)return;if("string"===typeof n)return k(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return k(n,e)}(n,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var I=function(){var n=(0,A.Z)(),e=(0,s.useState)({}),t=e[0],r=e[1],o=(0,s.useCallback)((function(n){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"suiapi.";return t["".concat(e).concat(n)]}),[t]),i=(0,s.useCallback)((function(){return o("user")}),[o]);return(0,s.useEffect)((function(){if(n){var e=document.cookie.split(/\s*;\s*/);r(e.reduce((function(n,e){var t,r=P(e.split("=",2),2),o=r[0],i=r[1],u=decodeURIComponent(i);if(u.startsWith("j:"))try{t=JSON.parse(u.substring(2))}catch(l){t=i}else t=i;return n[o]=t,n}),{}))}}),[n]),{cookieJar:t,getCookie:o,getSessionUser:i}};function C(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function Z(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})))),r.forEach((function(e){C(n,e,t[e])}))}return n}var E="AnvilDrawer",M={actionIcon:"".concat(E,"-actionIcon"),list:"".concat(E,"-list")},B=(0,i.ZP)(v.ZP)((function(){var n;return C(n={},"& .".concat(M.list),{width:"200px"}),C(n,"& .".concat(M.actionIcon),{fontSize:"2.3em",color:f.of}),n})),T=function(n){var e=n.open,t=n.setOpen,o=(0,I().getSessionUser)();return(0,r.jsx)(B,{BackdropProps:{invisible:!0},anchor:"left",open:e,onClose:function(){return t(!e)},children:(0,r.jsx)("div",{role:"presentation",children:(0,r.jsxs)(y.Z,{className:M.list,children:[(0,r.jsx)(m.ZP,{children:(0,r.jsx)(x.Ac,{children:o?(0,r.jsxs)(r.Fragment,{children:["Welcome, ",o.name]}):"Unregistered"})}),(0,r.jsx)(O.Z,{}),(0,r.jsx)(b.Z,{component:"a",href:"/index.html",children:(0,r.jsxs)(S.Z,{fullWidth:!0,row:!0,spacing:"2em",children:[(0,r.jsx)(d.Z,{className:M.actionIcon}),(0,r.jsx)(x.Ac,{children:"Dashboard"})]})}),g.map((function(n){return(0,r.jsx)(b.Z,{component:"a",href:n.uri,children:(0,r.jsxs)(S.Z,{fullWidth:!0,row:!0,spacing:"2em",children:[(0,r.jsx)("img",Z({alt:n.text,src:n.image},h)),(0,r.jsx)(x.Ac,{children:n.text})]})},"anvil-drawer-".concat(n.image))})),(0,r.jsx)(b.Z,{onClick:function(){j.Z.put("/auth/logout").then((function(){window.location.replace("/login")})).catch((function(n){(0,w.Z)(n)}))},children:(0,r.jsxs)(S.Z,{fullWidth:!0,row:!0,spacing:"2em",children:[(0,r.jsx)(p.Z,{className:M.actionIcon}),(0,r.jsx)(x.Ac,{children:"Logout"})]})})]})})})},F=t(3377),R=t(2444);function U(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}var N="Header",_={input:"".concat(N,"-input"),barElement:"".concat(N,"-barElement"),iconBox:"".concat(N,"-iconBox"),searchBar:"".concat(N,"-searchBar"),icons:"".concat(N,"-icons")},V=(0,i.ZP)(u.Z)((function(n){var e,t=n.theme;return U(e={paddingTop:t.spacing(.5),paddingBottom:t.spacing(.5),paddingLeft:t.spacing(3),paddingRight:t.spacing(3),borderBottom:"solid 1px",borderBottomColor:f.hM,position:"static"},"& .".concat(_.input),{height:"2.8em",width:"30vw",backgroundColor:t.palette.secondary.main,borderRadius:f.n_}),U(e,"& .".concat(_.barElement),{padding:0}),U(e,"& .".concat(_.iconBox),U({},t.breakpoints.down("sm"),{display:"none"})),U(e,"& .".concat(_.searchBar),U({},t.breakpoints.down("sm"),{flexGrow:1,paddingLeft:"15vw"})),U(e,"& .".concat(_.icons),{paddingLeft:".1em",paddingRight:".1em"}),e})),H=function(){var n=(0,s.useRef)({}),e=(0,s.useRef)({}),t=(0,s.useState)(!1),i=t[0],u=t[1];return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(V,{children:(0,r.jsxs)(l.Z,{display:"flex",justifyContent:"space-between",flexDirection:"row",children:[(0,r.jsx)(S.Z,{row:!0,children:(0,r.jsx)(a.Z,{onClick:function(){return u(!i)},children:(0,r.jsx)("img",{alt:"",src:"/pngs/logo.png",width:"160",height:"40"})})}),(0,r.jsx)(S.Z,{className:_.iconBox,row:!0,spacing:0,children:(0,r.jsx)(l.Z,{children:(0,r.jsx)(c.Z,{onClick:function(n){var t,r,o=n.currentTarget;null===(t=e.current.setAnchor)||void 0===t||t.call(null,o),null===(r=e.current.setOpen)||void 0===r||r.call(null,!0)},sx:{color:f.of,padding:"0 .1rem"},children:(0,r.jsx)(F.Z,{icon:o.Z,ref:n})})})})]})}),(0,r.jsx)(T,{open:i,setOpen:u}),(0,r.jsx)(R.Z,{onFetchSuccessAppend:function(e){var t;null===(t=n.current.indicate)||void 0===t||t.call(null,Object.keys(e).length>0)},ref:e})]})}},9099:function(n,e,t){t.d(e,{Z:function(){return g}});var r=t(7294),o={boolean:function(n){return Boolean(n)},number:function(n){return parseInt(String(n),10)||0},string:function(n){return String(n)}},i=function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=n.postSet,t=n.preSet,r=n.set,i=n.setType,u=void 0===i?"string":i,l=n.valueKey,a=void 0===l?"value":l;return function(n){var i=n.target[a],l=o[u](i);null===t||void 0===t||t.call(null,n),null===r||void 0===r||r.call(null,l),null===e||void 0===e||e.call(null,n)}},u=t(7987);function l(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function a(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function c(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})))),r.forEach((function(e){a(n,e,t[e])}))}return n}function s(n,e){if(null==n)return{};var t,r,o=function(n,e){if(null==n)return{};var t,r,o={},i=Object.keys(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||(o[t]=n[t]);return o}(n,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}function f(n){return function(n){if(Array.isArray(n))return l(n)}(n)||function(n){if("undefined"!==typeof Symbol&&null!=n[Symbol.iterator]||null!=n["@@iterator"])return Array.from(n)}(n)||function(n,e){if(!n)return;if("string"===typeof n)return l(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return l(n,e)}(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(n){var e=function(n,e){if("object"!==p(n)||null===n)return n;var t=n[Symbol.toPrimitive];if(void 0!==t){var r=t.call(n,e||"default");if("object"!==p(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(n)}(n,"string");return"symbol"===p(e)?e:String(e)}var p=function(n){return n&&"undefined"!==typeof Symbol&&n.constructor===Symbol?"symbol":typeof n};var v="input",y={boolean:!1,number:0,string:""},m={createInputOnChangeHandlerOptions:{},required:!1,valueType:"string"},b=(0,r.forwardRef)((function(n,e){var t=n.input,o=n.inputTestBatch,l=n.onBlurAppend,p=n.onFirstRender,b=n.onFocusAppend,g=n.onUnmount,h=n.required,j=void 0===h?m.required:h,O=n.valueKey,S=n.valueType,w=void 0===S?m.valueType:S,x=n.createInputOnChangeHandlerOptions,A=void 0===x?m.createInputOnChangeHandlerOptions:x,k=A.postSet,P=A.valueKey,I=void 0===P?O:P,C=s(n.createInputOnChangeHandlerOptions,["postSet","valueKey"]),Z=t.props,E=(0,r.useMemo)((function(){return null!==I&&void 0!==I?I:"checked"in Z?"checked":"value"}),[Z,I]),M=Z.onBlur,B=Z.onChange,T=Z.onFocus,F=Z[E],R=void 0===F?y[w]:F,U=s(Z,["onBlur","onChange","onFocus",E].map(d)),N=(0,r.useState)(R),_=N[0],V=N[1],H=(0,r.useState)(!1),K=H[0],D=H[1],q=(0,r.useState)(!1),W=q[0],$=q[1],L=(0,r.useCallback)((function(n){V(n)}),[]),G=(0,r.useMemo)((function(){var n;return o&&(o.isRequired=j,n=(0,u.LT)(a({},v,o))),n}),[o,j]),J=(0,r.useMemo)((function(){return null!==M&&void 0!==M?M:G&&function(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];var r,o=e[0],i=o.target.value,u=G({inputs:a({},v,{value:i})});$(u),null===l||void 0===l||(r=l).call.apply(r,[null].concat(f(e)))}}),[M,l,G]),z=(0,r.useMemo)((function(){return i(c({postSet:function(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];var r,o;D(!0),null===B||void 0===B||(r=B).call.apply(r,[null].concat(f(e))),null===k||void 0===k||(o=k).call.apply(o,[null].concat(f(e)))},set:L,setType:w,valueKey:E},C))}),[B,k,C,L,E,w]),Q=(0,r.useMemo)((function(){return null!==T&&void 0!==T?T:o&&function(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];var r,i,u;null===(i=o.defaults)||void 0===i||null===(u=i.onSuccess)||void 0===u||u.call(null,{append:{}}),null===b||void 0===b||(r=b).call.apply(r,[null].concat(f(e)))}}),[T,o,b]);return(0,r.useEffect)((function(){var n,e=null!==(n=null===G||void 0===G?void 0:G.call(null,{inputs:a({},v,{value:_}),isIgnoreOnCallbacks:!0}))&&void 0!==n&&n;return null===p||void 0===p||p.call(null,{isValid:e}),g}),[]),(0,r.useImperativeHandle)(e,(function(){return{getIsChangedByUser:function(){return K},getValue:function(){return _},isValid:function(){return W},setValue:L}}),[_,K,W,L]),(0,r.cloneElement)(t,c({},U,a({onBlur:J,onChange:z,onFocus:Q,required:j},E,_)))}));b.defaultProps=m,b.displayName="InputWithRef";var g=b},7869:function(n,e,t){var r=t(5893),o=t(7294),i=t(8187);function u(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function l(n,e){if(null==n)return{};var t,r,o=function(n,e){if(null==n)return{};var t,r,o={},i=Object.keys(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||(o[t]=n[t]);return o}(n,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}function a(n,e){return function(n){if(Array.isArray(n))return n}(n)||function(n,e){var t=null==n?null:"undefined"!==typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=t){var r,o,i=[],u=!0,l=!1;try{for(t=t.call(n);!(u=(r=t.next()).done)&&(i.push(r.value),!e||i.length!==e);u=!0);}catch(a){l=!0,o=a}finally{try{u||null==t.return||t.return()}finally{if(l)throw o}}return i}}(n,e)||function(n,e){if(!n)return;if("string"===typeof n)return u(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return u(n,e)}(n,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(n){var e=function(n,e){if("object"!==s(n)||null===n)return n;var t=n[Symbol.toPrimitive];if(void 0!==t){var r=t.call(n,e||"default");if("object"!==s(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(n)}(n,"string");return"symbol"===s(e)?e:String(e)}var s=function(n){return n&&"undefined"!==typeof Symbol&&n.constructor===Symbol?"symbol":typeof n};var f={count:0,defaultMessageType:"info",onSet:void 0,usePlaceholder:!0},d=(0,o.forwardRef)((function(n,e){var t=n.count,u=void 0===t?f.count:t,s=n.defaultMessageType,d=void 0===s?f.defaultMessageType:s,p=n.onSet,v=n.usePlaceholder,y=void 0===v?f.usePlaceholder:v,m=(0,o.useState)({}),b=m[0],g=m[1],h=(0,o.useCallback)((function(n){return void 0!==b[n]}),[b]),j=(0,o.useCallback)((function(n,e){var t=0;g((function(r){r[n];var o=l(r,[n].map(c));return e&&(o[n]=e),t=Object.keys(o).length,o})),null===p||void 0===p||p.call(null,t)}),[p]),O=(0,o.useCallback)((function(n,e){var t=0,r=e?function(n,r){n[r]=e,t+=1}:void 0;g((function(e){var o={};return Object.keys(e).forEach((function(i){n.test(i)?null===r||void 0===r||r.call(null,o,i):(o[i]=e[i],t+=1)})),o})),null===p||void 0===p||p.call(null,t)}),[p]),S=(0,o.useMemo)((function(){var n=Object.entries(b),e=u>0,t=e?u:n.length,o=[];if(n.every((function(n){var e=a(n,2),u=e[0],l=e[1],c=l.children,s=l.type,f=void 0===s?d:s;return o.push((0,r.jsx)(i.Z,{type:f,children:c},"message-".concat(u))),o.length<t})),y&&e&&0===o.length)for(var l=u-o.length,c=0;c<l;c+=1)o.push((0,r.jsx)(i.Z,{sx:{visibility:"hidden"},text:"Placeholder"},"message-placeholder-".concat(c)));return o}),[u,d,y,b]);return(0,o.useImperativeHandle)(e,(function(){return{exists:h,setMessage:j,setMessageRe:O}}),[h,j,O]),(0,r.jsx)(r.Fragment,{children:S})}));d.defaultProps=f,d.displayName="MessageGroup",e.Z=d},8859:function(n,e,t){var r=t(7294),o=t(4390),i=t(6607),u=t(1770),l=t(2749);function a(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function c(n,e){return function(n){if(Array.isArray(n))return n}(n)||function(n,e){var t=null==n?null:"undefined"!==typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=t){var r,o,i=[],u=!0,l=!1;try{for(t=t.call(n);!(u=(r=t.next()).done)&&(i.push(r.value),!e||i.length!==e);u=!0);}catch(a){l=!0,o=a}finally{try{u||null==t.return||t.return()}finally{if(l)throw o}}return i}}(n,e)||function(n,e){if(!n)return;if("string"===typeof n)return a(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return a(n,e)}(n,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}e.Z=function(n,e){var t,a=c((0,l.Z)(!1),2),s=a[0],f=a[1],d=(0,r.useState)({}),p=d[0],v=d[1],y=(0,r.useCallback)((function(n,t){var r,o;null===e||void 0===e||null===(r=e.current)||void 0===r||null===(o=r.setMessage)||void 0===o||o.call(null,String(n),t)}),[e]),m=(0,r.useCallback)((function(n,t){var r,o;null===e||void 0===e||null===(r=e.current)||void 0===r||null===(o=r.setMessageRe)||void 0===o||o.call(null,n,t)}),[e]),b=(0,r.useCallback)((function(n,e){v((0,i.ZP)(n,e))}),[]),g=(0,r.useCallback)((function(n,e){v((0,i.Um)(n,e))}),[]),h=(0,r.useCallback)((function(n){y(n),b(n)}),[y,b]),j=(0,r.useCallback)((function(n){m(n),g(n)}),[m,g]),O=(0,r.useCallback)((function(n){return function(e){b(n,e)}}),[b]),S=(0,r.useCallback)((function(n){return function(e){var t=e.isValid;b(n,t)}}),[b]),w=(0,r.useCallback)((function(n){return function(){h(n)}}),[h]),x=(0,r.useCallback)((function(n){var r=n.body,i=n.getErrorMsg,l=n.msgKey,a=void 0===l?"api":l,c=n.method,s=n.setMsg,d=void 0===s?null===e||void 0===e||null===(t=e.current)||void 0===t?void 0:t.setMessage:s,p=n.successMsg,v=n.url;f(!0),o.Z.request({data:r,method:c,url:v}).then((function(){null===d||void 0===d||d.call(null,a,{children:p,type:"info"})})).catch((function(n){var e=(0,u.Z)(n);e.children=i(e.children),null===d||void 0===d||d.call(null,a,e)})).finally((function(){f(!1)}))}),[e,f]),A=(0,r.useMemo)((function(){return Object.values(p).some((function(n){return!n}))}),[p]);return{buildFinishInputTestBatchFunction:O,buildInputFirstRenderFunction:S,buildInputUnmountFunction:w,formValidity:p,isFormInvalid:A,isFormSubmitting:s,setFormValidity:v,setMessage:y,setMessageRe:m,setValidity:b,setValidityRe:g,submitForm:x,unsetKey:h,unsetKeyRe:j}}},1081:function(n,e,t){var r=t(7294);e.Z=function(){var n=(0,r.useRef)(!0);return n.current?(n.current=!1,!0):n.current}},6607:function(n,e,t){function r(n,e){(null==e||e>n.length)&&(e=n.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=n[t];return r}function o(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function i(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{},r=Object.keys(t);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})))),r.forEach((function(e){o(n,e,t[e])}))}return n}function u(n,e){if(null==n)return{};var t,r,o=function(n,e){if(null==n)return{};var t,r,o={},i=Object.keys(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||(o[t]=n[t]);return o}(n,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);for(r=0;r<i.length;r++)t=i[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}function l(n,e){return function(n){if(Array.isArray(n))return n}(n)||function(n,e){var t=null==n?null:"undefined"!==typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=t){var r,o,i=[],u=!0,l=!1;try{for(t=t.call(n);!(u=(r=t.next()).done)&&(i.push(r.value),!e||i.length!==e);u=!0);}catch(a){l=!0,o=a}finally{try{u||null==t.return||t.return()}finally{if(l)throw o}}return i}}(n,e)||function(n,e){if(!n)return;if("string"===typeof n)return r(n,e);var t=Object.prototype.toString.call(n).slice(8,-1);"Object"===t&&n.constructor&&(t=n.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return r(n,e)}(n,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(n){var e=function(n,e){if("object"!==c(n)||null===n)return n;var t=n[Symbol.toPrimitive];if(void 0!==t){var r=t.call(n,e||"default");if("object"!==c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(n)}(n,"string");return"symbol"===c(e)?e:String(e)}t.d(e,{Um:function(){return d}});var c=function(n){return n&&"undefined"!==typeof Symbol&&n.constructor===Symbol?"symbol":typeof n};var s=function(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];var r=l(e,4),o=r[1],i=r[2],u=r[3];void 0!==u&&(o[i]=u)},f=function(n,e){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=t.guard,o=void 0===r?function(){return!0}:r,l=t.set,c=void 0===l?s:l;return function(t){t[n];var r=i({},u(t,[n].map(a)));return o(t,n,e)&&c(t,r,n,e),r}},d=function(n,e){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=t.set,o=void 0===r?s:r;return function(t){var r={};return Object.keys(t).forEach((function(i){var u=i;n.test(i)?o(t,r,u,e):r[u]=t[u]})),r}};e.ZP=f}}]);