UNPKG

devextreme-react

Version:

DevExtreme React UI and Visualization Components

1,459 lines • 53.4 kB
/*!
 * devextreme-react
 * Version: 24.2.6
 * Build date: Mon Mar 17 2025
 *
 * Copyright (c) 2012 - 2025 Developer Express Inc. ALL RIGHTS RESERVED
 *
 * This software may be modified and distributed under the terms
 * of the MIT license. See the LICENSE file in the root of the project for details.
 *
 * https://github.com/DevExpress/devextreme-react
 */

"use client";
import * as React from "react";
import { memo, forwardRef, useImperativeHandle, useRef, useMemo } from "react";
import dxChart from "devextreme/viz/chart";
import { Component as BaseComponent } from "./core/component";
import NestedOption from "./core/nested-option";
const Chart = memo(forwardRef((props, ref) => {
    const baseRef = useRef(null);
    useImperativeHandle(ref, () => ({
        instance() {
            return baseRef.current?.getInstance();
        }
    }), [baseRef.current]);
    const subscribableOptions = useMemo(() => (["argumentAxis", "argumentAxis.categories", "argumentAxis.visualRange", "loadingIndicator", "loadingIndicator.show", "valueAxis", "valueAxis.categories", "valueAxis.visualRange"]), []);
    const independentEvents = useMemo(() => (["onArgumentAxisClick", "onDisposing", "onDone", "onDrawn", "onExported", "onExporting", "onFileSaving", "onIncidentOccurred", "onInitialized", "onLegendClick", "onPointClick", "onSeriesClick", "onTooltipHidden", "onTooltipShown", "onZoomEnd", "onZoomStart"]), []);
    const defaults = useMemo(() => ({
        defaultArgumentAxis: "argumentAxis",
        defaultLoadingIndicator: "loadingIndicator",
        defaultValueAxis: "valueAxis",
    }), []);
    const expectedChildren = useMemo(() => ({
        adaptiveLayout: { optionName: "adaptiveLayout", isCollectionItem: false },
        animation: { optionName: "animation", isCollectionItem: false },
        annotation: { optionName: "annotations", isCollectionItem: true },
        argumentAxis: { optionName: "argumentAxis", isCollectionItem: false },
        chartTitle: { optionName: "title", isCollectionItem: false },
        commonAnnotationSettings: { optionName: "commonAnnotationSettings", isCollectionItem: false },
        commonAxisSettings: { optionName: "commonAxisSettings", isCollectionItem: false },
        commonPaneSettings: { optionName: "commonPaneSettings", isCollectionItem: false },
        commonSeriesSettings: { optionName: "commonSeriesSettings", isCollectionItem: false },
        crosshair: { optionName: "crosshair", isCollectionItem: false },
        dataPrepareSettings: { optionName: "dataPrepareSettings", isCollectionItem: false },
        export: { optionName: "export", isCollectionItem: false },
        legend: { optionName: "legend", isCollectionItem: false },
        loadingIndicator: { optionName: "loadingIndicator", isCollectionItem: false },
        margin: { optionName: "margin", isCollectionItem: false },
        pane: { optionName: "panes", isCollectionItem: true },
        scrollBar: { optionName: "scrollBar", isCollectionItem: false },
        series: { optionName: "series", isCollectionItem: true },
        seriesTemplate: { optionName: "seriesTemplate", isCollectionItem: false },
        size: { optionName: "size", isCollectionItem: false },
        title: { optionName: "title", isCollectionItem: false },
        tooltip: { optionName: "tooltip", isCollectionItem: false },
        valueAxis: { optionName: "valueAxis", isCollectionItem: true },
        zoomAndPan: { optionName: "zoomAndPan", isCollectionItem: false }
    }), []);
    return (React.createElement((BaseComponent), {
        WidgetClass: dxChart,
        ref: baseRef,
        useRequestAnimationFrameFlag: true,
        subscribableOptions,
        independentEvents,
        defaults,
        expectedChildren,
        ...props,
    }));
}));
const _componentAdaptiveLayout = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "adaptiveLayout",
        },
    });
};
const AdaptiveLayout = Object.assign(_componentAdaptiveLayout, {
    componentType: "option",
});
const _componentAggregation = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "aggregation",
        },
    });
};
const Aggregation = Object.assign(_componentAggregation, {
    componentType: "option",
});
const _componentAggregationInterval = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "aggregationInterval",
        },
    });
};
const AggregationInterval = Object.assign(_componentAggregationInterval, {
    componentType: "option",
});
const _componentAnimation = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "animation",
        },
    });
};
const Animation = Object.assign(_componentAnimation, {
    componentType: "option",
});
const _componentAnnotation = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "annotations",
            IsCollectionItem: true,
            ExpectedChildren: {
                annotationBorder: { optionName: "border", isCollectionItem: false },
                annotationImage: { optionName: "image", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                image: { optionName: "image", isCollectionItem: false },
                shadow: { optionName: "shadow", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "template",
                    render: "render",
                    component: "component"
                }, {
                    tmplOption: "tooltipTemplate",
                    render: "tooltipRender",
                    component: "tooltipComponent"
                }],
        },
    });
};
const Annotation = Object.assign(_componentAnnotation, {
    componentType: "option",
});
const _componentAnnotationBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const AnnotationBorder = Object.assign(_componentAnnotationBorder, {
    componentType: "option",
});
const _componentAnnotationImage = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "image",
        },
    });
};
const AnnotationImage = Object.assign(_componentAnnotationImage, {
    componentType: "option",
});
const _componentArgumentAxis = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "argumentAxis",
            DefaultsProps: {
                defaultCategories: "categories",
                defaultVisualRange: "visualRange"
            },
            ExpectedChildren: {
                aggregationInterval: { optionName: "aggregationInterval", isCollectionItem: false },
                axisConstantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                axisLabel: { optionName: "label", isCollectionItem: false },
                axisTitle: { optionName: "title", isCollectionItem: false },
                break: { optionName: "breaks", isCollectionItem: true },
                breakStyle: { optionName: "breakStyle", isCollectionItem: false },
                constantLine: { optionName: "constantLines", isCollectionItem: true },
                constantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                grid: { optionName: "grid", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                minorGrid: { optionName: "minorGrid", isCollectionItem: false },
                minorTick: { optionName: "minorTick", isCollectionItem: false },
                minorTickInterval: { optionName: "minorTickInterval", isCollectionItem: false },
                minVisualRangeLength: { optionName: "minVisualRangeLength", isCollectionItem: false },
                strip: { optionName: "strips", isCollectionItem: true },
                stripStyle: { optionName: "stripStyle", isCollectionItem: false },
                tick: { optionName: "tick", isCollectionItem: false },
                tickInterval: { optionName: "tickInterval", isCollectionItem: false },
                title: { optionName: "title", isCollectionItem: false },
                visualRange: { optionName: "visualRange", isCollectionItem: false },
                wholeRange: { optionName: "wholeRange", isCollectionItem: false }
            },
        },
    });
};
const ArgumentAxis = Object.assign(_componentArgumentAxis, {
    componentType: "option",
});
const _componentArgumentFormat = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "argumentFormat",
        },
    });
};
const ArgumentFormat = Object.assign(_componentArgumentFormat, {
    componentType: "option",
});
const _componentAxisConstantLineStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "constantLineStyle",
            ExpectedChildren: {
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const AxisConstantLineStyle = Object.assign(_componentAxisConstantLineStyle, {
    componentType: "option",
});
const _componentAxisConstantLineStyleLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const AxisConstantLineStyleLabel = Object.assign(_componentAxisConstantLineStyleLabel, {
    componentType: "option",
});
const _componentAxisLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false },
                format: { optionName: "format", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "template",
                    render: "render",
                    component: "component"
                }],
        },
    });
};
const AxisLabel = Object.assign(_componentAxisLabel, {
    componentType: "option",
});
const _componentAxisTitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "title",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const AxisTitle = Object.assign(_componentAxisTitle, {
    componentType: "option",
});
const _componentBackgroundColor = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "backgroundColor",
        },
    });
};
const BackgroundColor = Object.assign(_componentBackgroundColor, {
    componentType: "option",
});
const _componentBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const Border = Object.assign(_componentBorder, {
    componentType: "option",
});
const _componentBreak = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "breaks",
            IsCollectionItem: true,
        },
    });
};
const Break = Object.assign(_componentBreak, {
    componentType: "option",
});
const _componentBreakStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "breakStyle",
        },
    });
};
const BreakStyle = Object.assign(_componentBreakStyle, {
    componentType: "option",
});
const _componentChartTitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "title",
            ExpectedChildren: {
                chartTitleSubtitle: { optionName: "subtitle", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                margin: { optionName: "margin", isCollectionItem: false },
                subtitle: { optionName: "subtitle", isCollectionItem: false }
            },
        },
    });
};
const ChartTitle = Object.assign(_componentChartTitle, {
    componentType: "option",
});
const _componentChartTitleSubtitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "subtitle",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const ChartTitleSubtitle = Object.assign(_componentChartTitleSubtitle, {
    componentType: "option",
});
const _componentColor = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "color",
        },
    });
};
const Color = Object.assign(_componentColor, {
    componentType: "option",
});
const _componentCommonAnnotationSettings = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "commonAnnotationSettings",
            ExpectedChildren: {
                annotationBorder: { optionName: "border", isCollectionItem: false },
                annotationImage: { optionName: "image", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                image: { optionName: "image", isCollectionItem: false },
                shadow: { optionName: "shadow", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "template",
                    render: "render",
                    component: "component"
                }, {
                    tmplOption: "tooltipTemplate",
                    render: "tooltipRender",
                    component: "tooltipComponent"
                }],
        },
    });
};
const CommonAnnotationSettings = Object.assign(_componentCommonAnnotationSettings, {
    componentType: "option",
});
const _componentCommonAxisSettings = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "commonAxisSettings",
            ExpectedChildren: {
                breakStyle: { optionName: "breakStyle", isCollectionItem: false },
                commonAxisSettingsConstantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                commonAxisSettingsLabel: { optionName: "label", isCollectionItem: false },
                commonAxisSettingsTitle: { optionName: "title", isCollectionItem: false },
                constantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                grid: { optionName: "grid", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                minorGrid: { optionName: "minorGrid", isCollectionItem: false },
                minorTick: { optionName: "minorTick", isCollectionItem: false },
                stripStyle: { optionName: "stripStyle", isCollectionItem: false },
                tick: { optionName: "tick", isCollectionItem: false },
                title: { optionName: "title", isCollectionItem: false }
            },
        },
    });
};
const CommonAxisSettings = Object.assign(_componentCommonAxisSettings, {
    componentType: "option",
});
const _componentCommonAxisSettingsConstantLineStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "constantLineStyle",
            ExpectedChildren: {
                commonAxisSettingsConstantLineStyleLabel: { optionName: "label", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const CommonAxisSettingsConstantLineStyle = Object.assign(_componentCommonAxisSettingsConstantLineStyle, {
    componentType: "option",
});
const _componentCommonAxisSettingsConstantLineStyleLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const CommonAxisSettingsConstantLineStyleLabel = Object.assign(_componentCommonAxisSettingsConstantLineStyleLabel, {
    componentType: "option",
});
const _componentCommonAxisSettingsLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "template",
                    render: "render",
                    component: "component"
                }],
        },
    });
};
const CommonAxisSettingsLabel = Object.assign(_componentCommonAxisSettingsLabel, {
    componentType: "option",
});
const _componentCommonAxisSettingsTitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "title",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const CommonAxisSettingsTitle = Object.assign(_componentCommonAxisSettingsTitle, {
    componentType: "option",
});
const _componentCommonPaneSettings = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "commonPaneSettings",
            ExpectedChildren: {
                backgroundColor: { optionName: "backgroundColor", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                paneBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const CommonPaneSettings = Object.assign(_componentCommonPaneSettings, {
    componentType: "option",
});
const _componentCommonSeriesSettings = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "commonSeriesSettings",
            ExpectedChildren: {
                aggregation: { optionName: "aggregation", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                commonSeriesSettingsHoverStyle: { optionName: "hoverStyle", isCollectionItem: false },
                commonSeriesSettingsLabel: { optionName: "label", isCollectionItem: false },
                commonSeriesSettingsSelectionStyle: { optionName: "selectionStyle", isCollectionItem: false },
                hoverStyle: { optionName: "hoverStyle", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                point: { optionName: "point", isCollectionItem: false },
                reduction: { optionName: "reduction", isCollectionItem: false },
                selectionStyle: { optionName: "selectionStyle", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false },
                valueErrorBar: { optionName: "valueErrorBar", isCollectionItem: false }
            },
        },
    });
};
const CommonSeriesSettings = Object.assign(_componentCommonSeriesSettings, {
    componentType: "option",
});
const _componentCommonSeriesSettingsHoverStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "hoverStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                hatching: { optionName: "hatching", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const CommonSeriesSettingsHoverStyle = Object.assign(_componentCommonSeriesSettingsHoverStyle, {
    componentType: "option",
});
const _componentCommonSeriesSettingsLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                argumentFormat: { optionName: "argumentFormat", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                connector: { optionName: "connector", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                format: { optionName: "format", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const CommonSeriesSettingsLabel = Object.assign(_componentCommonSeriesSettingsLabel, {
    componentType: "option",
});
const _componentCommonSeriesSettingsSelectionStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "selectionStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                hatching: { optionName: "hatching", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const CommonSeriesSettingsSelectionStyle = Object.assign(_componentCommonSeriesSettingsSelectionStyle, {
    componentType: "option",
});
const _componentConnector = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "connector",
        },
    });
};
const Connector = Object.assign(_componentConnector, {
    componentType: "option",
});
const _componentConstantLine = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "constantLines",
            IsCollectionItem: true,
            ExpectedChildren: {
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const ConstantLine = Object.assign(_componentConstantLine, {
    componentType: "option",
});
const _componentConstantLineLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const ConstantLineLabel = Object.assign(_componentConstantLineLabel, {
    componentType: "option",
});
const _componentConstantLineStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "constantLineStyle",
            ExpectedChildren: {
                commonAxisSettingsConstantLineStyleLabel: { optionName: "label", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const ConstantLineStyle = Object.assign(_componentConstantLineStyle, {
    componentType: "option",
});
const _componentCrosshair = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "crosshair",
            ExpectedChildren: {
                horizontalLine: { optionName: "horizontalLine", isCollectionItem: false },
                horizontalLineLabel: { optionName: "label", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                verticalLine: { optionName: "verticalLine", isCollectionItem: false }
            },
        },
    });
};
const Crosshair = Object.assign(_componentCrosshair, {
    componentType: "option",
});
const _componentDataPrepareSettings = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "dataPrepareSettings",
        },
    });
};
const DataPrepareSettings = Object.assign(_componentDataPrepareSettings, {
    componentType: "option",
});
const _componentDragBoxStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "dragBoxStyle",
        },
    });
};
const DragBoxStyle = Object.assign(_componentDragBoxStyle, {
    componentType: "option",
});
const _componentExport = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "export",
        },
    });
};
const Export = Object.assign(_componentExport, {
    componentType: "option",
});
const _componentFont = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "font",
        },
    });
};
const Font = Object.assign(_componentFont, {
    componentType: "option",
});
const _componentFormat = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "format",
        },
    });
};
const Format = Object.assign(_componentFormat, {
    componentType: "option",
});
const _componentGrid = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "grid",
        },
    });
};
const Grid = Object.assign(_componentGrid, {
    componentType: "option",
});
const _componentHatching = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "hatching",
        },
    });
};
const Hatching = Object.assign(_componentHatching, {
    componentType: "option",
});
const _componentHeight = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "height",
        },
    });
};
const Height = Object.assign(_componentHeight, {
    componentType: "option",
});
const _componentHorizontalLine = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "horizontalLine",
            ExpectedChildren: {
                horizontalLineLabel: { optionName: "label", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const HorizontalLine = Object.assign(_componentHorizontalLine, {
    componentType: "option",
});
const _componentHorizontalLineLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false },
                format: { optionName: "format", isCollectionItem: false }
            },
        },
    });
};
const HorizontalLineLabel = Object.assign(_componentHorizontalLineLabel, {
    componentType: "option",
});
const _componentHoverStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "hoverStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                hatching: { optionName: "hatching", isCollectionItem: false },
                pointBorder: { optionName: "border", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const HoverStyle = Object.assign(_componentHoverStyle, {
    componentType: "option",
});
const _componentImage = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "image",
            ExpectedChildren: {
                height: { optionName: "height", isCollectionItem: false },
                url: { optionName: "url", isCollectionItem: false },
                width: { optionName: "width", isCollectionItem: false }
            },
        },
    });
};
const Image = Object.assign(_componentImage, {
    componentType: "option",
});
const _componentLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                argumentFormat: { optionName: "argumentFormat", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                connector: { optionName: "connector", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                format: { optionName: "format", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "template",
                    render: "render",
                    component: "component"
                }],
        },
    });
};
const Label = Object.assign(_componentLabel, {
    componentType: "option",
});
const _componentLegend = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "legend",
            ExpectedChildren: {
                annotationBorder: { optionName: "border", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                legendTitle: { optionName: "title", isCollectionItem: false },
                margin: { optionName: "margin", isCollectionItem: false },
                title: { optionName: "title", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "markerTemplate",
                    render: "markerRender",
                    component: "markerComponent"
                }],
        },
    });
};
const Legend = Object.assign(_componentLegend, {
    componentType: "option",
});
const _componentLegendTitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "title",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false },
                legendTitleSubtitle: { optionName: "subtitle", isCollectionItem: false },
                margin: { optionName: "margin", isCollectionItem: false },
                subtitle: { optionName: "subtitle", isCollectionItem: false }
            },
        },
    });
};
const LegendTitle = Object.assign(_componentLegendTitle, {
    componentType: "option",
});
const _componentLegendTitleSubtitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "subtitle",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const LegendTitleSubtitle = Object.assign(_componentLegendTitleSubtitle, {
    componentType: "option",
});
const _componentLength = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "length",
        },
    });
};
const Length = Object.assign(_componentLength, {
    componentType: "option",
});
const _componentLoadingIndicator = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "loadingIndicator",
            DefaultsProps: {
                defaultShow: "show"
            },
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const LoadingIndicator = Object.assign(_componentLoadingIndicator, {
    componentType: "option",
});
const _componentMargin = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "margin",
        },
    });
};
const Margin = Object.assign(_componentMargin, {
    componentType: "option",
});
const _componentMinorGrid = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "minorGrid",
        },
    });
};
const MinorGrid = Object.assign(_componentMinorGrid, {
    componentType: "option",
});
const _componentMinorTick = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "minorTick",
        },
    });
};
const MinorTick = Object.assign(_componentMinorTick, {
    componentType: "option",
});
const _componentMinorTickInterval = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "minorTickInterval",
        },
    });
};
const MinorTickInterval = Object.assign(_componentMinorTickInterval, {
    componentType: "option",
});
const _componentMinVisualRangeLength = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "minVisualRangeLength",
        },
    });
};
const MinVisualRangeLength = Object.assign(_componentMinVisualRangeLength, {
    componentType: "option",
});
const _componentPane = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "panes",
            IsCollectionItem: true,
            ExpectedChildren: {
                backgroundColor: { optionName: "backgroundColor", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                paneBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const Pane = Object.assign(_componentPane, {
    componentType: "option",
});
const _componentPaneBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const PaneBorder = Object.assign(_componentPaneBorder, {
    componentType: "option",
});
const _componentPoint = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "point",
            ExpectedChildren: {
                color: { optionName: "color", isCollectionItem: false },
                hoverStyle: { optionName: "hoverStyle", isCollectionItem: false },
                image: { optionName: "image", isCollectionItem: false },
                pointBorder: { optionName: "border", isCollectionItem: false },
                selectionStyle: { optionName: "selectionStyle", isCollectionItem: false }
            },
        },
    });
};
const Point = Object.assign(_componentPoint, {
    componentType: "option",
});
const _componentPointBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const PointBorder = Object.assign(_componentPointBorder, {
    componentType: "option",
});
const _componentPointHoverStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "hoverStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                pointBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const PointHoverStyle = Object.assign(_componentPointHoverStyle, {
    componentType: "option",
});
const _componentPointImage = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "image",
            ExpectedChildren: {
                height: { optionName: "height", isCollectionItem: false },
                url: { optionName: "url", isCollectionItem: false },
                width: { optionName: "width", isCollectionItem: false }
            },
        },
    });
};
const PointImage = Object.assign(_componentPointImage, {
    componentType: "option",
});
const _componentPointSelectionStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "selectionStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                pointBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const PointSelectionStyle = Object.assign(_componentPointSelectionStyle, {
    componentType: "option",
});
const _componentReduction = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "reduction",
        },
    });
};
const Reduction = Object.assign(_componentReduction, {
    componentType: "option",
});
const _componentScrollBar = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "scrollBar",
        },
    });
};
const ScrollBar = Object.assign(_componentScrollBar, {
    componentType: "option",
});
const _componentSelectionStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "selectionStyle",
            ExpectedChildren: {
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                hatching: { optionName: "hatching", isCollectionItem: false },
                pointBorder: { optionName: "border", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false }
            },
        },
    });
};
const SelectionStyle = Object.assign(_componentSelectionStyle, {
    componentType: "option",
});
const _componentSeries = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "series",
            IsCollectionItem: true,
            ExpectedChildren: {
                aggregation: { optionName: "aggregation", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                color: { optionName: "color", isCollectionItem: false },
                commonSeriesSettingsHoverStyle: { optionName: "hoverStyle", isCollectionItem: false },
                commonSeriesSettingsLabel: { optionName: "label", isCollectionItem: false },
                commonSeriesSettingsSelectionStyle: { optionName: "selectionStyle", isCollectionItem: false },
                hoverStyle: { optionName: "hoverStyle", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                point: { optionName: "point", isCollectionItem: false },
                reduction: { optionName: "reduction", isCollectionItem: false },
                selectionStyle: { optionName: "selectionStyle", isCollectionItem: false },
                seriesBorder: { optionName: "border", isCollectionItem: false },
                valueErrorBar: { optionName: "valueErrorBar", isCollectionItem: false }
            },
        },
    });
};
const Series = Object.assign(_componentSeries, {
    componentType: "option",
});
const _componentSeriesBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const SeriesBorder = Object.assign(_componentSeriesBorder, {
    componentType: "option",
});
const _componentSeriesTemplate = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "seriesTemplate",
        },
    });
};
const SeriesTemplate = Object.assign(_componentSeriesTemplate, {
    componentType: "option",
});
const _componentShadow = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "shadow",
        },
    });
};
const Shadow = Object.assign(_componentShadow, {
    componentType: "option",
});
const _componentSize = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "size",
        },
    });
};
const Size = Object.assign(_componentSize, {
    componentType: "option",
});
const _componentStrip = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "strips",
            IsCollectionItem: true,
            ExpectedChildren: {
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const Strip = Object.assign(_componentStrip, {
    componentType: "option",
});
const _componentStripLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const StripLabel = Object.assign(_componentStripLabel, {
    componentType: "option",
});
const _componentStripStyle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "stripStyle",
            ExpectedChildren: {
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const StripStyle = Object.assign(_componentStripStyle, {
    componentType: "option",
});
const _componentStripStyleLabel = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "label",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const StripStyleLabel = Object.assign(_componentStripStyleLabel, {
    componentType: "option",
});
const _componentSubtitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "subtitle",
            ExpectedChildren: {
                font: { optionName: "font", isCollectionItem: false }
            },
        },
    });
};
const Subtitle = Object.assign(_componentSubtitle, {
    componentType: "option",
});
const _componentTick = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "tick",
        },
    });
};
const Tick = Object.assign(_componentTick, {
    componentType: "option",
});
const _componentTickInterval = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "tickInterval",
        },
    });
};
const TickInterval = Object.assign(_componentTickInterval, {
    componentType: "option",
});
const _componentTitle = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "title",
            ExpectedChildren: {
                chartTitleSubtitle: { optionName: "subtitle", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                legendTitleSubtitle: { optionName: "subtitle", isCollectionItem: false },
                margin: { optionName: "margin", isCollectionItem: false }
            },
        },
    });
};
const Title = Object.assign(_componentTitle, {
    componentType: "option",
});
const _componentTooltip = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "tooltip",
            ExpectedChildren: {
                argumentFormat: { optionName: "argumentFormat", isCollectionItem: false },
                border: { optionName: "border", isCollectionItem: false },
                font: { optionName: "font", isCollectionItem: false },
                format: { optionName: "format", isCollectionItem: false },
                shadow: { optionName: "shadow", isCollectionItem: false },
                tooltipBorder: { optionName: "border", isCollectionItem: false }
            },
            TemplateProps: [{
                    tmplOption: "contentTemplate",
                    render: "contentRender",
                    component: "contentComponent"
                }],
        },
    });
};
const Tooltip = Object.assign(_componentTooltip, {
    componentType: "option",
});
const _componentTooltipBorder = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "border",
        },
    });
};
const TooltipBorder = Object.assign(_componentTooltipBorder, {
    componentType: "option",
});
const _componentUrl = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "url",
        },
    });
};
const Url = Object.assign(_componentUrl, {
    componentType: "option",
});
const _componentValueAxis = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "valueAxis",
            IsCollectionItem: true,
            DefaultsProps: {
                defaultCategories: "categories",
                defaultVisualRange: "visualRange"
            },
            ExpectedChildren: {
                axisConstantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                axisLabel: { optionName: "label", isCollectionItem: false },
                axisTitle: { optionName: "title", isCollectionItem: false },
                break: { optionName: "breaks", isCollectionItem: true },
                breakStyle: { optionName: "breakStyle", isCollectionItem: false },
                constantLine: { optionName: "constantLines", isCollectionItem: true },
                constantLineStyle: { optionName: "constantLineStyle", isCollectionItem: false },
                grid: { optionName: "grid", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false },
                minorGrid: { optionName: "minorGrid", isCollectionItem: false },
                minorTick: { optionName: "minorTick", isCollectionItem: false },
                minorTickInterval: { optionName: "minorTickInterval", isCollectionItem: false },
                minVisualRangeLength: { optionName: "minVisualRangeLength", isCollectionItem: false },
                strip: { optionName: "strips", isCollectionItem: true },
                stripStyle: { optionName: "stripStyle", isCollectionItem: false },
                tick: { optionName: "tick", isCollectionItem: false },
                tickInterval: { optionName: "tickInterval", isCollectionItem: false },
                title: { optionName: "title", isCollectionItem: false },
                visualRange: { optionName: "visualRange", isCollectionItem: false },
                wholeRange: { optionName: "wholeRange", isCollectionItem: false }
            },
        },
    });
};
const ValueAxis = Object.assign(_componentValueAxis, {
    componentType: "option",
});
const _componentValueErrorBar = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "valueErrorBar",
        },
    });
};
const ValueErrorBar = Object.assign(_componentValueErrorBar, {
    componentType: "option",
});
const _componentVerticalLine = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "verticalLine",
            ExpectedChildren: {
                horizontalLineLabel: { optionName: "label", isCollectionItem: false },
                label: { optionName: "label", isCollectionItem: false }
            },
        },
    });
};
const VerticalLine = Object.assign(_componentVerticalLine, {
    componentType: "option",
});
const _componentVisualRange = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "visualRange",
            DefaultsProps: {
                defaultEndValue: "endValue",
                defaultStartValue: "startValue"
            },
            ExpectedChildren: {
                length: { optionName: "length", isCollectionItem: false }
            },
        },
    });
};
const VisualRange = Object.assign(_componentVisualRange, {
    componentType: "option",
});
const _componentWholeRange = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "wholeRange",
            DefaultsProps: {
                defaultEndValue: "endValue",
                defaultStartValue: "startValue"
            },
            ExpectedChildren: {
                length: { optionName: "length", isCollectionItem: false }
            },
        },
    });
};
const WholeRange = Object.assign(_componentWholeRange, {
    componentType: "option",
});
const _componentWidth = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "width",
        },
    });
};
const Width = Object.assign(_componentWidth, {
    componentType: "option",
});
const _componentZoomAndPan = (props) => {
    return React.createElement((NestedOption), {
        ...props,
        elementDescriptor: {
            OptionName: "zoomAndPan",
            ExpectedChildren: {
                dragBoxStyle: { optionName: "dragBoxStyle", isCollectionItem: false }
            },
        },
    });
};
const ZoomAndPan = Object.assign(_componentZoomAndPan, {
    componentType: "option",
});
export default Chart;
export { Chart, AdaptiveLayout, Aggregation, AggregationInterval, Animation, Annotation, AnnotationBorder, AnnotationImage, ArgumentAxis, ArgumentFormat, AxisConstantLineStyle, AxisConstantLineStyleLabel, AxisLabel, AxisTitle, BackgroundColor, Border, Break, BreakStyle, ChartTitle, ChartTitleSubtitle, Color, CommonAnnotationSettings, CommonAxisSettings, CommonAxisSettingsConstantLineStyle, CommonAxisSettingsConstantLineStyleLabel, CommonAxisSettingsLabel, CommonAxisSettingsTitle, CommonPaneSettings, CommonSeriesSettings, CommonSeriesSettingsHoverStyle, CommonSeriesSettingsLabel, CommonSeriesSettingsSelectionStyle, Connector, ConstantLine, ConstantLineLabel, ConstantLineStyle, Crosshair, DataPrepareSettings, DragBoxStyle, Export, Font, Format, Grid, Hatching, Height, HorizontalLine, HorizontalLineLabel, HoverStyle, Image, Label, Legend, LegendTitle, LegendTitleSubtitle, Length, LoadingIndicator, Margin, MinorGrid, MinorTick, MinorTickInterval, MinVisualRangeLength, Pane, PaneBorder, Point, PointBorder, PointHoverStyle, PointImage, PointSelectionStyle, Reduction, ScrollBar, SelectionStyle, Series, SeriesBorder, SeriesTemplate, Shadow, Size, Strip, StripLabel, StripStyle, StripStyleLabel, Subtitle, Tick, TickInterval, Title, Tooltip, TooltipBorder, Url, ValueAxis, ValueErrorBar, VerticalLine, VisualRange, WholeRange, Width, ZoomAndPan };