import { ChartJs } from "https://deno.land/x/fresh_charts@0.3.0/deps.ts";
const { Scale } = ChartJs;
Constructors
new
Scale(cfg: { id: string; type: string; ctx: CanvasRenderingContext2D; chart: Chart; })import { type ChartJs } from "https://deno.land/x/fresh_charts@0.3.0/deps.ts";
const { Scale } = ChartJs;
Type Parameters
optional
O extends CoreScaleOptions = CoreScaleOptionsMethods
getMatchingVisibleMetas(type?: string): ChartMeta[]
drawTitle(chartArea: ChartArea): void
drawLabels(chartArea: ChartArea): void
drawGrid(chartArea: ChartArea): void
Utility for getting the pixel location of a percentage of scale The coordinate (0, 0) is at the upper-left corner of the canvas
Returns the location of the tick at the given index The coordinate (0, 0) is at the upper-left corner of the canvas
Returns the location of the given data point. Value can either be an index or a numerical value The coordinate (0, 0) is at the upper-left corner of the canvas
Used to get the data value from a given pixel. This is the inverse of getPixelForValue The coordinate (0, 0) is at the upper-left corner of the canvas
Returns the pixel for the minimum chart value The coordinate (0, 0) is at the upper-left corner of the canvas
init(options: O): void
getTicks(): Tick[]
buildTicks(): Tick[]
generateTickLabels(ticks: Tick[]): void