[APP-1750] Add the ability to report livestreams (#9654)

* Add report dialog to LiveStatus dialog

* Mr Worldwide™

* Bug fix bug fix

* Copy update

* Simplify parsing

* Bump api sdk

* update dev-env

* Update yarn.lock

* Bump api sdk

* Refactor useActorStatus, add disablement and appeal dialog

* Fix types

* Guard against chat profile views

* Go live (disabled)

* Fix types

* Status reports should only go to bsky

* Ah yeah let's not override types

---------

Co-authored-by: Samuel Newman <mozzius@protonmail.com>
This commit is contained in:
Eric Bailey
2026-01-09 10:19:47 -06:00
committed by GitHub
parent 85a616eee0
commit edb19dd6cf
16 changed files with 325 additions and 55 deletions
+7
View File
@@ -3,6 +3,7 @@ import {createContext, useContext, useMemo, useState} from 'react'
import {type AgeAssuranceRedirectDialogState} from '#/components/ageAssurance/AgeAssuranceRedirectDialog'
import * as Dialog from '#/components/Dialog'
import {type Screen} from '#/components/dialogs/EmailDialog/types'
import {type ReportSubject} from '#/components/moderation/ReportDialog'
type Control = Dialog.DialogControlProps
@@ -24,6 +25,7 @@ type ControlsContext = {
share?: boolean
}>
ageAssuranceRedirectDialogControl: StatefulControl<AgeAssuranceRedirectDialogState>
reportDialogControl: StatefulControl<{subject: ReportSubject}>
}
const ControlsContext = createContext<ControlsContext | null>(null)
@@ -51,6 +53,9 @@ export function Provider({children}: React.PropsWithChildren<{}>) {
}>()
const ageAssuranceRedirectDialogControl =
useStatefulDialogControl<AgeAssuranceRedirectDialogState>()
const reportDialogControl = useStatefulDialogControl<{
subject: ReportSubject
}>()
const ctx = useMemo<ControlsContext>(
() => ({
@@ -60,6 +65,7 @@ export function Provider({children}: React.PropsWithChildren<{}>) {
emailDialogControl,
linkWarningDialogControl,
ageAssuranceRedirectDialogControl,
reportDialogControl,
}),
[
mutedWordsDialogControl,
@@ -68,6 +74,7 @@ export function Provider({children}: React.PropsWithChildren<{}>) {
emailDialogControl,
linkWarningDialogControl,
ageAssuranceRedirectDialogControl,
reportDialogControl,
],
)