Repository navigation
Respect pointer pooling per mark - #2490
Open
pcbeingused33 wants to merge 2 commits into
Open
pcbeingused33 wants to merge 2 commits into
pcbeingused33 wants to merge 2 commits into
Conversation
A pointer that picks nothing is removed from the pool instead of competing with maxRadius², so it can no longer hide a real pick (case 1 of observablehq#2475). This also restores the 0.6.17 facet behavior: the value resets to null on pointerleave, and the winning pick renders last so that a losing pointer cannot overwrite the dispatched value with null.
Fil
approved these changes
Dec 1, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes case 2 of #2475 (a later mark's
pool: falseis ignored). Case 1 (a pointer that picks nothing outranking a real pick) is not addressed here, so the issue should stay open.The first pointer mark to render determines whether the plot has a shared pool. That makes later marks inherit its pooling setting and can hide a highlight configured with
pool: false.Choose the pool for each mark when it renders. Marks with pooling enabled lazily create or reuse the shared pool. Independent marks retain their per-mark facet pool when faceted.
The regression test exercises both render orders and expects an independent highlight alongside a single tooltip from two competing tips. Run it with
pnpm exec vitest run test/pointer-test.js.This change was prepared with AI assistance.