Commit 136c16bb authored by lynn's avatar lynn Committed by GitHub

fix: fix sell bag empty state (#5079)

* init

* fix comments
parent 691dcd26
...@@ -9,6 +9,9 @@ export const bagContainer = style([ ...@@ -9,6 +9,9 @@ export const bagContainer = style([
height: 'full', height: 'full',
right: '0', right: '0',
background: 'backgroundSurface', background: 'backgroundSurface',
borderLeftStyle: 'solid',
borderColor: 'backgroundOutline',
borderWidth: '1px',
color: 'textPrimary', color: 'textPrimary',
paddingTop: '20', paddingTop: '20',
paddingBottom: '24', paddingBottom: '24',
......
...@@ -3,13 +3,22 @@ import { LargeBagIcon, LargeTagIcon } from 'nft/components/icons' ...@@ -3,13 +3,22 @@ import { LargeBagIcon, LargeTagIcon } from 'nft/components/icons'
import { subhead } from 'nft/css/common.css' import { subhead } from 'nft/css/common.css'
import { themeVars } from 'nft/css/sprinkles.css' import { themeVars } from 'nft/css/sprinkles.css'
import { useLocation } from 'react-router-dom' import { useLocation } from 'react-router-dom'
import styled from 'styled-components/macro'
const StyledColumn = styled(Column)<{ isProfilePage?: boolean }>`
gap: ${({ isProfilePage }) => !isProfilePage && '12'};
margin-top: 36;
display: ${({ isProfilePage }) => isProfilePage && 'flex'};
justify-content: ${({ isProfilePage }) => isProfilePage && 'center'};
height: ${({ isProfilePage }) => isProfilePage && 'inherit'};
`
const EmptyState = () => { const EmptyState = () => {
const { pathname } = useLocation() const { pathname } = useLocation()
const isProfilePage = pathname.startsWith('/profile') const isProfilePage = pathname.startsWith('/profile')
return ( return (
<Column gap={isProfilePage ? '16' : '12'} marginTop="36"> <StyledColumn isProfilePage={isProfilePage}>
<Center> <Center>
{isProfilePage ? ( {isProfilePage ? (
<LargeTagIcon color={themeVars.colors.textTertiary} /> <LargeTagIcon color={themeVars.colors.textTertiary} />
...@@ -18,7 +27,7 @@ const EmptyState = () => { ...@@ -18,7 +27,7 @@ const EmptyState = () => {
)} )}
</Center> </Center>
{isProfilePage ? ( {isProfilePage ? (
<span className={subhead}>No NFTs Selected</span> <Center className={subhead}>No NFTs selected</Center>
) : ( ) : (
<Column gap="16"> <Column gap="16">
<Center className={subhead} style={{ lineHeight: '24px' }}> <Center className={subhead} style={{ lineHeight: '24px' }}>
...@@ -29,7 +38,7 @@ const EmptyState = () => { ...@@ -29,7 +38,7 @@ const EmptyState = () => {
</Center> </Center>
</Column> </Column>
)} )}
</Column> </StyledColumn>
) )
} }
......
...@@ -371,6 +371,7 @@ const colorStyles = defineProperties({ ...@@ -371,6 +371,7 @@ const colorStyles = defineProperties({
color: vars.color, color: vars.color,
background: vars.color, background: vars.color,
borderColor: vars.color, borderColor: vars.color,
borderLeftColor: vars.color,
borderBottomColor: vars.color, borderBottomColor: vars.color,
borderTopColor: vars.color, borderTopColor: vars.color,
backgroundColor: vars.color, backgroundColor: vars.color,
...@@ -390,6 +391,7 @@ const unresponsiveProperties = defineProperties({ ...@@ -390,6 +391,7 @@ const unresponsiveProperties = defineProperties({
properties: { properties: {
cursor: ['default', 'pointer', 'auto'], cursor: ['default', 'pointer', 'auto'],
borderStyle, borderStyle,
borderLeftStyle: borderStyle,
borderBottomStyle: borderStyle, borderBottomStyle: borderStyle,
borderTopStyle: borderStyle, borderTopStyle: borderStyle,
borderRadius: vars.radii, borderRadius: vars.radii,
......
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