mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-07-24 19:48:30 +00:00
4.20.1
* Added: Option to hide Twitch's native stream uptime. Enabled by default when using FFZ's own stream uptime. * Fixed: Implement stream metadata for the new Twitch layout. * Fixed: Display the subscription tier in badge tool-tips for Tier 2 and Tier 3 subscriber badges. This release involves significant changes under the hood. Due to Twitch's heavy use of functional React components and effects in recent updates to their site, we need to start listening for DOM nodes rather than components in many cases. To that end, I've implemented the Elemental module to grab elements using MutationObservers. I didn't want to, but this is where we're at. In a future release I'll be using Elemental to add support back to the directory for certain features.
This commit is contained in:
parent
8c9a3aa8a4
commit
ed0577f09e
16 changed files with 719 additions and 824 deletions
|
@ -59,6 +59,21 @@ export default class CSSTweaks extends Module {
|
|||
|
||||
// Layout
|
||||
|
||||
this.settings.add('metadata.uptime.no-native', {
|
||||
requires: ['metadata.uptime'],
|
||||
default: null,
|
||||
process(ctx, val) {
|
||||
return val == null ? ctx.get('metadata.uptime') !== 0 : val
|
||||
},
|
||||
changed: val => this.toggle('hide-native-uptime', val),
|
||||
ui: {
|
||||
path: 'Channel > Metadata >> Player',
|
||||
title: "Hide Twitch's native Stream Uptime.",
|
||||
description: "By default, this is enabled whenever FFZ's own Stream Uptime display is enabled to avoid redundant information.",
|
||||
component: 'setting-check-box'
|
||||
}
|
||||
});
|
||||
|
||||
this.settings.add('layout.use-chat-fix', {
|
||||
requires: ['layout.swap-sidebars', 'layout.use-portrait', 'chat.use-width'],
|
||||
process(ctx) {
|
||||
|
@ -318,6 +333,7 @@ export default class CSSTweaks extends Module {
|
|||
}
|
||||
|
||||
onEnable() {
|
||||
this.toggle('hide-native-uptime', this.settings.get('metadata.uptime.no-native'));
|
||||
this.toggle('chat-fix', this.settings.get('layout.use-chat-fix'));
|
||||
this.toggle('swap-sidebars', this.settings.get('layout.swap-sidebars'));
|
||||
this.toggle('minimal-navigation', this.settings.get('layout.minimal-navigation'));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue