good night
This commit is contained in:
parent
8c5bbb9116
commit
c39107bc81
|
@ -5389,6 +5389,7 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
NativeSubComponents.FavButton = BDFDB.ModuleUtils.findByName("GIFFavButton");
|
NativeSubComponents.FavButton = BDFDB.ModuleUtils.findByName("GIFFavButton");
|
||||||
NativeSubComponents.PopoutContainer = BDFDB.ModuleUtils.findByName("Popout");
|
NativeSubComponents.PopoutContainer = BDFDB.ModuleUtils.findByName("Popout");
|
||||||
NativeSubComponents.Select = BDFDB.ModuleUtils.findByName("SelectTempWrapper");
|
NativeSubComponents.Select = BDFDB.ModuleUtils.findByName("SelectTempWrapper");
|
||||||
|
NativeSubComponents.Switch = BDFDB.ModuleUtils.findByName("Switch");
|
||||||
NativeSubComponents.TabBar = BDFDB.ModuleUtils.findByName("TabBar");
|
NativeSubComponents.TabBar = BDFDB.ModuleUtils.findByName("TabBar");
|
||||||
NativeSubComponents.TextInput = BDFDB.ModuleUtils.findByName("TextInput");
|
NativeSubComponents.TextInput = BDFDB.ModuleUtils.findByName("TextInput");
|
||||||
|
|
||||||
|
@ -5560,7 +5561,7 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
} : undefined;
|
} : undefined;
|
||||||
LibraryComponents.FavButton = reactInitialized ? class BDFDB_FavButton extends LibraryModules.React.Component {
|
LibraryComponents.FavButton = reactInitialized ? class BDFDB_FavButton extends LibraryModules.React.Component {
|
||||||
handleClick() {
|
handleClick() {
|
||||||
if (typeof this.props.onClick == "function") this.props.onClick(!isFavorite, this);
|
if (typeof this.props.onClick == "function") this.props.onClick(!this.props.isFavorite, this);
|
||||||
this.props.isFavorite = !this.props.isFavorite;
|
this.props.isFavorite = !this.props.isFavorite;
|
||||||
BDFDB.ReactUtils.forceUpdate(this);
|
BDFDB.ReactUtils.forceUpdate(this);
|
||||||
}
|
}
|
||||||
|
@ -5636,9 +5637,17 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
}
|
}
|
||||||
return BDFDB.ReactUtils.createElement("div", {
|
return BDFDB.ReactUtils.createElement("div", {
|
||||||
className: BDFDB.disCN.popoutcontainer,
|
className: BDFDB.disCN.popoutcontainer,
|
||||||
|
onContextMenu: e => {
|
||||||
|
let basePopoutIns = BDFDB.ReactUtils.findOwner(e._targetInst, {name:"BasePopout", up:true});
|
||||||
|
if (basePopoutIns && (!basePopoutIns.domElementRef.current || basePopoutIns.domElementRef.current.contains(e.target))) {
|
||||||
|
if (typeof this.props.onContextMenu == "function") this.props.onContextMenu(e, this);
|
||||||
|
if (basePopoutIns.domElementRef.current) basePopoutIns.close();
|
||||||
|
}
|
||||||
|
},
|
||||||
onClick: e => {
|
onClick: e => {
|
||||||
let basePopoutIns = BDFDB.ReactUtils.findOwner(e._targetInst, {name:"BasePopout", up:true});
|
let basePopoutIns = BDFDB.ReactUtils.findOwner(e._targetInst, {name:"BasePopout", up:true});
|
||||||
if (basePopoutIns && (!basePopoutIns.domElementRef.current || basePopoutIns.domElementRef.current.contains(e.target))) {
|
if (basePopoutIns && (!basePopoutIns.domElementRef.current || basePopoutIns.domElementRef.current.contains(e.target))) {
|
||||||
|
if (typeof this.props.onClick == "function") this.props.onClick(e, this);
|
||||||
basePopoutIns.handleClick();
|
basePopoutIns.handleClick();
|
||||||
if (!basePopoutIns.nativeClose) {
|
if (!basePopoutIns.nativeClose) {
|
||||||
basePopoutIns.nativeClose = basePopoutIns.close;
|
basePopoutIns.nativeClose = basePopoutIns.close;
|
||||||
|
@ -5710,12 +5719,8 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
}
|
}
|
||||||
}: undefined;
|
}: undefined;
|
||||||
LibraryComponents.SettingsItem = reactInitialized ? class BDFDB_SettingsItem extends LibraryModules.React.Component {
|
LibraryComponents.SettingsItem = reactInitialized ? class BDFDB_SettingsItem extends LibraryModules.React.Component {
|
||||||
handleChange(e) {
|
handleChange(value) {
|
||||||
if (typeof this.props.onChange == "function") this.props.onChange(!this.props.value, this);
|
if (typeof this.props.onChange == "function") this.props.onChange(value, this);
|
||||||
if (this.props.type == "Switch") {
|
|
||||||
this.props.value = !this.props.value;
|
|
||||||
BDFDB.ReactUtils.forceUpdate(this);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
render() {
|
render() {
|
||||||
if (typeof this.props.type != "string" || !["BUTTON", "SWITCH", "TEXTINPUT"].includes(this.props.type.toUpperCase())) return null;
|
if (typeof this.props.type != "string" || !["BUTTON", "SWITCH", "TEXTINPUT"].includes(this.props.type.toUpperCase())) return null;
|
||||||
|
@ -5799,7 +5804,16 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
}
|
}
|
||||||
} : undefined;
|
} : undefined;
|
||||||
LibraryComponents.SvgIcon = BDFDB.ModuleUtils.findByProperties("Gradients", "Names");
|
LibraryComponents.SvgIcon = BDFDB.ModuleUtils.findByProperties("Gradients", "Names");
|
||||||
LibraryComponents.Switch = BDFDB.ModuleUtils.findByName("Switch");
|
LibraryComponents.Switch = reactInitialized ? class BDFDB_Switch extends LibraryModules.React.Component {
|
||||||
|
handleChange() {
|
||||||
|
if (typeof this.props.onChange == "function") this.props.onChange(!this.props.value, this);
|
||||||
|
this.props.value = !this.props.value;
|
||||||
|
BDFDB.ReactUtils.forceUpdate(this);
|
||||||
|
}
|
||||||
|
render() {
|
||||||
|
return BDFDB.ReactUtils.createElement(NativeSubComponents.Switch, Object.assign({}, this.props, {onChange: this.handleChange.bind(this)}));
|
||||||
|
}
|
||||||
|
} : undefined;
|
||||||
LibraryComponents.TabBar = reactInitialized ? class BDFDB_TabBar extends LibraryModules.React.Component {
|
LibraryComponents.TabBar = reactInitialized ? class BDFDB_TabBar extends LibraryModules.React.Component {
|
||||||
handleItemSelect(item) {
|
handleItemSelect(item) {
|
||||||
if (typeof this.props.onItemSelect == "function") this.props.onItemSelect(item, this);
|
if (typeof this.props.onItemSelect == "function") this.props.onItemSelect(item, this);
|
||||||
|
@ -5810,7 +5824,7 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins || {}, cleanUps: BDFDB && BDFDB
|
||||||
} : undefined;
|
} : undefined;
|
||||||
LibraryComponents.TextElement = BDFDB.ModuleUtils.findByName("Text");
|
LibraryComponents.TextElement = BDFDB.ModuleUtils.findByName("Text");
|
||||||
LibraryComponents.TextInput = reactInitialized ? class BDFDB_TextInput extends LibraryModules.React.Component {
|
LibraryComponents.TextInput = reactInitialized ? class BDFDB_TextInput extends LibraryModules.React.Component {
|
||||||
handleChange(e) {
|
handleChange(value) {
|
||||||
if (typeof this.props.onChange == "function") this.props.onChange(value, this);
|
if (typeof this.props.onChange == "function") this.props.onChange(value, this);
|
||||||
this.props.value = value;
|
this.props.value = value;
|
||||||
BDFDB.ReactUtils.forceUpdate(this);
|
BDFDB.ReactUtils.forceUpdate(this);
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -375,7 +375,7 @@ class PinDMs {
|
||||||
|
|
||||||
processLazyScroller (instance, wrapper, returnvalue) {
|
processLazyScroller (instance, wrapper, returnvalue) {
|
||||||
let privateChannelIds = BDFDB.ReactUtils.getValue(instance, "_reactInternalFiber.return.memoizedProps.privateChannelIds");
|
let privateChannelIds = BDFDB.ReactUtils.getValue(instance, "_reactInternalFiber.return.memoizedProps.privateChannelIds");
|
||||||
if (privateChannelIds) {
|
if (privateChannelIds && instance.updater.isMounted(instance)) {
|
||||||
if (this.forceAdding || !instance.props.PinDMsPatched) {
|
if (this.forceAdding || !instance.props.PinDMsPatched) {
|
||||||
instance.props.PinDMsPatched = true;
|
instance.props.PinDMsPatched = true;
|
||||||
let dms = instance.props.children;
|
let dms = instance.props.children;
|
||||||
|
|
Loading…
Reference in New Issue