Skip to content

[UI] Highlight the selected trace and spans better in the UI [1/n]#337

Merged
XinweiHe merged 1 commit intomainfrom
xinwei_selected_span_color_change_v1
Nov 21, 2025
Merged

[UI] Highlight the selected trace and spans better in the UI [1/n]#337
XinweiHe merged 1 commit intomainfrom
xinwei_selected_span_color_change_v1

Conversation

@XinweiHe
Copy link
Collaborator

@XinweiHe XinweiHe commented Nov 21, 2025

Summary

as titled.
resolves https://github.com/traceroot-ai/traceroot-internal/issues/295

Type of Change

  • feat - A new feature
  • fix - A bug fix
  • docs - Documentation only changes
  • style - Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)
  • refactor - A code change that neither fixes a bug nor adds a feature
  • perf - A code change that improves performance
  • test - Adding missing tests or correcting existing tests
  • build - Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
  • ci - Changes to our Cl configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs)
  • chore - Other changes that don't modify sc or test files
  • revert - Reverts a previous commit
  • security - A security fix or improvement
  • github - Changes to our GitHub configuration files and scripts
  • other (please describe):

Details

as titled.

Screenshots / Recordings (if applicable)

Screenshot 2025-11-20 at 10 42 31 PM

Checklist

  • I have read the CONTRIBUTING.md
  • I have added/updated tests where applicable
  • I have added screenshots or recordings for UI changes (if applicable)
  • I have updated documentation where necessary

@XinweiHe XinweiHe requested a review from a team as a code owner November 21, 2025 06:43
@greptile-apps
Copy link

greptile-apps bot commented Nov 21, 2025

Greptile Overview

Greptile Summary

Enhanced the visual highlighting of selected traces and spans in the UI by updating the background color from bg-zinc-100 to bg-zinc-200 (and dark mode equivalents) and adding a 4px left border with a distinctive color (border-l-zinc-400).

  • Improved visual contrast makes selected items more distinguishable from unselected items
  • Consistent styling applied across both trace and span components
  • Changes are purely cosmetic with no impact on functionality or logic

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • The changes are purely cosmetic, involving only CSS class modifications to improve UI visibility. No logic changes, no new functionality, and no potential for runtime errors.
  • No files require special attention

Important Files Changed

File Analysis

Filename Score Overview
ui/src/components/explore/Trace.tsx 5/5 Enhanced visual highlighting for selected traces with darker background (bg-zinc-200) and 4px left border indicator
ui/src/components/explore/span/Span.tsx 5/5 Applied consistent visual highlighting to selected spans matching trace styling

Sequence Diagram

sequenceDiagram
    participant User
    participant Trace
    participant Span
    participant DOM

    User->>Trace: Click on trace item
    Trace->>Trace: handleTraceClick(traceId)
    Trace->>Trace: Update selectedTraceIds
    Trace->>DOM: Apply new styling classes
    Note over DOM: bg-zinc-200 dark:bg-zinc-800<br/>border-l-4 border-l-zinc-400
    Trace->>Span: Expand trace and render spans
    
    User->>Span: Click on span item
    Span->>Span: handleSpanClick()
    Span->>Trace: onSpanSelect(spanId, childSpanIds)
    Span->>DOM: Apply new styling classes
    Note over DOM: bg-zinc-200 dark:bg-zinc-800<br/>border-l-4 border-l-zinc-400
Loading

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

2 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

Base automatically changed from xinwei_self_host_recover_v2 to main November 21, 2025 06:48
@XinweiHe XinweiHe merged commit 1d44b63 into main Nov 21, 2025
1 check passed
@XinweiHe XinweiHe deleted the xinwei_selected_span_color_change_v1 branch November 21, 2025 06:48
XinweiHe added a commit that referenced this pull request Jan 23, 2026
…change_v1

[UI] Highlight the selected trace and spans better in the UI [1/n]
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.

1 participant