General cool popover mixin
parent
1bab78eb08
commit
71f2d9ee1b
|
@ -0,0 +1,25 @@
|
|||
@mixin popover($width, $top:"", $left:"", $bottom:"", $right:"") {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
list-style-type: none;
|
||||
position: absolute;
|
||||
background: $blackish;
|
||||
color: $white;
|
||||
font-family: 'DroidSans';
|
||||
padding: 10px;
|
||||
top: #{$top};
|
||||
left: #{$left};
|
||||
bottom: #{$bottom};
|
||||
right: #{$right};
|
||||
width: $width;
|
||||
display: none;
|
||||
a {
|
||||
padding: 10px 2px;
|
||||
display: block;
|
||||
@extend .small;
|
||||
border-bottom: 1px solid $grayer;
|
||||
&:last-child {
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -20,6 +20,7 @@ $prefix-for-spec: true;
|
|||
@import 'components/buttons';
|
||||
@import 'components/avatar';
|
||||
@import 'components/summary';
|
||||
@import 'components/popover';
|
||||
|
||||
//Layout
|
||||
@import 'layout/base';
|
||||
|
|
|
@ -51,27 +51,44 @@
|
|||
}
|
||||
}
|
||||
|
||||
.user-settings {
|
||||
|
||||
}
|
||||
|
||||
.user {
|
||||
width: 80px;
|
||||
padding: 0 10px;
|
||||
position: absolute;
|
||||
bottom: 1em;
|
||||
a {
|
||||
text-align: center;
|
||||
.popover {
|
||||
@include popover(150px, "", 30px, 30px);
|
||||
a{
|
||||
text-align: left;
|
||||
@extend .small;
|
||||
color: $white;
|
||||
@extend .medium;
|
||||
&:hover {
|
||||
color: $freshTaiga;
|
||||
@include transition (color .2s linear);
|
||||
}
|
||||
}
|
||||
}
|
||||
.user-settings{
|
||||
position: relative;
|
||||
img{
|
||||
border: 1px solid transparent;
|
||||
width: 100%;
|
||||
border-radius: 50%;
|
||||
&:hover {
|
||||
border: 2px solid $freshTaiga;
|
||||
@include transition (all .6s ease-in-out);
|
||||
}
|
||||
}
|
||||
}
|
||||
.settings {
|
||||
text-align: center;
|
||||
a {
|
||||
margin-right: .5em;
|
||||
color: $whitish;
|
||||
&:hover {
|
||||
@include transition (color .3s linear);
|
||||
color: $freshTaiga;
|
||||
|
|
|
@ -28,6 +28,14 @@ nav.menu
|
|||
span.icon.icon-video
|
||||
span.item Video
|
||||
div.user
|
||||
div.user-settings
|
||||
ul.popover
|
||||
li
|
||||
a(href="", title="Change profile photo") Change profile photo
|
||||
li
|
||||
a(href="", title="Account settings") Account settings
|
||||
li
|
||||
a(href="", title="Logout") Logout
|
||||
a.avatar(href="", title="User preferences")
|
||||
img(src="http://thecodeplayer.com/u/uifaces/12.jpg", alt="username")
|
||||
div.settings
|
||||
|
|
Loading…
Reference in New Issue