1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-08-02 16:08:31 +00:00
* Fixed: Bug causing link previews to fail to load correctly.
This commit is contained in:
SirStendec 2023-10-12 14:06:40 -04:00
parent 5b65f6b735
commit 60e4edf7c2
4 changed files with 11 additions and 9 deletions

View file

@ -1,7 +1,7 @@
{ {
"name": "frankerfacez", "name": "frankerfacez",
"author": "Dan Salvato LLC", "author": "Dan Salvato LLC",
"version": "4.55.2", "version": "4.55.3",
"description": "FrankerFaceZ is a Twitch enhancement suite.", "description": "FrankerFaceZ is a Twitch enhancement suite.",
"private": true, "private": true,
"license": "Apache-2.0", "license": "Apache-2.0",

View file

@ -12,8 +12,8 @@
"description": "Use the new API to look up links instead of the socket cluster.", "description": "Use the new API to look up links instead of the socket cluster.",
"groups": [ "groups": [
{"value": true, "weight": 30}, {"value": true, "weight": 30},
{"value": "cf", "weight": 5}, {"value": "cf", "weight": 10},
{"value": false, "weight": 65} {"value": false, "weight": 60}
] ]
}, },
"pubsub": { "pubsub": {

View file

@ -132,7 +132,7 @@ export default class Chat extends Module {
});*/ });*/
this.settings.add('debug.link-resolver.source', { this.settings.add('debug.link-resolver.source', {
process(ctx, val) { process: (ctx, val) => {
if ( val == null ) { if ( val == null ) {
const exp = this.experiments.getAssignment('api_links'); const exp = this.experiments.getAssignment('api_links');
if ( exp === 'cf' ) if ( exp === 'cf' )

View file

@ -61,16 +61,16 @@ function applySpacing(term, token, classes, styles) {
const thing = term === 'pd' ? 'padding' : 'margin'; const thing = term === 'pd' ? 'padding' : 'margin';
if ( mode === '' ) if ( mode === '' )
styles[thing] = value; styles[thing] = value;
if ( mode === 'x' || mode === 'l' ) if ( mode === '-x' || mode === '-l' )
styles[`${thing}-left`] = value; styles[`${thing}-left`] = value;
if ( mode === 'x' || mode === 'r' ) if ( mode === '-x' || mode === '-r' )
styles[`${thing}-right`] = value; styles[`${thing}-right`] = value;
if ( mode === 'y' || mode === 't' ) if ( mode === '-y' || mode === '-t' )
styles[`${thing}-top`] = value; styles[`${thing}-top`] = value;
if ( mode === 'y' || mode === 'b' ) if ( mode === '-y' || mode === '-b' )
styles[`${thing}-bottom`] = value; styles[`${thing}-bottom`] = value;
} }
} }
@ -501,7 +501,9 @@ TOKEN_TYPES.gallery = function(token, createElement, ctx) {
if ( ! token.items ) if ( ! token.items )
return null; return null;
let items = token.items.map(item => renderTokens(item, createElement, ctx)).filter(x => x); let items = token.items
.map(item => renderTokens(item, createElement, ctx))
.filter(x => x);
if ( ! items.length ) if ( ! items.length )
return null; return null;