File size: 1,912 Bytes
1e92f2d |
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 |
// Rules in this file inspired by:
// client/components/jetpack/profile-dropdown/style.scss
.jetpack-cloud-sidebar__profile-dropdown {
position: relative;
}
.jetpack-cloud-sidebar__profile-dropdown-button {
position: relative;
z-index: 1;
display: flex;
justify-content: center;
align-items: center;
height: 100%;
cursor: pointer;
}
html.accessible-focus .jetpack-cloud-sidebar__profile-dropdown-button:focus {
box-shadow: inset 0 0 0 2px var(--color-primary-light);
}
.jetpack-cloud-sidebar__profile-dropdown-menu {
// Required for older browsers
&[hidden] {
display: none;
}
position: absolute;
// 4px below the bottom of the icon
top: calc(100% + 4px);
// Float the dropdown to the left on small screens,
// and to the right on larger screens
right: 0;
@include breakpoint-deprecated( ">660px" ) {
right: initial;
}
// The menu should render "on top" of the profile picture & site switcher
z-index: 20;
width: 220px;
margin: 0;
padding: 8px;
background: var(--color-surface);
border: 1px solid var(--studio-gray-0);
border-radius: 2px;
box-shadow:
0 4px 6px color-mix(in srgb, var(--studio-gray-100) 10%, transparent),
0 1px 2px color-mix(in srgb, var(--studio-gray-100) 10%, transparent);
list-style-type: none;
font-size: $font-body-small;
}
.jetpack-cloud-sidebar__profile-dropdown-menu-item {
padding: 1px 0;
border-radius: 4px;
&:hover,
&:focus {
background: var(--color-sidebar-menu-hover-background);
}
a,
a:visited,
a:hover,
a:focus {
display: block;
width: 100%;
height: 100%;
color: var(--color-text);
}
.button {
width: 100%;
height: 100%;
text-align: start;
}
a,
.button {
&.is-borderless {
display: block;
padding-inline: 8px;
}
}
}
a.jetpack-cloud-sidebar__external-link {
display: inline-flex;
&:hover,
&:focus {
display: inline-flex;
}
svg {
position: absolute;
right: 16px;
}
}
|