Skip to content

Comments

🎨 Palette: Enhance Telemetry Timeline with Rich Tooltip and Accessible Table#25

Draft
igor-holt wants to merge 1 commit intomainfrom
palette-ux-improvement-telemetry-tooltip-10824587432111725168
Draft

🎨 Palette: Enhance Telemetry Timeline with Rich Tooltip and Accessible Table#25
igor-holt wants to merge 1 commit intomainfrom
palette-ux-improvement-telemetry-tooltip-10824587432111725168

Conversation

@igor-holt
Copy link
Owner

Implemented a custom tooltip for the Telemetry Timeline chart to show rich event details (Event, Probability, Outcome, Subjective) and improved table accessibility by adding scope="col" to headers. Verified changes via static analysis as the dev environment is restricted.


PR created automatically by Jules for task 10824587432111725168 started by @igor-holt

This change improves the user experience of the Telemetry Timeline in two ways:
1.  **Rich Tooltip:** Replaces the basic date/probability tooltip with a custom-styled card that displays the Event Name, Probability, Outcome, and Subjective notes. This connects the visualization directly to the narrative data, providing immediate context without needing to cross-reference the table.
2.  **Accessibility:** Adds `scope="col"` to the table headers (`<th>`) to ensure proper association for screen readers.

Modified Files:
- `data/telemetry.ts`: Updated `getProbabilityData` to expose `event`, `outcome`, and `subjective` fields.
- `components/TelemetryTimeline.tsx`: Implemented `CustomTooltip` and updated table markup.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
@google-labs-jules
Copy link

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

Copilot AI review requested due to automatic review settings February 24, 2026 01:10
@gemini-code-assist
Copy link

Summary of Changes

Hello @igor-holt, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly improves the user experience and accessibility of the Telemetry Timeline feature. It introduces a detailed, custom tooltip for the chart, allowing users to quickly grasp more context about individual data points. Concurrently, it enhances the semantic structure of the associated data table, making it more accessible for assistive technologies.

Highlights

  • Enhanced Telemetry Timeline Tooltip: A custom tooltip component has been implemented for the Telemetry Timeline chart, providing rich event details such as Event, Probability, Outcome, and Subjective information upon hover.
  • Improved Table Accessibility: The table within the Telemetry Timeline component has been made more accessible by adding the scope="col" attribute to all table header (<th>) elements.
  • Extended Telemetry Data: The getProbabilityData function now includes additional event details (event, outcome, subjective) in the data it returns, enabling the richer tooltip display.
Changelog
  • components/TelemetryTimeline.tsx
    • Added a new CustomTooltip React component to display detailed event information.
    • Modified the Tooltip component in LineChart to use the newly created CustomTooltip.
    • Updated table header (<th>) elements to include scope="col" for improved accessibility.
  • data/telemetry.ts
    • Extended the getProbabilityData function to include event, outcome, and subjective fields in the returned data objects.
Activity
  • PR created automatically by Jules for task 10824587432111725168, initiated by @igor-holt.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a valuable enhancement to the Telemetry Timeline by adding a custom, detailed tooltip and improves table accessibility by adding scope=\"col\" to headers. The code is well-structured and the changes are effective. I have one suggestion to improve type safety in the new CustomTooltip component by replacing the any type with a more specific type from the recharts library.

ResponsiveContainer,
} from 'recharts';

const CustomTooltip = ({ active, payload, label }: any) => {

Choose a reason for hiding this comment

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

medium

To improve type safety and leverage TypeScript's benefits, avoid using any for component props. You can use TooltipProps from recharts to properly type your custom tooltip component. This makes the component more maintainable and easier to understand.

Suggested change
const CustomTooltip = ({ active, payload, label }: any) => {
const CustomTooltip = ({ active, payload, label }: import('recharts').TooltipProps<number, string>) => {

Copy link

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 enhances the Telemetry Timeline component by implementing a rich custom tooltip that displays detailed event information (Event, Probability, Outcome, and Subjective fields) when hovering over data points on the chart. It also improves table accessibility by adding scope="col" attributes to all table headers, following WCAG guidelines.

Changes:

  • Extended the data structure returned by getProbabilityData() to include event, outcome, and subjective fields
  • Implemented a CustomTooltip component with styled rendering of all event details
  • Added accessibility attributes to table header cells

Reviewed changes

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

File Description
data/telemetry.ts Extended getProbabilityData() to include event, outcome, and subjective fields in the returned data structure
components/TelemetryTimeline.tsx Added CustomTooltip component with rich formatting and replaced default tooltip; added scope="col" to table headers for accessibility

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

ResponsiveContainer,
} from 'recharts';

const CustomTooltip = ({ active, payload, label }: any) => {
Copy link

Copilot AI Feb 24, 2026

Choose a reason for hiding this comment

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

The CustomTooltip function uses any type for its parameters, which defeats TypeScript's type safety. This is particularly important because the tsconfig.json has "strict": true enabled. Consider defining a proper interface for the tooltip props. Recharts provides types that can be used, or you can define a custom interface like:

interface CustomTooltipProps {
  active?: boolean;
  payload?: Array<{
    payload: {
      time: number;
      probability: number;
      event: string;
      outcome: string;
      subjective: string;
    };
  }>;
  label?: number;
}

This will provide proper type checking and IntelliSense support.

Suggested change
const CustomTooltip = ({ active, payload, label }: any) => {
interface CustomTooltipProps {
active?: boolean;
payload?: Array<{
payload: {
time: number;
probability: number;
event: string;
outcome: string;
subjective: string;
};
}>;
label?: number;
}
const CustomTooltip: React.FC<CustomTooltipProps> = ({ active, payload, label }) => {

Copilot uses AI. Check for mistakes.
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