2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-12 21:10:47 +08:00

UX: Type system rebuild (#5492)

This commit is contained in:
Kris 2018-01-12 17:27:38 -05:00 committed by GitHub
parent 298ee26908
commit 674013129a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
86 changed files with 931 additions and 859 deletions

View file

@ -8,5 +8,5 @@
margin-bottom: -3px;
margin-top: -5px;
padding: 15px;
font-size: 1em;
font-size: $font-0;
}

View file

@ -4,6 +4,11 @@
// throughout the Discourse application

// Base Elements
html {
font-size: 15px; // Increasing overall font-size on mobile by 1px
}


body {
background-color: $secondary;
}
@ -75,7 +80,7 @@ blockquote {
&.preferences-nav {
position: absolute;
right: 0px;
top: -55px;
top: -57px;
}

a {
@ -84,6 +89,7 @@ blockquote {
.fa {
margin-right: 8px;
color: dark-light-choose($primary-medium, $secondary-medium);
line-height: $line-height-medium;
}
}


View file

@ -4,7 +4,7 @@

@media only screen and (max-width: 320px) {
#site-text-logo {
font-size: 1.286em;
font-size: $font-up-2;
}
}

@ -34,10 +34,9 @@
}

.d-header-icons {
.badge-notification {
top: -5px;
.d-icon {
line-height: $line-height-medium;
}

.active .icon {
&:after { margin-top: -1px; }
}
@ -52,5 +51,5 @@
}

.search-link .topic-statuses .topic-status i {
font-size: 1em;
font-size: $font-0;
}

View file

@ -6,7 +6,7 @@
display: none;
}
#revision-numbers {
line-height: 2em;
line-height: $line-height-large;
}
#revision-details {
background-color: $primary-low;

View file

@ -2,7 +2,7 @@

.btn-social {
width: 150px;
font-size: 1.143em;
font-size: $font-up-1;
overflow: hidden;
white-space: nowrap;
}
@ -20,7 +20,7 @@
}
label { float: left; display: block; }
textarea, input, select {
font-size: 1.143em;
font-size: $font-up-1;
clear: left;
margin-top: 0;
}

View file

@ -59,12 +59,12 @@

h3 {
display: inline;
font-size: 1.286em;
font-size: $font-up-2;
margin: 0px;
}
}
.close {
font-size: 1.857em;
font-size: $font-up-4;
padding: 10px 15px 5px 5px;
color: $primary;
}
@ -106,7 +106,7 @@
.custom-message-length {
margin: -4px 0 10px 20px;
color: dark-light-choose($primary-high, $secondary-low);
font-size: .857em;
font-size: $font-down-1;
}

