aboutsummaryrefslogtreecommitdiff
path: root/.config/BetterDiscord/plugins
diff options
context:
space:
mode:
authorLoek Le Blansch <l.leblansch@gmail.com>2020-09-05 10:11:42 +0200
committerLoek Le Blansch <l.leblansch@gmail.com>2020-09-05 10:11:42 +0200
commita475f8d5d557596168195e28efcc86e86122bd1b (patch)
treef58bf473356e99d8dbfe951406c8fc2ed7102311 /.config/BetterDiscord/plugins
parent2a2f894cfda57dc6e6a4b6f6824b60dd809b4db8 (diff)
updated pywal vulnerability + other
Diffstat (limited to '.config/BetterDiscord/plugins')
-rw-r--r--.config/BetterDiscord/plugins/NotificationSounds.config.json2
-rw-r--r--.config/BetterDiscord/plugins/NotificationSounds.plugin.js21
-rw-r--r--.config/BetterDiscord/plugins/PinDMs.config.json3
-rw-r--r--.config/BetterDiscord/plugins/PinDMs.plugin.js14
4 files changed, 27 insertions, 13 deletions
diff --git a/.config/BetterDiscord/plugins/NotificationSounds.config.json b/.config/BetterDiscord/plugins/NotificationSounds.config.json
index 23be4d7..88b73e0 100644
--- a/.config/BetterDiscord/plugins/NotificationSounds.config.json
+++ b/.config/BetterDiscord/plugins/NotificationSounds.config.json
@@ -53,7 +53,7 @@
}
},
"changelog": {
- "currentversion": "3.4.7"
+ "currentversion": "3.4.9"
},
"choices": {
"message1": {
diff --git a/.config/BetterDiscord/plugins/NotificationSounds.plugin.js b/.config/BetterDiscord/plugins/NotificationSounds.plugin.js
index 0cdbc55..e40a415 100644
--- a/.config/BetterDiscord/plugins/NotificationSounds.plugin.js
+++ b/.config/BetterDiscord/plugins/NotificationSounds.plugin.js
@@ -69,7 +69,7 @@ var NotificationSounds = (_ => {
return class NotificationSounds {
getName () {return "NotificationSounds";}
- getVersion () {return "3.4.7";}
+ getVersion () {return "3.4.9";}
getAuthor () {return "DevilBro";}
@@ -77,7 +77,7 @@ var NotificationSounds = (_ => {
constructor () {
this.changelog = {
- "improved":[["Incoming","Works again"]]
+ "improved":[["Start Over","When someone calls you again the call sound now starts over instead of continuing from the last time"]]
};
this.patchedModules = {
@@ -292,9 +292,9 @@ var NotificationSounds = (_ => {
children: Object.keys(BDFDB.ObjectUtils.filter(types, typedata => !typedata.implemented)).map(type => createSoundCard(type)).flat(10).filter(n => n)
}));
- let removeableAudios = [{value:removeAllKey, label:BDFDB.LanguageUtils.LanguageStrings.FORM_LABEL_ALL}].concat(Object.keys(audios).filter(name => !defaultAudios[name]).map(name => ({value:name, label:name})));
+ let removeableCategories = [{value:removeAllKey, label:BDFDB.LanguageUtils.LanguageStrings.FORM_LABEL_ALL}].concat(Object.keys(audios).filter(category => !(defaultAudios[category] && !Object.keys(audios[category] || {}).filter(song => defaultAudios[category][song] === undefined).length)).map(name => ({value:name, label:name})));
let removeableSongs = {};
- for (let audio of removeableAudios) removeableSongs[audio.value] = [{value:removeAllKey, label:BDFDB.LanguageUtils.LanguageStrings.FORM_LABEL_ALL}].concat(Object.keys(audios[audio.value] || {}).map(name => ({value:name, label:name})));
+ for (let category of removeableCategories) removeableSongs[category.value] = [{value:removeAllKey, label:BDFDB.LanguageUtils.LanguageStrings.FORM_LABEL_ALL}].concat(Object.keys(audios[category.value] || {}).filter(song => !(defaultAudios[category.value] && defaultAudios[category.value][song] !== undefined)).map(name => ({value:name, label:name})));
settingsItems.push(BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.CollapseContainer, {
title: "Remove Songs",
collapseStates: collapseStates,
@@ -311,12 +311,13 @@ var NotificationSounds = (_ => {
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Select, {
key: "REMOVE_CATEGORY",
value: removeAllKey,
- options: removeableAudios,
+ options: removeableCategories,
searchable: true,
onChange: (category, instance) => {
let songSelectIns = BDFDB.ReactUtils.findOwner(BDFDB.ReactUtils.findOwner(instance, {name:["BDFDB_Modal", "BDFDB_SettingsPanel"], up:true}), {key:"REMOVE_SONG"});
if (songSelectIns && removeableSongs[category.value]) {
songSelectIns.props.options = removeableSongs[category.value];
+ songSelectIns.props.value = removeAllKey;
BDFDB.ReactUtils.forceUpdate(songSelectIns);
}
}
@@ -352,8 +353,8 @@ var NotificationSounds = (_ => {
let songAmount = 0;
let catAll = categorySelectIns.props.value == removeAllKey;
let songAll = songSelectIns.props.value == removeAllKey;
- if (catAll) songAmount = BDFDB.ArrayUtils.sum(Object.keys(audios).filter(name => !defaultAudios[name]).map(category => Object.keys(audios[category] || {}).length));
- else if (songAll) songAmount = Object.keys(audios[categorySelectIns.props.value] || {}).length;
+ if (catAll) songAmount = BDFDB.ArrayUtils.sum(Object.keys(audios).map(category => Object.keys(audios[category] || {}).filter(song => !(defaultAudios[category] && defaultAudios[category][song] !== undefined)).length));
+ else if (songAll) songAmount = Object.keys(audios[categorySelectIns.props.value] || {}).filter(song => !(defaultAudios[categorySelectIns.props.value] && defaultAudios[categorySelectIns.props.value][song] !== undefined)).length;
else if (audios[categorySelectIns.props.value][songSelectIns.props.value]) songAmount = 1;
if (songAmount) BDFDB.ModalUtils.confirm(this, `Are you sure you want to delete ${songAmount} added song${songAmount == 1 ? "" : "s"}?`, _ => {
@@ -382,7 +383,9 @@ var NotificationSounds = (_ => {
}
// Legacy
- load () {}
+ load () {
+ if (window.BDFDB && typeof BDFDB === "object" && BDFDB.loaded) BDFDB.PluginUtils.load(this);
+ }
start () {
if (!window.BDFDB) window.BDFDB = {myPlugins:{}};
@@ -473,11 +476,13 @@ var NotificationSounds = (_ => {
audio.volume = choices[type].volume/100;
e.returnValue.play = _ => {
if (!audio.paused || this.dontPlayAudio(type)) return;
+ audio.currentTime = 0;
audio.loop = false;
audio.play();
};
e.returnValue.loop = _ => {
if (!audio.paused || this.dontPlayAudio(type)) return;
+ audio.currentTime = 0;
audio.loop = true;
audio.play();
};
diff --git a/.config/BetterDiscord/plugins/PinDMs.config.json b/.config/BetterDiscord/plugins/PinDMs.config.json
index ef732e3..0d43d13 100644
--- a/.config/BetterDiscord/plugins/PinDMs.config.json
+++ b/.config/BetterDiscord/plugins/PinDMs.config.json
@@ -1,12 +1,13 @@
{
"changelog": {
- "currentversion": "1.7.4"
+ "currentversion": "1.7.5"
},
"dmCategories": {
"3516090637537661": {
"collapsed": false,
"color": null,
"dms": [
+ "703197442098855997",
"642833698315698232",
"456428001463369729",
"390601823523962892",
diff --git a/.config/BetterDiscord/plugins/PinDMs.plugin.js b/.config/BetterDiscord/plugins/PinDMs.plugin.js
index 4fc8b3d..17fe404 100644
--- a/.config/BetterDiscord/plugins/PinDMs.plugin.js
+++ b/.config/BetterDiscord/plugins/PinDMs.plugin.js
@@ -9,7 +9,7 @@ var PinDMs = (_ => {
return class PinDMs {
getName () {return "PinDMs";}
- getVersion () {return "1.7.4";}
+ getVersion () {return "1.7.5";}
getAuthor () {return "DevilBro";}
@@ -17,7 +17,7 @@ var PinDMs = (_ => {
constructor () {
this.changelog = {
- "fixed":[["Sort by recent","Works again"]]
+ "fixed":[["All pinned","No longer acts weird if all DMs are pinned in a category"]]
};
this.patchedModules = {
@@ -145,7 +145,9 @@ var PinDMs = (_ => {
}
// Legacy
- load () {}
+ load () {
+ if (window.BDFDB && typeof BDFDB === "object" && BDFDB.loaded) BDFDB.PluginUtils.load(this);
+ }
start () {
if (!window.BDFDB) window.BDFDB = {myPlugins:{}};
@@ -355,6 +357,12 @@ var PinDMs = (_ => {
return rowHeightFunc(...args);
};
+ let renderRow = e.returnvalue.props.renderRow;
+ e.returnvalue.props.renderRow = (...args) => {
+ let row = renderRow(...args);
+ return row && row.key == "no-private-channels" ? null : row;
+ };
+
let renderSection = e.returnvalue.props.renderSection;
e.returnvalue.props.renderSection = (...args) => {
if (args[0].section != 0 && args[0].section != e.returnvalue.props.sections.length - 1) {