feat: add hexbin transform and Hexgrid mark#542
Draft
RobertFrenken wants to merge 4 commits intosvelteplot:mainfrom
Draft
feat: add hexbin transform and Hexgrid mark#542RobertFrenken wants to merge 4 commits intosvelteplot:mainfrom
RobertFrenken wants to merge 4 commits intosvelteplot:mainfrom
Conversation
Add hexbin transform for aggregating 2D point data into hexagonal bins, with Hexgrid helper mark and documentation page. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
✅ Deploy Preview for svelteplot ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
4 tasks
Fixes svelte/no-useless-children-snippet lint error. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Cast groupProps to Record<string | symbol, RawValue> for DataRecord assignment compatibility. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
RobertFrenken
added a commit
to RobertFrenken/svelteplot
that referenced
this pull request
Apr 7, 2026
…in docs Add comprehensive unit tests for all 5 Delaunay/Voronoi marks: - Voronoi (16 tests): rendering, styling, channel mapping, events, edge cases - VoronoiMesh (11 tests): single-path rendering, attributes, edge cases - DelaunayMesh (10 tests): triangulation path, attributes, edge cases - DelaunayLink (12 tests): per-edge paths, styling, events, deduplication - Hull (14 tests): grouping by z/fill/stroke, styling, edge cases Fix Hull grouping bug where NaN coordinates during initial reactive render caused duplicate keyed-each keys crash: - Guard against NaN with Number.isFinite() instead of typeof === 'number' - Use index-based each key instead of path string to prevent duplicate keys Remove hexbin docs (Hexgrid + Hexbin transform sections) that were incorrectly included in the Delaunay docs page — these belong in the hexbin PR (svelteplot#542). ## New mark checklist (remaining items for this feature) - [x] Component source (`src/lib/marks/`) - [x] Type definitions (`src/lib/types/mark.ts`) - [x] Exports (`src/lib/marks/index.ts`) - [x] Sidebar config (`config/sidebar.ts`) - [x] Docs page (`src/routes/marks/delaunay/+page.md`) - [x] Unit tests (`src/tests/`) - [ ] Examples gallery (`src/routes/examples/delaunay/`) - [ ] Visual regression snapshots (`src/snapshots/delaunay/`) - [ ] Canvas rendering variants Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
11 tests covering rendering, default/custom styling (stroke, fill, opacity, strokeWidth), CSS class override, binWidth geometry scaling, hexagon density, and plot dimension adaptation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
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.

Summary
count,mean,sum, and other reducers via existing reduce infrastructureCloses #86
Closes #80
Split from #531 per reviewer request.
Test plan
pnpm testpassespnpm buildsucceedspnpm lintpasses (prettier formatting fixed)/transforms/hexbin🤖 Generated with Claude Code