Skip to content

Commit

Permalink
fix(bar): allow BarCanvas axis to be nullable (#1980)
Browse files Browse the repository at this point in the history
Types do not currently allow `axisBottom`, `axisLeft`, `axisRight`, or `axisTop` to be set to `null`, however this is required to disable axis and is found in the nivo documentation.
  • Loading branch information
squidsoup committed May 10, 2022
1 parent b021074 commit d15406e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/bar/src/types.ts
Expand Up @@ -289,10 +289,10 @@ export type BarCanvasProps<RawDatum extends BarDatum> = Partial<BarCommonProps<R
BarHandlers<RawDatum, HTMLCanvasElement> &
Dimensions &
Partial<{
axisBottom: CanvasAxisProps<any>
axisLeft: CanvasAxisProps<any>
axisRight: CanvasAxisProps<any>
axisTop: CanvasAxisProps<any>
axisBottom: CanvasAxisProps<any> | null
axisLeft: CanvasAxisProps<any> | null
axisRight: CanvasAxisProps<any> | null
axisTop: CanvasAxisProps<any> | null

renderBar: (context: CanvasRenderingContext2D, props: RenderBarProps<RawDatum>) => void

Expand Down

0 comments on commit d15406e

Please sign in to comment.