Open source video conferencing app powered by LiveKit. Built with Django and React.
♿️(frontend) set explicit document title on recording download page
Cyrilf0fda145d9b2
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 5f3bfd15..e2efddd1 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -23,6 +23,7 @@ and this project adheres to- 🥅(backend) refine Twirp error handling for participant operations- ✨(summary) allow more file extensions #1265- ♿️(frontend) refocus reactions toolbar with ctrl+shift+e is activated #1262+- ♿️(frontend) set an explicit document title on recording download page #1261### Fixeddiff --git a/src/frontend/src/features/recording/routes/RecordingDownload.tsx b/src/frontend/src/features/recording/routes/RecordingDownload.tsxindex 3974158e..e6f872b9 100644--- a/src/frontend/src/features/recording/routes/RecordingDownload.tsx+++ b/src/frontend/src/features/recording/routes/RecordingDownload.tsx@@ -3,6 +3,8 @@ import { useQuery } from '@tanstack/react-query'import { Center, VStack } from '@/styled-system/jsx'import { css } from '@/styled-system/css'import { useTranslation } from 'react-i18next'+import { useTitle } from 'hoofd'+import { useMemo } from 'react'import { mediaUrl } from '@/api/mediaUrl'import { UserAware, useUser } from '@/features/auth'import { Screen } from '@/layout/Screen'@@ -14,6 +16,8 @@ import { fetchRecording } from '../api/fetchRecording'import { RecordingStatus } from '@/features/recording'import { useConfig } from '@/api/useConfig'+const APP_TITLE = import.meta.env.VITE_APP_TITLE ?? ''+const BetaBadge = () => (<spanclassName={css({@@ -49,6 +53,21 @@ export const RecordingDownload = () => {enabled: !!recordingId,})+ const isSaved =+ data?.status === RecordingStatus.Saved ||+ data?.status === RecordingStatus.NotificationSucceed ||+ data?.status === RecordingStatus.FailedToStop++ const pageTitle = useMemo(() => {+ if (isError) return `${APP_TITLE} - ${t('error.title')}`+ if (data && !isSaved) return `${APP_TITLE} - ${t('unsaved.title')}`+ if (data?.is_expired) return `${APP_TITLE} - ${t('expired.title')}`+ if (data && isSaved) return `${APP_TITLE} - ${t('success.title')}`+ return APP_TITLE+ }, [isError, data, isSaved, t])++ useTitle(pageTitle)+if (isLoggedIn === undefined || isAuthLoading) {return <LoadingScreen />}