mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-07-31 06:58:30 +00:00
4.20.44
* Fixed: Switchboard being unable to force a chunk to load after Twitch made changes to their async component loader. * Changed: Grab the latest chat types array from Twitch. * Changed: Delay forcing a layout update when loading our CSS to ensure it has more of a chance to load and affect the page.
This commit is contained in:
parent
8ea12ab73c
commit
46dd59ef8d
7 changed files with 24 additions and 10 deletions
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "frankerfacez",
|
||||
"author": "Dan Salvato LLC",
|
||||
"version": "4.20.43",
|
||||
"version": "4.20.44",
|
||||
"description": "FrankerFaceZ is a Twitch enhancement suite.",
|
||||
"license": "Apache-2.0",
|
||||
"scripts": {
|
||||
|
|
|
@ -146,10 +146,6 @@ export default {
|
|||
return [];
|
||||
|
||||
return deep_copy(data.items);
|
||||
},
|
||||
|
||||
onSelected(...args) {
|
||||
console.log('selected', args);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -136,7 +136,8 @@ const CHAT_TYPES = make_enum(
|
|||
'BitsBadgeTierMessage',
|
||||
'InlinePrivateCallout',
|
||||
'ChannelPointsReward',
|
||||
'CommunityChallengeContribution'
|
||||
'CommunityChallengeContribution',
|
||||
'CelebrationPurchase'
|
||||
);
|
||||
|
||||
|
||||
|
|
|
@ -522,6 +522,8 @@ export default class CSSTweaks extends Module {
|
|||
this.chunks[k] = raw(key).default;
|
||||
}
|
||||
|
||||
this.emit('site.layout:resize');
|
||||
|
||||
this.chunks_loaded = true;
|
||||
r();
|
||||
})
|
||||
|
|
|
@ -331,12 +331,27 @@ export default class Directory extends SiteModule {
|
|||
if ( ! props?.channelLogin )
|
||||
return;
|
||||
|
||||
const game = props.gameTitle || props.trackingProps?.categoryName || props.trackingProps?.category;
|
||||
const game = props.gameTitle || props.trackingProps?.categoryName || props.trackingProps?.category,
|
||||
tags = props.tagListProps?.tags;
|
||||
|
||||
let bad_tag = false;
|
||||
|
||||
el.classList.toggle('ffz-hide-thumbnail', this.settings.provider.get('directory.game.hidden-thumbnails', []).includes(game));
|
||||
el.dataset.ffzType = props.streamType;
|
||||
|
||||
const should_hide = (props.streamType === 'rerun' && this.settings.get('directory.hide-vodcasts')) ||
|
||||
if ( Array.isArray(tags) ) {
|
||||
const bad_tags = this.settings.provider.get('directory.game.hidden-tags', []);
|
||||
if ( bad_tags.length ) {
|
||||
for(const tag of tags) {
|
||||
if ( tag?.id && bad_tags.includes(tag.id) ) {
|
||||
bad_tag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const should_hide = bad_tag || (props.streamType === 'rerun' && this.settings.get('directory.hide-vodcasts')) ||
|
||||
(props.context != null && props.context !== CARD_CONTEXTS.SingleGameList && this.settings.provider.get('directory.game.blocked-games', []).includes(game)) ||
|
||||
((props.sourceType === 'PROMOTION' || props.sourceType === 'SPONSORED') && this.settings.get('directory.hide-promoted'));
|
||||
|
||||
|
|
|
@ -261,7 +261,7 @@ export default class Layout extends Module {
|
|||
if ( this._resize_timer )
|
||||
return;
|
||||
|
||||
this._resize_timer = requestAnimationFrame(() => this._handleResize());
|
||||
this._resize_timer = setTimeout(() => this._handleResize(), 50);
|
||||
}
|
||||
|
||||
_handleResize() {
|
||||
|
|
|
@ -87,7 +87,7 @@ export default class Switchboard extends Module {
|
|||
|
||||
if ( component_class.Preload ) {
|
||||
try {
|
||||
component = component_class.Preload();
|
||||
component = component_class.Preload({priority: 1});
|
||||
} catch(err) {
|
||||
this.log.warn('Error instantiating preloader for forced chunk loading.', err);
|
||||
component = null;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue