diff --git a/local-tool/frontend/src/app/devices/[id]/device-detail-client.tsx b/local-tool/frontend/src/app/devices/[id]/device-detail-client.tsx
index 930486b..8319aeb 100644
--- a/local-tool/frontend/src/app/devices/[id]/device-detail-client.tsx
+++ b/local-tool/frontend/src/app/devices/[id]/device-detail-client.tsx
@@ -7,6 +7,7 @@ import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
import { Button } from '@/components/ui/button';
import { Separator } from '@/components/ui/separator';
import { DeviceStatusBadge } from '@/components/devices/device-status';
+import { FlashDialog } from '@/components/devices/flash-dialog';
import { DeviceHealthCard } from '@/components/devices/device-health-card';
import { DeviceConnectionLog } from '@/components/devices/device-connection-log';
import { DeviceSettingsCard } from '@/components/devices/device-settings-card';
@@ -57,9 +58,12 @@ export default function DeviceDetailClient() {
{isConnected ? (
<>
-
-
-
+
+ {selectedDevice.flashedModel && (
+
+
+
+ )}
diff --git a/local-tool/frontend/src/app/workspace/[deviceId]/workspace-client.tsx b/local-tool/frontend/src/app/workspace/[deviceId]/workspace-client.tsx
index 0d6e662..d911bb9 100644
--- a/local-tool/frontend/src/app/workspace/[deviceId]/workspace-client.tsx
+++ b/local-tool/frontend/src/app/workspace/[deviceId]/workspace-client.tsx
@@ -5,16 +5,15 @@ import Link from 'next/link';
import { Button } from '@/components/ui/button';
import { CameraInferenceView } from '@/components/camera/camera-inference-view';
import { InferencePanel } from '@/components/inference/inference-panel';
+import { FlashDialog } from '@/components/devices/flash-dialog';
import { useDeviceStore } from '@/stores/device-store';
import { useInferenceStore } from '@/stores/inference-store';
import { useInferenceStream } from '@/hooks/use-inference-stream';
import { useCameraStore } from '@/stores/camera-store';
import { useResolvedParams } from '@/hooks/use-resolved-params';
import { api } from '@/lib/api';
-import { useTranslation } from '@/lib/i18n';
export default function WorkspaceClient() {
- const { t } = useTranslation();
const { deviceId } = useResolvedParams();
const { selectedDevice, fetchDevice } = useDeviceStore();
const { isRunning, setRunning, reset } = useInferenceStore();
@@ -60,26 +59,29 @@ export default function WorkspaceClient() {
-
+
- {t('inference.workspace') + ':'} {selectedDevice?.name || deviceId}
+ {'工作區:'} {selectedDevice?.name || deviceId}
- {/* Only show manual inference controls in camera mode */}
- {!isMediaMode && (
-
- {isRunning ? (
-
- ) : (
-
- )}
-
- )}
+
+
+ {/* Only show manual inference controls in camera mode */}
+ {!isMediaMode && (
+ <>
+ {isRunning ? (
+
+ ) : (
+
+ )}
+ >
+ )}
+
diff --git a/local-tool/frontend/src/app/workspace/page.tsx b/local-tool/frontend/src/app/workspace/page.tsx
index 8743385..141b1a2 100644
--- a/local-tool/frontend/src/app/workspace/page.tsx
+++ b/local-tool/frontend/src/app/workspace/page.tsx
@@ -1,15 +1,12 @@
'use client';
-// TODO: M2 redesign workspace landing (device picker, empty state)
import Link from 'next/link';
import { useEffect } from 'react';
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
import { Button } from '@/components/ui/button';
import { useDeviceStore } from '@/stores/device-store';
-import { useTranslation } from '@/lib/i18n';
export default function WorkspaceIndexPage() {
- const { t } = useTranslation();
const { devices, fetchDevices } = useDeviceStore();
useEffect(() => {
@@ -23,21 +20,21 @@ export default function WorkspaceIndexPage() {
return (
-
{t('workspace.title')}
-
{t('workspace.subtitle')}
+
工作區
+
選擇已連線的裝置開始推論
{connected.length === 0 ? (
- {t('workspace.noConnectedDevice')}
+ 沒有已連線的裝置
- {t('workspace.noConnectedDeviceDesc')}
+ 請先前往裝置頁面連接裝置,再回到工作區開始推論。
-
+
@@ -51,6 +48,9 @@ export default function WorkspaceIndexPage() {
{d.type}
+ {d.flashedModel && (
+ {d.flashedModel}
+ )}
diff --git a/local-tool/frontend/src/components/devices/device-card.tsx b/local-tool/frontend/src/components/devices/device-card.tsx
index 4f88bec..5d1607e 100644
--- a/local-tool/frontend/src/components/devices/device-card.tsx
+++ b/local-tool/frontend/src/components/devices/device-card.tsx
@@ -63,6 +63,13 @@ export function DeviceCard({ device, isFirstCard }: DeviceCardProps) {
{t('common.manage')}
+ {device.flashedModel && (
+
+
+
+ )}