Commit e04be071 authored by eddie's avatar eddie Committed by GitHub

fix: unknown token logo styling (#7132)

* fix: unknown token logo styling

* fix: tests
parent 5c3caa71
...@@ -15,6 +15,9 @@ export const MissingImageLogo = styled.div<{ size?: string }>` ...@@ -15,6 +15,9 @@ export const MissingImageLogo = styled.div<{ size?: string }>`
line-height: ${({ size }) => size ?? '24px'}; line-height: ${({ size }) => size ?? '24px'};
text-align: center; text-align: center;
width: ${({ size }) => size ?? '24px'}; width: ${({ size }) => size ?? '24px'};
display: flex;
align-items: center;
justify-content: center;
` `
const LogoImage = styled.img<{ size: string; imgLoaded?: boolean }>` const LogoImage = styled.img<{ size: string; imgLoaded?: boolean }>`
...@@ -83,7 +86,7 @@ export default function AssetLogo({ ...@@ -83,7 +86,7 @@ export default function AssetLogo({
}) })
return ( return (
<LogoContainer style={style}> <LogoContainer style={{ height: size, width: size, ...style }}>
{src ? ( {src ? (
<LogoImageWrapper size={size} imgLoaded={imgLoaded}> <LogoImageWrapper size={size} imgLoaded={imgLoaded}>
<LogoImage <LogoImage
......
...@@ -362,6 +362,7 @@ exports[`LoadedRow.tsx renders a row 1`] = ` ...@@ -362,6 +362,7 @@ exports[`LoadedRow.tsx renders a row 1`] = `
> >
<div <div
class="c7" class="c7"
style="height: 24px; width: 24px;"
> >
<div <div
class="c8" class="c8"
......
...@@ -165,6 +165,7 @@ exports[`SwapModalHeader.tsx matches base snapshot, test trade exact input 1`] = ...@@ -165,6 +165,7 @@ exports[`SwapModalHeader.tsx matches base snapshot, test trade exact input 1`] =
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
...@@ -212,6 +213,7 @@ exports[`SwapModalHeader.tsx matches base snapshot, test trade exact input 1`] = ...@@ -212,6 +213,7 @@ exports[`SwapModalHeader.tsx matches base snapshot, test trade exact input 1`] =
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
...@@ -397,6 +399,7 @@ exports[`SwapModalHeader.tsx renders ETH input token for an ETH input UniswapX s ...@@ -397,6 +399,7 @@ exports[`SwapModalHeader.tsx renders ETH input token for an ETH input UniswapX s
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
...@@ -444,6 +447,7 @@ exports[`SwapModalHeader.tsx renders ETH input token for an ETH input UniswapX s ...@@ -444,6 +447,7 @@ exports[`SwapModalHeader.tsx renders ETH input token for an ETH input UniswapX s
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
...@@ -629,6 +633,7 @@ exports[`SwapModalHeader.tsx test trade exact output, no recipient 1`] = ` ...@@ -629,6 +633,7 @@ exports[`SwapModalHeader.tsx test trade exact output, no recipient 1`] = `
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
...@@ -676,6 +681,7 @@ exports[`SwapModalHeader.tsx test trade exact output, no recipient 1`] = ` ...@@ -676,6 +681,7 @@ exports[`SwapModalHeader.tsx test trade exact output, no recipient 1`] = `
</div> </div>
<div <div
class="c10" class="c10"
style="height: 36px; width: 36px;"
> >
<div <div
class="c11" class="c11"
......
...@@ -1833,7 +1833,7 @@ exports[`disable nft on landing page does not render nft information and card 1` ...@@ -1833,7 +1833,7 @@ exports[`disable nft on landing page does not render nft information and card 1`
> >
<div <div
class="c29" class="c29"
style="margin-right: 2px;" style="height: 24px; width: 24px; margin-right: 2px;"
> >
<div <div
class="c30" class="c30"
...@@ -4407,7 +4407,7 @@ exports[`disable nft on landing page renders nft information and card 1`] = ` ...@@ -4407,7 +4407,7 @@ exports[`disable nft on landing page renders nft information and card 1`] = `
> >
<div <div
class="c29" class="c29"
style="margin-right: 2px;" style="height: 24px; width: 24px; margin-right: 2px;"
> >
<div <div
class="c30" class="c30"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment