Skip to content

Commit

Permalink
🟣 Release 5.2.3
Browse files Browse the repository at this point in the history
Merge pull request #6327 from ikprk/release/5.2.3
  • Loading branch information
ikprk authored May 24, 2024
2 parents 66fcc81 + b3979e7 commit 4f1e4d6
Show file tree
Hide file tree
Showing 10 changed files with 172 additions and 60 deletions.
12 changes: 11 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [5.2.3] - 2024-05-24

### Added

- Earnings to the rewards landing page

### Fixed

- Hidden shorts from channel videos
- Rewards dashboard copy change and links update

## [5.2.2] - 2024-05-21

### Added
Expand All @@ -17,7 +28,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Meta server fix
- CRT UI/UX fixes


## [5.2.1] - 2024-05-06

### Added
Expand Down
4 changes: 2 additions & 2 deletions packages/atlas/atlas.config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ features:
googleConsoleClientId: '$VITE_GOOGLE_CONSOLE_CLIENT_ID'
youtubeSyncApiUrl: '$VITE_YOUTUBE_SYNC_API_URL'
suspensionReasonsLink: https://joystream.notion.site/My-channel-is-suspended-what-to-do-86a3df16c55c434ab2184d61dfcfc41b # Link with explanation what might be the reason of ypp channel suspension
suspendedSupportLink: https://discord.com/channels/811216481340751934/1053294778529353788 # Link that will be displayed for users suspended in YPP
suspendedSupportLink: https://discord.gg/joystream # Link that will be displayed for users suspended in YPP
suspendedLinkText: '#ypp-support channel on our Discord server'
youtubeCollaboratorMemberId: '$VITE_YOUTUBE_COLLABORATOR_MEMBER_ID'
enrollmentReward: 5000 # Amount for successful enrollment in YPP in joystream.tokenTicker units.
Expand Down Expand Up @@ -127,7 +127,7 @@ features:
label: Studio
icon: tokenStack
- title: Community
link: https://discord.com/channels/811216481340751934/1224709788592767136
link: https://discord.gg/joystream
linkText: Go to Discord
label: Discord
icon: message
Expand Down
2 changes: 1 addition & 1 deletion packages/atlas/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@joystream/atlas",
"description": "UI for consuming Joystream - a user governed video platform",
"version": "5.2.2",
"version": "5.2.3",
"license": "GPL-3.0",
"scripts": {
"start": "vite",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

61 changes: 61 additions & 0 deletions packages/atlas/src/api/queries/__generated__/nfts.generated.tsx

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions packages/atlas/src/api/queries/nfts.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,11 @@ mutation RequestNftFeatured($nftId: String!, $rationale: String!) {
createdAt
}
}

query GetJoystreamTotalEarnings {
totalJoystreamEarnings {
crtSaleVolume
totalRewardsPaid
nftSaleVolume
}
}
2 changes: 1 addition & 1 deletion packages/atlas/src/api/schemas/orion.json

Large diffs are not rendered by default.

113 changes: 71 additions & 42 deletions packages/atlas/src/views/global/YppLandingView/sections/YppHero.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
import BN from 'bn.js'
import { FC } from 'react'
import { CSSTransition, SwitchTransition } from 'react-transition-group'
import useResizeObserver from 'use-resize-observer'

import { useMostPaidChannels } from '@/api/hooks/channel'
import { useGetJoystreamTotalEarningsQuery } from '@/api/queries/__generated__/nfts.generated'
import { SvgActionChevronR, SvgActionNewTab } from '@/assets/icons'
import crt_card from '@/assets/images/ypp-hero/crt-card-hero.webp'
import crt_dashboard from '@/assets/images/ypp-hero/crt-dashboard-hero.webp'
import payments from '@/assets/images/ypp-hero/crt-payments-hero.webp'
import { AppLogo } from '@/components/AppLogo'
import { FlexBox } from '@/components/FlexBox'
import { GlassDetailsWidget } from '@/components/GlassDetailsWidget'
import { GridItem, LayoutGrid } from '@/components/LayoutGrid'
import { NumberFormat } from '@/components/NumberFormat'
import { Text } from '@/components/Text'
import { Button, TextButton } from '@/components/_buttons/Button'
import { PaidChannelCard } from '@/components/_channel/ChannelCard'
Expand All @@ -31,6 +35,7 @@ import {
LogosContainer,
RightImage,
StyledInfiniteCarousel,
WidgetsContainer,
} from './YppHero.styles'

