-
-
-
+ {/* No tooltip — the numbers describe themselves and the popover
+ speaks on click (owner, subtlety round 2026-09-25). */}
+
{open && (
) {
return (
@@ -19,9 +32,16 @@ function TooltipProvider({
}
function Tooltip({
+ disableHoverableContent = true,
...props
}: React.ComponentProps) {
- return
+ return (
+
+ )
}
function TooltipTrigger({
@@ -32,7 +52,7 @@ function TooltipTrigger({
function TooltipContent({
className,
- sideOffset = 0,
+ sideOffset = 6,
children,
...props
}: React.ComponentProps) {
@@ -42,16 +62,15 @@ function TooltipContent({
data-slot="tooltip-content"
sideOffset={sideOffset}
className={cn(
- "z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-foreground px-3 py-1.5 text-xs text-balance text-background fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
+ "z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-accent px-2 py-1 text-[11px] text-foreground/85 text-balance fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
className
)}
{...props}
>
{children}
-
)
}
-export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider }
+export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider }
\ No newline at end of file
diff --git a/tests/tooltip-mechanism.test.tsx b/tests/tooltip-mechanism.test.tsx
index 0339384..0e838b0 100644
--- a/tests/tooltip-mechanism.test.tsx
+++ b/tests/tooltip-mechanism.test.tsx
@@ -17,18 +17,19 @@ import { describe, it } from "node:test";
import { createElement } from "react";
import { renderToStaticMarkup } from "react-dom/server";
import { Hint, hintText } from "../components/ui/hint.tsx";
+import { TOOLTIP_DELAY_MS } from "../components/ui/tooltip.tsx";
import { AUTO_UPDATE_HINT } from "../components/settings/settings-dialog.tsx";
-describe("hintText — the em-dash composition", () => {
+describe("hintText — the parenthesized composition", () => {
it("a registry action appends the LIVE binding (override-aware source)", () => {
- assert.equal(hintText("Dictate", "toggle-dictation"), "Dictate — ⌘D");
- assert.equal(hintText("Settings", "open-settings"), "Settings — ⌘,");
- assert.equal(hintText("Search sessions", "sessions-search"), "Search sessions — ⌘⇧F");
+ assert.equal(hintText("Dictate", "toggle-dictation"), "Dictate (⌘D)");
+ assert.equal(hintText("Settings", "open-settings"), "Settings (⌘,)");
+ assert.equal(hintText("Search sessions", "sessions-search"), "Search sessions (⌘⇧F)");
});
it("surface-owned keys ride the binding prop (no registry entry)", () => {
- assert.equal(hintText("Close", undefined, "escape"), "Close — Esc");
- assert.equal(hintText("Send", undefined, "enter"), "Send — ↵");
+ assert.equal(hintText("Close", undefined, "escape"), "Close (Esc)");
+ assert.equal(hintText("Send", undefined, "enter"), "Send (↵)");
});
it("no shortcut = the label alone, no dangling dash", () => {
@@ -37,6 +38,12 @@ describe("hintText — the em-dash composition", () => {
});
});
+describe("subtlety round pins (owner 2026-09-25)", () => {
+ it("the rest delay is 500ms — tooltips appear on pause, never in passing", () => {
+ assert.equal(TOOLTIP_DELAY_MS, 500);
+ });
+});
+
describe("spot-pins: the dev-speak cull (owner copy review at merge)", () => {
it("the auto-update hint is honest user language — no stream jargon", () => {
assert.equal(AUTO_UPDATE_HINT, "Automatic updates arrive in an upcoming release");