Skip to content

Commit 0c865e8

Browse files
committed
add styles for compact layout
Signed-off-by: Hubert Chathi <hubert@uhoreg.ca>
1 parent 020d496 commit 0c865e8

9 files changed

Lines changed: 141 additions & 1 deletion

File tree

‎src/skins/vector/css/matrix-react-sdk/structures/_RoomStatusBar.scss‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,3 +175,22 @@ limitations under the License.
175175
margin-top: -2px;
176176
}
177177

178+
.mx_MatrixChat_useCompactLayout {
179+
.mx_RoomStatusBar {
180+
min-height: 40px;
181+
}
182+
183+
.mx_RoomStatusBar_indicator {
184+
margin-top: 10px;
185+
}
186+
187+
.mx_RoomStatusBar_callBar {
188+
height: 40px;
189+
line-height: 40px;
190+
}
191+
192+
.mx_RoomStatusBar_typingBar {
193+
height: 40px;
194+
line-height: 40px;
195+
}
196+
}

‎src/skins/vector/css/matrix-react-sdk/structures/_RoomView.scss‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,4 +260,14 @@ hr.mx_RoomView_myReadMarker {
260260

261261
.mx_RoomView_ongoingConfCallNotification a {
262262
color: $accent-fg-color ! important;
263-
}
263+
}
264+
265+
.mx_MatrixChat_useCompactLayout {
266+
.mx_RoomView_MessageList {
267+
margin-bottom: 4px;
268+
}
269+
270+
.mx_RoomView_statusAreaBox {
271+
min-height: 42px;
272+
}
273+
}

‎src/skins/vector/css/matrix-react-sdk/views/elements/_MemberEventListSummary.scss‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,13 @@ limitations under the License.
4848
margin-left: 63px;
4949
line-height: 30px;
5050
}
51+
52+
.mx_MatrixChat_useCompactLayout {
53+
.mx_MemberEventListSummary_line {
54+
line-height: 22px;
55+
}
56+
57+
.mx_MemberEventListSummary_toggle {
58+
margin-top: 2px;
59+
}
60+
}

‎src/skins/vector/css/matrix-react-sdk/views/rooms/_EventTile.scss‎

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -360,3 +360,59 @@ limitations under the License.
360360
}
361361

362362
/* end of overrides */
363+
364+
.mx_MatrixChat_useCompactLayout {
365+
.mx_EventTile {
366+
padding-top: 4px;
367+
}
368+
369+
.mx_EventTile.mx_EventTile_emote {
370+
padding-top: 8px;
371+
.mx_EventTile_avatar {
372+
top: 2px;
373+
}
374+
.mx_EventTile_line {
375+
padding-top: 1px;
376+
padding-bottom: 2px;
377+
}
378+
}
379+
380+
.mx_EventTile.mx_EventTile_emote.mx_EventTile_continuation {
381+
padding-top: 0;
382+
.mx_EventTile_line {
383+
padding-top: 1px;
384+
padding-bottom: 1px;
385+
}
386+
}
387+
388+
.mx_EventTile_line {
389+
padding-top: 1px;
390+
padding-bottom: 1px;
391+
}
392+
393+
.mx_EventTile_avatar {
394+
top: 0;
395+
}
396+
397+
.mx_EventTile.mx_EventTile_info .mx_EventTile_avatar {
398+
top: 5px;
399+
}
400+
401+
.mx_EventTile_e2eIcon {
402+
top: 7px;
403+
}
404+
405+
.mx_EventTile_readAvatars {
406+
top: 27px;
407+
}
408+
409+
.mx_EventTile_continuation .mx_EventTile_readAvatars,
410+
.mx_EventTile_info .mx_EventTile_readAvatars,
411+
.mx_EventTile_emote .mx_EventTile_readAvatars {
412+
top: 5px;
413+
}
414+
415+
.mx_RoomView_MessageList h2 {
416+
margin-top: 6px;
417+
}
418+
}

‎src/skins/vector/css/matrix-react-sdk/views/rooms/_LinkPreviewWidget.scss‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,3 +60,10 @@ limitations under the License.
6060
.mx_LinkPreviewWidget:hover .mx_LinkPreviewWidget_cancel {
6161
visibility: visible;
6262
}
63+
64+
.mx_MatrixChat_useCompactLayout {
65+
.mx_LinkPreviewWidget {
66+
margin-top: 6px;
67+
margin-bottom: 6px;
68+
}
69+
}

‎src/skins/vector/css/matrix-react-sdk/views/rooms/_MessageComposer.scss‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,3 +200,9 @@ limitations under the License.
200200
padding: 4px 4px 4px 0;
201201
opacity: 0.8;
202202
}
203+
204+
.mx_MatrixChat_useCompactLayout {
205+
.mx_MessageComposer_input {
206+
min-height: 50px;
207+
}
208+
}

‎src/skins/vector/css/matrix-react-sdk/views/rooms/_TopUnreadMessagesBar.scss‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,10 @@ limitations under the License.
4444
padding-top: 3px;
4545
cursor: pointer;
4646
}
47+
48+
.mx_MatrixChat_useCompactLayout {
49+
.mx_TopUnreadMessagesBar {
50+
padding-top: 4px;
51+
padding-bottom: 4px;
52+
}
53+
}

‎src/skins/vector/css/vector-web/structures/_LeftPanel.scss‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,3 +104,17 @@ limitations under the License.
104104
top: -25px;
105105
left: 6px;
106106
}
107+
108+
.mx_MatrixChat_useCompactLayout {
109+
.mx_LeftPanel .mx_BottomLeftMenu {
110+
flex: 0 0 50px;
111+
}
112+
113+
.mx_LeftPanel.collapsed .mx_BottomLeftMenu {
114+
flex: 0 0 160px;
115+
}
116+
117+
.mx_LeftPanel .mx_BottomLeftMenu_options {
118+
margin-top: 12px;
119+
}
120+
}

‎src/skins/vector/css/vector-web/structures/_RightPanel.scss‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,3 +118,14 @@ limitations under the License.
118118
vertical-align: top;
119119
padding-left: 10px
120120
}
121+
122+
.mx_MatrixChat_useCompactLayout {
123+
.mx_RightPanel_footer {
124+
flex: 0 0 50px;
125+
}
126+
127+
.mx_RightPanel_footer .mx_RightPanel_invite {
128+
line-height: 25px;
129+
padding-top: 8px;
130+
}
131+
}

0 commit comments

Comments
 (0)