-
-
Notifications
You must be signed in to change notification settings - Fork 32
fix(profiles): Fix treemap and sunburst display issues #1203
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
Conversation
- Update FRAME_COLOR constants with vibrant, high-contrast colors - Update CSS theme variables for frame colors - Add custom nanovis palette for Spotlight's dark theme - Add overlay to fix sunburst center showing bytes instead of samples - Fix tooltip to show sample counts properly
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Outdated
Show resolved
Hide resolved
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
6804a76 to
dbe49fc
Compare
dbe49fc to
a29d5cb
Compare
a29d5cb to
ba414b6
Compare
ba414b6 to
a9f647d
Compare
a9f647d to
87a68ca
Compare
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
87a68ca to
779f122
Compare
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
8031eec to
8b895ea
Compare
8b895ea to
a12fbdf
Compare
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Outdated
Show resolved
Hide resolved
a12fbdf to
3a9b844
Compare
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
...es/spotlight/src/ui/telemetry/components/traces/TraceDetails/components/TraceProfileTree.tsx
Show resolved
Hide resolved
3a9b844 to
fe7f4c5
Compare
fe7f4c5 to
0663bd6
Compare
…ions The nanovis library calls resize() in its constructor before the element is appended to the DOM, resulting in 0 dimensions. Using ResizeObserver ensures we call resize() only after the container has been laid out with proper dimensions. This fixes the treemap being invisible on initial render.
0663bd6 to
153fb21
Compare
betegon
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this looks good. i think we could benefit from moving some visualization code from TraceProfileTree.tsx if we add more visualization things, but we're good!
| palette: { | ||
| text: "#e0e7ff", // primary-100 for better visibility | ||
| fg: "#fff", | ||
| bg: "#1e1b4b", // primary-950 | ||
| stroke: "#4338ca", // primary-700 | ||
| fallback: "#9ca3af", // Gray-400 fallback | ||
| hover: "#ffffff33", // Semi-transparent white for hover | ||
| shadow: "#00000066", // Semi-transparent black for shadows |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wonder if we should reuse these color fo other charts
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @spotlightjs/[email protected] ### Minor Changes - Add support for continuous profiling (Profiling V2) ([#1202](#1202)) - Add self-documenting CLI commands with per-command help support ([#1206](#1206)) Each CLI command now provides its own metadata (short description, usage, detailed help, and examples). The main help output is generated dynamically from this metadata, and users can get detailed help for specific commands via `spotlight help <command>` or `spotlight <command> --help`. ### Patch Changes - Remove dead code ([#1214](#1214)) - Fix profile visualization issues in trace views: ([#1203](#1203)) - Update frame colors to use vibrant, high-contrast colors for better visibility - Add custom nanovis palette for Spotlight's dark theme - Fix sunburst center text showing bytes instead of sample counts - Fix treemap visibility with proper color contrast - added support for AI SDK v2 in AI Mode ([#1216](#1216)) - updated the empty pages of traces and envelopes ([#1213](#1213)) - open external links in default browser ([#1212](#1212)) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary
Fix two issues with the Profiles tab under trace views:
Sunburst chart showing byte sizes (e.g., '42kb'): The nanovis library interprets the
sizefield as bytes. Added an overlay to cover the center text and display proper sample counts instead.Treemap and sunburst colors appearing white/invisible: rendering issue
Changes