"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
exports.__esModule = true;
exports.SingleCollectionBulkActionToolbar = void 0;
var _react = _interopRequireDefault(require("react"));
var _react2 = require("@wix/bex-core/react");
var _mobxReactLite = require("mobx-react-lite");
var _jsxFileName = "/home/builduser/work/843658b9f44192f0/packages/cairo/dist/cjs/components/BulkAction/SingleCollectionBulkActionToolbar.tsx";
function _SingleCollectionBulkActionToolbar(props) {
  const {
    state,
    bulkActionToolbar
  } = props;
  const {
    collection,
    bulk
  } = state;
  const {
    result: {
      total
    },
    bulkSelect
  } = collection;
  const {
    selectedValues,
    uncheckedInCurrentCollection: uncheckedValues,
    allSelected
  } = bulkSelect;
  const {
    modals: {
      openModal,
      openConfirmModal
    }
  } = bulk;
  return /*#__PURE__*/_react.default.createElement(_react2.CollectionProvider, {
    value: collection,
    __self: this,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 37,
      columnNumber: 5
    }
  }, bulkActionToolbar({
    query: collection.result.originQuery,
    selectedValues,
    uncheckedValues,
    allSelected,
    total,
    openModal,
    clearSelection: collection.bulkSelect.resetToDefaults,
    openConfirmModal
  }));
}
const SingleCollectionBulkActionToolbar = exports.SingleCollectionBulkActionToolbar = (0, _mobxReactLite.observer)(_SingleCollectionBulkActionToolbar);
//# sourceMappingURL=SingleCollectionBulkActionToolbar.js.map