1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-09-16 18:06:55 +00:00
* Fixed: Bug with the Following directory throwing errors about updating up-time.
* API Added: Added several icons for the new FS Chat add-on to use.
This commit is contained in:
SirStendec 2020-07-17 18:42:55 -04:00
parent 2bb87db83c
commit ced61d2bfc
15 changed files with 73 additions and 17 deletions

View file

@ -43,7 +43,7 @@ export default class Directory extends SiteModule {
this.inject(Game);
this.DirectoryCard = this.elemental.define(
'directory-card', '.live-channel-card,article[data-a-target^="followed-vod-"],article[data-a-target^="card-"],div[data-a-target^="video-tower-card-"] article,div[data-a-target^="clips-card-"] article,.shelf-card__impression-wrapper article,.tw-tower div article',
'directory-card', 'article[data-a-target^="followed-vod-"],article[data-a-target^="card-"],div[data-a-target^="video-tower-card-"] article,div[data-a-target^="clips-card-"] article,.shelf-card__impression-wrapper article,.tw-tower div article',
DIR_ROUTES, null, 0, 0
);
@ -399,6 +399,16 @@ export default class Directory extends SiteModule {
</div>));
}
if ( ! el.ffz_uptime_span )
el.ffz_uptime_span = el.ffz_uptime_el.querySelector('p');
if ( ! el.ffz_uptime_span )
return this.clearUptime(el);
if ( ! el.ffz_uptime_tt )
el.ffz_uptime_tt = el.ffz_uptime_el.querySelector('.tw-tooltip > div');
if ( ! el.ffz_uptime_tt )
return this.clearUptime(el);
if ( ! el.ffz_update_timer )
el.ffz_update_timer = setInterval(this.updateUptime.bind(this, el, props), 1000);

View file

@ -81,8 +81,12 @@ The CSS loaded by this setting is far too heavy and can cause performance issues
});
this.settings.add('theme.is-dark', {
requires: ['theme.can-dark', 'context.ui.theme', 'context.ui.theatreModeEnabled', 'context.route.name', 'context.location.search'],
requires: ['context.force-dark', 'theme.can-dark', 'context.ui.theme', 'context.ui.theatreModeEnabled', 'context.route.name', 'context.location.search'],
process(ctx) {
const force = ctx.get('context.force-theme');
if ( force != null )
return force;
if ( ctx.get('context.route.name') === 'embed-chat' )
return (ctx.get('context.location.search')||'').includes('dark');

View file

@ -94,5 +94,8 @@ export default [
"fast-fw",
"comp-on",
"comp-off",
"viewers"
"viewers",
"move",
"chat-empty",
"chat"
];