diff options
author | Hailey <me@haileyok.com> | 2025-03-06 12:20:48 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-06 14:20:48 -0600 |
commit | 618c4e4a56987a1520ee9ca871b2d8e20b13fded (patch) | |
tree | d78d5ee52b15e65e99eb410df7e9a792936b3907 /src/view | |
parent | 153fc17676cf9301e0f066e3c280da83821a6a63 (diff) | |
download | voidsky-618c4e4a56987a1520ee9ca871b2d8e20b13fded.tar.zst |
add some metrics for labelers (#7747)
* add some metrics * add label pref switch metric * Update src/screens/Profile/Header/ProfileHeaderLabeler.tsx * Use new logger.metric * Fix conflicting types * Remove duplicate toasts * Move metric to try body * Move metric to try body --------- Co-authored-by: Eric Bailey <git@esb.lol>
Diffstat (limited to 'src/view')
-rw-r--r-- | src/view/screens/ProfileList.tsx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/view/screens/ProfileList.tsx b/src/view/screens/ProfileList.tsx index 66a6478fa..acd603126 100644 --- a/src/view/screens/ProfileList.tsx +++ b/src/view/screens/ProfileList.tsx @@ -393,6 +393,11 @@ function Header({ try { await listMuteMutation.mutateAsync({uri: list.uri, mute: true}) Toast.show(_(msg({message: 'List muted', context: 'toast'}))) + logger.metric( + 'moderation:subscribedToList', + {listType: 'mute'}, + {statsig: true}, + ) } catch { Toast.show( _( @@ -406,6 +411,11 @@ function Header({ try { await listMuteMutation.mutateAsync({uri: list.uri, mute: false}) Toast.show(_(msg({message: 'List unmuted', context: 'toast'}))) + logger.metric( + 'moderation:unsubscribedFromList', + {listType: 'mute'}, + {statsig: true}, + ) } catch { Toast.show( _( @@ -419,6 +429,11 @@ function Header({ try { await listBlockMutation.mutateAsync({uri: list.uri, block: true}) Toast.show(_(msg({message: 'List blocked', context: 'toast'}))) + logger.metric( + 'moderation:subscribedToList', + {listType: 'block'}, + {statsig: true}, + ) } catch { Toast.show( _( @@ -432,6 +447,11 @@ function Header({ try { await listBlockMutation.mutateAsync({uri: list.uri, block: false}) Toast.show(_(msg({message: 'List unblocked', context: 'toast'}))) + logger.metric( + 'moderation:unsubscribedFromList', + {listType: 'block'}, + {statsig: true}, + ) } catch { Toast.show( _( |