|
|
|
@ -23,6 +23,7 @@ import {
|
|
|
|
|
ScrollPanDirection, |
|
|
|
|
AxisOption, |
|
|
|
|
AxesOptions, |
|
|
|
|
RenderComponent, |
|
|
|
|
} from './types'; |
|
|
|
|
import { uid } from './utils'; |
|
|
|
|
import { palette } from './colors'; |
|
|
|
@ -193,6 +194,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
this.metricContainer = clipContatiner |
|
|
|
|
.append('g') |
|
|
|
|
.attr('class', 'metrics-rect'); |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.METRICS_CONTAINER); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected createSvg(): void { |
|
|
|
@ -209,6 +211,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
|
|
|
|
|
protected renderGrid(): void { |
|
|
|
|
this.grid.render(); |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.GRID); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected renderAxes(): void { |
|
|
|
@ -216,6 +219,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
this.renderXAxis(); |
|
|
|
|
this.renderYAxis(); |
|
|
|
|
this.renderY1Axis(); |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.AXES); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected renderXAxis(): void { |
|
|
|
@ -316,6 +320,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
.attr('x2', this.width) |
|
|
|
|
.style('pointer-events', 'none'); |
|
|
|
|
} |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.CROSSHAIR); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected addEvents(): void { |
|
|
|
@ -363,6 +368,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
.attr('cursor', 'crosshair') |
|
|
|
|
.attr('fill', 'none'); |
|
|
|
|
} |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.OVERLAY); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected initBrush(): void { |
|
|
|
@ -449,6 +455,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
.attr('height', this.height) |
|
|
|
|
.attr('x', 0) |
|
|
|
|
.attr('y', 0); |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.CLIP_PATH); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected renderLegend(): void { |
|
|
|
@ -487,6 +494,7 @@ abstract class ChartwerkPod<T extends Serie, O extends Options> {
|
|
|
|
|
.text(series[idx].target) |
|
|
|
|
.on('click', () => this.options.callbackLegendLabelClick(idx)); |
|
|
|
|
} |
|
|
|
|
this.options.callbackComponentRenderEnd(RenderComponent.LEGEND); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
protected renderYLabel(): void { |
|
|
|
@ -904,7 +912,7 @@ export {
|
|
|
|
|
ChartwerkPod, VueChartwerkPodMixin, |
|
|
|
|
PodState, CoreSeries, CoreOptions, CORE_SERIE_DEFAULTS, CORE_DEFAULT_OPTIONS, |
|
|
|
|
Margin, Serie, Options, TimeFormat, BrushOrientation, PanOrientation, |
|
|
|
|
AxesOptions, AxisOption, |
|
|
|
|
AxesOptions, AxisOption, RenderComponent, |
|
|
|
|
AxisFormat, yAxisOrientation, CrosshairOrientation, ScrollPanOrientation, ScrollPanDirection, KeyEvent, |
|
|
|
|
palette |
|
|
|
|
}; |
|
|
|
|