Feature
Allower greater control over the layer rendering order on canvas layers. Should sync with legend and tooltip order somehow.
Proposed API
Very rough idea right now to start thinking about the best approach
// Render ordering
interface OrderFn = (series: SeriesIdentifier) => number; // number to use as global z-index
interface OrderSortFn = (seriesA: SeriesIdentifier, seriesB: SeriesIdentifier) => -1 | 0 | 1; // relative ordering of series
type Order = OrderFn | OrderSortFn | number // number would be the simplest ordering or spec
interface BasicSeriesSpec {
order: Order;
}
// Edge clippings
interface EdgeClippingProps {
lineWidth?: boolean; // including line width on edge
points?: boolean; // including point radius on edge
highlighter?: boolean; // include all highlighter elements outside of chart area
padding?: number; // max padding for clippings
}
interface SettingsSpec {
// not sure if Settings is the right place for this but it should be a global thing
edgeClipping: EdgeClippingProps;
...
}
Related to #315, #303, #585 & #160
Examples
Overall ordering
Order rendering per spec, based on simple number or order.
Series ordering
Order rendering per series, overriding spec order. For example, select which line gets drawn on top of the other.

Edge clipping
Greater control for clipping at the edge for line widths and points

Feature
Allower greater control over the layer rendering order on canvas layers. Should sync with legend and tooltip order somehow.
Proposed API
Very rough idea right now to start thinking about the best approach
Related to #315, #303, #585 & #160
Examples
Overall ordering
Order rendering per spec, based on simple number or order.
Series ordering
Order rendering per series, overriding spec order. For example, select which line gets drawn on top of the other.
Edge clipping
Greater control for clipping at the edge for line widths and points