mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-28 01:56:01 -05:00
Fix layout of category badges on categories page and in combobox
This commit is contained in:
parent
96af490d7c
commit
44bebf255d
3 changed files with 8 additions and 4 deletions
|
@ -27,10 +27,10 @@ Discourse.CategoryChooserView = Discourse.ComboboxView.extend({
|
||||||
template: function(text, templateData) {
|
template: function(text, templateData) {
|
||||||
if (!templateData.color) return text;
|
if (!templateData.color) return text;
|
||||||
|
|
||||||
var result = "<span class='badge-category' style='background-color: #" + templateData.color + '; color: #' +
|
var result = "<div class='badge-category' style='background-color: #" + templateData.color + '; color: #' +
|
||||||
templateData.text_color + ";'>" + templateData.name + "</span>";
|
templateData.text_color + ";'>" + templateData.name + "</div>";
|
||||||
|
|
||||||
result += " <span class='topic-count'>× " + templateData.topic_count + "</span>";
|
result += " <div class='topic-count'>× " + templateData.topic_count + "</div>";
|
||||||
|
|
||||||
var description = templateData.description_text;
|
var description = templateData.description_text;
|
||||||
// TODO wtf how can this be null?
|
// TODO wtf how can this be null?
|
||||||
|
|
|
@ -1,7 +1,11 @@
|
||||||
.category-combobox {
|
.category-combobox {
|
||||||
|
.badge-category {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
.topic-count {
|
.topic-count {
|
||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
color: #666;
|
color: #666;
|
||||||
|
display: inline-block;
|
||||||
}
|
}
|
||||||
.highlighted .topic-count {
|
.highlighted .topic-count {
|
||||||
color: white;
|
color: white;
|
||||||
|
|
|
@ -221,7 +221,7 @@
|
||||||
}
|
}
|
||||||
.badge-category {
|
.badge-category {
|
||||||
float: left;
|
float: left;
|
||||||
margin: 3px 4px 0 0;
|
margin: 1px 4px 0 0;
|
||||||
}
|
}
|
||||||
.posters {
|
.posters {
|
||||||
float: left;
|
float: left;
|
||||||
|
|
Loading…
Reference in a new issue