Options
All
  • Public
  • Public/Protected
  • All
Menu

Class DualScaleTrack

A scale track that supports interpolation between two scale domains. Requires container to supply a scale handler in the onMount event.

The dual scale has a master/slave mode, which can be toggled to change its behaviour (switch between domains), using the scale-handler's setMode-function.

Hierarchy

Index

Constructors

constructor

Properties

Protected _data

_data: any

Protected _isLoading

_isLoading: boolean

Protected _mounted

_mounted: boolean

elm

elm: HTMLElement

error

error: Error | string

id

id: string | number

labelBounds

labelBounds: LabelBounds

Optional legendUpdate

legendUpdate: LegendTriggerFunction

loader

loader: D3Selection

options

order

order: number

Protected plotGroup

plotGroup: D3Selection

scale

scale: Scale

scaleHandler

ticks

ticks: number[]

transform

transform: Transform

viewMode

viewMode: number

xscale

xscale: Scale

Accessors

data

  • get data(): any
  • set data(data: Promise<any> | Function | any): void

extent

isLoading

  • get isLoading(): boolean
  • set isLoading(val: boolean): void

isMaster

  • get isMaster(): boolean

isMounted

  • get isMounted(): boolean

Methods

createMeasures

createRuler

createTicks

  • createTicks(): void

init

  • init(elm: HTMLElement, scale: Scale): void
  • Calls OnMount and OnUpdate. Useful if track is stand-alone

    Parameters

    • elm: HTMLElement
    • scale: Scale

    Returns void

loadData

  • loadData(data: any, showLoader?: boolean): void
  • Initiate loading of data for track. Will set response to the track's data property. If showLoader is set to true, the current track will be hidden, and (if supplied) the loader element will be shown, until data is resolved. Calls onDataLoaded if implemented by track.

    Parameters

    • data: any
    • Default value showLoader: boolean = true

    Returns void

onDataLoaded

  • onDataLoaded(data?: any): void

onError

  • onError(error: Error | string): void
  • Should be called from track implementation in case an unrecoverable error occurs.

    Parameters

    • error: Error | string

    Returns void

onMount

onRescale

onUnmount

  • Handler for onUnmount event. Called when track DOM-element is remove from the DOM model. Typically, trackEvent will be an empty object, but depends on container.

    Parameters

    Returns void

onUpdate

plot

  • plot(): void

refresh

  • refresh(): void

Generated using TypeDoc