Skip to content

plugin-charts: a scatter's extreme points are half-clipped by the plot edge — the numeric axes get no domain padding #7396

Description

@hotlong

Found while fixing objectui#7248 (that card's stray dot turned out to be the legend swatch; this is a separate, real instance of the same reader-facing complaint, and is NOT addressed by that PR).

What happens

The scatter branch of AdvancedChartImpl renders its two numeric axes with no domain, so recharts fits the domain to [dataMin, dataMax] on x. Rows sitting at either extreme land exactly ON the plot boundary, and since a mark has a radius, roughly half of each extreme symbol renders outside the plot area.

Measured

Showcase Chart Gallery, Estimate vs Progress, real Chromium, viewport 1440, widget svg 510x350:

  • plot area: x 53..505
  • marks: cx 53, 256.4, 301.6, 414.6, 459.8, 505

The first and last marks sit precisely on the left and right boundary. The symbol radius is about 5px, so about half of each is painted outside the plot area. Visible in the screenshots on objectui#7248 as clipped half-dots hugging both edges.

Why it is filed separately

Different mechanism from objectui#7248 (axis domain fitting, not legend label resolution) and a different blast radius: adding padding changes the appearance of every scatter, so it wants its own justification and its own pins rather than riding along.

Expected

A mark is drawn wholly inside the plot area — either by padding the numeric domain by roughly one symbol radius, or by reserving that margin in the chart box.

Generated by Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdomain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatpm:queuepriority:p3

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions