Skip to content

Conversation

@Abhijay007
Copy link
Collaborator

@Abhijay007 Abhijay007 commented Nov 23, 2025

closes: #5848

PR Description

This PR aims to adds a copy button to error toasts, allowing users to easily copy the error message before using “Ask Goose.”

Changes Made

  • ui/desktop/src/toasts.tsx – Added copy button with tooltip
  • ui/desktop/src/App.tsx – Increased toast container width from 380px → 450px to so that content fits nicely, and also the cross button doesn't overlap
  • ui/desktop/src/styles/main.css – Adjusted close button alignment a bit

Type of Change

  • Feature

Testing

Tested in the desktop UI by triggering an error and copying it.

Screenshots / Demos (for UX changes)

Before:

beforeToast

After:

afterToast

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a copy button to error toasts, making it easier for users to copy error messages before using the "Ask Goose" recovery feature. The implementation intelligently adapts the UI based on what actions are available: when both copy and recovery options are present, it uses a compact icon button for copying; when only copying is available, it uses a text button.

Key Changes

  • Added copy functionality to error toasts with async clipboard API
  • Implemented conditional UI rendering: icon button when both actions available, text button otherwise
  • Increased toast width from 380px to 450px to accommodate multiple buttons without overlap

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
ui/desktop/src/toasts.tsx Added copy handler with clipboard API, conditional button rendering (icon vs text), and tooltip for icon button
ui/desktop/src/App.tsx Increased ToastContainer width to 450px to prevent button overlap
ui/desktop/src/styles/main.css Adjusted close button alignment to center and updated margins for better spacing

Copy link
Collaborator

@michaelneale michaelneale left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good - but haven't had a chance to try it by hand.

@michaelneale
Copy link
Collaborator

(hopefully that node error will be resolved on main or by github soon)

@angiejones
Copy link
Collaborator

thank you @Abhijay007!

@angiejones angiejones merged commit 9a22ffe into block:main Nov 24, 2025
16 checks passed
michaelneale added a commit that referenced this pull request Nov 25, 2025
* main:
  docs: add DataHub MCP server extension documentation (#5769)
  docs: lowercase goose in remaining topics (#5861)
  docs: lowercase goose in getting-started and guides topics (#5857)
  Fix multi tool calling (#5855)
  fix(#5626 #5832): handle multiple content chunks & images better (#5839)
  chore: some old code hanging around, and mention configure cli (#5822)
  feat : add support for math / science symbology via katex (#5773)
  feat : add ability to see error message in toast (#5851)
kskarthik pushed a commit to kskarthik/goose that referenced this pull request Nov 25, 2025
kskarthik pushed a commit to kskarthik/goose that referenced this pull request Nov 26, 2025
BlairAllan pushed a commit to BlairAllan/goose that referenced this pull request Nov 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add ability to see error message in toast

3 participants