GeezerVison is showing github.com — feat(lint): ban native title tooltips and migrate to styled Tooltip by UtkarshUsername · Pull Request #7209 · pingdotgg/t3code
feat(lint): ban native title tooltips and migrate to styled Tooltip
#7209
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and
privacy statement . We’ll occasionally send you account related emails.
Already on GitHub?
Sign in
to your account
Uh oh!
There was an error while loading. Please reload this page.
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
70cfb95
feat(lint): ban native title attribute tooltips in oxlint
UtkarshUsername Aug 16, 2026
d0b35cb
Merge branch 'main' into feat/oxlint-no-native-title-tooltip
UtkarshUsername Aug 16, 2026
9674722
refactor(web): replace native title tooltips with styled Tooltip and …
UtkarshUsername Aug 16, 2026
9c2f68d
Merge branch 'main' into feat/oxlint-no-native-title-tooltip
UtkarshUsername Aug 16, 2026
95e9914
fix(web): scope migrated tooltips to their own hover surfaces
UtkarshUsername Aug 16, 2026
0f70b17
fix(web): make remaining tooltip replacements readable and accessible
UtkarshUsername Aug 16, 2026
620d91d
fix(web): keep disabled menu items as direct children of MenuRadioGroup
UtkarshUsername Aug 16, 2026
2805cc9
fix(web): migrate remaining pass-through title props on Badge and Men…
UtkarshUsername Aug 16, 2026
462154d
fix(web): restore branch-range indicator order with per-label tooltips
UtkarshUsername Aug 16, 2026
ce2372e
Merge branch 'main' into feat/oxlint-no-native-title-tooltip
UtkarshUsername Aug 16, 2026
4b89f77
fix(web): add tooltip opt-out to PullRequestActorLabel for nested-too…
UtkarshUsername Aug 16, 2026
774d434
fix(web): remove tooltip from resize handle to prevent drag interference
UtkarshUsername Aug 16, 2026
File filter
Filter by extension
.ts
(4)
.tsx
(23)
All 2 file types selected
Viewed files
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Hide whitespace
Diff view
Hide whitespace
There are no files selected for viewing
Original file line number
Diff line number
Diff line change
Expand Up
@@ -12,6 +12,7 @@ import { useState } from "react";
import { Button } from "~/components/ui/button";
import { Input } from "~/components/ui/input";
import { Tooltip, TooltipPopup, TooltipTrigger } from "~/components/ui/tooltip";
import {
Select,
SelectGroup,
Expand Down
Expand Up
@@ -296,26 +297,34 @@ export function BrowserDeviceToolbar({
/>
</form>
<Button
variant="ghost"
size="icon-xs"
type="button"
aria-label={
aspectRatio === null ? "Lock viewport aspect ratio" : "Unlock viewport aspect ratio"
}
aria-pressed={aspectRatio !== null}
title={aspectRatio === null ? "Lock aspect ratio" : "Unlock aspect ratio"}
className={cn(aspectRatio !== null && "bg-accent text-foreground")}
disabled={pending || !customValid}
onPointerDown={(event) => event.preventDefault()}
onClick={toggleAspectRatio}
>
{aspectRatio === null ? (
<Unlink2 className={cn(aspectRatio !== null && "text-foreground")} />
) : (
<Link2 className={cn(aspectRatio !== null && "text-foreground")} />
)}
</Button>
<Tooltip>
<TooltipTrigger
render={
<Button
variant="ghost"
size="icon-xs"
type="button"
aria-label={
aspectRatio === null ? "Lock viewport aspect ratio" : "Unlock viewport aspect ratio"
}
aria-pressed={aspectRatio !== null}
className={cn(aspectRatio !== null && "bg-accent text-foreground")}
disabled={pending || !customValid}
onPointerDown={(event) => event.preventDefault()}
onClick={toggleAspectRatio}
/>
}
>
{aspectRatio === null ? (
<Unlink2 className={cn(aspectRatio !== null && "text-foreground")} />
) : (
<Link2 className={cn(aspectRatio !== null && "text-foreground")} />
)}
</TooltipTrigger>
<TooltipPopup side="top">
{aspectRatio === null ? "Lock aspect ratio" : "Unlock aspect ratio"}
</TooltipPopup>
</Tooltip>
<Button
variant="ghost"
size="icon-xs"
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -6348,7 +6348,6 @@ function ChatViewContent(props: ChatViewProps) {
>
<Button
aria-label="Scroll to end"
title="Scroll to end"
onClick={() => scrollToEnd(true)}
className="pointer-events-auto gap-1.5 rounded-full px-3 text-muted-foreground hover:text-foreground"
size="xs"
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -59,7 +59,6 @@ export function ConnectionStatusDot({
const dot = (
<button
type="button"
title={tooltipText}
aria-label={tooltipText}
className="relative flex size-3 shrink-0 cursor-help items-center justify-center rounded-full outline-hidden"
>
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -583,11 +583,19 @@ export default function DiffPanel({
{selectedTurnId === null && selectedGitScope === "branch" && selectedGitSource?.baseRef && (
<div
className="flex min-w-0 max-w-full items-center gap-2 overflow-hidden text-xs text-muted-foreground"
title={`${selectedGitSource.headRef ?? "HEAD"} → ${selectedGitSource.baseRef}`}
aria-label={`Comparing ${selectedGitSource.headRef ?? "HEAD"} against ${selectedGitSource.baseRef}`}
>
<span className="min-w-0 max-w-48 truncate">{selectedGitSource.headRef ?? "HEAD"}</span>
<ArrowRightIcon className="size-3.5 shrink-0 opacity-70" />
<Tooltip>
<TooltipTrigger render={<span className="flex min-w-0 items-center gap-2" />}>
<span className="min-w-0 max-w-48 truncate">
{selectedGitSource.headRef ?? "HEAD"}
</span>
<ArrowRightIcon className="size-3.5 shrink-0 opacity-70" />
</TooltipTrigger>
<TooltipPopup side="top">
{`${selectedGitSource.headRef ?? "HEAD"} → ${selectedGitSource.baseRef}`}
</TooltipPopup>
</Tooltip>
<Combobox
items={baseRefItems}
filteredItems={filteredBaseRefItems}
Expand Down
Expand Up
@@ -677,12 +685,20 @@ export default function DiffPanel({
/>
</div>
) : choice.remote ? (
<span
className="flex justify-end text-muted-foreground"
title="Remote only"
>
<CheckIcon aria-hidden="true" className="size-3" />
</span>
<Tooltip>
<TooltipTrigger
render={
<span className="flex justify-end text-muted-foreground">
<CheckIcon
role="img"
aria-label="Remote only"
className="size-3"
/>
</span>
}
/>
<TooltipPopup side="top">Remote only</TooltipPopup>
</Tooltip>
) : null}
</div>
</ComboboxItem>
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -11,6 +11,7 @@ import { useAtomCommand } from "~/state/use-atom-command";
import { manualServerUpdateCommand } from "~/versionSkew";
import { Button } from "./ui/button";
import { toastManager } from "./ui/toast";
import { Tooltip, TooltipPopup, TooltipTrigger } from "./ui/tooltip";
// The wire "installing" stage is a sub-second launcher handoff, so the UI
// folds it into the download phase; everything after the handoff is the
Expand Down
Expand Up
@@ -45,9 +46,12 @@ export function ServerUpdateProgress({
return (
<div className="mt-1 flex min-w-0 items-center gap-2 text-xs text-destructive" role="alert">
<span className="size-1.5 shrink-0 rounded-full bg-destructive" aria-hidden="true" />
<span className="min-w-0 truncate" title={state.message}>
{state.message}
</span>
<Tooltip>
<TooltipTrigger render={<span className="min-w-0 truncate">{state.message}</span>} />
<TooltipPopup side="top" className="max-w-80">
{state.message}
</TooltipPopup>
</Tooltip>
</div>
);
}
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -537,15 +537,21 @@ const SidebarDraftRow = memo(function SidebarDraftRow(props: {
{props.projectTitle}
</span>
<span className="ml-auto flex h-5 min-w-5 shrink-0 items-center justify-end">
<button
type="button"
aria-label="Discard draft"
title="Discard draft"
onClick={handleDiscard}
className="pointer-events-none inline-flex cursor-pointer items-center rounded-md bg-transparent px-1 text-muted-foreground opacity-0 transition-opacity hover:text-foreground focus-visible:pointer-events-auto focus-visible:opacity-100 group-hover/sidebar-row:pointer-events-auto group-hover/sidebar-row:opacity-100"
>
<XIcon className="size-3" />
</button>
<Tooltip>
<TooltipTrigger
render={
<button
type="button"
aria-label="Discard draft"
onClick={handleDiscard}
className="pointer-events-none inline-flex cursor-pointer items-center rounded-md bg-transparent px-1 text-muted-foreground opacity-0 transition-opacity hover:text-foreground focus-visible:pointer-events-auto focus-visible:opacity-100 group-hover/sidebar-row:pointer-events-auto group-hover/sidebar-row:opacity-100"
>
<XIcon className="size-3" />
</button>
}
/>
<TooltipPopup side="top">Discard draft</TooltipPopup>
</Tooltip>
</span>
</div>
<div className="mt-0.5 truncate text-sm font-medium text-foreground/90">{preview}</div>
Expand Down
Expand Up
@@ -1247,16 +1253,22 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: {
) : isWoke ? (
// A wake can land straight in the settled tail (e.g. PR
// merged while snoozed); the signal must survive the trip.
<button
type="button"
aria-label="Dismiss Woke notification"
title="Dismiss Woke notification"
onClick={handleAcknowledgeWokeClick}
className="inline-flex cursor-pointer items-center gap-1 rounded-sm text-xs font-medium text-amber-700 outline-none hover:underline focus-visible:ring-2 focus-visible:ring-ring dark:text-amber-300"
>
<AlarmClockIcon aria-hidden className="size-3" />
<span role="status">Woke</span>
</button>
<Tooltip>
<TooltipTrigger
render={
<button
type="button"
aria-label="Dismiss Woke notification"
onClick={handleAcknowledgeWokeClick}
className="inline-flex cursor-pointer items-center gap-1 rounded-sm text-xs font-medium text-amber-700 outline-none hover:underline focus-visible:ring-2 focus-visible:ring-ring dark:text-amber-300"
>
<AlarmClockIcon aria-hidden className="size-3" />
<span role="status">Woke</span>
</button>
}
/>
<TooltipPopup side="top">Dismiss Woke notification</TooltipPopup>
</Tooltip>
) : (
<span className="text-xs">
{variantAction === "unsettle"
Expand Down
Expand Up
@@ -1414,19 +1426,25 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: {
>
{topStatus ? (
isWokeStatus ? (
<button
type="button"
aria-label="Dismiss Woke notification"
title="Dismiss Woke notification"
onClick={handleAcknowledgeWokeClick}
className={cn(
"inline-flex cursor-pointer items-center gap-1 rounded-sm font-medium outline-none hover:underline focus-visible:ring-2 focus-visible:ring-ring",
topStatus.className,
)}
>
<AlarmClockIcon aria-hidden className="size-4 shrink-0" />
<span role="status">{topStatus.label}</span>
</button>
<Tooltip>
<TooltipTrigger
render={
<button
type="button"
aria-label="Dismiss Woke notification"
onClick={handleAcknowledgeWokeClick}
className={cn(
"inline-flex cursor-pointer items-center gap-1 rounded-sm font-medium outline-none hover:underline focus-visible:ring-2 focus-visible:ring-ring",
topStatus.className,
)}
>
<AlarmClockIcon aria-hidden className="size-4 shrink-0" />
<span role="status">{topStatus.label}</span>
</button>
}
/>
<TooltipPopup side="top">Dismiss Woke notification</TooltipPopup>
</Tooltip>
) : (
<span
className={cn(
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -174,21 +174,26 @@ export const ChangedFilesCard = memo(function ChangedFilesCard(props: {
</p>
<div className="mt-2 flex flex-wrap items-center gap-1.5">
{previewFiles.map((file) => (
<button
key={file.path}
type="button"
title={file.path}
className="inline-flex max-w-48 items-center gap-1 rounded-md border border-border/70 bg-background/45 px-1.5 py-1 font-mono text-[10px] text-muted-foreground transition-colors hover:bg-accent/60 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
onClick={() => onOpenTurnDiff(turnId, file.path)}
>
<PierreEntryIcon
pathValue={file.path}
kind="file"
theme={resolvedTheme}
className="size-3 shrink-0 text-muted-foreground/70"
/>
<span className="truncate">{changedFileName(file.path)}</span>
</button>
<Tooltip key={file.path}>
<TooltipTrigger
render={
<button
type="button"
className="inline-flex max-w-48 items-center gap-1 rounded-md border border-border/70 bg-background/45 px-1.5 py-1 font-mono text-[10px] text-muted-foreground transition-colors hover:bg-accent/60 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
onClick={() => onOpenTurnDiff(turnId, file.path)}
/>
}
>
<PierreEntryIcon
pathValue={file.path}
kind="file"
theme={resolvedTheme}
className="size-3 shrink-0 text-muted-foreground/70"
/>
<span className="truncate">{changedFileName(file.path)}</span>
</TooltipTrigger>
<TooltipPopup side="top">{file.path}</TooltipPopup>
</Tooltip>
))}
<button
type="button"
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -37,8 +37,9 @@ describe("ComposerPreviewAnnotationCards", () => {
);
expect(markup).toContain("Make this headline feel intentional.");
expect(markup).toContain('title="1 region"');
expect(markup).toContain('title="1 style change"');
expect(markup.match(/data-slot="tooltip-trigger"/g)).toHaveLength(2);
expect(markup).not.toContain('title="1 region"');
expect(markup).not.toContain('title="1 style change"');
expect(markup).not.toContain("Welcome");
expect(markup).not.toContain("localhost:3000");
expect(markup).not.toContain("Preview annotation");
Expand Down
Original file line number
Diff line number
Diff line change
Expand Up
@@ -6,6 +6,7 @@ import type { ComposerImageAttachment } from "~/composerDraftStore";
import { formatElementContextLabel, normalizeElementContextSelection } from "~/lib/elementContext";
import { cn } from "~/lib/utils";
import { Button } from "../ui/button";
import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
interface ComposerPreviewAnnotationCardsProps {
annotations: ReadonlyArray<PreviewAnnotationPayload>;
Expand All
@@ -16,14 +17,19 @@ interface ComposerPreviewAnnotationCardsProps {
}
function TargetStat(props: { icon: ReactNode; count: number; label: string }) {
const tooltipText = `${props.count} ${props.label}${props.count === 1 ? "" : "s"}`;
return (
<span
className="inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground"
title={`${props.count} ${props.label}${props.count === 1 ? "" : "s"}`}
>
{props.icon}
{props.count}
</span>
<Tooltip>
<TooltipTrigger
render={
<span className="inline-flex items-center gap-1 text-[10px] font-medium text-muted-foreground">
{props.icon}
{props.count}
</span>
}
/>
<TooltipPopup side="top">{tooltipText}</TooltipPopup>
</Tooltip>
);
}
Expand Down
Loading
Oops, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Loading
Oops, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.