diff --git a/webapp/src/components/AssetBrowse/AssetBrowse.tsx b/webapp/src/components/AssetBrowse/AssetBrowse.tsx index 17fdc635fc..840aff3517 100644 --- a/webapp/src/components/AssetBrowse/AssetBrowse.tsx +++ b/webapp/src/components/AssetBrowse/AssetBrowse.tsx @@ -33,7 +33,6 @@ import CollectionList from '../CollectionList' import StoreSettings from '../StoreSettings' import Sales from '../Sales' import { Bids } from '../Bids' -import { ClaimYourName } from '../ClaimYourName' import { Props } from './AssetBrowse.types' import MapTopbar from './MapTopbar' import MapBrowse from './MapBrowse' @@ -233,7 +232,6 @@ const AssetBrowse = (props: Props) => { case DecentralandSection.ENS: right = ( <> - {!isAccountOrCurrentAccount && } diff --git a/webapp/src/components/ClaimYourName/ClaimYourName.module.css b/webapp/src/components/ClaimYourName/ClaimYourName.module.css deleted file mode 100644 index fb80ea7e0d..0000000000 --- a/webapp/src/components/ClaimYourName/ClaimYourName.module.css +++ /dev/null @@ -1,82 +0,0 @@ -.gradient { - height: 152px; - width: 100%; - margin-bottom: 11px; - border-radius: 14.482757568359375px; - display: flex; - justify-content: center; - align-items: center; - overflow: hidden; - position: relative; -} - -.gradient::before { - content: ''; - position: absolute; - aspect-ratio: 1/1; - width: 105%; - background-image: radial-gradient( - 100% 100% at 6% 9%, - #ffbc5bff 2%, - #ffffff00 73% - ), - linear-gradient(60deg, #ff2d55 18%, #c640cd 100%); - z-index: -1; - animation: rotate 4s linear infinite; -} - -@keyframes rotate { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(360deg); - } -} - -@media (max-width: 767px) { - .gradient { - display: none; - } -} - -.container { - height: 146px; - width: calc(100% - 6px); - background: #242129; - border-radius: 14.482757568359375px; - display: flex; - justify-content: space-between; - align-items: center; - padding: 0 33px 0 15px; -} - -.imgTitleAndTextContainer { - display: flex; - align-items: center; -} - -.img { - margin-right: 14px; -} - -.title { - font-size: 20px; - font-weight: 700; - line-height: 24px; - letter-spacing: 0px; - text-align: left; -} - -.text { - font-size: 14px; - font-weight: 400; - line-height: 18px; - letter-spacing: 0em; - text-align: left; -} - -.btn { - max-width: 222px; - margin-left: 21px !important; -} diff --git a/webapp/src/components/ClaimYourName/ClaimYourName.spec.tsx b/webapp/src/components/ClaimYourName/ClaimYourName.spec.tsx deleted file mode 100644 index 55f5eac038..0000000000 --- a/webapp/src/components/ClaimYourName/ClaimYourName.spec.tsx +++ /dev/null @@ -1,51 +0,0 @@ -import { render, fireEvent } from '@testing-library/react' -import ClaimYourName from './ClaimYourName' -import { getAnalytics } from 'decentraland-dapps/dist/modules/analytics/utils' -import * as events from '../../utils/events' - -jest.mock('../../lib/environment', () => { - return { - builderUrl: 'https://mocked-builder-url.com' - } -}) - -jest.mock('decentraland-dapps/dist/modules/analytics/utils') - -const mockGetAnalytics = getAnalytics as jest.MockedFunction< - typeof getAnalytics -> - -describe('ClaimYourName', () => { - it('should have a link to the builder with the names path', async () => { - const { findByRole } = render() - const button = await findByRole('button') - expect(button.getAttribute('href')).toBe( - `https://mocked-builder-url.com/claim-name` - ) - }) - - describe('when tracking the event that the button was clicked', () => { - let track: jest.Mock - - beforeEach(() => { - track = jest.fn() - - mockGetAnalytics.mockReturnValueOnce({ - track - }) - }) - - it('should track an event when the user clicks on the button', async () => { - const { findByRole } = render() - // TODO: Fix the "Error: Not implemented: navigation (except hash changes)" that happens because of the href. - fireEvent.click(await findByRole('button')) - expect(track).toHaveBeenCalledWith(events.CLICK_CLAIM_NEW_NAME) - }) - - it('should track an event when the user right clicks on the button', async () => { - const { findByRole } = render() - fireEvent.contextMenu(await findByRole('button')) - expect(track).toHaveBeenCalledWith(events.CLICK_CLAIM_NEW_NAME) - }) - }) -}) diff --git a/webapp/src/components/ClaimYourName/ClaimYourName.tsx b/webapp/src/components/ClaimYourName/ClaimYourName.tsx deleted file mode 100644 index fcb4787cc3..0000000000 --- a/webapp/src/components/ClaimYourName/ClaimYourName.tsx +++ /dev/null @@ -1,55 +0,0 @@ -import React from 'react' -import { Link } from 'react-router-dom' -import { Button } from 'decentraland-ui' -import { T, t } from 'decentraland-dapps/dist/modules/translation/utils' -import { getAnalytics } from 'decentraland-dapps/dist/modules/analytics/utils' -import claimYourOwnNameImg from '../../images/claim-your-own-name.svg' -import * as events from '../../utils/events' -import { locations } from '../../modules/routing/locations' -import { Mana } from '../Mana' -import styles from './ClaimYourName.module.css' - -const ClaimYourName = () => { - const trackClick = () => { - getAnalytics().track(events.CLICK_CLAIM_NEW_NAME) - } - - return ( -
-
-
- Claim your own name -
-

{t('claim_your_own_name.title')}

-
- 100 - }} - /> -
-
-
- -
-
- ) -} - -export default React.memo(ClaimYourName) diff --git a/webapp/src/components/ClaimYourName/index.ts b/webapp/src/components/ClaimYourName/index.ts deleted file mode 100644 index 37a1ab46c5..0000000000 --- a/webapp/src/components/ClaimYourName/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -import ClaimYourName from './ClaimYourName' - -export { ClaimYourName }