浏览代码

fix(Chat): Fix modals displaying improperly due to chat.

* Adjust chat font size.
* Adjust invite more button and text size.
* Remove useless constant.
master
Mihai-Andrei Uscat 4 年前
父节点
当前提交
3972e076f0
没有帐户链接到提交者的电子邮件

+ 9
- 19
css/_atlaskit_overrides.scss 查看文件

@@ -113,27 +113,17 @@
113 113
     }
114 114
 }
115 115
 
116
-@media (min-width: 580px) and (max-width: 680px) {
117
-    .mobile-browser {
118
-        &.shift-right .focus-lock > div > div {
119
-            @include full-size-modal-positioner();
120
-        }
121
-
122
-        &.shift-right .focus-lock [role="dialog"] {
123
-            @include full-size-modal-dialog();
124
-        }
116
+@media (max-width: 580px) {
117
+    // Override Atlaskit inline style for the modal background.
118
+    // Important is unfortunately needed for that.
119
+    .shift-right .focus-lock [role="dialog"][style] {
120
+        background-color: $chatBackgroundColor !important;
125 121
     }
126
-}
127
-
128
-// Override Atlaskit inline style for the modal background.
129
-// Important is unfortunately needed for that.
130
-.shift-right .focus-lock [role="dialog"][style] {
131
-    background-color: $chatBackgroundColor !important;
132
-}
133 122
 
134
-// Remove Atlaskit padding from the chat dialog.
135
-.shift-right .focus-lock [role="dialog"] > div:first-child > div:nth-child(2) {
136
-    padding: 0;
123
+    // Remove Atlaskit padding from the chat dialog.
124
+    .shift-right .focus-lock [role="dialog"] > div:first-child > div:nth-child(2) {
125
+        padding: 0;
126
+    }
137 127
 }
138 128
 
139 129
 div.Tooltip {

+ 14
- 5
css/_chat.scss 查看文件

@@ -129,10 +129,6 @@
129 129
 
130 130
     &.populated {
131 131
         #chat-input {
132
-            &:focus-within {
133
-                border: 1px solid #619CF4;
134
-            }
135
-
136 132
             .send-button {
137 133
                 background: #1B67EC;
138 134
                 cursor: pointer;
@@ -161,6 +157,10 @@
161 157
     padding: 4px;
162 158
     border-radius: 3px;
163 159
 
160
+    &:focus-within {
161
+        border: 1px solid #619CF4;
162
+    }
163
+
164 164
     * {
165 165
         background-color: transparent;
166 166
     }
@@ -214,7 +214,7 @@
214 214
     border-radius:0;
215 215
     box-shadow: none;
216 216
     color: white;
217
-    font-size: 15px;
217
+    font-size: 14px;
218 218
     padding: 10px;
219 219
     overflow-y: auto;
220 220
     resize: none;
@@ -271,6 +271,14 @@
271 271
             height: 48px;
272 272
         }
273 273
     }
274
+
275
+    #usermsg {
276
+        font-size: 16px;
277
+    }
278
+
279
+    .chatmessage .usermessage {
280
+        font-size: 16px;
281
+    }
274 282
 }
275 283
 
276 284
 .sideToolbarContainer {
@@ -309,6 +317,7 @@
309 317
 
310 318
     .usermessage {
311 319
         white-space: pre-wrap;
320
+        font-size: 14px;
312 321
     }
313 322
 
314 323
     &.error {

+ 14
- 3
css/modals/invite/_invite_more.scss 查看文件

@@ -16,7 +16,7 @@
16 16
         background: rgba(0, 0, 0, 0.7);
17 17
         border-radius: 8px;
18 18
         color: #fff;
19
-        font-size: 16px;
19
+        font-size: 14px;
20 20
         line-height: 24px;
21 21
         font-weight: 600;
22 22
     }
@@ -32,9 +32,9 @@
32 32
     &-button {
33 33
         display: flex;
34 34
         max-width: 100%;
35
-        height: 48px;
35
+        height: 40px;
36 36
         box-sizing: border-box;
37
-        padding: 12px 16px;
37
+        padding: 8px 16px;
38 38
         background: #0376DA;
39 39
         border-radius: 3px;
40 40
         cursor: pointer;
@@ -207,3 +207,14 @@
207 207
         }
208 208
     }
209 209
 }
210
+
211
+.mobile-browser {
212
+    .invite-more-content {
213
+        font-size: 16px;
214
+    }
215
+
216
+    .invite-more-button {
217
+        height: 48px;
218
+        padding: 12px 16px;
219
+    }
220
+}

+ 2
- 5
react/features/chat/components/AbstractChat.js 查看文件

@@ -3,10 +3,9 @@
3 3
 import { Component } from 'react';
4 4
 import type { Dispatch } from 'redux';
5 5
 
6
-import { isMobileBrowser } from '../../base/environment/utils';
7 6
 import { getLocalParticipant } from '../../base/participants';
8 7
 import { sendMessage } from '../actions';
9
-import { DESKTOP_SMALL_WIDTH_THRESHOLD, MOBILE_SMALL_WIDTH_THRESHOLD } from '../constants';
8
+import { SMALL_WIDTH_THRESHOLD } from '../constants';
10 9
 
11 10
 /**
12 11
  * The type of the React {@code Component} props of {@code AbstractChat}.
@@ -106,9 +105,7 @@ export function _mapStateToProps(state: Object) {
106 105
     const _localParticipant = getLocalParticipant(state);
107 106
 
108 107
     return {
109
-        _isModal: isMobileBrowser()
110
-            ? window.innerWidth <= MOBILE_SMALL_WIDTH_THRESHOLD
111
-            : window.innerWidth <= DESKTOP_SMALL_WIDTH_THRESHOLD,
108
+        _isModal: window.innerWidth <= SMALL_WIDTH_THRESHOLD,
112 109
         _isOpen: isOpen,
113 110
         _messages: messages,
114 111
         _showNamePrompt: !_localParticipant.name

+ 1
- 3
react/features/chat/constants.js 查看文件

@@ -30,6 +30,4 @@ export const MESSAGE_TYPE_LOCAL = 'local';
30 30
  */
31 31
 export const MESSAGE_TYPE_REMOTE = 'remote';
32 32
 
33
-export const DESKTOP_SMALL_WIDTH_THRESHOLD = 580;
34
-
35
-export const MOBILE_SMALL_WIDTH_THRESHOLD = 680;
33
+export const SMALL_WIDTH_THRESHOLD = 580;

正在加载...
取消
保存