'use strict';

var React = require('react');
var CreateChannel_context = require('../../CreateChannelProvider-71e1e6d6.js');
var CreateChannel_components_InviteUsers = require('./InviteUsers.js');
var CreateChannel_components_SelectChannelType = require('./SelectChannelType.js');
require('../../sendbirdSelectors.js');
require('../../topics-a755c9c6.js');
require('../../utils-bf57a41a.js');
require('../../useSendbirdStateContext.js');
require('../../withSendbird.js');
require('../../_rollupPluginBabelHelpers-4265e501.js');
require('../../tslib.es6-ba69891c.js');
require('../../LocalizationContext-da62a103.js');
require('../../stringSet-857a128c.js');
require('../../index-25336220.js');
require('../../ui/Modal.js');
require('react-dom');
require('../../index-32562627.js');
require('../../index-05692021.js');
require('../../index-089e0fba.js');
require('prop-types');
require('../../ui/Icon.js');
require('../../ui/IconButton.js');
require('../../ui/UserListItem.js');
require('../../UserProfileContext-891590a7.js');
require('../../ui/Avatar.js');
require('../../ui/ImageRenderer.js');
require('../../uuid-49679ac2.js');
require('../../ui/MutedAvatarOverlay.js');
require('../../ui/Checkbox.js');
require('../../ui/UserProfile.js');
require('../../ui/ContextMenu.js');
require('../../ui/SortByRow.js');
require('../../index-06c3dca9.js');

function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }

var React__default = /*#__PURE__*/_interopDefaultLegacy(React);

var CreateChannel = function CreateChannel(props) {
  var _onCancel = props.onCancel,
      renderStepOne = props.renderStepOne;

  var _a = CreateChannel_context.useCreateChannelContext(),
      step = _a.step,
      setStep = _a.setStep,
      userListQuery = _a.userListQuery;

  return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, step === 0 && ((renderStepOne === null || renderStepOne === void 0 ? void 0 : renderStepOne()) || /*#__PURE__*/React__default["default"].createElement(CreateChannel_components_SelectChannelType, {
    onCancel: _onCancel
  })), step === 1 && /*#__PURE__*/React__default["default"].createElement(CreateChannel_components_InviteUsers, {
    userListQuery: userListQuery,
    onCancel: function onCancel() {
      setStep(0);

      _onCancel();
    }
  }));
};

module.exports = CreateChannel;
//# sourceMappingURL=CreateChannelUI.js.map
