diff --git a/README.md b/README.md index 0613cb5..3d33ead 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,8 @@ running statistics, and export the result to CSV — no backend, no installation **** -Open it in a Chromium-based browser, connect your meter, and click **Connect**. +Open it in a supported browser (Chrome, Edge, Opera, or Firefox 151+), connect +your meter, and click **Connect**. Everything runs locally in your browser — no data leaves your machine. ### Install & offline @@ -56,8 +57,10 @@ update. ## Requirements - A **ZOYI ZT703s** multimeter connected over USB serial (see device note above). -- A **Chromium-based browser** (Chrome, Edge, Opera). The Web Serial API is not - available in Firefox or Safari. +- A browser with the **Web Serial API**: any **Chromium-based browser** (Chrome, + Edge, Opera) or **Firefox 151+** on desktop ([added May 2026](https://hacks.mozilla.org/2026/05/web-serial-support-in-firefox/)). + Safari is not supported. On Firefox Enterprise builds, Web Serial is disabled by default + and must be enabled via the `DefaultSerialGuardSetting` policy. - A served origin of **`https://` or `localhost`** — Web Serial requires a secure context. The live demo is served over HTTPS, so it works out of the box. diff --git a/app/page.tsx b/app/page.tsx index 7953843..34746ce 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -468,6 +468,7 @@ export default function Home() { stats={sessionStats} unit={chartUnit} decimals={statDecimals} + canRecord={status === 'connected'} onExportCsv={exportCsv} onToggleRecord={handleToggleRecord} onClear={flushSession} diff --git a/components/DataLog.tsx b/components/DataLog.tsx index eb668ba..bb1e391 100644 --- a/components/DataLog.tsx +++ b/components/DataLog.tsx @@ -1,7 +1,7 @@ 'use client'; import { memo, useMemo, useState } from 'react'; -import { Search, Download, Pause, Play, Trash2 } from 'lucide-react'; +import { Search, Download, Square, Play, Trash2 } from 'lucide-react'; import { clsx } from 'clsx'; import { MODE_LABELS, type Reading } from '@/lib/parser'; import { StatisticsPanel, type SessionStats } from '@/components/StatisticsPanel'; @@ -27,6 +27,7 @@ export function DataLog({ stats, unit, decimals, + canRecord, onExportCsv, onToggleRecord, onClear, @@ -38,6 +39,7 @@ export function DataLog({ stats: SessionStats | null; unit: string; decimals?: number; + canRecord: boolean; onExportCsv: () => void; onToggleRecord: () => void; onClear: () => void; @@ -179,9 +181,10 @@ export function DataLog({
: } - label={recording ? 'Pause Logging' : 'Resume Logging'} - variant={recording ? 'active' : 'default'} + icon={recording ? : } + label={recording ? 'Stop Logging' : 'Start Logging'} + variant={recording ? 'danger' : 'success'} + disabled={!recording && !canRecord} />