Merge pull request #4669 from thelounge/collapseAway

allow away and back to be collapsed
This commit is contained in:
Max Leiter 2023-01-20 15:30:53 -08:00 committed by GitHub
commit 2803018c5a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 24 additions and 2 deletions

View file

@ -118,6 +118,18 @@ export default defineComponent({
(obj[type] > 1 ? " modes were set" : " mode was set")
);
break;
case "away":
strings.push(
"marked away " +
(obj[type] > 1 ? String(obj[type]) + " times" : "once")
);
break;
case "back":
strings.push(
"marked back " +
(obj[type] > 1 ? String(obj[type]) + " times" : "once")
);
break;
}
}
});

View file

@ -177,7 +177,7 @@ export default defineComponent({
});
const condensedMessages = computed(() => {
if (props.channel.type !== "channel") {
if (props.channel.type !== "channel" && props.channel.type !== "query") {
return props.channel.messages;
}

View file

@ -17,7 +17,17 @@ const colorCodeMap = [
["15", "Light Grey"],
];
const condensedTypes = new Set(["chghost", "join", "part", "quit", "nick", "kick", "mode"]);
const condensedTypes = new Set([
"away",
"back",
"chghost",
"join",
"kick",
"mode",
"nick",
"part",
"quit",
]);
const timeFormats = {
msgDefault: "HH:mm",