@progress/kendo-react-chart-wizard 8.3.0-develop.12 → 8.3.0-develop.13
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 +1559 -784
- package/SeriesGrid.js +1 -1
- package/SeriesGrid.mjs +37 -36
- package/chart-wizard-state.js +1 -1
- package/chart-wizard-state.mjs +11 -350
- package/common/get-wizard-data-from-data-rows.js +1 -1
- package/common/get-wizard-data-from-data-rows.mjs +3 -14
- package/dist/cdn/js/kendo-react-chart-wizard.js +1 -1
- package/grid-integration/get-wizard-data-from-grid-selection.js +1 -1
- package/grid-integration/get-wizard-data-from-grid-selection.mjs +4 -4
- package/index.d.mts +13 -189
- package/index.d.ts +13 -189
- package/index.js +1 -1
- package/index.mjs +8 -18
- package/messages.js +1 -1
- package/messages.mjs +109 -215
- package/package.json +15 -15
package/ChartWizard.js
CHANGED
|
@@ -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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Ia=require("react"),Na=require("@progress/kendo-react-dialogs"),p=require("@progress/kendo-react-charts"),m=require("@progress/kendo-react-layout"),Pa=require("@progress/kendo-react-buttons"),h=require("@progress/kendo-svg-icons"),L=require("@progress/kendo-react-animation"),C=require("@progress/kendo-react-dropdowns"),za=require("./SeriesGrid.js"),d=require("@progress/kendo-react-inputs"),He=require("@progress/kendo-react-labels"),l=require("./chart-wizard-state.js"),je=require("@progress/kendo-react-common"),I=require("@progress/kendo-react-form"),wa=require("@progress/kendo-react-intl"),e=require("./messages.js"),w=require("./export.js");function Va(r){const y=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const o in r)if(o!=="default"){const b=Object.getOwnPropertyDescriptor(r,o);Object.defineProperty(y,o,b.get?b:{enumerable:!0,get:()=>r[o]})}}return y.default=r,Object.freeze(y)}const t=Va(Ia),F=r=>t.createElement("fieldset",{className:"k-form-fieldset"},r.legend&&t.createElement("legend",{className:"k-form-legend"},r.legend),r.children),Ra=r=>{r.stopPropagation()},g=r=>t.createElement(I.FieldWrapper,{className:r.className},r.labelText&&r.editorId&&t.createElement(He.Label,{className:"k-form-label",editorId:r.editorId},r.labelText),t.createElement("div",{className:"k-form-field-wrap",onKeyDown:Ra},r.children)),u={value:null,text:""},Ba=/^\d+$/,N=(r,y)=>y.dataItem.style?t.cloneElement(r,r.props,t.createElement("span",{style:y.dataItem.style},r.props.children)):r,P=r=>{if(r.text==="")return!0;if(r.value===void 0){if(!Ba.test(r.text))return!1;r.value=r.text+"px"}return l.fontSizes.find(o=>o.value===r.value)||(l.fontSizes.push(r),l.fontSizes.sort((o,b)=>parseInt(o.text,10)-parseInt(b.text,10))),!0},k=r=>t.createElement("div",{className:je.classNames("k-icon-text-wrapper",{"k-selected":r.selected}),onClick:r.onClick},t.createElement("div",{className:"k-icon-background-area",tabIndex:0},t.createElement(je.IconWrap,{name:r.iconName,icon:r.icon,size:"xlarge",className:"k-svg-i-chart-bar-clustered"})),r.children),S={fillMode:"outline",popupSettings:{animate:!1}},q={type:"normal"},K={type:"100%"},Ye=t.forwardRef((r,y)=>{var le,oe,se,re,ie,ce,ge,me,ue,de,xe,Ce,Se,fe,be,pe,he,Ae,ve,Le,Ee,ke,ye,Te,Fe,Ie,Ne,Pe,ze,we,Ve,Re,Be,Me,De,We,qe,Ke,Oe,Ge,Xe;const o=wa.useLocalization(),b=[{value:"chartTitle",text:o.toLanguageString(e.formatTitleChartTitle,e.messages[e.formatTitleChartTitle])},{value:"chartSubtitle",text:o.toLanguageString(e.formatTitleChartSubtitle,e.messages[e.formatTitleChartSubtitle])}],O=[{value:"top",text:o.toLanguageString(e.formatLegendPositionTop,e.messages[e.formatLegendPositionTop])},{value:"bottom",text:o.toLanguageString(e.formatLegendPositionBottom,e.messages[e.formatLegendPositionBottom])},{value:"left",text:o.toLanguageString(e.formatLegendPositionLeft,e.messages[e.formatLegendPositionLeft])},{value:"right",text:o.toLanguageString(e.formatLegendPositionRight,e.messages[e.formatLegendPositionRight])}],B={name:o.toLanguageString(e.formatSeriesAllSeries,e.messages[e.formatSeriesAllSeries])},G={text:o.toLanguageString(e.formatValueAxisLabelsFormatText,e.messages[e.formatValueAxisLabelsFormatText]),value:""},X=[{value:"n0",text:o.toLanguageString(e.formatValueAxisLabelsFormatNumber,e.messages[e.formatValueAxisLabelsFormatNumber])},{value:"c0",text:o.toLanguageString(e.formatValueAxisLabelsFormatCurrency,e.messages[e.formatValueAxisLabelsFormatCurrency])},{value:"p0",text:o.toLanguageString(e.formatValueAxisLabelsFormatPercent,e.messages[e.formatValueAxisLabelsFormatPercent])}],V=t.useRef(null),_e=t.useCallback(a=>{var s;if(V.current){const c=new w.ExportEvent(V.current,w.resolveExportOptions(r.exportOptions));(s=r.onExport)==null||s.call(r,c),c.isDefaultPrevented()||a.item.exportHandler.call(void 0,c)}},[r.exportOptions]),[Ue,$e]=t.useState({width:700,height:550}),[Je,Qe]=t.useState("DEFAULT"),Ze=t.useCallback(a=>{$e({width:a.width,height:a.height})},[]),et=t.useCallback(a=>{Qe(a.state)},[]),[tt,at]=t.useState([{collapsible:!1},{size:"300px",collapsible:!1}]),nt=t.useCallback(a=>{at(a.newState)},[]),[j,lt]=t.useState(!0),ot=t.useCallback(a=>{lt(!a.expanded)},[]),[H,st]=t.useState(!0),rt=t.useCallback(a=>{st(!a.expanded)},[]),[Y,it]=t.useState(!0),ct=t.useCallback(a=>{it(!a.expanded)},[]),[_,gt]=t.useState(!0),mt=t.useCallback(a=>{gt(!a.expanded)},[]),[U,ut]=t.useState(!0),dt=t.useCallback(a=>{ut(!a.expanded)},[]),[$,xt]=t.useState(!0),Ct=t.useCallback(a=>{xt(!a.expanded)},[]),[J,St]=t.useState(!1),ft=t.useCallback(a=>{St(!a.expanded)},[]),[Q,bt]=t.useState(!1),pt=t.useCallback(a=>{bt(!a.expanded)},[]),[Z,ht]=t.useState(!1),At=t.useCallback(a=>{ht(!a.expanded)},[]),[ee,vt]=t.useState(!1),Lt=t.useCallback(a=>{vt(!a.expanded)},[]),[te,Et]=t.useState(!1),kt=t.useCallback(a=>{Et(!a.expanded)},[]),[ae,yt]=t.useState(!1),Tt=t.useCallback(a=>{yt(!a.expanded)},[]),[Ft,It]=t.useState(0),Nt=t.useCallback(a=>{It(a.selected)},[]),[n,i]=t.useState(l.createInitialState(r.data,"bar",r.defaultState)),ne=t.useRef(n);ne.current=n;const Pt=t.useCallback(()=>({get chart(){return V.current},get state(){return ne.current}}),[]);t.useImperativeHandle(y,Pt);const[A,v]=t.useState(""),zt=t.useCallback(a=>{const s=a.target.value.name;v(s===B.name?"":s)},[]),wt=t.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"bar"))),v("")},[n,r.data]),Vt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"bar"));i(l.updateState(a,l.ActionTypes.stacked,q)),v("")},[n,r.data]),Rt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"bar"));i(l.updateState(a,l.ActionTypes.stacked,K)),v("")},[n,r.data]),Bt=t.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"column"))),v("")},[n,r.data]),Mt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"column"));i(l.updateState(a,l.ActionTypes.stacked,q)),v("")},[n,r.data]),Dt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"column"));i(l.updateState(a,l.ActionTypes.stacked,K)),v("")},[n,r.data]),Wt=t.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"line"))),v("")},[n,r.data]),qt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"line"));i(l.updateState(a,l.ActionTypes.stacked,q)),v("")},[n,r.data]),Kt=t.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"line"));i(l.updateState(a,l.ActionTypes.stacked,K)),v("")},[n,r.data]),Ot=t.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"pie"))),v("")},[n,r.data]),Gt=t.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"scatter"))),v("")},[n,r.data]),Xt=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisX,a.target.value))},[n]),jt=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.seriesChange,a))},[n]),Ht=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisY,a.target.value))},[n]),Yt=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginLeft,a.target.value))},[n]),_t=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginRight,a.target.value))},[n]),Ut=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginTop,a.target.value))},[n]),$t=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginBottom,a.target.value))},[n]),T=n.area.margin,Jt=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaBackground,a.value))},[n]),[E,Qt]=t.useState(b[0]),Zt=t.useCallback(a=>{Qt(a.target.value)},[]),ea=t.useCallback(a=>{const s=E.value===b[0].value?l.ActionTypes.titleText:l.ActionTypes.subtitleText;i(l.updateState(n,s,a.target.value))},[n,E]),ta=t.useCallback(a=>{const s=E.value===b[0].value?l.ActionTypes.titleFontName:l.ActionTypes.subtitleFontName,c=a.target.value||u;i(l.updateState(n,s,c.value))},[n,E]),aa=t.useCallback(a=>{const s=E.value===b[0].value?l.ActionTypes.titleFontSize:l.ActionTypes.subtitleFontSize,c=a.target.value||u;P(c)&&i(l.updateState(n,s,c.value))},[n,E]),na=t.useCallback(a=>{const s=E.value===b[0].value?l.ActionTypes.titleColor:l.ActionTypes.subtitleColor;i(l.updateState(n,s,a.value))},[n,E]),R=(E.value===b[0].value?n.title:n.subtitle)||{text:"",font:"",color:""},la=t.useCallback(a=>{A&&i(l.updateState(n,l.ActionTypes.seriesColor,{seriesName:A,color:a.value}))},[n,A]),oa=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.seriesLabel,{seriesName:A,all:!A,visible:a.value}))},[n,A]),sa=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.legendVisible,a.value))},[n]),ra=t.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.legendFontSize,s.value))},[n]),ia=t.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.legendFontName,s.value))},[n]),ca=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.legendColor,a.value))},[n]),ga=t.useCallback(a=>{const s=a.target.value;i(l.updateState(n,l.ActionTypes.legendPosition,s.value))},[n]),ma=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisTitleText,a.target.value))},[n]),ua=t.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.categoryAxisTitleFontSize,s.value))},[n]),da=t.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.categoryAxisTitleFontName,s.value))},[n]),xa=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisTitleColor,a.value))},[n]),Ca=t.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.categoryAxisLabelsFontSize,s.value))},[n]),Sa=t.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.categoryAxisLabelsFontName,s.value))},[n]),fa=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisLabelsColor,a.value))},[n]),ba=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisLabelsRotation,a.target.value))},[n]),pa=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisReverseOrder,a.value))},[n]),ha=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisTitleText,a.target.value))},[n]),Aa=t.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.valueAxisTitleFontSize,s.value))},[n]),va=t.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.valueAxisTitleFontName,s.value))},[n]),La=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisTitleColor,a.value))},[n]),Ea=t.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.valueAxisLabelsFontSize,s.value))},[n]),ka=t.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.valueAxisLabelsFontName,s.value))},[n]),ya=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisLabelsColor,a.value))},[n]),Ta=t.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisLabelsRotation,a.target.value))},[n]),Fa=t.useCallback(a=>{const s=a.target.value;i(l.updateState(n,l.ActionTypes.valueAxisLabelsFormat,s.value))},[n]),x=n.seriesType,z=typeof((le=n.series[0])==null?void 0:le.stack)=="object"?(oe=n.series[0])==null?void 0:oe.stack:!1,M=z===!1,D=z&&z.type==="normal",W=z&&z.type==="100%";return t.createElement(Na.Window,{title:o.toLanguageString(e.windowTitle,e.messages[e.windowTitle]),className:"k-chart-wizard",modal:!0,resizable:!0,minimizeButton:()=>null,onClose:r.onClose,onResize:Ze,stage:Je,onStageChange:et,...Ue},t.createElement(m.Splitter,{panes:tt,onChange:nt,className:"k-chart-wizard-splitter"},t.createElement("div",{className:"k-chart-wizard-preview-pane k-pane"},t.createElement("div",{className:"k-preview-pane-header"},t.createElement(Pa.DropDownButton,{text:o.toLanguageString(e.exportButton,e.messages[e.exportButton]),fillMode:"flat",svgIcon:h.exportIcon,icon:"export",onItemClick:_e,items:[{svgIcon:h.filePdfIcon,icon:"file-pdf",exportHandler:w.handlePDFExport,text:o.toLanguageString(e.exportPDFButton,e.messages[e.exportPDFButton])},{svgIcon:h.fileIcon,icon:"file",exportHandler:w.handleSVGExport,text:o.toLanguageString(e.exportSVGButton,e.messages[e.exportSVGButton])},{svgIcon:h.fileImageIcon,icon:"file-image",exportHandler:w.handleImageExport,text:o.toLanguageString(e.exportPNGButton,e.messages[e.exportPNGButton])}]})),t.createElement("div",{className:"k-preview-pane-content",style:{height:"calc(100% - 50px)"}},t.createElement(p.Chart,{style:{width:"100%",height:"100%"},transitions:!1,ref:V},t.createElement(p.ChartTitle,{text:(se=n.title)==null?void 0:se.text,font:(re=n.title)==null?void 0:re.font,color:((ie=n.title)==null?void 0:ie.color)||"#000"}),t.createElement(p.ChartSubtitle,{text:(ce=n.subtitle)==null?void 0:ce.text,font:(ge=n.subtitle)==null?void 0:ge.font,color:((me=n.subtitle)==null?void 0:me.color)||"#000"}),t.createElement(p.ChartArea,{background:(ue=n.area)==null?void 0:ue.background,margin:T}),n.categoryAxis&&t.createElement(p.ChartCategoryAxis,null,n.categoryAxis.map((a,s)=>t.createElement(p.ChartCategoryAxisItem,{key:s,categories:a.categories,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{font:a.labels.font,color:a.labels.color,rotation:a.labels.rotation},reverse:a.reverse}))),n.valueAxis&&t.createElement(p.ChartValueAxis,null,n.valueAxis.map((a,s)=>t.createElement(p.ChartValueAxisItem,{key:s,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{format:a.labels.format,font:a.labels.font,color:a.labels.color,rotation:a.labels.rotation}}))),t.createElement(p.ChartSeries,null,n.series.map((a,s)=>t.createElement(p.ChartSeriesItem,{key:String(a.name)+s,...a}))),t.createElement(p.ChartXAxis,null,n.categoryAxis.map((a,s)=>t.createElement(p.ChartXAxisItem,{key:s,categories:a.categories,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{font:a.labels.font,color:a.labels.color,format:a.labels.format,rotation:a.labels.rotation}}))),t.createElement(p.ChartYAxis,null,n.valueAxis.map((a,s)=>t.createElement(p.ChartYAxisItem,{key:s,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{format:a.labels.format,font:a.labels.font,color:a.labels.color,rotation:a.labels.rotation}}))),t.createElement(p.ChartLegend,{visible:(de=n.legend)==null?void 0:de.visible,position:(xe=n.legend)==null?void 0:xe.position,labels:{color:((Se=(Ce=n.legend)==null?void 0:Ce.labels)==null?void 0:Se.color)||void 0,font:((be=(fe=n.legend)==null?void 0:fe.labels)==null?void 0:be.font)||void 0}})))),t.createElement("div",{className:"k-chart-wizard-property-pane k-pane k-pane-static"},t.createElement(m.TabStrip,{selected:Ft,onSelect:Nt,animation:!1},t.createElement(m.TabStripTab,{title:o.toLanguageString(e.tabChart,e.messages[e.tabChart])},t.createElement("div",null,t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.barChart,e.messages[e.barChart]),expanded:j,tabIndex:0,onAction:ot},t.createElement(L.Reveal,null,j&&t.createElement(m.ExpansionPanelContent,null,t.createElement("div",{className:"k-chart-types-wrapper"},t.createElement(k,{selected:x==="bar"&&M,onClick:wt,icon:h.chartBarClusteredIcon,iconName:"chart-bar-clustered"},o.toLanguageString(e.barChartBar,e.messages[e.barChartBar])),t.createElement(k,{selected:x==="bar"&&D,onClick:Vt,icon:h.chartBarStackedIcon,iconName:"chart-bar-stacked"},o.toLanguageString(e.barChartStackedBar,e.messages[e.barChartStackedBar])),t.createElement(k,{selected:x==="bar"&&W,onClick:Rt,icon:h.chartBarStacked100Icon,iconName:"chart-bar-stacked100"},o.toLanguageString(e.barChart100StackedBar,e.messages[e.barChart100StackedBar])))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.pieChart,e.messages[e.pieChart]),expanded:H,tabIndex:0,onAction:rt},t.createElement(L.Reveal,null,H&&t.createElement(m.ExpansionPanelContent,null,t.createElement("div",{className:"k-chart-types-wrapper"},t.createElement(k,{selected:x==="pie",onClick:Ot,icon:h.chartPieIcon,iconName:"chart-pie"},o.toLanguageString(e.pieChartPie,e.messages[e.pieChartPie])))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.columnChart,e.messages[e.columnChart]),expanded:Y,tabIndex:0,onAction:ct},t.createElement(L.Reveal,null,Y&&t.createElement(m.ExpansionPanelContent,null,t.createElement("div",{className:"k-chart-types-wrapper"},t.createElement(k,{selected:x==="column"&&M,onClick:Bt,icon:h.chartColumnClusteredIcon,iconName:"chart-column-clustered"},o.toLanguageString(e.columnChartColumn,e.messages[e.columnChartColumn])),t.createElement(k,{selected:x==="column"&&D,onClick:Mt,icon:h.chartColumnStackedIcon,iconName:"chart-column-stacked"},o.toLanguageString(e.columnChartStackedColumn,e.messages[e.columnChartStackedColumn])),t.createElement(k,{selected:x==="column"&&W,onClick:Dt,icon:h.chartColumnStacked100Icon,iconName:"chart-column-stacked100"},o.toLanguageString(e.columnChart100StackedColumn,e.messages[e.columnChart100StackedColumn])))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.lineChart,e.messages[e.lineChart]),expanded:_,tabIndex:0,onAction:mt},t.createElement(L.Reveal,null,_&&t.createElement(m.ExpansionPanelContent,null,t.createElement("div",{className:"k-chart-types-wrapper"},t.createElement(k,{selected:x==="line"&&M,onClick:Wt,icon:h.chartLineIcon,iconName:"chart-line"},o.toLanguageString(e.lineChartLine,e.messages[e.lineChartLine])),t.createElement(k,{selected:x==="line"&&D,onClick:qt,icon:h.chartLineStackedIcon,iconName:"chart-line-stacked"},o.toLanguageString(e.lineChartStackedLine,e.messages[e.lineChartStackedLine])),t.createElement(k,{selected:x==="line"&&W,onClick:Kt,icon:h.chartLineStacked100Icon,iconName:"chart-line-stacked100"},o.toLanguageString(e.lineChart100StackedLine,e.messages[e.lineChart100StackedLine])))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.scatterChart,e.messages[e.scatterChart]),expanded:U,tabIndex:0,onAction:dt},t.createElement(L.Reveal,null,U&&t.createElement(m.ExpansionPanelContent,null,t.createElement("div",{className:"k-chart-types-wrapper"},t.createElement(k,{selected:x==="scatter",onClick:Gt,icon:h.chartScatterIcon,iconName:"chart-scatter"},o.toLanguageString(e.scatterChartScatter,e.messages[e.scatterChartScatter])))))))),t.createElement(m.TabStripTab,{title:o.toLanguageString(e.tabData,e.messages[e.tabData])},t.createElement("div",null,t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.configuration,e.messages[e.configuration]),expanded:$,tabIndex:0,onAction:Ct},t.createElement(L.Reveal,null,$&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement(F,{legend:x==="scatter"?o.toLanguageString(e.configurationXAxis,e.messages[e.configurationXAxis]):o.toLanguageString(e.configurationCategoryAxis,e.messages[e.configurationCategoryAxis])},t.createElement(C.DropDownList,{data:n.columns||[],value:n.categoryField,onChange:Xt,...S})),l.isCategorical(x)&&t.createElement(F,{legend:o.toLanguageString(e.configurationSeries,e.messages[e.configurationSeries])},t.createElement(za.SeriesGrid,{data:n.series,initialData:n.initialSeries,onChange:jt})),x==="pie"&&t.createElement(F,{legend:o.toLanguageString(e.configurationValueAxis,e.messages[e.configurationValueAxis])},t.createElement(C.DropDownList,{data:n.columns||[],value:n.valueField||"",...S,onChange:Ht})))))))),t.createElement(m.TabStripTab,{title:o.toLanguageString(e.tabFormat,e.messages[e.tabFormat])},t.createElement("div",null,t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.formatChartArea,e.messages[e.formatChartArea]),expanded:J,tabIndex:0,onAction:ft},t.createElement(L.Reveal,null,J&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement(F,{legend:o.toLanguageString(e.formatChartAreaMargins,e.messages[e.formatChartAreaMargins])},t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{labelText:o.toLanguageString(e.formatChartAreaMarginsLeft,e.messages[e.formatChartAreaMarginsLeft]),editorId:"left"},t.createElement(d.NumericTextBox,{id:"left",value:T.left!==void 0?T.left:null,onChange:Yt,placeholder:o.toLanguageString(e.formatChartAreaMarginsAuto,e.messages[e.formatChartAreaMarginsAuto]),min:0,max:1e3,step:1,fillMode:"outline"})),t.createElement(g,{labelText:o.toLanguageString(e.formatChartAreaMarginsRight,e.messages[e.formatChartAreaMarginsRight]),editorId:"right"},t.createElement(d.NumericTextBox,{id:"right",value:T.right!==void 0?T.right:null,onChange:_t,placeholder:o.toLanguageString(e.formatChartAreaMarginsAuto,e.messages[e.formatChartAreaMarginsAuto]),min:0,max:1e3,step:1,fillMode:"outline"})),t.createElement(g,{labelText:o.toLanguageString(e.formatChartAreaMarginsTop,e.messages[e.formatChartAreaMarginsTop]),editorId:"top"},t.createElement(d.NumericTextBox,{id:"top",value:T.top!==void 0?T.top:null,onChange:Ut,placeholder:o.toLanguageString(e.formatChartAreaMarginsAuto,e.messages[e.formatChartAreaMarginsAuto]),min:0,max:1e3,step:1,fillMode:"outline"})),t.createElement(g,{labelText:o.toLanguageString(e.formatChartAreaMarginsBottom,e.messages[e.formatChartAreaMarginsBottom]),editorId:"bottom"},t.createElement(d.NumericTextBox,{id:"bottom",value:T.bottom!==void 0?T.bottom:null,onChange:$t,placeholder:o.toLanguageString(e.formatChartAreaMarginsAuto,e.messages[e.formatChartAreaMarginsAuto]),min:0,max:1e3,step:1,fillMode:"outline"})))),t.createElement(F,{legend:o.toLanguageString(e.formatChartAreaBackground,e.messages[e.formatChartAreaBackground])},t.createElement(g,{labelText:o.toLanguageString(e.formatChartAreaBackgroundColor,e.messages[e.formatChartAreaBackgroundColor]),editorId:"background"},t.createElement(d.ColorPicker,{id:"background",value:((pe=n.area)==null?void 0:pe.background)||"",onChange:Jt,view:"gradient",fillMode:"outline"}))))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.formatTitle,e.messages[e.formatTitle]),expanded:Q,tabIndex:0,onAction:pt},t.createElement(L.Reveal,null,Q&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{className:"k-col-span-2",editorId:"apply-to-title",labelText:o.toLanguageString(e.formatTitleApplyTo,e.messages[e.formatTitleApplyTo])},t.createElement(C.DropDownList,{id:"apply-to-title",data:b,textField:"text",dataItemKey:"value",value:b.find(a=>a.value===E.value),onChange:Zt,...S})),t.createElement(g,{className:"k-col-span-2",editorId:"titleText",labelText:o.toLanguageString(e.formatTitleLabel,e.messages[e.formatTitleLabel])},t.createElement(d.Input,{id:"titleText",placeholder:E.value===b[0].value?b[0].text:b[1].text,value:R.text,onChange:ea})),t.createElement(g,{className:"k-col-span-2",editorId:"titleFont",labelText:o.toLanguageString(e.formatTitleFont,e.messages[e.formatTitleFont])},t.createElement(C.ComboBox,{id:"titleFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatTitleFontPlaceholder,e.messages[e.formatTitleFontPlaceholder]),value:l.fontNames.find(a=>a.value===l.parseFont(R.font).name)||u,onChange:ta,itemRender:N,...S})),t.createElement(g,{editorId:"titleFontSize",labelText:o.toLanguageString(e.formatTitleSize,e.messages[e.formatTitleSize])},t.createElement(C.ComboBox,{id:"titleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatTitleSizePlaceholder,e.messages[e.formatTitleSizePlaceholder]),value:l.fontSizes.find(a=>a.value===l.parseFont(R.font).size)||u,onChange:aa,itemRender:N,allowCustom:!0,...S})),t.createElement(g,{editorId:"titleColor",labelText:o.toLanguageString(e.formatTitleColor,e.messages[e.formatTitleColor])},t.createElement(d.ColorPicker,{id:"titleColor",value:R.color||"",onChange:na,view:"gradient",fillMode:"outline"}))))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.formatSeries,e.messages[e.formatSeries]),expanded:Z,tabIndex:0,onAction:At},t.createElement(L.Reveal,null,Z&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement(g,{editorId:"apply-to-series",labelText:o.toLanguageString(e.formatSeriesApplyTo,e.messages[e.formatSeriesApplyTo])},t.createElement(C.DropDownList,{id:"apply-to-series",data:n.series,textField:"name",dataItemKey:"name",defaultItem:B,disabled:!l.isCategorical(x),value:n.series.find(a=>a.name===A)||B,onChange:zt,...S})),t.createElement(g,{editorId:"seriesColor",labelText:o.toLanguageString(e.formatSeriesColor,e.messages[e.formatSeriesColor])},t.createElement(d.ColorPicker,{id:"seriesColor",value:A?(he=n.series.find(a=>a.name===A))==null?void 0:he.color:"",onChange:la,disabled:!A,view:"gradient",fillMode:"outline"})),t.createElement(g,null,t.createElement(d.Checkbox,{label:o.toLanguageString(e.formatSeriesShowLabels,e.messages[e.formatSeriesShowLabels]),checked:A?(ve=(Ae=n.series.find(a=>a.name===A))==null?void 0:Ae.labels)==null?void 0:ve.visible:n.series.every(a=>{var s;return(s=a.labels)==null?void 0:s.visible}),onChange:oa})))))),t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(e.formatLegend,e.messages[e.formatLegend]),expanded:ee,tabIndex:0,onAction:Lt},t.createElement(L.Reveal,null,ee&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(He.Label,{editorId:"show-legend"},o.toLanguageString(e.formatLegendShowLegend,e.messages[e.formatLegendShowLegend])),t.createElement(d.Switch,{id:"show-legend",checked:(Le=n.legend)==null?void 0:Le.visible,onChange:sa}),t.createElement(g,{className:"k-col-span-2",editorId:"legendLabelsFont",labelText:o.toLanguageString(e.formatLegendFont,e.messages[e.formatLegendFont])},t.createElement(C.ComboBox,{id:"legendLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatLegendFontPlaceholder,e.messages[e.formatLegendFontPlaceholder]),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.legend)==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:ia,itemRender:N,disabled:((Ee=n.legend)==null?void 0:Ee.visible)===!1,...S})),t.createElement(g,{editorId:"legendLabelsSize",labelText:o.toLanguageString(e.formatLegendSize,e.messages[e.formatLegendSize])},t.createElement(C.ComboBox,{id:"legendLabelsSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatLegendSizePlaceholder,e.messages[e.formatLegendSizePlaceholder]),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.legend)==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:ra,disabled:((ke=n.legend)==null?void 0:ke.visible)===!1,allowCustom:!0,...S})),t.createElement(g,{editorId:"legendLabelsColor",labelText:o.toLanguageString(e.formatLegendColor,e.messages[e.formatLegendColor])},t.createElement(d.ColorPicker,{id:"legendLabelsColor",value:((Te=(ye=n.legend)==null?void 0:ye.labels)==null?void 0:Te.color)||"",onChange:ca,disabled:((Fe=n.legend)==null?void 0:Fe.visible)===!1,view:"gradient",fillMode:"outline"})),t.createElement(g,{className:"k-col-span-2",editorId:"legendPosition",labelText:o.toLanguageString(e.formatLegendPosition,e.messages[e.formatLegendPosition])},t.createElement(C.DropDownList,{id:"legendPosition",data:O,textField:"text",dataItemKey:"value",value:O.find(a=>{var s;return a.value===((s=n.legend)==null?void 0:s.position)}),onChange:ga,disabled:((Ie=n.legend)==null?void 0:Ie.visible)===!1,...S}))))))),x!=="pie"&&t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:x==="scatter"?o.toLanguageString(e.formatXAxis,e.messages[e.formatXAxis]):o.toLanguageString(e.formatCategoryAxis,e.messages[e.formatCategoryAxis]),expanded:te,tabIndex:0,onAction:kt},t.createElement(L.Reveal,null,te&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement(F,{legend:o.toLanguageString(e.formatCategoryAxisTitle,e.messages[e.formatCategoryAxisTitle])},t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{className:"k-col-span-2"},t.createElement(d.Input,{placeholder:o.toLanguageString(e.formatCategoryAxisTitlePlaceholder,e.messages[e.formatCategoryAxisTitlePlaceholder]),value:((Ne=n.categoryAxis[0].title)==null?void 0:Ne.text)||"",onChange:ma})),t.createElement(g,{className:"k-col-span-2",editorId:"categoryAxisTitleFont",labelText:o.toLanguageString(e.formatCategoryAxisTitleFont,e.messages[e.formatCategoryAxisTitleFont])},t.createElement(C.ComboBox,{id:"categoryAxisTitleFont",data:l.fontNames,textField:"text",dataItemKey:"value",itemRender:N,placeholder:o.toLanguageString(e.formatCategoryAxisTitleFontPlaceholder,e.messages[e.formatCategoryAxisTitleFontPlaceholder]),value:l.fontNames.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].title)==null?void 0:s.font)||""))==null?void 0:c.name)})||u,onChange:da,...S})),t.createElement(g,{editorId:"categoryAxisTitleFontSize",labelText:o.toLanguageString(e.formatCategoryAxisTitleSize,e.messages[e.formatCategoryAxisTitleSize])},t.createElement(C.ComboBox,{id:"categoryAxisTitleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatCategoryAxisTitleSizePlaceholder,e.messages[e.formatCategoryAxisTitleSizePlaceholder]),value:l.fontSizes.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].title)==null?void 0:s.font)||""))==null?void 0:c.size)})||u,onChange:ua,allowCustom:!0,...S})),t.createElement(g,{editorId:"categoryAxisTitleColor",labelText:o.toLanguageString(e.formatCategoryAxisTitleColor,e.messages[e.formatCategoryAxisTitleColor])},t.createElement(d.ColorPicker,{id:"categoryAxisTitleColor",view:"gradient",value:((Pe=n.categoryAxis[0].title)==null?void 0:Pe.color)||"",onChange:xa,fillMode:"outline"})))),t.createElement(F,{legend:o.toLanguageString(e.formatCategoryAxisLabels,e.messages[e.formatCategoryAxisLabels])},t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{className:"k-col-span-2",editorId:"categoryAxisLabelsFont",labelText:o.toLanguageString(e.formatCategoryAxisLabelsFont,e.messages[e.formatCategoryAxisLabelsFont])},t.createElement(C.ComboBox,{id:"categoryAxisLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatCategoryAxisLabelsFontPlaceholder,e.messages[e.formatCategoryAxisLabelsFontPlaceholder]),value:l.fontNames.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].labels)==null?void 0:s.font)||""))==null?void 0:c.name)})||u,onChange:Sa,itemRender:N,...S})),t.createElement(g,{editorId:"categoryAxisLabelsFontSize",labelText:o.toLanguageString(e.formatCategoryAxisLabelsSize,e.messages[e.formatCategoryAxisLabelsSize])},t.createElement(C.ComboBox,{id:"categoryAxisLabelsFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatCategoryAxisLabelsSizePlaceholder,e.messages[e.formatCategoryAxisLabelsSizePlaceholder]),value:l.fontSizes.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].labels)==null?void 0:s.font)||""))==null?void 0:c.size)})||u,onChange:Ca,allowCustom:!0,...S})),t.createElement(g,{editorId:"categoryAxisLabelsColor",labelText:o.toLanguageString(e.formatCategoryAxisLabelsColor,e.messages[e.formatCategoryAxisLabelsColor])},t.createElement(d.ColorPicker,{id:"categoryAxisLabelsColor",view:"gradient",value:((ze=n.categoryAxis[0].labels)==null?void 0:ze.color)||"",onChange:fa,fillMode:"outline"})),t.createElement(g,{editorId:"categoryAxisLabelsRotation",labelText:o.toLanguageString(e.formatCategoryAxisLabelsRotation,e.messages[e.formatCategoryAxisLabelsRotation])},t.createElement(d.NumericTextBox,{id:"categoryAxisLabelsRotation",value:typeof((we=n.categoryAxis[0].labels)==null?void 0:we.rotation)=="number"?(Ve=n.categoryAxis[0].labels)==null?void 0:Ve.rotation:null,placeholder:o.toLanguageString(e.formatCategoryAxisLabelsRotationAuto,e.messages[e.formatCategoryAxisLabelsRotationAuto]),onChange:ba,fillMode:"outline",min:-360,max:360,step:1})),t.createElement(g,{className:"k-col-span-2"},t.createElement(d.Checkbox,{label:o.toLanguageString(e.formatCategoryAxisLabelsReverseOrder,e.messages[e.formatCategoryAxisLabelsReverseOrder]),checked:n.categoryAxis[0].reverse||!1,onChange:pa})))))))),x!=="pie"&&t.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:x==="scatter"?o.toLanguageString(e.formatYAxis,e.messages[e.formatYAxis]):o.toLanguageString(e.formatValueAxis,e.messages[e.formatValueAxis]),expanded:ae,tabIndex:0,onAction:Tt},t.createElement(L.Reveal,null,ae&&t.createElement(m.ExpansionPanelContent,null,t.createElement(I.FormElement,null,t.createElement(F,{legend:o.toLanguageString(e.formatValueAxisTitle,e.messages[e.formatValueAxisTitle])},t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{className:"k-col-span-2"},t.createElement(d.Input,{placeholder:o.toLanguageString(e.formatValueAxisTitlePlaceholder,e.messages[e.formatValueAxisTitlePlaceholder]),value:((Be=(Re=n.valueAxis[0])==null?void 0:Re.title)==null?void 0:Be.text)||"",onChange:ha})),t.createElement(g,{className:"k-col-span-2",editorId:"valueAxisTitleFont",labelText:o.toLanguageString(e.formatValueAxisTitleFont,e.messages[e.formatValueAxisTitleFont])},t.createElement(C.ComboBox,{id:"valueAxisTitleFont",data:l.fontNames,textField:"text",dataItemKey:"value",itemRender:N,placeholder:o.toLanguageString(e.formatValueAxisTitleFontPlaceholder,e.messages[e.formatValueAxisTitleFontPlaceholder]),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.title)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:va,...S})),t.createElement(g,{editorId:"valueAxisTitleFontSize",labelText:o.toLanguageString(e.formatValueAxisTitleSize,e.messages[e.formatValueAxisTitleSize])},t.createElement(C.ComboBox,{id:"valueAxisTitleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatValueAxisTitleSizePlaceholder,e.messages[e.formatValueAxisTitleSizePlaceholder]),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.title)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:Aa,allowCustom:!0,...S})),t.createElement(g,{editorId:"valueAxisTitleColor",labelText:o.toLanguageString(e.formatValueAxisTitleColor,e.messages[e.formatValueAxisTitleColor])},t.createElement(d.ColorPicker,{id:"valueAxisTitleColor",view:"gradient",value:((De=(Me=n.valueAxis[0])==null?void 0:Me.title)==null?void 0:De.color)||"",onChange:La,fillMode:"outline"})))),t.createElement(F,{legend:o.toLanguageString(e.formatValueAxisLabels,e.messages[e.formatValueAxisLabels])},t.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},t.createElement(g,{className:"k-col-span-2",editorId:"valueAxisLabelsFormat",labelText:o.toLanguageString(e.formatValueAxisLabelsFormat,e.messages[e.formatValueAxisLabelsFormat])},t.createElement(C.DropDownList,{id:"valueAxisLabelsFormat",data:X,textField:"text",dataItemKey:"value",defaultItem:G,value:X.find(a=>{var s,c;return a.value===((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.format)})||G,onChange:Fa,...S})),t.createElement(g,{className:"k-col-span-2",editorId:"valueAxisLabelsFont",labelText:o.toLanguageString(e.formatValueAxisLabelsFont,e.messages[e.formatValueAxisLabelsFont])},t.createElement(C.ComboBox,{id:"valueAxisLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatValueAxisLabelsFontPlaceholder,e.messages[e.formatValueAxisLabelsFontPlaceholder]),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:ka,itemRender:N,...S})),t.createElement(g,{editorId:"valueAxisLabelsFontSize",labelText:o.toLanguageString(e.formatValueAxisLabelsSize,e.messages[e.formatValueAxisLabelsSize])},t.createElement(C.ComboBox,{id:"valueAxisLabelsFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(e.formatValueAxisLabelsSizePlaceholder,e.messages[e.formatValueAxisLabelsSizePlaceholder]),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:Ea,allowCustom:!0,...S})),t.createElement(g,{editorId:"valueAxisLabelsColor",labelText:o.toLanguageString(e.formatValueAxisLabelsColor,e.messages[e.formatValueAxisLabelsColor])},t.createElement(d.ColorPicker,{id:"valueAxisLabelsColor",view:"gradient",value:((qe=(We=n.valueAxis[0])==null?void 0:We.labels)==null?void 0:qe.color)||"",onChange:ya,fillMode:"outline"})),t.createElement(g,{editorId:"valueAxisLabelsRotation",labelText:o.toLanguageString(e.formatValueAxisLabelsRotation,e.messages[e.formatValueAxisLabelsRotation])},t.createElement(d.NumericTextBox,{id:"valueAxisLabelsRotation",value:typeof((Oe=(Ke=n.valueAxis[0])==null?void 0:Ke.labels)==null?void 0:Oe.rotation)=="number"?(Xe=(Ge=n.valueAxis[0])==null?void 0:Ge.labels)==null?void 0:Xe.rotation:null,placeholder:o.toLanguageString(e.formatValueAxisLabelsRotationAuto,e.messages[e.formatValueAxisLabelsRotationAuto]),onChange:Ta,fillMode:"outline",min:-360,max:360,step:1}))))))))))))))});Ye.displayName="ChartWizard";exports.ChartWizard=Ye;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Na=require("react"),Pa=require("@progress/kendo-react-dialogs"),E=require("@progress/kendo-react-charts"),m=require("@progress/kendo-react-layout"),za=require("@progress/kendo-react-buttons"),p=require("@progress/kendo-svg-icons"),v=require("@progress/kendo-react-animation"),C=require("@progress/kendo-react-dropdowns"),wa=require("./SeriesGrid.js"),d=require("@progress/kendo-react-inputs"),Xe=require("@progress/kendo-react-labels"),l=require("./chart-wizard-state.js"),He=require("@progress/kendo-react-common"),I=require("@progress/kendo-react-form"),Va=require("@progress/kendo-react-intl"),t=require("./messages.js"),w=require("./export.js");function Ra(r){const y=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const o in r)if(o!=="default"){const b=Object.getOwnPropertyDescriptor(r,o);Object.defineProperty(y,o,b.get?b:{enumerable:!0,get:()=>r[o]})}}return y.default=r,Object.freeze(y)}const e=Ra(Na),F=r=>e.createElement("fieldset",{className:"k-form-fieldset"},r.legend&&e.createElement("legend",{className:"k-form-legend"},r.legend),r.children),Ba=r=>{r.stopPropagation()},g=r=>e.createElement(I.FieldWrapper,{className:r.className},r.labelText&&r.editorId&&e.createElement(Xe.Label,{className:"k-form-label",editorId:r.editorId},r.labelText),e.createElement("div",{className:"k-form-field-wrap",onKeyDown:Ba},r.children)),u={value:null,text:""},Ma=/^\d+$/,N=(r,y)=>y.dataItem.style?e.cloneElement(r,r.props,e.createElement("span",{style:y.dataItem.style},r.props.children)):r,P=r=>{if(r.text==="")return!0;if(r.value===void 0){if(!Ma.test(r.text))return!1;r.value=r.text+"px"}return l.fontSizes.find(o=>o.value===r.value)||(l.fontSizes.push(r),l.fontSizes.sort((o,b)=>parseInt(o.text,10)-parseInt(b.text,10))),!0},k=r=>e.createElement("div",{className:He.classNames("k-icon-text-wrapper",{"k-selected":r.selected}),onClick:r.onClick},e.createElement("div",{className:"k-icon-background-area",tabIndex:0},e.createElement(He.IconWrap,{name:r.iconName,icon:r.icon,size:"xlarge",className:"k-svg-i-chart-bar-clustered"})),r.children),S={fillMode:"outline",popupSettings:{animate:!1}},q={type:"normal"},K={type:"100%"},_e=e.forwardRef((r,y)=>{var le,oe,se,re,ie,ce,ge,me,ue,de,xe,Ce,Se,fe,be,pe,he,Ae,ve,Le,Ee,ke,ye,Te,Fe,Ie,Ne,Pe,ze,we,Ve,Re,Be,Me,De,We,qe,Ke,Oe,Ge,je;const o=Va.useLocalization(),b=[{value:"chartTitle",text:o.toLanguageString(t.formatTitleChartTitle,t.messages.formatTitleChartTitle)},{value:"chartSubtitle",text:o.toLanguageString(t.formatTitleChartSubtitle,t.messages.formatTitleChartSubtitle)}],O=[{value:"top",text:o.toLanguageString(t.formatLegendPositionTop,t.messages.formatLegendPositionTop)},{value:"bottom",text:o.toLanguageString(t.formatLegendPositionBottom,t.messages.formatLegendPositionBottom)},{value:"left",text:o.toLanguageString(t.formatLegendPositionLeft,t.messages.formatLegendPositionLeft)},{value:"right",text:o.toLanguageString(t.formatLegendPositionRight,t.messages.formatLegendPositionRight)}],B={name:o.toLanguageString(t.formatSeriesAllSeries,t.messages.formatSeriesAllSeries)},G={text:o.toLanguageString(t.formatValueAxisLabelsFormatText,t.messages.formatValueAxisLabelsFormatText),value:""},j=[{value:"n0",text:o.toLanguageString(t.formatValueAxisLabelsFormatNumber,t.messages.formatValueAxisLabelsFormatNumber)},{value:"c0",text:o.toLanguageString(t.formatValueAxisLabelsFormatCurrency,t.messages.formatValueAxisLabelsFormatCurrency)},{value:"p0",text:o.toLanguageString(t.formatValueAxisLabelsFormatPercent,t.messages.formatValueAxisLabelsFormatPercent)}],V=e.useRef(null),Ye=e.useCallback(a=>{var s;if(V.current){const c=new w.ExportEvent(V.current,w.resolveExportOptions(r.exportOptions));(s=r.onExport)==null||s.call(r,c),c.isDefaultPrevented()||a.item.exportHandler.call(void 0,c)}},[r.exportOptions]),Ue=r.window||Pa.Window,[$e,Je]=e.useState({width:700,height:550}),[Qe,Ze]=e.useState("DEFAULT"),et=e.useCallback(a=>{Je({width:a.width,height:a.height})},[]),tt=e.useCallback(a=>{Ze(a.state)},[]),[at,nt]=e.useState([{collapsible:!1},{size:"300px",collapsible:!1}]),lt=e.useCallback(a=>{nt(a.newState)},[]),[H,ot]=e.useState(!0),st=e.useCallback(a=>{ot(!a.expanded)},[]),[X,rt]=e.useState(!0),it=e.useCallback(a=>{rt(!a.expanded)},[]),[_,ct]=e.useState(!0),gt=e.useCallback(a=>{ct(!a.expanded)},[]),[Y,mt]=e.useState(!0),ut=e.useCallback(a=>{mt(!a.expanded)},[]),[U,dt]=e.useState(!0),xt=e.useCallback(a=>{dt(!a.expanded)},[]),[$,Ct]=e.useState(!0),St=e.useCallback(a=>{Ct(!a.expanded)},[]),[J,ft]=e.useState(!1),bt=e.useCallback(a=>{ft(!a.expanded)},[]),[Q,pt]=e.useState(!1),ht=e.useCallback(a=>{pt(!a.expanded)},[]),[Z,At]=e.useState(!1),vt=e.useCallback(a=>{At(!a.expanded)},[]),[ee,Lt]=e.useState(!1),Et=e.useCallback(a=>{Lt(!a.expanded)},[]),[te,kt]=e.useState(!1),yt=e.useCallback(a=>{kt(!a.expanded)},[]),[ae,Tt]=e.useState(!1),Ft=e.useCallback(a=>{Tt(!a.expanded)},[]),[It,Nt]=e.useState(0),Pt=e.useCallback(a=>{Nt(a.selected)},[]),[n,i]=e.useState(l.createInitialState(r.data,"bar",r.defaultState)),ne=e.useRef(n);ne.current=n;const zt=e.useCallback(()=>({get chart(){return V.current},get state(){return ne.current}}),[]);e.useImperativeHandle(y,zt);const[h,A]=e.useState(""),wt=e.useCallback(a=>{const s=a.target.value.name;A(s===B.name?"":s)},[]),Vt=e.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"bar"))),A("")},[n,r.data]),Rt=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"bar"));i(l.updateState(a,l.ActionTypes.stacked,q)),A("")},[n,r.data]),Bt=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"bar"));i(l.updateState(a,l.ActionTypes.stacked,K)),A("")},[n,r.data]),Mt=e.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"column"))),A("")},[n,r.data]),Dt=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"column"));i(l.updateState(a,l.ActionTypes.stacked,q)),A("")},[n,r.data]),Wt=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"column"));i(l.updateState(a,l.ActionTypes.stacked,K)),A("")},[n,r.data]),qt=e.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"line"))),A("")},[n,r.data]),Kt=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"line"));i(l.updateState(a,l.ActionTypes.stacked,q)),A("")},[n,r.data]),Ot=e.useCallback(()=>{const a=l.mergeStates(n,l.createState(r.data,"line"));i(l.updateState(a,l.ActionTypes.stacked,K)),A("")},[n,r.data]),Gt=e.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"pie"))),A("")},[n,r.data]),jt=e.useCallback(()=>{i(l.mergeStates(n,l.createState(r.data,"scatter"))),A("")},[n,r.data]),Ht=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisX,a.target.value))},[n]),Xt=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.seriesChange,a))},[n]),_t=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisY,a.target.value))},[n]),Yt=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginLeft,a.target.value))},[n]),Ut=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginRight,a.target.value))},[n]),$t=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginTop,a.target.value))},[n]),Jt=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaMarginBottom,a.target.value))},[n]),T=n.area.margin,Qt=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.areaBackground,a.value))},[n]),[L,Zt]=e.useState(b[0]),ea=e.useCallback(a=>{Zt(a.target.value)},[]),ta=e.useCallback(a=>{const s=L.value===b[0].value?l.ActionTypes.titleText:l.ActionTypes.subtitleText;i(l.updateState(n,s,a.target.value))},[n,L]),aa=e.useCallback(a=>{const s=L.value===b[0].value?l.ActionTypes.titleFontName:l.ActionTypes.subtitleFontName,c=a.target.value||u;i(l.updateState(n,s,c.value))},[n,L]),na=e.useCallback(a=>{const s=L.value===b[0].value?l.ActionTypes.titleFontSize:l.ActionTypes.subtitleFontSize,c=a.target.value||u;P(c)&&i(l.updateState(n,s,c.value))},[n,L]),la=e.useCallback(a=>{const s=L.value===b[0].value?l.ActionTypes.titleColor:l.ActionTypes.subtitleColor;i(l.updateState(n,s,a.value))},[n,L]),R=(L.value===b[0].value?n.title:n.subtitle)||{text:"",font:"",color:""},oa=e.useCallback(a=>{h&&i(l.updateState(n,l.ActionTypes.seriesColor,{seriesName:h,color:a.value}))},[n,h]),sa=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.seriesLabel,{seriesName:h,all:!h,visible:a.value}))},[n,h]),ra=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.legendVisible,a.value))},[n]),ia=e.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.legendFontSize,s.value))},[n]),ca=e.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.legendFontName,s.value))},[n]),ga=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.legendColor,a.value))},[n]),ma=e.useCallback(a=>{const s=a.target.value;i(l.updateState(n,l.ActionTypes.legendPosition,s.value))},[n]),ua=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisTitleText,a.target.value))},[n]),da=e.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.categoryAxisTitleFontSize,s.value))},[n]),xa=e.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.categoryAxisTitleFontName,s.value))},[n]),Ca=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisTitleColor,a.value))},[n]),Sa=e.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.categoryAxisLabelsFontSize,s.value))},[n]),fa=e.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.categoryAxisLabelsFontName,s.value))},[n]),ba=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisLabelsColor,a.value))},[n]),pa=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisLabelsRotation,a.target.value))},[n]),ha=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.categoryAxisReverseOrder,a.value))},[n]),Aa=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisTitleText,a.target.value))},[n]),va=e.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.valueAxisTitleFontSize,s.value))},[n]),La=e.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.valueAxisTitleFontName,s.value))},[n]),Ea=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisTitleColor,a.value))},[n]),ka=e.useCallback(a=>{const s=a.target.value||u;P(s)&&i(l.updateState(n,l.ActionTypes.valueAxisLabelsFontSize,s.value))},[n]),ya=e.useCallback(a=>{const s=a.target.value||u;i(l.updateState(n,l.ActionTypes.valueAxisLabelsFontName,s.value))},[n]),Ta=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisLabelsColor,a.value))},[n]),Fa=e.useCallback(a=>{i(l.updateState(n,l.ActionTypes.valueAxisLabelsRotation,a.target.value))},[n]),Ia=e.useCallback(a=>{const s=a.target.value;i(l.updateState(n,l.ActionTypes.valueAxisLabelsFormat,s.value))},[n]),x=n.seriesType,z=typeof((le=n.series[0])==null?void 0:le.stack)=="object"?(oe=n.series[0])==null?void 0:oe.stack:!1,M=z===!1,D=z&&z.type==="normal",W=z&&z.type==="100%";return e.createElement(Ue,{title:o.toLanguageString(t.windowTitle,t.messages.windowTitle),className:"k-chart-wizard",modal:!0,resizable:!0,minimizeButton:()=>null,onClose:r.onClose,onResize:et,stage:Qe,onStageChange:tt,...$e},e.createElement(m.Splitter,{panes:at,onChange:lt,className:"k-chart-wizard-splitter"},e.createElement("div",{className:"k-chart-wizard-preview-pane k-pane"},e.createElement("div",{className:"k-preview-pane-header"},e.createElement(za.DropDownButton,{text:o.toLanguageString(t.exportButton,t.messages.exportButton),fillMode:"flat",svgIcon:p.exportIcon,icon:"export",onItemClick:Ye,items:[{svgIcon:p.filePdfIcon,icon:"file-pdf",exportHandler:w.handlePDFExport,text:o.toLanguageString(t.exportPDFButton,t.messages.exportPDFButton)},{svgIcon:p.fileIcon,icon:"file",exportHandler:w.handleSVGExport,text:o.toLanguageString(t.exportSVGButton,t.messages.exportSVGButton)},{svgIcon:p.fileImageIcon,icon:"file-image",exportHandler:w.handleImageExport,text:o.toLanguageString(t.exportPNGButton,t.messages.exportPNGButton)}]})),e.createElement("div",{className:"k-preview-pane-content",style:{height:"calc(100% - 50px)"}},e.createElement(E.Chart,{style:{width:"100%",height:"100%"},transitions:!1,ref:V},e.createElement(E.ChartTitle,{text:(se=n.title)==null?void 0:se.text,font:(re=n.title)==null?void 0:re.font,color:((ie=n.title)==null?void 0:ie.color)||"#000"}),e.createElement(E.ChartSubtitle,{text:(ce=n.subtitle)==null?void 0:ce.text,font:(ge=n.subtitle)==null?void 0:ge.font,color:((me=n.subtitle)==null?void 0:me.color)||"#000"}),e.createElement(E.ChartArea,{background:(ue=n.area)==null?void 0:ue.background,margin:T}),n.categoryAxis&&e.createElement(E.ChartCategoryAxis,null,n.categoryAxis.map((a,s)=>e.createElement(E.ChartCategoryAxisItem,{key:s,categories:a.categories,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{font:a.labels.font,color:a.labels.color,rotation:a.labels.rotation},reverse:a.reverse}))),n.valueAxis&&e.createElement(E.ChartValueAxis,null,n.valueAxis.map((a,s)=>e.createElement(E.ChartValueAxisItem,{key:s,title:a.title&&{text:a.title.text,font:a.title.font,color:a.title.color},labels:a.labels&&{format:a.labels.format,font:a.labels.font,color:a.labels.color,rotation:a.labels.rotation}}))),e.createElement(E.ChartSeries,null,n.series.map((a,s)=>e.createElement(E.ChartSeriesItem,{key:String(a.name)+s,...a}))),e.createElement(E.ChartLegend,{visible:(de=n.legend)==null?void 0:de.visible,position:(xe=n.legend)==null?void 0:xe.position,labels:{color:((Se=(Ce=n.legend)==null?void 0:Ce.labels)==null?void 0:Se.color)||void 0,font:((be=(fe=n.legend)==null?void 0:fe.labels)==null?void 0:be.font)||void 0}})))),e.createElement("div",{className:"k-chart-wizard-property-pane k-pane k-pane-static"},e.createElement(m.TabStrip,{selected:It,onSelect:Pt,animation:!1},e.createElement(m.TabStripTab,{title:o.toLanguageString(t.tabChart,t.messages.tabChart)},e.createElement("div",null,e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.barChart,t.messages.barChart),expanded:H,tabIndex:0,onAction:st},e.createElement(v.Reveal,null,H&&e.createElement(m.ExpansionPanelContent,null,e.createElement("div",{className:"k-chart-types-wrapper"},e.createElement(k,{selected:x==="bar"&&M,onClick:Vt,icon:p.chartBarClusteredIcon,iconName:"chart-bar-clustered"},o.toLanguageString(t.barChartBar,t.messages.barChartBar)),e.createElement(k,{selected:x==="bar"&&D,onClick:Rt,icon:p.chartBarStackedIcon,iconName:"chart-bar-stacked"},o.toLanguageString(t.barChartStackedBar,t.messages.barChartStackedBar)),e.createElement(k,{selected:x==="bar"&&W,onClick:Bt,icon:p.chartBarStacked100Icon,iconName:"chart-bar-stacked100"},o.toLanguageString(t.barChart100StackedBar,t.messages.barChart100StackedBar)))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.pieChart,t.messages.pieChart),expanded:X,tabIndex:0,onAction:it},e.createElement(v.Reveal,null,X&&e.createElement(m.ExpansionPanelContent,null,e.createElement("div",{className:"k-chart-types-wrapper"},e.createElement(k,{selected:x==="pie",onClick:Gt,icon:p.chartPieIcon,iconName:"chart-pie"},o.toLanguageString(t.pieChartPie,t.messages.pieChartPie)))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.columnChart,t.messages.columnChart),expanded:_,tabIndex:0,onAction:gt},e.createElement(v.Reveal,null,_&&e.createElement(m.ExpansionPanelContent,null,e.createElement("div",{className:"k-chart-types-wrapper"},e.createElement(k,{selected:x==="column"&&M,onClick:Mt,icon:p.chartColumnClusteredIcon,iconName:"chart-column-clustered"},o.toLanguageString(t.columnChartColumn,t.messages.columnChartColumn)),e.createElement(k,{selected:x==="column"&&D,onClick:Dt,icon:p.chartColumnStackedIcon,iconName:"chart-column-stacked"},o.toLanguageString(t.columnChartStackedColumn,t.messages.columnChartStackedColumn)),e.createElement(k,{selected:x==="column"&&W,onClick:Wt,icon:p.chartColumnStacked100Icon,iconName:"chart-column-stacked100"},o.toLanguageString(t.columnChart100StackedColumn,t.messages.columnChart100StackedColumn)))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.lineChart,t.messages.lineChart),expanded:Y,tabIndex:0,onAction:ut},e.createElement(v.Reveal,null,Y&&e.createElement(m.ExpansionPanelContent,null,e.createElement("div",{className:"k-chart-types-wrapper"},e.createElement(k,{selected:x==="line"&&M,onClick:qt,icon:p.chartLineIcon,iconName:"chart-line"},o.toLanguageString(t.lineChartLine,t.messages.lineChartLine)),e.createElement(k,{selected:x==="line"&&D,onClick:Kt,icon:p.chartLineStackedIcon,iconName:"chart-line-stacked"},o.toLanguageString(t.lineChartStackedLine,t.messages.lineChartStackedLine)),e.createElement(k,{selected:x==="line"&&W,onClick:Ot,icon:p.chartLineStacked100Icon,iconName:"chart-line-stacked100"},o.toLanguageString(t.lineChart100StackedLine,t.messages.lineChart100StackedLine)))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.scatterChart,t.messages.scatterChart),expanded:U,tabIndex:0,onAction:xt},e.createElement(v.Reveal,null,U&&e.createElement(m.ExpansionPanelContent,null,e.createElement("div",{className:"k-chart-types-wrapper"},e.createElement(k,{selected:x==="scatter",onClick:jt,icon:p.chartScatterIcon,iconName:"chart-scatter"},o.toLanguageString(t.scatterChartScatter,t.messages.scatterChartScatter)))))))),e.createElement(m.TabStripTab,{title:o.toLanguageString(t.tabData,t.messages.tabData)},e.createElement("div",null,e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.configuration,t.messages.configuration),expanded:$,tabIndex:0,onAction:St},e.createElement(v.Reveal,null,$&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement(F,{legend:x==="scatter"?o.toLanguageString(t.configurationXAxis,t.messages.configurationXAxis):o.toLanguageString(t.configurationCategoryAxis,t.messages.configurationCategoryAxis)},e.createElement(C.DropDownList,{data:n.columns||[],value:n.categoryField,onChange:Ht,...S})),l.isCategorical(x)&&e.createElement(F,{legend:o.toLanguageString(t.configurationSeries,t.messages.configurationSeries)},e.createElement(wa.SeriesGrid,{data:n.series,initialData:n.initialSeries,onChange:Xt})),x==="pie"&&e.createElement(F,{legend:o.toLanguageString(t.configurationValueAxis,t.messages.configurationValueAxis)},e.createElement(C.DropDownList,{data:n.columns||[],value:n.valueField||"",...S,onChange:_t})))))))),e.createElement(m.TabStripTab,{title:o.toLanguageString(t.tabFormat,t.messages.tabFormat)},e.createElement("div",null,e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.formatChartArea,t.messages.formatChartArea),expanded:J,tabIndex:0,onAction:bt},e.createElement(v.Reveal,null,J&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement(F,{legend:o.toLanguageString(t.formatChartAreaMargins,t.messages.formatChartAreaMargins)},e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{labelText:o.toLanguageString(t.formatChartAreaMarginsLeft,t.messages.formatChartAreaMarginsLeft),editorId:"left"},e.createElement(d.NumericTextBox,{id:"left",value:T.left!==void 0?T.left:null,onChange:Yt,placeholder:o.toLanguageString(t.formatChartAreaMarginsAuto,t.messages.formatChartAreaMarginsAuto),min:0,max:1e3,step:1,fillMode:"outline"})),e.createElement(g,{labelText:o.toLanguageString(t.formatChartAreaMarginsRight,t.messages.formatChartAreaMarginsRight),editorId:"right"},e.createElement(d.NumericTextBox,{id:"right",value:T.right!==void 0?T.right:null,onChange:Ut,placeholder:o.toLanguageString(t.formatChartAreaMarginsAuto,t.messages.formatChartAreaMarginsAuto),min:0,max:1e3,step:1,fillMode:"outline"})),e.createElement(g,{labelText:o.toLanguageString(t.formatChartAreaMarginsTop,t.messages.formatChartAreaMarginsTop),editorId:"top"},e.createElement(d.NumericTextBox,{id:"top",value:T.top!==void 0?T.top:null,onChange:$t,placeholder:o.toLanguageString(t.formatChartAreaMarginsAuto,t.messages.formatChartAreaMarginsAuto),min:0,max:1e3,step:1,fillMode:"outline"})),e.createElement(g,{labelText:o.toLanguageString(t.formatChartAreaMarginsBottom,t.messages.formatChartAreaMarginsBottom),editorId:"bottom"},e.createElement(d.NumericTextBox,{id:"bottom",value:T.bottom!==void 0?T.bottom:null,onChange:Jt,placeholder:o.toLanguageString(t.formatChartAreaMarginsAuto,t.messages.formatChartAreaMarginsAuto),min:0,max:1e3,step:1,fillMode:"outline"})))),e.createElement(F,{legend:o.toLanguageString(t.formatChartAreaBackground,t.messages.formatChartAreaBackground)},e.createElement(g,{labelText:o.toLanguageString(t.formatChartAreaBackgroundColor,t.messages.formatChartAreaBackgroundColor),editorId:"background"},e.createElement(d.ColorPicker,{id:"background",value:((pe=n.area)==null?void 0:pe.background)||"",onChange:Qt,view:"gradient",fillMode:"outline"}))))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.formatTitle,t.messages.formatTitle),expanded:Q,tabIndex:0,onAction:ht},e.createElement(v.Reveal,null,Q&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{className:"k-col-span-2",editorId:"apply-to-title",labelText:o.toLanguageString(t.formatTitleApplyTo,t.messages.formatTitleApplyTo)},e.createElement(C.DropDownList,{id:"apply-to-title",data:b,textField:"text",dataItemKey:"value",value:b.find(a=>a.value===L.value),onChange:ea,...S})),e.createElement(g,{className:"k-col-span-2",editorId:"titleText",labelText:o.toLanguageString(t.formatTitleLabel,t.messages.formatTitleLabel)},e.createElement(d.Input,{id:"titleText",placeholder:L.value===b[0].value?b[0].text:b[1].text,value:R.text,onChange:ta})),e.createElement(g,{className:"k-col-span-2",editorId:"titleFont",labelText:o.toLanguageString(t.formatTitleFont,t.messages.formatTitleFont)},e.createElement(C.ComboBox,{id:"titleFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatTitleFontPlaceholder,t.messages.formatTitleFontPlaceholder),value:l.fontNames.find(a=>a.value===l.parseFont(R.font).name)||u,onChange:aa,itemRender:N,...S})),e.createElement(g,{editorId:"titleFontSize",labelText:o.toLanguageString(t.formatTitleSize,t.messages.formatTitleSize)},e.createElement(C.ComboBox,{id:"titleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatTitleSizePlaceholder,t.messages.formatTitleSizePlaceholder),value:l.fontSizes.find(a=>a.value===l.parseFont(R.font).size)||u,onChange:na,itemRender:N,allowCustom:!0,...S})),e.createElement(g,{editorId:"titleColor",labelText:o.toLanguageString(t.formatTitleColor,t.messages.formatTitleColor)},e.createElement(d.ColorPicker,{id:"titleColor",value:R.color||"",onChange:la,view:"gradient",fillMode:"outline"}))))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.formatSeries,t.messages.formatSeries),expanded:Z,tabIndex:0,onAction:vt},e.createElement(v.Reveal,null,Z&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement(g,{editorId:"apply-to-series",labelText:o.toLanguageString(t.formatSeriesApplyTo,t.messages.formatSeriesApplyTo)},e.createElement(C.DropDownList,{id:"apply-to-series",data:n.series,textField:"name",dataItemKey:"name",defaultItem:B,disabled:!l.isCategorical(x),value:n.series.find(a=>a.name===h)||B,onChange:wt,...S})),e.createElement(g,{editorId:"seriesColor",labelText:o.toLanguageString(t.formatSeriesColor,t.messages.formatSeriesColor)},e.createElement(d.ColorPicker,{id:"seriesColor",value:h?(he=n.series.find(a=>a.name===h))==null?void 0:he.color:"",onChange:oa,disabled:!h,view:"gradient",fillMode:"outline"})),e.createElement(g,null,e.createElement(d.Checkbox,{label:o.toLanguageString(t.formatSeriesShowLabels,t.messages.formatSeriesShowLabels),checked:h?(ve=(Ae=n.series.find(a=>a.name===h))==null?void 0:Ae.labels)==null?void 0:ve.visible:n.series.every(a=>{var s;return(s=a.labels)==null?void 0:s.visible}),onChange:sa})))))),e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:o.toLanguageString(t.formatLegend,t.messages.formatLegend),expanded:ee,tabIndex:0,onAction:Et},e.createElement(v.Reveal,null,ee&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(Xe.Label,{editorId:"show-legend"},o.toLanguageString(t.formatLegendShowLegend,t.messages.formatLegendShowLegend)),e.createElement(d.Switch,{id:"show-legend",checked:(Le=n.legend)==null?void 0:Le.visible,onChange:ra}),e.createElement(g,{className:"k-col-span-2",editorId:"legendLabelsFont",labelText:o.toLanguageString(t.formatLegendFont,t.messages.formatLegendFont)},e.createElement(C.ComboBox,{id:"legendLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatLegendFontPlaceholder,t.messages.formatLegendFontPlaceholder),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.legend)==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:ca,itemRender:N,disabled:((Ee=n.legend)==null?void 0:Ee.visible)===!1,...S})),e.createElement(g,{editorId:"legendLabelsSize",labelText:o.toLanguageString(t.formatLegendSize,t.messages.formatLegendSize)},e.createElement(C.ComboBox,{id:"legendLabelsSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatLegendSizePlaceholder,t.messages.formatLegendSizePlaceholder),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.legend)==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:ia,disabled:((ke=n.legend)==null?void 0:ke.visible)===!1,allowCustom:!0,...S})),e.createElement(g,{editorId:"legendLabelsColor",labelText:o.toLanguageString(t.formatLegendColor,t.messages.formatLegendColor)},e.createElement(d.ColorPicker,{id:"legendLabelsColor",value:((Te=(ye=n.legend)==null?void 0:ye.labels)==null?void 0:Te.color)||"",onChange:ga,disabled:((Fe=n.legend)==null?void 0:Fe.visible)===!1,view:"gradient",fillMode:"outline"})),e.createElement(g,{className:"k-col-span-2",editorId:"legendPosition",labelText:o.toLanguageString(t.formatLegendPosition,t.messages.formatLegendPosition)},e.createElement(C.DropDownList,{id:"legendPosition",data:O,textField:"text",dataItemKey:"value",value:O.find(a=>{var s;return a.value===((s=n.legend)==null?void 0:s.position)}),onChange:ma,disabled:((Ie=n.legend)==null?void 0:Ie.visible)===!1,...S}))))))),x!=="pie"&&e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:x==="scatter"?o.toLanguageString(t.formatXAxis,t.messages.formatXAxis):o.toLanguageString(t.formatCategoryAxis,t.messages.formatCategoryAxis),expanded:te,tabIndex:0,onAction:yt},e.createElement(v.Reveal,null,te&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement(F,{legend:o.toLanguageString(t.formatCategoryAxisTitle,t.messages.formatCategoryAxisTitle)},e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{className:"k-col-span-2"},e.createElement(d.Input,{placeholder:o.toLanguageString(t.formatCategoryAxisTitlePlaceholder,t.messages.formatCategoryAxisTitlePlaceholder),value:((Ne=n.categoryAxis[0].title)==null?void 0:Ne.text)||"",onChange:ua})),e.createElement(g,{className:"k-col-span-2",editorId:"categoryAxisTitleFont",labelText:o.toLanguageString(t.formatCategoryAxisTitleFont,t.messages.formatCategoryAxisTitleFont)},e.createElement(C.ComboBox,{id:"categoryAxisTitleFont",data:l.fontNames,textField:"text",dataItemKey:"value",itemRender:N,placeholder:o.toLanguageString(t.formatCategoryAxisTitleFontPlaceholder,t.messages.formatCategoryAxisTitleFontPlaceholder),value:l.fontNames.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].title)==null?void 0:s.font)||""))==null?void 0:c.name)})||u,onChange:xa,...S})),e.createElement(g,{editorId:"categoryAxisTitleFontSize",labelText:o.toLanguageString(t.formatCategoryAxisTitleSize,t.messages.formatCategoryAxisTitleSize)},e.createElement(C.ComboBox,{id:"categoryAxisTitleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatCategoryAxisTitleSizePlaceholder,t.messages.formatCategoryAxisTitleSizePlaceholder),value:l.fontSizes.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].title)==null?void 0:s.font)||""))==null?void 0:c.size)})||u,onChange:da,allowCustom:!0,...S})),e.createElement(g,{editorId:"categoryAxisTitleColor",labelText:o.toLanguageString(t.formatCategoryAxisTitleColor,t.messages.formatCategoryAxisTitleColor)},e.createElement(d.ColorPicker,{id:"categoryAxisTitleColor",view:"gradient",value:((Pe=n.categoryAxis[0].title)==null?void 0:Pe.color)||"",onChange:Ca,fillMode:"outline"})))),e.createElement(F,{legend:o.toLanguageString(t.formatCategoryAxisLabels,t.messages.formatCategoryAxisLabels)},e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{className:"k-col-span-2",editorId:"categoryAxisLabelsFont",labelText:o.toLanguageString(t.formatCategoryAxisLabelsFont,t.messages.formatCategoryAxisLabelsFont)},e.createElement(C.ComboBox,{id:"categoryAxisLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatCategoryAxisLabelsFontPlaceholder,t.messages.formatCategoryAxisLabelsFontPlaceholder),value:l.fontNames.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].labels)==null?void 0:s.font)||""))==null?void 0:c.name)})||u,onChange:fa,itemRender:N,...S})),e.createElement(g,{editorId:"categoryAxisLabelsFontSize",labelText:o.toLanguageString(t.formatCategoryAxisLabelsSize,t.messages.formatCategoryAxisLabelsSize)},e.createElement(C.ComboBox,{id:"categoryAxisLabelsFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatCategoryAxisLabelsSizePlaceholder,t.messages.formatCategoryAxisLabelsSizePlaceholder),value:l.fontSizes.find(a=>{var s,c;return a.value===((c=l.parseFont(((s=n.categoryAxis[0].labels)==null?void 0:s.font)||""))==null?void 0:c.size)})||u,onChange:Sa,allowCustom:!0,...S})),e.createElement(g,{editorId:"categoryAxisLabelsColor",labelText:o.toLanguageString(t.formatCategoryAxisLabelsColor,t.messages.formatCategoryAxisLabelsColor)},e.createElement(d.ColorPicker,{id:"categoryAxisLabelsColor",view:"gradient",value:((ze=n.categoryAxis[0].labels)==null?void 0:ze.color)||"",onChange:ba,fillMode:"outline"})),e.createElement(g,{editorId:"categoryAxisLabelsRotation",labelText:o.toLanguageString(t.formatCategoryAxisLabelsRotation,t.messages.formatCategoryAxisLabelsRotation)},e.createElement(d.NumericTextBox,{id:"categoryAxisLabelsRotation",value:typeof((we=n.categoryAxis[0].labels)==null?void 0:we.rotation)=="number"?(Ve=n.categoryAxis[0].labels)==null?void 0:Ve.rotation:null,placeholder:o.toLanguageString(t.formatCategoryAxisLabelsRotationAuto,t.messages.formatCategoryAxisLabelsRotationAuto),onChange:pa,fillMode:"outline",min:-360,max:360,step:1})),e.createElement(g,{className:"k-col-span-2"},e.createElement(d.Checkbox,{label:o.toLanguageString(t.formatCategoryAxisLabelsReverseOrder,t.messages.formatCategoryAxisLabelsReverseOrder),checked:n.categoryAxis[0].reverse||!1,onChange:ha})))))))),x!=="pie"&&e.createElement(m.ExpansionPanel,{style:{maxWidth:"576px"},title:x==="scatter"?o.toLanguageString(t.formatYAxis,t.messages.formatYAxis):o.toLanguageString(t.formatValueAxis,t.messages.formatValueAxis),expanded:ae,tabIndex:0,onAction:Ft},e.createElement(v.Reveal,null,ae&&e.createElement(m.ExpansionPanelContent,null,e.createElement(I.FormElement,null,e.createElement(F,{legend:o.toLanguageString(t.formatValueAxisTitle,t.messages.formatValueAxisTitle)},e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{className:"k-col-span-2"},e.createElement(d.Input,{placeholder:o.toLanguageString(t.formatValueAxisTitlePlaceholder,t.messages.formatValueAxisTitlePlaceholder),value:((Be=(Re=n.valueAxis[0])==null?void 0:Re.title)==null?void 0:Be.text)||"",onChange:Aa})),e.createElement(g,{className:"k-col-span-2",editorId:"valueAxisTitleFont",labelText:o.toLanguageString(t.formatValueAxisTitleFont,t.messages.formatValueAxisTitleFont)},e.createElement(C.ComboBox,{id:"valueAxisTitleFont",data:l.fontNames,textField:"text",dataItemKey:"value",itemRender:N,placeholder:o.toLanguageString(t.formatValueAxisTitleFontPlaceholder,t.messages.formatValueAxisTitleFontPlaceholder),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.title)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:La,...S})),e.createElement(g,{editorId:"valueAxisTitleFontSize",labelText:o.toLanguageString(t.formatValueAxisTitleSize,t.messages.formatValueAxisTitleSize)},e.createElement(C.ComboBox,{id:"valueAxisTitleFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatValueAxisTitleSizePlaceholder,t.messages.formatValueAxisTitleSizePlaceholder),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.title)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:va,allowCustom:!0,...S})),e.createElement(g,{editorId:"valueAxisTitleColor",labelText:o.toLanguageString(t.formatValueAxisTitleColor,t.messages.formatValueAxisTitleColor)},e.createElement(d.ColorPicker,{id:"valueAxisTitleColor",view:"gradient",value:((De=(Me=n.valueAxis[0])==null?void 0:Me.title)==null?void 0:De.color)||"",onChange:Ea,fillMode:"outline"})))),e.createElement(F,{legend:o.toLanguageString(t.formatValueAxisLabels,t.messages.formatValueAxisLabels)},e.createElement("div",{className:"k-form-layout k-d-grid k-grid-cols-2 k-gap-x-4"},e.createElement(g,{className:"k-col-span-2",editorId:"valueAxisLabelsFormat",labelText:o.toLanguageString(t.formatValueAxisLabelsFormat,t.messages.formatValueAxisLabelsFormat)},e.createElement(C.DropDownList,{id:"valueAxisLabelsFormat",data:j,textField:"text",dataItemKey:"value",defaultItem:G,value:j.find(a=>{var s,c;return a.value===((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.format)})||G,onChange:Ia,...S})),e.createElement(g,{className:"k-col-span-2",editorId:"valueAxisLabelsFont",labelText:o.toLanguageString(t.formatValueAxisLabelsFont,t.messages.formatValueAxisLabelsFont)},e.createElement(C.ComboBox,{id:"valueAxisLabelsFont",data:l.fontNames,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatValueAxisLabelsFontPlaceholder,t.messages.formatValueAxisLabelsFontPlaceholder),value:l.fontNames.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.name)})||u,onChange:ya,itemRender:N,...S})),e.createElement(g,{editorId:"valueAxisLabelsFontSize",labelText:o.toLanguageString(t.formatValueAxisLabelsSize,t.messages.formatValueAxisLabelsSize)},e.createElement(C.ComboBox,{id:"valueAxisLabelsFontSize",data:l.fontSizes,textField:"text",dataItemKey:"value",placeholder:o.toLanguageString(t.formatValueAxisLabelsSizePlaceholder,t.messages.formatValueAxisLabelsSizePlaceholder),value:l.fontSizes.find(a=>{var s,c,f;return a.value===((f=l.parseFont(((c=(s=n.valueAxis[0])==null?void 0:s.labels)==null?void 0:c.font)||""))==null?void 0:f.size)})||u,onChange:ka,allowCustom:!0,...S})),e.createElement(g,{editorId:"valueAxisLabelsColor",labelText:o.toLanguageString(t.formatValueAxisLabelsColor,t.messages.formatValueAxisLabelsColor)},e.createElement(d.ColorPicker,{id:"valueAxisLabelsColor",view:"gradient",value:((qe=(We=n.valueAxis[0])==null?void 0:We.labels)==null?void 0:qe.color)||"",onChange:Ta,fillMode:"outline"})),e.createElement(g,{editorId:"valueAxisLabelsRotation",labelText:o.toLanguageString(t.formatValueAxisLabelsRotation,t.messages.formatValueAxisLabelsRotation)},e.createElement(d.NumericTextBox,{id:"valueAxisLabelsRotation",value:typeof((Oe=(Ke=n.valueAxis[0])==null?void 0:Ke.labels)==null?void 0:Oe.rotation)=="number"?(je=(Ge=n.valueAxis[0])==null?void 0:Ge.labels)==null?void 0:je.rotation:null,placeholder:o.toLanguageString(t.formatValueAxisLabelsRotationAuto,t.messages.formatValueAxisLabelsRotationAuto),onChange:Fa,fillMode:"outline",min:-360,max:360,step:1}))))))))))))))});_e.displayName="ChartWizard";exports.ChartWizard=_e;
|