import{_ as __rest,a as __assign}from"./tslib.es6-bjGg6Bxl.js";import React__default from"react";import{B as Button}from"./Button.component-Ck0-XKMD.js";import{B as ButtonRow}from"./ButtonRow.component-CgfANnke.js";var modalfooterstyles="\n\tjn-flex\n\tjn-flex-row\n\tjn-border-t\n\tjn-border-theme-background-lvl-4\n\tjn-py-2\n\tjn-px-8\n",defaultmodalfooterstyles="\n\tjn-justify-end\n\tjn-gap-3.5\n",ModalFooter=function(a){var b=a.children,c=void 0===b?null:b,d=a.confirmButtonLabel,e=void 0===d?"":d,f=a.cancelButtonLabel,g=void 0===f?"":f,h=a.confirmButtonIcon,i=void 0===h?null:h,j=a.cancelButtonIcon,k=void 0===j?null:j,l=a.onConfirm,m=a.onCancel,n=a.className,o=void 0===n?"":n,p=__rest(a,["children","confirmButtonLabel","cancelButtonLabel","confirmButtonIcon","cancelButtonIcon","onConfirm","onCancel","className"]),q=function(a){m&&m(a)};return React__default.createElement("div",__assign({className:"juno-modal-footer ".concat(modalfooterstyles," ").concat(c?null:defaultmodalfooterstyles," ").concat(o," ")},p),c?c:e||l?(React__default.createElement(ButtonRow,null,React__default.createElement(Button,{variant:"primary",label:e||"Confirm",icon:i||void 0,onClick:function(a){l&&l(a)}}),React__default.createElement(Button,{variant:"subdued",label:g||"Cancel",icon:k||void 0,onClick:q}))):(React__default.createElement(ButtonRow,null,React__default.createElement(Button,{variant:"subdued",onClick:q,label:g||"Close",icon:k||void 0}))))};export{ModalFooter as M};