ChannelThumbnail: fix quality typo + consolidate 'small' variant sizes
- Fixed quality typo - Make all the 'small' variants use the same size for better caching.
This commit is contained in:
parent
4e35a2e5dc
commit
1ab140c192
1 changed files with 3 additions and 2 deletions
|
@ -119,12 +119,13 @@ function ChannelThumbnail(props: Props) {
|
||||||
'channel-thumbnail--resolving': isResolving,
|
'channel-thumbnail--resolving': isResolving,
|
||||||
})}
|
})}
|
||||||
>
|
>
|
||||||
|
{/* width: use the same size for all 'small' variants so that caching works better */}
|
||||||
<OptimizedImage
|
<OptimizedImage
|
||||||
alt={__('Channel profile picture')}
|
alt={__('Channel profile picture')}
|
||||||
className={!channelThumbnail ? 'channel-thumbnail__default' : 'channel-thumbnail__custom'}
|
className={!channelThumbnail ? 'channel-thumbnail__default' : 'channel-thumbnail__custom'}
|
||||||
src={(!thumbLoadError && channelThumbnail) || defaultAvatar}
|
src={(!thumbLoadError && channelThumbnail) || defaultAvatar}
|
||||||
width={xxsmall ? 16 : small || xsmall ? 64 : 160}
|
width={xxsmall || xsmall || small ? 64 : 160}
|
||||||
quality={xxsmall ? 16 : small || xsmall ? 85 : 95}
|
quality={95}
|
||||||
loading={noLazyLoad ? undefined : 'lazy'}
|
loading={noLazyLoad ? undefined : 'lazy'}
|
||||||
onError={() => {
|
onError={() => {
|
||||||
if (setThumbUploadError) {
|
if (setThumbUploadError) {
|
||||||
|
|
Loading…
Reference in a new issue