diff --git a/css/_contact_list.scss b/css/_contact_list.scss index 1110fe457..889bad79b 100644 --- a/css/_contact_list.scss +++ b/css/_contact_list.scss @@ -13,11 +13,6 @@ .clickable { cursor: pointer; } - - .icon-security, - .icon-security-locked { - font-size: 16px; - } } #contacts { diff --git a/css/main.scss b/css/main.scss index 3d78bb622..a9c503650 100644 --- a/css/main.scss +++ b/css/main.scss @@ -65,7 +65,6 @@ @import 'components/button-control'; @import 'components/input-control'; @import 'components/input-slider'; -@import "modals/invite/invite"; @import "connection-info"; @import 'aui-components/dropdown'; @import '404'; diff --git a/css/modals/invite/_invite.scss b/css/modals/invite/_invite.scss deleted file mode 100644 index 4e7f297ce..000000000 --- a/css/modals/invite/_invite.scss +++ /dev/null @@ -1,96 +0,0 @@ -/* - * Sets the default cursor the remove password link. The link doesn't use - * the href attribute, so we need to set the cursor manually. - */ -#inviteDialogRemovePassword { - cursor: hand; -} - -.invite-dialog { - .dial-in-numbers { - .dial-in-numbers-conference-id { - color: orange; - margin-left: 3px; - } - - /* - * dial-in-numbers-copy styling is needed for the feature of copying - * text to the clipboard. The styling keeps the element invisible - * to the user but still programmatically selectable for copying. - */ - .dial-in-numbers-copy { - opacity: 0; - pointer-events: none; - position: fixed; - -webkit-user-select: text; - user-select: text; - } - - .is-disabled, - .is-loading { - .dial-in-numbers-trigger-icon { - display: none; - } - } - } - - .form-control { - padding: 0; - - &__container { - /** - * Ensure contents display in a line and vertically centered. - */ - align-items: center; - - button { - font-size: $modalButtonFontSize; - } - } - - &__input-container { - flex: 1; - margin-right: 10px; - - .dropdown-button-trigger { - text-align: left; - } - } - } - - .inviteLink { - color: $readOnlyInputColor; - } - - .lock-state { - display: flex; - } - - .password-overview { - margin-top: 10px; - - .form-control { - margin-top: 10px; - } - - .password-overview-status, - .remove-password { - display: flex; - justify-content: space-between; - } - - .password-overview-toggle-edit, - .remove-password-link { - cursor: pointer; - text-decoration: none; - } - - .remove-password { - margin-top: 15px; - } - } - - .remove-password-current { - color: $inputControlEmColor; - } -} diff --git a/interface_config.js b/interface_config.js index 38fbef8e6..c5dc3b57f 100644 --- a/interface_config.js +++ b/interface_config.js @@ -40,7 +40,7 @@ var interfaceConfig = { TOOLBAR_BUTTONS: [ // main toolbar - 'microphone', 'camera', 'desktop', 'invite', 'fullscreen', 'fodeviceselection', 'hangup', + 'microphone', 'camera', 'desktop', 'fullscreen', 'fodeviceselection', 'hangup', // extended toolbar 'profile', 'contacts', 'info', 'chat', 'recording', 'etherpad', 'sharedvideo', 'settings', 'raisehand', 'videoquality', 'filmstrip' ], @@ -49,7 +49,7 @@ var interfaceConfig = { * Main Toolbar Buttons * All of them should be in TOOLBAR_BUTTONS */ - MAIN_TOOLBAR_BUTTONS: [ 'microphone', 'camera', 'desktop', 'invite', 'fullscreen', 'fodeviceselection', 'hangup' ], + MAIN_TOOLBAR_BUTTONS: [ 'microphone', 'camera', 'desktop', 'fullscreen', 'fodeviceselection', 'hangup' ], SETTINGS_SECTIONS: [ 'language', 'devices', 'moderator' ], INVITE_OPTIONS: [ 'invite', 'dialout', 'addtocall' ], diff --git a/lang/main.json b/lang/main.json index 9d90574a8..39cf870b2 100644 --- a/lang/main.json +++ b/lang/main.json @@ -103,7 +103,6 @@ "videomute": "Start / Stop camera", "authenticate": "Authenticate", "lock": "Lock / Unlock room", - "invite": "Share the link", "chat": "Open / Close chat", "etherpad": "Open / Close shared document", "sharedvideo": "Share a YouTube video", @@ -228,7 +227,6 @@ "suboptimalExperienceDescription": "Eer... we are afraid your experience with __appName__ isn't going to be that great here. We are looking for ways to improve this but, until then, please try using one of the fully supported browsers." }, "dialog": { - "add": "Add", "allow": "Allow", "kickMessage": "Ouch! You have been kicked out of the meet!", "popupErrorTitle": "Pop-up blocked", @@ -243,7 +241,6 @@ "copy": "Copy", "contactSupport": "Contact support", "error": "Error", - "createPassword": "Create password", "detectext": "Error when trying to detect desktopsharing extension.", "failedpermissions": "Failed to obtain permissions to use the local microphone and/or camera.", "conferenceReloadTitle": "Unfortunately, something went wrong.", @@ -294,10 +291,6 @@ "Save": "Save", "recording": "Recording", "recordingToken": "Enter recording token", - "passwordCheck": "Are you sure you would like to remove your password?", - "passwordMsg": "Set a password to lock your room", - "shareLink": "Share the link to the call", - "yourPassword": "Enter new password", "Back": "Back", "serviceUnavailable": "Service unavailable", "gracefulShutdown": "Our service is currently down for maintenance. Please try again later.", @@ -468,19 +461,6 @@ "selectADevice": "Select a device", "testAudio": "Test sound" }, - "invite": { - "addPassword": "Add password", - "callNumber": "Call __number__", - "enterID": "Enter Meeting ID: __conferenceID__ following by # to dial in from a phone", - "howToDialIn": "To dial in, use one of the following numbers and meeting ID", - "hidePassword": "Hide password", - "inviteTo": "Invite people to __conferenceName__", - "invitedYouTo": "__userName__ has invited you to the __inviteURL__ conference", - "invitePeople": "Invite", - "locked": "This call is locked. New callers must have the link and enter the password to join.", - "showPassword": "Show password", - "unlocked": "This call is unlocked. Any new caller with the link may join the call." - }, "videoStatus": { "callQuality": "Call Quality", "hd": "HD", @@ -500,7 +480,7 @@ }, "dialOut": { "dial": "Dial", - "dialOut": "Call a #", + "dialOut": "Call a number", "statusMessage": "is now __status__", "enterPhone": "Enter phone number", "phoneNotAllowed": "Oh, we don't support that destination yet! Sorry!" @@ -533,6 +513,7 @@ "veryGood": "Very Good" }, "info": { + "addPassword": "Add password", "cancelPassword": "Cancel password", "conferenceURL": "Link: __url__", "country": "Country", diff --git a/react/features/invite/actions.js b/react/features/invite/actions.js index 3ef96fad4..71bd3bcca 100644 --- a/react/features/invite/actions.js +++ b/react/features/invite/actions.js @@ -1,25 +1,13 @@ // @flow -import { openDialog } from '../../features/base/dialog'; - import { SET_INFO_DIALOG_VISIBILITY, UPDATE_DIAL_IN_NUMBERS_FAILED, UPDATE_DIAL_IN_NUMBERS_SUCCESS } from './actionTypes'; -import { InviteDialog } from './components'; declare var $: Function; -/** - * Opens the Invite Dialog. - * - * @returns {Function} - */ -export function openInviteDialog() { - return openDialog(InviteDialog); -} - /** * Opens the inline conference info dialog. * diff --git a/react/features/invite/components/AddPasswordForm.js b/react/features/invite/components/AddPasswordForm.js deleted file mode 100644 index bd05dd3d4..000000000 --- a/react/features/invite/components/AddPasswordForm.js +++ /dev/null @@ -1,199 +0,0 @@ -import Button from '@atlaskit/button'; -import { FieldTextStateless as TextField } from '@atlaskit/field-text'; -import PropTypes from 'prop-types'; -import React, { Component } from 'react'; -import { connect } from 'react-redux'; - -import { setPassword } from '../../base/conference'; -import { translate } from '../../base/i18n'; - -/** - * A React {@code Component} for locking a JitsiConference with a password. - */ -class AddPasswordForm extends Component { - /** - * {@code AddPasswordForm}'s property types. - * - * @static - */ - static propTypes = { - /** - * The JitsiConference on which to lock and set a password. - * - * @type {JitsiConference} - */ - conference: PropTypes.object, - - /** - * Invoked to set a password on the conference. - */ - dispatch: PropTypes.func, - - /** - * Invoked to obtain translated strings. - */ - t: PropTypes.func - }; - - /** - * Initializes a new {@code AddPasswordForm} instance. - * - * @param {Object} props - The read-only properties with which the new - * instance is to be initialized. - */ - constructor(props) { - super(props); - - this.state = { - /** - * The current value to display in {@code AddPasswordForm} - * component's input field. The value is also used as the desired - * new password when creating a {@code setPassword} action. - * - * @type {string} - */ - password: '' - }; - - /** - * The internal reference to the React {@code component} for entering a - * password. - * - * @private - * @type {ReactComponent} - */ - this._inputComponent = null; - - // Bind event handlers so they are only bound once for every instance. - this._onKeyDown = this._onKeyDown.bind(this); - this._onPasswordChange = this._onPasswordChange.bind(this); - this._onSubmit = this._onSubmit.bind(this); - this._setInput = this._setInput.bind(this); - } - - /** - * Directly bind a handler to the input element. This is done in order to - * intercept enter presses so any outer forms do not become submitted. - * Atlaskit Button does not expose a way to hook onto keydown events. - * - * @inheritdoc - */ - componentDidMount() { - this._inputComponent.input.onkeydown = this._onKeyDown; - } - - /** - * Remove any handlers set directly on DOM elements. - * - * @inheritdoc - */ - componentWillUnmount() { - this._inputComponent.input.onkeydown = null; - } - - /** - * Implements React's {@link Component#render()}. - * - * @inheritdoc - * @returns {ReactElement} - */ - render() { - const { t } = this.props; - - return ( -
-
-
- -
- -
-
- ); - } - - /** - * Mimics form behavior by listening for enter key press and submitting the - * entered password. - * - * @param {Object} event - DOM Event for keydown. - * @private - * @returns {void} - */ - _onKeyDown(event) { - event.stopPropagation(); - - if (event.keyCode === /* Enter */ 13) { - this._onSubmit(); - } - } - - /** - * Updates the internal state of the entered password. - * - * @param {Object} event - DOM Event for value change. - * @private - * @returns {void} - */ - _onPasswordChange(event) { - this.setState({ password: event.target.value }); - } - - /** - * Dispatches a request to lock the conference with a password. - * - * @private - * @returns {void} - */ - _onSubmit() { - if (!this.state.password) { - return; - } - - const { conference } = this.props; - - this.props.dispatch(setPassword( - conference, - conference.lock, - this.state.password - )); - - this.setState({ password: '' }); - } - - /** - * Sets the instance variable for the React Component used for entering a - * password. - * - * @param {Object} inputComponent - The React Component for the input - * field. - * @private - * @returns {void} - */ - _setInput(inputComponent) { - if (inputComponent !== this._inputComponent) { - this._inputComponent = inputComponent; - } - } -} - -export default translate(connect()(AddPasswordForm)); diff --git a/react/features/invite/components/DialInNumbersForm.js b/react/features/invite/components/DialInNumbersForm.js deleted file mode 100644 index b9749b660..000000000 --- a/react/features/invite/components/DialInNumbersForm.js +++ /dev/null @@ -1,406 +0,0 @@ -import Button from '@atlaskit/button'; -import DropdownMenu, { - DropdownItem, DropdownItemGroup } from '@atlaskit/dropdown-menu'; -import PropTypes from 'prop-types'; -import React, { Component } from 'react'; -import { connect } from 'react-redux'; - -import { translate } from '../../base/i18n'; -import { getLocalParticipant } from '../../base/participants'; - -import { updateDialInNumbers } from '../actions'; - -const logger = require('jitsi-meet-logger').getLogger(__filename); - -/** - * React {@code Component} responsible for fetching and displaying telephone - * numbers for dialing into a conference. Also supports copying a selected - * dial-in number to the clipboard. - * - * @extends Component - */ -class DialInNumbersForm extends Component { - /** - * {@code DialInNumbersForm}'s property types. - * - * @static - */ - static propTypes = { - /** - * The redux state representing the dial-in numbers feature. - */ - _dialIn: PropTypes.object, - - /** - * The display name of the local user. - */ - _localUserDisplayName: PropTypes.string, - - /** - * Invoked to send an ajax request for dial-in numbers. - */ - dispatch: PropTypes.func, - - /** - * The URL of the conference into which this {@code DialInNumbersForm} - * is inviting the local participant. - */ - inviteURL: PropTypes.string, - - /** - * Invoked to obtain translated strings. - */ - t: PropTypes.func - }; - - /** - * Initializes a new {@code DialInNumbersForm} instance. - * - * @param {Object} props - The read-only properties with which the new - * instance is to be initialized. - */ - constructor(props) { - super(props); - - this.state = { - /** - * Whether or not the dropdown should be open. - * - * @type {boolean} - */ - isDropdownOpen: false, - - /** - * The dial-in number to display as currently selected in the - * dropdown. The value should be an object which has two key/value - * pairs, content and number. The value of "content" will display in - * the dropdown while the value of "number" is a substring of - * "content" which will be copied to clipboard. - * - * @type {object} - */ - selectedNumber: null - }; - - /** - * The internal reference to the DOM/HTML element backing the React - * {@code Component} text area. It is necessary for the implementation - * of copying to the clipboard. - * - * @private - * @type {HTMLTextAreaElement} - */ - this._copyElement = null; - - // Bind event handlers so they are only bound once for every instance. - this._onCopyClick = this._onCopyClick.bind(this); - this._onOpenChange = this._onOpenChange.bind(this); - this._onSelect = this._onSelect.bind(this); - this._setCopyElement = this._setCopyElement.bind(this); - } - - /** - * Sets a default number to display in the dropdown trigger. - * - * @inheritdoc - * returns {void} - */ - componentWillMount() { - const { numbers } = this.props._dialIn; - - if (numbers) { - this._setDefaultNumber(numbers); - } else { - this.props.dispatch(updateDialInNumbers()); - } - } - - /** - * Monitors for number updates and sets a default number to display in the - * dropdown trigger if not already set. - * - * @inheritdoc - * returns {void} - */ - componentWillReceiveProps(nextProps) { - if (!this.state.selectedNumber && nextProps._dialIn.numbers) { - this._setDefaultNumber(nextProps._dialIn.numbers); - } - } - - /** - * Implements React's {@link Component#render()}. Returns null if the - * component is not ready for display. - * - * @inheritdoc - * @returns {ReactElement|null} - */ - render() { - const { _dialIn, t } = this.props; - const { conferenceID, numbers, numbersEnabled } = _dialIn; - const { selectedNumber } = this.state; - - if (!conferenceID || !numbers || !numbersEnabled || !selectedNumber) { - return null; - } - - const items = this._renderDropdownItems(numbers); - - return ( -
- -
-
- { this._createDropdownMenu(items, selectedNumber) } -
- -
-