Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit 4bb7995

Browse files
authored
Merge pull request #2075 from jackmu95/fix-styleguide-trigger-positioning
fix(footer): Improve styleguide trigger positioning
2 parents b478aaf + 8d713f1 commit 4bb7995

File tree

2 files changed

+23
-19
lines changed

2 files changed

+23
-19
lines changed

public/_includes/_footer.jade

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,6 @@ else
5252
li <a href="https://angular.cn/">中文版</a>
5353

5454
footer(class="background-midnight")
55-
small.text-caption Powered by Google ©2010-2016. Code licensed under an <a href="/license" class="text-snow">MIT-style License</a>. Documentation licensed under <a class="text-snow" href="http://creativecommons.org/licenses/by/4.0/">CC BY 4.0</a>.
56-
a(aria-label="View Style Guide" href=styleguide title="Style Guide" class="styleguide-trigger text-snow")
55+
small.text-caption Powered by Google ©2010-2016. Code licensed under an <a href="/license">MIT-style License</a>. Documentation licensed under <a href="http://creativecommons.org/licenses/by/4.0/">CC BY 4.0</a>.
56+
a(aria-label="View Style Guide" href=styleguide title="Style Guide" class="styleguide-trigger")
5757
span.icon-favorite

public/resources/css/module/_footer.scss

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -80,30 +80,34 @@
8080
footer {
8181
text-align: left;
8282
padding: ($unit * 2) ($unit * 6);
83-
position: relative;
83+
84+
@include respond-to('mobile') {
85+
text-align: center;
86+
}
87+
88+
a {
89+
color: $snow;
90+
}
8491

8592
.styleguide-trigger {
86-
box-sizing: border-box;
87-
position: absolute;
88-
display: inline-block;
89-
bottom: $unit * 2;
90-
right: $unit * 2;
91-
font-size: 14px;
92-
line-height: 24px;
93-
height: 24px;
94-
margin: 0;
95-
padding: 0 ($unit * 3);
96-
opacity: .24;
97-
transition: all .3s;
93+
color: $darkgrey;
94+
text-decoration: none;
95+
float: right;
96+
transition: color .3s;
97+
98+
@include respond-to('mobile') {
99+
display: block;
100+
margin-top: $unit;
101+
font-size: 18px;
102+
float: none;
103+
}
98104

99105
&:hover {
100-
background: $blue-grey-700;
101-
text-decoration: none;
106+
color: $red-600;
102107
}
103108

104109
.icon-favorite {
105-
display: inline-block;
106-
line-height: 24px;
110+
line-height: 20px;
107111
}
108112
}
109113
}

0 commit comments

Comments
 (0)