GeezerVison is showing github.com — fix(web): audio and server spinners respect reduced motion (#33795) · Pipyakas/t3code@8a984ec
File treeExpand file treeCollapse file tree Open diff view settings Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: apps/web/src/components/chat/ThreadServersPanel.tsx +3-8Lines changed: 3 additions & 8 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -10,13 +10,7 @@ import { | 10 | 10 | isAtomCommandInterrupted, | 11 | 11 | squashAtomCommandFailure, | 12 | 12 | } from "@t3tools/client-runtime/state/runtime"; | 13 | | -import { | 14 | | - GlobeIcon, | 15 | | - LoaderCircleIcon, | 16 | | - SquareIcon, | 17 | | - ChevronDownIcon, | 18 | | - ChevronUpIcon, | 19 | | -} from "lucide-react"; | | 13 | +import { GlobeIcon, SquareIcon, ChevronDownIcon, ChevronUpIcon } from "lucide-react"; | 20 | 14 | import { type MouseEvent, useState } from "react"; | 21 | 15 |
| 22 | 16 | import { resolveDiscoveredServerUrl } from "../../browser/browserTargetResolver"; | @@ -28,6 +22,7 @@ import { previewEnvironment } from "../../state/preview"; | 28 | 22 | import { useEnvironmentScope } from "../../state/session"; | 29 | 23 | import { useAtomCommand } from "../../state/use-atom-command"; | 30 | 24 | import { openDiscoveredPort } from "../preview/openDiscoveredPort"; | | 25 | +import { Spinner } from "../ui/spinner"; | 31 | 26 | import { stackedThreadToast, toastManager } from "../ui/toast"; | 32 | 27 | import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip"; | 33 | 28 | import { ThreadDetailsControl } from "./ThreadDetailsControl"; | @@ -170,7 +165,7 @@ function ThreadServersList(props: ThreadServersPanelProps) { | 170 | 165 | } | 171 | 166 | > | 172 | 167 | {stoppingKey === key ? ( | 173 | | - <LoaderCircleIcon aria-hidden className="size-3 animate-spin" /> | | 168 | + <Spinner aria-hidden size="xs" /> | 174 | 169 | ) : ( | 175 | 170 | <SquareIcon aria-hidden className="size-3 fill-current" /> | 176 | 171 | )} | |
Collapse file Copy file name to clipboardExpand all lines: apps/web/src/components/files/AudioPreview.tsx +2-1Lines changed: 2 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -4,6 +4,7 @@ import { createContext, useContext, useRef, useState } from "react"; | 4 | 4 | import { useStableCallback } from "~/hooks/useStableCallback"; | 5 | 5 | import { ContextChip, ContextChipAction, ContextChipLabel } from "../ContextChip"; | 6 | 6 | import { middleTruncateAttachmentName } from "../composerInlineChip"; | | 7 | +import { Spinner } from "../ui/spinner"; | 7 | 8 |
| 8 | 9 | export const AudioPreviewUnmountContext = createContext<((audio: HTMLAudioElement) => void) | null>( | 9 | 10 | null, | @@ -140,7 +141,7 @@ function AudioChip(props: AudioPreviewProps) { | 140 | 141 | }); | 141 | 142 | }} | 142 | 143 | > | 143 | | - <Icon aria-hidden className={loading && props.src ? "animate-spin" : undefined} /> | | 144 | + {loading && props.src ? <Spinner aria-hidden /> : <Icon aria-hidden />} | 144 | 145 | </ContextChipAction> | 145 | 146 | <ContextChipLabel className={props.variant === "bubble" ? "flex-1" : "max-w-72"}> | 146 | 147 | {open ? ( | |
|