File tree Expand file tree Collapse file tree 1 file changed +9
-38
lines changed Expand file tree Collapse file tree 1 file changed +9
-38
lines changed Original file line number Diff line number Diff line change @@ -6,48 +6,10 @@ $mat-chip-line-height: 16px;
6
6
$mat-chips-chip-margin : $mat-chip-horizontal-padding / 4 ;
7
7
8
8
.mat-chip-list-wrapper {
9
-
10
9
display : flex ;
11
10
flex-direction : row ;
12
11
flex-wrap : wrap ;
13
12
align-items : flex-start ;
14
-
15
- /*
16
- * Only apply the margins to chips
17
- */
18
- .mat-chip :not (.mat-basic-chip ) {
19
- margin : 0 $mat-chips-chip-margin 0 $mat-chips-chip-margin ;
20
-
21
- // Remove the margin from the first element (in both LTR and RTL)
22
- & :first-child {
23
- margin : {
24
- left : 0 ;
25
- right : $mat-chips-chip-margin ;
26
- }
27
-
28
- [dir = ' rtl' ] & {
29
- margin : {
30
- left : $mat-chips-chip-margin ;
31
- right : 0 ;
32
- }
33
- }
34
- }
35
-
36
- // Remove the margin from the last element (in both LTR and RTL)
37
- & :last-child {
38
- margin : {
39
- left : $mat-chips-chip-margin ;
40
- right : 0 ;
41
- }
42
-
43
- [dir = ' rtl' ] & {
44
- margin : {
45
- left : 0 ;
46
- right : $mat-chips-chip-margin ;
47
- }
48
- }
49
- }
50
- }
51
13
}
52
14
53
15
.mat-chip :not (.mat-basic-chip ) {
@@ -57,6 +19,15 @@ $mat-chips-chip-margin: $mat-chip-horizontal-padding / 4;
57
19
58
20
font-size : $mat-chip-font-size ;
59
21
line-height : $mat-chip-line-height ;
22
+
23
+ // Apply a margin to adjacent sibling chips.
24
+ & + & {
25
+ margin : 0 0 0 $mat-chips-chip-margin ;
26
+
27
+ [dir = ' rtl' ] & {
28
+ margin : 0 $mat-chips-chip-margin 0 0 ;
29
+ }
30
+ }
60
31
}
61
32
62
33
.mat-chip-list-stacked .mat-chip-list-wrapper {
You can’t perform that action at this time.
0 commit comments