Use HSLuv for nick colors
This commit is contained in:
parent
6146b27adc
commit
afc80650e7
6 changed files with 19 additions and 12 deletions
|
@ -1,6 +1,6 @@
|
|||
import React, { PureComponent } from 'react';
|
||||
import classnames from 'classnames';
|
||||
import stringToHSL from 'utils/color';
|
||||
import stringToRGB from 'utils/color';
|
||||
|
||||
export default class Message extends PureComponent {
|
||||
handleNickClick = () => this.props.onNickClick(this.props.message.from);
|
||||
|
@ -20,7 +20,7 @@ export default class Message extends PureComponent {
|
|||
|
||||
const senderStyle = {};
|
||||
if (message.from) {
|
||||
senderStyle.color = stringToHSL(message.from);
|
||||
senderStyle.color = stringToRGB(message.from);
|
||||
}
|
||||
|
||||
return (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue