forked from CringeStudios/gamja
Display messages with a highlight differently
This commit is contained in:
parent
917b348992
commit
9cc44fbe98
@ -274,6 +274,8 @@ export default class App extends Component {
|
|||||||
msg.key = messagesCount;
|
msg.key = messagesCount;
|
||||||
messagesCount++;
|
messagesCount++;
|
||||||
|
|
||||||
|
msg.isHighlight = irc.isHighlight(msg, this.client.nick);
|
||||||
|
|
||||||
if (!msg.tags) {
|
if (!msg.tags) {
|
||||||
msg.tags = {};
|
msg.tags = {};
|
||||||
}
|
}
|
||||||
@ -291,7 +293,7 @@ export default class App extends Component {
|
|||||||
var text = msg.params[1];
|
var text = msg.params[1];
|
||||||
|
|
||||||
var kind;
|
var kind;
|
||||||
if (irc.isHighlight(msg, this.client.nick)) {
|
if (msg.isHighlight) {
|
||||||
msgUnread = Unread.HIGHLIGHT;
|
msgUnread = Unread.HIGHLIGHT;
|
||||||
kind = "highlight";
|
kind = "highlight";
|
||||||
} else if (target == this.client.nick) {
|
} else if (target == this.client.nick) {
|
||||||
|
@ -70,6 +70,10 @@ class LogLine extends Component {
|
|||||||
lineClass = "talk";
|
lineClass = "talk";
|
||||||
content = html`${"<"}${createNick(msg.prefix.name)}${">"} ${linkify(stripANSI(text))}`;
|
content = html`${"<"}${createNick(msg.prefix.name)}${">"} ${linkify(stripANSI(text))}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (msg.isHighlight) {
|
||||||
|
lineClass += " highlight";
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case "JOIN":
|
case "JOIN":
|
||||||
content = html`
|
content = html`
|
||||||
|
Loading…
x
Reference in New Issue
Block a user