import{__exports as e}from"../../../_virtual/Button.js";import t from"react";import{p as o}from"../../prop-types/index.js";import{c as r}from"../../classnames/index.js";import"./utils.js";import"./CloseButton.js";import{__exports as n}from"../../../_virtual/utils.js";import{__exports as l}from"../../../_virtual/CloseButton.js";!function(e){function a(e){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var u=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==a(e)&&"function"!=typeof e)return{default:e};var o=b(t);if(o&&o.has(e))return o.get(e);var r={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var u=n?Object.getOwnPropertyDescriptor(e,l):null;u&&(u.get||u.set)?Object.defineProperty(r,l,u):r[l]=e[l]}r.default=e,o&&o.set(e,r);return r}(t),i=p(o),f=p(r),c=n,s=p(l),d=["active","aria-label","block","className","close","cssModule","color","outline","size","tag","innerRef"];function p(e){return e&&e.__esModule?e:{default:e}}function b(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,o=new WeakMap;return(b=function(e){return e?o:t})(e)}function y(){return y=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var r in o)Object.prototype.hasOwnProperty.call(o,r)&&(e[r]=o[r])}return e},y.apply(this,arguments)}function m(e,t){if(null==e)return{};var o,r,n=function(e,t){if(null==e)return{};var o,r,n={},l=Object.keys(e);for(r=0;r<l.length;r++)o=l[r],t.indexOf(o)>=0||(n[o]=e[o]);return n}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)o=l[r],t.indexOf(o)>=0||Object.prototype.propertyIsEnumerable.call(e,o)&&(n[o]=e[o])}return n}var v={active:i.default.bool,"aria-label":i.default.string,block:i.default.bool,children:i.default.node,className:i.default.string,cssModule:i.default.object,close:i.default.bool,color:i.default.string,disabled:i.default.bool,innerRef:i.default.oneOfType([i.default.object,i.default.func,i.default.string]),onClick:i.default.func,outline:i.default.bool,size:i.default.string,tag:c.tagPropType};function j(e){var t=(0,u.useCallback)((function(t){if(!e.disabled)return e.onClick?e.onClick(t):void 0;t.preventDefault()}),[e.onClick,e.disabled]),o=e.active,r=e["aria-label"],n=e.block,l=e.className,a=e.close,i=e.cssModule,p=e.color,b=e.outline,v=e.size,j=e.tag,O=e.innerRef,g=m(e,d);if(a)return u.default.createElement(s.default,g);var k="btn".concat(b?"-outline":"","-").concat(p),_=(0,c.mapToCssModules)((0,f.default)(l,"btn",k,!!v&&"btn-".concat(v),!!n&&"d-block w-100",{active:o,disabled:e.disabled}),i);return g.href&&"button"===j&&(j="a"),u.default.createElement(j,y({type:"button"===j&&g.onClick?"button":void 0},g,{className:_,ref:O,onClick:t,"aria-label":r}))}j.propTypes=v,j.defaultProps={color:"secondary",tag:"button"};var O=j;e.default=O}(e);
//# sourceMappingURL=Button.js.map
