Skip to content
Source
Sign inSign up
TanStack/charts

Avoid clearing plain tooltip labels twice #254

Mergedtannerlinsleymerged 3 commits intomain fromtaren/plain-tooltip-current-1943merged by tannerlinsley

tannerlinsleycommented

Addresses one part of #187. Plain-text tooltips clear a stale accessible label once per paint. Structured tooltip content keeps its accessible label. Thanks to @toomingos for reporting the redundant work.

The regression test covers both content paths. All 42 focused runtime tests and the 146-row bundle policy passed on current main. The source fingerprint and matching comparison docs were refreshed within the approved scope. Numeric budgets and recorded size rows are unchanged.

The broader tooltip work in #187 remains open.

Summary by CodeRabbit

  • Bug Fixes
    • Plain-text tooltips no longer repeatedly clear their accessible label during chart updates, helping keep keyboard navigation and tooltip announcements consistent.
    • Tooltips retain their status role and polite live-region behavior, supporting assistive technology announcements. They also continue to display multiline text with preserved whitespace.
    1. changeset-bot[bot](GitHub profile, opens in a new tab)commented

      🦋 Changeset detected

      Latest commit: 5a9ac77f2acd40bd3c83e26fb14cfbf03c39050f

      The changes in this PR will be included in the next version bump.

      This PR includes changesets to release 12 packages
      NameType
      @tanstack/chartsPatch
      @tanstack/alpine-chartsPatch
      @tanstack/angular-chartsPatch
      @tanstack/lit-chartsPatch
      @tanstack/octane-chartsPatch
      @tanstack/preact-chartsPatch
      @tanstack/react-chartsPatch
      @tanstack/react-native-chartsPatch
      @tanstack/solid-chartsPatch
      @tanstack/svelte-chartsPatch
      @tanstack/vue-chartsPatch
      @tanstack/charts-scalesPatch

      Not sure what this means? Click here to learn what changesets are.

      Click here if you're a maintainer who wants to add another changeset to this PR

    2. coderabbitai[bot](GitHub profile, opens in a new tab)commented
      Review in Change Stack →

      No actionable comments were generated in the recent review.

      Walkthrough

      Plain-text tooltip configuration no longer clears aria-label during paint. A runtime test checks tooltip behavior after keyboard navigation. The pull request also updates comparison metadata and adds a patch changeset.

      Changes: Plain-Text Tooltip Accessibility

      Layer / File(s)Summary
      Tooltip semantics and regression coverage
      packages/charts-core/src/tooltip.ts, packages/charts-core/src/runtime.test.ts, .changeset/plain-tooltip-label.md
      Tooltip configuration no longer clears aria-label for non-custom string content. The runtime test checks tooltip text, accessibility attributes, whitespace style, and removal of a stale label exactly once. The changeset requests a patch release.

      Comparison Revision Metadata

      Layer / File(s)Summary
      Update comparison revision metadata
      benchmarks/comparison/bundle-baseline.json, docs/comparison.md, packages/charts-core/docs/comparison.md, benchmarks/conformance/previews/manifest.json
      The bundle baseline and comparison documents record the updated TanStack Charts workspace revision. The conformance manifest records a new source hash. Competitor package pins remain unchanged.

      Estimated code review effort: 2 (Simple) | ~10 minutes

      Change: Refactor

      Possibly related issues

      • TanStack/charts#187 — The change addresses the plain-text tooltip label behavior described in the issue. The broader repeated-attribute-write issue remains open.

      Suggested reviewers: greglum

      Merge Risk: Minimal · up to 5a9ac

      The tooltip accessibility change has no established merge-blocking risk, and the regression test covers the affected behavior.

      Pre-merge checks: Passed 5
      Check nameStatusExplanation
      Description CheckPassedCheck skipped - CodeRabbit’s high-level summary is enabled.
      Title checkPassedThe title clearly and concisely describes the main change: preventing duplicate clearing of plain tooltip labels.
      Docstring CoveragePassedNo eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
      Linked Issues checkPassedCheck skipped because no linked issues were found for this pull request.
      Out of Scope Changes checkPassedCheck skipped because no linked issues were found for this pull request.
      Full details: Docstring Coverage

      Explanation

      No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 1 files. (1 skipped: 1 unsupported.)

      Finishing Touches
      Generate unit tests (beta)
      • Commit to this branch
      • Create a new PR
      • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

      Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

      Share
      Recent review info
      Run configuration
      • Source mode: Auto
      • Repository: Unavailable
      • Branch: Unavailable
      • File: No configuration file from this repository applied
      • Commit: Unavailable
      • Layers: defaults
      • Review profile: CHILL
      • Plan: Advanced
      • Run ID: 8d1eff91-fdf2-4149-8822-4c913e5b729f
      Commits

      Reviewing files that changed from the base of the PR and between 182c0035940190d703b4990735247baf7a835f9a and 5a9ac77f2acd40bd3c83e26fb14cfbf03c39050f.

      Files selected for processing: 1
      • benchmarks/conformance/previews/manifest.json

      Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.

    3. nx-cloud[bot](GitHub profile, opens in a new tab)commented

      View your CI Pipeline Execution ↗ for commit 5a9ac77f2acd40bd3c83e26fb14cfbf03c39050f

      CommandStatusDurationResult
      nx run charts-workspace:ci-distributed✅ Succeeded4m 13sView ↗
      nx run charts-workspace:package-check✅ Succeeded<1sView ↗
      nx run charts-workspace:benchmark-check✅ Succeeded1m 8sView ↗

      ☁️ Nx Cloud last updated this comment at 2026-11-04 04:47:20 UTC

    4. Important

      At least one additional CI pipeline execution has run since the conclusion below was written and it may no longer be applicable.

      Nx Cloud is proposing a fix for your failed CI:

      We updated the sourceHash in benchmarks/conformance/previews/manifest.json so it matches our current packages/charts-core/src sources, which this PR's tooltip.ts and runtime.test.ts edits changed. That should fix the catalog-preview-check failure. After the change, node scripts/catalog-preview.mjs --check validates all 189 previews.

      Tip

      ✅ We verified this fix by re-running charts-workspace:catalog-preview-check.

      diff --git a/benchmarks/conformance/previews/manifest.json b/benchmarks/conformance/previews/manifest.json
      index 72a3c6c..cbbf0d0 100644
      --- a/benchmarks/conformance/previews/manifest.json
      +++ b/benchmarks/conformance/previews/manifest.json
      @@ -2,7 +2,7 @@
         "schemaVersion": 1,
         "width": 288,
         "height": 192,
      -  "sourceHash": "c0a8f6f71595708e1525044cae14a913f6f92d0e4a69cabe45508420372142e4",
      +  "sourceHash": "66a5db90bfd382f73b86f1b54be6dce55ff135cd7dcc0a4c72421ee1b30d7b24",
         "assets": [
           {
             "id": "01-line-gaps",
      

      Apply fix via Nx Cloud  Reject fix via Nx Cloud


      Or Apply changes locally with:

      npx nx-cloud apply-locally L5oz-zUdV
      Apply fix locally with your editor ↗   View interactive diff ↗

      🎓 Learn more about Self-Healing CI on [nx.dev](https://nx.dev/docs/features/ci-features/self-healing-ci?utm_source=pull-request&utm_medium=comment)
    5. tannerlinsley merged this7be9c41

    6. tannerlinsley closed this

Sign in to join this conversation.