Skip to content

Commit ea19096

Browse files
committed
skin all the buttons
1 parent a152eba commit ea19096

7 files changed

Lines changed: 56 additions & 77 deletions

File tree

‎src/skins/vector/css/_common.scss‎

Lines changed: 5 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -200,21 +200,13 @@ textarea {
200200
}
201201

202202
.mx_Dialog button, .mx_Dialog input[type="submit"] {
203-
border: 0px;
204-
height: 36px;
205-
border-radius: 40px;
206-
border: solid 1px $accent-color;
207-
font-weight: 600;
208-
font-size: 14px;
209-
font-family: $font-family;
203+
@mixin mx_DialogButton;
210204
margin-left: 0px;
211205
margin-right: 8px;
212-
padding-left: 1.5em;
213-
padding-right: 1.5em;
214-
outline: none;
215-
cursor: pointer;
206+
207+
// flip colours for the secondary ones
216208
color: $accent-color;
217-
background-color: $primary-bg-color;
209+
background-color: $accent-fg-color;
218210

219211
/* align images in buttons (eg spinners) */
220212
vertical-align: middle;
@@ -282,16 +274,8 @@ textarea {
282274
color: $selection-fg-color;
283275
}
284276

285-
/** green button with rounded corners */
286277
.mx_textButton {
287-
color: $accent-fg-color;
288-
background-color: $accent-color;
289-
border-radius: 17px;
290-
text-align: center;
291-
padding-left: 1em;
292-
padding-right: 1em;
293-
cursor: pointer;
294-
display: inline;
278+
@mixin mx_DialogButton_small;
295279
}
296280

297281
.mx_button_row {

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

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -64,30 +64,9 @@ limitations under the License.
6464
}
6565

6666
.mx_UserSettings_button {
67+
@mixin mx_DialogButton;
6768
display: inline;
68-
vertical-align: middle;
69-
border: 0px;
70-
border-radius: 36px;
71-
font-weight: 400;
72-
font-size: 16px;
73-
color: $accent-fg-color;
74-
background-color: $accent-color;
75-
width: auto;
7669
margin: auto;
77-
padding: 7px;
78-
padding-left: 1.5em;
79-
padding-right: 1.5em;
80-
cursor: pointer;
81-
}
82-
83-
.mx_UserSettings_button.mx_UserSettings_buttonSmall {
84-
height: 36px;
85-
padding: 4px;
86-
padding-left: 7px;
87-
padding-right: 7px;
88-
font-size: 12px;
89-
margin-right: 5px;
90-
line-height: 12px;
9170
}
9271

9372
.mx_UserSettings_button.danger {

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

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,7 @@ limitations under the License.
2626
}
2727

2828
.mx_MemberDeviceInfo_textButton {
29-
color: $accent-fg-color;
30-
background-color: $accent-color;
31-
border-radius: 17px;
32-
text-align: center;
33-
padding-left: 1em;
34-
padding-right: 1em;
35-
border: 0px;
36-
font-size: 14px;
37-
cursor: pointer;
29+
@mixin mx_DialogButton_small;
3830
margin: 2px;
3931
flex: 1;
4032
}

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

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -42,22 +42,10 @@ limitations under the License.
4242
}
4343

4444
.mx_RoomHeader_textButton {
45-
height: 36px;
46-
background-color: $accent-color;
47-
border-radius: 36px;
45+
@mixin mx_DialogButton;
4846
margin-right: 8px;
49-
color: $accent-fg-color;
50-
line-height: 34px;
51-
margin-top: -2px;
52-
text-align: center;
47+
margin-top: -5px;
5348
order: 2;
54-
cursor: pointer;
55-
56-
/*
57-
flex: 0 0 90px;
58-
*/
59-
padding-left: 12px;
60-
padding-right: 12px;
6149
}
6250

6351
.mx_RoomHeader_textButton_danger {

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

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,9 @@ limitations under the License.
2222

2323
.mx_RoomSettings_leaveButton,
2424
.mx_RoomSettings_unbanButton {
25+
@mixin mx_DialogButton;
2526
position: relative;
26-
height: 36px;
27-
background-color: $accent-color;
28-
border-radius: 36px;
2927
margin-right: 8px;
30-
color: $accent-fg-color;
31-
line-height: 34px;
32-
text-align: center;
33-
cursor: pointer;
34-
padding-left: 12px;
35-
padding-right: 12px;
3628
}
3729
.mx_RoomSettings_integrationsButton_error {
3830
position: relative;

‎src/skins/vector/css/themes/_base.scss‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,3 +130,27 @@ $lightbox-border-color: #ffffff;
130130

131131
// unused?
132132
$progressbar-color: #000;
133+
134+
// ***** Mixins! *****
135+
136+
@define-mixin mx_DialogButton {
137+
vertical-align: middle;
138+
border: 0px;
139+
border-radius: 36px;
140+
height: 33px;
141+
font-weight: 400;
142+
font-size: 16px;
143+
color: $accent-fg-color;
144+
background-color: $accent-color;
145+
width: auto;
146+
padding: 7px;
147+
padding-left: 1.5em;
148+
padding-right: 1.5em;
149+
cursor: pointer;
150+
display: inline-block;
151+
}
152+
153+
@define-mixin mx_DialogButton_small {
154+
@mixin mx_DialogButton;
155+
height: auto;
156+
}

‎src/skins/vector/themes/status/css/_status.scss‎

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ $event-selected-color: #f7f7f7;
9696
$primary-hairline-color: #e5e5e5;
9797

9898
// used for the border of input text fields
99-
$input-border-color: #f0f0f0;
99+
$input-border-color: #c9cfd4;
100100

101101
// apart from login forms, which have stronger border
102102
$strong-input-border-color: #c7c7c7;
@@ -178,14 +178,29 @@ $progressbar-color: #000;
178178

179179
@define-mixin mx_DialogButton {
180180
border-radius: 8px;
181-
height: 45px;
182181
border: 1px solid rgba(199, 206, 209, 0.12);
183182
background-color: $accent-color;
184183
font-size: 13px;
185184
font-family: $header-font-family;
186185
text-transform: uppercase;
187186
letter-spacing: 1px;
188187
color: $accent-fg-color;
188+
cursor: pointer;
189+
outline: none;
190+
padding: 14px;
191+
box-sizing: border-box;
192+
padding-left: 1.5em;
193+
padding-right: 1.5em;
194+
display: inline-block;
195+
}
196+
197+
@define-mixin mx_DialogButton_small {
198+
@mixin mx_DialogButton;
199+
height: auto;
200+
padding-top: 7px;
201+
padding-bottom: 7px;
202+
padding-left: 1em;
203+
padding-right: 1em;
189204
}
190205

191206
.mx_RoomSubList_label {
@@ -219,4 +234,9 @@ $progressbar-color: #000;
219234
margin-top: 8px ! important;
220235
margin-bottom: 7px ! important;
221236
padding: 8px ! important;
237+
}
238+
239+
.mx_RoomDirectory_perm {
240+
font-family: $header-font-family ! important;
241+
background-color: #fff ! important;
222242
}

0 commit comments

Comments
 (0)