From fd6f992786934fbb1fa0b84a7cd9ecb6d2b635f5 Mon Sep 17 00:00:00 2001 From: Graham Tackley Date: Tue, 23 Apr 2024 08:29:37 +0100 Subject: [PATCH] refactor: move images to src/assets/images (#1168) Rather than being dumped in the root directory, which is unusual. --- .../images/Subdomains_Rewards_Ads_Default.png | Bin .../assets/images/ad-benefits.svg | 0 .../assets/images/all_sizes_frame.svg | 0 .../assets/images/basic-attention-token.svg | 0 .../assets/images/brave-icon-release-color.svg | 0 .../assets/images/brave_logo_icon.png | Bin curtains.png => src/assets/images/curtains.png | Bin .../assets/images/darker-gradient.svg | 0 favicon.png => src/assets/images/favicon.png | Bin images.svg => src/assets/images/images.svg | 0 logo.svg => src/assets/images/logo.svg | 0 microwave.png => src/assets/images/microwave.png | Bin .../assets/images/news-mobile.png | Bin newsfeed.png => src/assets/images/newsfeed.png | Bin .../assets/images/notification.png | Bin .../assets/images/powerful_format_frame.svg | 0 .../assets/images/privacy_focused_frame.svg | 0 .../assets/images/search-preview.png | Bin tswift.png => src/assets/images/tswift.png | Bin src/auth/registration/AccountChoice.tsx | 2 +- src/auth/registration/AdvertiserRegistered.tsx | 2 +- src/auth/registration/RegistrationContainer.tsx | 2 +- src/auth/views/LandingPage.tsx | 2 +- src/auth/views/MobileAdsBenefits.tsx | 6 +++--- .../BasicAttentionTokenLandingPage.tsx | 6 +++--- src/components/AppBar/LandingPageAppBar.tsx | 2 +- src/components/Background/Background.tsx | 2 +- src/components/Creatives/NotificationPreview.tsx | 2 +- src/components/Navigation/Navbar.tsx | 2 +- 29 files changed, 14 insertions(+), 14 deletions(-) rename Subdomains_Rewards_Ads_Default.png => src/assets/images/Subdomains_Rewards_Ads_Default.png (100%) rename ad-benefits.svg => src/assets/images/ad-benefits.svg (100%) rename all_sizes_frame.svg => src/assets/images/all_sizes_frame.svg (100%) rename basic-attention-token.svg => src/assets/images/basic-attention-token.svg (100%) rename brave-icon-release-color.svg => src/assets/images/brave-icon-release-color.svg (100%) rename brave_logo_icon.png => src/assets/images/brave_logo_icon.png (100%) rename curtains.png => src/assets/images/curtains.png (100%) rename darker-gradient.svg => src/assets/images/darker-gradient.svg (100%) rename favicon.png => src/assets/images/favicon.png (100%) rename images.svg => src/assets/images/images.svg (100%) rename logo.svg => src/assets/images/logo.svg (100%) rename microwave.png => src/assets/images/microwave.png (100%) rename news-mobile.png => src/assets/images/news-mobile.png (100%) rename newsfeed.png => src/assets/images/newsfeed.png (100%) rename notification.png => src/assets/images/notification.png (100%) rename powerful_format_frame.svg => src/assets/images/powerful_format_frame.svg (100%) rename privacy_focused_frame.svg => src/assets/images/privacy_focused_frame.svg (100%) rename search-preview.png => src/assets/images/search-preview.png (100%) rename tswift.png => src/assets/images/tswift.png (100%) diff --git a/Subdomains_Rewards_Ads_Default.png b/src/assets/images/Subdomains_Rewards_Ads_Default.png similarity index 100% rename from Subdomains_Rewards_Ads_Default.png rename to src/assets/images/Subdomains_Rewards_Ads_Default.png diff --git a/ad-benefits.svg b/src/assets/images/ad-benefits.svg similarity index 100% rename from ad-benefits.svg rename to src/assets/images/ad-benefits.svg diff --git a/all_sizes_frame.svg b/src/assets/images/all_sizes_frame.svg similarity index 100% rename from all_sizes_frame.svg rename to src/assets/images/all_sizes_frame.svg diff --git a/basic-attention-token.svg b/src/assets/images/basic-attention-token.svg similarity index 100% rename from basic-attention-token.svg rename to src/assets/images/basic-attention-token.svg diff --git a/brave-icon-release-color.svg b/src/assets/images/brave-icon-release-color.svg similarity index 100% rename from brave-icon-release-color.svg rename to src/assets/images/brave-icon-release-color.svg diff --git a/brave_logo_icon.png b/src/assets/images/brave_logo_icon.png similarity index 100% rename from brave_logo_icon.png rename to src/assets/images/brave_logo_icon.png diff --git a/curtains.png b/src/assets/images/curtains.png similarity index 100% rename from curtains.png rename to src/assets/images/curtains.png diff --git a/darker-gradient.svg b/src/assets/images/darker-gradient.svg similarity index 100% rename from darker-gradient.svg rename to src/assets/images/darker-gradient.svg diff --git a/favicon.png b/src/assets/images/favicon.png similarity index 100% rename from favicon.png rename to src/assets/images/favicon.png diff --git a/images.svg b/src/assets/images/images.svg similarity index 100% rename from images.svg rename to src/assets/images/images.svg diff --git a/logo.svg b/src/assets/images/logo.svg similarity index 100% rename from logo.svg rename to src/assets/images/logo.svg diff --git a/microwave.png b/src/assets/images/microwave.png similarity index 100% rename from microwave.png rename to src/assets/images/microwave.png diff --git a/news-mobile.png b/src/assets/images/news-mobile.png similarity index 100% rename from news-mobile.png rename to src/assets/images/news-mobile.png diff --git a/newsfeed.png b/src/assets/images/newsfeed.png similarity index 100% rename from newsfeed.png rename to src/assets/images/newsfeed.png diff --git a/notification.png b/src/assets/images/notification.png similarity index 100% rename from notification.png rename to src/assets/images/notification.png diff --git a/powerful_format_frame.svg b/src/assets/images/powerful_format_frame.svg similarity index 100% rename from powerful_format_frame.svg rename to src/assets/images/powerful_format_frame.svg diff --git a/privacy_focused_frame.svg b/src/assets/images/privacy_focused_frame.svg similarity index 100% rename from privacy_focused_frame.svg rename to src/assets/images/privacy_focused_frame.svg diff --git a/search-preview.png b/src/assets/images/search-preview.png similarity index 100% rename from search-preview.png rename to src/assets/images/search-preview.png diff --git a/tswift.png b/src/assets/images/tswift.png similarity index 100% rename from tswift.png rename to src/assets/images/tswift.png diff --git a/src/auth/registration/AccountChoice.tsx b/src/auth/registration/AccountChoice.tsx index 4d556e83..6bb593c9 100644 --- a/src/auth/registration/AccountChoice.tsx +++ b/src/auth/registration/AccountChoice.tsx @@ -12,7 +12,7 @@ import { msg, Trans } from "@lingui/macro"; import { useLingui } from "@lingui/react"; import { MessageDescriptor } from "@lingui/core"; import { useState } from "react"; -import logo from "../../../brave-icon-release-color.svg"; +import logo from "assets/images/brave-icon-release-color.svg"; import { useTrackMatomoPageView } from "hooks/useTrackWithMatomo"; import { useIsMobile } from "hooks/useIsMobile"; import { AuthContainer } from "auth/views/components/AuthContainer"; diff --git a/src/auth/registration/AdvertiserRegistered.tsx b/src/auth/registration/AdvertiserRegistered.tsx index d08e5ad6..feb1efe0 100644 --- a/src/auth/registration/AdvertiserRegistered.tsx +++ b/src/auth/registration/AdvertiserRegistered.tsx @@ -2,7 +2,7 @@ import { Link, Stack, Typography } from "@mui/material"; import { useTrackMatomoPageView } from "hooks/useTrackWithMatomo"; import { Trans } from "@lingui/macro"; import { AuthContainer } from "auth/views/components/AuthContainer"; -import logo from "../../../brave-icon-release-color.svg"; +import logo from "assets/images/brave-icon-release-color.svg"; export function AdvertiserRegistered() { useTrackMatomoPageView({ documentTitle: "Advertiser Registration Complete" }); diff --git a/src/auth/registration/RegistrationContainer.tsx b/src/auth/registration/RegistrationContainer.tsx index c7661bc7..0c4a1029 100644 --- a/src/auth/registration/RegistrationContainer.tsx +++ b/src/auth/registration/RegistrationContainer.tsx @@ -1,6 +1,6 @@ import { PropsWithChildren } from "react"; import { PaddedCardContainer } from "components/Card/PaddedCardContainer"; -import logo from "../../../brave-icon-release-color.svg"; +import logo from "assets/images/brave-icon-release-color.svg"; import Typography from "@mui/material/Typography"; import { Trans } from "@lingui/macro"; import { PrivacyPolicy } from "basic-attention-token/PrivacyPolicy"; diff --git a/src/auth/views/LandingPage.tsx b/src/auth/views/LandingPage.tsx index 83b8914c..833f4deb 100644 --- a/src/auth/views/LandingPage.tsx +++ b/src/auth/views/LandingPage.tsx @@ -1,7 +1,7 @@ import { Background } from "components/Background/Background"; import { LandingPageAppBar } from "components/AppBar/LandingPageAppBar"; import { Box, Button, Link, Stack, Toolbar, Typography } from "@mui/material"; -import benefits from "../../../ad-benefits.svg"; +import benefits from "assets/images/ad-benefits.svg"; import { useIsAuthenticated } from "auth/hooks/queries/useIsAuthenticated"; import { Link as RouterLink } from "react-router-dom"; import { useIsMobile } from "hooks/useIsMobile"; diff --git a/src/auth/views/MobileAdsBenefits.tsx b/src/auth/views/MobileAdsBenefits.tsx index f32a7505..9689c182 100644 --- a/src/auth/views/MobileAdsBenefits.tsx +++ b/src/auth/views/MobileAdsBenefits.tsx @@ -1,8 +1,8 @@ import { Card, CardMedia, List, ListItem, Typography } from "@mui/material"; -import allSizes from "../../../all_sizes_frame.svg"; -import powerfulFormats from "../../../powerful_format_frame.svg"; -import privacyFocused from "../../../privacy_focused_frame.svg"; +import allSizes from "assets/images/all_sizes_frame.svg"; +import powerfulFormats from "assets/images/powerful_format_frame.svg"; +import privacyFocused from "assets/images/privacy_focused_frame.svg"; import { msg } from "@lingui/macro"; import { MessageDescriptor } from "@lingui/core"; import { Trans } from "@lingui/react"; diff --git a/src/basic-attention-token/BasicAttentionTokenLandingPage.tsx b/src/basic-attention-token/BasicAttentionTokenLandingPage.tsx index bb1edf47..70560ca9 100644 --- a/src/basic-attention-token/BasicAttentionTokenLandingPage.tsx +++ b/src/basic-attention-token/BasicAttentionTokenLandingPage.tsx @@ -7,9 +7,9 @@ import { Background } from "components/Background/Background"; import { LandingPageAppBar } from "components/AppBar/LandingPageAppBar"; import { Box, Button, Link, Stack, Toolbar, Typography } from "@mui/material"; import { Link as RouterLink } from "react-router-dom"; -import notification from "../../newsfeed.png"; -import mobileAd from "../../news-mobile.png"; -import bat from "../../basic-attention-token.svg"; +import notification from "assets/images/newsfeed.png"; +import mobileAd from "assets/images/news-mobile.png"; +import bat from "assets/images/basic-attention-token.svg"; import { Trans } from "@lingui/macro"; export function BasicAttentionTokenLandingPage() { diff --git a/src/components/AppBar/LandingPageAppBar.tsx b/src/components/AppBar/LandingPageAppBar.tsx index fd1409b5..2dffffda 100644 --- a/src/components/AppBar/LandingPageAppBar.tsx +++ b/src/components/AppBar/LandingPageAppBar.tsx @@ -7,7 +7,7 @@ import { Toolbar, Typography, } from "@mui/material"; -import ads from "../../../logo.svg"; +import ads from "assets/images/logo.svg"; import { Link as RouterLink, useRouteMatch } from "react-router-dom"; import { useIsAuthenticated } from "auth/hooks/queries/useIsAuthenticated"; import { useSignOut } from "auth/hooks/mutations/useSignOut"; diff --git a/src/components/Background/Background.tsx b/src/components/Background/Background.tsx index cec4ce2f..2939c94e 100644 --- a/src/components/Background/Background.tsx +++ b/src/components/Background/Background.tsx @@ -1,5 +1,5 @@ import { PropsWithChildren } from "react"; -import gradient from "../../../darker-gradient.svg"; +import gradient from "assets/images/darker-gradient.svg"; import { Container } from "@mui/material"; import { useIsMobile } from "hooks/useIsMobile"; diff --git a/src/components/Creatives/NotificationPreview.tsx b/src/components/Creatives/NotificationPreview.tsx index 87dc1212..1595cd86 100644 --- a/src/components/Creatives/NotificationPreview.tsx +++ b/src/components/Creatives/NotificationPreview.tsx @@ -1,5 +1,5 @@ import { Box, Paper, Stack, Typography } from "@mui/material"; -import logo from "../../../brave_logo_icon.png"; +import logo from "assets/images/brave_logo_icon.png"; import { useField, useFormikContext } from "formik"; import { CreativeInput } from "graphql/types"; import { Trans } from "@lingui/macro"; diff --git a/src/components/Navigation/Navbar.tsx b/src/components/Navigation/Navbar.tsx index e3a94290..331ba3ba 100644 --- a/src/components/Navigation/Navbar.tsx +++ b/src/components/Navigation/Navbar.tsx @@ -1,7 +1,7 @@ import { AppBar, Button, Divider, Stack, Toolbar } from "@mui/material"; import { DraftMenu } from "components/Navigation/DraftMenu"; -import ads from "../../../logo.svg"; +import ads from "assets/images/logo.svg"; import { useAdvertiser } from "auth/hooks/queries/useAdvertiser"; import { useSignOut } from "auth/hooks/mutations/useSignOut"; import { NewCampaignButton } from "components/Navigation/NewCampaignButton";