Skip to content
This repository has been archived by the owner on Mar 16, 2023. It is now read-only.

Commit

Permalink
fix(sdk): adjust styles for asset with large values
Browse files Browse the repository at this point in the history
  • Loading branch information
LeilaWang committed Feb 6, 2020
1 parent a138da2 commit a46e09d
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ $profile-icon-size: map-get($avatar-sizes-map, 'm');
.sealed-icon {
$sealed-icon-size: map-get($avatar-sizes-map, 'l');
position: absolute;
top: map-get($spacing-map, 'xxl');
bottom: $block-spacing;
right: $block-padding-h;
display: flex;
align-items: center;
Expand Down
36 changes: 18 additions & 18 deletions packages/extension/src/ui/components/AnimatedBlocks/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -94,24 +94,6 @@ class AnimatedBlocks extends PureComponent {
},
)}
>
{!!sealedIcon && type === 'sealed' && (
<div className={styles['sealed-icon']}>
{sealedIcon === 'aztec' && (
<AztecSvg
theme="light"
size="s"
/>
)}
{sealedIcon === 'link' && (
<SVG
glyph={linkGlyph}
color="white"
width={iconSizeMap.m}
height={iconSizeMap.m}
/>
)}
</div>
)}
{blocks.map((block, i) => (
<div
key={+i}
Expand All @@ -127,6 +109,24 @@ class AnimatedBlocks extends PureComponent {
layer={0}
{...block}
/>
{!!sealedIcon && type === 'sealed' && i === 0 && (
<div className={styles['sealed-icon']}>
{sealedIcon === 'aztec' && (
<AztecSvg
theme="light"
size="s"
/>
)}
{sealedIcon === 'link' && (
<SVG
glyph={linkGlyph}
color="white"
width={iconSizeMap.m}
height={iconSizeMap.m}
/>
)}
</div>
)}
</div>
))}
</div>
Expand Down
9 changes: 7 additions & 2 deletions packages/extension/src/ui/components/ListItem/index.jsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import {
FlexBox,
Block,
Expand All @@ -16,6 +17,7 @@ import {
profileShape,
} from '~/ui/config/propTypes';
import ProfileIcon from '~/ui/components/ProfileIcon';
import styles from './li.scss';

const spacingMapping = {
xxs: 's',
Expand Down Expand Up @@ -63,7 +65,7 @@ const ListItem = ({
size={size}
/>
<Block
className="flex-free-expand"
className={classnames('flex-free-expand', styles.content)}
align="left"
left={spacingMapping[contentSpacingSize || size]}
>
Expand All @@ -85,7 +87,10 @@ const ListItem = ({
nowrap
>
{profileNode}
<Block left="m">
<Block
className="flex-fixed"
left="m"
>
<Text
size={textSize || size}
>
Expand Down
3 changes: 3 additions & 0 deletions packages/extension/src/ui/components/ListItem/li.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.content {
word-break: break-all;
}

0 comments on commit a46e09d

Please sign in to comment.