add/cleanChannelGroups (#723)
* Add cleanChannelGroups * update patches --------- Co-authored-by: thororen1234 <78185467+thororen1234@users.noreply.github.com>
This commit is contained in:
parent
b2b4031702
commit
12b3331dfc
1 changed files with 29 additions and 0 deletions
29
src/equicordplugins/cleanerChannelGroups/index.ts
Normal file
29
src/equicordplugins/cleanerChannelGroups/index.ts
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
/*
|
||||
* Vencord, a Discord client mod
|
||||
* Copyright (c) 2026 Vendicated and contributors
|
||||
* SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*/
|
||||
|
||||
import { EquicordDevs } from "@utils/constants";
|
||||
import definePlugin from "@utils/types";
|
||||
|
||||
export default definePlugin({
|
||||
name: "CleanerChannelGroups",
|
||||
description: "Hides all channels in collapsed categories, even if they have unread messages.",
|
||||
authors: [EquicordDevs.justjxke],
|
||||
patches: [
|
||||
{
|
||||
find: '"placeholder-channel-id"',
|
||||
replacement: [
|
||||
{
|
||||
match: /this\.category\.isCollapsed&&\(.{0,600}?\)\?\{renderLevel:3,threadIds:/,
|
||||
replace: "this.category.isCollapsed?{renderLevel:3,threadIds:"
|
||||
},
|
||||
{
|
||||
match: /(?<=!this.category.isCollapsed.{0,50}\i=)(\i\(this\.record,.{0,5},\i\.hideMutedChannels\);)/,
|
||||
replace: "this.category.isCollapsed?[]:$1"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
});
|
||||
Loading…
Add table
Reference in a new issue