11.view-source-button {
2- position : absolute;
3- right : 1rem ;
4- top : 12px ;
5- display : none;
62 color : var (--color-brand-gray4 );
3+ font-family : "Source Code Pro" , sans-serif;
4+ background : url(../ img/awesome-github.svg) no-repeat center center;
5+ background-size : cover;
6+ display : inline-block;
7+ width : 16px ;
8+ height : 15.5px ;
9+ font-size : 0 ;
10+ margin-left : 0.5rem ;
11+ }
12+
13+ .view-source-button : hover ::after {
14+ content : attr (data-title);
15+ color : var (--color-brand-gray4 );
16+ font-size : var (--font-base );
17+ font-weight : var (--weight-light );
18+ line-height : 1 ;
19+ text-transform : capitalize;
20+ position : absolute;
21+ bottom : -53px ;
22+ right : -30% ;
23+ left : auto;
24+ margin : 0 ;
25+ padding : 5px ;
26+ text-align : center;
27+ box-shadow : 0 3px 6px rgba (0 , 0 , 0 , 0.06 );
28+ background : var (--color-brand-white );
29+ border : 1px solid var (--color-brand-gray7 );
30+ box-sizing : border-box;
31+ border-radius : 3px ;
32+ min-width : 90px ;
733 font-family : "Source Sans Pro" , sans-serif;
8- z-index : 1 ;
934}
1035
11- .doc .listingblock : hover .view-source-button {
12- display : block;
36+ .view-source-button : hover ::before {
37+ width : 0 ;
38+ height : 0 ;
39+ border-left : 7px solid transparent;
40+ border-right : 7px solid transparent;
41+ border-bottom : 10px solid var (--color-brand-white );
42+ position : absolute;
43+ content : "" ;
44+ box-shadow : inset 0 0 1px # bec0c1 ;
45+ bottom : -27px ;
46+ right : auto;
47+ left : auto;
1348}
1449
1550.copy-code-button {
16- position : absolute;
1751 background : url(../ img/copy.png) no-repeat center right/contain;
18- width : 24px ;
19- height : 14px ;
20- right : 3.2rem ;
21- top : 12px ;
22- display : none;
52+ width : 13px ;
53+ height : 16px ;
2354 cursor : pointer;
2455 font-family : "Source Sans Pro" , sans-serif;
2556 color : var (--color-brand-gray4 );
26- z-index : 1 ;
57+ margin-left : 0.5rem ;
58+ margin-right : 0.5rem ;
2759}
2860
2961a .copy-code-button : focus ,
3062a .copy-code-button : hover {
3163 color : var (--color-brand-gray4 );
3264}
3365
34- .doc .listingblock : hover .copy-code-button {
35- display : block;
36- }
3766
3867.copy-code-button : hover ::after {
3968 content : attr (data-title);
4069 color : var ("--color-brand-gray4" );
41- font-size : 14 px ;
70+ font-size : var ( --font-base ) ;
4271 font-weight : var (--weight-light );
4372 line-height : 1 ;
4473 text-transform : capitalize;
4574 position : absolute;
4675 bottom : -53px ;
47- right : -100 % ;
48- left : -100 % ;
49- margin : auto ;
76+ right : -30 % ;
77+ left : auto ;
78+ margin : 0 ;
5079 padding : 5px ;
5180 text-align : center;
5281 box-shadow : 0 3px 6px rgba (0 , 0 , 0 , 0.06 );
5382 background : var (--color-brand-white );
5483 border : 1px solid var (--color-brand-gray7 );
5584 box-sizing : border-box;
5685 border-radius : 3px ;
57- /* min-width: 90px; */
86+ min-width : 80 px ;
5887 font-family : "Source Sans Pro" , sans-serif;
5988}
6089
@@ -68,5 +97,63 @@ a.copy-code-button:hover {
6897 content : "" ;
6998 box-shadow : inset 0 0 1px # bec0c1 ;
7099 bottom : -27px ;
100+ right : auto;
101+ left : auto;
102+ }
103+
104+
105+ .doc .listingblock code [data-lang ] + .source-type-box {
106+ position : absolute;
107+ top : 0 ;
108+ right : 0 ;
109+ display : none;
110+ align-items : center;
111+ z-index : 1 ;
112+ padding-top : 12px ;
113+ }
114+
115+ .doc .listingblock code [data-lang ] + .source-type-box .data-source {
116+ content : attr (data-lang);
117+ color : var ("--color-brand-gray1" );
118+ font-size : 0.75rem ;
119+ font-weight : var (--weight-normal );
120+ letter-spacing : 1px ;
121+ line-height : 18px ;
122+ text-transform : uppercase;
123+ font-family : "Source Code Pro" , sans-serif;
124+ padding-right : 0.5rem ;
125+ border-right : 1px solid var (--color-brand-gray9 );
126+ }
127+
128+ /* .doc .listingblock:hover code[data-lang] + .source-type-box .data-source {
129+ display: block;
130+ } */
131+
132+ .doc .listingblock : hover code [data-lang ] + .source-type-box {
133+ display : flex;
134+ }
135+
136+ .doc .listingblock pre .fade-shadow {
137+ content : "" ;
138+ display : inline-block;
139+ background :
140+ transparent
141+ linear-gradient (
142+ 180deg ,
143+ # f1f7fe0d 0% ,
144+ # f1f7fe40 18% ,
145+ # f1f7fe 68% ,
146+ # f1f7fe 100%
147+ )
148+ 0% 0% no-repeat padding-box;
149+ width : 65px ;
150+ height : 80% ;
151+ position : absolute;
71152 right : 0 ;
153+ top : 0 ;
72154}
155+
156+ code .language-console .hljs .shell {
157+ white-space : nowrap;
158+ overflow-x : auto;
159+ }
0 commit comments