"use strict";(self.webpackChunkportal_ui=self.webpackChunkportal_ui||[]).push([[2112],{32112:function(e,n,t){t.r(n);var a=t(29439),o=t(72791),r=t(51691),i=t(21435),c=t(61889),s=t(9505),l=t(2148),u=t(38734),p=t(87995),f=t(25469),d=t(80184);n.default=function(e){var n=e.deleteOpen,t=e.selectedPVC,m=e.closeDeleteModalAndRefresh,h=(0,f.TL)(),C=(0,o.useState)(""),x=(0,a.Z)(C,2),v=x[0],P=x[1],Z=(0,s.Z)((function(){return m(!0)}),(function(e){return h((0,p.Ih)(e))})),b=(0,a.Z)(Z,2),j=b[0],T=b[1];return(0,d.jsx)(l.Z,{title:"Delete PVC",confirmText:"Delete",isOpen:n,titleIcon:(0,d.jsx)(u.NvT,{}),isLoading:j,onConfirm:function(){v===t.name?T("DELETE","/api/v1/namespaces/".concat(t.namespace,"/tenants/").concat(t.tenant,"/pvc/").concat(t.name)):h((0,p.Ih)({errorMessage:"PVC name is incorrect",detailedError:""}))},onClose:function(){return m(!1)},confirmButtonProps:{disabled:v!==t.name||j},confirmationContent:(0,d.jsxs)(r.Z,{children:["To continue please type ",(0,d.jsx)("b",{children:t.name})," in the box.",(0,d.jsx)(c.ZP,{item:!0,xs:12,children:(0,d.jsx)(i.Z,{id:"retype-PVC",name:"retype-PVC",onChange:function(e){P(e.target.value)},label:"",value:v})})]})})}}}]);
//# sourceMappingURL=2112.218ae789.chunk.js.map