This commit is contained in:
Mirco Wittrien 2021-04-08 16:00:33 +02:00
parent aecbf83418
commit 9a8ad3a504
2 changed files with 5 additions and 4 deletions

View File

@ -1652,6 +1652,7 @@
"channelmodeselected": ["Channel", "modeSelected"], "channelmodeselected": ["Channel", "modeSelected"],
"channelmodeunread": ["Channel", "modeUnread"], "channelmodeunread": ["Channel", "modeUnread"],
"channelname": ["Channel", "name"], "channelname": ["Channel", "name"],
"channelnameinner": ["Channel", "channelName"],
"channelpanel": ["AppBase", "activityPanel"], "channelpanel": ["AppBase", "activityPanel"],
"channelpaneltitle": ["NotFound", "channelPanelTitle"], "channelpaneltitle": ["NotFound", "channelPanelTitle"],
"channelpanels": ["AppBase", "panels"], "channelpanels": ["AppBase", "panels"],

View File

@ -2,7 +2,7 @@
* @name EditChannels * @name EditChannels
* @author DevilBro * @author DevilBro
* @authorId 278543574059057154 * @authorId 278543574059057154
* @version 4.2.6 * @version 4.2.7
* @description Allows you to locally edit Channels * @description Allows you to locally edit Channels
* @invite Jx3TjNS * @invite Jx3TjNS
* @donate https://www.paypal.me/MircoWittrien * @donate https://www.paypal.me/MircoWittrien
@ -17,12 +17,12 @@ module.exports = (_ => {
"info": { "info": {
"name": "EditChannels", "name": "EditChannels",
"author": "DevilBro", "author": "DevilBro",
"version": "4.2.6", "version": "4.2.7",
"description": "Allows you to locally edit Channels" "description": "Allows you to locally edit Channels"
}, },
"changeLog": { "changeLog": {
"fixed": { "fixed": {
"Mentions": "" "Gradient": "Works for Channels again"
} }
} }
}; };
@ -373,7 +373,7 @@ module.exports = (_ => {
if (!e.returnvalue) e.instance.props.channel = this.getChannelData(e.instance.props.channel.id); if (!e.returnvalue) e.instance.props.channel = this.getChannelData(e.instance.props.channel.id);
else { else {
let modify = BDFDB.ObjectUtils.extract(Object.assign({}, e.instance.props, e.instance.state), "muted", "locked", "selected", "unread", "connected", "hovered"); let modify = BDFDB.ObjectUtils.extract(Object.assign({}, e.instance.props, e.instance.state), "muted", "locked", "selected", "unread", "connected", "hovered");
let channelName = BDFDB.ReactUtils.findChild(e.returnvalue, {props: [["className", BDFDB.disCN.channelname]]}); let channelName = BDFDB.ReactUtils.findChild(e.returnvalue, {props: [["className", BDFDB.disCN.channelnameinner]]});
if (channelName) this.changeChannelColor(channelName, e.instance.props.channel.id, modify); if (channelName) this.changeChannelColor(channelName, e.instance.props.channel.id, modify);
let channelIcon = settings.changeChannelIcon && BDFDB.ReactUtils.findChild(e.returnvalue, {name: "ChannelItemIcon"}); let channelIcon = settings.changeChannelIcon && BDFDB.ReactUtils.findChild(e.returnvalue, {name: "ChannelItemIcon"});
if (channelIcon && typeof channelIcon.type == "function") { if (channelIcon && typeof channelIcon.type == "function") {