This commit is contained in:
Mirco Wittrien 2020-03-29 22:40:13 +02:00
parent 3ef5d7ce29
commit cf2230243f
4 changed files with 69 additions and 73 deletions

View File

@ -3993,7 +3993,6 @@
BDFDBundefined: "BDFDB_undefined", BDFDBundefined: "BDFDB_undefined",
avatarStatusHovered: "statusHovered-gF2976", avatarStatusHovered: "statusHovered-gF2976",
bdaRepoEntry: "entry-9JnAPs", bdaRepoEntry: "entry-9JnAPs",
bdaRepoEntryIconWrapper: "iconWrapper-kuCycr",
cardInner: "inner-OP_8zd", cardInner: "inner-OP_8zd",
cardWrapper: "card-rT4Wbb", cardWrapper: "card-rT4Wbb",
charCounter: "counter-uAzbKp", charCounter: "counter-uAzbKp",
@ -4534,7 +4533,6 @@
_repodescription: ["BDrepo", "bdaDescription"], _repodescription: ["BDrepo", "bdaDescription"],
_repodescriptionwrap: ["BDrepo", "bdaDescriptionWrap"], _repodescriptionwrap: ["BDrepo", "bdaDescriptionWrap"],
_repoentry: ["BDFDB", "bdaRepoEntry"], _repoentry: ["BDFDB", "bdaRepoEntry"],
_repoentryiconwrapper: ["BDFDB", "bdaRepoEntryIconWrapper"],
_repofolderbutton: ["BDrepo", "bdPfbtn"], _repofolderbutton: ["BDrepo", "bdPfbtn"],
_repofooter: ["BDrepo", "bdaFooter"], _repofooter: ["BDrepo", "bdaFooter"],
_repoheader: ["BDrepo", "bdaHeader"], _repoheader: ["BDrepo", "bdaHeader"],
@ -8747,10 +8745,8 @@
${BDFDB.dotCNS._repolist + BDFDB.dotCNS._repofooter + BDFDB.dotCN._repolinks} + * ~ * { ${BDFDB.dotCNS._repolist + BDFDB.dotCNS._repofooter + BDFDB.dotCN._repolinks} + * ~ * {
margin-left: 8px; margin-left: 8px;
} }
${BDFDB.dotCN._repoentryiconwrapper} { ${BDFDB.dotCN._repoicon} {
display: flex; color: var(--interactive-active);
justify-content: center;
align-items: center;
} }
${BDFDB.dotCN.noticewrapper} { ${BDFDB.dotCN.noticewrapper} {
@ -9119,7 +9115,6 @@
text: BDFDB.LanguageUtils.LanguageStrings.CHANGE_LOG, text: BDFDB.LanguageUtils.LanguageStrings.CHANGE_LOG,
children: BDFDB.ReactUtils.createElement(InternalComponents.LibraryComponents.SvgIcon, { children: BDFDB.ReactUtils.createElement(InternalComponents.LibraryComponents.SvgIcon, {
name: InternalComponents.LibraryComponents.SvgIcon.Names.CHANGELOG, name: InternalComponents.LibraryComponents.SvgIcon.Names.CHANGELOG,
color: "#FFFFFF",
className: BDFDB.disCN._repoicon, className: BDFDB.disCN._repoicon,
onClick: _ => {BDFDB.PluginUtils.openChangeLog(data);} onClick: _ => {BDFDB.PluginUtils.openChangeLog(data);}
}) })

File diff suppressed because one or more lines are too long

View File

@ -69,7 +69,7 @@ var PluginRepo = (_ => {
return class PluginRepo { return class PluginRepo {
getName () {return "PluginRepo";} getName () {return "PluginRepo";}
getVersion () {return "1.9.4";} getVersion () {return "1.9.5";}
getAuthor () {return "DevilBro";} getAuthor () {return "DevilBro";}
@ -493,44 +493,45 @@ var PluginRepo = (_ => {
else BDFDB.DataUtils.remove(this, "favorites", plugin.url); else BDFDB.DataUtils.remove(this, "favorites", plugin.url);
} }
}), }),
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { BDFDB.ReactUtils.createElement("div", {
text: "Go to Source", className: BDFDB.disCN._repocontrolsbutton,
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
className: BDFDB.disCNS._repoentryiconwrapper, text: "Go to Source",
onClick: _ => {
let giturl = null;
if (plugin.url.indexOf("https://raw.githubusercontent.com") == 0) {
let temp = plugin.url.replace("//raw.githubusercontent", "//github").split("/");
temp.splice(5, 0, "blob");
giturl = temp.join("/");
}
else if (plugin.url.indexOf("https://gist.githubusercontent.com/") == 0) {
giturl = plugin.url.replace("//gist.githubusercontent", "//gist.github").split("/raw/")[0];
}
if (giturl) BDFDB.DiscordUtils.openLink(giturl, BDFDB.DataUtils.get(this, "settings", "useChromium"));
},
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, {
name: BDFDB.LibraryComponents.SvgIcon.Names.GITHUB name: BDFDB.LibraryComponents.SvgIcon.Names.GITHUB,
className: BDFDB.disCN._repoicon,
onClick: _ => {
let giturl = null;
if (plugin.url.indexOf("https://raw.githubusercontent.com") == 0) {
let temp = plugin.url.replace("//raw.githubusercontent", "//github").split("/");
temp.splice(5, 0, "blob");
giturl = temp.join("/");
}
else if (plugin.url.indexOf("https://gist.githubusercontent.com/") == 0) {
giturl = plugin.url.replace("//gist.githubusercontent", "//gist.github").split("/raw/")[0];
}
if (giturl) BDFDB.DiscordUtils.openLink(giturl, BDFDB.DataUtils.get(this, "settings", "useChromium"));
}
}) })
}) })
}) }),
], ],
buttons: [ buttons: [
plugin.state != pluginStates.DOWNLOADABLE && BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { plugin.state != pluginStates.DOWNLOADABLE && BDFDB.ReactUtils.createElement("div", {
text: "Delete Pluginfile", className: BDFDB.disCN._repocontrolsbutton,
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
className: BDFDB.disCN._repoentryiconwrapper, text: "Delete Pluginfile",
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, {
className: BDFDB.disCN.svgicon, name: BDFDB.LibraryComponents.SvgIcon.Names.NOVA_TRASH,
name: BDFDB.LibraryComponents.SvgIcon.Names.NOVA_TRASH className: BDFDB.disCN._repoicon,
}), onClick: (e, instance) => {
onClick: (e, instance) => { this.deletePluginFile(plugin);
this.deletePluginFile(plugin); BDFDB.TimeUtils.timeout(_ => {
BDFDB.TimeUtils.timeout(_ => { this.updateList(instance, options);
this.updateList(instance, options); if (!BDFDB.BDUtils.isAutoLoadEnabled()) this.stopPlugin(plugin);
if (!BDFDB.BDUtils.isAutoLoadEnabled()) this.stopPlugin(plugin); }, 3000);
}, 3000); }
} })
}) })
}), }),
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Button, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Button, {

View File

@ -218,7 +218,6 @@ var ThemeRepo = (_ => {
children: [ children: [
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex.Child, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex.Child, {
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TextInput, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TextInput, {
placeholder: customUrl,
placeholder: "Insert Raw Github Link of Theme (https://raw.githubusercontent.com/...)", placeholder: "Insert Raw Github Link of Theme (https://raw.githubusercontent.com/...)",
onChange: value => {customUrl = value.trim();} onChange: value => {customUrl = value.trim();}
}) })
@ -719,24 +718,25 @@ var ThemeRepo = (_ => {
else BDFDB.DataUtils.remove(this, "favorites", theme.url); else BDFDB.DataUtils.remove(this, "favorites", theme.url);
} }
}), }),
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { BDFDB.ReactUtils.createElement("div", {
text: "Go to Source", className: BDFDB.disCN._repocontrolsbutton,
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
className: BDFDB.disCNS._repoentryiconwrapper, text: "Go to Source",
onClick: _ => {
let giturl = null;
if (theme.requesturl.indexOf("https://raw.githubusercontent.com") == 0) {
let temp = theme.requesturl.replace("//raw.githubusercontent", "//github").split("/");
temp.splice(5, 0, "blob");
giturl = temp.join("/");
}
else if (theme.requesturl.indexOf("https://gist.githubusercontent.com/") == 0) {
giturl = theme.requesturl.replace("//gist.githubusercontent", "//gist.github").split("/raw/")[0];
}
if (giturl) BDFDB.DiscordUtils.openLink(giturl, BDFDB.DataUtils.get(this, "settings", "useChromium"));
},
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, {
name: BDFDB.LibraryComponents.SvgIcon.Names.GITHUB name: BDFDB.LibraryComponents.SvgIcon.Names.GITHUB,
className: BDFDB.disCN._repoicon,
onClick: _ => {
let giturl = null;
if (theme.requesturl.indexOf("https://raw.githubusercontent.com") == 0) {
let temp = theme.requesturl.replace("//raw.githubusercontent", "//github").split("/");
temp.splice(5, 0, "blob");
giturl = temp.join("/");
}
else if (theme.requesturl.indexOf("https://gist.githubusercontent.com/") == 0) {
giturl = theme.requesturl.replace("//gist.githubusercontent", "//gist.github").split("/raw/")[0];
}
if (giturl) BDFDB.DiscordUtils.openLink(giturl, BDFDB.DataUtils.get(this, "settings", "useChromium"));
}
}) })
}) })
}), }),
@ -758,21 +758,21 @@ var ThemeRepo = (_ => {
}) })
], ],
buttons: [ buttons: [
theme.state != themeStates.DOWNLOADABLE && BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { theme.state != themeStates.DOWNLOADABLE && BDFDB.ReactUtils.createElement("div", {
text: "Delete Themefile", className: BDFDB.disCN._repocontrolsbutton,
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
className: BDFDB.disCN._repoentryiconwrapper, text: "Delete Themefile",
children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, {
className: BDFDB.disCN.svgicon, name: BDFDB.LibraryComponents.SvgIcon.Names.NOVA_TRASH,
name: BDFDB.LibraryComponents.SvgIcon.Names.NOVA_TRASH className: BDFDB.disCN._repoicon,
}), onClick: (e, instance) => {
onClick: (e, instance) => { this.deleteThemeFile(theme);
this.deleteThemeFile(theme); BDFDB.TimeUtils.timeout(_ => {
BDFDB.TimeUtils.timeout(_ => { this.updateList(instance, options);
this.updateList(instance, options); if (!BDFDB.BDUtils.isAutoLoadEnabled()) this.removeTheme(theme);
if (!BDFDB.BDUtils.isAutoLoadEnabled()) this.removeTheme(theme); }, 3000);
}, 3000); }
} })
}) })
}), }),
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Button, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Button, {