-
Notifications
You must be signed in to change notification settings - Fork 6.7k
/
chips.scss
92 lines (74 loc) · 1.81 KB
/
chips.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
@import '../core/a11y/a11y';
@import '../core/style/elevation';
$mat-chip-vertical-padding: 7px;
$mat-chip-horizontal-padding: 12px;
$mat-chip-remove-margin-before: 6px;
$mat-chip-remove-margin-after: -4px;
$mat-chips-chip-margin: 8px;
.mat-chip-list-wrapper {
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-items: flex-start;
}
.mat-chip:not(.mat-basic-chip) {
@include mat-elevation-transition;
display: inline-flex;
padding: $mat-chip-vertical-padding $mat-chip-horizontal-padding;
border-radius: $mat-chip-horizontal-padding * 2;
align-items: center;
cursor: default;
// Apply a margin to adjacent sibling chips.
& + & {
margin: 0 0 0 $mat-chips-chip-margin;
[dir='rtl'] & {
margin: 0 $mat-chips-chip-margin 0 0;
}
}
.mat-input-prefix & {
&:last-child {
margin-right: $mat-chips-chip-margin;
}
[dir='rtl'] &:last-child {
margin-left: $mat-chips-chip-margin;
}
}
.mat-chip-remove.mat-icon {
width: 1em;
height: 1em;
}
&:focus {
@include mat-elevation(3);
outline: none;
}
@include cdk-high-contrast {
outline: solid 1px;
}
}
.mat-chip-list-stacked .mat-chip-list-wrapper {
display: block;
.mat-chip:not(.mat-basic-chip) {
display: block;
margin: 0;
margin-bottom: $mat-chips-chip-margin;
[dir='rtl'] & {
margin: 0;
margin-bottom: $mat-chips-chip-margin;
}
&:last-child, [dir='rtl'] &:last-child {
margin-bottom: 0;
}
}
}
.mat-input-prefix .mat-chip-list-wrapper {
margin-bottom: $mat-chips-chip-margin;
}
.mat-chip-remove {
margin-right: $mat-chip-remove-margin-after;
margin-left: $mat-chip-remove-margin-before;
cursor: pointer;
[dir='rtl'] & {
margin-right: $mat-chip-remove-margin-before;
margin-left: $mat-chip-remove-margin-after;
}
}