Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

brushX with `values` can shorten the selection range when it’s dragged to the plot edge

Open Beginner friendly
#170 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@andersk is already working on this.

Since Oct 7, 2026.

  • #173 by @andersk — open

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
78/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
d3, typescript

Research direction

Start from the brushX implementation in this repo (search for where explicit values are used to round the selection endpoints when dragging) and read how each endpoint is snapped independently. Reproduce with the linked jsfiddle steps: drag a 3-day selection to the plot edge and watch it shrink. Done means both endpoints round against the same reference so the selection keeps its width at the edges, verified by a test or manual check that the range stays 2024-01-02..2024-01-04 through repeated edge drags.

Written by the indexing model from the issue text.

Description

When a brushX with explicit values sits over an x domain that extends past its first and last values, dragging the selected range all the way to either edge of the plot may shorten the selected range by one value. Each further drag to an edge can shorten it again. This happens due to independent rounding of the two endpoints.

Reproduction: https://jsfiddle.net/anderskaseorg/ty3hz9m8/

  1. Open the page. The range is 2024-01-02 to 2024-01-04 (3 days).
  2. Drag the selection all the way to the left. The range shortens to 2024-01-01 to 2024-01-02 (2 days).
  3. Drag the selection all the way to the right. The range shortens to 2024-01-05 to 2024-01-05 (1 day).
Dominant language
TypeScript
Stars
819
Forks
49
Avg merge
8h 8m
Merged PRs (30d)
11

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from TanStack/charts

All issues in TanStack/charts

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.