"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require('./../../ext-esm/tslib/tslib.es6.js'),r=require("react/jsx-runtime"),i=require("react"),n=require("../RadioAndCheckboxGroup/RadioAndCheckboxGroup.js"),o=require("../Checkbox/Checkbox.js"),t=function(e,r){return!!(null==r?void 0:r.includes(e))};exports.CheckboxGroup=function(a){var s=a.onChange,c=a.size,u=void 0===c?"medium":c,d=a.spacing,p=void 0===d?"normal":d,l=a.direction,_=void 0===l?"vertical":l,h=e.__rest(a,["onChange","size","spacing","direction"]),v=i.useCallback((function(r,i){return void 0===i&&(i=[]),function(n){for(var o=[],t=1;t<arguments.length;t++)o[t-1]=arguments[t];if(s){var a=n?e.__spreadArray(e.__spreadArray([],i,!0),[r],!1):i.filter((function(e){return e!==r}));s.apply(void 0,e.__spreadArray([a],o,!1))}}}),[s]);return r.jsx(n.RadioAndCheckboxGroup,e.__assign({},h,{size:u,spacing:p,direction:_,component:o.Checkbox,getOnChangeHandler:v,getOptionChecked:t}))};
