Fix some text wrong

Co-authored-by: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com>
This commit is contained in:
GuoQing Liu 2024-12-27 11:56:32 +08:00 committed by GitHub
parent 576a5c419e
commit 1c3e3304d2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 44 additions and 41 deletions

View File

@ -262,7 +262,6 @@ export default function MotionMaskEditPane({
<Trans> <Trans>
ui.settingView.masksAndZonesSettings.motionMasks.clickDrawPolygon ui.settingView.masksAndZonesSettings.motionMasks.clickDrawPolygon
</Trans> </Trans>
Click to draw a polygon on the image.
</div> </div>
<Separator className="my-3 bg-secondary" /> <Separator className="my-3 bg-secondary" />

View File

@ -476,50 +476,54 @@ export default function CameraSettingsView({
<div className="text-sm"> <div className="text-sm">
{watchedDetectionsZones && {watchedDetectionsZones &&
watchedDetectionsZones.length > 0 watchedDetectionsZones.length > 0
? !selectDetections ? !selectDetections ? (
? t( <Trans
"ui.settingView.cameraSettings.reviewClassification.zoneObjectDetectionsTips", i18nKey="ui.settingView.cameraSettings.reviewClassification.zoneObjectDetectionsTips"
{ values={{
detectionsLabels,
zone: watchedDetectionsZones
.map((zone) =>
capitalizeFirstLetter(zone).replaceAll(
"_",
" ",
),
)
.join(", "),
cameraName: capitalizeFirstLetter(
cameraConfig?.name ?? "",
).replaceAll("_", " "),
},
)
: t(
"ui.settingView.cameraSettings.reviewClassification.zoneObjectDetectionsTips.notSelectDetections",
{
detectionsLabels,
zone: watchedDetectionsZones
.map((zone) =>
capitalizeFirstLetter(zone).replaceAll(
"_",
" ",
),
)
.join(", "),
cameraName: capitalizeFirstLetter(
cameraConfig?.name ?? "",
).replaceAll("_", " "),
},
)
: t(
"ui.settingView.cameraSettings.reviewClassification.objectDetectionsTips",
{
detectionsLabels, detectionsLabels,
zone: watchedDetectionsZones
.map((zone) =>
capitalizeFirstLetter(zone).replaceAll(
"_",
" ",
),
)
.join(", "),
cameraName: capitalizeFirstLetter( cameraName: capitalizeFirstLetter(
cameraConfig?.name ?? "", cameraConfig?.name ?? "",
).replaceAll("_", " "), ).replaceAll("_", " "),
}, }}
)} ></Trans>
) : (
<Trans
i18nKey="ui.settingView.cameraSettings.reviewClassification.zoneObjectDetectionsTips.notSelectDetections"
values={{
detectionsLabels,
zone: watchedDetectionsZones
.map((zone) =>
capitalizeFirstLetter(zone).replaceAll(
"_",
" ",
),
)
.join(", "),
cameraName: capitalizeFirstLetter(
cameraConfig?.name ?? "",
).replaceAll("_", " "),
}}
/>
)
) : (
<Trans
i18nKey="ui.settingView.cameraSettings.reviewClassification.objectDetectionsTips"
values={{
detectionsLabels,
cameraName: capitalizeFirstLetter(
cameraConfig?.name ?? "",
).replaceAll("_", " "),
}}
/>
)}
</div> </div>
</FormItem> </FormItem>
)} )}