diff --git a/web/src/components/settings/Step1NameCamera.tsx b/web/src/components/settings/Step1NameCamera.tsx index 01f3b70ad..ceaaaf406 100644 --- a/web/src/components/settings/Step1NameCamera.tsx +++ b/web/src/components/settings/Step1NameCamera.tsx @@ -510,61 +510,29 @@ export default function Step1NameCamera({
- {testResult.snapshot && ( -
+ {testResult.snapshot ? ( +
Camera snapshot +
+
+ +
+
+ ) : ( + + + {t("cameraWizard.step1.streamDetails")} + + + + + )} - - - - {t("cameraWizard.step1.streamDetails")} - - - {testResult.resolution && ( -
- - {t("cameraWizard.testResultLabels.resolution")}: - {" "} - - {testResult.resolution} - -
- )} - {testResult.videoCodec && ( -
- - {t("cameraWizard.testResultLabels.video")}: - {" "} - - {testResult.videoCodec} - -
- )} - {testResult.audioCodec && ( -
- - {t("cameraWizard.testResultLabels.audio")}: - {" "} - - {testResult.audioCodec} - -
- )} - {testResult.fps && ( -
- - {t("cameraWizard.testResultLabels.fps")}: - {" "} - {testResult.fps} -
- )} -
-
)} @@ -604,3 +572,44 @@ export default function Step1NameCamera({ ); } + +function StreamDetails({ testResult }: { testResult: TestResult }) { + const { t } = useTranslation(["views/settings"]); + + return ( + <> + {testResult.resolution && ( +
+ + {t("cameraWizard.testResultLabels.resolution")}: + {" "} + {testResult.resolution} +
+ )} + {testResult.fps && ( +
+ + {t("cameraWizard.testResultLabels.fps")}: + {" "} + {testResult.fps} +
+ )} + {testResult.videoCodec && ( +
+ + {t("cameraWizard.testResultLabels.video")}: + {" "} + {testResult.videoCodec} +
+ )} + {testResult.audioCodec && ( +
+ + {t("cameraWizard.testResultLabels.audio")}: + {" "} + {testResult.audioCodec} +
+ )} + + ); +}