Skip to content

Commit

Permalink
chore: mf-5169 change persona link (#10646)
Browse files Browse the repository at this point in the history
* chore: add event tracking for luck send

* chore: mf-5169 change persona link
  • Loading branch information
beyond009 committed Aug 28, 2023
1 parent 326c3af commit 5367206
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 11 deletions.
2 changes: 2 additions & 0 deletions packages/mask/src/components/CompositionDialog/useSubmit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ export function useSubmit(onClose: () => void, reason: 'timeline' | 'popup' | 'r
const decoratedText = decorateEncryptedText(encrypted, t, content.meta)
pasteTextEncode(decoratedText ?? t('additional_post_box__encrypted_post_pre', { encrypted }), reason)
}
if (content.meta?.has(`${PluginID.RedPacket}:1`) || content.meta?.has(`${PluginID.RedPacket}_nft:1`))
Telemetry.captureEvent(EventType.Interact, EventID.EntryAppLuckSend)
Telemetry.captureEvent(EventType.Interact, EventID.EntryMaskComposeEncrypt)
onClose()
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { formatPersonaFingerprint } from '@masknet/shared-base'
import { makeStyles } from '@masknet/theme'
import { Link, Typography } from '@mui/material'
import { memo } from 'react'
import urlcat from 'urlcat'

const useStyles = makeStyles<{ iconSize: number }>()((theme, { iconSize }) => ({
text: {
Expand Down Expand Up @@ -47,7 +46,7 @@ export const PersonaPublicKey = memo<PersonaPublicKeyProps>(function PersonaPubl
underline="none"
target="_blank"
rel="noopener noreferrer"
href={urlcat('https://web3.bio/', { s: publicHexString })}
href={`https://web3.bio/${publicHexString}`}
className={classes.icon}>
<Icons.LinkOut size={iconSize} />
</Link>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import Services from '../../../../service.js'
import { useEverSeen } from '@masknet/shared-base-ui'
import { useFriendProfiles } from '../../../hook/useFriendProfiles.js'
import { useMutation, useQueryClient, type InfiniteData } from '@tanstack/react-query'
import urlcat from 'urlcat'
import { type Friend } from '../../../hook/useFriends.js'

const useStyles = makeStyles()((theme) => ({
Expand Down Expand Up @@ -200,7 +199,7 @@ export const ContactCard = memo<ContactCardProps>(function ContactCard({
underline="none"
target="_blank"
rel="noopener noreferrer"
href={urlcat('https://web3.bio/', { s: nextId })}
href={`https://web3.bio/${nextId}`}
className={classes.icon}>
<Icons.LinkOut size={12} />
</Link>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import { useTheme } from '@mui/system'
import { CopyButton, EmptyStatus } from '@masknet/shared'
import { ConnectedAccounts } from './ConnectAccounts/index.js'
import { useI18N } from '../../../../../utils/i18n-next-ui.js'
import urlcat from 'urlcat'

const useStyles = makeStyles()((theme) => ({
container: {
Expand Down Expand Up @@ -136,7 +135,7 @@ export const FriendsDetailUI = memo<FriendsDetailUIProps>(function FriendsDetail
underline="none"
target="_blank"
rel="noopener noreferrer"
href={urlcat('https://web3.bio/', { s: nextId })}
href={`https://web3.bio/${nextId}`}
className={classes.icon}>
<Icons.LinkOut size={12} />
</Link>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { makeStyles } from '@masknet/theme'
import { Avatar, Box, Link, Typography } from '@mui/material'
import { Icons } from '@masknet/icons'
import { formatPersonaFingerprint, formatPersonaName } from '@masknet/shared-base'
import urlcat from 'urlcat'
// import { CopyIconButton } from '../../../../components/CopyIconButton/index.js'

const useStyles = makeStyles()((theme) => ({
Expand Down Expand Up @@ -81,7 +80,7 @@ export const PersonaHeaderUI = memo<PersonaHeaderUIProps>(({ avatar, fingerprint
underline="none"
target="_blank"
rel="noopener noreferrer"
href={urlcat('https://web3.bio/', { s: publicHexString })}
href={`https://web3.bio/${publicHexString}`}
className={classes.icon}>
<Icons.LinkOut size={12} />
</Link>
Expand Down
3 changes: 0 additions & 3 deletions packages/web3-telemetry/src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@ export enum ExceptionType {
export enum EventID {
EntryAppLuckOpen = 'entry_app_luck_open',
EntryAppLuckCreate = 'entry_app_luck_create',

// todo
EntryAppLuckSend = 'entry_app_luck_send',

EntryAppNFT_PFP_Open = 'entry_app_nft_pfp_open',
EntryAppNFT_PFP_Setting = 'entry_app_nft_pfp_setting',
EntryAppSwapOpen = 'entry_app_swap_open',
Expand Down

0 comments on commit 5367206

Please sign in to comment.