From 731fa62f0dc69aa142ec2f426dc9ec23707f65a1 Mon Sep 17 00:00:00 2001 From: Mirco Wittrien Date: Mon, 5 Jul 2021 17:42:48 +0200 Subject: [PATCH] stuff --- Library/_res/BDFDB.data.json | 30 ++++---- Plugins/ThemeRepo/ThemeRepo.plugin.js | 1 + Plugins/_res/DiscordPreview.html | 101 ++++++++++++++++---------- Plugins/_res/DiscordPreview.js | 7 +- 4 files changed, 84 insertions(+), 55 deletions(-) diff --git a/Library/_res/BDFDB.data.json b/Library/_res/BDFDB.data.json index fac209b015..10c296af7e 100644 --- a/Library/_res/BDFDB.data.json +++ b/Library/_res/BDFDB.data.json @@ -1322,8 +1322,7 @@ "UserPopout": {"props": ["userPopout", "body"]}, "UserPopoutBody": {"props": ["rolesList", "note"]}, "UserPopoutFooter": {"props": ["wumpusTooltip", "footer"]}, - "UserPopoutHeader": {"props": ["aboutMeSection", "avatarPositionNormal"]}, - "UserPopoutInfo": {"props": ["headerTop", "profileBadges"]}, + "UserPopoutHeader": {"props": ["headerTop", "profileBadges"]}, "UserProfile": {"props": ["root", "tabBarContainer"]}, "UserProfileHeader": {"props": ["header", "additionalActionsIcon"]}, "UserProfileInfoSection": {"props": ["userInfoSection", "connectedAccounts"]}, @@ -3015,7 +3014,7 @@ "userbadge": ["UserBadges", "profileBadge"], "userbadgeouter": ["UserBadges", "clickable"], "userbadges": ["UserBadges", "container"], - "userbadgespopout": ["UserPopoutInfo", "profileBadges"], + "userbadgespopout": ["UserPopoutHeader", "profileBadges"], "userbadgesprofile": ["UserProfileHeader", "badgeList"], "userbanner": ["UserBanner", "banner"], "userbannerpopout": ["UserBanner", "popoutBanner"], @@ -3045,19 +3044,20 @@ "userpopoutcustomstatustext": ["UserPopoutHeader", "customStatusText"], "userpopoutdivider": ["UserPopout", "divider"], "userpopoutfooter": ["UserPopoutFooter", "footer"], - "userpopoutheaderbottag": ["UserPopoutInfo", "headerBotTag"], - "userpopoutheaderbottagwithnickname": ["UserPopoutInfo", "headerBotTagWithNickname"], - "userpopoutheaderdiscriminatorbase": ["UserPopoutInfo", "discrimBase"], - "userpopoutheaderdiscriminatornonickname": ["UserPopoutInfo", "headerTagDiscriminatorNoNickname"], - "userpopoutheadernickname": ["UserPopoutInfo", "nickname"], + "userpopoutheaderbottag": ["UserPopoutHeader", "headerBotTag"], + "userpopoutheaderbottagwithnickname": ["UserPopoutHeader", "headerBotTagWithNickname"], + "userpopoutheaderdiscriminatorbase": ["UserPopoutHeader", "discrimBase"], + "userpopoutheaderdiscriminatornonickname": ["UserPopoutHeader", "headerTagDiscriminatorNoNickname"], + "userpopoutheadernickname": ["UserPopoutHeader", "nickname"], "userpopoutheadernormal": ["UserPopout", "headerNormal"], - "userpopoutheadertag": ["UserPopoutInfo", "headerTag"], - "userpopoutheadertagnonickname": ["UserPopoutInfo", "headerTagNoNickname"], - "userpopoutheadertagusernamebase": ["UserPopoutInfo", "headerTagUsernameBase"], - "userpopoutheadertagusernamenonickname": ["UserPopoutInfo", "headerTagUsernameNoNickname"], - "userpopoutheadertagwithnickname": ["UserPopoutInfo", "headerTagWithNickname"], - "userpopoutheadertext": ["UserPopoutInfo", "headerText"], - "userpopoutheadertop": ["UserPopoutInfo", "headerTop"], + "userpopoutheadertag": ["UserPopoutHeader", "headerTag"], + "userpopoutheadertagnonickname": ["UserPopoutHeader", "headerTagNoNickname"], + "userpopoutheadertagusernamebase": ["UserPopoutHeader", "headerTagUsernameBase"], + "userpopoutheadertagusernamenonickname": ["UserPopoutHeader", "headerTagUsernameNoNickname"], + "userpopoutheadertagwithnickname": ["UserPopoutHeader", "headerTagWithNickname"], + "userpopoutheadertext": ["UserPopoutHeader", "headerText"], + "userpopoutheadertop": ["UserPopoutHeader", "headerTop"], + "userpopoutheadertopwithcustomstatus": ["UserPopoutHeader", "headerTopWithCustomStatus"], "userpopoutrole": ["Role", "role"], "userpopoutrolecircle": ["Role", "roleCircle"], "userpopoutrolelist": ["UserPopoutBody", "rolesList"], diff --git a/Plugins/ThemeRepo/ThemeRepo.plugin.js b/Plugins/ThemeRepo/ThemeRepo.plugin.js index 935404bdcc..481a76622d 100644 --- a/Plugins/ThemeRepo/ThemeRepo.plugin.js +++ b/Plugins/ThemeRepo/ThemeRepo.plugin.js @@ -258,6 +258,7 @@ module.exports = (_ => { classes: JSON.stringify(BDFDB.DiscordClasses), classModules: JSON.stringify(BDFDB.DiscordClassModules), nativeCSS: (nativeCSS || "").replace(/\/assets\//g, document.location.origin + "/assets/").replace(/[\t\r\n]/g, ""), + bdCSS: (document.querySelector("#bd-stylesheet") || {}).innerText || "", htmlClassName: document.documentElement.className, titleBar: titleBar && titleBar.outerHTML || "" }); diff --git a/Plugins/_res/DiscordPreview.html b/Plugins/_res/DiscordPreview.html index d6d1395b91..35968e3f23 100644 --- a/Plugins/_res/DiscordPreview.html +++ b/Plugins/_res/DiscordPreview.html @@ -108,7 +108,7 @@
-
public
+
public
@@ -380,7 +380,7 @@
-
+
@@ -407,7 +407,7 @@
-
+
@@ -1429,7 +1429,7 @@
-

Welcome in #selected text!

+

Welcome in #selected text!

This is the beginning of the channel #selected text.