This commit is contained in:
Mirco Wittrien 2021-03-23 14:55:26 +01:00
parent 54bb9731e9
commit 1c52462965
6 changed files with 51 additions and 14 deletions

View File

@ -2069,7 +2069,7 @@ module.exports = (_ => {
let tempReturn = BDFDB.TimeUtils.suppress(module.BDFDB_patches[methodName].instead[priority][id], `"instead" callback of ${methodName} in ${name}`, {name: module.BDFDB_patches[methodName].instead[priority][id].pluginName, version: module.BDFDB_patches[methodName].instead[priority][id].pluginVersion})(data);
if (tempReturn !== undefined) data.returnValue = tempReturn;
}
if ((!hasInsteadPatches || callInstead) && !stopCall) BDFDB.TimeUtils.suppress(data.callOriginalMethod, `originalMethod of ${methodName} in ${name}`)();
if ((!hasInsteadPatches || callInstead) && !stopCall) BDFDB.TimeUtils.suppress(data.callOriginalMethod, `originalMethod of ${methodName} in ${name}`, {name: "Discord"})();
if (!module.BDFDB_patches || !module.BDFDB_patches[methodName]) return methodName == "render" && data.returnValue === undefined ? null : data.returnValue;
for (let priority in module.BDFDB_patches[methodName].after) for (let id in BDFDB.ObjectUtils.sort(module.BDFDB_patches[methodName].after[priority])) {
@ -3603,9 +3603,12 @@ module.exports = (_ => {
let titleChildren = [], headerChildren = [], contentChildren = [], footerChildren = [];
if (typeof config.text == "string") contentChildren.push(BDFDB.ReactUtils.createElement(InternalComponents.LibraryComponents.TextElement, {
if (typeof config.text == "string") {
config.contentClassName = BDFDB.DOMUtils.formatClassName(config.contentClassName, BDFDB.disCN.modaltextcontent);
contentChildren.push(BDFDB.ReactUtils.createElement(InternalComponents.LibraryComponents.TextElement, {
children: config.text
}));
}
if (config.children) {
let tabBarItems = [], tabIns = {};
@ -7803,6 +7806,13 @@ module.exports = (_ => {
changeLogs = BDFDB.DataUtils.load(BDFDB, "changeLogs");
BDFDB.PluginUtils.checkChangeLog(BDFDB);
if (window.Lightcord || window.LightCord) BDFDB.ModalUtils.open(BDFDB, {
header: "Attention!",
subHeader: "Modified Client detected",
text: "We detected that you are using LightCord. Unlike other Client Modificaton (BD, PowerCord), LightCord is a completely modified Client, which is no longer maintained by Discord but instead by a 3rd Party. This will put your Account to risk, not only because the 3rd Party might due with your Account Credentials as they like, you are also breaking a higher Instance of Discord's ToS by using a 3rd Party Client instead of using a simple Client Mod. Many Plugins won't flawlessly run on LightCord. We do not support LightCord and as such, we do not provide Help or Support. You should switch to another Modification.",
buttons: [{color: "RED", contents: BDFDB.LanguageUtils.LanguageStrings.OKAY}]
});
InternalBDFDB.patchPlugin(BDFDB);
for (let type of QueuedComponents) if (!PluginStores.patchQueues[type]) PluginStores.patchQueues[type] = {query: [], modules: []};

View File

@ -605,6 +605,7 @@
"modalTabContent": "tabContent-nZ-1U5",
"modalTabContentOpen": "open-yICTYu",
"modalSubInner": "inner-t84Frz",
"modalTextContent": "text-8fSrts",
"modalWrapper": "modal-6GHvdM",
"multiInput": "multiInput-Ft9zQo",
"multiInputField": "multiInputField-GfMBpr",
@ -2412,6 +2413,7 @@
"modalsubinner": ["BDFDB", "modalSubInner"],
"modaltabcontent": ["BDFDB", "modalTabContent"],
"modaltabcontentopen": ["BDFDB", "modalTabContentOpen"],
"modaltextcontent": ["BDFDB", "modalTextContent"],
"modalwrapper": ["BDFDB", "modalWrapper"],
"modedefault": ["FormText", "modeDefault"],
"modedisabled": ["FormText", "modeDisabled"],

View File

@ -801,6 +801,9 @@ img:not([src]), img[src=""], img[src="null"] {
padding-left: 16px;
padding-right: 8px;
}
[REPLACE_CLASS_modaltextcontent] {
padding-bottom: 10px;
}
[REPLACE_CLASS_modalnoscroller] {
overflow: hidden;
}

View File

@ -2447,16 +2447,25 @@ body::before {
fill: rgb(var(--fontwhite1));
}
.bd-social-logo {
opacity: 1;
.bd-social-link[title="BD" i] .bd-social-logo,
.bd-social-link[title="BetterDiscord" i] .bd-social-logo,
.bd-social-link[title="BBD" i] .bd-social-logo,
.bd-social-link[title="BandagedBD" i] .bd-social-logo {
background: rgb(var(--fontwhite3));
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/betterdiscord.svg) center/contain no-repeat;
opacity: 1;
transition: background .15s ease;
}
.bd-social-link:hover .bd-social-logo {
.bd-social-link[title="BD" i]:hover .bd-social-logo,
.bd-social-link[title="BetterDiscord" i]:hover .bd-social-logo,
.bd-social-link[title="BBD" i]:hover .bd-social-logo,
.bd-social-link[title="BandagedBD" i]:hover .bd-social-logo {
background: rgb(var(--fontwhite1));
}
.bd-social-logo > * {
.bd-social-link[title="BD" i] .bd-social-logo > *,
.bd-social-link[title="BetterDiscord" i] .bd-social-logo > *,
.bd-social-link[title="BBD" i] .bd-social-logo > *,
.bd-social-link[title="BandagedBD" i] .bd-social-logo > * {
display: none;
}

View File

@ -2081,16 +2081,25 @@ img[src='/assets/58957d928db6fb9d4658eb882f33d7bc.svg'] {
fill: var(--header-primary);
}
.bd-social-logo {
opacity: 1;
.bd-social-link[title="BD" i] .bd-social-logo,
.bd-social-link[title="BetterDiscord" i] .bd-social-logo,
.bd-social-link[title="BBD" i] .bd-social-logo,
.bd-social-link[title="BandagedBD" i] .bd-social-logo {
background: var(--text-muted);
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/betterdiscord.svg) center/contain no-repeat;
opacity: 1;
transition: background .15s ease;
}
.bd-social-link:hover .bd-social-logo {
.bd-social-link[title="BD" i]:hover .bd-social-logo,
.bd-social-link[title="BetterDiscord" i]:hover .bd-social-logo,
.bd-social-link[title="BBD" i]:hover .bd-social-logo,
.bd-social-link[title="BandagedBD" i]:hover .bd-social-logo {
background: var(--header-primary);
}
.bd-social-logo > * {
.bd-social-link[title="BD" i] .bd-social-logo > *,
.bd-social-link[title="BetterDiscord" i] .bd-social-logo > *,
.bd-social-link[title="BBD" i] .bd-social-logo > *,
.bd-social-link[title="BandagedBD" i] .bd-social-logo > * {
display: none;
}

View File

@ -97,6 +97,8 @@
#bd-settings-sidebar .ui-tab-bar-item:nth-child(3)::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ.bd-settings-tab::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="pc-general-tab" i]::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="lightcord-tab" i]::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="core-tab" i]::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="Settings-tab" i]::before {
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/settings.svg) center/contain no-repeat;
}
@ -138,7 +140,8 @@
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="Logout-tab" i]::before {
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/logout.svg) center/contain no-repeat;
}
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="OVERVIEW-tab" i]::before {
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="OVERVIEW-tab" i]::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="accountinfo-tab" i]::before {
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/overview.svg) center/contain no-repeat;
}
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="ROLES-tab" i]::before,
@ -148,7 +151,8 @@
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="AUDIT_LOG-tab" i]::before {
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/audit.svg) center/contain no-repeat;
}
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="INTEGRATIONS-tab" i]::before {
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="INTEGRATIONS-tab" i]::before,
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="status-tab" i]::before {
-webkit-mask: url(https://mwittrien.github.io/BetterDiscordAddons/Themes/_res/svgs/settingsicons/integrations.svg) center/contain no-repeat;
}
.sidebar-CFHs9e .side-8zPYf6 .item-PXvHYJ[aria-controls="WIDGET-tab" i]::before {