mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-09-04 12:20:56 +00:00
4.20.54
* Added: New UI for clearing FrankerFaceZ settings (Data Management > Storage). * Fixed: Do not display duplicate bot badges in tool-tips when a bot has both a global bot badge and a channel-specific bot badge. * Fixed: Do not add click URLs for FFZ badges to add-on badges. * Fixed: Remove `debugger;` from automatic error reporting method. * Fixed: IndexedDBProvider not synchronizing settings correctly. * Fixed: Change a CSS class name used when changing emote visibility to avoid bad UX due to misbehaving third-party extensions. * Fixed: Color calculations for chat messages, including highlight colors. (Closes #947) * Changed: Use rounded images from the CDN for FFZ badges in tool-tips. * Changed: Use Twitch IDs rather than usernames for assigning channel-specific badges to users. * API Added: `settings.addClearable(key, definition)` for adding new UI to `Data Management > Storage >> Clear`.
This commit is contained in:
parent
7adee6556c
commit
ef4ff0c13a
15 changed files with 394 additions and 27 deletions
68
src/settings/clearables.js
Normal file
68
src/settings/clearables.js
Normal file
|
@ -0,0 +1,68 @@
|
|||
'use strict';
|
||||
|
||||
// ============================================================================
|
||||
// Clearable Settings
|
||||
// ============================================================================
|
||||
|
||||
export const Experiments = {
|
||||
label: 'Experiment Overrides',
|
||||
keys: [
|
||||
'exp-lock',
|
||||
'experiment-overrides'
|
||||
]
|
||||
};
|
||||
|
||||
export const HiddenEmotes = {
|
||||
label: 'Hidden Emotes',
|
||||
keys(provider) {
|
||||
const keys = ['emote-menu.hidden-sets'];
|
||||
for(const key of provider.keys())
|
||||
if ( key.startsWith('hidden-emotes.') )
|
||||
keys.push(key);
|
||||
|
||||
return keys;
|
||||
}
|
||||
};
|
||||
|
||||
export const FavoriteEmotes = {
|
||||
label: 'Favorited Emotes',
|
||||
keys(provider) {
|
||||
const keys = [];
|
||||
for(const key of provider.keys())
|
||||
if ( key.startsWith('favorite-emotes.') )
|
||||
keys.push(key);
|
||||
|
||||
return keys;
|
||||
}
|
||||
};
|
||||
|
||||
export const Overrides = {
|
||||
label: 'Name and Color Overrides',
|
||||
keys: [
|
||||
'overrides.colors',
|
||||
'overrides.names'
|
||||
]
|
||||
};
|
||||
|
||||
export const Profiles = {
|
||||
label: 'Profiles',
|
||||
clear(provider, settings) {
|
||||
const keys = ['profiles'];
|
||||
for(const key of provider.keys())
|
||||
if ( /^p:\d+:/.test(key) )
|
||||
keys.push(key);
|
||||
|
||||
for(const key of keys)
|
||||
provider.delete(key);
|
||||
|
||||
settings.loadProfiles();
|
||||
}
|
||||
};
|
||||
|
||||
export const Everything = {
|
||||
label: 'Absolutely Everything',
|
||||
clear(provider, settings) {
|
||||
provider.clear();
|
||||
settings.loadProfiles();
|
||||
}
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue