Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/marks/auto.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {group, groupX, groupY} from "../transforms/group.js";
import {marks} from "../mark.js";
import {ascending} from "d3";

export function auto(data, {x, y, color, size, fx, fy, mark} = {}) {
export function auto(data, {x, y, color, size, fx, fy, mark, ...otherOptions} = {}) {
// Allow x and y and other dimensions to be specified as shorthand field names
// (but note that they can also be specified as a {transform} object such as
// Plot.identity).
Expand Down Expand Up @@ -205,7 +205,7 @@ export function auto(data, {x, y, color, size, fx, fy, mark} = {}) {
// (particularly dots and lines) they should come before the mark.
const frames = fx != null || fy != null ? frame({strokeOpacity: 0.1}) : null;
const rules = [xZero ? ruleX([0]) : null, yZero ? ruleY([0]) : null];
mark = mark(data, options);
mark = mark(data, {...otherOptions, ...options});
return colorMode === "stroke" ? marks(frames, rules, mark) : marks(frames, mark, rules);
}

Expand Down
Loading