@progress/kendo-react-chart-wizard 9.4.0-develop.6 → 9.4.0-develop.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ChartWizard.js +1 -1
- package/ChartWizard.mjs +0 -1
- package/components/ChartComponent.js +1 -1
- package/components/ChartComponent.mjs +0 -1
- package/components/FormField.js +1 -1
- package/components/FormField.mjs +3 -4
- package/components/FormFieldSet.js +1 -1
- package/components/FormFieldSet.mjs +2 -3
- package/components/SeriesGrid.js +1 -1
- package/components/SeriesGrid.mjs +0 -1
- package/components/SeriesGridCells.js +1 -1
- package/components/SeriesGridCells.mjs +0 -1
- package/components/SeriesTypeButton.js +1 -1
- package/components/SeriesTypeButton.mjs +5 -6
- package/components/SeriesTypesWrap.js +1 -1
- package/components/SeriesTypesWrap.mjs +0 -1
- package/components/panels/BarChartPanel.js +1 -1
- package/components/panels/BarChartPanel.mjs +14 -15
- package/components/panels/CategoryAxisPanel.js +1 -1
- package/components/panels/CategoryAxisPanel.mjs +0 -1
- package/components/panels/ChartAreaPanel.js +1 -1
- package/components/panels/ChartAreaPanel.mjs +8 -9
- package/components/panels/ColumnChartPanel.js +1 -1
- package/components/panels/ColumnChartPanel.mjs +9 -10
- package/components/panels/ConfigurationPanel.js +1 -1
- package/components/panels/ConfigurationPanel.mjs +0 -1
- package/components/panels/LegendPanel.js +1 -1
- package/components/panels/LegendPanel.mjs +0 -1
- package/components/panels/LineChartPanel.js +1 -1
- package/components/panels/LineChartPanel.mjs +0 -1
- package/components/panels/PieChartPanel.js +1 -1
- package/components/panels/PieChartPanel.mjs +8 -9
- package/components/panels/ScatterChartPanel.js +1 -1
- package/components/panels/ScatterChartPanel.mjs +2 -3
- package/components/panels/SeriesPanel.js +1 -1
- package/components/panels/SeriesPanel.mjs +0 -1
- package/components/panels/TitlePanel.js +1 -1
- package/components/panels/TitlePanel.mjs +0 -1
- package/components/panels/ValueAxisPanel.js +1 -1
- package/components/panels/ValueAxisPanel.mjs +29 -30
- package/dist/cdn/js/kendo-react-chart-wizard.js +1 -1
- package/grid-integration/get-grid-selected-rows.js +1 -1
- package/grid-integration/get-grid-selected-rows.mjs +5 -6
- package/grid-integration/get-wizard-data-from-grid-selection.js +1 -1
- package/grid-integration/get-wizard-data-from-grid-selection.mjs +2 -3
- package/index.js +2 -1
- package/index.mjs +6 -6
- package/messages.js +1 -1
- package/messages.mjs +0 -1
- package/package.json +14 -14
- package/types/export.js +1 -1
- package/types/export.mjs +0 -1
- package/utils.js +1 -1
- package/utils.mjs +9 -10
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const y=require("react"),T=require("@progress/kendo-react-animation"),b=require("@progress/kendo-react-intl"),u=require("@progress/kendo-react-layout"),t=require("../../utils.js"),i=require("../../messages.js"),f=require("../SeriesTypesWrap.js"),o=require("../SeriesTypeButton.js"),l=require("@progress/kendo-svg-icons");function E(n){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const e in n)if(e!=="default"){const s=Object.getOwnPropertyDescriptor(n,e);Object.defineProperty(c,e,s.get?s:{enumerable:!0,get:()=>n[e]})}}return c.default=n,Object.freeze(c)}const a=E(y),q=n=>{const c=b.useLocalization(),e=n.state,s=e.seriesType,{isStackFalse:d,isStackNormal:g,isStack100:k}=t.stackState(e),[S,m]=a.useState(!0),p=a.useCallback(r=>{m(!r.expanded)},[]),h=()=>{n.onStateChange(t.mergeStates(e,t.createState(e.data,"line")))},L=()=>{const r=t.mergeStates(e,t.createState(e.data,"line"));n.onStateChange(t.updateState(r,t.ActionTypes.stacked,t.stackNormal))},C=()=>{const r=t.mergeStates(e,t.createState(e.data,"line"));n.onStateChange(t.updateState(r,t.ActionTypes.stacked,t.stack100))};return a.createElement(u.ExpansionPanel,{style:{maxWidth:"576px"},title:c.toLanguageString(i.lineChart,i.messages.lineChart),expanded:S,tabIndex:0,onAction:p},a.createElement(T.Reveal,null,S&&a.createElement(u.ExpansionPanelContent,null,a.createElement(f.SeriesTypesWrap,null,a.createElement(o.SeriesTypeButton,{selected:s==="line"&&d,onClick:h,icon:l.chartLineIcon,iconName:"chart-line"},c.toLanguageString(i.lineChartLine,i.messages.lineChartLine)),a.createElement(o.SeriesTypeButton,{selected:s==="line"&&g,onClick:L,icon:l.chartLineStackedIcon,iconName:"chart-line-stacked"},c.toLanguageString(i.lineChartStackedLine,i.messages.lineChartStackedLine)),a.createElement(o.SeriesTypeButton,{selected:s==="line"&&k,onClick:C,icon:l.chartLineStacked100Icon,iconName:"chart-line-stacked100"},c.toLanguageString(i.lineChart100StackedLine,i.messages.lineChart100StackedLine))))))};exports.LineChartPanel=q;
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import * as e from "react";
|
|
10
9
|
import { Reveal as E } from "@progress/kendo-react-animation";
|
|
11
10
|
import { useLocalization as f } from "@progress/kendo-react-intl";
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("react"),m=require("@progress/kendo-react-animation"),P=require("@progress/kendo-react-intl"),s=require("@progress/kendo-react-layout"),c=require("../../utils.js"),i=require("../../messages.js"),S=require("../SeriesTypesWrap.js"),y=require("../SeriesTypeButton.js"),h=require("@progress/kendo-svg-icons");function C(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const n=C(g),b=e=>{const a=P.useLocalization(),t=e.state,r=t.seriesType,[o,l]=n.useState(!0),u=n.useCallback(d=>{l(!d.expanded)},[]),p=()=>{e.onStateChange(c.mergeStates(t,c.createState(t.data,"pie")))};return n.createElement(s.ExpansionPanel,{style:{maxWidth:"576px"},title:a.toLanguageString(i.pieChart,i.messages.pieChart),expanded:o,tabIndex:0,onAction:u},n.createElement(m.Reveal,null,o&&n.createElement(s.ExpansionPanelContent,null,n.createElement(S.SeriesTypesWrap,null,n.createElement(y.SeriesTypeButton,{selected:r==="pie",onClick:p,icon:h.chartPieIcon,iconName:"chart-pie"},a.toLanguageString(i.pieChartPie,i.messages.pieChartPie))))))};exports.PieChartPanel=b;
|
|
@@ -5,21 +5,20 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import * as e from "react";
|
|
10
9
|
import { Reveal as l } from "@progress/kendo-react-animation";
|
|
11
10
|
import { useLocalization as d } from "@progress/kendo-react-intl";
|
|
12
|
-
import { ExpansionPanel as h, ExpansionPanelContent as
|
|
13
|
-
import { mergeStates as
|
|
11
|
+
import { ExpansionPanel as h, ExpansionPanelContent as C } from "@progress/kendo-react-layout";
|
|
12
|
+
import { mergeStates as u, createState as P } from "../../utils.mjs";
|
|
14
13
|
import { pieChart as x, messages as i, pieChartPie as f } from "../../messages.mjs";
|
|
15
14
|
import { SeriesTypesWrap as g } from "../SeriesTypesWrap.mjs";
|
|
16
15
|
import { SeriesTypeButton as S } from "../SeriesTypeButton.mjs";
|
|
17
16
|
import { chartPieIcon as E } from "@progress/kendo-svg-icons";
|
|
18
17
|
const R = (a) => {
|
|
19
|
-
const n = d(), t = a.state, o = t.seriesType, [r, s] = e.useState(!0), p = e.useCallback((
|
|
20
|
-
s(!
|
|
21
|
-
}, []),
|
|
22
|
-
a.onStateChange(
|
|
18
|
+
const n = d(), t = a.state, o = t.seriesType, [r, s] = e.useState(!0), p = e.useCallback((c) => {
|
|
19
|
+
s(!c.expanded);
|
|
20
|
+
}, []), m = () => {
|
|
21
|
+
a.onStateChange(u(t, P(t.data, "pie")));
|
|
23
22
|
};
|
|
24
23
|
return /* @__PURE__ */ e.createElement(
|
|
25
24
|
h,
|
|
@@ -30,11 +29,11 @@ const R = (a) => {
|
|
|
30
29
|
tabIndex: 0,
|
|
31
30
|
onAction: p
|
|
32
31
|
},
|
|
33
|
-
/* @__PURE__ */ e.createElement(l, null, r && /* @__PURE__ */ e.createElement(
|
|
32
|
+
/* @__PURE__ */ e.createElement(l, null, r && /* @__PURE__ */ e.createElement(C, null, /* @__PURE__ */ e.createElement(g, null, /* @__PURE__ */ e.createElement(
|
|
34
33
|
S,
|
|
35
34
|
{
|
|
36
35
|
selected: o === "pie",
|
|
37
|
-
onClick:
|
|
36
|
+
onClick: m,
|
|
38
37
|
icon: E,
|
|
39
38
|
iconName: "chart-pie"
|
|
40
39
|
},
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("react"),g=require("@progress/kendo-react-animation"),m=require("@progress/kendo-react-intl"),o=require("@progress/kendo-react-layout"),i=require("../../utils.js"),c=require("../../messages.js"),y=require("../SeriesTypesWrap.js"),h=require("../SeriesTypeButton.js"),C=require("@progress/kendo-svg-icons");function b(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const a=b(p),f=e=>{const n=m.useLocalization(),t=e.state,r=t.seriesType,[s,l]=a.useState(!0),u=a.useCallback(d=>{l(!d.expanded)},[]),S=()=>{e.onStateChange(i.mergeStates(t,i.createState(t.data,"scatter")))};return a.createElement(o.ExpansionPanel,{style:{maxWidth:"576px"},title:n.toLanguageString(c.scatterChart,c.messages.scatterChart),expanded:s,tabIndex:0,onAction:u},a.createElement(g.Reveal,null,s&&a.createElement(o.ExpansionPanelContent,null,a.createElement(y.SeriesTypesWrap,null,a.createElement(h.SeriesTypeButton,{selected:r==="scatter",onClick:S,icon:C.chartScatterIcon,iconName:"chart-scatter"},n.toLanguageString(c.scatterChartScatter,c.messages.scatterChartScatter))))))};exports.ScatterChartPanel=f;
|
|
@@ -5,12 +5,11 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import * as t from "react";
|
|
10
9
|
import { Reveal as p } from "@progress/kendo-react-animation";
|
|
11
10
|
import { useLocalization as S } from "@progress/kendo-react-intl";
|
|
12
11
|
import { ExpansionPanel as d, ExpansionPanelContent as h } from "@progress/kendo-react-layout";
|
|
13
|
-
import { mergeStates as
|
|
12
|
+
import { mergeStates as C, createState as u } from "../../utils.mjs";
|
|
14
13
|
import { scatterChart as x, messages as o, scatterChartScatter as f } from "../../messages.mjs";
|
|
15
14
|
import { SeriesTypesWrap as g } from "../SeriesTypesWrap.mjs";
|
|
16
15
|
import { SeriesTypeButton as E } from "../SeriesTypeButton.mjs";
|
|
@@ -19,7 +18,7 @@ const R = (a) => {
|
|
|
19
18
|
const r = S(), e = a.state, c = e.seriesType, [n, s] = t.useState(!0), i = t.useCallback((l) => {
|
|
20
19
|
s(!l.expanded);
|
|
21
20
|
}, []), m = () => {
|
|
22
|
-
a.onStateChange(
|
|
21
|
+
a.onStateChange(C(e, u(e.data, "scatter")));
|
|
23
22
|
};
|
|
24
23
|
return /* @__PURE__ */ t.createElement(
|
|
25
24
|
d,
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react"),y=require("@progress/kendo-react-layout"),F=require("@progress/kendo-react-form"),m=require("../FormField.js"),v=require("@progress/kendo-react-inputs"),n=require("../../utils.js"),o=require("../../messages.js"),q=require("@progress/kendo-react-intl"),T=require("@progress/kendo-react-dropdowns"),w=require("@progress/kendo-react-animation"),P=l=>{var g,p,f,b,C;const[s,d]=t.useState(""),r=q.useLocalization(),a=l.state,u=a.seriesType,E=typeof((g=a.series[0])==null?void 0:g.stack)=="object"?(p=a.series[0])==null?void 0:p.stack.type:!1,[S,h]=t.useState(!1),k=t.useCallback(e=>{h(!e.expanded)},[]),x=e=>{s&&l.onStateChange(n.updateState(a,n.ActionTypes.seriesColor,{seriesName:s,color:e.value}))},L=e=>{l.onStateChange(n.updateState(a,n.ActionTypes.seriesLabel,{seriesName:s,all:!s,visible:e.value}))},c={name:r.toLanguageString(o.formatSeriesAllSeries,o.messages.formatSeriesAllSeries)},A=e=>{const i=e.target.value.name;d(i===c.name?"":i)};return t.useEffect(()=>{d("")},[u,E]),t.createElement(y.ExpansionPanel,{style:{maxWidth:"576px"},title:r.toLanguageString(o.formatSeries,o.messages.formatSeries),expanded:S,tabIndex:0,onAction:k},t.createElement(w.Reveal,null,S&&t.createElement(y.ExpansionPanelContent,null,t.createElement(F.FormElement,{onKeyDown:n.stopPropagation},t.createElement(m.FormField,{editorId:"apply-to-series",labelText:r.toLanguageString(o.formatSeriesApplyTo,o.messages.formatSeriesApplyTo)},t.createElement(T.DropDownList,{id:"apply-to-series",data:a.series,textField:"name",dataItemKey:"name",defaultItem:c,disabled:!n.isCategorical(u),value:a.series.find(e=>e.name===s)||c,onChange:A,...n.dropdownlistCommonProps})),t.createElement(m.FormField,{editorId:"seriesColor",labelText:r.toLanguageString(o.formatSeriesColor,o.messages.formatSeriesColor)},t.createElement(v.ColorPicker,{id:"seriesColor",value:s?(f=a.series.find(e=>e.name===s))==null?void 0:f.color:"",onChange:x,disabled:!s,view:"gradient",fillMode:"outline"})),t.createElement(m.FormField,null,t.createElement(v.Checkbox,{label:r.toLanguageString(o.formatSeriesShowLabels,o.messages.formatSeriesShowLabels),checked:s?(C=(b=a.series.find(e=>e.name===s))==null?void 0:b.labels)==null?void 0:C.visible:a.series.every(e=>{var i;return(i=e.labels)==null?void 0:i.visible}),onChange:L}))))))};exports.SeriesPanel=P;
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import t from "react";
|
|
10
9
|
import { ExpansionPanel as k, ExpansionPanelContent as w } from "@progress/kendo-react-layout";
|
|
11
10
|
import { FormElement as T } from "@progress/kendo-react-form";
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("react"),p=require("@progress/kendo-react-layout"),k=require("@progress/kendo-react-form"),m=require("../FormField.js"),e=require("../../utils.js"),T=require("@progress/kendo-react-dropdowns"),f=require("@progress/kendo-react-inputs"),z=require("@progress/kendo-react-intl"),t=require("../../messages.js"),I=require("@progress/kendo-react-animation");function P(n){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const i in n)if(i!=="default"){const u=Object.getOwnPropertyDescriptor(n,i);Object.defineProperty(l,i,u.get?u:{enumerable:!0,get:()=>n[i]})}}return l.default=n,Object.freeze(l)}const a=P(E),A=n=>{const l=z.useLocalization(),i=n.state,[u,v]=a.useState(!1),S=a.useCallback(o=>{v(!o.expanded)},[]),r=[{value:"chartTitle",text:l.toLanguageString(t.formatTitleChartTitle,t.messages.formatTitleChartTitle)},{value:"chartSubtitle",text:l.toLanguageString(t.formatTitleChartSubtitle,t.messages.formatTitleChartSubtitle)}],[s,C]=a.useState(r[0]),x=a.useCallback(o=>{C(o.target.value)},[]),F=o=>{const c=s.value===r[0].value?e.ActionTypes.titleText:e.ActionTypes.subtitleText;n.onStateChange(e.updateState(i,c,o.target.value))},b=o=>{const c=s.value===r[0].value?e.ActionTypes.titleFontName:e.ActionTypes.subtitleFontName,g=o.target.value||e.nullItem;n.onStateChange(e.updateState(i,c,g.value))},h=o=>{const c=s.value===r[0].value?e.ActionTypes.titleFontSize:e.ActionTypes.subtitleFontSize,g=o.target.value||e.nullItem;e.ensureValue(g)&&n.onStateChange(e.updateState(i,c,g.value))},y=o=>{const c=s.value===r[0].value?e.ActionTypes.titleColor:e.ActionTypes.subtitleColor;n.onStateChange(e.updateState(i,c,o.value))},d=(s.value===r[0].value?i.title:i.subtitle)||{text:"",font:"",color:""};return a.createElement(p.ExpansionPanel,{style:{maxWidth:"576px"},title:l.toLanguageString(t.formatTitle,t.messages.formatTitle),expanded:u,tabIndex:0,onAction:S},a.createElement(I.Reveal,null,u&&a.createElement(p.ExpansionPanelContent,null,a.createElement(k.FormElement,{onKeyDown:e.stopPropagation},a.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},a.createElement(m.FormField,{className:"k-col-span-2",editorId:"apply-to-title",labelText:l.toLanguageString(t.formatTitleApplyTo,t.messages.formatTitleApplyTo)},a.createElement(T.DropDownList,{id:"apply-to-title",data:r,textField:"text",dataItemKey:"value",value:r.find(o=>o.value===s.value),onChange:x,...e.dropdownlistCommonProps})),a.createElement(m.FormField,{className:"k-col-span-2",editorId:"titleText",labelText:l.toLanguageString(t.formatTitleLabel,t.messages.formatTitleLabel)},a.createElement(f.Input,{id:"titleText",placeholder:s.value===r[0].value?r[0].text:r[1].text,value:d.text,onChange:F})),a.createElement(m.FormField,{className:"k-col-span-2",editorId:"titleFont",labelText:l.toLanguageString(t.formatTitleFont,t.messages.formatTitleFont)},a.createElement(T.ComboBox,{id:"titleFont",data:e.fontNames,textField:"text",dataItemKey:"value",placeholder:l.toLanguageString(t.formatTitleFontPlaceholder,t.messages.formatTitleFontPlaceholder),value:e.fontNames.find(o=>o.value===e.parseFont(d.font).name)||e.nullItem,onChange:b,itemRender:e.itemRender,...e.dropdownlistCommonProps})),a.createElement(m.FormField,{editorId:"titleFontSize",labelText:l.toLanguageString(t.formatTitleSize,t.messages.formatTitleSize)},a.createElement(T.ComboBox,{id:"titleFontSize",data:e.fontSizes,textField:"text",dataItemKey:"value",placeholder:l.toLanguageString(t.formatTitleSizePlaceholder,t.messages.formatTitleSizePlaceholder),value:e.fontSizes.find(o=>o.value===e.parseFont(d.font).size)||e.nullItem,onChange:h,itemRender:e.itemRender,allowCustom:!0,...e.dropdownlistCommonProps})),a.createElement(m.FormField,{editorId:"titleColor",labelText:l.toLanguageString(t.formatTitleColor,t.messages.formatTitleColor)},a.createElement(f.ColorPicker,{id:"titleColor",value:d.color||"",onChange:y,view:"gradient",fillMode:"outline"})))))))};exports.TitlePanel=A;
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import * as t from "react";
|
|
10
9
|
import { ExpansionPanel as P, ExpansionPanelContent as N } from "@progress/kendo-react-layout";
|
|
11
10
|
import { FormElement as A } from "@progress/kendo-react-form";
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react"),h=require("@progress/kendo-react-layout"),M=require("@progress/kendo-react-form"),E=require("../FormFieldSet.js"),m=require("../FormField.js"),g=require("@progress/kendo-react-inputs"),e=require("../../utils.js"),a=require("../../messages.js"),Y=require("@progress/kendo-react-intl"),j=require("@progress/kendo-react-animation"),x=require("@progress/kendo-react-dropdowns"),O=u=>{var f,v,F,b,L,S,V,C,T,p;const s=Y.useLocalization(),n=u.state,y=n.seriesType,d={text:s.toLanguageString(a.formatValueAxisLabelsFormatText,a.messages.formatValueAxisLabelsFormatText),value:""},c=[{value:"n0",text:s.toLanguageString(a.formatValueAxisLabelsFormatNumber,a.messages.formatValueAxisLabelsFormatNumber)},{value:"c0",text:s.toLanguageString(a.formatValueAxisLabelsFormatCurrency,a.messages.formatValueAxisLabelsFormatCurrency)},{value:"p0",text:s.toLanguageString(a.formatValueAxisLabelsFormatPercent,a.messages.formatValueAxisLabelsFormatPercent)}],[A,z]=l.useState(!1),I=l.useCallback(t=>{z(!t.expanded)},[]),P=t=>{u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisTitleText,t.target.value))},k=t=>{const o=t.target.value||e.nullItem;e.ensureValue(o)&&u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisTitleFontSize,o.value))},R=t=>{const o=t.target.value||e.nullItem;u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisTitleFontName,o.value))},N=t=>{u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisTitleColor,t.value))},w=t=>{const o=t.target.value||e.nullItem;e.ensureValue(o)&&u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisLabelsFontSize,o.value))},q=t=>{const o=t.target.value||e.nullItem;u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisLabelsFontName,o.value))},K=t=>{u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisLabelsColor,t.value))},B=t=>{u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisLabelsRotation,t.target.value))},D=t=>{const o=t.target.value;u.onStateChange(e.updateState(n,e.ActionTypes.valueAxisLabelsFormat,o.value))};return l.createElement(h.ExpansionPanel,{style:{maxWidth:"576px"},title:y==="scatter"?s.toLanguageString(a.formatYAxis,a.messages.formatYAxis):s.toLanguageString(a.formatValueAxis,a.messages.formatValueAxis),expanded:A,tabIndex:0,onAction:I},l.createElement(j.Reveal,null,A&&l.createElement(h.ExpansionPanelContent,null,l.createElement(M.FormElement,{onKeyDown:e.stopPropagation},l.createElement(E.FormFieldSet,{legend:s.toLanguageString(a.formatValueAxisTitle,a.messages.formatValueAxisTitle)},l.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},l.createElement(m.FormField,{className:"k-col-span-2"},l.createElement(g.Input,{placeholder:s.toLanguageString(a.formatValueAxisTitlePlaceholder,a.messages.formatValueAxisTitlePlaceholder),value:((v=(f=n.valueAxis[0])==null?void 0:f.title)==null?void 0:v.text)||"",onChange:P})),l.createElement(m.FormField,{className:"k-col-span-2",editorId:"valueAxisTitleFont",labelText:s.toLanguageString(a.formatValueAxisTitleFont,a.messages.formatValueAxisTitleFont)},l.createElement(x.ComboBox,{id:"valueAxisTitleFont",data:e.fontNames,textField:"text",dataItemKey:"value",itemRender:e.itemRender,placeholder:s.toLanguageString(a.formatValueAxisTitleFontPlaceholder,a.messages.formatValueAxisTitleFontPlaceholder),value:e.fontNames.find(t=>{var o,i,r;return t.value===((r=e.parseFont(((i=(o=n.valueAxis[0])==null?void 0:o.title)==null?void 0:i.font)||""))==null?void 0:r.name)})||e.nullItem,onChange:R,...e.dropdownlistCommonProps})),l.createElement(m.FormField,{editorId:"valueAxisTitleFontSize",labelText:s.toLanguageString(a.formatValueAxisTitleSize,a.messages.formatValueAxisTitleSize)},l.createElement(x.ComboBox,{id:"valueAxisTitleFontSize",data:e.fontSizes,textField:"text",dataItemKey:"value",placeholder:s.toLanguageString(a.formatValueAxisTitleSizePlaceholder,a.messages.formatValueAxisTitleSizePlaceholder),value:e.fontSizes.find(t=>{var o,i,r;return t.value===((r=e.parseFont(((i=(o=n.valueAxis[0])==null?void 0:o.title)==null?void 0:i.font)||""))==null?void 0:r.size)})||e.nullItem,onChange:k,allowCustom:!0,...e.dropdownlistCommonProps})),l.createElement(m.FormField,{editorId:"valueAxisTitleColor",labelText:s.toLanguageString(a.formatValueAxisTitleColor,a.messages.formatValueAxisTitleColor)},l.createElement(g.ColorPicker,{id:"valueAxisTitleColor",view:"gradient",value:((b=(F=n.valueAxis[0])==null?void 0:F.title)==null?void 0:b.color)||"",onChange:N,fillMode:"outline"})))),l.createElement(E.FormFieldSet,{legend:s.toLanguageString(a.formatValueAxisLabels,a.messages.formatValueAxisLabels)},l.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},l.createElement(m.FormField,{className:"k-col-span-2",editorId:"valueAxisLabelsFormat",labelText:s.toLanguageString(a.formatValueAxisLabelsFormat,a.messages.formatValueAxisLabelsFormat)},l.createElement(x.DropDownList,{id:"valueAxisLabelsFormat",data:c,textField:"text",dataItemKey:"value",defaultItem:d,value:c.find(t=>{var o,i;return t.value===((i=(o=n.valueAxis[0])==null?void 0:o.labels)==null?void 0:i.format)})||d,onChange:D,...e.dropdownlistCommonProps})),l.createElement(m.FormField,{className:"k-col-span-2",editorId:"valueAxisLabelsFont",labelText:s.toLanguageString(a.formatValueAxisLabelsFont,a.messages.formatValueAxisLabelsFont)},l.createElement(x.ComboBox,{id:"valueAxisLabelsFont",data:e.fontNames,textField:"text",dataItemKey:"value",placeholder:s.toLanguageString(a.formatValueAxisLabelsFontPlaceholder,a.messages.formatValueAxisLabelsFontPlaceholder),value:e.fontNames.find(t=>{var o,i,r;return t.value===((r=e.parseFont(((i=(o=n.valueAxis[0])==null?void 0:o.labels)==null?void 0:i.font)||""))==null?void 0:r.name)})||e.nullItem,onChange:q,itemRender:e.itemRender,...e.dropdownlistCommonProps})),l.createElement(m.FormField,{editorId:"valueAxisLabelsFontSize",labelText:s.toLanguageString(a.formatValueAxisLabelsSize,a.messages.formatValueAxisLabelsSize)},l.createElement(x.ComboBox,{id:"valueAxisLabelsFontSize",data:e.fontSizes,textField:"text",dataItemKey:"value",placeholder:s.toLanguageString(a.formatValueAxisLabelsSizePlaceholder,a.messages.formatValueAxisLabelsSizePlaceholder),value:e.fontSizes.find(t=>{var o,i,r;return t.value===((r=e.parseFont(((i=(o=n.valueAxis[0])==null?void 0:o.labels)==null?void 0:i.font)||""))==null?void 0:r.size)})||e.nullItem,onChange:w,allowCustom:!0,...e.dropdownlistCommonProps})),l.createElement(m.FormField,{editorId:"valueAxisLabelsColor",labelText:s.toLanguageString(a.formatValueAxisLabelsColor,a.messages.formatValueAxisLabelsColor)},l.createElement(g.ColorPicker,{id:"valueAxisLabelsColor",view:"gradient",value:((S=(L=n.valueAxis[0])==null?void 0:L.labels)==null?void 0:S.color)||"",onChange:K,fillMode:"outline"})),l.createElement(m.FormField,{editorId:"valueAxisLabelsRotation",labelText:s.toLanguageString(a.formatValueAxisLabelsRotation,a.messages.formatValueAxisLabelsRotation)},l.createElement(g.NumericTextBox,{id:"valueAxisLabelsRotation",value:typeof((C=(V=n.valueAxis[0])==null?void 0:V.labels)==null?void 0:C.rotation)=="number"?(p=(T=n.valueAxis[0])==null?void 0:T.labels)==null?void 0:p.rotation:null,placeholder:s.toLanguageString(a.formatValueAxisLabelsRotationAuto,a.messages.formatValueAxisLabelsRotationAuto),onChange:B,fillMode:"outline",min:-360,max:360,step:1}))))))))};exports.ValueAxisPanel=O;
|
|
@@ -5,21 +5,20 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use client";
|
|
9
8
|
import a from "react";
|
|
10
9
|
import { ExpansionPanel as J, ExpansionPanelContent as O } from "@progress/kendo-react-layout";
|
|
11
10
|
import { FormElement as Q } from "@progress/kendo-react-form";
|
|
12
11
|
import { FormFieldSet as N } from "../FormFieldSet.mjs";
|
|
13
12
|
import { FormField as u } from "../FormField.mjs";
|
|
14
13
|
import { Input as U, ColorPicker as y, NumericTextBox as X } from "@progress/kendo-react-inputs";
|
|
15
|
-
import { stopPropagation as Z, fontNames as
|
|
16
|
-
import { formatValueAxisLabelsFormatText as $, messages as o, formatValueAxisLabelsFormatNumber as ee, formatValueAxisLabelsFormatCurrency as ae, formatValueAxisLabelsFormatPercent as te, formatYAxis as le, formatValueAxis as oe, formatValueAxisTitle as ie, formatValueAxisTitlePlaceholder as ne, formatValueAxisTitleFont as
|
|
14
|
+
import { stopPropagation as Z, fontNames as d, itemRender as k, parseFont as c, nullItem as g, dropdownlistCommonProps as A, fontSizes as f, updateState as m, ActionTypes as x, ensureValue as R } from "../../utils.mjs";
|
|
15
|
+
import { formatValueAxisLabelsFormatText as $, messages as o, formatValueAxisLabelsFormatNumber as ee, formatValueAxisLabelsFormatCurrency as ae, formatValueAxisLabelsFormatPercent as te, formatYAxis as le, formatValueAxis as oe, formatValueAxisTitle as ie, formatValueAxisTitlePlaceholder as ne, formatValueAxisTitleFont as re, formatValueAxisTitleFontPlaceholder as se, formatValueAxisTitleSize as ue, formatValueAxisTitleSizePlaceholder as me, formatValueAxisTitleColor as xe, formatValueAxisLabels as ge, formatValueAxisLabelsFormat as Ae, formatValueAxisLabelsFont as de, formatValueAxisLabelsFontPlaceholder as ce, formatValueAxisLabelsSize as fe, formatValueAxisLabelsSizePlaceholder as ve, formatValueAxisLabelsColor as Le, formatValueAxisLabelsRotation as be, formatValueAxisLabelsRotationAuto as Ve } from "../../messages.mjs";
|
|
17
16
|
import { useLocalization as Se } from "@progress/kendo-react-intl";
|
|
18
17
|
import { Reveal as Fe } from "@progress/kendo-react-animation";
|
|
19
18
|
import { ComboBox as v, DropDownList as Ce } from "@progress/kendo-react-dropdowns";
|
|
20
|
-
const we = (
|
|
19
|
+
const we = (s) => {
|
|
21
20
|
var S, F, C, h, T, E, p, z, P, I;
|
|
22
|
-
const l = Se(), i =
|
|
21
|
+
const l = Se(), i = s.state, w = i.seriesType, L = {
|
|
23
22
|
text: l.toLanguageString($, o.formatValueAxisLabelsFormatText),
|
|
24
23
|
value: ""
|
|
25
24
|
}, b = [
|
|
@@ -47,28 +46,28 @@ const we = (r) => {
|
|
|
47
46
|
], [V, K] = a.useState(!1), D = a.useCallback((e) => {
|
|
48
47
|
K(!e.expanded);
|
|
49
48
|
}, []), M = (e) => {
|
|
50
|
-
|
|
49
|
+
s.onStateChange(m(i, x.valueAxisTitleText, e.target.value));
|
|
51
50
|
}, B = (e) => {
|
|
52
51
|
const t = e.target.value || g;
|
|
53
|
-
R(t) &&
|
|
52
|
+
R(t) && s.onStateChange(m(i, x.valueAxisTitleFontSize, t.value));
|
|
54
53
|
}, Y = (e) => {
|
|
55
54
|
const t = e.target.value || g;
|
|
56
|
-
|
|
55
|
+
s.onStateChange(m(i, x.valueAxisTitleFontName, t.value));
|
|
57
56
|
}, _ = (e) => {
|
|
58
|
-
|
|
57
|
+
s.onStateChange(m(i, x.valueAxisTitleColor, e.value));
|
|
59
58
|
}, W = (e) => {
|
|
60
59
|
const t = e.target.value || g;
|
|
61
|
-
R(t) &&
|
|
60
|
+
R(t) && s.onStateChange(m(i, x.valueAxisLabelsFontSize, t.value));
|
|
62
61
|
}, j = (e) => {
|
|
63
62
|
const t = e.target.value || g;
|
|
64
|
-
|
|
63
|
+
s.onStateChange(m(i, x.valueAxisLabelsFontName, t.value));
|
|
65
64
|
}, q = (e) => {
|
|
66
|
-
|
|
65
|
+
s.onStateChange(m(i, x.valueAxisLabelsColor, e.value));
|
|
67
66
|
}, G = (e) => {
|
|
68
|
-
|
|
67
|
+
s.onStateChange(m(i, x.valueAxisLabelsRotation, e.target.value));
|
|
69
68
|
}, H = (e) => {
|
|
70
69
|
const t = e.target.value;
|
|
71
|
-
|
|
70
|
+
s.onStateChange(m(i, x.valueAxisLabelsFormat, t.value));
|
|
72
71
|
};
|
|
73
72
|
return /* @__PURE__ */ a.createElement(
|
|
74
73
|
J,
|
|
@@ -103,7 +102,7 @@ const we = (r) => {
|
|
|
103
102
|
className: "k-col-span-2",
|
|
104
103
|
editorId: "valueAxisTitleFont",
|
|
105
104
|
labelText: l.toLanguageString(
|
|
106
|
-
|
|
105
|
+
re,
|
|
107
106
|
o.formatValueAxisTitleFont
|
|
108
107
|
)
|
|
109
108
|
},
|
|
@@ -111,18 +110,18 @@ const we = (r) => {
|
|
|
111
110
|
v,
|
|
112
111
|
{
|
|
113
112
|
id: "valueAxisTitleFont",
|
|
114
|
-
data:
|
|
113
|
+
data: d,
|
|
115
114
|
textField: "text",
|
|
116
115
|
dataItemKey: "value",
|
|
117
116
|
itemRender: k,
|
|
118
117
|
placeholder: l.toLanguageString(
|
|
119
|
-
|
|
118
|
+
se,
|
|
120
119
|
o.formatValueAxisTitleFontPlaceholder
|
|
121
120
|
),
|
|
122
|
-
value:
|
|
121
|
+
value: d.find(
|
|
123
122
|
(e) => {
|
|
124
|
-
var t, n,
|
|
125
|
-
return e.value === ((
|
|
123
|
+
var t, n, r;
|
|
124
|
+
return e.value === ((r = c(((n = (t = i.valueAxis[0]) == null ? void 0 : t.title) == null ? void 0 : n.font) || "")) == null ? void 0 : r.name);
|
|
126
125
|
}
|
|
127
126
|
) || g,
|
|
128
127
|
onChange: Y,
|
|
@@ -151,8 +150,8 @@ const we = (r) => {
|
|
|
151
150
|
),
|
|
152
151
|
value: f.find(
|
|
153
152
|
(e) => {
|
|
154
|
-
var t, n,
|
|
155
|
-
return e.value === ((
|
|
153
|
+
var t, n, r;
|
|
154
|
+
return e.value === ((r = c(((n = (t = i.valueAxis[0]) == null ? void 0 : t.title) == null ? void 0 : n.font) || "")) == null ? void 0 : r.size);
|
|
156
155
|
}
|
|
157
156
|
) || g,
|
|
158
157
|
onChange: B,
|
|
@@ -222,7 +221,7 @@ const we = (r) => {
|
|
|
222
221
|
className: "k-col-span-2",
|
|
223
222
|
editorId: "valueAxisLabelsFont",
|
|
224
223
|
labelText: l.toLanguageString(
|
|
225
|
-
|
|
224
|
+
de,
|
|
226
225
|
o.formatValueAxisLabelsFont
|
|
227
226
|
)
|
|
228
227
|
},
|
|
@@ -230,17 +229,17 @@ const we = (r) => {
|
|
|
230
229
|
v,
|
|
231
230
|
{
|
|
232
231
|
id: "valueAxisLabelsFont",
|
|
233
|
-
data:
|
|
232
|
+
data: d,
|
|
234
233
|
textField: "text",
|
|
235
234
|
dataItemKey: "value",
|
|
236
235
|
placeholder: l.toLanguageString(
|
|
237
|
-
|
|
236
|
+
ce,
|
|
238
237
|
o.formatValueAxisLabelsFontPlaceholder
|
|
239
238
|
),
|
|
240
|
-
value:
|
|
239
|
+
value: d.find(
|
|
241
240
|
(e) => {
|
|
242
|
-
var t, n,
|
|
243
|
-
return e.value === ((
|
|
241
|
+
var t, n, r;
|
|
242
|
+
return e.value === ((r = c(((n = (t = i.valueAxis[0]) == null ? void 0 : t.labels) == null ? void 0 : n.font) || "")) == null ? void 0 : r.name);
|
|
244
243
|
}
|
|
245
244
|
) || g,
|
|
246
245
|
onChange: j,
|
|
@@ -270,8 +269,8 @@ const we = (r) => {
|
|
|
270
269
|
),
|
|
271
270
|
value: f.find(
|
|
272
271
|
(e) => {
|
|
273
|
-
var t, n,
|
|
274
|
-
return e.value === ((
|
|
272
|
+
var t, n, r;
|
|
273
|
+
return e.value === ((r = c(((n = (t = i.valueAxis[0]) == null ? void 0 : t.labels) == null ? void 0 : n.font) || "")) == null ? void 0 : r.size);
|
|
275
274
|
}
|
|
276
275
|
) || g,
|
|
277
276
|
onChange: W,
|