Custom Emoji: Limit canvas size to wrapper (#6890)

This commit is contained in:
zubiden 2026-04-27 14:29:23 +02:00 committed by Alexander Zinchuk
parent e30555d3b3
commit d8f913b3a0
3 changed files with 10 additions and 1 deletions

View File

@ -13,6 +13,8 @@
:global(.rlottie-canvas) { :global(.rlottie-canvas) {
display: block; display: block;
width: 100% !important;
height: 100% !important;
} }
} }

View File

@ -28,6 +28,7 @@ const RankBadge = ({
const { openRankModal } = getActions(); const { openRankModal } = getActions();
const lang = useLang(); const lang = useLang();
const hasCustomColor = isOwner || isAdmin; const hasCustomColor = isOwner || isAdmin;
const isPlain = !hasCustomColor;
const rankText = rank || (isOwner && lang('ChannelCreator')) || (isAdmin && lang('ChannelAdmin')); const rankText = rank || (isOwner && lang('ChannelCreator')) || (isAdmin && lang('ChannelAdmin'));
@ -44,9 +45,10 @@ const RankBadge = ({
<BadgeButton <BadgeButton
className={buildClassName( className={buildClassName(
hasCustomColor && getPeerColorClass(isOwner ? OWNER_PEER_COLOR : ADMIN_PEER_COLOR), hasCustomColor && getPeerColorClass(isOwner ? OWNER_PEER_COLOR : ADMIN_PEER_COLOR),
isPlain && 'admin-title-plain',
className, className,
)} )}
isPlain={!hasCustomColor} isPlain={isPlain}
inline inline
onClick={isClickable ? handleClick : undefined} onClick={isClickable ? handleClick : undefined}
> >

View File

@ -335,6 +335,7 @@
.sender-title { .sender-title {
overflow: hidden; overflow: hidden;
line-height: normal;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
@ -416,6 +417,10 @@
margin-right: -0.1875rem; margin-right: -0.1875rem;
} }
.admin-title-plain {
padding-inline: 0.25rem;
}
.admin-title { .admin-title {
font-size: 0.75rem; font-size: 0.75rem;
font-weight: var(--font-weight-normal); font-weight: var(--font-weight-normal);