mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-07 14:35:47 +01:00
update buildCategoryLabel
no bg image in labels dont put a i tag if no icon
This commit is contained in:
@@ -98,8 +98,8 @@ module.exports = function (utils, Benchpress, relative_path) {
|
|||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
return `<span class="badge px-1 ${className}" style="${generateCategoryBackground(category)}">
|
return `<span class="badge px-1 ${className}" style="color: ${category.color};background-color: ${category.bgColor};border-color: ${category.bgColor};">
|
||||||
${category.icon ? `<i class="fa fa-fw ${category.icon}"></i>` : ''}
|
${category.icon && category.icon !== 'fa-nbb-none' ? `<i class="fa fa-fw ${category.icon}"></i>` : ''}
|
||||||
${category.name}
|
${category.name}
|
||||||
</span>`;
|
</span>`;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user