discourse/app/assets/stylesheets/common/base/user-badges.scss

266 lines
4.1 KiB
SCSS

/* Default badge styles. */
.user-badge {
padding: 3px 8px;
color: $primary;
border: 1px solid $primary-low;
line-height: $line-height-large;
display: inline-block;
background-color: $secondary;
margin: 0 0 3px;
.fa {
padding-right: 3px;
font-size: 1.4em;
vertical-align: bottom;
}
img {
height: 16px;
width: 16px;
}
&.badge-type-gold .fa {
color: rgb(231, 195, 0) !important;
}
&.badge-type-silver .fa {
color: #c0c0c0 !important;
}
&.badge-type-bronze .fa {
color: #cd7f32 !important;
}
&.disabled {
color: $primary-medium;
background-color: $primary-very-low;
.fa {
opacity: 0.4;
}
}
}
@media all and (max-width: 750px) {
.show-badge .user-badge-with-posts .badge-user a.post-link {
width: auto;
}
.show-badge div.badge-user {
padding: 0;
}
.badges-listing {
display: block;
.info, .grant-count {
text-align: left;
}
.row > div.info { display: none; }
.row {
display: block;
> div {
display: block;
margin-top: 10px;
}
}
}
}
.show-badge .badge-user-info {
.earned {
font-size: $font-up-2;
margin-bottom: 1em;
}
}
.show-badge .single-user {
margin-left: 2%;
padding-bottom: 20px;
.load-more {
padding-top: 30px;
display: block;
font-size: $font-up-2;
}
}
.show-badge .single-user .badge-user {
padding-left: 0;
text-align: left;
display: block;
margin: 20px 0;
.badge-info {
display: none;
}
.date {
display: inline-block;
font-size: $font-up-1;
margin-left: 10px;
}
.post-link {
font-size: $font-up-2;
width: 500px;
margin: 0;
padding: 0;
}
width: 800px;
&:after {
content: "";
clear: both;
display: table;
}
}
.long-description.banner {
width: 88%;
margin-bottom: 15px;
margin-top: 15px;
}
.badge-card {
position: relative;
display: inline-block;
background-color: $primary-low;
margin-right: 5px;
margin-bottom: 10px;
.check-display {
position: absolute;
left: 5px;
top: 5px;
}
.grant-count {
position: absolute;
right: 5px;
top: 5px;
font-weight: bold;
color: $primary-medium;
font-size: $font-up-2;
}
.badge-contents {
display: flex;
flex-direction: row;
min-height: 128px;
height: 100%;
.badge-icon {
min-width: 90px;
display: flex;
align-items: center;
justify-content: center;
background-color: $primary-low;
font-size: 3em;
img {
max-width: 80px;
max-height: 80px;
}
&.badge-type-gold .fa {
color: rgb(231, 195, 0) !important;
}
&.badge-type-silver .fa {
color: #c0c0c0 !important;
}
&.badge-type-bronze .fa {
color: #cd7f32 !important;
}
}
.badge-info {
display: flex;
align-items: center;
justify-content: center;
padding: 15px;
color: $primary;
h3 {
margin-bottom: 0.4em;
}
}
}
}
.badge-card.medium {
width: 350px;
vertical-align: top;
}
@media all and (max-width: 320px) {
.badge-card.medium {
width: 100%;
}
}
.badge-card.large {
width: 750px;
}
.badge-groups {
margin: 20px 0;
color: dark-light-choose($primary-medium, $secondary-medium);
h3 {
margin-bottom: 1.0em;
}
}
.badge-grouping {
margin-bottom: 1.5em;
}
.show-badge-details {
display: flex;
flex-direction: row;
margin-bottom: 2em;
margin-top: 1em;
.badge-grant-info {
display: flex;
align-items: center;
margin-left: 1em;
&.hidden {
display: none;
}
}
.grant-info-item {
margin-bottom: 1em;
color: dark-light-choose($primary-medium, $secondary-medium);
}
.badge-title .form-horizontal .controls {
margin-left: 20px;
}
.close-btn {
margin: -20px 0 0 20px;
}
}
.check-display {
display: inline-block;
width: 18px;
border-radius: 10px;
text-align: center;
.fa {
font-size: 0.9em;
color: $secondary;
}
}
.check-display.status-checked {
background-color: $success;
}
.check-display.status-unchecked {
background-color: $danger;
}
.hyperlink {
cursor: pointer;
}