!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("openstack-uicore-foundation",[],t):"object"==typeof exports?exports["openstack-uicore-foundation"]=t():e["openstack-uicore-foundation"]=t()}(this,(()=>(()=>{"use strict";var e={5814:e=>{e.exports=require("@mui/icons-material")},8619:e=>{e.exports=require("@mui/material")},9825:e=>{e.exports=require("prop-types")},2015:e=>{e.exports=require("react")}},t={};function o(n){var r=t[n];if(void 0!==r)return r.exports;var i=t[n]={exports:{}};return e[n](i,i.exports,o),i.exports}(()=>{o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t}})(),(()=>{o.d=(e,t)=>{for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}})(),(()=>{o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t)})(),(()=>{o.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}})();var n={};o.r(n),o.d(n,{default:()=>m});var r=o(2015),i=o.n(r),a=o(9825),c=o.n(a),l=o(8619),u=o(5814);const p={warning:i().createElement(u.Warning,{color:"warning"}),success:i().createElement(u.CheckCircle,{color:"success"}),error:i().createElement(u.Error,{color:"error"}),info:i().createElement(u.Info,{color:"info"})},s=({open:e,title:t,text:o,iconType:n="",onConfirm:r,onCancel:a,confirmButtonText:c="Confirm",confirmButtonColor:u="primary",cancelButtonText:s="Cancel",cancelButtonColor:m="primary"})=>i().createElement(l.Dialog,{open:e,onClose:a},i().createElement(l.DialogTitle,{sx:{p:2},component:"div"},i().createElement(l.Typography,{variant:"h5"},t)),i().createElement(l.Divider,null),i().createElement(l.DialogContent,{sx:{p:2}},i().createElement("div",{style:{display:"flex",alignItems:"center"}},p[n]&&i().createElement("div",{style:{marginRight:10}},p[n]),i().createElement(l.Typography,{variant:"body1"},o))),i().createElement(l.Divider,{sx:{margin:"10px 0px 10px 0px"}}),i().createElement(l.DialogActions,null,i().createElement(l.Button,{fullWidth:!0,onClick:a,color:m,variant:"outlined",sx:{whiteSpace:"nowrap",minWidth:100}},s),i().createElement(l.Button,{fullWidth:!0,onClick:r,color:u,variant:"contained",sx:{whiteSpace:"nowrap",minWidth:100}},c)));s.propTypes={open:c().bool,title:c().string.isRequired,text:c().string.isRequired,iconType:c().string,onConfirm:c().func.isRequired,onCancel:c().func.isRequired,confirmButtonText:c().string,confirmButtonColor:c().string,cancelButtonText:c().string,cancelButtonColor:c().string},s.defaultProps={open:!1,iconType:"warning",confirmButtonText:"Confirm",confirmButtonColor:"primary",cancelButtonText:"Cancel",cancelButtonColor:"default"};const m=s;return n})()));
//# sourceMappingURL=confirm-dialog.js.map