Bladeren bron

fix(jaas) hide support link in invite error for jaas users

j8
Tudor-Ovidiu Avram 4 jaren geleden
bovenliggende
commit
3a073d9af4

+ 8
- 3
react/features/base/react/components/web/InlineDialogFailure.js Bestand weergeven

@@ -20,7 +20,12 @@ type Props = {
20 20
     /**
21 21
      * Invoked to obtain translated strings.
22 22
      */
23
-    t: Function
23
+    t: Function,
24
+
25
+    /**
26
+     * Indicates whether the support link should be shown in case of an error
27
+     */
28
+     showSupportLink: Boolean,
24 29
 };
25 30
 
26 31
 /**
@@ -33,12 +38,12 @@ class InlineDialogFailure extends Component<Props> {
33 38
      * @returns {ReactElement}
34 39
      */
35 40
     render() {
36
-        const { t } = this.props;
41
+        const { t, showSupportLink } = this.props;
37 42
 
38 43
         const supportLink = interfaceConfig.SUPPORT_URL;
39 44
         const supportString = t('inlineDialogFailure.supportMsg');
40 45
         const supportLinkElem
41
-            = supportLink
46
+            = supportLink && showSupportLink
42 47
                 ? (
43 48
                     <div className = 'inline-dialog-error-text'>
44 49
                         <span>{ supportString.padEnd(supportString.length + 1) }

+ 8
- 2
react/features/base/react/components/web/MultiSelectAutocomplete.js Bestand weergeven

@@ -70,7 +70,12 @@ type Props = {
70 70
     /**
71 71
      * Indicates if we should focus.
72 72
      */
73
-    shouldFocus: boolean
73
+    shouldFocus: boolean,
74
+
75
+    /**
76
+     * Indicates whether the support link should be shown in case of an error
77
+     */
78
+    showSupportLink: Boolean,
74 79
 };
75 80
 
76 81
 /**
@@ -263,7 +268,8 @@ class MultiSelectAutocomplete extends Component<Props, State> {
263 268
         const content = (
264 269
             <div className = 'autocomplete-error'>
265 270
                 <InlineDialogFailure
266
-                    onRetry = { this._onRetry } />
271
+                    onRetry = { this._onRetry }
272
+                    showSupportLink = { this.props.showSupportLink } />
267 273
             </div>
268 274
         );
269 275
 

+ 11
- 2
react/features/invite/components/add-people-dialog/web/InviteContactsForm.js Bestand weergeven

@@ -10,6 +10,7 @@ import { Icon, IconPhone } from '../../../../base/icons';
10 10
 import { getLocalParticipant } from '../../../../base/participants';
11 11
 import { MultiSelectAutocomplete } from '../../../../base/react';
12 12
 import { connect } from '../../../../base/redux';
13
+import { isVpaasMeeting } from '../../../../billing-counter/functions';
13 14
 import { hideAddPeopleDialog } from '../../../actions';
14 15
 import AbstractAddPeopleDialog, {
15 16
     type Props as AbstractProps,
@@ -31,6 +32,11 @@ type Props = AbstractProps & {
31 32
      */
32 33
     _footerTextEnabled: boolean,
33 34
 
35
+    /**
36
+     * Whether the meeting belongs to JaaS user
37
+     */
38
+    _isVpaas: boolean,
39
+
34 40
     /**
35 41
      * The redux {@code dispatch} function.
36 42
      */
@@ -110,6 +116,7 @@ class InviteContactsForm extends AbstractAddPeopleDialog<Props, State> {
110 116
         const {
111 117
             _addPeopleEnabled,
112 118
             _dialOutEnabled,
119
+            _isVpaas,
113 120
             t
114 121
         } = this.props;
115 122
         const footerText = this._renderFooterText();
@@ -152,7 +159,8 @@ class InviteContactsForm extends AbstractAddPeopleDialog<Props, State> {
152 159
                     ref = { this._setMultiSelectElement }
153 160
                     resourceClient = { this._resourceClient }
154 161
                     shouldFitContainer = { true }
155
-                    shouldFocus = { true } />
162
+                    shouldFocus = { true }
163
+                    showSupportLink = { !_isVpaas } />
156 164
                 { this._renderFormActions() }
157 165
             </div>
158 166
         );
@@ -516,7 +524,8 @@ function _mapStateToProps(state) {
516 524
 
517 525
     return {
518 526
         ..._abstractMapStateToProps(state),
519
-        _footerTextEnabled: footerTextEnabled
527
+        _footerTextEnabled: footerTextEnabled,
528
+        _isVpaas: isVpaasMeeting(state)
520 529
     };
521 530
 }
522 531
 

Laden…
Annuleren
Opslaan