diff --git a/src/components/IconWrapper/IconWrapper.scss b/src/components/IconWrapper/IconWrapper.scss index 28b7a2887..8f63d5a80 100644 --- a/src/components/IconWrapper/IconWrapper.scss +++ b/src/components/IconWrapper/IconWrapper.scss @@ -27,10 +27,13 @@ $block: '.#{$ns}icon-wrapper'; max-width: 100%; margin-bottom: $indentXXS; height: $iconSizePositionTop; - width: $iconSizePositionTop; object-fit: contain; display: block; + &_gravity-icon { + width: $iconSizePositionTop; + } + &_icon-position { &_left { height: $iconSizePositionLeftSizeS; diff --git a/src/components/IconWrapper/IconWrapper.tsx b/src/components/IconWrapper/IconWrapper.tsx index 62eebfff5..ec9766b49 100644 --- a/src/components/IconWrapper/IconWrapper.tsx +++ b/src/components/IconWrapper/IconWrapper.tsx @@ -25,7 +25,11 @@ const IconWrapper = (props: React.PropsWithChildren & ClassNam icon={icon?.value} gravityIcon={gravityIcon?.value} containerClassName={b('icon-container')} - className={b('icon', {['icon-position']: position, size})} + className={b('icon', { + ['icon-position']: position, + size, + ['gravity-icon']: Boolean(gravityIcon), + })} />
{children}