Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit e980c14

Browse files
authored
Create a mixin of cancel button (#8526)
1 parent 7e63202 commit e980c14

File tree

7 files changed

+16
-35
lines changed

7 files changed

+16
-35
lines changed

res/css/_common.scss

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -385,15 +385,22 @@ legend {
385385
color: $alert;
386386
}
387387

388-
.mx_Dialog_cancelButton {
388+
@define-mixin customisedCancelButton {
389389
mask: url('$(res)/img/feather-customised/cancel.svg');
390390
mask-repeat: no-repeat;
391391
mask-position: center;
392392
mask-size: cover;
393-
width: 14px;
394-
height: 14px;
395393
background-color: $dialog-close-fg-color;
396394
cursor: pointer;
395+
position: unset;
396+
width: unset;
397+
height: unset;
398+
}
399+
400+
.mx_Dialog_cancelButton {
401+
@mixin customisedCancelButton;
402+
width: 14px;
403+
height: 14px;
397404
position: absolute;
398405
top: 10px;
399406
right: 0;

res/css/structures/auth/_CompleteSecurity.scss

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,9 @@ limitations under the License.
3434
}
3535

3636
.mx_CompleteSecurity_skip {
37-
mask: url('$(res)/img/feather-customised/cancel.svg');
38-
mask-repeat: no-repeat;
39-
mask-position: center;
40-
mask-size: cover;
37+
@mixin customisedCancelButton;
4138
width: 18px;
4239
height: 18px;
43-
background-color: $dialog-close-fg-color;
44-
cursor: pointer;
4540
position: absolute;
4641
right: 24px;
4742
}

res/css/views/dialogs/_CompoundDialog.scss

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,9 @@ limitations under the License.
3838
}
3939

4040
.mx_CompoundDialog_cancelButton {
41-
mask: url('$(res)/img/feather-customised/cancel.svg');
42-
mask-repeat: no-repeat;
43-
mask-position: center;
44-
mask-size: cover;
41+
@mixin customisedCancelButton;
4542
width: 20px;
4643
height: 20px;
47-
background-color: $dialog-close-fg-color;
48-
cursor: pointer;
4944

5045
// Align with middle of title, 34px from right edge
5146
position: absolute;

res/css/views/elements/_EditableItemList.scss

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,12 @@ limitations under the License.
2525
}
2626

2727
.mx_EditableItem_delete {
28+
@mixin customisedCancelButton;
2829
order: 3;
2930
margin-right: 5px;
30-
cursor: pointer;
3131
vertical-align: middle;
3232
width: 14px;
3333
height: 14px;
34-
mask-image: url('$(res)/img/feather-customised/cancel.svg');
35-
mask-repeat: no-repeat;
3634
background-color: $alert;
3735
mask-size: 100%;
3836
}

res/css/views/right_panel/_VerificationPanel.scss

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,10 @@ limitations under the License.
2525

2626
.mx_UserInfo {
2727
.mx_EncryptionPanel_cancel {
28-
mask: url('$(res)/img/feather-customised/cancel.svg');
29-
mask-repeat: no-repeat;
30-
mask-position: center;
31-
mask-size: cover;
28+
@mixin customisedCancelButton;
3229
width: 14px;
3330
height: 14px;
3431
background-color: $settings-subsection-fg-color;
35-
cursor: pointer;
3632
position: absolute;
3733
z-index: 100;
3834
top: 14px;

res/css/views/voip/_DialPadContextMenu.scss

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,10 @@ limitations under the License.
3535
}
3636

3737
.mx_DialPadContextMenu_cancel {
38+
@mixin customisedCancelButton;
3839
float: right;
39-
mask: url('$(res)/img/feather-customised/cancel.svg');
40-
mask-repeat: no-repeat;
41-
mask-position: center;
42-
mask-size: cover;
4340
width: 14px;
4441
height: 14px;
45-
background-color: $dialog-close-fg-color;
46-
cursor: pointer;
4742
}
4843

4944
.mx_DialPadContextMenu_header:focus-within {

res/css/views/voip/_DialPadModal.scss

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,10 @@ limitations under the License.
4545
}
4646

4747
.mx_DialPadModal_cancel {
48+
@mixin customisedCancelButton;
4849
float: right;
49-
mask: url('$(res)/img/feather-customised/cancel.svg');
50-
mask-repeat: no-repeat;
51-
mask-position: center;
52-
mask-size: cover;
5350
width: 14px;
5451
height: 14px;
55-
background-color: $dialog-close-fg-color;
56-
cursor: pointer;
5752
margin-right: 16px;
5853
}
5954

0 commit comments

Comments
 (0)