Implementing a way to fix the view on the current Meeting account to:
* Avoid auto-updates on timeline * Control the timeline index, so when the account is discarded in any way, we don't show it anymore
This commit is contained in:
parent
e28cfabbcc
commit
9094e0b844
|
@ -556,10 +556,19 @@ div.main-content.meet {
|
||||||
background: transparent !important;
|
background: transparent !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.virtual-list-item.meetshown {
|
||||||
|
z-index: 20 !important;
|
||||||
|
width: 100% !important;
|
||||||
|
}
|
||||||
|
|
||||||
div.virtual-list-item {
|
div.virtual-list-item {
|
||||||
|
position: fixed;
|
||||||
|
top: 0 !important;
|
||||||
|
width: 0;
|
||||||
max-width: 100em;
|
max-width: 100em;
|
||||||
margin: auto;
|
margin: auto;
|
||||||
opacity: 1 !important;
|
opacity: 1 !important;
|
||||||
|
z-index: 0;
|
||||||
|
|
||||||
article.status-article {
|
article.status-article {
|
||||||
background-repeat: no-repeat !important;
|
background-repeat: no-repeat !important;
|
||||||
|
|
|
@ -280,7 +280,8 @@ var fediloveData = {
|
||||||
meetAccountImageLocked: false,
|
meetAccountImageLocked: false,
|
||||||
myAccountId: undefined,
|
myAccountId: undefined,
|
||||||
currentAccount: null,
|
currentAccount: null,
|
||||||
currentAccountIsEmpty: false,
|
currentAccouontIsEmpty: false,
|
||||||
|
currentIDMeetTimeline: null,
|
||||||
gotEmojifyTextFunction: false,
|
gotEmojifyTextFunction: false,
|
||||||
composeTxtKeypressEvent: false
|
composeTxtKeypressEvent: false
|
||||||
};
|
};
|
||||||
|
@ -597,6 +598,31 @@ function fedilove_customization() {
|
||||||
fediloveUI.registerSwipeOnElement('#meet-navigation #anim-swipe', function(swiperightBol) {
|
fediloveUI.registerSwipeOnElement('#meet-navigation #anim-swipe', function(swiperightBol) {
|
||||||
fediloveUI.meetPageGoToCurrentAccount(swiperightBol)
|
fediloveUI.meetPageGoToCurrentAccount(swiperightBol)
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// make sure only the wanted items in timeline are shown
|
||||||
|
const _this = setInterval(function()
|
||||||
|
{
|
||||||
|
if (window.location.pathname !== '/federated')
|
||||||
|
return clearInterval(_this);
|
||||||
|
|
||||||
|
const items = $('div.virtual-list > div.virtual-list-item');
|
||||||
|
if (items.length > 0) {
|
||||||
|
if (window.fediloveData.currentIDMeetTimeline === null ||
|
||||||
|
document.getElementById(window.fediloveData.currentIDMeetTimeline) === null) {
|
||||||
|
const itemToId = items.first().find('article:first');
|
||||||
|
if (itemToId[0] !== undefined) {
|
||||||
|
window.fediloveData.currentIDMeetTimeline = itemToId[0].id;
|
||||||
|
itemToId.parent().addClass('meetshown');
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
items.removeClass('meetshown');
|
||||||
|
const itemToId = $(document.getElementById(window.fediloveData.currentIDMeetTimeline));
|
||||||
|
if (itemToId.length > 0)
|
||||||
|
itemToId.parent().addClass('meetshown');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}, 200);
|
||||||
}
|
}
|
||||||
else if (window.location.pathname.startsWith('/notifications/mentions')) {
|
else if (window.location.pathname.startsWith('/notifications/mentions')) {
|
||||||
$('nav.notification-filters li > a.focus-fix').attr('onclick', 'return false;');
|
$('nav.notification-filters li > a.focus-fix').attr('onclick', 'return false;');
|
||||||
|
|
Loading…
Reference in New Issue