@progress/kendo-react-chart-wizard
Version:
React Chart Wizard lets you create a chart using data from a Grid, another data-bound component, or an external source
47 lines (46 loc) • 1.81 kB
JavaScript
/**
* @license
*-------------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the package root for more information
*-------------------------------------------------------------------------------------------
*/
import * as t from "react";
import { Reveal as p } from "@progress/kendo-react-animation";
import { useLocalization as S } from "@progress/kendo-react-intl";
import { ExpansionPanel as d, ExpansionPanelContent as h } from "@progress/kendo-react-layout";
import { mergeStates as C, createState as u } from "../../utils.mjs";
import { scatterChart as x, messages as o, scatterChartScatter as f } from "../../messages.mjs";
import { SeriesTypesWrap as g } from "../SeriesTypesWrap.mjs";
import { SeriesTypeButton as E } from "../SeriesTypeButton.mjs";
import { chartScatterIcon as y } from "@progress/kendo-svg-icons";
const R = (a) => {
const r = S(), e = a.state, c = e.seriesType, [n, s] = t.useState(!0), i = t.useCallback((l) => {
s(!l.expanded);
}, []), m = () => {
a.onStateChange(C(e, u(e.data, "scatter")));
};
return /* @__PURE__ */ t.createElement(
d,
{
style: { maxWidth: "576px" },
title: r.toLanguageString(x, o.scatterChart),
expanded: n,
tabIndex: 0,
onAction: i
},
/* @__PURE__ */ t.createElement(p, null, n && /* @__PURE__ */ t.createElement(h, null, /* @__PURE__ */ t.createElement(g, null, /* @__PURE__ */ t.createElement(
E,
{
selected: c === "scatter",
onClick: m,
icon: y,
iconName: "chart-scatter"
},
r.toLanguageString(f, o.scatterChartScatter)
))))
);
};
export {
R as ScatterChartPanel
};