API reference: @salmonui/charts/chart
ChartAxisPropsinterface
import type { ChartAxisProps } from '@salmonui/charts/chart';interface ChartAxisProps extends ChartAxisOptions {
readonly direction: 'x' | 'y';
readonly id?: string | undefined;
}
| Name | Signature | Description |
|---|---|---|
direction | readonly direction: 'x' | 'y'; |
|
idoptional | readonly id?: string | undefined; | Required except for the primary axes ( |
scaleoptionalinherited | scale?: ChartScale; | |
titleoptionalinherited | title?: string; | |
minoptionalinherited | min?: number | Date; | |
maxoptionalinherited | max?: number | Date; | |
intervaloptionalinherited | interval?: number | { readonly unit: "day" | "hour" | "millisecond" | "minute" | "month" | "second" | "week" | "year"; readonly step: number; }; | Numeric step, or a calendar interval on time axes. |
tickCountoptionalinherited | tickCount?: number; | |
includeZerooptionalinherited | includeZero?: boolean; | |
paddingoptionalinherited | padding?: "additional" | "auto" | "none" | "normal" | "round"; | |
baseoptionalinherited | base?: number; | |
positionoptionalinherited | position?: "end" | "start"; |
|
reversedoptionalinherited | reversed?: boolean; | |
hiddenoptionalinherited | hidden?: boolean; | |
gridLinesoptionalinherited | gridLines?: "both" | "major" | boolean; | |
minorTicksoptionalinherited | minorTicks?: number; | |
labelOverlapoptionalinherited | labelOverlap?: ChartLabelOverlap; | |
labelAngleoptionalinherited | labelAngle?: number; | |
maxLabelWidthoptionalinherited | maxLabelWidth?: number; | |
labelPlacementoptionalinherited | labelPlacement?: "between" | "on"; | |
edgeLabelsoptionalinherited | edgeLabels?: "hide" | "none" | "shift"; | |
labelPositionoptionalinherited | labelPosition?: "inside" | "outside"; | |
tickPositionoptionalinherited | tickPosition?: "inside" | "outside"; | |
plotOffsetoptionalinherited | plotOffset?: number; | Padding in px between the axis ends and the first and last data positions. |
indexedoptionalinherited | indexed?: boolean; | Category axis by point index: duplicate categories stay separate. |
ticksoptionalinherited | ticks?: boolean; |
|
lineoptionalinherited | line?: boolean; |
|
titleAngleoptionalinherited | titleAngle?: number; | Title rotation in degrees (default 0 on horizontal axes, -90 / 90 on vertical ones). |
formatoptionalinherited | format?: ChartFormat; | |
formatLabeloptionalinherited | formatLabel?: ((value: unknown) => string); | |
renderLabeloptionalinherited | renderLabel?: ((ctx: ChartAxisLabelContext) => ReactNode); | SVG text content for a tick label (a string or |
labelGroupsoptionalinherited | labelGroups?: readonly ChartAxisLabelGroup[]; | Grouped labels below the tick labels (multi-level labels). |
bandsoptionalinherited | bands?: readonly ChartAxisBand[]; | |
linesoptionalinherited | lines?: readonly ChartAxisLine[]; | |
domainoptionalinherited | domain?: ((computed: readonly [number, number]) => readonly [number, number]); | Adjust the computed numeric domain (pure). |
paneoptionalinherited | pane?: { readonly row?: number; readonly column?: number; readonly span?: number; }; | |
startAngleoptionalinherited | startAngle?: number; | Polar and radar x axis: the angle of the first category or value, in degrees clockwise from 12 o'clock. |
crossAtoptionalinherited | crossAt?: { readonly value: number | Date; readonly axis?: string | undefined; }; | Draws the axis line where the crossing axis (default: the primary one) has |
labelsAtCrossoptionalinherited | labelsAtCross?: boolean; | With |