"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[560],{2545:function(e,t,r){var n=r(5893),o=r(7294),l=r(157);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function s(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,l=[],i=!0,u=!1;try{for(r=r.call(e);!(i=(n=r.next()).done)&&(l.push(n.value),!t||l.length!==t);i=!0);}catch(c){u=!0,o=c}finally{try{i||null==r.return||r.return()}finally{if(u)throw o}}return l}}(e,t)||y(e,t)||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 f(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||y(e)||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 y(e,t){if(e){if("string"===typeof e)return i(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(r):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}}var p=(0,o.forwardRef)((function(e,t){var r=e.children,i=e.contentContainerProps,u=e.dialogProps,y=e.onSubmitAppend,p=e.proceedButtonProps,d=e.scrollBoxProps,b=e.scrollContent,h=a(e,["children","contentContainerProps","dialogProps","onSubmitAppend","proceedButtonProps","scrollBoxProps","scrollContent"]),m=(0,o.useMemo)((function(){return c({},i,{component:"form",onSubmit:function(){for(var e=arguments.length,t=new Array(e),r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);r0}),[y.length]),b=(0,o.useMemo)((function(){return f.length>1}),[f.length]),h=(0,o.useCallback)((function(e){var t=e.confirmDialogProps,r=void 0===t?{}:t,o=e.formSummaryProps,l=void 0===o?{}:o,u=e.getConfirmDialogTitle,s=e.onProceedAppend,f=e.renderEntry;return c({actionProceedText:"Delete",content:(0,n.jsx)(i.Z,c({entries:a,maxDepth:0,renderEntry:f},l)),onProceedAppend:s,proceedColour:"red",titleText:u(y.length)},r)}),[a,y.length]),m=(0,o.useCallback)((function(e){return a[e]}),[a]),g=(0,o.useCallback)((function(){return s({})}),[]),v=(0,o.useCallback)((function(e){return s(f.reduce((function(t,r){return e&&(t[r]=e),t}),{}))}),[f]),O=(0,o.useCallback)((function(e,t){return s((0,l.ZP)(e,t||void 0))}),[]);return{buildDeleteDialogProps:h,checklist:a,checks:y,getCheck:m,hasAllChecks:p,hasChecks:d,multipleItems:b,resetChecks:g,setAllChecks:v,setCheck:O}}},6632:function(e,t,r){var n=r(7294);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function l(e){for(var t=1;t=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}t.Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.actionProceedText,r=void 0===t?"":t,o=e.content,u=void 0===o?"":o,c=e.titleText,a=void 0===c?"":c,s=i(e,["actionProceedText","content","titleText"]);return(0,n.useState)(l({actionProceedText:r,content:u,titleText:a},s))}}}]);