Make img alt="" text maximum of 32 characters #564

This commit is contained in:
the-djmaze 2022-10-19 16:44:35 +02:00
parent c7cf5b1c2c
commit 60d7cbb318

View file

@ -325,7 +325,7 @@ export const
{ {
setAttribute('data-x-src', value); setAttribute('data-x-src', value);
result.hasExternals = true; result.hasExternals = true;
oElement.alt || (oElement.alt = value.replace(/^.+\/([^/]+)$/, '$1')); oElement.alt || (oElement.alt = value.replace(/^.+\/([^/]+)$/, '$1').slice(0, 32));
} }
else if ('data:image/' === value.slice(0, 11)) else if ('data:image/' === value.slice(0, 11))
{ {