import{__exports as t}from"../../../_virtual/UncontrolledAccordion.js";import e from"react";import{p as r}from"../../prop-types/index.js";import"./utils.js";import"./Accordion.js";import{__exports as n}from"../../../_virtual/utils.js";import{__exports as o}from"../../../_virtual/Accordion.js";!function(t){function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var u=function(t,e){if(!e&&t&&t.__esModule)return t;if(null===t||"object"!==a(t)&&"function"!=typeof t)return{default:t};var r=s(e);if(r&&r.has(t))return r.get(t);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in t)if("default"!==u&&Object.prototype.hasOwnProperty.call(t,u)){var l=o?Object.getOwnPropertyDescriptor(t,u):null;l&&(l.get||l.set)?Object.defineProperty(n,u,l):n[u]=t[u]}n.default=t,r&&r.set(t,n);return n}(e),l=p(r),i=n,f=p(o),c=["defaultOpen","stayOpen"];function p(t){return t&&t.__esModule?t:{default:t}}function s(t){if("function"!=typeof WeakMap)return null;var e=new WeakMap,r=new WeakMap;return(s=function(t){return t?r:e})(t)}function y(){return y=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},y.apply(this,arguments)}function d(t){return function(t){if(Array.isArray(t))return v(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||m(t)||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 b(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==r)return;var n,o,a=[],u=!0,l=!1;try{for(r=r.call(t);!(u=(n=r.next()).done)&&(a.push(n.value),!e||a.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{u||null==r.return||r.return()}finally{if(l)throw o}}return a}(t,e)||m(t,e)||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 m(t,e){if(t){if("string"==typeof t)return v(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?v(t,e):void 0}}function v(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function O(t,e){if(null==t)return{};var r,n,o=function(t,e){if(null==t)return{};var r,n,o={},a=Object.keys(t);for(n=0;n<a.length;n++)r=a[n],e.indexOf(r)>=0||(o[r]=t[r]);return o}(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(n=0;n<a.length;n++)r=a[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(o[r]=t[r])}return o}var j={tag:i.tagPropType,className:l.default.string,cssModule:l.default.object,innerRef:l.default.oneOfType([l.default.object,l.default.string,l.default.func]),children:l.default.node,defaultOpen:l.default.oneOfType([l.default.array,l.default.string]),stayOpen:l.default.bool};function g(t){var e=t.defaultOpen,r=t.stayOpen,n=O(t,c),o=b((0,u.useState)(e||(r?[]:void 0)),2),a=o[0],l=o[1];return u.default.createElement(f.default,y({},n,{open:a,toggle:function(t){r?a.includes(t)?l(a.filter((function(e){return e!==t}))):l([].concat(d(a),[t])):l(a===t?void 0:t)}}))}g.propTypes=j,g.defaultProps={tag:"div"};var h=g;t.default=h}(t);
//# sourceMappingURL=UncontrolledAccordion.js.map
