diff --git a/src/App.tsx b/src/App.tsx index 2859e9b..5c22556 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -38,8 +38,8 @@ export default function App() { const table = s.rpmTable.length ? s.rpmTable.map((v) => v * 10) : NOMINAL_TABLE; const pairing = s.needsPairing && (connected || connecting); - const onDash = location.pathname.startsWith('/dashboard'); - const onGuide = !onDash; + const onGuide = location.pathname.startsWith('/guide'); + const onDash = !onGuide; const guideProps: GuideProps = { dark, @@ -47,7 +47,7 @@ export default function App() { table, onSend: (level) => { void client.setSpeedLevel(level); - navigate('/dashboard'); + navigate('/'); }, }; @@ -67,7 +67,7 @@ export default function App() {
- @@ -149,7 +149,7 @@ export default function App() { } /> } /> } /> - } /> - } /> + {/* The dashboard lived at /dashboard until v1.1.1 — keep old bookmarks working. */} + } /> + } /> diff --git a/src/Dashboard.tsx b/src/Dashboard.tsx index 5313f01..c911cbe 100644 --- a/src/Dashboard.tsx +++ b/src/Dashboard.tsx @@ -2,6 +2,7 @@ import { useEffect, useState } from 'react'; import type { ToolState } from './protocol/client'; import { NOMINAL_TABLE } from './guide'; import { Icon } from './Icons'; +import { useDocumentMeta } from './meta'; // Tachometer geometry — 270° open-bottom dial. const A0 = 135; @@ -37,6 +38,11 @@ export default function Dashboard({ onConnect, onSetSpeed, }: DashboardProps) { + // Same as index.html, so coming back from a guide page restores the app's own title + canonical. + useDocumentMeta( + 'COLLET — Dremel 8260 Bluetooth companion & accessory speed guide', + 'Live speed, battery and temperature from your Dremel 8260, speed control, and an accessory & material speed guide. In Chrome over Web Bluetooth — no account, no cloud.', + ); // Real per-level RPM (tool reports ÷10), else the nominal dial. const table = state.rpmTable.length ? state.rpmTable.map((v) => v * 10) : NOMINAL_TABLE; const levels = state.countOfSpeedLevels || table.length;