.flag-message {

View file

@ -48,6 +48,7 @@
}
.nav-pills > li {
background: $primary-low;
font-size: $font-down-1;
.d-icon-caret-down {
margin-left: 8px;
}
@ -85,7 +86,7 @@
.badge-notification, .category-topic-link td.num .badge-notification {
position: relative;
top: -1px;
font-size: 1em;
font-size: $font-down-1;
padding: 4px 6px 3px 6px;
i {color: $secondary;}

@ -105,7 +106,6 @@
}

.topic-item-stats {
margin-top: 8px;
.category, .num, .last-poster {
float: left;
}
@ -222,7 +222,7 @@ tr.category-topic-link {

h3 {
display: inline-block;
font-size: 1.286em;
font-size: $font-up-2;
margin: 0 0 0 10px;
i {
margin-right: 5px;
@ -237,7 +237,7 @@ tr.category-topic-link {
}

.category-topic-link .main-link .age {
font-size: 0.857em;
font-size: $font-down-1;
}

.category-description td {
@ -283,7 +283,7 @@ tr.category-topic-link {
margin: 3px 7px 0 0;
color: dark-light-choose($primary, $secondary-low);
font-weight: bold;
font-size: 0.857em;
font-size: $font-down-1;
}
figcaption {
display: inline;
@ -361,7 +361,7 @@ tr.category-topic-link {
padding: 3px 15px;
clear: both;
font-weight: normal;
line-height: 18px;
line-height: $line-height-medium;
color: $primary;
}
.dropdown-menu li > a:hover,
@ -391,8 +391,7 @@ ol.category-breadcrumb {
height: 200px;

a.badge-category {
line-height: 26px !important;
margin-bottom: 0 !important;
line-height: $line-height-large;
}
}

@ -434,7 +433,7 @@ td .main-link {
}
.topic-list {
.posts-map {
font-size: 1.143em;
font-size: $font-up-1;
}
// so the topic excerpt is full width
// as the containing div is 80%

View file

@ -5,7 +5,7 @@

.topic-post article {
border-top: 1px solid $primary-low;
padding: 8px 0;
padding: 15px 0 8px 0;
}

.post-stream {
@ -20,10 +20,6 @@ span.badge-posts {
display: none;
}

.who-liked {
margin-left: 10px;
}

.topic-post {
nav.post-controls {
clear: both;
@ -33,9 +29,9 @@ span.badge-posts {
}
button {
border: none;
font-size: 1.286em;
font-size: $font-up-1;
padding: 8px 10px;
vertical-align: top;
vertical-align: middle;
background: transparent;
float: left;
&.hidden {
@ -60,7 +56,7 @@ span.badge-posts {
}

button.like-count {
font-size: 1em;
font-size: $font-0;
padding: 8px 4px;
}
}
@ -88,7 +84,7 @@ span.badge-posts {
h3 {
margin-top: 0;
color: $primary;
font-size: 1em;
font-size: $font-0;
}

ul {
@ -129,10 +125,11 @@ span.badge-posts {
}

a.reply-to-tab {
position: absolute;
z-index: 400;
right: 80px;
color: dark-light-choose($primary-medium, $secondary-medium);
margin: -3px 10px 0 0;
float: right;
}

.topic-post .boxed .contents {
@ -154,17 +151,17 @@ a.reply-to-tab {
margin-bottom: 4px;
margin-top: 0;
color: dark-light-choose($primary-medium, $secondary-medium);
line-height: 23px;
line-height: $line-height-large;
font-weight: normal;
font-size: 1em;
font-size: $font-0;
}

h4 {
margin: 0 0 3px 0;
color: dark-light-choose($primary-medium, $secondary-medium);
font-weight: normal;
font-size: 0.857em;
line-height: 15px;
font-size: $font-down-1;
line-height: $line-height-medium;
}

.user {
@ -177,29 +174,6 @@ a.reply-to-tab {
list-style: none;
}

.avatars {
> div {
float: left;
position: relative;
margin: 3px 0;
}
.post-count {
position: absolute;
right: 0;
border-radius: 100px;
padding: 4px 5px 2px 5px;
text-align: center;
font-weight: normal;
font-size: .857em;
line-height: 1;
}
}

.avatar {
float: left;
margin-right: 4px;
}

.map-collapsed {
.secondary {
display: none;
@ -215,11 +189,11 @@ a.reply-to-tab {
}
}
a, .number {
line-height: 20px;
line-height: $line-height-large;
}
.number, i {
color: dark-light-choose($primary-high, $secondary-low);
font-size: 1.143em;
font-size: $font-up-1;
}

.avatar + a {
@ -231,11 +205,17 @@ a.reply-to-tab {
}

.links, .information, .avatars {
padding: 7px 10px;
padding: 10px;
color: $primary;
overflow: auto;
}

.information {
p {
margin: 0 0 10px 0;
}
}

.participants { // PMs //
.user {float: left; margin: 0 10px 10px 0;}
}
@ -256,17 +236,15 @@ a.reply-to-tab {
}

.buttons {
float: right;
.btn {
border: 0;
padding: 0 15px;
color: dark-light-choose($primary-medium, $secondary-high);
background: blend-primary-secondary(5%);
border-left: 1px solid $primary-low;
border-top: 1px solid $primary-low;
.fa {
margin: 0;
font-size: 1.286em;
font-size: $font-up-2;
line-height: 52px;
}
}
@ -312,7 +290,7 @@ a.reply-to-tab {
}

a.badge-category, a.badge-category-parent {
font-size: 0.857em;
font-size: $font-down-1;
vertical-align: top;
}
}
@ -347,8 +325,6 @@ span.post-count {
// this prevents image overflow on deeply nested blockquotes, lists, etc
.cooked {
overflow: hidden;
font-size: $base-font-size + 1; /* let's bump post body font size on mobile slightly */
line-height: $base-line-height + 2; /* bump up line height to match increased font */
}

.quote-button.visible {
@ -444,7 +420,7 @@ button.select-post {
}

.deleted-user-avatar {
font-size: 2.286em;
font-size: $font-up-5;
}

span.btn-text {display: none;}
@ -466,15 +442,15 @@ span.highlighted {

.topic-avatar {
float: left;
padding-top: 5px;
margin-right: 10px;
z-index:999; /* must render on top of topic-body + topic-meta-data, otherwise not tappable */
}

.topic-meta-data {
margin-left: 50px;
font-size: $font-down-1;
.names {
margin: 5px 0 0 5px;
line-height: 17px;
line-height: $line-height-medium;

.poster-icon {
float: right;
@ -482,7 +458,6 @@ span.highlighted {
}
.post-info {
float: right;
margin: 4px 10px 0 0;
.edits { margin-right: 5px; }
}
}

View file

@ -17,8 +17,8 @@
//margin-bottom: 20px;
margin: 0 60px 10px 0;
h1 {
font-size: 1.429em;
line-height: 1.25;
font-size: $font-up-3;
line-height: $line-height-medium;
a {
color: $primary;
vertical-align: middle;
@ -81,7 +81,7 @@
display: block;
margin-top: 2px;
margin-bottom: 2px;
font-size: 1.286em;
font-size: $font-up-2;
}
}
.jump-form {
@ -90,7 +90,7 @@
width: 45px;
height: 20px;
text-align: center;
font-size: 1.143em;
font-size: $font-up-1;
}
button.btn {
float: right !important;
@ -130,8 +130,8 @@
}
h4 {
display: inline;
font-size: 1.286em;
line-height: 15px;
font-size: $font-up-2;
line-height: $line-height-small;
}
.d-icon {
position: absolute;
@ -155,8 +155,8 @@
width: 90%;
margin-left: auto;
margin-right: auto;
font-size: 1.857em;
line-height: 1.25;
font-size: $font-up-4;
line-height: $line-height-medium;

.topic-retry {
display: block;
@ -195,7 +195,7 @@ sup sup, sub sup, sup sub, sub sub { top: 0; }
width: 100% !important;
}
.btn-small {
padding: 8px 12px;
padding: 6px 12px;
margin: 6px 6px 0 0;
}

@ -208,7 +208,7 @@ sup sup, sub sup, sup sub, sub sub { top: 0; }
// make mobile timeline top and bottom dates easier to select
.topic-timeline {
.start-date, .now-date {
font-size: 1.143em;
font-size: $font-up-1;
padding: 5px;
}
}

View file

@ -3,8 +3,8 @@
width: 520px;
}
input[type="file"] {
font-size: 1em;
line-height: 18px;
font-size: $font-0;
line-height: $line-height-medium;
}
.description {
color: dark-light-choose($primary-medium, $secondary-medium);

View file

@ -97,11 +97,11 @@

h1 {
margin: 0;
line-height: 1;
line-height: $line-height-small;
}

h2 {
line-height: normal;
line-height: $line-height-medium;
}

.primary {