1
0
mirror of https://github.com/flarum/core.git synced 2025-07-31 13:40:20 +02:00

Don't apply background color if there is none

This commit is contained in:
Toby Zerner
2015-07-18 10:55:56 +09:30
parent 7706914b33
commit 24f100899c

View File

@@ -26,10 +26,11 @@ export default class UserCard extends Component {
view() {
const user = this.props.user;
const controls = UserControls.controls(user, this).toArray();
const color = user.color();
return (
<div className={'UserCard ' + (this.props.className || '')}
style={{backgroundColor: user.color()}}>
style={color ? {backgroundColor: color} : ''}>
<div className="darkenBackground">
<div className="container">