This commit is contained in:
Mirco Wittrien 2021-01-30 12:36:34 +01:00
parent 2611246e18
commit 2fcc57baf8
5 changed files with 57 additions and 44 deletions

View File

@ -16,14 +16,13 @@ module.exports = (_ => {
"info": {
"name": "BDFDB",
"author": "DevilBro",
"version": "1.3.3",
"version": "1.3.4",
"description": "Give other plugins utility functions"
},
"rawUrl": "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js",
"changeLog": {
"improved": {
"New Toast API": "Changed Toast API to add new functionalities and styles",
"Toast Positions": "You can now change the default Position of Toasts (left/right/center) in the BDFDB Settings"
"Canary Changes": "Preparing Plugins for the changes that are already done on Discord Canary"
}
}
};
@ -2080,8 +2079,8 @@ module.exports = (_ => {
try {
let filteredModules = BDFDB.ArrayUtils.removeCopies(updateDataArray.map(n => n.filteredModules).flat(10));
let specialModules = BDFDB.ArrayUtils.removeCopies(updateDataArray.map(n => n.specialModules).flat(10));
const appInsDown = BDFDB.ReactUtils.findOwner(app, {name: filteredModules, type: specialModules, all: true, group: true, unlimited: true});
const appInsUp = BDFDB.ReactUtils.findOwner(app, {name: filteredModules, type: specialModules, all: true, group: true, unlimited: true, up: true});
const appInsDown = BDFDB.ReactUtils.findOwner(app, {name: filteredModules, type: specialModules, all: true, unlimited: true, group: true});
const appInsUp = BDFDB.ReactUtils.findOwner(app, {name: filteredModules, type: specialModules, all: true, unlimited: true, group: true, up: true});
for (let type in appInsDown) {
let filteredPlugins = plugins.filter(n => updateData[n.name].filteredModules.includes(type) || updateData[n.name].specialModuleTypes.includes(type)).map(n => ({plugin: n, patchTypes: updateData[n.name].patchTypes}));
for (let ins of appInsDown[type]) InternalBDFDB.forceInitiateProcess(filteredPlugins, ins, type);
@ -2635,11 +2634,10 @@ module.exports = (_ => {
catch (err) {BDFDB.LogUtils.error("Could not render react element! " + err);}
};
let MessageRerenderTimeout;
BDFDB.MessageUtils = {};
BDFDB.MessageUtils.rerenderAll = function (instant) {
BDFDB.TimeUtils.clear(MessageRerenderTimeout);
MessageRerenderTimeout = BDFDB.TimeUtils.timeout(_ => {
BDFDB.TimeUtils.clear(BDFDB.MessageUtils.rerenderAll.timeout);
BDFDB.MessageUtils.rerenderAll.timeout = BDFDB.TimeUtils.timeout(_ => {
let channel = BDFDB.LibraryModules.ChannelStore.getChannel(BDFDB.LibraryModules.LastChannelStore.getChannelId());
if (channel) {
if (BDFDB.DMUtils.isDMChannel(channel)) BDFDB.DMUtils.markAsRead(channel);
@ -2648,8 +2646,9 @@ module.exports = (_ => {
let LayerProviderIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.messageswrapper), {name: "LayerProvider", unlimited: true, up: true});
let LayerProviderPrototype = BDFDB.ObjectUtils.get(LayerProviderIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`);
if (LayerProviderIns && LayerProviderPrototype) {
BDFDB.PatchUtils.patch(BDFDB, LayerProviderPrototype, "render", {after: e => {
e.returnValue.props.children = [];
BDFDB.PatchUtils.patch({name: "BDFDB MessageUtils"}, LayerProviderPrototype, "render", {after: e => {
e.returnValue.props.children = typeof e.returnValue.props.children == "function" ? (_ => {return null;}) : [];
BDFDB.ReactUtils.forceUpdate(LayerProviderIns);
}}, {once: true});
BDFDB.ReactUtils.forceUpdate(LayerProviderIns);
}
@ -2725,7 +2724,6 @@ module.exports = (_ => {
});
};
let GuildsRerenderTimeout;
BDFDB.GuildUtils = {};
BDFDB.GuildUtils.is = function (guild) {
if (!BDFDB.ObjectUtils.is(guild)) return false;
@ -2835,8 +2833,8 @@ module.exports = (_ => {
if (unreadChannels.length) BDFDB.ChannelUtils.markAsRead(unreadChannels);
};
BDFDB.GuildUtils.rerenderAll = function (instant) {
BDFDB.TimeUtils.clear(GuildsRerenderTimeout);
GuildsRerenderTimeout = BDFDB.TimeUtils.timeout(_ => {
BDFDB.TimeUtils.clear(BDFDB.GuildUtils.rerenderAll.timeout);
BDFDB.GuildUtils.rerenderAll.timeout = BDFDB.TimeUtils.timeout(_ => {
let GuildsIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.app), {name: "Guilds", unlimited: true});
let GuildsPrototype = BDFDB.ObjectUtils.get(GuildsIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`);
if (GuildsIns && GuildsPrototype) {
@ -2845,7 +2843,7 @@ module.exports = (_ => {
if (index > -1) children.splice(index + 1, 0, BDFDB.ReactUtils.createElement("div", {}));
BDFDB.ReactUtils.forceUpdate(GuildsIns);
};
BDFDB.PatchUtils.patch(BDFDB, GuildsPrototype, "render", {after: e => {
BDFDB.PatchUtils.patch({name: "BDFDB GuildUtils"}, GuildsPrototype, "render", {after: e => {
if (typeof e.returnValue.props.children == "function") {
let childrenRender = e.returnValue.props.children;
e.returnValue.props.children = (...args) => {
@ -2899,7 +2897,6 @@ module.exports = (_ => {
return found;
};
let ChannelsRerenderTimeout;
BDFDB.ChannelUtils = {};
BDFDB.ChannelUtils.is = function (channel) {
if (!BDFDB.ObjectUtils.is(channel)) return false;
@ -2974,12 +2971,12 @@ module.exports = (_ => {
if (unreadChannels.length) LibraryModules.AckUtils.bulkAck(unreadChannels);
};
BDFDB.ChannelUtils.rerenderAll = function (instant) {
BDFDB.TimeUtils.clear(ChannelsRerenderTimeout);
ChannelsRerenderTimeout = BDFDB.TimeUtils.timeout(_ => {
BDFDB.TimeUtils.clear(BDFDB.ChannelUtils.rerenderAll.timeout);
BDFDB.ChannelUtils.rerenderAll.timeout = BDFDB.TimeUtils.timeout(_ => {
let ChannelsIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.guildchannels), {name: "Channels", unlimited: true});
let ChannelsPrototype = BDFDB.ObjectUtils.get(ChannelsIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`);
if (ChannelsIns && ChannelsPrototype) {
BDFDB.PatchUtils.patch(BDFDB, ChannelsPrototype, "render", {after: e => {
BDFDB.PatchUtils.patch({name: "BDFDB ChannelUtils"}, ChannelsPrototype, "render", {after: e => {
e.returnValue.props.children = typeof e.returnValue.props.children == "function" ? (_ => {return null;}) : [];
BDFDB.ReactUtils.forceUpdate(ChannelsIns);
}}, {once: true});
@ -4182,7 +4179,21 @@ module.exports = (_ => {
return parseInt(document.firstElementChild.style.fontSize.replace("%", ""));
};
BDFDB.DiscordUtils.shake = function () {
BDFDB.ReactUtils.getInstance(document.querySelector(BDFDB.dotCN.appinner)).return.stateNode.shake();
BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.appcontainer), {name: "Shakeable", unlimited: true, up: true}).shake();
};
BDFDB.DiscordUtils.rerenderAll = function (instant) {
BDFDB.TimeUtils.clear(BDFDB.DiscordUtils.rerenderAll.timeout);
BDFDB.DiscordUtils.rerenderAll.timeou = BDFDB.TimeUtils.timeout(_ => {
let ShakeableIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.appcontainer), {name: "Shakeable", unlimited: true, up: true});
let ShakeablePrototype = BDFDB.ObjectUtils.get(ShakeableIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`);
if (ShakeableIns && ShakeablePrototype) {
BDFDB.PatchUtils.patch({name: "BDFDB DiscordUtils"}, ShakeablePrototype, "render", {after: e => {
e.returnValue.props.children = typeof e.returnValue.props.children == "function" ? (_ => {return null;}) : [];
BDFDB.ReactUtils.forceUpdate(ShakeableIns);
}}, {once: true});
BDFDB.ReactUtils.forceUpdate(ShakeableIns);
}
}, instant ? 0 : 1000);
};
BDFDB.WindowUtils = {};
@ -5147,7 +5158,7 @@ module.exports = (_ => {
}
componentDidMount() {
this.domElementRef = {current: BDFDB.DOMUtils.getParent(BDFDB.dotCN.itemlayer, BDFDB.ReactUtils.findDOMNode(this))};
let popoutContainerInstance = BDFDB.ReactUtils.findOwner(this.domElementRef.current, {name: "BDFDB_PopoutContainer", up: true, unlimited: true});
let popoutContainerInstance = BDFDB.ReactUtils.findOwner(this.domElementRef.current, {name: "BDFDB_PopoutContainer", unlimited: true, up: true});
if (popoutContainerInstance) {
let mousedown = event => {
if (!this.domElementRef.current || !document.contains(this.domElementRef.current)) document.removeEventListener("mousedown", mousedown);
@ -7440,6 +7451,7 @@ module.exports = (_ => {
PrivateChannel: ["componentDidMount", "componentDidUpdate"],
UserPopout: ["componentDidMount", "componentDidUpdate"],
UserProfile: ["componentDidMount", "componentDidUpdate"],
Shakeable: "render",
V2C_ContentColumn: "render"
}
};
@ -7479,6 +7491,12 @@ module.exports = (_ => {
}
};
let AppViewExport = BDFDB.ModuleUtils.findByName("AppView", false);
if (AppViewExport) InternalBDFDB.processShakeable = function (e) {
let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {name: "AppView"});
if (index > -1) children[index] = BDFDB.ReactUtils.createElement(AppViewExport.exports.default, children[index].props);
};
let MessageHeaderExport = BDFDB.ModuleUtils.findByProperties("MessageTimestamp", false);
InternalBDFDB.processMessage = function (e) {
if (MessageHeaderExport && BDFDB.ObjectUtils.get(e, "instance.props.childrenHeader.type.type.name") && BDFDB.ObjectUtils.get(e, "instance.props.childrenHeader.props.message")) {

View File

@ -369,7 +369,7 @@ module.exports = (_ => {
size: BDFDB.LibraryComponents.Button.Sizes.MIN,
color: BDFDB.LibraryComponents.Button.Colors[buttonConfig.colorClass],
style: {backgroundColor: BDFDB.DiscordConstants.Colors[buttonConfig.backgroundColor] || buttonConfig.backgroundColor},
children: buttonConfig.text,
children: BDFDB.LanguageUtils.LibraryStrings[buttonConfig.text],
onClick: (e, instance) => {
_this.downloadPlugin(this.props.plugin);
if (list && list.props.rnmStart) BDFDB.TimeUtils.timeout(_ => {

View File

@ -14,7 +14,7 @@ module.exports = (_ => {
"info": {
"name": "ServerFolders",
"author": "DevilBro",
"version": "6.8.7",
"version": "6.8.8",
"description": "Patch Discords native Folders in a way to open Servers within a Folder in a new bar to the right, also adds a bunch of new features to more easily organize, customize and manage your Folders"
},
"changeLog": {
@ -250,7 +250,7 @@ module.exports = (_ => {
}
};
var redCross = `'data:image/svg+xml; base64, PHN2ZyB4bWxuczp4bGluaz0iaHR0cDovL3d3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i4zNDMsNDAuNDAwIDE3LjE3OHoiIGZpbGw9InJnYigyNDAsIDcxLCA3MSkiPjwvcGF0aD48L3N2Zz4='`;
const redCross = `'data:image/svg+xml; utf8, <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20"><g fill="none" stroke="rgb(240,71,71)" stroke-width="2.63295174" stroke-linecap="round"><pathd="M 2.3297741,2.3297744 17.669885,17.670227"/><path d="M 17.66721,2.3327927 2.3327902,17.667207"/></svg>'`;
const folderIconCustomPreviewComponent = class FolderIconCustomPreview extends BdApi.React.Component {
componentDidMount() {
@ -406,7 +406,7 @@ module.exports = (_ => {
this.patchedModules = {
after: {
AppView: "render",
AppView: "default",
GuildFolder: "type",
Guilds: "render",
Guild: ["componentDidMount", "render"],
@ -555,7 +555,7 @@ module.exports = (_ => {
BDFDB.ReactUtils.forceUpdate(folderGuildContent);
BDFDB.PatchUtils.forceAllUpdates(this);
BDFDB.GuildUtils.rerenderAll();
BDFDB.DiscordUtils.rerenderAll();
}
onGuildContextMenu (e) {
@ -654,7 +654,7 @@ module.exports = (_ => {
processAppView (e) {
if (settings.extraColumn) {
let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {name: ["FluxContainer(Guilds)", "FluxContainer(NavigableGuilds)"]});
let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {props: [["className", BDFDB.disCN.guilds]]});
if (index > -1) children.splice(index + 1, 0, BDFDB.ReactUtils.createElement(folderGuildContentComponent, {
themeOverride: children[index].props.themeOverride
}, true));

View File

@ -14,12 +14,12 @@ module.exports = (_ => {
"info": {
"name": "SpotifyControls",
"author": "DevilBro",
"version": "1.1.0",
"version": "1.1.1",
"description": "Add a control panel to discord when listening to spotify"
},
"changeLog": {
"improved": {
"Double Click Back": "Added option to allow ppl to go back to the previous song without having to double click the back button"
"Canary Changes": "Preparing Plugins for the changes that are already done on Discord Canary"
}
}
};
@ -64,7 +64,6 @@ module.exports = (_ => {
}
} : (([Plugin, BDFDB]) => {
var _this;
var insertPatchCancel;
var controls, starting, lastSong, currentVolume, lastVolume, stopTime, previousIsClicked, previousDoubleTimeout, timelineTimeout, timelineDragging, updateInterval;
var playbackState = {};
var settings = {}, buttonConfigs = {};
@ -432,8 +431,8 @@ module.exports = (_ => {
};
this.patchedModules = {
before: {
AppView: "render"
after: {
AppView: "default"
}
};
@ -631,7 +630,7 @@ module.exports = (_ => {
contents: BDFDB.LanguageUtils.LanguageStrings.CONNECT,
color: "BRAND",
close: true,
onClick: _ => {
onClick: modal => {
BDFDB.LibraryModules.UserSettingsUtils.open(BDFDB.DiscordConstants.UserSettingsSections.CONNECTIONS)
}
}]
@ -642,8 +641,6 @@ module.exports = (_ => {
onStop () {
this.forceUpdateAll();
if (typeof insertPatchCancel == "function") insertPatchCancel();
}
getSettingsPanel (collapseStates = {}) {
@ -718,18 +715,16 @@ module.exports = (_ => {
buttonConfigs = BDFDB.DataUtils.get(this, "buttonConfigs");
BDFDB.PatchUtils.forceAllUpdates(this);
BDFDB.DiscordUtils.rerenderAll();
}
processAppView (e) {
if (typeof insertPatchCancel == "function") insertPatchCancel();
insertPatchCancel = BDFDB.PatchUtils.patch(this, e.instance, "renderChannelSidebar", {after: e2 => {
let [children, index] = BDFDB.ReactUtils.findParent(e2.returnValue, {props: [["section", BDFDB.DiscordConstants.AnalyticsSections.ACCOUNT_PANEL]]});
if (index > -1) children.splice(index - 1, 0, BDFDB.ReactUtils.createElement(SpotifyControlsComponent, {
song: BDFDB.LibraryModules.SpotifyTrackUtils.getActivity(false),
maximized: BDFDB.DataUtils.load(this, "playerState", "maximized"),
timeline: settings.addTimeline
}, true));
}}, {force: true, noCache: true});
let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {props: [["section", BDFDB.DiscordConstants.AnalyticsSections.ACCOUNT_PANEL]]});
if (index > -1) children.splice(index - 1, 0, BDFDB.ReactUtils.createElement(SpotifyControlsComponent, {
song: BDFDB.LibraryModules.SpotifyTrackUtils.getActivity(false),
maximized: BDFDB.DataUtils.load(this, "playerState", "maximized"),
timeline: settings.addTimeline
}, true));
}
updatePlayer (song) {

View File

@ -661,7 +661,7 @@ module.exports = (_ => {
size: BDFDB.LibraryComponents.Button.Sizes.MIN,
color: BDFDB.LibraryComponents.Button.Colors[buttonConfig.colorClass],
style: {backgroundColor: BDFDB.DiscordConstants.Colors[buttonConfig.backgroundColor] || buttonConfig.backgroundColor},
children: buttonConfig.text,
children: BDFDB.LanguageUtils.LibraryStrings[buttonConfig.text],
onClick: (e, instance) => {
_this.downloadTheme(this.props.theme);
if (list && list.props.rnmStart) BDFDB.TimeUtils.timeout(_ => {