-
Notifications
You must be signed in to change notification settings - Fork 14
/
highlight-share.scss
108 lines (98 loc) · 2.88 KB
/
highlight-share.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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
@import "vars";
@import "mixins";
.highlight-share-popover {
max-width: $highlight-share-border-distance * 2;
pointer-events: none;
@include highlight-share-filter(drop-shadow(0 1px 3px rgba(0, 0, 0, .35)));
@include highlight-share-animation(highlight-share-intro $highlight-share-animation-length);
&::before {
content: "";
position: absolute;
bottom: 100%;
left: 50%;
width: 0;
height: 0;
margin: $highlight-share-vertical-offset + $highlight-share-arrow-size (-$highlight-share-arrow-size);
border-width: $highlight-share-arrow-size $highlight-share-arrow-size 0;
border-style: solid;
border-color: $highlight-share-background transparent;
}
> ul {
pointer-events: auto;
list-style: none;
padding: 0;
margin: $highlight-share-vertical-offset - $highlight-share-arrow-size 0 0;
white-space: nowrap;
background: $highlight-share-background;
color: $highlight-share-foreground;
border-radius: $highlight-share-border-radius;
position: absolute;
left: 50%;
@include highlight-share-transform(translate(-50%, -100%));
> li {
display: inline-block;
width: $highlight-share-sharer-width;
height: $highlight-share-sharer-height;
line-height: $highlight-share-sharer-height;
text-align: center;
> a {
display: inline-block;
width: 100%;
height: 100%;
color: inherit;
box-sizing: border-box;
padding: $highlight-share-sharer-padding;
&:hover, &:focus {
background: $highlight-share-highlight-link;
}
}
polyline {
stroke: $highlight-share-foreground;
}
}
}
@media (pointer: coarse) {
font-size: 150%;
@include highlight-share-on-bottom();
}
@media (max-width: $highlight-share-small-devices-max) {
left: 0 !important;
right: 0 !important;
width: auto !important;
max-width: none;
@include highlight-share-on-bottom();
> ul {
left: 0;
width: 100%;
transform: none;
border-radius: 0;
text-align: center;
}
}
}
@-webkit-keyframes highlight-share-intro {
0% {
-webkit-transform: translateY(-3em);
opacity: 0;
}
80% {
-webkit-transform: translateY(.5em);
opacity: 1;
}
100% {
-webkit-transform: translateY(0);
}
}
@keyframes highlight-share-intro {
0% {
transform: translateY(-3em);
opacity: 0;
}
80% {
transform: translateY(.5em);
opacity: 1;
}
100% {
transform: translateY(0);
}
}