2020-07-13 11:22:24 -04:00
|
|
|
export const SERVER_BUFFER = "*";
|
|
|
|
|
2020-06-26 04:35:38 -04:00
|
|
|
export const BufferType = {
|
|
|
|
SERVER: "server",
|
|
|
|
CHANNEL: "channel",
|
|
|
|
NICK: "nick",
|
|
|
|
};
|
2020-06-24 10:56:28 -04:00
|
|
|
|
|
|
|
export const Status = {
|
|
|
|
DISCONNECTED: "disconnected",
|
|
|
|
CONNECTING: "connecting",
|
|
|
|
REGISTERED: "registered",
|
|
|
|
};
|
|
|
|
|
|
|
|
export const Unread = {
|
|
|
|
NONE: "",
|
|
|
|
MESSAGE: "message",
|
2020-06-29 05:08:47 -04:00
|
|
|
HIGHLIGHT: "highlight",
|
2020-06-24 10:56:28 -04:00
|
|
|
|
|
|
|
union: (a, b) => {
|
|
|
|
const priority = {
|
|
|
|
[Unread.None]: 0,
|
|
|
|
[Unread.MESSAGE]: 1,
|
2020-06-29 05:08:47 -04:00
|
|
|
[Unread.HIGHLIGHT]: 2,
|
2020-06-24 10:56:28 -04:00
|
|
|
};
|
|
|
|
return (priority[a] > priority[b]) ? a : b;
|
|
|
|
},
|
|
|
|
};
|