stuff fixed

This commit is contained in:
Mirco Wittrien 2020-04-23 17:35:43 +02:00
parent 5fb3b8521a
commit 7ec2a3c59f
3 changed files with 61 additions and 54 deletions

View File

@ -8612,6 +8612,7 @@
} }
${BDFDB.dotCNS.popoutwrapper + BDFDB.dotCN.messagespopouttabbarheader} { ${BDFDB.dotCNS.popoutwrapper + BDFDB.dotCN.messagespopouttabbarheader} {
flex: 1 0 auto;
align-items: center; align-items: center;
height: unset; height: unset;
min-height: 56px; min-height: 56px;

File diff suppressed because one or more lines are too long

View File

@ -12,13 +12,13 @@ var PersonalPins = (_ => {
getDescription () {return "Similar to normal pins. Lets you save messages as notes for yourself.";} getDescription () {return "Similar to normal pins. Lets you save messages as notes for yourself.";}
getVersion () {return "1.9.0";} getVersion () {return "1.9.1";}
getAuthor () {return "DevilBro";} getAuthor () {return "DevilBro";}
constructor () { constructor () {
this.changelog = { this.changelog = {
"fixed":[["Crash","Fixed some weird rare crash occuring for some people"]] "fixed":[["Styling","Adjusted the styling to the new styling of the recent mentions popout"]]
}; };
this.patchedModules = { this.patchedModules = {
@ -256,60 +256,66 @@ var PersonalPins = (_ => {
let searchTimeout; let searchTimeout;
return [ return [
BDFDB.ReactUtils.createElement("div", { BDFDB.ReactUtils.createElement("div", {
className: BDFDB.disCN.messagespopoutheader, className: BDFDB.disCNS.messagespopouttabbarheader + BDFDB.disCN.messagespopoutheader,
style: { style: {
paddingBottom: 0 paddingBottom: 4
}, },
children: [ children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, {
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, { direction: BDFDB.LibraryComponents.Flex.Direction.VERTICAL,
children: [ children: [
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex.Child, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, {
className: BDFDB.disCN.messagespopouttitle, className: BDFDB.disCN.marginbottom4,
children: this.labels.popout_note_text align: BDFDB.LibraryComponents.Flex.Align.CENTER,
}), children: [
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SearchBar, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex.Child, {
query: buttonInstance.props.searchKey, className: BDFDB.disCN.messagespopouttitle,
onChange: value => { children: this.labels.popout_note_text
BDFDB.TimeUtils.clear(searchTimeout); }),
searchTimeout = BDFDB.TimeUtils.timeout(_ => { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SearchBar, {
buttonInstance.props.searchKey = value; query: buttonInstance.props.searchKey,
onChange: value => {
BDFDB.TimeUtils.clear(searchTimeout);
searchTimeout = BDFDB.TimeUtils.timeout(_ => {
buttonInstance.props.searchKey = value;
BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode);
}, 1000);
},
onClear: _ => {
buttonInstance.props.searchKey = "";
BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode); BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode);
}, 1000); }
}, })
onClear: _ => { ]
buttonInstance.props.searchKey = ""; }),
BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode); BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, {
} align: BDFDB.LibraryComponents.Flex.Align.CENTER,
}) children: [
] BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TabBar, {
}), className: BDFDB.disCN.messagespopouttabbar,
BDFDB.ReactUtils.createElement("div", { itemClassName: BDFDB.disCN.messagespopouttabbartab,
className: BDFDB.disCN.tabbarheadercontainer, itemSelectedClassName: BDFDB.disCN.messagespopouttabbartabactive,
children: [ type: BDFDB.LibraryComponents.TabBar.Types.TOP_PILL,
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TabBar, { selectedItem: buttonInstance.props.selectedFilter.value,
className: BDFDB.disCN.tabbarheader, items: tabKeys.map(key => this.getValue(key, "filter")),
itemClassName: BDFDB.disCN.tabbarheaderitem, onItemSelect: key => {
type: BDFDB.LibraryComponents.TabBar.Types.TOP, buttonInstance.props.selectedFilter = this.getValue(key, "filter");
selectedItem: buttonInstance.props.selectedFilter.value, BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode);
items: tabKeys.map(key => this.getValue(key, "filter")), }
onItemSelect: key => { }),
buttonInstance.props.selectedFilter = this.getValue(key, "filter"); BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.QuickSelect, {
BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode); spacing: -2,
} label: this.labels.popout_sort_text + ":",
}), value: buttonInstance.props.selectedSort,
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.QuickSelect, { options: sortKeys.map(key => this.getValue(key, "sort")),
spacing: -25, onChange: key => {
label: this.labels.popout_sort_text + ":", buttonInstance.props.selectedSort = this.getValue(key, "sort");
value: buttonInstance.props.selectedSort, BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode);
options: sortKeys.map(key => this.getValue(key, "sort")), }
onChange: key => { })
buttonInstance.props.selectedSort = this.getValue(key, "sort"); ]
BDFDB.ReactUtils.forceUpdate(buttonInstance.popout._owner.stateNode); })
} ]
}) })
]
})
]
}), }),
BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.ScrollerVertical, { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.ScrollerVertical, {
className: BDFDB.disCN.messagespopout, className: BDFDB.disCN.messagespopout,