Animated Custom Emoji: Better quality

This commit is contained in:
Alexander Zinchuk 2022-12-01 13:43:56 +01:00
parent 9f15821d15
commit f7ed70c832
2 changed files with 4 additions and 1 deletions

View File

@ -30,6 +30,7 @@ type OwnProps = {
className?: string; className?: string;
loopLimit?: number; loopLimit?: number;
style?: string; style?: string;
isBig?: boolean;
withGridFix?: boolean; withGridFix?: boolean;
withSharedAnimation?: boolean; withSharedAnimation?: boolean;
sharedCanvasRef?: React.RefObject<HTMLCanvasElement>; sharedCanvasRef?: React.RefObject<HTMLCanvasElement>;
@ -48,6 +49,7 @@ const CustomEmoji: FC<OwnProps> = ({
ref, ref,
documentId, documentId,
size = STICKER_SIZE, size = STICKER_SIZE,
isBig,
className, className,
loopLimit, loopLimit,
style, style,
@ -143,7 +145,7 @@ const CustomEmoji: FC<OwnProps> = ({
<StickerView <StickerView
containerRef={containerRef} containerRef={containerRef}
sticker={customEmoji} sticker={customEmoji}
isSmall isSmall={!isBig}
size={size} size={size}
customColor={customColor} customColor={customColor}
thumbClassName={styles.thumb} thumbClassName={styles.thumb}

View File

@ -64,6 +64,7 @@ const AnimatedCustomEmoji: FC<OwnProps & StateProps> = ({
className={buildClassName('AnimatedEmoji media-inner', sticker?.id === LIKE_STICKER_ID && 'like-sticker-thumb')} className={buildClassName('AnimatedEmoji media-inner', sticker?.id === LIKE_STICKER_ID && 'like-sticker-thumb')}
style={style} style={style}
size={size} size={size}
isBig
withSharedAnimation withSharedAnimation
forceOnHeavyAnimation forceOnHeavyAnimation
observeIntersectionForLoading={observeIntersection} observeIntersectionForLoading={observeIntersection}