stuff
This commit is contained in:
parent
c7b67478d1
commit
bf93853045
|
@ -2,7 +2,7 @@
|
||||||
* @name DisplayServersAsChannels
|
* @name DisplayServersAsChannels
|
||||||
* @author DevilBro
|
* @author DevilBro
|
||||||
* @authorId 278543574059057154
|
* @authorId 278543574059057154
|
||||||
* @version 1.6.2
|
* @version 1.6.4
|
||||||
* @description Displays Servers in a similar way as Channels
|
* @description Displays Servers in a similar way as Channels
|
||||||
* @invite Jx3TjNS
|
* @invite Jx3TjNS
|
||||||
* @donate https://www.paypal.me/MircoWittrien
|
* @donate https://www.paypal.me/MircoWittrien
|
||||||
|
@ -72,6 +72,9 @@ module.exports = (_ => {
|
||||||
this.patchPriority = 9;
|
this.patchPriority = 9;
|
||||||
|
|
||||||
this.modulePatches = {
|
this.modulePatches = {
|
||||||
|
before: [
|
||||||
|
"TooltipContainer"
|
||||||
|
],
|
||||||
after: [
|
after: [
|
||||||
"CircleIconButton",
|
"CircleIconButton",
|
||||||
"DirectMessage",
|
"DirectMessage",
|
||||||
|
@ -86,6 +89,9 @@ module.exports = (_ => {
|
||||||
};
|
};
|
||||||
|
|
||||||
this.css = `
|
this.css = `
|
||||||
|
${BDFDB.dotCN.guildlistitemtooltip} {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
${BDFDB.dotCN.forumpagelist} {
|
${BDFDB.dotCN.forumpagelist} {
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
}
|
}
|
||||||
|
@ -282,8 +288,13 @@ module.exports = (_ => {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
processTooltipContainer (e) {
|
||||||
|
if (!e.instance.props.tooltipClassName || e.instance.props.tooltipClassName.indexOf(BDFDB.disCN.guildlistitemtooltip) == -1) return;
|
||||||
|
e.instance.props.shouldShow = false;
|
||||||
|
}
|
||||||
|
|
||||||
removeTooltip (parent, guild) {
|
removeTooltip (parent, guild) {
|
||||||
let [children, index] = BDFDB.ReactUtils.findParent(parent, {name: ["Tooltip", "ListItemTooltip", "GuildTooltip", "BDFDB_TooltipContainer"]});
|
let [children, index] = BDFDB.ReactUtils.findParent(parent, {name: ["ListItemTooltip", "GuildTooltip", "BDFDB_TooltipContainer"]});
|
||||||
if (index == -1) return;
|
if (index == -1) return;
|
||||||
if (!guild) children[index] = children[index].props.children;
|
if (!guild) children[index] = children[index].props.children;
|
||||||
else children[index] = BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
|
else children[index] = BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
|
||||||
|
@ -427,9 +438,6 @@ module.exports = (_ => {
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
padding-top: 1px;
|
padding-top: 1px;
|
||||||
}
|
}
|
||||||
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCN.guildinboxtooltip} {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCNS.guildiconchildwrapper + BDFDB.dotCN._displayserversaschannelsname} {
|
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCNS.guildiconchildwrapper + BDFDB.dotCN._displayserversaschannelsname} {
|
||||||
flex: 1 1 auto;
|
flex: 1 1 auto;
|
||||||
font-size: ${this.settings.amounts.serverElementHeight / 2}px;
|
font-size: ${this.settings.amounts.serverElementHeight / 2}px;
|
||||||
|
@ -502,7 +510,7 @@ module.exports = (_ => {
|
||||||
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCN.guildfolderwrapper} [role="group"] {
|
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCN.guildfolderwrapper} [role="group"] {
|
||||||
height: auto !important;
|
height: auto !important;
|
||||||
}
|
}
|
||||||
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCN.guildfolderwrapper} [role="group"] ${BDFDB.dotCN.guildouter}:last-child {
|
${BDFDB.dotCNS._displayserversaschannelsstyled + BDFDB.dotCNS.guildswrapper + BDFDB.dotCN.guildfolderwrapper} [role="group"] > ${BDFDB.dotCN.guildouter}:last-child {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -813,6 +813,7 @@ module.exports = (_ => {
|
||||||
e.instance.props.children = BDFDB.TimeUtils.suppress((...args) => BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
|
e.instance.props.children = BDFDB.TimeUtils.suppress((...args) => BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, {
|
||||||
text: child.props.children.props.folderNode.name || e.instance.props.text,
|
text: child.props.children.props.folderNode.name || e.instance.props.text,
|
||||||
tooltipConfig: {
|
tooltipConfig: {
|
||||||
|
className: BDFDB.disCN.guildlistitemtooltip,
|
||||||
type: "right",
|
type: "right",
|
||||||
list: true,
|
list: true,
|
||||||
offset: 12,
|
offset: 12,
|
||||||
|
|
Loading…
Reference in New Issue