Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
interface
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
LuckySwap
interface
Commits
e903a335
Unverified
Commit
e903a335
authored
Dec 01, 2022
by
lynn
Committed by
GitHub
Dec 01, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: disabled treatment for unlisted collection page card + tooltip styling fixes (#5507)
init
parent
3be5e9b5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
9 deletions
+26
-9
CollectionAsset.tsx
src/nft/components/collection/CollectionAsset.tsx
+24
-8
ViewMyNftsAsset.tsx
src/nft/components/profile/view/ViewMyNftsAsset.tsx
+2
-1
No files found.
src/nft/components/collection/CollectionAsset.tsx
View file @
e903a335
...
@@ -2,6 +2,7 @@ import { BigNumber } from '@ethersproject/bignumber'
...
@@ -2,6 +2,7 @@ import { BigNumber } from '@ethersproject/bignumber'
import
{
Trans
}
from
'
@lingui/macro
'
import
{
Trans
}
from
'
@lingui/macro
'
import
{
sendAnalyticsEvent
,
useTrace
}
from
'
@uniswap/analytics
'
import
{
sendAnalyticsEvent
,
useTrace
}
from
'
@uniswap/analytics
'
import
{
EventName
,
PageName
}
from
'
@uniswap/analytics-events
'
import
{
EventName
,
PageName
}
from
'
@uniswap/analytics-events
'
import
{
MouseoverTooltip
}
from
'
components/Tooltip
'
import
Tooltip
from
'
components/Tooltip
'
import
Tooltip
from
'
components/Tooltip
'
import
{
Box
}
from
'
nft/components/Box
'
import
{
Box
}
from
'
nft/components/Box
'
import
{
bodySmall
}
from
'
nft/css/common.css
'
import
{
bodySmall
}
from
'
nft/css/common.css
'
...
@@ -120,7 +121,7 @@ export const CollectionAsset = ({
...
@@ -120,7 +121,7 @@ export const CollectionAsset = ({
addAssetToBag=
{
handleAddAssetToBag
}
addAssetToBag=
{
handleAddAssetToBag
}
removeAssetFromBag=
{
handleRemoveAssetFromBag
}
removeAssetFromBag=
{
handleRemoveAssetFromBag
}
>
>
<
Card
.
ImageContainer
>
<
Card
.
ImageContainer
isDisabled=
{
asset
.
notForSale
}
>
<
StyledContainer
>
<
StyledContainer
>
<
Tooltip
<
Tooltip
text=
{
text=
{
...
@@ -145,13 +146,28 @@ export const CollectionAsset = ({
...
@@ -145,13 +146,28 @@ export const CollectionAsset = ({
rarityLogo=
{
rarityLogo
}
rarityLogo=
{
rarityLogo
}
/>
/>
)
}
)
}
{
assetMediaType
===
AssetMediaType
.
Image
?
(
<
MouseoverTooltip
<
Card
.
Image
/>
text=
{
)
:
assetMediaType
===
AssetMediaType
.
Video
?
(
<
Box
as=
"span"
className=
{
bodySmall
}
color=
"textPrimary"
>
<
Card
.
Video
shouldPlay=
{
mediaShouldBePlaying
}
setCurrentTokenPlayingMedia=
{
setCurrentTokenPlayingMedia
}
/>
<
Trans
>
This item is not for sale
</
Trans
>
)
:
(
</
Box
>
<
Card
.
Audio
shouldPlay=
{
mediaShouldBePlaying
}
setCurrentTokenPlayingMedia=
{
setCurrentTokenPlayingMedia
}
/>
}
)
}
placement=
"bottom"
offsetX=
{
0
}
offsetY=
{
-
50
}
style=
{
{
display
:
'
block
'
}
}
hideArrow=
{
true
}
disableHover=
{
!
asset
.
notForSale
}
timeout=
{
isMobile
?
TOOLTIP_TIMEOUT
:
undefined
}
>
{
assetMediaType
===
AssetMediaType
.
Image
?
(
<
Card
.
Image
/>
)
:
assetMediaType
===
AssetMediaType
.
Video
?
(
<
Card
.
Video
shouldPlay=
{
mediaShouldBePlaying
}
setCurrentTokenPlayingMedia=
{
setCurrentTokenPlayingMedia
}
/>
)
:
(
<
Card
.
Audio
shouldPlay=
{
mediaShouldBePlaying
}
setCurrentTokenPlayingMedia=
{
setCurrentTokenPlayingMedia
}
/>
)
}
</
MouseoverTooltip
>
</
Card
.
ImageContainer
>
</
Card
.
ImageContainer
>
<
Card
.
DetailsContainer
>
<
Card
.
DetailsContainer
>
<
Card
.
InfoContainer
>
<
Card
.
InfoContainer
>
...
...
src/nft/components/profile/view/ViewMyNftsAsset.tsx
View file @
e903a335
...
@@ -126,7 +126,8 @@ export const ViewMyNftsAsset = ({
...
@@ -126,7 +126,8 @@ export const ViewMyNftsAsset = ({
text=
{
getUnsupportedNftTextComponent
(
asset
)
}
text=
{
getUnsupportedNftTextComponent
(
asset
)
}
placement=
"bottom"
placement=
"bottom"
offsetX=
{
0
}
offsetX=
{
0
}
offsetY=
{
-
100
}
offsetY=
{
-
60
}
hideArrow=
{
true
}
style=
{
{
display
:
'
block
'
}
}
style=
{
{
display
:
'
block
'
}
}
disableHover=
{
!
isDisabled
}
disableHover=
{
!
isDisabled
}
timeout=
{
isMobile
?
TOOLTIP_TIMEOUT
:
undefined
}
timeout=
{
isMobile
?
TOOLTIP_TIMEOUT
:
undefined
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment