"use strict";

require("core-js/modules/es.object.define-property.js");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.Security = void 0;
var _i18n = require("../../../i18n");
var _checkbox = require("../../checkbox");
var _dropMenu = require("../../drop-menu");
var _type = require("../../icon/type");
var _tooltip = require("../../tooltip");
var _item = require("../item");
var _jsxRuntime = require("react/jsx-runtime");
var Security = exports.Security = function Security(_ref) {
  var id = _ref.id,
    order = _ref.order;
  var t = (0, _i18n.useI18n)();
  var title = t('fmt_screenshare_controlbar_button_security');
  var tooltip = t('fmt_screenshare_controlbar_button_security');
  var SecurityOptions = function SecurityOptions() {
    var allActions = [{
      title: /*#__PURE__*/(0, _jsxRuntime.jsx)(_checkbox.FcrCheckbox, {
        checked: false,
        label: t('fmt_screenshare_controlbar_security_list_lock'),
        styleType: "white"
      }),
      key: 'lock_room',
      type: 'primary',
      onButtonClick: function onButtonClick() {}
    }, {
      title: /*#__PURE__*/(0, _jsxRuntime.jsx)(_checkbox.FcrCheckbox, {
        checked: false,
        label: t('fmt_security_options_activatewaitingroom'),
        styleType: "white"
      }),
      key: 'enable_waiting_room',
      type: 'disabled',
      onButtonClick: function onButtonClick() {},
      classNames: 'room-control-drop-with-under-line'
    }, {
      title: t('fmt_screenshare_options_allow'),
      key: 'allow_attendee_title',
      type: 'title'
    }, {
      title: /*#__PURE__*/(0, _jsxRuntime.jsx)(_checkbox.FcrCheckbox, {
        checked: false,
        label: t('fmt_screenshare_controlbar_security_list_participant_unmute'),
        styleType: "white"
      }),
      key: 'unmute_yourself',
      type: 'primary',
      onButtonClick: function onButtonClick() {}
    }, {
      title: /*#__PURE__*/(0, _jsxRuntime.jsx)(_checkbox.FcrCheckbox, {
        checked: false,
        label: t('fmt_screenshare_controlbar_security_list_participant_changeName'),
        styleType: "white"
      }),
      key: 'rename',
      type: 'disabled',
      onButtonClick: function onButtonClick() {}
    }, {
      title: /*#__PURE__*/(0, _jsxRuntime.jsx)(_checkbox.FcrCheckbox, {
        checked: false,
        label: t('fmt_security_start_video'),
        styleType: "white"
      }),
      key: 'start_video',
      type: 'primary',
      onButtonClick: function onButtonClick() {},
      classNames: 'room-control-drop-with-under-line'
    }];
    return /*#__PURE__*/(0, _jsxRuntime.jsx)(_dropMenu.FcrDropMenu, {
      options: allActions
    });
  };
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_tooltip.FcrToolTip, {
    content: tooltip,
    children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_item.ActionBarItemWithPopover, {
      popoverProps: {
        content: /*#__PURE__*/(0, _jsxRuntime.jsx)(SecurityOptions, {}),
        overlayClassName: 'attendee__footer-more-actions',
        overlayInnerStyle: {
          boxShadow: 'none',
          border: 'none',
          minWidth: '256px',
          width: 'auto',
          maxWidth: '300px'
        }
      },
      id: id,
      order: order,
      onClick: function onClick() {},
      icon: _type.FcrIconType.FCR_SECURITY,
      title: title,
      iconColors: {
        iconPrimary: 'var(--fcr_web_ui_scene_mainicon1)'
      }
    })
  });
};