From 8e37e0fbeda7b4f5d4ea9fb133fc719f8be4680f Mon Sep 17 00:00:00 2001 From: Martti Malmi Date: Wed, 10 Jan 2024 18:53:35 +0200 Subject: [PATCH] fix some warnings --- .../app/src/Components/Feed/ImageGridItem.tsx | 14 +- packages/app/src/Pages/DonatePage.tsx | 2 +- packages/app/src/Pages/Layout/index.tsx | 2 +- packages/app/src/Pages/NostrAddressPage.tsx | 19 +- .../app/src/Pages/Profile/ProfilePage.tsx | 11 +- packages/app/src/Pages/Profile/ProfileTab.tsx | 61 +---- .../app/src/Pages/Profile/ProfileTabType.tsx | 11 + .../app/src/Pages/Profile/ProfileTabs.tsx | 49 ++++ .../src/Pages/onboarding/fixedModeration.tsx | 105 ++++++++ .../app/src/Pages/onboarding/fixedTopics.tsx | 249 ++++++++++++++++++ .../app/src/Pages/onboarding/moderation.tsx | 105 +------- packages/app/src/Pages/onboarding/topics.tsx | 249 +----------------- .../settings/SnortNostrAddressService.tsx | 12 + .../src/Pages/subscribe/SubscriptionCard.tsx | 2 +- packages/app/src/index.css | 6 +- 15 files changed, 450 insertions(+), 447 deletions(-) create mode 100644 packages/app/src/Pages/Profile/ProfileTabType.tsx create mode 100644 packages/app/src/Pages/Profile/ProfileTabs.tsx create mode 100644 packages/app/src/Pages/onboarding/fixedModeration.tsx create mode 100644 packages/app/src/Pages/onboarding/fixedTopics.tsx create mode 100644 packages/app/src/Pages/settings/SnortNostrAddressService.tsx diff --git a/packages/app/src/Components/Feed/ImageGridItem.tsx b/packages/app/src/Components/Feed/ImageGridItem.tsx index c9935560..6fb3f749 100644 --- a/packages/app/src/Components/Feed/ImageGridItem.tsx +++ b/packages/app/src/Components/Feed/ImageGridItem.tsx @@ -7,14 +7,14 @@ import Icon from "@/Components/Icons/Icon"; import { ProxyImg } from "@/Components/ProxyImg"; import getEventMedia from "@/Utils/getEventMedia"; -export interface ImageGridItemProps { +interface ImageGridItemProps { event: TaggedNostrEvent; onClick?: (event: MouseEvent) => void; waitUntilInView?: boolean; } -function ImageGridItem(props: ImageGridItemProps) { - const { event, onClick } = props; +const ImageGridItem = memo((props: ImageGridItemProps) => { + const { event, onClick, waitUntilInView } = props; const { ref, inView } = useInView({ triggerOnce: true, rootMargin: "0px 0px 3000px 0px" }); const media = getEventMedia(event); @@ -33,7 +33,7 @@ function ImageGridItem(props: ImageGridItemProps) { }; const renderContent = (): ReactNode | undefined => { - if (props.waitUntilInView && !inView) return undefined; + if (waitUntilInView && !inView) return undefined; return ( <> @@ -54,6 +54,8 @@ function ImageGridItem(props: ImageGridItemProps) { {renderContent()} ); -} +}); -export default memo(ImageGridItem); +ImageGridItem.displayName = "ImageGridItem"; + +export default ImageGridItem; diff --git a/packages/app/src/Pages/DonatePage.tsx b/packages/app/src/Pages/DonatePage.tsx index 344bd04d..5fda9c60 100644 --- a/packages/app/src/Pages/DonatePage.tsx +++ b/packages/app/src/Pages/DonatePage.tsx @@ -55,7 +55,7 @@ const Translators = [ bech32ToHex("npub1ust7u0v3qffejwhqee45r49zgcyewrcn99vdwkednd356c9resyqtnn3mj"), // Petri - FI ]; -export const DonateLNURL = "donate@snort.social"; +const DonateLNURL = "donate@snort.social"; const DonatePage = () => { const [splits, setSplits] = useState([]); diff --git a/packages/app/src/Pages/Layout/index.tsx b/packages/app/src/Pages/Layout/index.tsx index 7a77e3dc..08befc20 100644 --- a/packages/app/src/Pages/Layout/index.tsx +++ b/packages/app/src/Pages/Layout/index.tsx @@ -61,7 +61,7 @@ export default function Index() {
-
+
{!shouldHideHeader &&
} diff --git a/packages/app/src/Pages/NostrAddressPage.tsx b/packages/app/src/Pages/NostrAddressPage.tsx index dfbbb598..9da73f4f 100644 --- a/packages/app/src/Pages/NostrAddressPage.tsx +++ b/packages/app/src/Pages/NostrAddressPage.tsx @@ -1,26 +1,11 @@ import { FormattedMessage } from "react-intl"; import Nip5Service from "@/Components/Nip5Service"; -import { ApiHost } from "@/Utils/Const"; +import { SnortNostrAddressService } from "@/Pages/settings/SnortNostrAddressService"; import messages from "./messages"; -export const SnortNostrAddressService = { - name: "Snort", - service: `${ApiHost}/api/v1/n5sp`, - link: "https://snort.social/", - supportLink: "https://snort.social/help", - about: , -}; -export const NostrPlebsService = { - name: "Nostr Plebs", - service: "https://nostrplebs.com/api/v1", - link: "https://nostrplebs.com/", - supportLink: "https://nostrplebs.com/manage", - about: , -}; - -export const Nip5Services = [SnortNostrAddressService]; +const Nip5Services = [SnortNostrAddressService]; export default function NostrAddressPage() { return ( diff --git a/packages/app/src/Pages/Profile/ProfilePage.tsx b/packages/app/src/Pages/Profile/ProfilePage.tsx index 6f514c6f..3f42aa2b 100644 --- a/packages/app/src/Pages/Profile/ProfilePage.tsx +++ b/packages/app/src/Pages/Profile/ProfilePage.tsx @@ -45,14 +45,9 @@ import useHorizontalScroll from "@/Hooks/useHorizontalScroll"; import { useMuteList, usePinList } from "@/Hooks/useLists"; import useLogin from "@/Hooks/useLogin"; import useModeration from "@/Hooks/useModeration"; -import ProfileTab, { - BookMarksTab, - FollowersTab, - FollowsTab, - ProfileTabType, - RelaysTab, - ZapsProfileTab, -} from "@/Pages/Profile/ProfileTab"; +import ProfileTab from "@/Pages/Profile/ProfileTab"; +import { BookMarksTab, FollowersTab, FollowsTab, RelaysTab, ZapsProfileTab } from "@/Pages/Profile/ProfileTabs"; +import { ProfileTabType } from "@/Pages/Profile/ProfileTabType"; import { findTag, hexToBech32, parseId, unwrap } from "@/Utils"; import { EmailRegex } from "@/Utils/Const"; import { ZapTarget } from "@/Utils/Zapper"; diff --git a/packages/app/src/Pages/Profile/ProfileTab.tsx b/packages/app/src/Pages/Profile/ProfileTab.tsx index 4bb1884a..91425675 100644 --- a/packages/app/src/Pages/Profile/ProfileTab.tsx +++ b/packages/app/src/Pages/Profile/ProfileTab.tsx @@ -1,67 +1,8 @@ -import { HexKey, NostrLink, NostrPrefix } from "@snort/system"; import { FormattedMessage } from "react-intl"; -import { default as ZapElement } from "@/Components/Event/Zap"; import Icon from "@/Components/Icons/Icon"; -import RelaysMetadata from "@/Components/Relay/RelaysMetadata"; import { Tab } from "@/Components/Tabs/Tabs"; -import Bookmarks from "@/Components/User/Bookmarks"; -import FollowsList from "@/Components/User/FollowListBase"; -import useFollowersFeed from "@/Feed/FollowersFeed"; -import useFollowsFeed from "@/Feed/FollowsFeed"; -import useRelaysFeed from "@/Feed/RelaysFeed"; -import useZapsFeed from "@/Feed/ZapsFeed"; -import { useBookmarkList } from "@/Hooks/useLists"; -import { formatShort } from "@/Utils/Number"; - -import messages from "../messages"; - -export enum ProfileTabType { - NOTES = 0, - REACTIONS = 1, - FOLLOWERS = 2, - FOLLOWS = 3, - ZAPS = 4, - MUTED = 5, - BLOCKED = 6, - RELAYS = 7, - BOOKMARKS = 8, -} - -export function ZapsProfileTab({ id }: { id: HexKey }) { - const zaps = useZapsFeed(new NostrLink(NostrPrefix.PublicKey, id)); - const zapsTotal = zaps.reduce((acc, z) => acc + z.amount, 0); - return ( - <> -

- -

- {zaps.map(z => ( - - ))} - - ); -} - -export function FollowersTab({ id }: { id: HexKey }) { - const followers = useFollowersFeed(id); - return ; -} - -export function FollowsTab({ id }: { id: HexKey }) { - const follows = useFollowsFeed(id); - return ; -} - -export function RelaysTab({ id }: { id: HexKey }) { - const relays = useRelaysFeed(id); - return ; -} - -export function BookMarksTab({ id }: { id: HexKey }) { - const bookmarks = useBookmarkList(id); - return ; -} +import { ProfileTabType } from "@/Pages/Profile/ProfileTabType"; const ProfileTab = { Notes: { diff --git a/packages/app/src/Pages/Profile/ProfileTabType.tsx b/packages/app/src/Pages/Profile/ProfileTabType.tsx new file mode 100644 index 00000000..08b1340a --- /dev/null +++ b/packages/app/src/Pages/Profile/ProfileTabType.tsx @@ -0,0 +1,11 @@ +export enum ProfileTabType { + NOTES = 0, + REACTIONS = 1, + FOLLOWERS = 2, + FOLLOWS = 3, + ZAPS = 4, + MUTED = 5, + BLOCKED = 6, + RELAYS = 7, + BOOKMARKS = 8, +} diff --git a/packages/app/src/Pages/Profile/ProfileTabs.tsx b/packages/app/src/Pages/Profile/ProfileTabs.tsx new file mode 100644 index 00000000..f14c8b7e --- /dev/null +++ b/packages/app/src/Pages/Profile/ProfileTabs.tsx @@ -0,0 +1,49 @@ +import { HexKey, NostrLink, NostrPrefix } from "@snort/system"; +import { FormattedMessage } from "react-intl"; + +import Zap from "@/Components/Event/Zap"; +import RelaysMetadata from "@/Components/Relay/RelaysMetadata"; +import Bookmarks from "@/Components/User/Bookmarks"; +import FollowsList from "@/Components/User/FollowListBase"; +import useFollowersFeed from "@/Feed/FollowersFeed"; +import useFollowsFeed from "@/Feed/FollowsFeed"; +import useRelaysFeed from "@/Feed/RelaysFeed"; +import useZapsFeed from "@/Feed/ZapsFeed"; +import { useBookmarkList } from "@/Hooks/useLists"; +import messages from "@/Pages/messages"; +import { formatShort } from "@/Utils/Number"; + +export function ZapsProfileTab({ id }: { id: HexKey }) { + const zaps = useZapsFeed(new NostrLink(NostrPrefix.PublicKey, id)); + const zapsTotal = zaps.reduce((acc, z) => acc + z.amount, 0); + return ( + <> +

+ +

+ {zaps.map(z => ( + + ))} + + ); +} + +export function FollowersTab({ id }: { id: HexKey }) { + const followers = useFollowersFeed(id); + return ; +} + +export function FollowsTab({ id }: { id: HexKey }) { + const follows = useFollowsFeed(id); + return ; +} + +export function RelaysTab({ id }: { id: HexKey }) { + const relays = useRelaysFeed(id); + return ; +} + +export function BookMarksTab({ id }: { id: HexKey }) { + const bookmarks = useBookmarkList(id); + return ; +} diff --git a/packages/app/src/Pages/onboarding/fixedModeration.tsx b/packages/app/src/Pages/onboarding/fixedModeration.tsx new file mode 100644 index 00000000..8ffe23e3 --- /dev/null +++ b/packages/app/src/Pages/onboarding/fixedModeration.tsx @@ -0,0 +1,105 @@ +import { FormattedMessage } from "react-intl"; + +export const FixedModeration = { + /*hateSpeech: { + title: , + words: [], + canEdit: false, + }, + derogatory: { + title: , + words: [], + canEdit: false, + },*/ + nsfw: { + title: , + words: [ + "adult content", + "explicit", + "mature audiences", + "18+", + "sensitive content", + "graphic content", + "age-restricted", + "explicit material", + "adult material", + "nsfw", + "explicit images", + "adult film", + "adult video", + "mature themes", + "sexual content", + "graphic violence", + "strong language", + "explicit language", + "adult-only", + "mature language", + "sex", + ], + canEdit: false, + }, + crypto: { + title: , + words: [ + "bitcoin", + "btc", + "satoshi", + "crypto", + "blockchain", + "mining", + "wallet", + "exchange", + "halving", + "hash rate", + "ledger", + "crypto trading", + "digital currency", + "virtual currency", + "cryptocurrency investment", + "altcoin", + "decentralized finance", + "defi", + "token", + "ico", + "crypto wallet", + "satoshi nakamoto", + ], + canEdit: false, + }, + politics: { + title: , + words: [ + "politics", + "election", + "democrat", + "republican", + "senate", + "congress", + "parliament", + "president", + "prime minister", + "policy", + "legislation", + "vote", + "campaign", + "government", + "political party", + "lobbying", + "referendum", + "bill", + "conservative", + "liberal", + "left-wing", + "right-wing", + "socialist", + "capitalist", + "diplomacy", + "sanction", + "geopolitics", + "activism", + "protest", + "rally", + ], + canEdit: false, + }, +}; diff --git a/packages/app/src/Pages/onboarding/fixedTopics.tsx b/packages/app/src/Pages/onboarding/fixedTopics.tsx new file mode 100644 index 00000000..301885ce --- /dev/null +++ b/packages/app/src/Pages/onboarding/fixedTopics.tsx @@ -0,0 +1,249 @@ +import { FormattedMessage } from "react-intl"; + +export const FixedTopics = { + life: { + text: , + tags: [ + "life", + "lifestyle", + "dailyinspiration", + "motivation", + "lifelessons", + "personaldevelopment", + "happiness", + "wellbeing", + "mindfulness", + "selfcare", + "positivity", + "growth", + "inspiration", + "lifegoals", + "mindset", + "joy", + "balance", + "fulfillment", + "purpose", + "living", + "lifetips", + "lifehacks", + "wellness", + "lifejourney", + "enjoylife", + "simplepleasures", + "gratitude", + "lifeadvice", + "lifecoaching", + "lifelove", + ], + }, + science: { + text: , + tags: [ + "science", + "research", + "innovation", + "technology", + "biology", + "physics", + "chemistry", + "astronomy", + "environment", + "ecology", + "geology", + "neuroscience", + "genetics", + "data", + "experiment", + "theory", + "discovery", + "engineering", + "mathematics", + "robotics", + "artificialintelligence", + "climate", + "space", + "quantum", + "microbiology", + "biotechnology", + "nanotechnology", + "pharmacology", + "astrophysics", + "scientificmethod", + ], + }, + nature: { + text: , + tags: [ + "nature", + "wildlife", + "forest", + "mountains", + "rivers", + "oceans", + "flora", + "fauna", + "ecosystem", + "biodiversity", + "conservation", + "habitat", + "landscape", + "outdoors", + "environment", + "geography", + "earth", + "climate", + "naturalbeauty", + "wilderness", + "green", + "sustainability", + "wildlifeconservation", + "nationalpark", + "gardening", + "hiking", + "birdwatching", + "ecotourism", + "photography", + "naturelovers", + ], + }, + business: { + text: , + tags: [ + "business", + "entrepreneurship", + "marketing", + "finance", + "innovation", + "management", + "startup", + "leadership", + "economics", + "strategy", + "branding", + "sales", + "technology", + "investment", + "networking", + "growth", + "corporate", + "customer", + "market", + "productivity", + "advertising", + "ecommerce", + "analytics", + "humanresources", + "globalbusiness", + "digitalmarketing", + "socialmedia", + "sustainability", + "entrepreneur", + "businessdevelopment", + ], + }, + game: { + text: , + tags: [ + "gaming", + "videogames", + "esports", + "multiplayer", + "onlinegaming", + "gameplay", + "streaming", + "gamer", + "console", + "pcgaming", + "mobilegaming", + "gamedevelopment", + "virtualreality", + "roleplaying", + "strategygames", + "actiongames", + "simulation", + "indiegames", + "adventuregames", + "puzzle", + "fantasy", + "scifi", + "horror", + "sports", + "racing", + "fighting", + "platformer", + "mmorpg", + "retrogaming", + "arcade", + ], + }, + sport: { + text: , + tags: [ + "sports", + "athletics", + "soccer", + "basketball", + "baseball", + "football", + "tennis", + "golf", + "swimming", + "running", + "cycling", + "volleyball", + "hockey", + "skiing", + "boxing", + "martialarts", + "gymnastics", + "cricket", + "rugby", + "tabletennis", + "badminton", + "fishing", + "archery", + "bowling", + "surfing", + "skateboarding", + "motorsports", + "equestrian", + "fitness", + "yoga", + ], + }, + photography: { + text: , + tags: [ + "photography", + "landscape", + "portrait", + "naturephotography", + "streetphotography", + "blackandwhite", + "travelphotography", + "macro", + "wildlifephotography", + "urbanphotography", + "nightphotography", + "fashionphotography", + "fineartphotography", + "documentary", + "sportsphotography", + "foodphotography", + "architecturalphotography", + "candid", + "aerialphotography", + "underwaterphotography", + "filmphotography", + "digitalphotography", + "photographytips", + "photoediting", + "photographygear", + "lighting", + "composition", + "exposure", + "photographyworkshop", + "photographyart", + ], + }, +}; diff --git a/packages/app/src/Pages/onboarding/moderation.tsx b/packages/app/src/Pages/onboarding/moderation.tsx index d5470404..7a9d6a4d 100644 --- a/packages/app/src/Pages/onboarding/moderation.tsx +++ b/packages/app/src/Pages/onboarding/moderation.tsx @@ -6,113 +6,10 @@ import { useNavigate } from "react-router-dom"; import AsyncButton from "@/Components/Button/AsyncButton"; import { ToggleSwitch } from "@/Components/Icons/Toggle"; import useLogin from "@/Hooks/useLogin"; +import { FixedModeration } from "@/Pages/onboarding/fixedModeration"; import { appendDedupe } from "@/Utils"; import { updateAppData } from "@/Utils/Login"; -export const FixedModeration = { - /*hateSpeech: { - title: , - words: [], - canEdit: false, - }, - derogatory: { - title: , - words: [], - canEdit: false, - },*/ - nsfw: { - title: , - words: [ - "adult content", - "explicit", - "mature audiences", - "18+", - "sensitive content", - "graphic content", - "age-restricted", - "explicit material", - "adult material", - "nsfw", - "explicit images", - "adult film", - "adult video", - "mature themes", - "sexual content", - "graphic violence", - "strong language", - "explicit language", - "adult-only", - "mature language", - "sex", - ], - canEdit: false, - }, - crypto: { - title: , - words: [ - "bitcoin", - "btc", - "satoshi", - "crypto", - "blockchain", - "mining", - "wallet", - "exchange", - "halving", - "hash rate", - "ledger", - "crypto trading", - "digital currency", - "virtual currency", - "cryptocurrency investment", - "altcoin", - "decentralized finance", - "defi", - "token", - "ico", - "crypto wallet", - "satoshi nakamoto", - ], - canEdit: false, - }, - politics: { - title: , - words: [ - "politics", - "election", - "democrat", - "republican", - "senate", - "congress", - "parliament", - "president", - "prime minister", - "policy", - "legislation", - "vote", - "campaign", - "government", - "political party", - "lobbying", - "referendum", - "bill", - "conservative", - "liberal", - "left-wing", - "right-wing", - "socialist", - "capitalist", - "diplomacy", - "sanction", - "geopolitics", - "activism", - "protest", - "rally", - ], - canEdit: false, - }, -}; - export function Moderation() { const id = useLogin(s => s.id); const [topics, setTopics] = useState>(Object.keys(FixedModeration)); diff --git a/packages/app/src/Pages/onboarding/topics.tsx b/packages/app/src/Pages/onboarding/topics.tsx index 16e2f215..44f5ca3f 100644 --- a/packages/app/src/Pages/onboarding/topics.tsx +++ b/packages/app/src/Pages/onboarding/topics.tsx @@ -6,256 +6,9 @@ import { useNavigate } from "react-router-dom"; import AsyncButton from "@/Components/Button/AsyncButton"; import useEventPublisher from "@/Hooks/useEventPublisher"; +import { FixedTopics } from "@/Pages/onboarding/fixedTopics"; import { appendDedupe } from "@/Utils"; -export const FixedTopics = { - life: { - text: , - tags: [ - "life", - "lifestyle", - "dailyinspiration", - "motivation", - "lifelessons", - "personaldevelopment", - "happiness", - "wellbeing", - "mindfulness", - "selfcare", - "positivity", - "growth", - "inspiration", - "lifegoals", - "mindset", - "joy", - "balance", - "fulfillment", - "purpose", - "living", - "lifetips", - "lifehacks", - "wellness", - "lifejourney", - "enjoylife", - "simplepleasures", - "gratitude", - "lifeadvice", - "lifecoaching", - "lifelove", - ], - }, - science: { - text: , - tags: [ - "science", - "research", - "innovation", - "technology", - "biology", - "physics", - "chemistry", - "astronomy", - "environment", - "ecology", - "geology", - "neuroscience", - "genetics", - "data", - "experiment", - "theory", - "discovery", - "engineering", - "mathematics", - "robotics", - "artificialintelligence", - "climate", - "space", - "quantum", - "microbiology", - "biotechnology", - "nanotechnology", - "pharmacology", - "astrophysics", - "scientificmethod", - ], - }, - nature: { - text: , - tags: [ - "nature", - "wildlife", - "forest", - "mountains", - "rivers", - "oceans", - "flora", - "fauna", - "ecosystem", - "biodiversity", - "conservation", - "habitat", - "landscape", - "outdoors", - "environment", - "geography", - "earth", - "climate", - "naturalbeauty", - "wilderness", - "green", - "sustainability", - "wildlifeconservation", - "nationalpark", - "gardening", - "hiking", - "birdwatching", - "ecotourism", - "photography", - "naturelovers", - ], - }, - business: { - text: , - tags: [ - "business", - "entrepreneurship", - "marketing", - "finance", - "innovation", - "management", - "startup", - "leadership", - "economics", - "strategy", - "branding", - "sales", - "technology", - "investment", - "networking", - "growth", - "corporate", - "customer", - "market", - "productivity", - "advertising", - "ecommerce", - "analytics", - "humanresources", - "globalbusiness", - "digitalmarketing", - "socialmedia", - "sustainability", - "entrepreneur", - "businessdevelopment", - ], - }, - game: { - text: , - tags: [ - "gaming", - "videogames", - "esports", - "multiplayer", - "onlinegaming", - "gameplay", - "streaming", - "gamer", - "console", - "pcgaming", - "mobilegaming", - "gamedevelopment", - "virtualreality", - "roleplaying", - "strategygames", - "actiongames", - "simulation", - "indiegames", - "adventuregames", - "puzzle", - "fantasy", - "scifi", - "horror", - "sports", - "racing", - "fighting", - "platformer", - "mmorpg", - "retrogaming", - "arcade", - ], - }, - sport: { - text: , - tags: [ - "sports", - "athletics", - "soccer", - "basketball", - "baseball", - "football", - "tennis", - "golf", - "swimming", - "running", - "cycling", - "volleyball", - "hockey", - "skiing", - "boxing", - "martialarts", - "gymnastics", - "cricket", - "rugby", - "tabletennis", - "badminton", - "fishing", - "archery", - "bowling", - "surfing", - "skateboarding", - "motorsports", - "equestrian", - "fitness", - "yoga", - ], - }, - photography: { - text: , - tags: [ - "photography", - "landscape", - "portrait", - "naturephotography", - "streetphotography", - "blackandwhite", - "travelphotography", - "macro", - "wildlifephotography", - "urbanphotography", - "nightphotography", - "fashionphotography", - "fineartphotography", - "documentary", - "sportsphotography", - "foodphotography", - "architecturalphotography", - "candid", - "aerialphotography", - "underwaterphotography", - "filmphotography", - "digitalphotography", - "photographytips", - "photoediting", - "photographygear", - "lighting", - "composition", - "exposure", - "photographyworkshop", - "photographyart", - ], - }, -}; - export function Topics() { const { publisher, system } = useEventPublisher(); const [topics, setTopics] = useState>([]); diff --git a/packages/app/src/Pages/settings/SnortNostrAddressService.tsx b/packages/app/src/Pages/settings/SnortNostrAddressService.tsx new file mode 100644 index 00000000..6b53db11 --- /dev/null +++ b/packages/app/src/Pages/settings/SnortNostrAddressService.tsx @@ -0,0 +1,12 @@ +import { FormattedMessage } from "react-intl"; + +import messages from "@/Pages/messages"; +import { ApiHost } from "@/Utils/Const"; + +export const SnortNostrAddressService = { + name: "Snort", + service: `${ApiHost}/api/v1/n5sp`, + link: "https://snort.social/", + supportLink: "https://snort.social/help", + about: , +}; diff --git a/packages/app/src/Pages/subscribe/SubscriptionCard.tsx b/packages/app/src/Pages/subscribe/SubscriptionCard.tsx index ed03fc50..53dd7da2 100644 --- a/packages/app/src/Pages/subscribe/SubscriptionCard.tsx +++ b/packages/app/src/Pages/subscribe/SubscriptionCard.tsx @@ -4,7 +4,7 @@ import Icon from "@/Components/Icons/Icon"; import Nip5Service from "@/Components/Nip5Service"; import Nip05 from "@/Components/User/Nip05"; import { Subscription } from "@/External/SnortApi"; -import { SnortNostrAddressService } from "@/Pages/NostrAddressPage"; +import { SnortNostrAddressService } from "@/Pages/settings/SnortNostrAddressService"; import { mapPlanName } from "@/Pages/subscribe/utils"; import { RenewSub } from "./RenewSub"; diff --git a/packages/app/src/index.css b/packages/app/src/index.css index b6b6542b..cf6a17b7 100644 --- a/packages/app/src/index.css +++ b/packages/app/src/index.css @@ -923,7 +923,11 @@ svg.repeat { } .pb-safe-area { - padding-bottom: calc(20vh + env(safe-area-inset-bottom)); + padding-bottom: env(safe-area-inset-bottom); +} + +.pb-safe-area-plus { + padding-bottom: calc(10vh + env(safe-area-inset-bottom)); } .active > .icon-outline {