import {
Expand All @@ -55,16 +60,19 @@ export const YppHero: FC<YppHeroProps> = ({ onSignUpClick, yppAtlasStatus, onVie
const xsMatch = useMediaMatch('xs')
const xxsMatch = useMediaMatch('xxs')
const smMatch = useMediaMatch('sm')
const mdMatch = useMediaMatch('md')
const { ref, width, height } = useResizeObserver({ box: 'border-box' })
const [, subtitleVariant, titleVariant] = useSectionTextVariants()
const setIsYppChannelFlow = useYppStore((state) => state.actions.setIsYppChannelFlow)
const setAuthModalOpenName = useAuthStore((state) => state.actions.setAuthModalOpenName)
const { memberChannels, isLoggedIn } = useUser()
const { trackRewardsCreateChannelButtonClick } = useSegmentAnalytics()
const { channels, loading } = useMostPaidChannels()
const { data, loading: loadingEarnings } = useGetJoystreamTotalEarningsQuery()
const items = !loading
? channels?.map((channel) => <PaidChannelCard key={channel.id} channel={channel} />)
: Array.from({ length: 30 }).map((_, idx) => <PaidChannelCard key={idx} loading />)
const widgetContentTextVariant = mdMatch ? ('h700' as const) : ('h600' as const)

return (
<HeroBackgroundContainer noBackground>
Expand Down Expand Up @@ -194,51 +202,72 @@ export const YppHero: FC<YppHeroProps> = ({ onSignUpClick, yppAtlasStatus, onVie
</>
)}
{yppAtlasStatus !== 'ypp-signed' && 'It takes under 1 minute and is 100% free.'}
</Text> */}
</Text> */}
</GridItem>
</LayoutGrid>

{/*<LayoutGrid data-aos="fade-up" data-aos-delay="450" data-aos-offset="40" data-aos-easing="atlas-easing">*/}
{/* <GridItem margin={{ top: 6 }} colStart={{ base: 1, lg: 2 }} colSpan={{ base: 12, lg: 10 }}>*/}
{/* <WidgetsContainer>*/}
{/* <Text margin={{ bottom: 6 }} variant="h500" as="h5">*/}
{/* Creator Earnings*/}
{/* </Text>*/}
{/* </WidgetsContainer>*/}
{/* <WidgetsContainer justifyContent="space-between" gap={4} width="100%">*/}
{/* <GlassDetailsWidget*/}
{/* title="Total Rewards Paid"*/}
{/* titleVariant="h300"*/}
{/* tooltip={{ text: 'xd' }}*/}
{/* customNode={*/}
{/* <Text variant={widgetContentTextVariant} as="h2">*/}
{/* 204M*/}
{/* </Text>*/}
{/* }*/}
{/* />*/}
{/* <GlassDetailsWidget*/}
{/* title="NFTs sold"*/}
{/* titleVariant="h300"*/}
{/* tooltip={{ text: 'xd' }}*/}
{/* customNode={*/}
{/* <Text variant={widgetContentTextVariant} as="h2">*/}
{/* 204M*/}
{/* </Text>*/}
{/* }*/}
{/* />*/}
{/* <GlassDetailsWidget*/}
{/* title="Creator Tokens Sold"*/}
{/* titleVariant="h300"*/}
{/* tooltip={{ text: 'xd' }}*/}
{/* customNode={*/}
{/* <Text variant={widgetContentTextVariant} as="h2">*/}
{/* 204M*/}
{/* </Text>*/}
{/* }*/}
{/* />*/}
{/* </WidgetsContainer>*/}
{/* </GridItem>*/}
{/*</LayoutGrid>*/}
<LayoutGrid data-aos="fade-up" data-aos-delay="450" data-aos-offset="40" data-aos-easing="atlas-easing">
<GridItem margin={{ top: 6 }} colStart={{ base: 1, lg: 2 }} colSpan={{ base: 12, lg: 10 }}>
<WidgetsContainer>
<Text margin={{ bottom: 6 }} variant="h500" as="h5">
Creator Earnings
</Text>
</WidgetsContainer>
<WidgetsContainer justifyContent="space-between" gap={4} width="100%">
<GlassDetailsWidget
title="Total Rewards Paid"
titleVariant="h300"
customNode={
loadingEarnings ? (
<SkeletonLoader width={120} height={60} />
) : (
<NumberFormat
as="h2"
format="short"
withDenomination
variant={widgetContentTextVariant}
value={new BN(data?.totalJoystreamEarnings.totalRewardsPaid ?? 0)}
/>
)
}
/>
<GlassDetailsWidget
title="NFTs Sold"
titleVariant="h300"
customNode={
loadingEarnings ? (
<SkeletonLoader width={120} height={60} />
) : (
<NumberFormat
as="h2"
format="short"
withDenomination
variant={widgetContentTextVariant}
value={new BN(data?.totalJoystreamEarnings.nftSaleVolume ?? 0)}
/>
)
}
/>
<GlassDetailsWidget
title="Creator Tokens Sold"
titleVariant="h300"
customNode={
loadingEarnings ? (
<SkeletonLoader width={120} height={60} />
) : (
<NumberFormat
as="h2"
format="short"
withDenomination
variant={widgetContentTextVariant}
value={new BN(data?.totalJoystreamEarnings.crtSaleVolume ?? 0)}
/>
)
}
/>
</WidgetsContainer>
</GridItem>
</LayoutGrid>

<ImagesContainer width="100%" justifyContent="center">
<FrontImage src={crt_dashboard} alt="Hero back" width="1152" height="824" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,12 @@ const benefitsMetadata = {
title: 'Discord Community',
description: (
<>
Introduce yourself to the{' '}
<TextButton to="https://discord.com/channels/811216481340751934/1231910540243238932">intros</TextButton> channel
Introduce yourself to the <TextButton to={atlasConfig.general.joystreamDiscordUrl}>#intros</TextButton> channel
and share the link to your {atlasConfig.general.appName} channel page. Five best intros per weeks are rewarded!
</>
),
reward: '10 USD',
actionLink: 'https://discord.com/channels/811216481340751934/1224709788592767136',
actionLink: atlasConfig.general.joystreamDiscordUrl,
tooltipLink: 'https://www.notion.so/joystream/Creators-Discord-bc8df1d87b58435a9ea325b073bea4d6?pvs=4',
},
twitterPost: {
Expand All @@ -64,7 +63,7 @@ const benefitsMetadata = {
title: 'Roundtable events',
description: `Participate in Creator Roundtable events held on Discord to exchange perspectives on current ${atlasConfig.general.appName} opportunities and features in the pipeline. Best questions are rewarded.`,
reward: '25 USD',
actionLink: 'https://discord.com/channels/811216481340751934/1231911228398637077',
actionLink: atlasConfig.general.joystreamDiscordUrl,
tooltipLink: 'https://www.notion.so/joystream/Roundtable-Events-cd106924a7314f75acf8813277fc21a8?pvs=4',
},
originalCreatorsContent: {
Expand Down Expand Up @@ -98,7 +97,7 @@ const benefitsMetadata = {
actionLink: 'https://joystream.notion.site/Ambassador-Program-Space-93dfd2767d6b4729ac7dab79f9970d5b',
tooltipLink: 'https://joystream.notion.site/Ambassador-Program-Space-93dfd2767d6b4729ac7dab79f9970d5b',
},
discordLink: 'https://discord.com/channels/811216481340751934/1053294778529353788',
discordLink: atlasConfig.general.joystreamDiscordUrl,
}

export const YppDashboardMainTab: FC = () => {
Expand Down Expand Up @@ -493,10 +492,8 @@ export const YppDashboardMainTab: FC = () => {
description={
<>
Drop the link of your post to{' '}
<TextButton as="span" to="https://discord.com/channels/811216481340751934/1224714104552558682">
shared NFTs channel
</TextButton>{' '}
on Discord to participate in rewards.
<TextButton to={atlasConfig.general.joystreamDiscordUrl}>#shared-NFTs</TextButton> on Discord to
participate in rewards.
</>
}
rewardTooltip={
Expand All @@ -522,10 +519,8 @@ export const YppDashboardMainTab: FC = () => {
description={
<>
Drop the link of your post to{' '}
<TextButton as="span" to="https://discord.com/channels/811216481340751934/1233002048979603487">
shared Tokens channel{' '}
</TextButton>{' '}
on Discord to participate in rewards.
<TextButton to={atlasConfig.general.joystreamDiscordUrl}>#shared-CRTs</TextButton> on Discord to
participate in rewards.
</>
}
rewardTooltip={
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export const ChannelVideos: FC<ChannelVideosProps> = ({
isPublic_eq: true,
createdAt_lt: USER_TIMESTAMP,
isCensored_eq: false,
isShort_eq: false,
thumbnailPhoto: {
isAccepted_eq: true,
},
Expand Down

0 comments on commit 4f1e4d6

Please sign in to comment.