Skip to content

Commit

Permalink
feat: improve the intersection observer hook by using refs
Browse files Browse the repository at this point in the history
  • Loading branch information
juanmahidalgo committed Feb 3, 2025
1 parent cb8365a commit ec7ed2a
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,9 @@ const SaleRentActionBox = ({
[order, currentMana]
)

const isClaimeable = !!wallet && !!rental && canBeClaimed('0xe5dd995b4a941e96a0afe9c0994b1258645cbc42', rental, nft)
console.log('isClaimeable:', isClaimeable)

return (
<div className={styles.main}>
{isRentalOpen && maxPriceOfPeriods ? (
Expand Down Expand Up @@ -208,7 +211,7 @@ const SaleRentActionBox = ({
) : (
<div className={styles.upperMessage}>{t('asset_page.sales_rent_action_box.not_for_sale')}</div>
)}
{isOwner && rental && wallet && canBeClaimed(wallet?.address, rental, nft) ? (
{rental && wallet && isClaimeable ? (
<div className={styles.upperMessageDescription}>
{t('asset_page.sales_rent_action_box.claim_back_message', {
asset_type: nft.category
Expand Down

0 comments on commit ec7ed2a

Please sign in to comment.