GeezerVison is showing github.com — fix(web): banner titles truncate and stay announced · pingdotgg/t3code@365011e
File tree
Expand file treeCollapse file tree
Open diff view settings
apps/web/src/components/chat
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: apps/web/src/components/chat/BackgroundWorkBanner.tsx +5-3Lines changed: 5 additions & 3 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -268,7 +268,6 @@ function Rows({ |
268 | 268 | ) : ( |
269 | 269 | <button |
270 | 270 | type="button" |
271 | | - aria-label={`Open subagent ${row.label}`} |
272 | 271 | className={cn( |
273 | 272 | rowClassName, |
274 | 273 | "cursor-pointer hover:bg-accent focus-visible:outline-2 focus-visible:-outline-offset-2 focus-visible:outline-ring", |
@@ -311,7 +310,7 @@ export function BackgroundWorkBanner(props: { |
311 | 310 | <HeaderIcon rows={presentation.rows} /> |
312 | 311 | </ComposerBanner.Icon> |
313 | 312 | <ComposerBanner.Content className="whitespace-nowrap"> |
314 | | - <span className="min-w-0 shrink-0 truncate font-medium leading-7 sm:leading-6"> |
| 313 | + <span className="min-w-0 truncate font-medium leading-7 sm:leading-6"> |
315 | 314 | {single?.kind === "command" ? ( |
316 | 315 | <> |
317 | 316 | {presentation.waiting ? "Waiting on " : "Running "} |
@@ -321,7 +320,7 @@ export function BackgroundWorkBanner(props: { |
321 | 320 | presentation.title |
322 | 321 | )} |
323 | 322 | </span> |
324 | | - {description && !expanded ? ( |
| 323 | + {description && (single || !expanded) ? ( |
325 | 324 | <span className={cn("w-0 min-w-0 grow truncate @max-[400px]:sr-only", mutedText)}> |
326 | 325 | {description} |
327 | 326 | </span> |
@@ -343,6 +342,9 @@ export function BackgroundWorkBanner(props: { |
343 | 342 | ); |
344 | 343 | return ( |
345 | 344 | <div data-background-work-banner="true"> |
| 345 | + <span role="status" className="sr-only"> |
| 346 | + {presentation.title} |
| 347 | + </span> |
346 | 348 | <div className="flex items-center"> |
347 | 349 | {single ? ( |
348 | 350 | <ComposerBanner.Row className="flex-1">{header}</ComposerBanner.Row> |
|