@ecan-bi/indicator-library 1.0.88 → 1.0.89

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.
Files changed (44) hide show
  1. package/dist/assets/editor.worker-02df2e61.js +1 -1
  2. package/dist/assets/json.worker-867823a6.js +1 -1
  3. package/dist/assets/ts.worker-7254b425.js +1 -1
  4. package/dist/index.es.js +11758 -6904
  5. package/dist/index.es.js.map +1 -1
  6. package/dist/index.umd.js +21 -10
  7. package/dist/index.umd.js.map +1 -1
  8. package/dist/style.css +2 -2
  9. package/package.json +13 -12
  10. package/types/env.d.ts +15 -0
  11. package/types/indicator/indicator-library/data-config/data-config-group/data-config-card/DataConfigCard.vue.d.ts +1 -1
  12. package/types/indicator/indicator-library/data-config/style-config-group/StyleConfigGroup.vue.d.ts +2 -2
  13. package/types/indicator/indicator-library/data-config/style-config-group/chart-props/bar/props.d.ts +50 -0
  14. package/types/indicator/indicator-library/data-config/style-config-group/chart-props/combo-graph/props.d.ts +5 -1
  15. package/types/indicator/indicator-library/data-config/style-config-group/chart-props/index.d.ts +65 -1
  16. package/types/indicator/indicator-library/data-config/style-config-group/chart-props/line/props.d.ts +120 -2
  17. package/types/indicator/indicator-library/data-config/style-config-group/chart-props/pie/props.d.ts +26 -1
  18. package/types/indicator/indicator-library/data-config/style-config-group/data.d.ts +7 -1
  19. package/types/indicator/indicator-library/data-config/style-config-group/indicator-container/IndicatorContainer.vue.d.ts +8 -0
  20. package/types/indicator/indicator-library/data-config/style-config-group/indicator-container/index.d.ts +2 -0
  21. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/PropsToForm.vue.d.ts +1 -1
  22. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/data.d.ts +5 -0
  23. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/form-group/FormGroup.vue.d.ts +1 -1
  24. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/input-number/InputNumber.vue.d.ts +4 -4
  25. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/radio-group/RadioGroup.vue.d.ts +2 -2
  26. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/select/Select.vue.d.ts +8 -2
  27. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/slider/Slider.vue.d.ts +18 -0
  28. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/slider/index.d.ts +2 -0
  29. package/types/indicator/indicator-library/data-config/style-config-group/props-to-form/switch/Switch.vue.d.ts +2 -2
  30. package/types/indicator/indicator-library/data-config/style-config-group/table-column-config/TableColumnConfig.vue.d.ts +3 -0
  31. package/types/indicator/indicator-library/data-config/style-config-group/table-column-config/components/Condition.vue.d.ts +54 -0
  32. package/types/indicator/indicator-library/data-config/style-config-group/table-column-config/components/ConditionList.vue.d.ts +33 -0
  33. package/types/indicator/indicator-library/data-config/style-config-group/table-column-config/components/ConditionWrap.vue.d.ts +42 -0
  34. package/types/indicator/indicator-library/data-config/style-config-group/table-column-config/components/ConditionsTable.vue.d.ts +20 -0
  35. package/types/indicator/indicator-library/data-list/IndSourceList.vue.d.ts +9 -0
  36. package/types/indicator/table-graph/TableGraph.vue.d.ts +35 -0
  37. package/types/utils/constant.d.ts +1 -1
  38. package/types/utils/util.d.ts +10 -8
  39. package/types/hooks/useTransformChartDataByAttrKey.d.ts +0 -25
  40. package/types/hooks/useTransformChartDataByAttrValue.d.ts +0 -23
  41. package/types/hooks/useValueFormatter.d.ts +0 -2
  42. package/types/hooks/useVariablesInText.d.ts +0 -12
  43. package/types/indicator/chart-graph/transformProps.d.ts +0 -1
  44. package/types/utils/runCode.d.ts +0 -4
package/dist/index.umd.js CHANGED
@@ -1,5 +1,5 @@
1
- /*! @ecan-bi/indicator-library@1.0.88 */
2
- (function(ke,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("lodash-es"),require("ant-design-vue"),require("vuedraggable"),require("dayjs"),require("ant-design-vue/es/popover/style"),require("ant-design-vue/es/dropdown/style"),require("ant-design-vue/es/table/style"),require("monaco-editor"),require("ant-design-vue/es/collapse/style"),require("echarts")):typeof define=="function"&&define.amd?define(["exports","vue","lodash-es","ant-design-vue","vuedraggable","dayjs","ant-design-vue/es/popover/style","ant-design-vue/es/dropdown/style","ant-design-vue/es/table/style","monaco-editor","ant-design-vue/es/collapse/style","echarts"],e):(ke=typeof globalThis<"u"?globalThis:ke||self,e(ke["@ecan-bi/indicator-library"]={},ke.Vue,ke.LodashEs,ke.AntDesignVue,ke.Draggable,ke.Dayjs,null,null,null,ke.MonacoEditor,null,ke.Echarts))})(this,function(ke,e,ee,P,mt,ue,rm,lm,im,fr,sm,mr){var ur;"use strict";function hr(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(o,n,a.get?a:{enumerable:!0,get:()=>t[n]})}}return o.default=t,Object.freeze(o)}const yr=hr(mr),mn=(t,o)=>{if(t.install=n=>{for(const a of[t,...Object.values(o??{})])n.component(a.name,a)},o)for(const[n,a]of Object.entries(o))t[n]=a;return t},Oe="$request",_e=((ur=window==null?void 0:window.config)==null?void 0:ur.indicatorURL)||"",De="INDICATOR_TOKEN",hn="DATA_LIST",Ye="SELECTED_COMPONENT",Ce="GRAPHIC_CONFIG",xe="UPDATE_GRAPHIC_CONFIG",yn="SHOW_STYLE_CONFIG",gn="REFRESH_DATA",Yt="CHARTS_OPTIONS",bn="TABLE_OPTIONS",gr=18,bo="UPDATE_CHARTS_OPTIONS",Co="UPDATE_TABLE_OPTIONS",At="SOURCE_TYPE",Cn="CHANGE_CONDITION",wn="DATA_VIEW_COLUMNS",ve="RENDER_USED_COMPONENTS",Wt="UPDATE_USED_COMPONENT",kn="MAP_ATTRIBUTE_PROPS",_n="PAGE_CONFIG",Sn={bar:{name:"柱状图",type:"bar",width:"400px",height:"400px",xAxisLabelFormatter:"{value}",yAxisLabelFormatter:"{value}",yAxisLineAlwaysDisplay:!1,titleText:"",titleSubtext:"",colors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],legendShow:!0,legendTextStyleColor:"#333",legendOrient:"horizontal",legendTop:"top",legendLeft:"center",tooltipShow:!0,tooltipTextStyleColor:"",tooltipFormatter:"{marker} {a} {c}",xAxisSplitLineShow:!0,xAxisSplitLineStyleColor:"#333",xAxisLabelInterval:0,xAxisLabelColor:"#333",xAxisLabelWidth:void 0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisMinInterval:0,yAxisMinInterval:0,yAxisLabelWidth:void 0,yAxisLabelRotate:0,yAxisLabelOverflow:"none",yAxisSplitLineShow:!0,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",barWidth:"40%",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",toolboxShow:!1,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",isUseHorizontalAxis:!1,axisInverse:!1,xAxisInverse:!1,yAxisInverse:!1,isStack:!1,labelShow:!1,labelFontSize:"12px",labelPosition:"inside",labelColor:"",toolboxLocation:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0},line:{name:"折线图",type:"line",width:"400px",height:"400px",legendShow:!0,legendOrient:"horizontal",legendTop:"top",legendLeft:"center",titleText:"",titleSubtext:"",colors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],symbolSize:4,lineStyleWidth:2,smooth:!1,xAxisLabelWidth:void 0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLabelInterval:0,xAxisSplitLineShow:!0,xAxisSplitLineStyleColor:"#333",xAxisLabelColor:"#333",xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisLabelFormatter:"{value}",xAxisMinInterval:0,yAxisMinInterval:0,yAxisSplitLineShow:!0,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",yAxisLineAlwaysDisplay:!1,yAxisLabelFormatter:"{value}",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",tooltipShow:!0,tooltipFormatter:"{marker} {a} {c}",toolboxShow:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",areaStyleOpacity:0},pie:{name:"饼图",type:"pie",width:"400px",height:"400px",titleText:"",titleSubtext:"",colors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],backgroundColor:"",tooltipShow:!0,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,tooltipTextStyleColor:"",tooltipTrigger:"item",tooltipFormatter:"{marker} {b} {c} ({d}%)",legendShow:!0,legendTextStyleColor:"#333",legendOrient:"vertical",legendTop:"top",legendLeft:"left",innerRadius:"0%",outerRadius:"60%",centerLeft:"50%",centerTop:"50%",minAngle:0,labelShow:!0,labelColor:"#333",isUseLabelColors:!1,labelFontSize:12,labelPosition:"outside",labelFormatter:"{b}\\n{d}%",labelLineShow:!0,labelLineLength:10,labelLineLength2:15,roseType:"",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",toolboxShow:!1,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息"},customGraph:{name:"自定义图表",type:"customGraph",width:"400px",height:"400px",option:{},optionCode:""},comboGraph:{name:"组合图表",type:"comboGraph",width:"400px",height:"400px",titleText:"",titleSubtext:"",colors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],legendShow:!0,legendTextStyleColor:"#333",legendOrient:"horizontal",legendTop:"top",legendLeft:"center",tooltipShow:!0,tooltipTextStyleColor:"",tooltipTrigger:"item",tooltipFormatter:"{marker} {a} {c}",xAxisLabelInterval:0,xAxisSplitLineShow:!0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLabelWidth:void 0,xAxisSplitLineStyleColor:"#333",xAxisLabelColor:"#333",xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisMinInterval:0,yAxisMinInterval:0,yAxisSplitLineShow:!0,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",yAxisLineAlwaysDisplay:!1,seriesTypes:[{type:"bar",axisIndex:0},{type:"line",axisIndex:0}],yAxis:[{axisLabelFormatter:"{value}"},{axisLabelFormatter:"{value}"}],gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",toolboxShow:!1,toolboxLocation:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",areaStyleOpacity:0,symbolSize:4,lineStyleWidth:2,smooth:!1,barWidth:"40%"}},br={name:"表格",type:"table",size:"medium",allOverflow:"title",hoverRow:!0,hoverColor:"#f5f7fa",headerCellStyleMethod:"",rowStyleMethod:"",boderList:[],columnDropEnable:!0,showTotalBool:!1,totalName:"",expandAll:!1},Cr=e.defineComponent({name:"DataViewList",components:{ASpin:P.Spin,ATreeSelect:P.TreeSelect,Draggable:mt},setup(){var x;const t=e.inject(Oe),o=e.unref(e.inject(De)),n=e.inject(Ce),a=e.inject(xe),r=e.computed(()=>{var A;return((A=e.unref(n))==null?void 0:A.dataViewId)||null}),i=e.ref(!1),c=e.ref([]),d=(x=window==null?void 0:window.config)==null?void 0:x.pageId,l=e.reactive({title:"已选",value:"YXJG",id:"YXJG",pId:"0",disabled:!0,selectable:!1,isLeaf:!0}),s=async()=>{var y,_;const A=r.value;i.value=!0;try{const{data:E}=await t.post(`${_e}/diagram/sourceList`,{source:"SQL_VIEW",dataViewId:A,pageId:d,pageFlag:!0},{headers:{Authentication:o,operateContext:"ygt"}});i.value=!1,E.success&&((y=c.value)==null||y.push(l),c.value=(_=c.value)==null?void 0:_.concat(p([E.data.rows[0]],"YXJG")))}catch{i.value=!1}},p=(A=[],y)=>{const _=[];return A.forEach(E=>{_.push({id:E.id,pId:y??E.parentId,value:E.id,title:E.name,isLeaf:E.leaf||!1,nature:E.nature,selectable:E.leaf||!1})}),_},u=async(A,y)=>{var T;let _=0;if(A){const{value:V}=A.dataRef;_=V}const{data:E}=await t.post(`${_e}/dataview/treetable`,{pageFlag:!0,pageId:d,parentId:_},{headers:{Authentication:o,operateContext:"ygt"}});E.success&&(c.value=(T=e.unref(c))==null?void 0:T.concat(p(E.data)),y&&e.unref(r)&&await s())},m=A=>{g(A),a({dataViewId:A,classificationList:[],seriesList:[],leftAxisList:[],rightAxisList:[],indicators:[],controlList:[]})},{setDataList:b}=e.inject(hn,{setDataList:A=>A}),h=e.ref(!1),f=e.ref([]),g=async A=>{if(A){f.value=[],h.value=!0;try{const y=await t.post(`${_e}/diagram/sourceList`,{source:"SQL_VIEW",dataViewId:A,pageId:d,pageFlag:!0},{headers:{Authentication:o,operateContext:"ygt"}}),{success:_,data:E={}}=y.data;if(h.value=!1,_){const{rows:T=[]}=E;T==null||T.forEach(V=>{var I;const N=((I=V==null?void 0:V.dataViewColumns)==null?void 0:I.map(M=>({...M,show:!0})))||[];f.value=[...e.unref(f),...N]}),b(e.unref(f))}}catch{h.value=!1}}},w=A=>({TEXT:"字符",NUMBER:"数字",DATE:"时间"})[A],C=(A,y)=>{const _=y[A.oldIndex];if(_){const E={..._,label:_.name,name:_.label};sessionStorage.setItem("indicator-list-item",JSON.stringify(E))}};return e.onMounted(async()=>{await u(void 0,!0),g(e.unref(r))}),{dataViewId:r,handleLoadData:u,treeSelectData:c,treeSelectLoading:i,dataViewList:f,dataViewLoading:h,onDataViewIdChange:m,mapGenericType:w,onDragStart:C}}}),mm="",ne=(t,o)=>{const n=t.__vccOpts||t;for(const[a,r]of o)n[a]=r;return n},wr={class:"data-view-list"},kr={class:"columns"},_r={class:"column-item"},Sr={class:"column-item-name"};function xr(t,o,n,a,r,i){const c=e.resolveComponent("a-tree-select"),d=e.resolveComponent("a-spin"),l=e.resolveComponent("draggable");return e.openBlock(),e.createElementBlock("div",wr,[e.createVNode(d,{"wrapper-class-name":"tree-spin",spinning:t.treeSelectLoading,tip:"视图加载中..."},{default:e.withCtx(()=>[e.createVNode(c,{value:t.dataViewId,style:{width:"100%"},placeholder:"请选择视图","dropdown-style":{maxHeight:"400px",overflow:"auto"},"tree-data":t.treeSelectData,"load-data":t.handleLoadData,"tree-data-simple-mode":"",onChange:t.onDataViewIdChange},null,8,["value","tree-data","load-data","onChange"])]),_:1},8,["spinning"]),e.createElementVNode("div",kr,[e.createVNode(d,{spinning:t.dataViewLoading,tip:"数据加载中..."},{default:e.withCtx(()=>[e.createVNode(l,{modelValue:t.dataViewList,"onUpdate:modelValue":o[0]||(o[0]=s=>t.dataViewList=s),group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,onStart:o[1]||(o[1]=s=>t.onDragStart(s,t.dataViewList))},{item:e.withCtx(({element:s})=>[e.createElementVNode("div",_r,[e.createTextVNode(" 【"+e.toDisplayString(t.mapGenericType(s.genericType))+"】 ",1),e.createElementVNode("span",Sr,e.toDisplayString(s.name),1)])]),_:1},8,["modelValue"])]),_:1},8,["spinning"])])])}const Nr=ne(Cr,[["render",xr],["__scopeId","data-v-4a66f7d2"]]);function Ie(t,o){Ar(t)&&(t="100%");var n=Tr(t);return t=o===360?t:Math.min(o,Math.max(0,parseFloat(t))),n&&(t=parseInt(String(t*o),10)/100),Math.abs(t-o)<1e-6?1:(o===360?t=(t<0?t%o+o:t%o)/parseFloat(String(o)):t=t%o/parseFloat(String(o)),t)}function Ar(t){return typeof t=="string"&&t.indexOf(".")!==-1&&parseFloat(t)===1}function Tr(t){return typeof t=="string"&&t.indexOf("%")!==-1}function Er(t){return t=parseFloat(t),(isNaN(t)||t<0||t>1)&&(t=1),t}function qt(t){return t<=1?"".concat(Number(t)*100,"%"):t}function wo(t){return t.length===1?"0"+t:String(t)}function Vr(t,o,n){return{r:Ie(t,255)*255,g:Ie(o,255)*255,b:Ie(n,255)*255}}function ko(t,o,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(o-t)*(6*n):n<1/2?o:n<2/3?t+(o-t)*(2/3-n)*6:t}function Lr(t,o,n){var a,r,i;if(t=Ie(t,360),o=Ie(o,100),n=Ie(n,100),o===0)r=n,i=n,a=n;else{var c=n<.5?n*(1+o):n+o-n*o,d=2*n-c;a=ko(d,c,t+1/3),r=ko(d,c,t),i=ko(d,c,t-1/3)}return{r:a*255,g:r*255,b:i*255}}function Br(t,o,n){t=Ie(t,255),o=Ie(o,255),n=Ie(n,255);var a=Math.max(t,o,n),r=Math.min(t,o,n),i=0,c=a,d=a-r,l=a===0?0:d/a;if(a===r)i=0;else{switch(a){case t:i=(o-n)/d+(o<n?6:0);break;case o:i=(n-t)/d+2;break;case n:i=(t-o)/d+4;break}i/=6}return{h:i,s:l,v:c}}function Or(t,o,n){t=Ie(t,360)*6,o=Ie(o,100),n=Ie(n,100);var a=Math.floor(t),r=t-a,i=n*(1-o),c=n*(1-r*o),d=n*(1-(1-r)*o),l=a%6,s=[n,c,i,i,d,n][l],p=[d,n,n,c,i,i][l],u=[i,i,d,n,n,c][l];return{r:s*255,g:p*255,b:u*255}}function Dr(t,o,n,a){var r=[wo(Math.round(t).toString(16)),wo(Math.round(o).toString(16)),wo(Math.round(n).toString(16))];return a&&r[0].startsWith(r[0].charAt(1))&&r[1].startsWith(r[1].charAt(1))&&r[2].startsWith(r[2].charAt(1))?r[0].charAt(0)+r[1].charAt(0)+r[2].charAt(0):r.join("")}function xn(t){return Ee(t)/255}function Ee(t){return parseInt(t,16)}var Nn={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Tt(t){var o={r:0,g:0,b:0},n=1,a=null,r=null,i=null,c=!1,d=!1;return typeof t=="string"&&(t=$r(t)),typeof t=="object"&&(We(t.r)&&We(t.g)&&We(t.b)?(o=Vr(t.r,t.g,t.b),c=!0,d=String(t.r).substr(-1)==="%"?"prgb":"rgb"):We(t.h)&&We(t.s)&&We(t.v)?(a=qt(t.s),r=qt(t.v),o=Or(t.h,a,r),c=!0,d="hsv"):We(t.h)&&We(t.s)&&We(t.l)&&(a=qt(t.s),i=qt(t.l),o=Lr(t.h,a,i),c=!0,d="hsl"),Object.prototype.hasOwnProperty.call(t,"a")&&(n=t.a)),n=Er(n),{ok:c,format:t.format||d,r:Math.min(255,Math.max(o.r,0)),g:Math.min(255,Math.max(o.g,0)),b:Math.min(255,Math.max(o.b,0)),a:n}}var Ir="[-\\+]?\\d+%?",Fr="[-\\+]?\\d*\\.\\d+%?",et="(?:".concat(Fr,")|(?:").concat(Ir,")"),_o="[\\s|\\(]+(".concat(et,")[,|\\s]+(").concat(et,")[,|\\s]+(").concat(et,")\\s*\\)?"),So="[\\s|\\(]+(".concat(et,")[,|\\s]+(").concat(et,")[,|\\s]+(").concat(et,")[,|\\s]+(").concat(et,")\\s*\\)?"),Re={CSS_UNIT:new RegExp(et),rgb:new RegExp("rgb"+_o),rgba:new RegExp("rgba"+So),hsl:new RegExp("hsl"+_o),hsla:new RegExp("hsla"+So),hsv:new RegExp("hsv"+_o),hsva:new RegExp("hsva"+So),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function $r(t){if(t=t.trim().toLowerCase(),t.length===0)return!1;var o=!1;if(Nn[t])t=Nn[t],o=!0;else if(t==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n=Re.rgb.exec(t);return n?{r:n[1],g:n[2],b:n[3]}:(n=Re.rgba.exec(t),n?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=Re.hsl.exec(t),n?{h:n[1],s:n[2],l:n[3]}:(n=Re.hsla.exec(t),n?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=Re.hsv.exec(t),n?{h:n[1],s:n[2],v:n[3]}:(n=Re.hsva.exec(t),n?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=Re.hex8.exec(t),n?{r:Ee(n[1]),g:Ee(n[2]),b:Ee(n[3]),a:xn(n[4]),format:o?"name":"hex8"}:(n=Re.hex6.exec(t),n?{r:Ee(n[1]),g:Ee(n[2]),b:Ee(n[3]),format:o?"name":"hex"}:(n=Re.hex4.exec(t),n?{r:Ee(n[1]+n[1]),g:Ee(n[2]+n[2]),b:Ee(n[3]+n[3]),a:xn(n[4]+n[4]),format:o?"name":"hex8"}:(n=Re.hex3.exec(t),n?{r:Ee(n[1]+n[1]),g:Ee(n[2]+n[2]),b:Ee(n[3]+n[3]),format:o?"name":"hex"}:!1)))))))))}function We(t){return!!Re.CSS_UNIT.exec(String(t))}var Kt=2,An=.16,Pr=.05,Mr=.05,jr=.15,Tn=5,En=4,vr=[{index:7,opacity:.15},{index:6,opacity:.25},{index:5,opacity:.3},{index:5,opacity:.45},{index:5,opacity:.65},{index:5,opacity:.85},{index:4,opacity:.9},{index:3,opacity:.95},{index:2,opacity:.97},{index:1,opacity:.98}];function Vn(t){var o=t.r,n=t.g,a=t.b,r=Br(o,n,a);return{h:r.h*360,s:r.s,v:r.v}}function Qt(t){var o=t.r,n=t.g,a=t.b;return"#".concat(Dr(o,n,a,!1))}function Rr(t,o,n){var a=n/100,r={r:(o.r-t.r)*a+t.r,g:(o.g-t.g)*a+t.g,b:(o.b-t.b)*a+t.b};return r}function Ln(t,o,n){var a;return Math.round(t.h)>=60&&Math.round(t.h)<=240?a=n?Math.round(t.h)-Kt*o:Math.round(t.h)+Kt*o:a=n?Math.round(t.h)+Kt*o:Math.round(t.h)-Kt*o,a<0?a+=360:a>=360&&(a-=360),a}function Bn(t,o,n){if(t.h===0&&t.s===0)return t.s;var a;return n?a=t.s-An*o:o===En?a=t.s+An:a=t.s+Pr*o,a>1&&(a=1),n&&o===Tn&&a>.1&&(a=.1),a<.06&&(a=.06),Number(a.toFixed(2))}function On(t,o,n){var a;return n?a=t.v+Mr*o:a=t.v-jr*o,a>1&&(a=1),Number(a.toFixed(2))}function xo(t){for(var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=[],a=Tt(t),r=Tn;r>0;r-=1){var i=Vn(a),c=Qt(Tt({h:Ln(i,r,!0),s:Bn(i,r,!0),v:On(i,r,!0)}));n.push(c)}n.push(Qt(a));for(var d=1;d<=En;d+=1){var l=Vn(a),s=Qt(Tt({h:Ln(l,d),s:Bn(l,d),v:On(l,d)}));n.push(s)}return o.theme==="dark"?vr.map(function(p){var u=p.index,m=p.opacity,b=Qt(Rr(Tt(o.backgroundColor||"#141414"),Tt(n[u]),m*100));return b}):n}var No={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1890FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},Ao={},To={};Object.keys(No).forEach(function(t){Ao[t]=xo(No[t]),Ao[t].primary=Ao[t][5],To[t]=xo(No[t],{theme:"dark",backgroundColor:"#141414"}),To[t].primary=To[t][5]});var Dn=[],Et=[],Ur="insert-css: You need to provide a CSS string. Usage: insertCss(cssString[, options]).";function Gr(){var t=document.createElement("style");return t.setAttribute("type","text/css"),t}function zr(t,o){if(o=o||{},t===void 0)throw new Error(Ur);var n=o.prepend===!0?"prepend":"append",a=o.container!==void 0?o.container:document.querySelector("head"),r=Dn.indexOf(a);r===-1&&(r=Dn.push(a)-1,Et[r]={});var i;return Et[r]!==void 0&&Et[r][n]!==void 0?i=Et[r][n]:(i=Et[r][n]=Gr(),n==="prepend"?a.insertBefore(i,a.childNodes[0]):a.appendChild(i)),t.charCodeAt(0)===65279&&(t=t.substr(1,t.length)),i.styleSheet?i.styleSheet.cssText+=t:i.textContent+=t,i}function In(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Hr(t,r,n[r])})}return t}function Hr(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}function Yr(t,o){process.env.NODE_ENV!=="production"&&!t&&console!==void 0&&console.error("Warning: ".concat(o))}function Wr(t,o){Yr(t,"[@ant-design/icons-vue] ".concat(o))}function Fn(t){return typeof t=="object"&&typeof t.name=="string"&&typeof t.theme=="string"&&(typeof t.icon=="object"||typeof t.icon=="function")}function Eo(t,o,n){return n?e.h(t.tag,In({key:o},n,t.attrs),(t.children||[]).map(function(a,r){return Eo(a,"".concat(o,"-").concat(t.tag,"-").concat(r))})):e.h(t.tag,In({key:o},t.attrs),(t.children||[]).map(function(a,r){return Eo(a,"".concat(o,"-").concat(t.tag,"-").concat(r))}))}function $n(t){return xo(t)[0]}function Pn(t){return t?Array.isArray(t)?t:[t]:[]}var qr=`
1
+ /*! @ecan-bi/indicator-library@1.0.89 */
2
+ (function(me,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("lodash-es"),require("ant-design-vue"),require("vuedraggable"),require("dayjs"),require("ant-design-vue/es/popover/style"),require("ant-design-vue/es/dropdown/style"),require("ant-design-vue/es/table/style"),require("monaco-editor"),require("ant-design-vue/es/collapse/style"),require("echarts")):typeof define=="function"&&define.amd?define(["exports","vue","lodash-es","ant-design-vue","vuedraggable","dayjs","ant-design-vue/es/popover/style","ant-design-vue/es/dropdown/style","ant-design-vue/es/table/style","monaco-editor","ant-design-vue/es/collapse/style","echarts"],e):(me=typeof globalThis<"u"?globalThis:me||self,e(me["@ecan-bi/indicator-library"]={},me.Vue,me.LodashEs,me.AntDesignVue,me.Draggable,me.Dayjs,null,null,null,me.MonacoEditor,null,me.Echarts))})(this,function(me,e,J,j,Et,he,uy,fy,my,qr,hy,Kr){var Yr;"use strict";function Xr(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(o,n,a.get?a:{enumerable:!0,get:()=>t[n]})}}return o.default=t,Object.freeze(o)}const Qr=Xr(Kr),ia=(t,o)=>{if(t.install=n=>{for(const a of[t,...Object.values(o??{})])n.component(a.name,a)},o)for(const[n,a]of Object.entries(o))t[n]=a;return t},Ee="$request",Se=((Yr=window==null?void 0:window.config)==null?void 0:Yr.indicatorURL)||"",Be="INDICATOR_TOKEN",sa="DATA_LIST",Ie="SELECTED_COMPONENT",Ce="GRAPHIC_CONFIG",Ne="UPDATE_GRAPHIC_CONFIG",ca="SHOW_STYLE_CONFIG",da="REFRESH_DATA",Co="CHARTS_OPTIONS",pa="TABLE_OPTIONS",Jr=18,Yo="UPDATE_CHARTS_OPTIONS",qo="UPDATE_TABLE_OPTIONS",Wt="SOURCE_TYPE",wo="CHANGE_CONDITION",ua="DATA_VIEW_COLUMNS",Ue="RENDER_USED_COMPONENTS",ko="UPDATE_USED_COMPONENT",fa="MAP_ATTRIBUTE_PROPS",ma="PAGE_CONFIG",Ko={bar:{name:"柱状图",type:"bar",width:"400px",height:"400px",xAxisLabelFormatter:"{value}",yAxisLabelFormatter:"{value}",yAxisLineAlwaysDisplay:!1,titleText:"",titleSubtext:"",titleFontSize:"12px",titleColor:"#333",fontWeight:400,textAlign:"left",colors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],legendShow:!0,legendTextStyleColor:"#333",legendOrient:"horizontal",legendTop:"top",legendLeft:"center",tooltipShow:!0,tooltipTextStyleColor:"",tooltipFormatter:"{marker} {a} {c}",xAxisSplitLineShow:!0,xAxisSplitLineInterval:0,xAxisSplitAreaShow:!1,xAxisSplitLineStyleColor:"#333",xAxisLabelInterval:0,xAxisLabelColor:"#333",xAxisLabelWidth:void 0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLineShow:!0,xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisMinInterval:0,yAxisMinInterval:0,yAxisLabelWidth:void 0,yAxisLabelRotate:0,yAxisLabelOverflow:"none",yAxisSplitLineShow:!0,yAxisSplitAreaShow:!1,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",valueTypeDataFieldNames:{name:"name",value:"value",type:"type"},keyTypeDataFieldNames:{name:"name",types:[]},dataFieldConfigType:"value",barWidth:"40%",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",graphicConfig:{},toolboxShow:!1,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",isUseHorizontalAxis:!1,axisInverse:!1,xAxisInverse:!1,yAxisInverse:!1,isStack:!1,stackColumns:[],labelShow:!1,labelFontSize:"12px",labelPosition:"inside",labelColor:"",labelWidth:100,labelOverflow:"none",labelFormatter:"{c}",toolboxLocation:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,gradientShow:!1,gradientColors:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientOffset:1,barBorderRadius:"",yAxisLabelShow:!0,yAxisSplitLineType:"solid",xAxisSplitLineType:"solid",legendItemGap:10,legendItemWidth:25,legendItemHeight:14,showBarBackground:!1,legendType:"",legendFontSize:"12px",xAxisLabelFontSize:"12px",yAxisLabelFontSize:"12px",graphicType:"ecanBar",tooltipPosition:"",isShowMarkLine:!1,markLineType:"average",legendFormatter:"{name}",legendWidth:null,legendHeight:null,legendTextWidth:null,legendScroll:!1,yAxisName:"",xAxisName:"",defaultRangeValue:!1,startValue:"",endValue:"",xAxisMaxValue:null,yAxisMaxValue:null,colorsType:"默认"},line:{name:"折线图",type:"line",width:"400px",height:"400px",colors:["#FFBF53","#04B1C2","#F07474","#C55784","#9A5FB3","#CF62D7","#5E78EA","#51B3F0","#69D4DC","#49B788","#9CCC66","#C18C00"],colorsType:"默认",legendShow:!0,legendOrient:"horizontal",legendTop:"top",legendLeft:"center",legendCustomPosition:!1,legendTextStyleColor:"#333",legendTextStyleFontSize:"12px",legendTextItemGap:10,legendTopPadding:10,legendBottomPadding:10,legendLeftPadding:10,legendRightPadding:10,titleText:"",titleSubtext:"",symbolSize:4,lineStyleWidth:2,smooth:!1,xAxisName:"",xAxisType:"category",xAxisShow:!0,xAxisLabelWidth:void 0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLabelInterval:0,xAxisSplitLineShow:!0,xAxisSplitLineStyleColor:"#333",xAxisLabelColor:"#333",xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisLabelFormatter:"{value}",xAxisMinInterval:0,yAxisName:"",yAxisMinInterval:0,yAxisSplitLineShow:!0,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",yAxisLineAlwaysDisplay:!1,yAxisLabelShow:!0,yAxisLabelFormatter:"{value}",yAxisSplitLineType:"solid",xAxisSplitLineType:"solid",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",tooltipShow:!0,tooltipTextStyleColor:"",tooltipFormatter:"{marker} {a} {c}",tooltipBorderColor:"#333",tooltipBackgroundColor:"#fff",toolboxShow:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",areaStyleOpacity:0,titleFontSize:"12px",titleColor:"#333",fontWeight:400,textAlign:"left",titleLeft:"",xAxisSplitAreaShow:!1,xAxisSplitLineInterval:0,xAxisLineShow:!0,yAxisSplitAreaShow:!1,valueTypeDataFieldNames:{name:"name",value:"value",type:"type"},keyTypeDataFieldNames:{name:"name",types:[]},dataFieldConfigType:"value",graphicConfig:{},areaGradientShow:!1,areaGradientColor:"",isBoundaryGap:!0,legendItemGap:10,legendItemWidth:25,legendItemHeight:14,legendType:"",shadowColor:"",shadowBlur:0,shadowOffsetY:0,shadowOffsetX:0,legendFontSize:"12px",xAxisLabelFontSize:"12px",yAxisLabelFontSize:"12px",graphicType:"ecanLine",tooltipPosition:"",isShowMarkLine:!1,markLineType:"average",legendFormatter:"{name}",legendWidth:null,legendHeight:null,legendTextWidth:null,legendScroll:!1,xAxisMaxValue:null,yAxisMaxValue:null},pie:{name:"饼图",type:"pie",width:"400px",height:"400px",titleText:"",titleSubtext:"",colors:["#FFBF53","#04B1C2","#F07474","#C55784","#9A5FB3","#CF62D7","#5E78EA","#51B3F0","#69D4DC","#49B788","#9CCC66","#C18C00"],colorsType:"默认",backgroundColor:"",toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,tooltipShow:!0,tooltipTextStyleColor:"",tooltipTrigger:"item",tooltipFormatter:"{marker} {b} {c} ({d}%)",tooltipBorderColor:"#333",tooltipBackgroundColor:"#fff",legendShow:!0,legendTextStyleColor:"#333",legendOrient:"vertical",legendTop:"top",legendLeft:"left",innerRadius:"0%",outerRadius:"60%",centerLeft:"50%",centerTop:"50%",minAngle:0,labelShow:!0,labelColor:"#333",isUseLabelColors:!1,labelFontSize:12,labelPosition:"outside",labelFormatter:"{b}\\n{d}%",labelLineShow:!0,labelLineLength:10,labelLineLength2:15,roseType:"",gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",toolboxShow:!1,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",titleFontSize:"12px",titleColor:"#333",fontWeight:400,textAlign:"left",titleLeft:"",labelWidth:100,labelOverflow:"none",valueTypeDataFieldNames:{name:"name",value:"value",type:"type"},dataFieldConfigType:"value",graphicConfig:{},legendItemGap:10,legendItemWidth:25,legendItemHeight:14,legendFormatter:"{name}",legendFontSize:"12px",graphicType:"ecanPie",legendWidth:null,legendHeight:null,legendTextWidth:null,legendScroll:!1},customGraph:{name:"自定义图表",type:"customGraph",width:"400px",height:"400px",option:{},optionCode:""},comboGraph:{name:"组合图表",type:"comboGraph",width:"400px",height:"400px",titleText:"",titleSubtext:"",colors:["#FFBF53","#04B1C2","#F07474","#C55784","#9A5FB3","#CF62D7","#5E78EA","#51B3F0","#69D4DC","#49B788","#9CCC66","#C18C00"],colorsType:"默认",legendShow:!0,legendTextStyleColor:"#333",legendOrient:"horizontal",legendTop:"top",legendLeft:"center",tooltipShow:!0,tooltipTextStyleColor:"",tooltipTrigger:"item",tooltipFormatter:"{marker} {a} {c}",tooltipBorderColor:"#333",tooltipBackgroundColor:"#fff",xAxisLabelInterval:0,xAxisSplitLineShow:!0,xAxisLabelRotate:0,xAxisLabelOverflow:"none",xAxisLabelWidth:void 0,xAxisSplitLineStyleColor:"#333",xAxisLabelColor:"#333",xAxisLineStyleColor:"#333",xAxisTickShow:!0,xAxisMinInterval:0,yAxisMinInterval:0,yAxisSplitLineShow:!0,yAxisSplitLineStyleColor:"#333",yAxisLabelColor:"#333",yAxisLineStyleColor:"#333",yAxisLineAlwaysDisplay:!1,yAxisLabelShow:!0,seriesTypes:[{type:"bar",axisIndex:0},{type:"line",axisIndex:0}],yAxis:[{axisLabelFormatter:"{value}"},{axisLabelFormatter:"{value}"}],gridContainLabel:!0,gridTop:"10%",gridBottom:"10%",gridLeft:"5%",gridRight:"5%",toolboxShow:!1,toolboxLocation:!1,toolboxDownloadShow:!0,toolboxDataZoomShow:!0,toolboxInfoShow:!0,toolboxOrient:"horizontal",toolboxItemSize:16,toolboxItemGap:8,toolboxLeft:"right",toolboxTop:"top",toolboxIconStyleBorderColor:"#666",toolboxDownloadUrl:"",toolboxInfoText:"当前无说明信息",areaStyleOpacity:0,symbolSize:4,lineStyleWidth:2,smooth:!1,barWidth:"40%"}},Zr={name:"表格",type:"table",size:"medium",allOverflow:"title",hoverRow:!0,hoverColor:"#f5f7fa",headerCellStyleMethod:"",rowStyleMethod:"",boderList:[],columnDropEnable:!0,showTotalBool:!1,totalName:"",expandAll:!1},ei=e.defineComponent({name:"DataViewList",components:{ASpin:j.Spin,ATreeSelect:j.TreeSelect,Draggable:Et},setup(){var S;const t=e.inject(Ee),o=e.unref(e.inject(Be)),n=e.inject(Ce),a=e.inject(Ne),l=e.computed(()=>{var C;return((C=e.unref(n))==null?void 0:C.dataViewId)||null}),r=e.ref(!1),s=e.ref([]),d=(S=window==null?void 0:window.config)==null?void 0:S.pageId,i=e.reactive({title:"已选",value:"YXJG",id:"YXJG",pId:"0",disabled:!0,selectable:!1,isLeaf:!0}),c=async()=>{var k,_;const C=l.value;r.value=!0;try{const{data:E}=await t.post(`${Se}/diagram/sourceList`,{source:"SQL_VIEW",dataViewId:C,pageId:d,pageFlag:!0},{headers:{Authentication:o,operateContext:"ygt"}});r.value=!1,E.success&&((k=s.value)==null||k.push(i),s.value=(_=s.value)==null?void 0:_.concat(p([E.data.rows[0]],"YXJG")))}catch{r.value=!1}},p=(C=[],k)=>{const _=[];return C.forEach(E=>{_.push({id:E.id,pId:k??E.parentId,value:E.id,title:E.name,isLeaf:E.leaf||!1,nature:E.nature,selectable:E.leaf||!1})}),_},u=async(C,k)=>{var O;let _=0;if(C){const{value:B}=C.dataRef;_=B}const{data:E}=await t.post(`${Se}/dataview/treetable`,{pageFlag:!0,pageId:d,parentId:_},{headers:{Authentication:o,operateContext:"ygt"}});E.success&&(s.value=(O=e.unref(s))==null?void 0:O.concat(p(E.data)),k&&e.unref(l)&&await c())},f=C=>{m(C),a({dataViewId:C,classificationList:[],seriesList:[],leftAxisList:[],rightAxisList:[],indicators:[],controlList:[]})},{setDataList:y}=e.inject(sa,{setDataList:C=>C}),h=e.ref(!1),b=e.ref([]),m=async C=>{if(C){b.value=[],h.value=!0;try{const k=await t.post(`${Se}/diagram/sourceList`,{source:"SQL_VIEW",dataViewId:C,pageId:d,pageFlag:!0},{headers:{Authentication:o,operateContext:"ygt"}}),{success:_,data:E={}}=k.data;if(h.value=!1,_){const{rows:O=[]}=E;O==null||O.forEach(B=>{var D;const L=((D=B==null?void 0:B.dataViewColumns)==null?void 0:D.map(I=>({...I,show:!0})))||[];b.value=[...e.unref(b),...L]}),y(e.unref(b))}}catch{h.value=!1}}},w=C=>({TEXT:"字符",NUMBER:"数字",DATE:"时间"})[C],g=(C,k)=>{const _=k[C.oldIndex];if(_){const E={..._,label:_.name,name:_.label};sessionStorage.setItem("indicator-list-item",JSON.stringify(E))}};return e.onMounted(async()=>{await u(void 0,!0),m(e.unref(l))}),{dataViewId:l,handleLoadData:u,treeSelectData:s,treeSelectLoading:r,dataViewList:b,dataViewLoading:h,onDataViewIdChange:f,mapGenericType:w,onDragStart:g}}}),ky="",oe=(t,o)=>{const n=t.__vccOpts||t;for(const[a,l]of o)n[a]=l;return n},ti={class:"data-view-list"},oi={class:"columns"},ni={class:"column-item"},ai={class:"column-item-name"};function li(t,o,n,a,l,r){const s=e.resolveComponent("a-tree-select"),d=e.resolveComponent("a-spin"),i=e.resolveComponent("draggable");return e.openBlock(),e.createElementBlock("div",ti,[e.createVNode(d,{"wrapper-class-name":"tree-spin",spinning:t.treeSelectLoading,tip:"视图加载中..."},{default:e.withCtx(()=>[e.createVNode(s,{value:t.dataViewId,style:{width:"100%"},placeholder:"请选择视图","dropdown-style":{maxHeight:"400px",overflow:"auto"},"tree-data":t.treeSelectData,"load-data":t.handleLoadData,"tree-data-simple-mode":"",onChange:t.onDataViewIdChange},null,8,["value","tree-data","load-data","onChange"])]),_:1},8,["spinning"]),e.createElementVNode("div",oi,[e.createVNode(d,{spinning:t.dataViewLoading,tip:"数据加载中..."},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:t.dataViewList,"onUpdate:modelValue":o[0]||(o[0]=c=>t.dataViewList=c),group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,onStart:o[1]||(o[1]=c=>t.onDragStart(c,t.dataViewList))},{item:e.withCtx(({element:c})=>[e.createElementVNode("div",ni,[e.createTextVNode(" 【"+e.toDisplayString(t.mapGenericType(c.genericType))+"】 ",1),e.createElementVNode("span",ai,e.toDisplayString(c.name),1)])]),_:1},8,["modelValue"])]),_:1},8,["spinning"])])])}const ri=oe(ei,[["render",li],["__scopeId","data-v-4a66f7d2"]]);function De(t,o){ii(t)&&(t="100%");var n=si(t);return t=o===360?t:Math.min(o,Math.max(0,parseFloat(t))),n&&(t=parseInt(String(t*o),10)/100),Math.abs(t-o)<1e-6?1:(o===360?t=(t<0?t%o+o:t%o)/parseFloat(String(o)):t=t%o/parseFloat(String(o)),t)}function ii(t){return typeof t=="string"&&t.indexOf(".")!==-1&&parseFloat(t)===1}function si(t){return typeof t=="string"&&t.indexOf("%")!==-1}function ci(t){return t=parseFloat(t),(isNaN(t)||t<0||t>1)&&(t=1),t}function xo(t){return t<=1?"".concat(Number(t)*100,"%"):t}function Xo(t){return t.length===1?"0"+t:String(t)}function di(t,o,n){return{r:De(t,255)*255,g:De(o,255)*255,b:De(n,255)*255}}function Qo(t,o,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(o-t)*(6*n):n<1/2?o:n<2/3?t+(o-t)*(2/3-n)*6:t}function pi(t,o,n){var a,l,r;if(t=De(t,360),o=De(o,100),n=De(n,100),o===0)l=n,r=n,a=n;else{var s=n<.5?n*(1+o):n+o-n*o,d=2*n-s;a=Qo(d,s,t+1/3),l=Qo(d,s,t),r=Qo(d,s,t-1/3)}return{r:a*255,g:l*255,b:r*255}}function ui(t,o,n){t=De(t,255),o=De(o,255),n=De(n,255);var a=Math.max(t,o,n),l=Math.min(t,o,n),r=0,s=a,d=a-l,i=a===0?0:d/a;if(a===l)r=0;else{switch(a){case t:r=(o-n)/d+(o<n?6:0);break;case o:r=(n-t)/d+2;break;case n:r=(t-o)/d+4;break}r/=6}return{h:r,s:i,v:s}}function fi(t,o,n){t=De(t,360)*6,o=De(o,100),n=De(n,100);var a=Math.floor(t),l=t-a,r=n*(1-o),s=n*(1-l*o),d=n*(1-(1-l)*o),i=a%6,c=[n,s,r,r,d,n][i],p=[d,n,n,s,r,r][i],u=[r,r,d,n,n,s][i];return{r:c*255,g:p*255,b:u*255}}function mi(t,o,n,a){var l=[Xo(Math.round(t).toString(16)),Xo(Math.round(o).toString(16)),Xo(Math.round(n).toString(16))];return a&&l[0].startsWith(l[0].charAt(1))&&l[1].startsWith(l[1].charAt(1))&&l[2].startsWith(l[2].charAt(1))?l[0].charAt(0)+l[1].charAt(0)+l[2].charAt(0):l.join("")}function ha(t){return Ve(t)/255}function Ve(t){return parseInt(t,16)}var ba={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Yt(t){var o={r:0,g:0,b:0},n=1,a=null,l=null,r=null,s=!1,d=!1;return typeof t=="string"&&(t=yi(t)),typeof t=="object"&&(Qe(t.r)&&Qe(t.g)&&Qe(t.b)?(o=di(t.r,t.g,t.b),s=!0,d=String(t.r).substr(-1)==="%"?"prgb":"rgb"):Qe(t.h)&&Qe(t.s)&&Qe(t.v)?(a=xo(t.s),l=xo(t.v),o=fi(t.h,a,l),s=!0,d="hsv"):Qe(t.h)&&Qe(t.s)&&Qe(t.l)&&(a=xo(t.s),r=xo(t.l),o=pi(t.h,a,r),s=!0,d="hsl"),Object.prototype.hasOwnProperty.call(t,"a")&&(n=t.a)),n=ci(n),{ok:s,format:t.format||d,r:Math.min(255,Math.max(o.r,0)),g:Math.min(255,Math.max(o.g,0)),b:Math.min(255,Math.max(o.b,0)),a:n}}var hi="[-\\+]?\\d+%?",bi="[-\\+]?\\d*\\.\\d+%?",lt="(?:".concat(bi,")|(?:").concat(hi,")"),Jo="[\\s|\\(]+(".concat(lt,")[,|\\s]+(").concat(lt,")[,|\\s]+(").concat(lt,")\\s*\\)?"),Zo="[\\s|\\(]+(".concat(lt,")[,|\\s]+(").concat(lt,")[,|\\s]+(").concat(lt,")[,|\\s]+(").concat(lt,")\\s*\\)?"),ze={CSS_UNIT:new RegExp(lt),rgb:new RegExp("rgb"+Jo),rgba:new RegExp("rgba"+Zo),hsl:new RegExp("hsl"+Jo),hsla:new RegExp("hsla"+Zo),hsv:new RegExp("hsv"+Jo),hsva:new RegExp("hsva"+Zo),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function yi(t){if(t=t.trim().toLowerCase(),t.length===0)return!1;var o=!1;if(ba[t])t=ba[t],o=!0;else if(t==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n=ze.rgb.exec(t);return n?{r:n[1],g:n[2],b:n[3]}:(n=ze.rgba.exec(t),n?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=ze.hsl.exec(t),n?{h:n[1],s:n[2],l:n[3]}:(n=ze.hsla.exec(t),n?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=ze.hsv.exec(t),n?{h:n[1],s:n[2],v:n[3]}:(n=ze.hsva.exec(t),n?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=ze.hex8.exec(t),n?{r:Ve(n[1]),g:Ve(n[2]),b:Ve(n[3]),a:ha(n[4]),format:o?"name":"hex8"}:(n=ze.hex6.exec(t),n?{r:Ve(n[1]),g:Ve(n[2]),b:Ve(n[3]),format:o?"name":"hex"}:(n=ze.hex4.exec(t),n?{r:Ve(n[1]+n[1]),g:Ve(n[2]+n[2]),b:Ve(n[3]+n[3]),a:ha(n[4]+n[4]),format:o?"name":"hex8"}:(n=ze.hex3.exec(t),n?{r:Ve(n[1]+n[1]),g:Ve(n[2]+n[2]),b:Ve(n[3]+n[3]),format:o?"name":"hex"}:!1)))))))))}function Qe(t){return!!ze.CSS_UNIT.exec(String(t))}var _o=2,ya=.16,gi=.05,Ci=.05,wi=.15,ga=5,Ca=4,ki=[{index:7,opacity:.15},{index:6,opacity:.25},{index:5,opacity:.3},{index:5,opacity:.45},{index:5,opacity:.65},{index:5,opacity:.85},{index:4,opacity:.9},{index:3,opacity:.95},{index:2,opacity:.97},{index:1,opacity:.98}];function wa(t){var o=t.r,n=t.g,a=t.b,l=ui(o,n,a);return{h:l.h*360,s:l.s,v:l.v}}function So(t){var o=t.r,n=t.g,a=t.b;return"#".concat(mi(o,n,a,!1))}function xi(t,o,n){var a=n/100,l={r:(o.r-t.r)*a+t.r,g:(o.g-t.g)*a+t.g,b:(o.b-t.b)*a+t.b};return l}function ka(t,o,n){var a;return Math.round(t.h)>=60&&Math.round(t.h)<=240?a=n?Math.round(t.h)-_o*o:Math.round(t.h)+_o*o:a=n?Math.round(t.h)+_o*o:Math.round(t.h)-_o*o,a<0?a+=360:a>=360&&(a-=360),a}function xa(t,o,n){if(t.h===0&&t.s===0)return t.s;var a;return n?a=t.s-ya*o:o===Ca?a=t.s+ya:a=t.s+gi*o,a>1&&(a=1),n&&o===ga&&a>.1&&(a=.1),a<.06&&(a=.06),Number(a.toFixed(2))}function _a(t,o,n){var a;return n?a=t.v+Ci*o:a=t.v-wi*o,a>1&&(a=1),Number(a.toFixed(2))}function en(t){for(var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=[],a=Yt(t),l=ga;l>0;l-=1){var r=wa(a),s=So(Yt({h:ka(r,l,!0),s:xa(r,l,!0),v:_a(r,l,!0)}));n.push(s)}n.push(So(a));for(var d=1;d<=Ca;d+=1){var i=wa(a),c=So(Yt({h:ka(i,d),s:xa(i,d),v:_a(i,d)}));n.push(c)}return o.theme==="dark"?ki.map(function(p){var u=p.index,f=p.opacity,y=So(xi(Yt(o.backgroundColor||"#141414"),Yt(n[u]),f*100));return y}):n}var tn={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1890FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},on={},nn={};Object.keys(tn).forEach(function(t){on[t]=en(tn[t]),on[t].primary=on[t][5],nn[t]=en(tn[t],{theme:"dark",backgroundColor:"#141414"}),nn[t].primary=nn[t][5]});var Sa=[],qt=[],_i="insert-css: You need to provide a CSS string. Usage: insertCss(cssString[, options]).";function Si(){var t=document.createElement("style");return t.setAttribute("type","text/css"),t}function Ni(t,o){if(o=o||{},t===void 0)throw new Error(_i);var n=o.prepend===!0?"prepend":"append",a=o.container!==void 0?o.container:document.querySelector("head"),l=Sa.indexOf(a);l===-1&&(l=Sa.push(a)-1,qt[l]={});var r;return qt[l]!==void 0&&qt[l][n]!==void 0?r=qt[l][n]:(r=qt[l][n]=Si(),n==="prepend"?a.insertBefore(r,a.childNodes[0]):a.appendChild(r)),t.charCodeAt(0)===65279&&(t=t.substr(1,t.length)),r.styleSheet?r.styleSheet.cssText+=t:r.textContent+=t,r}function Na(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Ti(t,l,n[l])})}return t}function Ti(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}function Ai(t,o){process.env.NODE_ENV!=="production"&&!t&&console!==void 0&&console.error("Warning: ".concat(o))}function Oi(t,o){Ai(t,"[@ant-design/icons-vue] ".concat(o))}function Ta(t){return typeof t=="object"&&typeof t.name=="string"&&typeof t.theme=="string"&&(typeof t.icon=="object"||typeof t.icon=="function")}function an(t,o,n){return n?e.h(t.tag,Na({key:o},n,t.attrs),(t.children||[]).map(function(a,l){return an(a,"".concat(o,"-").concat(t.tag,"-").concat(l))})):e.h(t.tag,Na({key:o},t.attrs),(t.children||[]).map(function(a,l){return an(a,"".concat(o,"-").concat(t.tag,"-").concat(l))}))}function Aa(t){return en(t)[0]}function Oa(t){return t?Array.isArray(t)?t:[t]:[]}var Ei=`
3
3
  .anticon {
4
4
  display: inline-block;
5
5
  color: inherit;
@@ -53,12 +53,23 @@
53
53
  transform: rotate(360deg);
54
54
  }
55
55
  }
56
- `,Mn=!1,Kr=function(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:qr;e.nextTick(function(){Mn||(typeof window<"u"&&window.document&&window.document.documentElement&&zr(o,{prepend:!0}),Mn=!0)})},Qr=["icon","primaryColor","secondaryColor"];function Xr(t,o){if(t==null)return{};var n=Jr(t,o),a,r;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)a=i[r],!(o.indexOf(a)>=0)&&Object.prototype.propertyIsEnumerable.call(t,a)&&(n[a]=t[a])}return n}function Jr(t,o){if(t==null)return{};var n={},a=Object.keys(t),r,i;for(i=0;i<a.length;i++)r=a[i],!(o.indexOf(r)>=0)&&(n[r]=t[r]);return n}function Xt(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Zr(t,r,n[r])})}return t}function Zr(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Vt={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function el(t){var o=t.primaryColor,n=t.secondaryColor;Vt.primaryColor=o,Vt.secondaryColor=n||$n(o),Vt.calculated=!!n}function tl(){return Xt({},Vt)}var ht=function(o,n){var a=Xt({},o,n.attrs),r=a.icon,i=a.primaryColor,c=a.secondaryColor,d=Xr(a,Qr),l=Vt;if(i&&(l={primaryColor:i,secondaryColor:c||$n(i)}),Kr(),Wr(Fn(r),"icon should be icon definiton, but got ".concat(r)),!Fn(r))return null;var s=r;return s&&typeof s.icon=="function"&&(s=Xt({},s,{icon:s.icon(l.primaryColor,l.secondaryColor)})),Eo(s.icon,"svg-".concat(s.name),Xt({},d,{"data-icon":s.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"}))};ht.props={icon:Object,primaryColor:String,secondaryColor:String,focusable:String},ht.inheritAttrs=!1,ht.displayName="IconBase",ht.getTwoToneColors=tl,ht.setTwoToneColors=el;const Vo=ht;function ol(t,o){return ll(t)||rl(t,o)||al(t,o)||nl()}function nl(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
57
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function al(t,o){if(t){if(typeof t=="string")return jn(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return jn(t,o)}}function jn(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function rl(t,o){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a=[],r=!0,i=!1,c,d;try{for(n=n.call(t);!(r=(c=n.next()).done)&&(a.push(c.value),!(o&&a.length===o));r=!0);}catch(l){i=!0,d=l}finally{try{!r&&n.return!=null&&n.return()}finally{if(i)throw d}}return a}}function ll(t){if(Array.isArray(t))return t}function vn(t){var o=Pn(t),n=ol(o,2),a=n[0],r=n[1];return Vo.setTwoToneColors({primaryColor:a,secondaryColor:r})}function il(){var t=Vo.getTwoToneColors();return t.calculated?[t.primaryColor,t.secondaryColor]:t.primaryColor}var sl=["class","icon","spin","rotate","tabindex","twoToneColor","onClick"];function cl(t,o){return fl(t)||ul(t,o)||pl(t,o)||dl()}function dl(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
58
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pl(t,o){if(t){if(typeof t=="string")return Rn(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rn(t,o)}}function Rn(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function ul(t,o){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a=[],r=!0,i=!1,c,d;try{for(n=n.call(t);!(r=(c=n.next()).done)&&(a.push(c.value),!(o&&a.length===o));r=!0);}catch(l){i=!0,d=l}finally{try{!r&&n.return!=null&&n.return()}finally{if(i)throw d}}return a}}function fl(t){if(Array.isArray(t))return t}function Un(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Lo(t,r,n[r])})}return t}function Lo(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}function ml(t,o){if(t==null)return{};var n=hl(t,o),a,r;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(r=0;r<i.length;r++)a=i[r],!(o.indexOf(a)>=0)&&Object.prototype.propertyIsEnumerable.call(t,a)&&(n[a]=t[a])}return n}function hl(t,o){if(t==null)return{};var n={},a=Object.keys(t),r,i;for(i=0;i<a.length;i++)r=a[i],!(o.indexOf(r)>=0)&&(n[r]=t[r]);return n}vn("#1890ff");var yt=function(o,n){var a,r=Un({},o,n.attrs),i=r.class,c=r.icon,d=r.spin,l=r.rotate,s=r.tabindex,p=r.twoToneColor,u=r.onClick,m=ml(r,sl),b=(a={anticon:!0},Lo(a,"anticon-".concat(c.name),!!c.name),Lo(a,i,i),a),h=d===""||d||c.name==="loading"?"anticon-spin":"",f=s;f===void 0&&u&&(f=-1,m.tabindex=f);var g=l?{msTransform:"rotate(".concat(l,"deg)"),transform:"rotate(".concat(l,"deg)")}:void 0,w=Pn(p),C=cl(w,2),x=C[0],A=C[1];return e.createVNode("span",Un({role:"img","aria-label":c.name},m,{onClick:u,class:b}),[e.createVNode(Vo,{class:h,icon:c,primaryColor:x,secondaryColor:A,style:g},null)])};yt.props={spin:Boolean,rotate:Number,icon:Object,twoToneColor:String},yt.displayName="AntdIcon",yt.inheritAttrs=!1,yt.getTwoToneColor=il,yt.setTwoToneColor=vn;const we=yt;var yl={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H212V212h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H612V212h200v200zm52 132H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H612V612h200v200zM424 712H296V584c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v128H104c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h128v128c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V776h128c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}}]},name:"appstore-add",theme:"outlined"};const gl=yl;function Gn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){bl(t,r,n[r])})}return t}function bl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Bo=function(o,n){var a=Gn({},o,n.attrs);return e.createVNode(we,Gn({},a,{icon:gl}),null)};Bo.displayName="AppstoreAddOutlined",Bo.inheritAttrs=!1;const Oo=Bo;var Cl={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"outlined"};const wl=Cl;function zn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){kl(t,r,n[r])})}return t}function kl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Do=function(o,n){var a=zn({},o,n.attrs);return e.createVNode(we,zn({},a,{icon:wl}),null)};Do.displayName="CaretDownOutlined",Do.inheritAttrs=!1;const Hn=Do;var _l={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M715.8 493.5L335 165.1c-14.2-12.2-35-1.2-35 18.5v656.8c0 19.7 20.8 30.7 35 18.5l380.8-328.4c10.9-9.4 10.9-27.6 0-37z"}}]},name:"caret-right",theme:"outlined"};const Sl=_l;function Yn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){xl(t,r,n[r])})}return t}function xl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Io=function(o,n){var a=Yn({},o,n.attrs);return e.createVNode(we,Yn({},a,{icon:Sl}),null)};Io.displayName="CaretRightOutlined",Io.inheritAttrs=!1;const Wn=Io;var Nl={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"};const Al=Nl;function qn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Tl(t,r,n[r])})}return t}function Tl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Fo=function(o,n){var a=qn({},o,n.attrs);return e.createVNode(we,qn({},a,{icon:Al}),null)};Fo.displayName="CloseOutlined",Fo.inheritAttrs=!1;const Jt=Fo;var El={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M832 64H296c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h496v688c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V96c0-17.7-14.3-32-32-32zM704 192H192c-17.7 0-32 14.3-32 32v530.7c0 8.5 3.4 16.6 9.4 22.6l173.3 173.3c2.2 2.2 4.7 4 7.4 5.5v1.9h4.2c3.5 1.3 7.2 2 11 2H704c17.7 0 32-14.3 32-32V224c0-17.7-14.3-32-32-32zM350 856.2L263.9 770H350v86.2zM664 888H414V746c0-22.1-17.9-40-40-40H232V264h432v624z"}}]},name:"copy",theme:"outlined"};const Vl=El;function Kn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Ll(t,r,n[r])})}return t}function Ll(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var $o=function(o,n){var a=Kn({},o,n.attrs);return e.createVNode(we,Kn({},a,{icon:Vl}),null)};$o.displayName="CopyOutlined",$o.inheritAttrs=!1;const Bl=$o;var Ol={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};const Dl=Ol;function Qn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Il(t,r,n[r])})}return t}function Il(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Po=function(o,n){var a=Qn({},o,n.attrs);return e.createVNode(we,Qn({},a,{icon:Dl}),null)};Po.displayName="DeleteOutlined",Po.inheritAttrs=!1;const Xn=Po;var Fl={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"};const $l=Fl;function Jn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Pl(t,r,n[r])})}return t}function Pl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Mo=function(o,n){var a=Jn({},o,n.attrs);return e.createVNode(we,Jn({},a,{icon:$l}),null)};Mo.displayName="DoubleRightOutlined",Mo.inheritAttrs=!1;const Ml=Mo;var jl={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};const vl=jl;function Zn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Rl(t,r,n[r])})}return t}function Rl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var jo=function(o,n){var a=Zn({},o,n.attrs);return e.createVNode(we,Zn({},a,{icon:vl}),null)};jo.displayName="DownOutlined",jo.inheritAttrs=!1;const Ul=jo;var Gl={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"};const zl=Gl;function ea(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Hl(t,r,n[r])})}return t}function Hl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var vo=function(o,n){var a=ea({},o,n.attrs);return e.createVNode(we,ea({},a,{icon:zl}),null)};vo.displayName="InfoCircleOutlined",vo.inheritAttrs=!1;const Yl=vo;var Wl={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};const ql=Wl;function ta(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Kl(t,r,n[r])})}return t}function Kl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Ro=function(o,n){var a=ta({},o,n.attrs);return e.createVNode(we,ta({},a,{icon:ql}),null)};Ro.displayName="LoadingOutlined",Ro.inheritAttrs=!1;const Ql=Ro;var Xl={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M904 160H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8zm0 624H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8zm0-312H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8z"}}]},name:"menu",theme:"outlined"};const Jl=Xl;function oa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){Zl(t,r,n[r])})}return t}function Zl(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Uo=function(o,n){var a=oa({},o,n.attrs);return e.createVNode(we,oa({},a,{icon:Jl}),null)};Uo.displayName="MenuOutlined",Uo.inheritAttrs=!1;const na=Uo;var ei={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"minus-circle",theme:"outlined"};const ti=ei;function aa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){oi(t,r,n[r])})}return t}function oi(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Go=function(o,n){var a=aa({},o,n.attrs);return e.createVNode(we,aa({},a,{icon:ti}),null)};Go.displayName="MinusCircleOutlined",Go.inheritAttrs=!1;const ni=Go;var ai={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"plus-circle",theme:"outlined"};const ri=ai;function ra(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){li(t,r,n[r])})}return t}function li(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var zo=function(o,n){var a=ra({},o,n.attrs);return e.createVNode(we,ra({},a,{icon:ri}),null)};zo.displayName="PlusCircleOutlined",zo.inheritAttrs=!1;const ii=zo;var si={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"};const ci=si;function la(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){di(t,r,n[r])})}return t}function di(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Ho=function(o,n){var a=la({},o,n.attrs);return e.createVNode(we,la({},a,{icon:ci}),null)};Ho.displayName="PlusOutlined",Ho.inheritAttrs=!1;const pi=Ho;var ui={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"};const fi=ui;function ia(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){mi(t,r,n[r])})}return t}function mi(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Yo=function(o,n){var a=ia({},o,n.attrs);return e.createVNode(we,ia({},a,{icon:fi}),null)};Yo.displayName="QuestionCircleOutlined",Yo.inheritAttrs=!1;const hi=Yo;var yi={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.1 209.3l-56.4 44.1C775.8 155.1 656.2 92 521.9 92 290 92 102.3 279.5 102 511.5 101.7 743.7 289.8 932 521.9 932c181.3 0 335.8-115 394.6-276.1 1.5-4.2-.7-8.9-4.9-10.3l-56.7-19.5a8 8 0 00-10.1 4.8c-1.8 5-3.8 10-5.9 14.9-17.3 41-42.1 77.8-73.7 109.4A344.77 344.77 0 01655.9 829c-42.3 17.9-87.4 27-133.8 27-46.5 0-91.5-9.1-133.8-27A341.5 341.5 0 01279 755.2a342.16 342.16 0 01-73.7-109.4c-17.9-42.4-27-87.4-27-133.9s9.1-91.5 27-133.9c17.3-41 42.1-77.8 73.7-109.4 31.6-31.6 68.4-56.4 109.3-73.8 42.3-17.9 87.4-27 133.8-27 46.5 0 91.5 9.1 133.8 27a341.5 341.5 0 01109.3 73.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.6 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c-.1-6.6-7.8-10.3-13-6.2z"}}]},name:"reload",theme:"outlined"};const gi=yi;function sa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){bi(t,r,n[r])})}return t}function bi(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Wo=function(o,n){var a=sa({},o,n.attrs);return e.createVNode(we,sa({},a,{icon:gi}),null)};Wo.displayName="ReloadOutlined",Wo.inheritAttrs=!1;const Ci=Wo;var wi={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z"}}]},name:"setting",theme:"outlined"};const ki=wi;function ca(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable}))),a.forEach(function(r){_i(t,r,n[r])})}return t}function _i(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var qo=function(o,n){var a=ca({},o,n.attrs);return e.createVNode(we,ca({},a,{icon:ki}),null)};qo.displayName="SettingOutlined",qo.inheritAttrs=!1;const Si=qo,ge=(t,o)=>{if(typeof t=="string"&&typeof o=="string")return t.toLocaleLowerCase().includes(o.toLocaleLowerCase());if(typeof t=="string"&&Array.isArray(o)){const n=o.length;for(let a=0;a<n;a++){const r=o[a];if(typeof r=="string"&&t.toLocaleLowerCase().includes(r.toLocaleLowerCase()))return!0}}return!1},xi=t=>t.replace(/\\n/g,`
59
- `),gt=(t,o)=>Object.prototype.hasOwnProperty.call(t,o),tt=t=>{const o=[];if(t!=null&&t.length)for(const n of t)n.conditions?o.push(...tt(n.conditions)):(n==null?void 0:n.dataType)==="component"&&o.push(n);return o},da=(t,o)=>{var f;const n=ee.cloneDeep((t==null?void 0:t.controlList)||[]),{classificationList:a=[],rowHeaderList:r=[],dimensionList:i=[],seriesList:c=[],leftAxisList:d=[],rightAxisList:l=[],queryColumnList:s=[],indicators:p=[]}=t;ua(n,o);const u=n,m=[...a,...r,...i,...c,...d,...l,...s,...p],b=[];for(const g of m){const w=tt((g==null?void 0:g.conditions)||[]);if(w!=null&&w.length){const C=w.filter(x=>fa(x,o)?(x==null?void 0:x.dataType)==="component":!1).map(x=>{const A=fa(x,o),y={};return x!=null&&x.dateFormat&&(y.format=x.dateFormat),{conditionKey:x.fieldName,conditionLabel:x.fieldName,conditionName:x.fieldName,conditionValueType:x.fieldType,id:A.id,keyName:x.fieldValue,rule:x.rule,notGlobal:!0,indexCode:x.indexCode,typeGuid:x.typeGuid,indexCodeNum:x.indexCodeNum,...y}});if(C!=null&&C.length)for(const x of C)b.find(A=>A.keyName===x.keyName)||b.push(x)}}const h=b.length;for(let g=0;g<h;g++){const w=b[g];if(w&&!((f=Object.keys(w))!=null&&f.length)||(w==null?void 0:w.conditionKey)==="parentCode")continue;const{id:C,keyName:x,prop:A,format:y,dataType:_="component",customValue:E}=w,T=pa(w);Ko({sqlCondition:T,renderUsedComponents:o,id:C,dateFormat:y,prop:A,keyName:x,dataType:_,customValue:E}),u.push(T)}for(let g=u.length-1;g>=0;g--){const w=u[g];w.globalCondition||tt(u).find(x=>x.alias===w.alias&&x.globalCondition)&&u.splice(g,1)}return u},Lt=(t,o)=>{const n=[];if(t!=null&&t.length){for(const a of t)if(a.variableName){const r={variateName:a.variableName,globalCondition:!1,valueType:a.variableType,alias:a.keyName||""};Ko({sqlCondition:r,renderUsedComponents:o,id:a.id,dateFormat:a.format,prop:a.dateTypeValue,keyName:a.keyName,dataType:a.dataType,customValue:a.variableValue,operateType:a.operateType,operateMode:a.operateMode,operateValue:a.operateValue}),a.format&&(r.dateFormat=a.format),a.label&&(r.label=a.label),n.push(r)}}return n};function pa(t){const{id:o,keyName:n,conditionLabel:a,conditionKey:r,conditionValueType:i,prop:c,rule:d="NONE",notGlobal:l=!1,indexCode:s,indexCodeNum:p,typeGuid:u,dataType:m="component"}=t;let b=n||o;return b&&c&&(b+=`-${c}`),{rule:d,label:a,fieldName:r,fieldValue:"",valueType:i,alias:b,globalCondition:!l,indexCode:s,indexCodeNum:p,typeGuid:u,dataType:m}}const Ni=["keyValue","conditionKey","conditionLabel","conditionName","conditionValueType","customValue","id","keyName"];function ua(t,o){if(t!=null&&t.length)for(const n of t)if(n!=null&&n.conditions)ua(n.conditions,o);else{const{id:a,keyName:r,prop:i,format:c,dataType:d="component",customValue:l}=n,s=pa(n);Ko({sqlCondition:s,renderUsedComponents:o,id:a,dateFormat:c,prop:i,keyName:r,dataType:d,customValue:l});for(const p in s)n[p]=s[p];for(const p of Ni)delete n[p]}}function Ko(t){const{sqlCondition:o,renderUsedComponents:n,id:a,dateFormat:r,prop:i,keyName:c,dataType:d,customValue:l,operateValue:s,operateMode:p,operateType:u}=t,m=n.find(x=>x.id===a),{value:b,format:h="YYYY-MM-DD",operate:f,type:g="",useCurrentTime:w}=m||{},C=r||h;if(ge(g,"date")){let x;if(w?x=ue():x=ue(b),f&&b){const{mode:A,type:y,value:_}=f;if(_)switch(y){case"add":x=x.add(_,A);break;case"minus":x=x.subtract(_,A);break}}if(s&&p&&u)switch(u){case"add":x=x.add(s,p);break;case"minus":x=x.subtract(s,p);break}o.fieldValue=(x==null?void 0:x.format(C))||"",o.dateFormat=C}else if(g==="ecanRangePicker"){const{interval:x,intervalUnit:A,startTime:y,endTime:_}=m||{};let E=i;if(!i){const V=c==null?void 0:c.split("-");V!=null&&V.length&&(E=V[V.length-1])}if(!E)return;let T=null;if(w&&(E==="startTime"?T=ue().subtract(x,A):E==="endTime"&&(T=ue())),m[E]&&(T=ue(m[E])),f){const{type:V,value:N,mode:I}=f;switch(V){case"add":T=T&&T.add(N,I);break;case"minus":T=T&&T.subtract(N,I)}}if(s&&p&&u){if(s==="rangeValue"){if(y&&_){const V=ue(_).diff(ue(y),p)+1;switch(u){case"add":T=T&&T.add(V,p);break;case"minus":T=T&&T.subtract(V,p)}}}else if(!isNaN(+s))switch(u){case"add":T=T&&T.add(s,p);break;case"minus":T=T&&T.subtract(s,p)}}if(T&&(o.fieldValue=T==null?void 0:T.format(C)),E==="rangeValue"&&y&&_){const V=Ai(C);V&&(o.fieldValue=ue(_).diff(ue(y),V)+1)}o.dateFormat=C}else{const x=b&&b.match(/\{(.+?)\}/g);x!=null&&x.length?o.fieldValue="":o.fieldValue=b}d===""&&(o.fieldValue=l||"")}const Zt=t=>{let o="";switch(t){case"ecanDatePicker":case"ecanRangePicker":o="dateChange";break;case"ecanTimeDisplay":o="timeChange";break;case"ecanSelect":case"ecanTreeSelect":o="selectChange";break;case"ecanTabs":o="tabChange";break;case"ecanInput":o="inputChange";break;case"ecanCheckbox":case"ecanRadio":o="checkboxChange";break;case"ecanText":o="valueChange";break;case"ecanImage":o="click";break}return o};function fa(t,o){var n;if(t.componentId)return o.find(a=>a.id===t.componentId);if(t.dataType==="component")if(t.fieldType==="DATE"){const a=(n=t.fieldValue)==null?void 0:n.split("-");return a!=null&&a.length?a[0]:null}else return o.find(a=>a.keyName===t.fieldValue);else return null}function Ai(t){const o=t.split("-");let n="";if(o!=null&&o.length)switch(o[o.length-1]){case"YYYY":n="year";break;case"MM":n="month";break;case"DD":n="day";break}return n}const ma=t=>({DIM:"维度",BUILT_IN_DIM:"维度",IDX:"指标",BUILT_IN_IDX:"指标",FIELD:"数据集"})[t],ha=t=>({0:"文本",1:"数值",2:"日期"})[t],ya=t=>t==="0"?"手工录入":t==="1"?"系统取数":t==="2"?"运算加工":"",ga=t=>{let o="";switch(t){case"1":o="人力系统";break;case"2":o="绩效系统";break;case"3":o="预算系统";break;case"4":o="财务系统";break;case"5":o="成本系统";break;case"6":o="物流系统";break;case"7":o="固定资产系统";break;case"8":o="OA办公系统";break;case"9":o="电子档案系统";break;case"10":o="个人收入系统";break;case"11":o="奖金二次分配系统";break;case"12":o="财务管理系统";break;case"13":o="报销系统";break;case"14":o="科研管理系统";break;case"15":o="审计系统";break;case"16":o="分组器系统";break}return o},ba=t=>t==="0"?"指标库":t==="1"?"视图":t==="2"?"数据集":"其他",Ti=e.defineComponent({name:"IndSourceList",components:{CaretRightOutlined:Wn,CaretDownOutlined:Hn,LoadingOutlined:Ql,Draggable:mt,ATooltip:P.Tooltip},props:{data:{type:Array,default:()=>[]},source:{type:String,default:""},isSub:{type:Boolean,default:!1},hasChildren:{type:Boolean,default:!1},total:{type:Number,default:0}},setup(t,{emit:o,expose:n}){var y;const a=(y=window==null?void 0:window.config)==null?void 0:y.pageId,r=e.inject(Oe),i=e.unref(e.inject(De)),c=e.inject("setItemDisabled",_=>!1),d=e.ref([]),l=e.ref(),s=e.reactive({pageSize:20,currentPage:1,totalResult:0}),p=e.ref(!1),u=e.ref(""),m=e.ref(!1);e.watch(()=>t.data,_=>{t.isSub&&(_==null||_.forEach(E=>{var T;E!=null&&E.isLeaf||(T=E.dataViewColumns)==null||T.forEach(V=>{V.show=!0,V.edit=!1,V.title&&(V.label=V.title)})}),d.value=_)},{deep:!0,immediate:!0});const b=()=>{var _;t.isSub||(_=e.unref(l))==null||_.removeEventListener("scroll",C)},h=async _=>{var T;if(e.unref(p))return;p.value=!0;const E={source:t.source,pageId:a,dataSourceId:"",indexName:u.value};_?(_.loading=!0,E.indexTypeGuid=_.indexTypeGuid,E.isLeaf=_.isLeaf):s&&(E.queryRequest={pageSize:s.pageSize,pageNum:s.currentPage});try{const V=await r.post(`${_e}/diagram/sourceList`,E,{headers:{Authentication:i,operateContext:"ygt"}}),{success:N,data:I={}}=V.data;if(N){const{rows:M=[],total:j=0}=I;M==null||M.forEach(B=>{var F;(_==null?void 0:_.isLeaf)==="1"?(F=B.dataViewColumns)==null||F.forEach(O=>{O.show=!0,O.edit=!1,O.title&&(O.label=O.title)}):B.show=!1}),_?(_.children=M,_.show=!0,M!=null&&M.length||(_.noData=!0)):(d.value=e.unref(d).concat(M),s.totalResult=+j,((T=e.unref(d))==null?void 0:T.length)>=j&&b())}_&&(_.loading=!1),p.value=!1}catch{_&&(_.loading=!1),p.value=!1}},f=async _=>{const E=d.value[_],{children:T=[]}=E;T!=null&&T.length?E.show=!E.show:!E.noData&&E.isLeaf?h(E):E.noData&&(E.show=!E.show)},g=(_,E)=>{o("onDragStart",_,E)},w=_=>{_.show=!_.show},C=_=>{_.target.scrollTop+_.target.clientHeight+20>=_.target.scrollHeight&&(s.currentPage++,h())},x=async()=>{await h(),e.nextTick(async()=>{e.unref(l).scrollHeight===e.unref(l).clientHeight&&s.totalResult>e.unref(d).length&&(s.currentPage++,x())})},A=async _=>{var E;b(),m.value=!0,s.currentPage=1,s.totalResult=0,d.value=[],u.value=_,await x(),m.value=!1,(E=e.unref(l))==null||E.addEventListener("scroll",C)};return e.onMounted(async()=>{var _;t.isSub||(x(),(_=e.unref(l))==null||_.addEventListener("scroll",C))}),e.onUnmounted(()=>{b()}),n({handleSearch:A}),{columnRef:l,sourceList:d,searchLoading:m,onToggleGroup:f,onToggleSource:w,setItemDisabled:c,onDragStart:g,mapDataSetScope:ha,mapScope:ma,getLoadType:ya,getUseType:ga,getSourceType:ba}}}),hm="",Ei={key:0,class:"no-data"},Vi={class:"column-item"},Li=["onClick"],Bi={key:3,class:"item-name"},Oi={key:0},Di={class:"column-item"},Ii={key:0},Fi={key:1},$i={key:2},Pi=["onClick"],Mi={class:"column-child-item"},ji={class:"field"},vi={class:"column-child-item-name"};function Ri(t,o,n,a,r,i){const c=e.resolveComponent("loading-outlined"),d=e.resolveComponent("caret-down-outlined"),l=e.resolveComponent("caret-right-outlined"),s=e.resolveComponent("ind-source-list",!0),p=e.resolveComponent("a-tooltip"),u=e.resolveComponent("draggable"),m=e.resolveComponent("a-spin");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["columns",t.isSub?"sub-columns":""]),ref:"columnRef"},[e.createVNode(m,{spinning:t.searchLoading,tip:"数据源加载中..."},{default:e.withCtx(()=>{var b;return[!((b=t.sourceList)!=null&&b.length)&&!t.searchLoading?(e.openBlock(),e.createElementBlock("div",Ei,"暂无数据")):t.hasChildren?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.sourceList,(h,f)=>(e.openBlock(),e.createElementBlock("div",{key:h.indexTypeGuid||h.id},[e.createElementVNode("div",Vi,[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:g=>t.onToggleGroup(f)},[h.loading?(e.openBlock(),e.createBlock(c,{key:0})):h.show?(e.openBlock(),e.createBlock(d,{key:1})):(e.openBlock(),e.createBlock(l,{key:2})),h.isLeaf?(e.openBlock(),e.createElementBlock("span",Bi,e.toDisplayString(h.indexTypeCode+"."+h.indexTypeName),1)):e.createCommentVNode("",!0)],8,Li)]),h.show?(e.openBlock(),e.createElementBlock("div",Oi,[e.createVNode(s,{data:h.children,isSub:!0,hasChildren:h.isLeaf==="0",source:"INDICATOR_LIB",onOnDragStart:t.onDragStart},null,8,["data","hasChildren","onOnDragStart"])])):e.createCommentVNode("",!0)]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(t.sourceList,h=>(e.openBlock(),e.createElementBlock("div",{key:h.id,class:e.normalizeClass(t.setItemDisabled(h.dataViewColumns)?"column-disabled":"")},[e.createElementVNode("div",Di,[e.createVNode(p,null,{title:e.withCtx(()=>[e.createElementVNode("div",null,"加载类型:"+e.toDisplayString(t.getLoadType(h.loadType)),1),h.useType?(e.openBlock(),e.createElementBlock("div",Ii,"数据使用系统:"+e.toDisplayString(t.getUseType(h.useType)),1)):e.createCommentVNode("",!0),h.systemSource?(e.openBlock(),e.createElementBlock("div",Fi,"制度出处:"+e.toDisplayString(h.systemSource),1)):e.createCommentVNode("",!0),h.dataTo?(e.openBlock(),e.createElementBlock("div",$i,"数据来源:"+e.toDisplayString(t.getSourceType(h.dataTo)),1)):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:f=>t.onToggleSource(h)},[h.show?(e.openBlock(),e.createBlock(d,{key:0})):(e.openBlock(),e.createBlock(l,{key:1})),e.createTextVNode(" "+e.toDisplayString((h.indexCode?h.indexCode:"")+" "+h.name),1)],8,Pi)]),_:2},1024)]),h.show?(e.openBlock(),e.createBlock(u,{key:0,modelValue:h.dataViewColumns,"onUpdate:modelValue":f=>h.dataViewColumns=f,group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,disabled:t.setItemDisabled(h.dataViewColumns),onStart:f=>t.onDragStart(f,h)},{item:e.withCtx(({element:f})=>[e.createElementVNode("div",Mi,[e.createElementVNode("span",ji," 【"+e.toDisplayString(f.scope==="FIELD"?t.mapDataSetScope(f.genericType):t.mapScope(f.scope))+"】 ",1),e.createElementVNode("span",vi,e.toDisplayString(f.label),1)])]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","onStart"])):e.createCommentVNode("",!0)],2))),128))]}),_:1},8,["spinning"])],2)}const Ui=ne(Ti,[["render",Ri],["__scopeId","data-v-1b27fabf"]]),Gi=e.defineComponent({name:"DataSourceList",components:{CaretRightOutlined:Wn,CaretDownOutlined:Hn,IndSourceList:Ui,AInputSearch:P.InputSearch,ASpin:P.Spin,APagination:P.Pagination,Draggable:mt,ATooltip:P.Tooltip},setup(){var y;const t=(y=window==null?void 0:window.config)==null?void 0:y.pageId,o=e.inject(Oe),n=e.unref(e.inject(De)),a=e.inject(Ye),r=e.computed(()=>{var _;return(_=e.unref(a))==null?void 0:_.graphicConfig}),i=e.computed(()=>{var _;return(_=e.unref(r))==null?void 0:_.dataSourceId}),c=e.ref([]),d=e.ref(!1),l=e.ref(),s=e.reactive({pageSize:20,currentPage:1,totalResult:0}),p=e.inject(At),u=e.ref(""),m=async()=>{if(e.unref(w).source==="INDICATOR_LIB")return;d.value=!0;const _={source:e.unref(p),indexName:e.unref(u),pageId:t,dataSourceId:e.unref(i),queryRequest:{pageSize:s.pageSize,pageNum:s.currentPage}};_.source==="EDV_DATA_SET"&&(_.edvDataSetName=_.indexName,delete _.indexName);try{const E=await o.post(`${_e}/diagram/sourceList`,_,{headers:{Authentication:n,operateContext:"ygt"}});d.value=!1;const{success:T,data:V={}}=E.data;if(T){const{rows:N=[],total:I=0}=V;N==null||N.forEach(M=>{var j;M.show=!1,(j=M.dataViewColumns)==null||j.forEach(B=>{B.show=!0,B.edit=!1,B.title&&(B.label=B.title)})}),c.value=N,s.totalResult=+I}}catch{d.value=!1}},b=_=>{c.value[_].show=!c.value[_].show},h=()=>{var _;s.currentPage=1,m(),e.unref(w).source==="INDICATOR_LIB"&&((_=e.unref(l))==null||_.handleSearch(e.unref(u)))},f=ee.debounce(()=>{s.currentPage=1,m()},200),g=(_,E)=>{s.pageSize=E,s.currentPage=_,m()};e.onMounted(()=>{m()});const w=e.inject(Ce),C=e.computed(()=>{const _=["classificationList","rowHeaderList","dimensionList","queryColumnList"];let E=[];for(const T in e.unref(w))if(Object.prototype.hasOwnProperty.call(e.unref(w),T)&&_.includes(T)){const V=e.unref(w)[T];Array.isArray(V)&&(E=E.concat(V))}return E}),x=(_=[])=>{let E=!1;if(e.unref(p)==="EDV_DATA_SET"){for(const T of e.unref(C))if(!_.find(N=>N.parentId===T.parentId)){E=!0;break}}else for(const T of e.unref(C))if(!_.find(N=>N.typeGuid===T.typeGuid)){E=!0;break}return E};return e.provide("setItemDisabled",x),{dataSourceList:c,dataSourceLoading:d,pagination:s,onToggleGroup:b,mapScope:ma,mapDataSetScope:ha,onSearch:h,onChange:f,source:p,onPaginationChange:g,searchText:u,setItemDisabled:x,onDragStart:(_,E)=>{const T=E.dataViewColumns[_.oldIndex];let V={};E.dataSetParams&&(V=E.dataSetParams),T&&(sessionStorage.setItem("indicator-list-item",JSON.stringify({...T,dataTo:E.dataTo,dataSetParams:V})),E.dataTo==="1"&&(E!=null&&E.hrpIndexVariates)&&sessionStorage.setItem("indicator-variates",JSON.stringify(E.hrpIndexVariates)),E.dataTo==="2"&&(E!=null&&E.dataSetParams)&&sessionStorage.setItem("indicator-variates",JSON.stringify(E.dataSetParams)))},getSourceType:ba,getLoadType:ya,getUseType:ga,graphicConfig:w,indSourceRef:l}}}),ym="",zi={class:"data-source-list"},Hi={class:"columns"},Yi={class:"column-item"},Wi={key:0},qi={key:1},Ki=["onClick"],Qi={key:0},Xi={class:"column-child-item"},Ji={class:"column-child-item-name"};function Zi(t,o,n,a,r,i){const c=e.resolveComponent("a-input-search"),d=e.resolveComponent("ind-source-list"),l=e.resolveComponent("caret-down-outlined"),s=e.resolveComponent("caret-right-outlined"),p=e.resolveComponent("a-tooltip"),u=e.resolveComponent("draggable"),m=e.resolveComponent("a-spin"),b=e.resolveComponent("a-pagination");return e.openBlock(),e.createElementBlock("div",zi,[e.createVNode(c,{value:t.searchText,"onUpdate:value":o[0]||(o[0]=h=>t.searchText=h),placeholder:"请输入关键字",style:{width:"100%"},onChange:t.onChange,onSearch:t.onSearch},null,8,["value","onChange","onSearch"]),t.graphicConfig.source==="INDICATOR_LIB"?(e.openBlock(),e.createBlock(d,{key:0,ref:"indSourceRef",data:t.dataSourceList,hasChildren:!0,isSub:!1,source:"INDICATOR_LIB",onSetItemDisabled:t.setItemDisabled,onOnDragStart:t.onDragStart},null,8,["data","onSetItemDisabled","onOnDragStart"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",Hi,[e.createVNode(m,{spinning:t.dataSourceLoading,tip:"数据源加载中..."},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dataSourceList,(h,f)=>(e.openBlock(),e.createElementBlock("div",{key:h.id,class:e.normalizeClass(t.setItemDisabled(h.dataViewColumns)?"column-disabled":"")},[e.createElementVNode("div",Yi,[e.createVNode(p,null,{title:e.withCtx(()=>[e.createElementVNode("div",null,"加载类型:"+e.toDisplayString(t.getLoadType(h.loadType)),1),h.useType?(e.openBlock(),e.createElementBlock("div",Wi,"数据使用系统:"+e.toDisplayString(t.getUseType(h.useType)),1)):e.createCommentVNode("",!0),h.systemSource?(e.openBlock(),e.createElementBlock("div",qi,"制度出处:"+e.toDisplayString(h.systemSource),1)):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:g=>t.onToggleGroup(f)},[h.show?(e.openBlock(),e.createBlock(l,{key:0})):(e.openBlock(),e.createBlock(s,{key:1})),e.createTextVNode(" "+e.toDisplayString((h.indexCode?h.indexCode:"")+" "+h.name)+"【"+e.toDisplayString(t.getSourceType(h.dataTo))+"】 ",1)],8,Ki)]),_:2},1024)]),h.show?(e.openBlock(),e.createElementBlock("div",Qi,[e.createVNode(u,{modelValue:h.dataViewColumns,"onUpdate:modelValue":g=>h.dataViewColumns=g,group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,disabled:t.setItemDisabled(h.dataViewColumns),onStart:g=>t.onDragStart(g,h)},{item:e.withCtx(({element:g})=>[e.createElementVNode("div",Xi,[e.createTextVNode(" 【"+e.toDisplayString(g.scope==="FIELD"?t.mapDataSetScope(g.genericType):t.mapScope(g.scope))+"】 ",1),e.createElementVNode("span",Ji,e.toDisplayString(g.label),1)])]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","onStart"])])):e.createCommentVNode("",!0)],2))),128))]),_:1},8,["spinning"])]),e.createVNode(b,{size:"small","show-quick-jumper":"",pageSize:t.pagination.pageSize,"onUpdate:pageSize":o[1]||(o[1]=h=>t.pagination.pageSize=h),total:t.pagination.totalResult,"show-total":h=>`共 ${h} 条`,current:t.pagination.currentPage,"onUpdate:current":o[2]||(o[2]=h=>t.pagination.currentPage=h),onChange:t.onPaginationChange},null,8,["pageSize","total","show-total","current","onChange"])],64))])}const es=ne(Gi,[["render",Zi],["__scopeId","data-v-7b6f9e5d"]]),ts=e.defineComponent({name:"DataList",components:{DataSourceList:es,DataViewList:Nr},setup(){return{source:e.inject(At)}}});function os(t,o,n,a,r,i){const c=e.resolveComponent("data-view-list"),d=e.resolveComponent("data-source-list");return e.openBlock(),e.createElementBlock(e.Fragment,null,[t.source==="SQL_VIEW"?(e.openBlock(),e.createBlock(c,{key:0})):e.createCommentVNode("",!0),t.source==="INDICATOR_LIB"||t.source==="EDV_DATA_SET"?(e.openBlock(),e.createBlock(d,{key:1})):e.createCommentVNode("",!0)],64)}const ns=ne(ts,[["render",os]]),Ca={mounted(t){t.focus()}},as=e.defineComponent({name:"CustomSortModal",props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""},sortList:{type:Array,default:()=>[]}},components:{Draggable:mt,AModal:P.Modal,AButton:P.Button,ASelect:P.Select,ASelectOption:P.SelectOption,DeleteOutlined:Xn},setup(t,{expose:o}){var V;const n=(V=window==null?void 0:window.config)==null?void 0:V.pageId,a=e.inject(Oe),r=e.unref(e.inject(De)),i=e.inject(Ce),c=e.inject(xe),d=e.computed(()=>e.unref(i).source),l=e.computed(()=>e.unref(i).dataViewId),s=e.ref([]),p=e.ref("1"),u=e.ref([]),m=N=>{const I=t.sortList.filter(j=>!e.unref(u).find(B=>B.columnName===j.name)||N.columnName===j.name),M=[];return I.forEach((j,B)=>{M.includes(j.name)?j.name=`${j.name}_ecanrepeat_${B}`:M.push(j.name)}),I},b=async()=>{try{const N=await a.post(`${_e}/diagram/groupvalue`,{source:e.unref(d),dataViewId:e.unref(l),groupColumn:t.item.name,hrpIndexTypeGuid:t.item.typeGuid,pageId:n,pageFlag:!0,edvDataSetId:e.unref(i).edvDataSetId||""},{headers:{Authentication:r,operateContext:"ygt"}}),{success:I,data:M=[]}=N.data;I&&(s.value=M==null?void 0:M.slice(0,200))}catch(N){console.error(N)}},h=()=>{var B,F;const N=((B=e.unref(i)[t.type])==null?void 0:B.slice())||[],I=N[t.index],{label:M,name:j}=t.item;e.unref(p)==="2"?I.sort={label:M,columnName:j,type:"CUSTOM",customOrderColumns:e.unref(s)}:e.unref(p)==="1"&&((F=e.unref(u))!=null&&F.length?I.sort=ee.cloneDeep(e.unref(u)):delete I.sort),c({[t.type]:N})};let f=!1;const g=()=>{f=!0},w=e.ref(!1),C=N=>{var M;const{sort:I}=N;I?Array.isArray(I)?(p.value=((M=I[0])==null?void 0:M.type)==="CUSTOM"?"2":"1",e.unref(p)==="1"?u.value=ee.cloneDeep(I):u.value=[]):(p.value=(I==null?void 0:I.type)==="CUSTOM"?"2":"1",e.unref(p)==="1"?u.value=[ee.cloneDeep(I)]:u.value=[]):u.value=[],w.value=!0},x=()=>{w.value=!1},A=()=>{e.unref(p)==="2"?(f&&h(),f=!1):h(),x()};return o({showModal:C}),e.watch(w,N=>{var I,M;if(N){const j=(M=(I=t.item)==null?void 0:I.sort)==null?void 0:M.customOrderColumns;j==null?b():s.value=j}else s.value=[];window.changeShowTable&&window.changeShowTable(!N)},{flush:"post"}),{visible:w,customSortList:s,activeKey:p,combSortList:u,getSortOptions:m,onChange:g,onDeleteConfig:()=>{var M;const N=((M=e.unref(i)[t.type])==null?void 0:M.slice())||[],I=N[t.index];delete I.sort,c({[t.type]:N}),x()},onCancel:A,onAddSort:()=>{e.unref(u).push({label:"",columnName:null,type:"COMBINATION",order:null})},handleDeleteSort:N=>{u.value.splice(N,1)},onColumnChange:N=>{const I=e.unref(u).find(M=>M.columnName===N);if(I){const M=t.sortList.find(j=>j.name===N);M&&(I.label=M.label,M.defaultCode?I.defaultCode=M.defaultCode:delete I.defaultCode)}}}}}),gm="",rs={class:"button-wrapper"},ls={class:"list-wrapper"},is={class:"button-wrapper"},ss={class:"sort-item"};function cs(t,o,n,a,r,i){const c=e.resolveComponent("a-button"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-select-option"),s=e.resolveComponent("delete-outlined"),p=e.resolveComponent("a-tab-pane"),u=e.resolveComponent("draggable"),m=e.resolveComponent("a-tabs"),b=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(b,{title:"排序配置",visible:t.visible,"destroy-on-close":"",width:"50%",onCancel:t.onCancel,bodyStyle:{height:"70vh",overflow:"auto",padding:"10px 24px"},footer:null},{default:e.withCtx(()=>[e.createVNode(m,{activeKey:t.activeKey,"onUpdate:activeKey":o[1]||(o[1]=h=>t.activeKey=h)},{default:e.withCtx(()=>[e.createVNode(p,{key:"1",tab:"组合排序"},{default:e.withCtx(()=>[e.createElementVNode("div",rs,[e.createVNode(c,{primary:"",onClick:t.onAddSort},{default:e.withCtx(()=>[e.createTextVNode(" 新增 ")]),_:1},8,["onClick"])]),e.createElementVNode("div",ls,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.combSortList,(h,f)=>(e.openBlock(),e.createElementBlock("div",{class:"sort-row",key:f},[e.createVNode(d,{value:h.columnName,"onUpdate:value":g=>h.columnName=g,style:{width:"200px"},placeholder:"维度/指标",options:t.getSortOptions(h),fieldNames:{label:"label",value:"name"},onChange:t.onColumnChange},null,8,["value","onUpdate:value","options","onChange"]),e.createVNode(d,{value:h.order,"onUpdate:value":g=>h.order=g,style:{"margin-left":"10px",width:"100px"},placeholder:"升/降序"},{default:e.withCtx(()=>[e.createVNode(l,{value:"ASC"},{default:e.withCtx(()=>[e.createTextVNode("升序")]),_:1}),e.createVNode(l,{value:"DESC"},{default:e.withCtx(()=>[e.createTextVNode("降序")]),_:1})]),_:2},1032,["value","onUpdate:value"]),e.createVNode(s,{style:{color:"red","margin-left":"10px"},onClick:g=>t.handleDeleteSort(f)},null,8,["onClick"])]))),128))])]),_:1}),e.createVNode(p,{key:"2",tab:"自定义排序","force-render":""},{default:e.withCtx(()=>[e.createElementVNode("div",is,[e.createVNode(c,{danger:"",onClick:t.onDeleteConfig},{default:e.withCtx(()=>[e.createTextVNode(" 删除配置 ")]),_:1},8,["onClick"])]),e.createVNode(u,{modelValue:t.customSortList,"onUpdate:modelValue":o[0]||(o[0]=h=>t.customSortList=h),class:"custom-sort-list","item-key":"id",put:!1,onChange:t.onChange},{item:e.withCtx(({element:h})=>[e.createElementVNode("div",ss,e.toDisplayString(h),1)]),_:1},8,["modelValue","onChange"])]),_:1})]),_:1},8,["activeKey"])]),_:1},8,["visible","onCancel"])}const ds=ne(as,[["render",cs],["__scopeId","data-v-6a468e35"]]),ps=e.defineComponent({name:"CustomGroupModal",directives:{focus:Ca},components:{CloseOutlined:Jt,AModal:P.Modal,ASelect:P.Select,ASelectOption:P.SelectOption,AButton:P.Button,AInput:P.Input,ACheckbox:P.Checkbox,ACollapse:P.Collapse,ACollapsePanel:P.CollapsePanel,ATag:P.Tag,ACheckableTag:P.CheckableTag},props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""}},setup(t,{expose:o}){var R;const n=e.inject(Oe),a=(R=window==null?void 0:window.config)==null?void 0:R.pageId,r=e.unref(e.inject(De));let i=!1;const c=e.computed(()=>`自定义分组-${t.item.label}`),d=e.ref(null),l=e.ref([]),s=e.ref([]),p=e.computed(()=>{const S=e.unref(s).map(L=>L.title);return new Set(S)}),u=e.ref([]);e.watch(()=>e.unref(s).length,S=>{u.value=new Array(S).fill(!1)});const m=e.computed(()=>{let S=0;return e.unref(s).forEach(L=>{var k;(k=L.data)==null||k.forEach(D=>{D.checked&&S++})}),S}),b=()=>{const S=e.unref(d);if(!S){P.message.error("创建分组名不能空");return}e.unref(p).has(S)?P.message.error("分组名已存在,请重新命名"):(e.unref(s).push({title:S,data:[]}),i=!0)},h=S=>{e.unref(s).splice(S,1),i=!0},f=e.ref(null),g=()=>{if(e.unref(m)===0){P.message.error("当前移入分组已选个数为0");return}const S=e.unref(f);if(S==null){P.message.error("请选择移入分组");return}if(!e.unref(s)[S]){P.message.error("移入分组不存在,请重新选择");return}const L=[],k=e.unref(s).length;for(let D=0;D<k;D++){const $=e.unref(s)[D];e.unref(s)[D].data=$.data.filter(z=>(z.checked&&L.push({...z,checked:!1}),!z.checked))}e.unref(s)[S].data=[...L,...e.unref(s)[S].data],i=!0},w=S=>{e.unref(u)[S]=!0},C=S=>{e.unref(u)[S]=!1},x=(S,L)=>{const k=S.target.value;e.unref(p).has(k)&&P.message.error("组名不能相同,请修改"),e.unref(s)[L].title=k,i=!0},A=e.inject(Ce),y=e.inject(xe),_=e.computed(()=>e.unref(A).source),E=e.computed(()=>e.unref(A).dataViewId),T=e.ref(!1),V=()=>{var W,Q;const S=e.unref(s);let L="";e.unref(T)&&(L=(W=S[0])==null?void 0:W.title);const k=S==null?void 0:S.length,D={};for(let Z=1;Z<k;Z++){const oe=S[Z]||{},{title:ie,data:se}=oe;D[ie]=(se==null?void 0:se.map(je=>je.label))||[]}const $=((Q=e.unref(A)[t.type])==null?void 0:Q.slice())||[],z=$[t.index];z.customGroup={groupInfoMap:D,otherGroupName:L},y({[t.type]:$})},N=e.ref(!1),I=()=>{N.value=!0},M=()=>{N.value=!1},j=()=>{M(),i&&V(),i=!1},B=()=>{i=!0},F=new Set,O=async()=>{const S=t.item.customGroup||{},L=S.otherGroupName,k=S.groupInfoMap;(L===""||L==null)&&(T.value=!1),e.unref(s)[0]={title:L||"未分组",data:[]};let D=1;for(const $ in k)if(Object.prototype.hasOwnProperty.call(k,$)){const W=k[$].map(Q=>(F.add(Q),{label:Q,checked:!1}));e.unref(s)[D]={title:$,data:W},D++}await G()},G=async()=>{var S;try{const L=await n.post(`${_e}/diagram/groupvalue`,{source:e.unref(_),dataViewId:e.unref(E),groupColumn:t.item.name,hrpIndexTypeGuid:t.item.typeGuid,pageId:a,pageFlag:!0,edvDataSetId:e.unref(A).edvDataSetId||""},{headers:{Authentication:r,operateContext:"ygt"}}),{success:k,data:D=[]}=L.data;if(k){const $=[];(S=D==null?void 0:D.slice(0,200))==null||S.forEach(z=>{F.has(z)||$.push({label:z,checked:!1})}),e.unref(s)[0].data=$}}catch(L){console.error(L)}};return e.watch(N,S=>{S&&O(),window.changeShowTable&&window.changeShowTable(!S)},{flush:"post"}),o({showModal:I}),{visible:N,title:c,activeKey:l,customGroupList:s,onCancel:j,useOtherGroup:T,selectCount:m,createGroupTitle:d,onAddGroup:b,onDeleteGroup:h,onMoveInGroup:g,selectGroupIndex:f,onEditTitle:w,onTitleChange:x,onFinishEditTitle:C,onUseOtherGroup:B,customGroupEditTitleList:u}}}),bm="",Cm="",us={class:"custom-group-header"},fs={class:"move-and-create"},ms={class:"select-tip"},hs={class:"select-count"},ys={class:"create-group"},gs={class:"custom-group-content"},bs=["onClick"],Cs={class:"extra"},ws={class:"custom-group-list"},ks={class:"text"};function _s(t,o,n,a,r,i){const c=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-button"),s=e.resolveComponent("a-input"),p=e.resolveComponent("a-checkbox"),u=e.resolveComponent("a-tag"),m=e.resolveComponent("close-outlined"),b=e.resolveComponent("a-checkable-tag"),h=e.resolveComponent("a-collapse-panel"),f=e.resolveComponent("a-collapse"),g=e.resolveComponent("a-modal"),w=e.resolveDirective("focus");return e.openBlock(),e.createBlock(g,{title:t.title,visible:t.visible,"destroy-on-close":"",width:"50%",bodyStyle:{height:"70vh",overflow:"auto",display:"flex",flexDirection:"column"},footer:null,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",us,[e.createElementVNode("div",fs,[e.createElementVNode("div",null,[e.createElementVNode("span",ms,[e.createTextVNode(" 已选"),e.createElementVNode("span",hs,e.toDisplayString(t.selectCount),1),e.createTextVNode("个 ")]),e.createVNode(d,{value:t.selectGroupIndex,"onUpdate:value":o[0]||(o[0]=C=>t.selectGroupIndex=C),class:"select-group",placeholder:"请选择移入分组"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.customGroupList,(C,x)=>(e.openBlock(),e.createBlock(c,{key:x},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(C.title),1)]),_:2},1024))),128))]),_:1},8,["value"]),e.createVNode(l,{onClick:t.onMoveInGroup},{default:e.withCtx(()=>[e.createTextVNode("移入分组")]),_:1},8,["onClick"])]),e.createElementVNode("div",ys,[e.createTextVNode(" 创建分组: "),e.createVNode(s,{class:"create-group-name",value:t.createGroupTitle,"onUpdate:value":o[1]||(o[1]=C=>t.createGroupTitle=C),placeholder:"请输入创建分组名",onPressEnter:t.onAddGroup},null,8,["value","onPressEnter"])])]),e.createElementVNode("div",null,[e.createVNode(p,{checked:t.useOtherGroup,"onUpdate:checked":o[2]||(o[2]=C=>t.useOtherGroup=C),onChange:t.onUseOtherGroup},{default:e.withCtx(()=>[e.createTextVNode(" 将未分组设为其他分组 ")]),_:1},8,["checked","onChange"])])]),e.createElementVNode("div",gs,[e.createVNode(f,{activeKey:t.activeKey,"onUpdate:activeKey":o[3]||(o[3]=C=>t.activeKey=C),ghost:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.customGroupList,(C,x)=>(e.openBlock(),e.createBlock(h,{key:x},{header:e.withCtx(()=>[t.customGroupEditTitleList[x]?e.withDirectives((e.openBlock(),e.createBlock(s,{key:1,class:"edit-title-input",value:C.title,size:"small",onChange:A=>t.onTitleChange(A,x),onBlur:A=>t.onFinishEditTitle(x),onPressEnter:A=>t.onFinishEditTitle(x)},null,8,["value","onChange","onBlur","onPressEnter"])),[[w]]):(e.openBlock(),e.createElementBlock("div",{key:0,onClick:e.withModifiers(A=>t.onEditTitle(x),["prevent","stop"])},e.toDisplayString(C.title),9,bs))]),extra:e.withCtx(()=>[e.createElementVNode("div",Cs,[x===0&&t.useOtherGroup?(e.openBlock(),e.createBlock(u,{key:0,class:"tag",color:"blue"},{default:e.withCtx(()=>[e.createTextVNode(" 其他组 ")]),_:1})):e.createCommentVNode("",!0),x!==0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(u,{class:"tag",color:"green"},{default:e.withCtx(()=>[e.createTextVNode(" 自定义组 ")]),_:1}),e.createVNode(m,{onClick:e.withModifiers(A=>t.onDeleteGroup(x),["prevent","stop"])},null,8,["onClick"])],64)):e.createCommentVNode("",!0)])]),default:e.withCtx(()=>[e.createElementVNode("div",ws,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.data,(A,y)=>(e.openBlock(),e.createBlock(b,{color:"red",checked:A.checked,"onUpdate:checked":_=>A.checked=_,class:"custom-group",key:y},{default:e.withCtx(()=>[e.createElementVNode("span",ks,e.toDisplayString(A.label),1)]),_:2},1032,["checked","onUpdate:checked"]))),128))])]),_:2},1024))),128))]),_:1},8,["activeKey"])])]),_:1},8,["title","visible","onCancel"])}const Ss=ne(ps,[["render",_s],["__scopeId","data-v-a0733a80"]]);let Se=(t=21)=>{let o="",n=crypto.getRandomValues(new Uint8Array(t));for(;t--;){let a=n[t]&63;a<36?o+=a.toString(36):a<62?o+=(a-26).toString(36).toUpperCase():a<63?o+="_":o+="-"}return o};var xs=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Qo={},Ns={get exports(){return Qo},set exports(t){Qo=t}};(function(t,o){(function(n,a){t.exports=a()})(xs,function(){var n="month",a="quarter";return function(r,i){var c=i.prototype;c.quarter=function(s){return this.$utils().u(s)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(s-1))};var d=c.add;c.add=function(s,p){return s=Number(s),this.$utils().p(p)===a?this.add(3*s,n):d.bind(this)(s,p)};var l=c.startOf;c.startOf=function(s,p){var u=this.$utils(),m=!!u.u(p)||p;if(u.p(s)===a){var b=this.quarter()-1;return m?this.month(3*b).startOf(n).startOf("day"):this.month(3*b+2).endOf(n).endOf("day")}return l.bind(this)(s,p)}}})})(Ns);const As=Qo;ue.extend(As);const Ts=e.defineComponent({name:"Condition",components:{CloseOutlined:Jt,DownOutlined:Ul,AppstoreAddOutlined:Oo,ASelect:P.Select,AInput:P.Input,ADatePicker:P.DatePicker,AButton:P.Button,ADropdown:P.Dropdown,AMenu:P.Menu,AMenuItem:P.MenuItem,ASubMenu:P.SubMenu,APopover:P.Popover,ATabs:P.Tabs,ATabPane:P.TabPane,ARadioGroup:P.RadioGroup,ARadio:P.Radio,AInputNumber:P.InputNumber,ASelectOption:P.SelectOption,MenuOutlined:na},props:{data:{type:Object,default:()=>({})},level:{type:Number,default:0},index:{type:Number,default:0},type:{type:String,default:""},path:{type:String,default:""}},setup(t){var Nt,dt,Le,Qe,Xe,Je,Be,pt,Ze,at,ut,go,Gt,zt,Ht;const o=(Nt=window==null?void 0:window.config)==null?void 0:Nt.pageId,n=e.inject(Ce),a=e.inject(Oe),r=e.unref(e.inject(De)),i=e.inject(wn),c=e.inject(ve),d=e.ref(!1),l=ue(),s=e.computed(()=>{var q;const H=[];return(q=e.unref(c))==null||q.forEach(X=>{const{keyName:te="",id:ae="",type:fe}=X;fe==="ecanRangePicker"?H.push({value:`${ae}-startTime`,label:`${te||ae}-开始时间值`,keyName:`${te||ae}-startTime`,id:ae},{value:`${ae}-endTime`,label:`${te||ae}-结束时间值`,keyName:`${te||ae}-endTime`,id:ae}):H.push({value:ae,label:`${te||ae}`,keyName:`${te||ae}`,id:ae})}),H}),p=e.computed(()=>[{label:"父页面",value:"PARENT",id:"PARENT",keyName:"PARENT"},...e.unref(s)]),u=e.computed(()=>{var H;return(H=e.unref(n))==null?void 0:H.dataViewId}),m=e.computed(()=>{var H;return(H=e.unref(n))==null?void 0:H.source}),b=e.ref(!1),h={display:"block",height:"34px",lineHeight:"34px",marginTop:"3px"},f=[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}],g=e.ref({expression:"rangeValue",unit:"YEAR",around:"before"}),w=e.ref([{key:0,value:"",label:"年",type:"years",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"年前",afterLabel:"年后",beforeText:"年初",afterText:"年末"},{key:1,value:"",label:"季度",type:"quarters",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"个季度前",afterLabel:"个季度后",beforeText:"季度初",afterText:"季度末"},{key:2,value:"",label:"月",type:"months",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"个月前",afterLabel:"个月后",beforeText:"月初",afterText:"月末"},{key:3,value:"",label:"周",type:"weeks",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"周前",afterLabel:"周后",beforeText:"",afterText:""},{key:4,value:"",label:"天",type:"days",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"天前",afterLabel:"天后",beforeText:"今天",afterText:""}]),C=[{label:"年份",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"季的季度",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"月的月份",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"周的周",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"天的日期",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"}],x=[{label:"时间值",value:"time"},{label:"过滤组件值",value:"component"}],A=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],y=e.ref({fieldName:(dt=t.data)==null?void 0:dt.fieldName,fieldType:(Le=t.data)==null?void 0:Le.fieldType,rule:(Qe=t.data)==null?void 0:Qe.rule,id:(Xe=t.data)==null?void 0:Xe.id,fieldValue:_(),label:(Je=t.data)==null?void 0:Je.label,targetSource:"",typeGuid:(Be=t.data)==null?void 0:Be.typeGuid,indexCode:(pt=t.data)==null?void 0:pt.indexCode,indexCodeNum:(Ze=t.data)==null?void 0:Ze.indexCodeNum,dataType:((at=t.data)==null?void 0:at.dataType)||"",componentId:((ut=t.data)==null?void 0:ut.componentId)||"",useCurrentTime:!!((go=t.data)!=null&&go.useCurrentTime),keyValue:(Gt=t.data)==null?void 0:Gt.keyValue,modelKey:(zt=t.data)==null?void 0:zt.modelKey,prop:(Ht=t.data)==null?void 0:Ht.prop});function _(){const{fieldType:H="",dataType:q="",fieldValue:X=""}=t.data;if(H==="DATE"&&q==="time")return X&&ue(X);if(q==="component"){const te=e.unref(s).find(ae=>ae.keyName===X);return te?te.value:X}else return X}const E=e.ref([]),T=e.ref(!1),V=e.computed(()=>y.value.fieldType==="DATE"),N=e.computed(()=>{const H=t.type,{source:q}=e.unref(n);let X=[];const te=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],ae=["controlList","sqlConditions","variableList","variableConditions"];if(q==="EDV_DATA_SET")X=E.value;else if(te.includes(H)){let fe=[];for(const v in e.unref(n))if(Object.prototype.hasOwnProperty.call(e.unref(n),v)&&!ae.includes(v)){const U=e.unref(n)[v];Array.isArray(U)&&(te.includes(v)?fe=fe.concat(U.filter(Y=>Y.show)):fe=fe.concat(U))}X=fe}else["leftAxisList","rightAxisList","indicators"].includes(H)&&(X=e.unref(i));return X.map(fe=>({...fe,label:fe.label||fe.title,value:fe.name}))}),{updateCondition:I,deleteCondition:M,addCondition:j}=e.inject(Cn,{updateCondition:(H,q,X)=>{},deleteCondition:(H,q)=>{},addCondition:(H,q,X)=>{}}),B=()=>{M(t.index,t.path)};e.watch(y,H=>{const q=ee.cloneDeep(H);H.fieldType==="DATE"&&H.dataType!=="component"&&H.fieldValue&&(q.fieldValue=H.fieldValue.format(H.dateFormat)),I(q,t.index,t.path)},{deep:!0}),e.watch(d,H=>{y.value.fieldValue="",y.value.useCurrentTime=H});const F=H=>{var re;const q=e.unref(N).find(le=>le.value===H)||{},{name:X,genericType:te,id:ae,edvDataSetId:fe,label:v,typeGuid:U,indexCode:Y,indexCodeNum:K}=q;y.value={id:ae,fieldName:X,fieldType:te,label:v,rule:"",fieldValue:te==="DATE"?null:void 0,targetSource:"",typeGuid:U,indexCode:Y,edvDataSetId:fe,indexCodeNum:K,dataType:"",useCurrentTime:!1,keyValue:((re=e.unref(y))==null?void 0:re.keyValue)||Se(),modelKey:"",prop:""}},O=H=>{const q=e.unref(s).find(X=>X.value===H)||{};e.unref(y).componentId=q.id||""},G=e.computed(()=>{const H=e.unref(y).fieldType;return H==="TEXT"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"包含",value:"LIKE"},{label:"不包含",value:"NOT_LIKE"},{label:"开头是",value:"LIKE%"},{label:"结尾是",value:"%LIKE"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"}]:H==="NUMBER"?[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:H==="DATE"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]}),R=e.computed(()=>{let H="";const q=e.unref(G).find(X=>X.value===e.unref(y).rule);return q&&(H=q.label),H}),S=e.computed(()=>{let H={fontSize:"12px"};return e.unref(R)||(H={...H,position:"absolute",right:"11px",top:"9px"}),H}),L=e.ref([]),k=async()=>{var H;if(!(e.unref(L).length>0))try{const q=await a.post(`${_e}/diagram/groupvalue`,{source:e.unref(m),dataViewId:e.unref(u),groupColumn:e.unref(y).fieldName,hrpIndexTypeGuid:e.unref(y).typeGuid,pageId:o,pageFlag:!0,edvDataSetId:e.unref(y).edvDataSetId||""},{headers:{Authentication:r,operateContext:"ygt"}}),{success:X,data:te=[]}=q.data;X&&(L.value=(H=te==null?void 0:te.slice(0,200))==null?void 0:H.map(ae=>({label:ae,value:ae})))}catch(q){console.error(q)}},D=H=>{e.unref(y).rule=H,e.unref(y).fieldValue=e.unref(y).fieldType==="DATE"?null:void 0,["IN","NOT_IN"].includes(H)&&k()},$=H=>{e.unref(y).dataType=H,e.unref(y).fieldValue="",e.unref(y).modelKey="",e.unref(y).prop=""},z=e.ref(),W=H=>{z.value=H,e.unref(y).fieldValue=(H==null?void 0:H.join(","))||""},Q=H=>{const{keyPath:q}=H;e.unref(y).rule=q[0],e.unref(y).dataType=q[1],e.unref(y).dateFormat=q[2],e.unref(y).fieldValue="",e.unref(y).modelKey="",e.unref(y).prop=""};e.onMounted(async()=>{var ae,fe,v,U,Y,K,re,le,J,he;if(y.value.dataType=((ae=t.data)==null?void 0:ae.dataType)||"",y.value.componentId=((fe=t.data)==null?void 0:fe.componentId)||"",y.value.keyValue=(v=t.data)==null?void 0:v.keyValue,y.value.modelKey=(U=t.data)==null?void 0:U.modelKey,y.value.prop=(Y=t.data)==null?void 0:Y.prop,e.unref(y).fieldType==="DATE"){const{activeKey:de,dateCalcTypes:ce=[]}=t.data||{};if(e.unref(y).dateFormat=(K=t.data)==null?void 0:K.dateFormat,e.unref(y).activeKey=de,e.unref(y).calcWays=((re=t.data)==null?void 0:re.calcWays)||[],e.unref(y).dateCalcTypes=ce,e.unref(y).useCurrentTime&&e.unref(y).dataType!=="component"&&(d.value=!0),de===5){const ye=e.unref(y).calcWays[0];if(ye){const me=ye.split("-");e.unref(g).expression=me[0],e.unref(g).around=me[1]}e.unref(g).unit=ce[0]||"YEAR"}else{e.unref(y).radioValue=((le=t.data)==null?void 0:le.radioValue)||"";const ye=e.unref(w).find(me=>{var be;return me.key===((be=t.data)==null?void 0:be.activeKey)});ye&&He(ye,t.data)}}else z.value=((he=(J=t.data)==null?void 0:J.fieldValue)==null?void 0:he.split(","))||[];const{fieldType:H,fieldName:q,rule:X}=y.value;H!=="DATE"&&q&&X&&["IN","NOT_IN"].includes(X)&&k();const{source:te}=e.unref(n);te==="EDV_DATA_SET"&&await a.get(`${_e}/dataset/`+e.unref(n).edvDataSetId||"",{headers:{Authentication:r,operateContext:"ygt"}}).then(de=>{de.data.success&&(console.log(de.data),E.value=de.data.data.column.map(ce=>({...ce,genericType:ce.columnCategory==="0"?"TEXT":ce.columnCategory==="1"?"NUMBER":"DATE",edvDataSetId:de.data.data.id,name:ce.columnName,label:ce.columnName})))}).catch(de=>{console.error(de)})});const Z=H=>{if(e.unref(y).activeKey===H){e.unref(w)[H].radioValue=e.unref(y).radioValue,e.unref(w)[e.unref(y).activeKey]&&(e.unref(w)[e.unref(y).activeKey].radioValue=e.unref(y).radioValue,e.unref(y).radioValue==="1"?e.unref(w)[H].beforeNum=e.unref(y).calcWays[0]:e.unref(y).radioValue==="2"&&(e.unref(w)[H].afterNum=e.unref(y).calcWays[0]));return}e.unref(w).forEach(q=>{q.beforeNum=0,q.afterNum=0,q.radioValue="1",q.value=""})},oe=(H,q)=>{b.value=!0;const X=H.target.value,te=q.type,ae=e.unref(y).dateFormat,fe=Math.abs(q.beforeNum),v=q.afterNum;q.value=pe(X,te,ae,fe,v)},ie=H=>{const q=e.unref(y).activeKey;if(H!==q)return;let X="";q===0?X="years":q===1?X="quarters":q===2?X="months":q===3?X="weeks":q===4&&(X="days");const te=e.unref(y).dateFormat,ae=e.unref(y).radioValue;let fe=0,v=0;return ae==="1"?fe=Math.abs(e.unref(y).calcWays[0]):ae==="2"&&(v=e.unref(y).calcWays[0]),pe(ae,X,te,fe,v)},se=(H,q,X,te)=>{if(b.value=!0,q.radioValue===te){const ae=H.target.value;X==="+"?q.value=ue().add(ae,q.type).format(e.unref(y).dateFormat):q.value=ue().subtract(ae,q.type).format(e.unref(y).dateFormat)}},je=(H,q)=>{e.unref(y).calcWays||(e.unref(y).calcWays=[]),e.unref(y).activeKey=q,e.unref(y).radioValue=H.radioValue,H.radioValue==="1"?e.unref(y).calcWays[0]="-"+H.beforeNum:H.radioValue==="2"?e.unref(y).calcWays[0]=H.afterNum:H.radioValue==="3"?q===4?e.unref(y).calcWays[0]="0":e.unref(y).calcWays[0]="BEGIN":H.radioValue==="4"&&(e.unref(y).calcWays[0]="END"),q===0?e.unref(y).dateCalcTypes=["YEAR"]:q===1?e.unref(y).dateCalcTypes=["QUARTER"]:q===2?e.unref(y).dateCalcTypes=["MONTH"]:q===3?e.unref(y).dateCalcTypes=["WEEK"]:q===4&&(e.unref(y).dateCalcTypes=["DAY"]),T.value=!1},ct=()=>{e.unref(y).activeKey=5,e.unref(y).dateCalcTypes=[e.unref(g).unit],e.unref(y).calcWays[0]=`${e.unref(g).expression}-${e.unref(g).around}`,T.value=!1};function He(H,q){const{radioValue:X="",calcWays:te=[]}=q;H.radioValue=X,te!=null&&te.length&&(X==="1"?H.beforeNum=Math.abs(te[0]):X==="2"&&(H.afterNum=te[0]))}function pe(H,q,X,te,ae){if(H==="1")return ue().subtract(te,q).format(X);if(H==="2")return ue().add(ae,q).format(X);if(H==="3"){if(q==="years")return ue().startOf("year").format(X);if(q==="quarters")return ue().startOf("quarter").format(X);if(q==="months")return ue().startOf("month").format(X);if(q==="days")return ue().format(X)}else if(H==="4"){if(q==="years")return ue().endOf("year").format(X);if(q==="quarters")return ue().endOf("quarter").format(X);if(q==="months")return ue().endOf("month").format(X)}return""}const Te=(H,q)=>q.label.toLowerCase().indexOf(H.toLowerCase())>=0,nt=e.computed(()=>!["IN","NOT_IN"].includes(e.unref(y).rule));return{fieldOptions:N,ruleOptions:G,onFieldChange:F,condition:y,valueOptions:L,onRuleChange:D,onDataTypeChange:$,onFieldValueSelectChange:W,fieldValues:z,onDelete:B,isDateType:V,formatList:f,tabDateList:w,compareList:C,menuRule:x,dateBtnLabel:R,downIconStyle:S,popoverVisible:T,dateRadioStyle:h,showTime:b,controlList:s,keyNameOptions:p,dataTypeList:A,customTabData:g,isUseCurrentTime:d,currentTime:l,isShowCustomDataType:nt,handleMenuClick:Q,changeTabInitDate:Z,changeRadioValue:oe,getFieldValue:ie,blurCompare:se,okDatePickConfig:je,onChangeComponent:O,filterOption:Te,okCustomConfig:ct,clickConditionMenu:({key:H})=>{j(t.path,t.index,H==="2"?"||":"&&")},dataSetfieldOptions:E}}}),wm="",km="",Es={class:"condition"},Vs=["title"],Ls={class:"rule"},Bs={class:"data-type"},Os={key:0,class:"field-value",style:{display:"flex","align-items":"center"}},Ds={class:"popover-content-wrap"},Is={key:0,class:"use-current-time"},Fs={class:"tabFilterRadio"},$s={key:0},Ps={key:1},Ms={style:{"margin-left":"10px"}},js={style:{"margin-left":"10px"}},vs={style:{position:"absolute",bottom:"10px"}},Rs={style:{display:"flex"}},Us={style:{position:"absolute",bottom:"10px",left:"0","text-align":"center",width:"100%"}};function Gs(t,o,n,a,r,i){const c=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-menu-item"),s=e.resolveComponent("a-sub-menu"),p=e.resolveComponent("a-menu"),u=e.resolveComponent("DownOutlined"),m=e.resolveComponent("a-button"),b=e.resolveComponent("a-dropdown"),h=e.resolveComponent("a-date-picker"),f=e.resolveComponent("a-input"),g=e.resolveComponent("a-checkbox"),w=e.resolveComponent("a-input-number"),C=e.resolveComponent("a-radio"),x=e.resolveComponent("a-radio-group"),A=e.resolveComponent("a-tab-pane"),y=e.resolveComponent("a-tabs"),_=e.resolveComponent("appstore-add-outlined"),E=e.resolveComponent("a-popover"),T=e.resolveComponent("menu-outlined"),V=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",Es,[e.createVNode(d,{class:"field-name",value:t.condition.fieldName,onChange:t.onFieldChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.fieldOptions,(N,I)=>(e.openBlock(),e.createBlock(c,{key:I,value:N.value},{default:e.withCtx(()=>[e.createElementVNode("span",{title:N.label},e.toDisplayString(N.label),9,Vs)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"]),e.createElementVNode("div",Ls,[t.isDateType?(e.openBlock(),e.createBlock(b,{key:0,class:"dropdown",trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.handleMenuClick},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.ruleOptions,N=>(e.openBlock(),e.createBlock(s,{key:N.value},{title:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===N.value?"color: #1890FF;":"")},e.toDisplayString(N.label),5)]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.menuRule,I=>{var M;return e.openBlock(),e.createBlock(s,{key:I.value,disabled:I.value==="component"&&!((M=t.controlList)!=null&&M.length)},{title:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===N.value&&t.condition.dataType===I.value?"color: #1890FF;":"")},e.toDisplayString(I.label),5)]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formatList,j=>(e.openBlock(),e.createBlock(l,{key:j.value},{default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===N.value&&t.condition.dataType===I.value&&t.condition.dateFormat===j.value?"color: #1890FF;":"")},e.toDisplayString(j.label),5)]),_:2},1024))),128))]),_:2},1032,["disabled"])}),128))]),_:2},1024))),128))]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(m,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.dateBtnLabel)+" ",1),e.createVNode(u,{style:e.normalizeStyle(t.downIconStyle)},null,8,["style"])]),_:1})]),_:1})):(e.openBlock(),e.createBlock(d,{key:1,style:{width:"100%"},value:t.condition.rule,options:t.ruleOptions,onChange:t.onRuleChange},null,8,["value","options","onChange"]))]),e.withDirectives(e.createElementVNode("div",Bs,[e.createVNode(d,{style:{width:"100%"},value:t.condition.dataType,onChange:t.onDataTypeChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dataTypeList,(N,I)=>(e.openBlock(),e.createBlock(c,{key:I,value:N.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(N.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])],512),[[e.vShow,(!t.condition.fieldType||["TEXT","NUMBER"].includes(t.condition.fieldType))&&t.isShowCustomDataType]]),t.isDateType?(e.openBlock(),e.createElementBlock("div",Os,[t.condition.dataType==="time"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.isUseCurrentTime?(e.openBlock(),e.createBlock(h,{key:0,disabled:"",style:{width:"calc(100% - 35px)","margin-right":"10px"},value:t.currentTime,format:t.condition.dateFormat},null,8,["value","format"])):(e.openBlock(),e.createBlock(h,{key:1,style:{width:"calc(100% - 35px)","margin-right":"10px"},value:t.condition.fieldValue,"onUpdate:value":o[0]||(o[0]=N=>t.condition.fieldValue=N),format:t.condition.dateFormat},null,8,["value","format"]))],64)):typeof t.condition.fieldValue=="string"?(e.openBlock(),e.createBlock(d,{key:1,"show-search":"",style:e.normalizeStyle({width:t.condition.fieldValue==="PARENT"?"":"calc(100% - 35px)",marginRight:"10px"}),value:t.condition.fieldValue,"onUpdate:value":o[1]||(o[1]=N=>t.condition.fieldValue=N),"filter-option":t.filterOption,options:t.keyNameOptions,onChange:t.onChangeComponent},null,8,["style","value","filter-option","options","onChange"])):e.createCommentVNode("",!0),t.condition.fieldValue==="PARENT"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(f,{class:"field-value",value:t.condition.modelKey,"onUpdate:value":o[2]||(o[2]=N=>t.condition.modelKey=N),placeholder:"组件别名",style:{margin:"0"}},null,8,["value"]),e.createVNode(f,{class:"field-value",value:t.condition.prop,"onUpdate:value":o[3]||(o[3]=N=>t.condition.prop=N),placeholder:"属性名"},null,8,["value"])],64)):e.createCommentVNode("",!0),e.createVNode(E,{visible:t.popoverVisible,"onUpdate:visible":o[11]||(o[11]=N=>t.popoverVisible=N),trigger:"click",placement:"bottomRight"},{content:e.withCtx(()=>[e.createElementVNode("div",Ds,[t.condition.dataType!=="component"?(e.openBlock(),e.createElementBlock("div",Is,[e.createVNode(g,{checked:t.isUseCurrentTime,"onUpdate:checked":o[4]||(o[4]=N=>t.isUseCurrentTime=N)},{default:e.withCtx(()=>[e.createTextVNode("使用当前时间")]),_:1},8,["checked"])])):e.createCommentVNode("",!0),e.createVNode(y,{defaultActiveKey:t.condition.activeKey,onChange:t.changeTabInitDate},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tabDateList,(N,I)=>(e.openBlock(),e.createBlock(A,{key:I,tab:N.label},{default:e.withCtx(()=>[e.createElementVNode("div",Fs,[e.createVNode(x,{value:N.radioValue,"onUpdate:value":M=>N.radioValue=M,onChange:M=>t.changeRadioValue(M,N)},{default:e.withCtx(()=>[t.showTime?(e.openBlock(),e.createElementBlock("div",$s,"相对当前时间:"+e.toDisplayString(N.value),1)):(e.openBlock(),e.createElementBlock("div",Ps,"相对当前时间:"+e.toDisplayString(t.getFieldValue(I)),1)),e.createVNode(C,{style:e.normalizeStyle(t.dateRadioStyle),value:"1"},{default:e.withCtx(()=>[e.createVNode(w,{value:N.beforeNum,"onUpdate:value":M=>N.beforeNum=M,min:0,onBlur:M=>t.blurCompare(M,N,"-","1")},null,8,["value","onUpdate:value","onBlur"]),e.createElementVNode("span",Ms,e.toDisplayString(N.beforeLabel),1)]),_:2},1032,["style"]),e.createVNode(C,{style:e.normalizeStyle(t.dateRadioStyle),value:"2"},{default:e.withCtx(()=>[e.createVNode(w,{value:N.afterNum,"onUpdate:value":M=>N.afterNum=M,min:0,onBlur:M=>t.blurCompare(M,N,"+","2")},null,8,["value","onUpdate:value","onBlur"]),e.createElementVNode("span",js,e.toDisplayString(N.afterLabel),1)]),_:2},1032,["style"]),N.beforeText?(e.openBlock(),e.createBlock(C,{key:2,style:e.normalizeStyle(t.dateRadioStyle),value:"3"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(N.beforeText),1)]),_:2},1032,["style"])):e.createCommentVNode("",!0),N.afterText?(e.openBlock(),e.createBlock(C,{key:3,style:e.normalizeStyle(t.dateRadioStyle),value:"4"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(N.afterText),1)]),_:2},1032,["style"])):e.createCommentVNode("",!0)]),_:2},1032,["value","onUpdate:value","onChange"]),e.createElementVNode("div",vs,[e.createVNode(m,{style:{"margin-right":"12px"},onClick:o[5]||(o[5]=M=>t.popoverVisible=!1)},{default:e.withCtx(()=>[e.createTextVNode("取消")]),_:1}),e.createVNode(m,{onClick:M=>t.okDatePickConfig(N,I)},{default:e.withCtx(()=>[e.createTextVNode("确定")]),_:2},1032,["onClick"])])])]),_:2},1032,["tab"]))),128)),(e.openBlock(),e.createBlock(A,{tab:"自定义",key:5},{default:e.withCtx(()=>[e.createElementVNode("div",Rs,[e.createVNode(d,{value:t.customTabData.expression,"onUpdate:value":o[6]||(o[6]=N=>t.customTabData.expression=N),allowClear:"",style:{width:"120px","margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(c,{value:"rangeValue"},{default:e.withCtx(()=>[e.createTextVNode("范围差值")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.customTabData.unit,"onUpdate:value":o[7]||(o[7]=N=>t.customTabData.unit=N),style:{"margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(c,{value:"YEAR"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(c,{value:"QUARTER"},{default:e.withCtx(()=>[e.createTextVNode("季度")]),_:1}),e.createVNode(c,{value:"MONTH"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(c,{value:"WEEK"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(c,{value:"DAY"},{default:e.withCtx(()=>[e.createTextVNode("天")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.customTabData.around,"onUpdate:value":o[8]||(o[8]=N=>t.customTabData.around=N)},{default:e.withCtx(()=>[e.createVNode(c,{value:"before"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(c,{value:"after"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value"])]),e.createElementVNode("div",Us,[e.createVNode(m,{style:{"margin-right":"12px"},onClick:o[9]||(o[9]=N=>t.popoverVisible=!1)},{default:e.withCtx(()=>[e.createTextVNode("取消")]),_:1}),e.createVNode(m,{onClick:t.okCustomConfig},{default:e.withCtx(()=>[e.createTextVNode("确定")]),_:1},8,["onClick"])])]),_:1}))]),_:1},8,["defaultActiveKey","onChange"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:"calendar-wrap",onClick:o[10]||(o[10]=N=>{t.popoverVisible=!0})},[e.createVNode(_)])]),_:1},8,["visible"])])):["IN","NOT_IN"].includes(t.condition.rule||"")?(e.openBlock(),e.createBlock(d,{key:1,class:"field-value",value:t.fieldValues,mode:"multiple",options:t.valueOptions,onChange:t.onFieldValueSelectChange},null,8,["value","options","onChange"])):(!t.condition.fieldType||["TEXT","NUMBER"].includes(t.condition.fieldType))&&t.isShowCustomDataType&&t.condition.dataType==="component"?(e.openBlock(),e.createBlock(d,{key:2,class:"field-value","show-search":"",value:t.condition.fieldValue,"onUpdate:value":o[12]||(o[12]=N=>t.condition.fieldValue=N),"filter-option":t.filterOption,options:t.keyNameOptions,onChange:t.onChangeComponent},null,8,["value","filter-option","options","onChange"])):(e.openBlock(),e.createBlock(f,{key:3,class:"field-value",value:t.condition.fieldValue,"onUpdate:value":o[13]||(o[13]=N=>t.condition.fieldValue=N)},null,8,["value"])),!t.isDateType&&t.condition.fieldValue==="PARENT"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createVNode(f,{class:"field-value",value:t.condition.modelKey,"onUpdate:value":o[14]||(o[14]=N=>t.condition.modelKey=N),placeholder:"组件别名",style:{margin:"0"}},null,8,["value"]),e.createVNode(f,{class:"field-value",value:t.condition.prop,"onUpdate:value":o[15]||(o[15]=N=>t.condition.prop=N),placeholder:"属性名"},null,8,["value"])],64)):e.createCommentVNode("",!0),e.createVNode(b,{trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.clickConditionMenu},{default:e.withCtx(()=>[e.createVNode(l,{key:"1"},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(l,{key:"2"},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(T,{class:"more-icon"})]),_:1}),e.createVNode(V,{class:"delete-icon",onClick:t.onDelete},null,8,["onClick"])])}const zs=ne(Ts,[["render",Gs],["__scopeId","data-v-29a39def"]]),Hs=e.defineComponent({name:"ConditionList",props:{list:{type:Array,default:()=>[]},level:{type:Number,default:0},type:{type:String,default:""},path:{type:String,default:""}},components:{Condition:zs}}),_m="",Ys={key:0,class:"condition-list"},Ws={key:0,class:"condition-container"},qs={key:0,class:"condition-text"},Ks={key:1,class:"condition-text"},Qs={class:"conditions"};function Xs(t,o,n,a,r,i){const c=e.resolveComponent("condition-list",!0),d=e.resolveComponent("condition");return Array.isArray(t.list)?(e.openBlock(),e.createElementBlock("div",Ys,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.list,(l,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[l.join&&l.conditions&&Array.isArray(l.conditions)?(e.openBlock(),e.createElementBlock("div",Ws,[l.conditions.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.join==="||"?(e.openBlock(),e.createElementBlock("div",qs,"或")):e.createCommentVNode("",!0),l.join==="&&"?(e.openBlock(),e.createElementBlock("div",Ks,"且")):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createElementVNode("div",Qs,[l.conditions.length>0?(e.openBlock(),e.createBlock(c,{key:0,level:t.level+1,path:`${t.path?t.path+"-":""}${s}`,list:l.conditions,type:t.type},null,8,["level","path","list","type"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(d,{class:"condition",key:l.keyValue||`${t.level}-${s}`,data:l,level:t.level,index:s,path:t.path||"",type:t.type},null,8,["data","level","index","path","type"]))],64))),128))])):e.createCommentVNode("",!0)}const Js=ne(Hs,[["render",Xs],["__scopeId","data-v-553c1496"]]),Zs=e.defineComponent({name:"TruncationList",props:{list:{type:Array,default:()=>[]}},components:{ASelect:P.Select,AInput:P.Input,AInputNumber:P.InputNumber},setup(t,{emit:o}){const n=[{label:"前N个",value:"TOP"},{label:"后N个",value:"BOTTOM"}],a=e.ref([]);return e.watch(a,i=>{i!=null&&i.length&&o("update",i)},{deep:!0}),e.onMounted(()=>{var i;(i=t.list)!=null&&i.length?a.value=ee.cloneDeep(t.list):a.value=[{num:0,rule:"",name:"其他"}]}),{ruleOptions:n,truncationList:a,clearData:i=>{i.rule="",i.num=0,i.name=""}}}}),Sm="",wa=t=>(e.pushScopeId("data-v-f543c690"),t=t(),e.popScopeId(),t),ec={class:"truncations"},tc={class:"rule"},oc={class:"field-value"},nc={class:"field-value"},ac=wa(()=>e.createElementVNode("div",{class:"text"},"将其余项设为",-1)),rc=wa(()=>e.createElementVNode("div",{class:"text"},"分组",-1)),lc=["onClick"];function ic(t,o,n,a,r,i){const c=e.resolveComponent("a-select"),d=e.resolveComponent("a-input-number"),l=e.resolveComponent("a-input");return e.openBlock(),e.createElementBlock("div",ec,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.truncationList,(s,p)=>(e.openBlock(),e.createElementBlock("div",{class:"item",key:p},[e.createElementVNode("div",tc,[e.createVNode(c,{style:{width:"100%"},value:s.rule,"onUpdate:value":u=>s.rule=u,options:t.ruleOptions},null,8,["value","onUpdate:value","options"])]),e.createElementVNode("div",oc,[e.createTextVNode(" N= "),e.createVNode(d,{value:s.num,"onUpdate:value":u=>s.num=u,min:0},null,8,["value","onUpdate:value"])]),e.createElementVNode("div",nc,[ac,e.createVNode(l,{value:s.name,"onUpdate:value":u=>s.name=u,style:{width:"100px",margin:"0 10px"}},null,8,["value","onUpdate:value"]),rc]),e.createElementVNode("div",{class:"clear-truncation",onClick:u=>t.clearData(s)},"清空",8,lc)]))),128))])}const sc=ne(Zs,[["render",ic],["__scopeId","data-v-f543c690"]]),cc=e.defineComponent({name:"FilterModal",props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""}},components:{ConditionList:Js,TruncationList:sc,AModal:P.Modal,AButton:P.Button,ATabs:P.Tabs,ATabPane:P.TabPane},setup(t,{expose:o}){var B;const n=e.ref("1"),a=()=>{var F;return`添加过滤条件-${((F=t.item)==null?void 0:F.label)||""}`},r=e.inject(Ce),i=e.inject(xe),c=e.inject(ve),d=e.computed(()=>{var F;return(F=e.unref(r))==null?void 0:F.dataSourceId}),l=e.inject(Ye),s=e.inject(Wt),p=e.ref([]),u=e.ref([]),m=e.ref(!1),b=e.inject(At),h=F=>{var O;for(const G of F)(O=G.conditions)!=null&&O.length?h(G.conditions):G.keyValue=Se()};e.watch(m,F=>{var O,G,R,S;if(F){if(Array.isArray((O=t.item)==null?void 0:O.conditions)){const L=ee.cloneDeep(((G=t.item)==null?void 0:G.conditions)||[]);h(L),p.value=L}Array.isArray((R=t.item)==null?void 0:R.truncations)?u.value=ee.cloneDeep((S=t.item)==null?void 0:S.truncations)||[]:u.value=[{rule:"",num:0,name:"其他"}]}window.changeShowTable&&window.changeShowTable(!F)},{flush:"post"});let f=!1;const g=F=>{var O;f=!0,e.unref(p)==null||((O=e.unref(p))==null?void 0:O.length)===0?p.value=[{}]:e.unref(p)[0]!=null&&(e.unref(p)[0].conditions==null||e.unref(p)[0].join!==F?p.value=[{join:F,conditions:[e.unref(p)[0],{keyValue:Se()}]}]:e.unref(p)[0].conditions.length>1&&e.unref(p)[0].join===F&&p.value[0].conditions.push({keyValue:Se()}))};e.provide(Cn,{updateCondition(F,O,G){var L;f=!0;let R=e.unref(p);const S=G.split("-");if(S!=null&&S.length)for(const k of S)if(R[k])R=(L=R[k])==null?void 0:L.conditions;else break;Array.isArray(R)&&R[O]&&(R[O]=F)},deleteCondition(F,O){var S,L,k;f=!0;let G=e.unref(p);const R=O.split("-");if(R!=null&&R.length){for(const D of R)if(G[D])G=(S=G[D])==null?void 0:S.conditions;else break;if(Array.isArray(G)&&G[F])if(G.splice(F,1),G.length===1){if(R.length>0){const D=R.length-1,$=R[D],z=R.slice(0,D);let W=e.unref(p),Q="";for(const Z of z)if(W[Z])Q=(L=W[Z])==null?void 0:L.join,W=(k=W[Z])==null?void 0:k.conditions;else break;if(Q===G[0].join){if(Array.isArray(G[0].conditions)){const Z=ee.cloneDeep(G[0].conditions);W.splice(+$,1),W.splice(+$,0,...Z)}}else W[$]=G[0]}}else G.length===0&&(p.value=[])}},addCondition(F,O,G){var k,D;f=!0;let R=e.unref(p),S="";const L=F.split("-");if(L!=null&&L.length){for(const $ of L)if(R[$])S=(k=R[$])==null?void 0:k.join,R=(D=R[$])==null?void 0:D.conditions;else break;if(S===G)R.splice(O+1,0,{keyValue:Se()});else{const $=ee.cloneDeep(R[O]);R[O]={join:G,conditions:[$,{keyValue:Se()}]}}}}});const w=F=>{f=!0,u.value=F},C=e.computed(()=>{var O;const F=[];return(O=e.unref(c))==null||O.forEach(G=>{const{keyName:R="",id:S="",type:L}=G;L==="ecanRangePicker"?F.push({value:`${S}-startTime`,label:`${R||S}-开始时间值`,keyName:`${R||S}-startTime`},{value:`${S}-endTime`,label:`${R||S}-结束时间值`,keyName:`${R||S}-endTime`}):F.push({value:S,label:`${R||S}`,keyName:`${R||S}`})}),F}),x=()=>{var k,D,$;const F=tt(((k=e.unref(r))==null?void 0:k.controlList)||[]),O=((D=e.unref(r)[t.type])==null?void 0:D.slice())||[],G=tt(ee.cloneDeep(O[t.index].conditions));O[t.index].conditions=e.unref(p),["classificationList","rowHeaderList","dimensionList"].includes(t.type)&&(($=e.unref(u))!=null&&$.length)&&(O[t.index].truncations=e.unref(u));const R=tt(e.unref(p));for(const z of R)if(z.dataType==="component"&&z.fieldValue){const W=e.unref(C).find(Q=>Q.value===z.fieldValue);W&&(z.fieldValue=W.keyName)}const S=G.filter(z=>!R.find(W=>W.componentId===z.componentId)).filter(z=>!F.find(W=>W.id===z.componentId)),L=R.filter(z=>!G.find(W=>W.componentId===z.componentId));A(S,L),i({[t.type]:O,sqlConditions:da({...e.unref(r),[t.type]:O},e.unref(c))})};function A(F,O){var R;const G=F.map(S=>({...S,delete:!0})).concat(O.map(S=>({...S,add:!0})));for(const S of G){const L=e.unref(c).find(k=>k.id===S.componentId);if(L){const{type:k,id:D,events:$=[]}=L,z=Zt(k);if(S.add)$.find(W=>{var Q;return W.on===z&&W.target===((Q=e.unref(l))==null?void 0:Q.id)&&W.emit==="refreshData"})||s({id:D,events:[...$,{on:z,target:(R=e.unref(l))==null?void 0:R.id,emit:"refreshData"}].reverse()});else if(S.delete){const W=$.findIndex(Q=>{var Z;return Q.on===z&&Q.target===((Z=e.unref(l))==null?void 0:Z.id)&&Q.emit==="refreshData"});W!==-1&&($.splice(W,1),s({id:D,events:$}))}}}}const y=()=>{m.value=!0},_=()=>{p.value=[],m.value=!1},E=()=>{f&&x(),f=!1,_()},T=()=>{_()},V=e.inject(Oe),N=e.unref(e.inject(De)),I=(B=window==null?void 0:window.config)==null?void 0:B.pageId,M=e.ref([]);e.provide(wn,M);const j=async F=>{var O;if(["leftAxisList","rightAxisList","indicators","queryColumnList"].includes(t.type))try{const{id:G,indexCode:R}=F,S=await V.post(`${_e}/diagram/hrpIndexWithComplex`,{pageId:I,dataSourceId:e.unref(d),indexGuid:G,indexCode:R},{headers:{Authentication:N,operateContext:"ygt"}}),{success:L,data:k=[]}=S.data;L&&((O=k==null?void 0:k.dataViewColumns)!=null&&O.length)&&(M.value=k.dataViewColumns.map(D=>({...D,label:D.title||D.label})))}catch(G){console.error(G)}};return e.watch(()=>t.item,F=>{F&&m.value&&e.unref(b)!=="EDV_DATA_SET"&&j(F)}),o({showModal:y}),{visible:m,onOk:E,onCancel:T,handleTitle:a,conditionList:p,truncationList:u,addCondition:g,onUpdatetruncation:w,activeKey:n,source:b}}}),xm="",dc={class:"header"},pc={class:"header"};function uc(t,o,n,a,r,i){const c=e.resolveComponent("a-button"),d=e.resolveComponent("condition-list"),l=e.resolveComponent("a-tab-pane"),s=e.resolveComponent("truncation-list"),p=e.resolveComponent("a-tabs"),u=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(u,{title:t.handleTitle(),visible:t.visible,"destroy-on-close":"",width:"55%",bodyStyle:{height:"70vh",overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[["classificationList","rowHeaderList","dimensionList"].includes(t.type)?(e.openBlock(),e.createBlock(p,{key:0,activeKey:t.activeKey,"onUpdate:activeKey":o[3]||(o[3]=m=>t.activeKey=m)},{default:e.withCtx(()=>[e.createVNode(l,{key:"1",tab:"过滤条件",style:{overflow:"auto"}},{default:e.withCtx(()=>[e.createElementVNode("div",dc,[Array.isArray(t.conditionList)&&t.conditionList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(c,{class:"add-and-condition",onClick:o[0]||(o[0]=m=>t.addCondition("&&"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加且条件 ")]),_:1}),e.createVNode(c,{class:"add-or-condition",onClick:o[1]||(o[1]=m=>t.addCondition("||"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加或条件 ")]),_:1})],64)):(e.openBlock(),e.createBlock(c,{key:1,onClick:o[2]||(o[2]=m=>t.addCondition())},{default:e.withCtx(()=>[e.createTextVNode(" 添加条件 ")]),_:1}))]),e.createVNode(d,{class:"condition-list",list:t.conditionList,level:0,type:t.type},null,8,["list","type"])]),_:1}),e.createVNode(l,{key:"2",tab:"截断配置"},{default:e.withCtx(()=>[e.createVNode(s,{list:t.truncationList,onUpdate:t.onUpdatetruncation},null,8,["list","onUpdate"])]),_:1})]),_:1},8,["activeKey"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",pc,[Array.isArray(t.conditionList)&&t.conditionList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(c,{class:"add-and-condition",onClick:o[4]||(o[4]=m=>t.addCondition("&&"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加且条件 ")]),_:1}),e.createVNode(c,{class:"add-or-condition",onClick:o[5]||(o[5]=m=>t.addCondition("||"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加或条件 ")]),_:1})],64)):(e.openBlock(),e.createBlock(c,{key:1,onClick:o[6]||(o[6]=m=>t.addCondition())},{default:e.withCtx(()=>[e.createTextVNode(" 添加条件 ")]),_:1}))]),e.createVNode(d,{class:"condition-list",list:t.conditionList,level:0,type:t.type},null,8,["list","type"])],64))]),_:1},8,["title","visible","onOk","onCancel"])}const fc=ne(cc,[["render",uc],["__scopeId","data-v-38f115c6"]]),mc=e.defineComponent({name:"ConfigName",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{AInput:P.Input,AModal:P.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),r=e.inject(xe),i=e.ref(),c=p=>{const{showLabel:u="",label:m=""}=p;i.value=u||m||"",n.value=!0},d=()=>{n.value=!1},l=()=>{var u;const p=((u=e.unref(a)[t.type])==null?void 0:u.slice())||[];p[t.index].showLabel=i.value,r({[t.type]:p}),d()},s=()=>{d()};return o({showModal:c}),{visible:n,onOk:l,onCancel:s,fieldName:i}}}),Nm="",hc=t=>(e.pushScopeId("data-v-de6a1755"),t=t(),e.popScopeId(),t),yc={class:"config-name"},gc=hc(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"名称:",-1));function bc(t,o,n,a,r,i){const c=e.resolveComponent("a-input"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置展示名称",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",yc,[gc,e.createVNode(c,{value:t.fieldName,"onUpdate:value":o[0]||(o[0]=l=>t.fieldName=l)},null,8,["value"])])]),_:1},8,["visible","onOk","onCancel"])}const Cc=ne(mc,[["render",bc],["__scopeId","data-v-de6a1755"]]),wc=e.defineComponent({name:"SortByCpnt",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{ASelect:P.Select,AModal:P.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),r=e.inject(xe),i=e.inject(ve),c=e.inject(Ye),d=e.inject(Wt),l=e.ref(),s=e.computed(()=>{var w;return(w=e.unref(i))==null?void 0:w.filter(C=>C.keyName!=="")});let p=[];const u=w=>{const{sortCpnts:C=[]}=w;p=ee.cloneDeep(C),l.value=ee.cloneDeep(C),n.value=!0},m=()=>{n.value=!1},b=()=>{var y,_;const w=tt(((y=e.unref(a))==null?void 0:y.controlList)||[]),C=p.filter(E=>!e.unref(l).includes(E)).filter(E=>!w.find(T=>T.id===E)),x=e.unref(l).filter(E=>!p.includes(E)).filter(E=>!w.find(T=>T.id===E)),A=C.map(E=>({componentId:E,delete:!0})).concat(x.map(E=>({componentId:E,add:!0})));for(const E of A){const T=e.unref(i).find(V=>V.id===E.componentId);if(T){const{type:V,id:N,events:I=[]}=T,M=Zt(V);if(E.add)I.find(j=>{var B;return j.on===M&&j.target===((B=e.unref(c))==null?void 0:B.id)&&j.emit==="refreshData"})||d({id:N,events:[...I,{on:M,target:(_=e.unref(c))==null?void 0:_.id,emit:"refreshData"}].reverse()});else if(E.delete){const j=I.findIndex(B=>{var F;return B.on===M&&B.target===((F=e.unref(c))==null?void 0:F.id)&&B.emit==="refreshData"});j!==-1&&(I.splice(j,1),d({id:N,events:I}))}}}},h=()=>{var C;b();const w=((C=e.unref(a)[t.type])==null?void 0:C.slice())||[];w[t.index].sortCpnts=l.value,r({[t.type]:w}),m()},f=()=>{m()},g=(w,C)=>{var x;return(x=C==null?void 0:C.keyName)==null?void 0:x.toLowerCase().includes(w==null?void 0:w.toLowerCase())};return o({showModal:u}),{visible:n,onOk:h,onCancel:f,idFilterOption:g,fieldName:l,usedComponentList:s}}}),Am="",kc=t=>(e.pushScopeId("data-v-08af1ef8"),t=t(),e.popScopeId(),t),_c={class:"sort-by-cpnt"},Sc=kc(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"控件:",-1));function xc(t,o,n,a,r,i){const c=e.resolveComponent("a-select"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置关联组件排序",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",_c,[Sc,e.createVNode(c,{class:"field-name",value:t.fieldName,"onUpdate:value":o[0]||(o[0]=l=>t.fieldName=l),mode:"multiple",style:{width:"100%"},options:t.usedComponentList,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption},null,8,["value","options","filter-option"])])]),_:1},8,["visible","onOk","onCancel"])}const Nc=ne(wc,[["render",xc],["__scopeId","data-v-08af1ef8"]]),Ac=e.defineComponent({name:"DimByCount",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{ASelect:P.Select,AModal:P.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),r=e.inject(xe),i=e.ref(),c=e.ref([]),d=(m,b)=>{const{dimByCount:h=""}=m;i.value=h,c.value=b.filter(f=>["DIM","BUILT_IN_DIM","FIELD"].includes(f.scope)).map(f=>({label:f.title||f.name,value:f.typeGuid})),n.value=!0},l=()=>{n.value=!1},s=()=>{var b;const m=((b=e.unref(a)[t.type])==null?void 0:b.slice())||[];m[t.index].dimByCount=i.value,r({[t.type]:m}),l()},p=()=>{l()},u=(m,b)=>{var h;return(h=b==null?void 0:b.label)==null?void 0:h.toLowerCase().includes(m==null?void 0:m.toLowerCase())};return o({showModal:d}),{visible:n,onOk:s,onCancel:p,idFilterOption:u,fieldName:i,dimensionList:c}}}),Tm="",Tc=t=>(e.pushScopeId("data-v-aa1c298e"),t=t(),e.popScopeId(),t),Ec={class:"dim-by-count"},Vc=Tc(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"维度:",-1));function Lc(t,o,n,a,r,i){const c=e.resolveComponent("a-select"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置关联维度",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",Ec,[Vc,e.createVNode(c,{class:"field-name",value:t.fieldName,"onUpdate:value":o[0]||(o[0]=l=>t.fieldName=l),style:{width:"100%"},options:t.dimensionList,"show-search":"","filter-option":t.idFilterOption},null,8,["value","options","filter-option"])])]),_:1},8,["visible","onOk","onCancel"])}const Bc=ne(Ac,[["render",Lc],["__scopeId","data-v-aa1c298e"]]),Xo=(t,o)=>{let n;for(let a=0;a<o.length;a++){const r=o[a];r.children&&(r.children.some(i=>i.key===t)?n=r.key:Xo(t,r.children)&&(n=Xo(t,r.children)))}return n},Oc=e.defineComponent({name:"FormulaCalculation",props:{value:{type:String,default:""},item:{type:Object,default:()=>({})},mode:{type:String,default:"add"}},components:{ARow:P.Row,ACol:P.Col,ATextarea:P.Textarea,APopover:P.Popover,AInputSearch:P.InputSearch,ATree:P.Tree,ARadioGroup:P.RadioGroup,ARadioButton:P.RadioButton,DoubleRightOutlined:Ml},emits:["update:value","change"],setup(t,{emit:o}){const n=e.inject(Oe),a=e.unref(e.inject(De)),r=e.inject(Ce),i=e.computed(()=>e.unref(r).leftAxisList||[]),c=e.computed(()=>e.unref(r).variableList||[]),d=e.computed(()=>e.unref(r).rightAxisList||[]),l=e.computed(()=>e.unref(r).indicators||[]),s=e.computed(()=>e.unref(r).queryColumnList||[]),p=e.computed(()=>{const V=e.unref(i).concat(e.unref(d)).concat(e.unref(l)).concat(e.unref(s));return t.mode==="edit"?(V==null?void 0:V.filter(N=>{var I;return N.id!==((I=t.item)==null?void 0:I.id)}))||[]:V||[]}),u=e.computed(()=>c.value.filter(V=>!V.randomKey)),m=e.computed({get:()=>t.value||"",set:V=>{o("update:value",V),o("change",V)}}),b=e.ref("1"),h=e.ref(""),f=V=>{const N=document.getElementById("calTextArea");let I=m.value;if(document.selection){const M=document.selection.createRange();M.text=V}else if(typeof N.selectionStart=="number"&&typeof N.selectionEnd=="number"){const M=N.selectionStart,j=N.selectionEnd;let B=M;I=I.substring(0,M)+V+I.substring(j,I.length),B+=V.length,N.selectionStart=N.selectionEnd=B}else I+=V;m.value=I},g=["+","-","*","/","(",")"],w=(V,N)=>{let I="";switch(N){case"name":{I="${"+V+"}";break}case"function":{I=V+"()";break}default:I=V}f(I)},C=[],x=e.ref([]),A=e.ref(!0),y=e.ref([]),_=V=>{var N;for(const I of V)(N=I==null?void 0:I.children)!=null&&N.length?_(I.children):C.push({key:I.key,title:I.title})},E=async()=>{try{const V=await n.get(`${_e}/diagram/funcdescs`,{},{headers:{Authentication:a,operateContext:"ygt"}}),{success:N,data:I=[]}=V.data;N&&(I!=null&&I.length)&&(_(I),y.value=I)}catch(V){console.error(V)}},T=V=>{x.value=V,A.value=!1};return e.watch(h,V=>{const N=C.map(I=>I.title.indexOf(V)>-1?Xo(I.key,y.value):null).filter((I,M,j)=>I&&j.indexOf(I)===M);x.value=N,h.value=V,A.value=!0}),e.onMounted(()=>{E()}),{fieldList:p,varList:u,myValue:m,calculMethods:g,funcDescsData:y,searchFuncValue:h,expandedKeys:x,autoExpandParent:A,activeKey:b,selectedElem:w,onExpand:T}}}),Em="",Vm="",ka=t=>(e.pushScopeId("data-v-69040cfb"),t=t(),e.popScopeId(),t),Dc={class:"formula-calculation"},Ic={class:"field-area"},Fc={style:{"text-align":"center",padding:"10px 0"}},$c=["onClick"],Pc=["onClick"],Mc={class:"cal_right_bottom"},jc={class:"cal_fu"},vc=["onClick"],Rc={class:"function-wrap"},Uc={class:"wrap-search"},Gc={class:"tree-box"},zc=ka(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"描述:",-1)),Hc=ka(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"示例:",-1)),Yc={key:0},Wc={style:{color:"#f50"}},qc={key:1},Kc=["onClick"],Qc={class:"cal_a"};function Xc(t,o,n,a,r,i){const c=e.resolveComponent("a-radio-button"),d=e.resolveComponent("a-radio-group"),l=e.resolveComponent("a-col"),s=e.resolveComponent("a-textarea"),p=e.resolveComponent("a-input-search"),u=e.resolveComponent("a-tooltip"),m=e.resolveComponent("a-tree"),b=e.resolveComponent("double-right-outlined"),h=e.resolveComponent("a-popover"),f=e.resolveComponent("a-row");return e.openBlock(),e.createElementBlock("div",Dc,[e.createVNode(f,{style:{height:"100%"}},{default:e.withCtx(()=>[e.createVNode(l,{span:6},{default:e.withCtx(()=>[e.createElementVNode("div",Ic,[e.createElementVNode("div",Fc,[e.createVNode(d,{value:t.activeKey,"onUpdate:value":o[0]||(o[0]=g=>t.activeKey=g),size:"small"},{default:e.withCtx(()=>[e.createVNode(c,{value:"1"},{default:e.withCtx(()=>[e.createTextVNode("数值字段("+e.toDisplayString(t.fieldList.length)+")",1)]),_:1}),e.createVNode(c,{value:"2"},{default:e.withCtx(()=>[e.createTextVNode("全局变量("+e.toDisplayString(t.varList.length)+")",1)]),_:1})]),_:1},8,["value"])]),t.activeKey==="1"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.fieldList,(g,w)=>(e.openBlock(),e.createElementBlock("div",{class:"field",key:w,onClick:C=>t.selectedElem(g.label,"name")},e.toDisplayString(g.label),9,$c))),128)):e.createCommentVNode("",!0),t.activeKey==="2"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.varList,(g,w)=>(e.openBlock(),e.createElementBlock("div",{class:"field",key:w,onClick:C=>t.selectedElem(g.variableName,"name")},e.toDisplayString(g.variableName),9,Pc))),128)):e.createCommentVNode("",!0)])]),_:1}),e.createVNode(l,{span:18},{default:e.withCtx(()=>[e.createVNode(s,{class:"textarea",id:"calTextArea",value:t.myValue,"onUpdate:value":o[1]||(o[1]=g=>t.myValue=g),autoSize:{minRows:13,maxRows:13},placeholder:"示例: ${指标} * 3"},null,8,["value"]),e.createElementVNode("div",Mc,[e.createElementVNode("ul",jc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.calculMethods,(g,w)=>(e.openBlock(),e.createElementBlock("li",{onClick:C=>t.selectedElem(g,"symbol"),key:w},e.toDisplayString(g),9,vc))),128))]),e.createVNode(h,{placement:"topRight",trigger:"click",overlayClassName:"func-popover"},{content:e.withCtx(()=>[e.createElementVNode("div",Rc,[e.createElementVNode("div",Uc,[e.createVNode(p,{value:t.searchFuncValue,"onUpdate:value":o[2]||(o[2]=g=>t.searchFuncValue=g),style:{"margin-bottom":"8px"},placeholder:"请输入关键字搜索"},null,8,["value"])]),e.createElementVNode("div",Gc,[e.createVNode(m,{"expanded-keys":t.expandedKeys,"auto-expand-parent":t.autoExpandParent,"tree-data":t.funcDescsData,onExpand:t.onExpand},{title:e.withCtx(({title:g,leaf:w,describe:C,exp:x})=>[e.createVNode(u,{placement:"top"},e.createSlots({default:e.withCtx(()=>[g.indexOf(t.searchFuncValue)>-1?(e.openBlock(),e.createElementBlock("span",Yc,[e.createTextVNode(e.toDisplayString(g.substr(0,g.indexOf(t.searchFuncValue)))+" ",1),e.createElementVNode("span",Wc,e.toDisplayString(t.searchFuncValue),1),e.createTextVNode(" "+e.toDisplayString(g.substr(g.indexOf(t.searchFuncValue)+t.searchFuncValue.length)),1)])):(e.openBlock(),e.createElementBlock("span",qc,e.toDisplayString(g),1)),w?(e.openBlock(),e.createElementBlock("span",{key:2,class:"insertsty",onClick:A=>t.selectedElem(g,"function")},"插入",8,Kc)):e.createCommentVNode("",!0)]),_:2},[w?{name:"title",fn:e.withCtx(()=>[e.createElementVNode("div",null,[zc,e.createElementVNode("span",null,e.toDisplayString(C),1)]),e.createElementVNode("div",null,[Hc,e.createElementVNode("span",null,e.toDisplayString(x),1)])]),key:"0"}:void 0]),1024)]),_:1},8,["expanded-keys","auto-expand-parent","tree-data","onExpand"])])])]),default:e.withCtx(()=>[e.createElementVNode("span",Qc,[e.createTextVNode(" 更多函数 "),e.createVNode(b,{style:{"font-size":"12px",margin:"2px 0 0 2px",color:"#1890ff"}})])]),_:1})])]),_:1})]),_:1})])}const Jc=ne(Oc,[["render",Xc],["__scopeId","data-v-69040cfb"]]),Zc=e.defineComponent({name:"CalculationModal",components:{FormulaCalculation:Jc,AForm:P.Form,AModal:P.Modal,AFormItem:P.FormItem,AInput:P.Input,ASelect:P.Select,ASelectOption:P.SelectOption,ATextarea:P.Textarea,AInputNumber:P.InputNumber,ATooltip:P.Tooltip,QuestionCircleOutlined:hi},props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""},mode:{type:String,default:"add"}},setup(t,{expose:o}){const n=e.inject(ve),a=e.inject(Ce),r=e.inject(xe),i=e.computed(()=>e.unref(n)),c=e.computed(()=>e.unref(a)[t.type]||[]),d=e.computed(()=>{const j=["leftAxisList","rightAxisList","queryColumnList","indicators"];let B=[];for(const F of j)Object.prototype.hasOwnProperty.call(e.unref(a),F)&&(B=B.concat(e.unref(a)[F]));return B}),l={span:4},s={span:18},p={label:"",calcType:"FORMULA",formula:void 0,builtInValueSource:void 0,builtInFormula:void 0,builtInCalcWay:void 0},u={value:0,unit:"YEAR",around:"before"},m=e.ref({}),b=e.ref(),h=e.ref(!1),f=e.ref();e.watch(h,j=>{if(j)if(t.mode==="edit"){const{label:B,calcType:F,formula:O,builtInValueSource:G,builtInFormula:R,builtInCalcWay:S}=t.item;if(f.value={label:B,calcType:F,formula:O,builtInValueSource:G,builtInFormula:R,builtInCalcWay:S},R==="DATE_OFFSET"){const L=S.split("-");(L==null?void 0:L.length)===3&&(m.value={value:L[0],unit:L[1],around:L[2]})}}else t.mode==="add"&&(f.value=ee.cloneDeep(p),m.value=ee.cloneDeep(u));else f.value=ee.cloneDeep(p),m.value=ee.cloneDeep(u);window.changeShowTable&&window.changeShowTable(!j)},{immediate:!0,deep:!0});let g=!1;const w=()=>{g=!0},C=j=>{const B=e.unref(i).find(F=>F.id===j);B&&(f.value.builtInCalcWay=B.keyName),g=!0},x=()=>{var G;const j=((G=e.unref(a)[t.type])==null?void 0:G.slice())||[],{label:B,builtInFormula:F}=e.unref(f)||{},O={};if(F==="DATE_OFFSET"&&(O.builtInCalcWay=`${e.unref(m).value}-${e.unref(m).unit}-${e.unref(m).around}`),t.mode==="add"){const R=Se();j.push({...e.unref(f),...O,id:R,show:!0,name:B})}else t.mode==="edit"&&(j[t.index]={...j[t.index],...e.unref(f),...O,name:B});r({[t.type]:j})},A=()=>{h.value=!0},y=()=>{h.value=!1},_=async(j,B)=>{if(B==="")return Promise.reject(new Error("请输入指标名"));{const F=e.unref(d).find(O=>O.label===B);return F?F.id===t.item.id?Promise.resolve():Promise.reject(new Error("指标名不能重复")):Promise.resolve()}},E=e.computed(()=>{let j={label:[{required:!0,validator:_,trigger:"change"}]};return f.value.calcType==="BUILT_IN"&&(j={...j,builtInFormula:[{required:!0,message:"请选择内置公式"}],builtInValueSource:[{required:!0,message:"请选择数值来自"}],builtInCalcWay:[{required:!0,message:"请选择取数原则"}]}),j}),T=()=>{b.value.validate().then(()=>{g&&x(),g=!1,y()})},V=()=>{b.value.clearValidate(),y()},N=()=>{g=!0,e.unref(f).builtInCalcWay=""},I=e.computed(()=>{let j="";const B=e.unref(f).builtInCalcWay,F=e.unref(f).builtInValueSource;if(!F||!B)return j;switch(e.unref(f).builtInFormula){case"BUILT_IN_RANK":{B==="ASC"?j="【"+F+"】由小到大在所有值中的排名":j="【"+F+"】由大到小在所有值中的排名";break}case"BUILT_IN_RANK_IN_GROUPO":{j=`所有【】的
60
- `,B==="ASC"?j=j+"【"+F+"】由小到大的组内的排名":j=j+"【"+F+"】由大到小的组内的排名";break}case"BUILT_IN_ALL_VALUE":{let O="";switch(B){case"SUM":{O="求和";break}case"AVG":{O="求平均值";break}case"MIN":{O="求最小值";break}case"MAX":{O="求最大值";break}}j="将所有【"+F+"】"+O;break}case"BUILT_IN_ALL_VALUE_IN_GROUPO":{let O="";switch(j=`所有【】的
61
- `,B){case"SUM":{O="求和";break}case"AVG":{O="求平均值";break}case"MIN":{O="求最小值";break}case"MAX":{O="求最大值";break}}j=j+"将所有【"+F+"】"+O;break}}return j}),M=(j,B)=>B.keyName.toLowerCase().indexOf(j.toLowerCase())>=0;return o({showModal:A}),{visible:h,onCancel:V,labelCol:l,wrapperCol:s,formState:f,builtInValueSourceList:c,onOK:T,onChange:w,formRules:E,accessLogic:I,formRef:b,onChangeBuiltInFormula:N,componentList:i,onChangeComponent:C,filterOption:M,offsetConfig:m}}}),Lm="",Bm="",ed={key:0,class:"accesstip"},td={style:{display:"flex","align-items":"center"}};function od(t,o,n,a,r,i){const c=e.resolveComponent("a-input"),d=e.resolveComponent("a-form-item"),l=e.resolveComponent("a-select-option"),s=e.resolveComponent("a-select"),p=e.resolveComponent("formula-calculation"),u=e.resolveComponent("a-textarea"),m=e.resolveComponent("a-input-number"),b=e.resolveComponent("question-circle-outlined"),h=e.resolveComponent("a-tooltip"),f=e.resolveComponent("a-form"),g=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(g,{title:`${t.mode==="add"?"新增":"编辑"}计算指标`,visible:t.visible,width:"50%",bodyStyle:{height:"55vh",overflow:"auto",display:"flex",flexDirection:"column"},closable:!1,onOk:t.onOK,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createVNode(f,{model:t.formState,rules:t.formRules,ref:"formRef"},{default:e.withCtx(()=>[e.createVNode(d,{label:"指标名","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"label"},{default:e.withCtx(()=>[e.createVNode(c,{value:t.formState.label,"onUpdate:value":o[0]||(o[0]=w=>t.formState.label=w),onChange:t.onChange},null,8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),e.createVNode(d,{label:"计算方式","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[e.createVNode(s,{value:t.formState.calcType,"onUpdate:value":o[1]||(o[1]=w=>t.formState.calcType=w),onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(l,{value:"FORMULA"},{default:e.withCtx(()=>[e.createTextVNode("公式")]),_:1}),e.createVNode(l,{value:"BUILT_IN"},{default:e.withCtx(()=>[e.createTextVNode("内置公式")]),_:1}),e.createVNode(l,{value:"COMPONENT"},{default:e.withCtx(()=>[e.createTextVNode("固定值")]),_:1})]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),t.formState.calcType==="FORMULA"?(e.openBlock(),e.createBlock(p,{key:0,value:t.formState.formula,"onUpdate:value":o[2]||(o[2]=w=>t.formState.formula=w),item:t.item,mode:t.mode,onChange:t.onChange},null,8,["value","item","mode","onChange"])):e.createCommentVNode("",!0),t.formState.calcType==="BUILT_IN"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(d,{label:"内置公式","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInFormula"},{default:e.withCtx(()=>[e.createVNode(s,{value:t.formState.builtInFormula,"onUpdate:value":o[3]||(o[3]=w=>t.formState.builtInFormula=w),onChange:t.onChangeBuiltInFormula},{default:e.withCtx(()=>[e.createVNode(l,{value:"BUILT_IN_ALL_VALUE"},{default:e.withCtx(()=>[e.createTextVNode("所有值")]),_:1}),e.createVNode(l,{value:"BUILT_IN_ALL_VALUE_IN_GROUPO"},{default:e.withCtx(()=>[e.createTextVNode("组内所有值")]),_:1}),e.createVNode(l,{value:"BUILT_IN_RANK"},{default:e.withCtx(()=>[e.createTextVNode("排名")]),_:1}),e.createVNode(l,{value:"BUILT_IN_RANK_IN_GROUPO"},{default:e.withCtx(()=>[e.createTextVNode("组内排名")]),_:1}),e.createVNode(l,{value:"FIRST_ROW_RATE"},{default:e.withCtx(()=>[e.createTextVNode("首行占比")]),_:1}),e.createVNode(l,{value:"DATE_OFFSET"},{default:e.withCtx(()=>[e.createTextVNode("日期偏移")]),_:1})]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),e.createVNode(d,{label:"数值来自","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(s,{value:t.formState.builtInValueSource,"onUpdate:value":o[4]||(o[4]=w=>t.formState.builtInValueSource=w),onChange:t.onChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.builtInValueSourceList,(w,C)=>(e.openBlock(),e.createBlock(l,{key:C,value:w.label,disabled:t.mode==="edit"&&t.item.label===w.name},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(w.label),1)]),_:2},1032,["value","disabled"]))),128))]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),["FIRST_ROW_RATE","DATE_OFFSET"].includes(t.formState.builtInFormula)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:0,label:"取数原则","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(s,{value:t.formState.builtInCalcWay,"onUpdate:value":o[5]||(o[5]=w=>t.formState.builtInCalcWay=w),onChange:t.onChange},{default:e.withCtx(()=>[["BUILT_IN_ALL_VALUE","BUILT_IN_ALL_VALUE_IN_GROUPO"].includes(t.formState.builtInFormula||"")?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(l,{value:"SUM"},{default:e.withCtx(()=>[e.createTextVNode("求和")]),_:1}),e.createVNode(l,{value:"AVG"},{default:e.withCtx(()=>[e.createTextVNode("求平均")]),_:1}),e.createVNode(l,{value:"MAX"},{default:e.withCtx(()=>[e.createTextVNode("求最大值")]),_:1}),e.createVNode(l,{value:"MIN"},{default:e.withCtx(()=>[e.createTextVNode("求最小值")]),_:1})],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(l,{value:"ASC"},{default:e.withCtx(()=>[e.createTextVNode("升序")]),_:1}),e.createVNode(l,{value:"DESC"},{default:e.withCtx(()=>[e.createTextVNode("降序")]),_:1})],64))]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"])),["FIRST_ROW_RATE","DATE_OFFSET"].includes(t.formState.builtInFormula)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:1,label:"取数逻辑","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[["BUILT_IN_RANK_IN_GROUPO","BUILT_IN_ALL_VALUE_IN_GROUPO"].includes(t.formState.builtInFormula)&&t.formState.builtInValueSource?(e.openBlock(),e.createElementBlock("div",ed," 蓝色字段跟随您后续维度设置的顺序而变化,以获取相应的"+e.toDisplayString(t.formState.builtInValueSource),1)):e.createCommentVNode("",!0),e.createVNode(u,{value:t.accessLogic,rows:6,disabled:""},null,8,["value"])]),_:1},8,["label-col","wrapper-col"]))],64)):e.createCommentVNode("",!0),t.formState.calcType==="COMPONENT"?(e.openBlock(),e.createBlock(d,{key:2,label:"数值来自","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(s,{"show-search":"",value:t.formState.builtInValueSource,"onUpdate:value":o[6]||(o[6]=w=>t.formState.builtInValueSource=w),"filter-option":t.filterOption,options:t.componentList,fieldNames:{value:"id",label:"keyName"},onChange:t.onChangeComponent},null,8,["value","filter-option","options","onChange"])]),_:1},8,["label-col","wrapper-col"])):e.createCommentVNode("",!0),t.formState.builtInFormula==="DATE_OFFSET"?(e.openBlock(),e.createBlock(d,{key:3,label:"偏移设置","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[e.createElementVNode("div",td,[e.createVNode(m,{value:t.offsetConfig.value,"onUpdate:value":o[7]||(o[7]=w=>t.offsetConfig.value=w),style:{width:"120px","margin-right":"10px"},onChange:t.onChange},null,8,["value","onChange"]),e.createVNode(s,{value:t.offsetConfig.unit,"onUpdate:value":o[8]||(o[8]=w=>t.offsetConfig.unit=w),style:{width:"120px","margin-right":"10px"},onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(l,{value:"YEAR"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(l,{value:"MONTH"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(l,{value:"DAY"},{default:e.withCtx(()=>[e.createTextVNode("天")]),_:1})]),_:1},8,["value","onChange"]),e.createVNode(s,{value:t.offsetConfig.around,"onUpdate:value":o[9]||(o[9]=w=>t.offsetConfig.around=w),style:{width:"120px"},onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(l,{value:"before"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(l,{value:"after"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value","onChange"]),e.createVNode(h,{title:"内置公式【日期偏移】,依赖于【全局过滤】中的时间条件,若没有配置则不会进行偏移计算",overlayClassName:"question-tooltip",color:"#fff"},{default:e.withCtx(()=>[e.createVNode(b,{class:"icon",style:{color:"#40a9ff","font-size":"18px",cursor:"pointer","margin-left":"10px"}})]),_:1})])]),_:1},8,["label-col","wrapper-col"])):e.createCommentVNode("",!0)]),_:1},8,["model","rules"])]),_:1},8,["title","visible","onOk","onCancel"])}const nd=ne(Zc,[["render",od],["__scopeId","data-v-33575cd9"]]),ad=e.defineComponent({name:"DataConfigCard",directives:{focus:Ca},components:{CalculationModal:nd,FilterModal:fc,CustomGroupModal:Ss,SettingOutlined:Si,DeleteOutlined:Xn,CopyOutlined:Bl,InfoCircleOutlined:Yl,CustomSortModal:ds,PlusOutlined:pi,ACard:P.Card,ACheckbox:P.Checkbox,AInput:P.Input,ADropdown:P.Dropdown,AMenu:P.Menu,ASubMenu:P.SubMenu,AMenuItem:P.MenuItem,AMenuDivider:P.MenuDivider,ASelect:P.Select,APopover:P.Popover,Draggable:mt,ConfigName:Cc,SortByCpnt:Nc,DimByCount:Bc},props:{title:{type:String,default:""},type:{type:String,default:""}},setup(t){const o=[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"}],n=e.inject(Ce),a=e.inject(xe),r=e.inject(ve),i=["leftAxisList","rightAxisList","indicators"],c=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],d=e.inject(At),l=e.ref(),s=(v={})=>{var K;const{type:U}=t;if(e.unref(d)==="SQL_VIEW")return!0;e.unref(d)==="EDV_DATA_SET"&&a({edvDataSetId:v.parentId});let Y=!1;if(v.scope==="FIELD"&&(Y=!0,v.genericType==="0"&&i.includes(U)&&(Y=!1)),["IDX","BUILT_IN_IDX"].includes(v.scope)?i.includes(U)&&(Y=!0):["DIM","BUILT_IN_DIM"].includes(v.scope)&&c.includes(U)&&(Y=!0),U==="dimensionList"){const re=((K=e.unref(n)[U])==null?void 0:K.slice())||[];(re==null?void 0:re.length)===1&&(Y=!1)}return Y},p=e.computed(()=>e.unref(te).type==="ecanDataSelect"&&t.type==="indicators"),u=(v="{}")=>{var U,Y;try{const K=JSON.parse(v);if(!s(K))return;const re=((U=e.unref(n)[t.type])==null?void 0:U.slice())||[];(t.type==="seriesList"||t.type==="classificationList"&&!ge(e.unref(te).type,["list","circulate","scatter"])||e.unref(p))&&re.forEach(he=>{he.show=!1}),b(re,K),K.randomKey=Se(),re.push(K);const{type:le}=t,J={};if(["IDX","BUILT_IN_IDX","FIELD"].includes(K.scope)){const he=((Y=e.unref(n))==null?void 0:Y.variableList)||[];let de=sessionStorage.getItem("indicator-variates");if(K.scope==="FIELD"&&!i.includes(le)&&(de="[]"),de){const ce=JSON.parse(de);if(ce!=null&&ce.length)for(const ye of ce)he.unshift({...ye,dataType:"",id:null,variableValue:e.unref(d)==="EDV_DATA_SET"?ye.defaultValue:null,dateTypeValue:null,format:ye.valueFormat&&ye.valueFormat.toUpperCase()||null,variableName:ye.name,variableType:ye.valueType,label:K.label,randomKey:K.randomKey,keyValue:Se(),disabled:e.unref(d)==="EDV_DATA_SET"})}J.variableList=he,J.variableConditions=Lt(he,r)}a({[t.type]:re,...J}),sessionStorage.setItem("indicator-list-item",""),sessionStorage.setItem("indicator-variates","")}catch(K){console.error(K)}},m=(v="{}")=>{var U;try{const{cardItem:Y,type:K,index:re}=JSON.parse(v);if(!s(Y)||K===t.type)return;const le=((U=e.unref(n)[t.type])==null?void 0:U.slice())||[];b(le,Y),le.push(Y);const J=e.unref(n)[K].slice()||[];J.splice(re,1),a({[t.type]:le,[K]:J})}catch(Y){console.error(Y)}};function b(v,U){const Y=[];if(v.forEach(K=>{K.label.includes(U.label)&&Y.push(K.label.split(U.label)[1])}),Y.length>=1){for(let K=1;K<=Y.length;K++)if(!Y.includes(K+"")){U.label=U.label+K;break}}}const h=(v,U)=>{var re,le;const Y=(re=v.target)==null?void 0:re.checked,K=((le=e.unref(n)[t.type])==null?void 0:le.slice())||[];(t.type==="seriesList"||t.type==="classificationList"&&!ge(e.unref(te).type,["list","circulate"])||e.unref(p))&&K.forEach(J=>{J.show=!1}),K[U].show=Y,a({[t.type]:K})},f=v=>{var Y;const U=((Y=e.unref(n)[t.type])==null?void 0:Y.slice())||[];U.splice(v,1),a({[t.type]:U})},g=()=>{sessionStorage.setItem("indicator-card-item","")},w=v=>{const U=sessionStorage.getItem("indicator-list-item"),Y=sessionStorage.getItem("indicator-card-item");U?u(U):Y&&m(Y)},C=v=>{var he,de;const{newIndex:U,oldIndex:Y,from:K,to:re}=v,le=K.id,J=re.id;if(U>=0&&Y>=0){if(le===J){const ce=((he=e.unref(n)[t.type])==null?void 0:he.slice())||[],ye=ce.splice(Y,1)[0];ye&&(ce.splice(U,0,ye),a({[t.type]:ce}))}else if(t.type===J){const ce=((de=e.unref(n)[J])==null?void 0:de.slice())||[];if(ce!=null&&ce.length){const ye=ce.splice(ce.length-1,1)[0];ye&&(ce.splice(U,0,ye),a({[t.type]:ce}))}}}},x=(v,U)=>{const Y=v.oldIndex,K=U[Y];K&&sessionStorage.setItem("indicator-card-item",JSON.stringify({cardItem:K,type:t.type,index:Y}))},A=e.computed(()=>e.unref(n)[t.type]||[]),y=e.ref([]);let _=!1;e.watch(()=>e.unref(A).length,v=>{y.value=new Array(v).fill(!1)},{flush:"post",immediate:!0});const E=v=>{var Y,K,re;const U=((Y=e.unref(n)[t.type])==null?void 0:Y.slice())||[];if((K=U[v])!=null&&K.randomKey){const le=((re=e.unref(n))==null?void 0:re.variableList)||[];for(let J=le.length-1;J>=0;J--)le[J].randomKey===U[v].randomKey&&le.splice(J,1);a({variableConditions:Lt(le,r),variableList:le})}U.splice(v,1),a({[t.type]:U})},T=v=>{y.value[v]=!0},V=()=>{_=!0},N=(v,U,Y)=>{var K,re,le,J;if(y.value[U]=!1,_){const he=(K=v.target)==null?void 0:K.value,de=((re=e.unref(n)[t.type])==null?void 0:re.slice())||[],ce=de.filter(me=>{var be;return(be=me==null?void 0:me.formula)==null?void 0:be.includes(Y)}).map(me=>me.id),ye=de.filter(me=>{var be;return(be=me==null?void 0:me.builtInValueSource)==null?void 0:be.includes(Y)}).map(me=>me.id);if(ce!=null&&ce.length)for(const me of ce){const be=de.find(ft=>ft.id===me);be.formula=be.formula.replaceAll(Y,he)}if(ye!=null&&ye.length)for(const me of ye){const be=de.find(ft=>ft.id===me);be.builtInValueSource=be.builtInValueSource.replaceAll(Y,he)}if(de[U].label=he,(le=de[U])!=null&&le.randomKey){const me=((J=e.unref(n))==null?void 0:J.variableList)||[],be=me.filter(ft=>ft.randomKey===de[U].randomKey);be!=null&&be.length&&be.forEach(ft=>{ft.label=he}),a({variableConditions:Lt(me,r),variableList:me})}a({[t.type]:de})}_=!1},I="DEFAULT",M=e.computed(()=>{const v=[],{scope:U}=e.unref(l)||{},Y=e.unref(n)[t.type]||[];if(U==="DIM"&&!e.unref(l).typeGuid.includes("_code")){const J=ee.cloneDeep(e.unref(l));delete J.show,delete J.truncations,delete J.conditions,J.hrpIndexComplexid+="_code",J.id+="_code",J.typeGuid+="_code",J.label=J.name+"_编码",J.name=J.typeGuid,J.defaultCode=J.typeGuid,v.push(J)}const{leftAxisList:K=[],rightAxisList:re=[],indicators:le=[]}=e.unref(n)||{};return[...Y,...v,...K,...re,...le]}),j=(v={},U,Y="ASC")=>{var de;const{label:K,name:re,id:le,defaultCode:J}=v,he=((de=e.unref(n)[t.type])==null?void 0:de.slice())||[];le===I?delete he[U].sort:he[U].sort={label:K,columnName:re,type:"NORMAL",order:Y,defaultCode:J},a({[t.type]:he})},B=(v={},U="ASC")=>{const K={ASC:"升序",DESC:"降序"}[U],{sort:re}=v,{label:le,order:J}=re||{};return le&&J===U?`${K}(${le})`:K},F=e.ref(),O=e.ref(),G=e.ref(),R=e.ref(),S=(v={},U)=>{var Y;F.value=v,O.value=U,(Y=e.unref(G))==null||Y.showModal(v)},L=v=>"排序"+(v!=null&&v.sort?"(已配置)":""),k=(v={},U)=>{var Y;F.value=v,O.value=U,(Y=e.unref(R))==null||Y.showModal()},D=v=>"自定义分组"+((v==null?void 0:v.customGroup)!=null?"(已配置)":""),$=[{name:"总和",value:"SUM"},{name:"平均数",value:"AVG"},{name:"最小值",value:"MIN"},{name:"最大值",value:"MAX"},{name:"计数",value:"COUNT"}],z=[{name:"是",value:1},{name:"否",value:0}],W=(v,U)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[U].aggregate=v,a({[t.type]:Y})},Q=(v,U)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[U].distinct=v,a({[t.type]:Y})},Z=(v,U)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[U].dateFormat=v,a({[t.type]:Y})},oe=(v="SUM")=>`汇总方式(${{SUM:"总和",AVG:"平均数",MIN:"最小值",MAX:"最大值",COUNT:"计数"}[v]})`,ie=v=>`是否去重(${{0:"否",1:"是"}[v]||"否"})`,se=(v={})=>{var U;return"过滤"+(v!=null&&v.conditions&&((U=v==null?void 0:v.conditions)==null?void 0:U.length)>0?"(已配置)":"")},je=e.ref(),ct=e.ref(),He=e.ref(),pe=e.ref(),Te=(v={},U)=>{F.value=v,O.value=U,e.unref(je).showModal()},nt=(v={},U)=>{F.value=v,O.value=U,e.unref(ct).showModal(v)},Ut=(v={},U)=>{F.value=v,O.value=U,e.unref(He).showModal(v)},Nt=(v={},U)=>{F.value=v,O.value=U,e.unref(pe).showModal(v,e.unref(Ht))},dt=e.ref(),Le=e.ref("add"),Qe=(v,U,Y)=>{var K;Le.value=v,v==="edit"&&(F.value=U,O.value=Y),(K=e.unref(dt))==null||K.showModal()},Xe=e.inject(Oe),Je=e.unref(e.inject(De)),Be=e.ref([]),pt=e.computed(()=>e.unref(n)[t.type]||{});e.watch(n,()=>{var v;ge(e.unref(te).type,["scatter","valueline"])&&((v=e.unref(n))!=null&&v.indicators)&&(Be.value=e.unref(n).indicators.map(U=>({label:U.label,value:U.label})))}),e.watch(()=>n.value.classificationList,()=>{at()});const Ze=e.ref(""),at=async()=>{const{source:v}=e.unref(n);if(v!=="EDV_DATA_SET"||!ge(e.unref(te).type,"select"))return;const{classificationList:U=[]}=e.unref(n),Y=U.find(J=>J.show);if(Y!=null&&Y.parentId){if(e.unref(Ze)===Y.parentId)return;Ze.value=Y.parentId}else{e.unref(n).selectFieldOptions=[],Be.value=[],Ze.value="";return}const K=await Xe.get(`${_e}/dataset/`+Y.parentId,{headers:{Authentication:Je,operateContext:"ygt"}}),{success:re,data:le=[]}=K.data;if(re){const J=le.column.map(he=>({label:he.columnName,value:he.columnName}));e.unref(n).selectFieldOptions=J,Be.value=J}},ut=async()=>{const{source:v}=e.unref(n);if(!ge(e.unref(te).type,["scatter","valueline"]))try{if(v==="EDV_DATA_SET")await at();else{const U=await Xe.post(`${_e}/diagram/dimFields`,{},{headers:{Authentication:Je,operateContext:"ygt"}}),{success:Y,data:K=[]}=U.data;Y&&(e.unref(n).selectFieldOptions=K||[],Be.value=K)}}catch(U){console.error(U)}},go=(v,U)=>{const Y=e.unref(n)[t.type]||{};Y[U]=v,a({[t.type]:Y})},Gt=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],zt=e.ref({}),Ht=e.ref([]),H=async(v,U)=>{var K;const{name:Y}=U;if(!Gt.includes(t.type)&&v&&gt(U,"indexCode")){const re=await Xe.post(`${_e}/diagram/hrpIndexWithComplex`,{dataSourceId:"",indexGuid:U.id,indexCode:U.indexCode,pageId:(K=window==null?void 0:window.config)==null?void 0:K.pageId},{headers:{Authentication:Je,operateContext:"ygt"}}),{success:le,data:J}=re.data;le&&J&&(Ht.value=(J==null?void 0:J.dataViewColumns)||[],zt.value[Y]={name:J.name,code:J.indexCode})}},q=v=>{l.value=v},X=v=>{const U=document.createElement("input");document.body.appendChild(U),U.setAttribute("value",v),U.select(),document.execCommand("copy"),document.body.removeChild(U),P.message.success("复制成功")},te=e.inject(Ye),ae=e.computed(()=>t.type==="indicators"&&e.unref(te).type==="ecanTable"),fe=e.computed(()=>!!["indicators","classificationList","leftAxisList","rightAxisList"].includes(t.type));return e.onMounted(()=>{t.type==="formFields"&&(e.unref(te).type==="ecanDataSelect"?Be.value=[{label:"维度编码",value:"_code"},{label:"维度值",value:"_value"}]:ut())}),{onCheckboxChange:h,onDropEnd:f,onDragItemEnd:g,onDragItemAdd:w,onDragItemSort:C,onDragItemStart:x,cardItemList:A,onDelete:E,onEdit:T,onCommitLabelChange:N,sortList:M,onSort:j,handleSortTitle:B,showCustomSortModal:S,customSortModalRef:G,currentItem:F,currentIndex:O,handleCustomSortTitle:L,handleCustomGroupTitle:D,customGroupModalRef:R,showCustomGroupModal:k,editLabelList:y,onLabelChange:V,aggregateList:$,distinctList:z,onAggregateChange:W,onDistinctChange:Q,onDateFormatChange:Z,handleAggregateTitle:oe,handleDistinctTitle:ie,onShowCalculationModal:Qe,handleFilterTitle:se,filterModalRef:je,configNameRef:ct,sortByCpntRef:He,dimByCountRef:pe,showFilterModal:Te,calculationModalRef:dt,calculationModalMode:Le,formatList:o,fieldOptions:Be,fieldData:pt,onFieldChange:go,onVisibleChange:H,onClickSetting:q,copyDataViewName:X,dataViewMap:zt,isShowConfigName:ae,showConfigNameModal:nt,dimensionType:Gt,isShowSortByCpnt:fe,showSortByCpntModal:Ut,dataSelectIndicators:p,showDimByCountModal:Nt,selectedComponent:te,lowerCaseIncludes:ge}}}),Om="",Dm="",rt=t=>(e.pushScopeId("data-v-57291191"),t=t(),e.popScopeId(),t),rd={class:"title"},ld={class:"title-text"},id={class:"field-wrap"},sd={class:"field-item"},cd=rt(()=>e.createElementVNode("div",{class:"item-label"},"名称:",-1)),dd={class:"field-item"},pd=rt(()=>e.createElementVNode("div",{class:"item-label"},"值:",-1)),ud={key:0,class:"field-item"},fd=rt(()=>e.createElementVNode("div",{class:"item-label",style:{width:"20px"}},null,-1)),md={class:"title"},hd={class:"title-text"},yd=rt(()=>e.createElementVNode("p",null,"配置了维度后,会使用返回数据的第一条中以【维度名】为key的值作为显示值",-1)),gd=rt(()=>e.createElementVNode("span",null,"添加计算指标",-1)),bd={class:"card-item-wrap"},Cd={class:"card-item-inner"},wd=["onClick"],kd=["onClick"],_d=["onClick"],Sd={style:{display:"flex","align-items":"center"}},xd=["title"],Nd=rt(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"指标名:",-1)),Ad={style:{display:"flex","align-items":"center"}},Td=["title"],Ed=rt(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"指标编码:",-1));function Vd(t,o,n,a,r,i){const c=e.resolveComponent("a-select"),d=e.resolveComponent("a-checkbox"),l=e.resolveComponent("a-card"),s=e.resolveComponent("info-circle-outlined"),p=e.resolveComponent("a-popover"),u=e.resolveComponent("plus-outlined"),m=e.resolveComponent("a-input"),b=e.resolveComponent("setting-outlined"),h=e.resolveComponent("a-menu-item"),f=e.resolveComponent("a-menu-divider"),g=e.resolveComponent("a-sub-menu"),w=e.resolveComponent("copy-outlined"),C=e.resolveComponent("a-menu"),x=e.resolveComponent("a-dropdown"),A=e.resolveComponent("delete-outlined"),y=e.resolveComponent("draggable"),_=e.resolveComponent("custom-sort-modal"),E=e.resolveComponent("custom-group-modal"),T=e.resolveComponent("filter-modal"),V=e.resolveComponent("config-name"),N=e.resolveComponent("sort-by-cpnt"),I=e.resolveComponent("dim-by-count"),M=e.resolveComponent("calculation-modal"),j=e.resolveDirective("focus");return t.type==="formFields"?(e.openBlock(),e.createBlock(l,{key:0,class:"data-config-card","head-style":{backgroundColor:"rgba(161,212,230,0.3)",height:"58px",padding:"0 10px"}},{title:e.withCtx(()=>[e.createElementVNode("div",rd,[e.createElementVNode("div",ld,e.toDisplayString(t.title),1)])]),default:e.withCtx(()=>[e.createElementVNode("div",id,[e.createElementVNode("div",sd,[cd,e.createVNode(c,{style:{width:"70%"},class:"item-select",value:t.fieldData.labelField,options:t.fieldOptions,onChange:o[0]||(o[0]=B=>t.onFieldChange(B,"labelField"))},null,8,["value","options"])]),e.createElementVNode("div",dd,[pd,e.createVNode(c,{style:{width:"70%"},class:"item-select",value:t.fieldData.valueField,options:t.fieldOptions,mode:t.lowerCaseIncludes(t.selectedComponent.type,"valueline")?"multiple":void 0,onChange:o[1]||(o[1]=B=>t.onFieldChange(B,"valueField"))},null,8,["value","options","mode"])]),t.selectedComponent.type==="ecanSelect"?(e.openBlock(),e.createElementBlock("div",ud,[fd,e.createVNode(d,{checked:t.fieldData.hasAllOption,"onUpdate:checked":o[2]||(o[2]=B=>t.fieldData.hasAllOption=B)},{default:e.withCtx(()=>[e.createTextVNode(" 显示【全部】选项 ")]),_:1},8,["checked"])])):e.createCommentVNode("",!0)])]),_:1},8,["head-style"])):(e.openBlock(),e.createBlock(l,{key:1,class:"data-config-card","head-style":{backgroundColor:"rgba(161,212,230,0.3)",height:"58px",padding:"0 10px"}},{title:e.withCtx(()=>[e.createElementVNode("div",md,[e.createElementVNode("div",hd,[e.createTextVNode(e.toDisplayString(t.title)+" ",1),t.type==="dimensionList"?(e.openBlock(),e.createBlock(p,{key:0,title:"提示",placement:"topLeft"},{content:e.withCtx(()=>[yd]),default:e.withCtx(()=>[e.createVNode(s,{style:{color:"#919191",cursor:"pointer"}})]),_:1})):e.createCommentVNode("",!0)]),!t.dimensionType.includes(t.type)&&!t.dataSelectIndicators?(e.openBlock(),e.createElementBlock("div",{key:0,class:"add-calculation",onClick:o[3]||(o[3]=e.withModifiers(B=>t.onShowCalculationModal("add"),["prevent","stop"]))},[e.createVNode(u,{class:"add-calculation-icon"}),gd])):e.createCommentVNode("",!0)])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(t.type+"-list"),style:{height:"100%",padding:"10px"}},[e.createVNode(y,{modelValue:t.cardItemList,"onUpdate:modelValue":o[4]||(o[4]=B=>t.cardItemList=B),class:"chart-column",id:t.type,group:"cardItem","item-key":"index",onAdd:t.onDragItemAdd,onSort:t.onDragItemSort,onEnd:t.onDragItemEnd,onStart:o[5]||(o[5]=B=>t.onDragItemStart(B,t.cardItemList))},{item:e.withCtx(({element:B,index:F})=>[e.createElementVNode("div",bd,[e.createVNode(d,{class:"card-item",checked:B.show,onChange:O=>t.onCheckboxChange(O,F)},{default:e.withCtx(()=>[e.createElementVNode("div",Cd,[!t.editLabelList[F]&&B.label?(e.openBlock(),e.createElementBlock("div",{key:0,class:"name",onClick:e.withModifiers(O=>t.onEdit(F),["prevent","stop"])},e.toDisplayString(B.label),9,wd)):e.createCommentVNode("",!0),!t.editLabelList[F]&&!B.label?(e.openBlock(),e.createElementBlock("div",{key:1,class:"name placeholder",onClick:e.withModifiers(O=>t.onEdit(F),["prevent","stop"])}," 请点击填入名字 ",8,kd)):e.createCommentVNode("",!0),t.editLabelList[F]?e.withDirectives((e.openBlock(),e.createBlock(m,{key:2,"default-value":B.label,size:"small",onBlur:O=>t.onCommitLabelChange(O,F,B.label),onPressEnter:O=>t.onCommitLabelChange(O,F,B.label),onChange:t.onLabelChange},null,8,["default-value","onBlur","onPressEnter","onChange"])),[[j]]):e.createCommentVNode("",!0),["FORMULA","BUILT_IN","COMPONENT"].includes(B.calcType)?(e.openBlock(),e.createElementBlock("span",{key:3,class:"calculation-icon",onClick:e.withModifiers(O=>t.onShowCalculationModal("edit",B,F),["prevent","stop"])}," fx ",8,_d)):e.createCommentVNode("",!0),e.createVNode(x,{trigger:["click"],onVisibleChange:O=>t.onVisibleChange(O,B)},{overlay:e.withCtx(()=>[e.createVNode(C,null,{default:e.withCtx(()=>[t.dimensionType.includes(t.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(h,{onClick:O=>t.showCustomSortModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleCustomSortTitle(B)),1)]),_:2},1032,["onClick"]),e.createVNode(f),e.createVNode(h,{onClick:O=>t.showCustomGroupModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleCustomGroupTitle(B)),1)]),_:2},1032,["onClick"]),e.createVNode(f),B.genericType==="DATE"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(g,{title:"日期格式化"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formatList,O=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:O.value,onClick:G=>t.onDateFormatChange(O.value,F)},{default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(B.dateFormat===O.value||!B.dateFormat&&O.value==="YYYY-MM"?"color: #1890FF;":"")},e.toDisplayString(O.label),5)]),_:2},1032,["onClick"]))),128))]),_:2},1024),e.createVNode(f)],64)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createVNode(h,{onClick:O=>t.showFilterModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleFilterTitle(B)),1)]),_:2},1032,["onClick"]),e.createVNode(f),["classificationList","seriesList"].includes(t.type)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(g,{title:t.handleAggregateTitle(B.aggregate)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.aggregateList,O=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:O.value,onClick:G=>t.onAggregateChange(O.value,F)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(O.name),1)]),_:2},1032,["onClick"]))),128))]),_:2},1032,["title"]),e.createVNode(f)],64)),t.isShowConfigName?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(h,{onClick:O=>t.showConfigNameModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(" 修改展示名称 ")]),_:2},1032,["onClick"]),e.createVNode(f)],64)):e.createCommentVNode("",!0),t.isShowSortByCpnt?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createVNode(h,{onClick:O=>t.showSortByCpntModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(" 关联组件排序 ")]),_:2},1032,["onClick"]),e.createVNode(f)],64)):e.createCommentVNode("",!0),B.name==="the_count"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createVNode(h,{onClick:O=>t.showDimByCountModal(B,F)},{default:e.withCtx(()=>[e.createTextVNode(" 关联维度 ")]),_:2},1032,["onClick"]),e.createVNode(f),e.createVNode(g,{title:t.handleDistinctTitle(B.distinct)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.distinctList,O=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:O.value,onClick:G=>t.onDistinctChange(O.value,F)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(O.name),1)]),_:2},1032,["onClick"]))),128))]),_:2},1032,["title"]),e.createVNode(f)],64)):e.createCommentVNode("",!0),t.dimensionType.includes(t.type)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[t.dataViewMap[B.name]?(e.openBlock(),e.createBlock(h,{key:0,onClick:O=>t.copyDataViewName(t.dataViewMap[B.name].name)},{default:e.withCtx(()=>[e.createElementVNode("div",Sd,[e.createElementVNode("span",{class:"data-view-name",title:t.dataViewMap[B.name].name},[Nd,e.createTextVNode(" "+e.toDisplayString(t.dataViewMap[B.name].name),1)],8,xd),e.createVNode(w,{style:{color:"#52C41A","margin-left":"10px"},title:"点击复制"})])]),_:2},1032,["onClick"])):e.createCommentVNode("",!0),t.dataViewMap[B.name]?(e.openBlock(),e.createBlock(h,{key:1,onClick:O=>t.copyDataViewName(t.dataViewMap[B.name].code)},{default:e.withCtx(()=>[e.createElementVNode("div",Ad,[e.createElementVNode("span",{class:"data-view-name",title:t.dataViewMap[B.name].code},[Ed,e.createTextVNode(" "+e.toDisplayString(t.dataViewMap[B.name].code),1)],8,Td),e.createVNode(w,{style:{color:"#52C41A","margin-left":"10px"},title:"点击复制"})])]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)],64))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(b,{class:"setting-icon",onClick:O=>t.onClickSetting(B)},null,8,["onClick"])]),_:2},1032,["onVisibleChange"]),e.createVNode(A,{class:"delete-icon",onClick:e.withModifiers(O=>t.onDelete(F),["prevent"])},null,8,["onClick"])])]),_:2},1032,["checked","onChange"])])]),_:1},8,["modelValue","id","onAdd","onSort","onEnd"])],2),e.createVNode(_,{item:t.currentItem,index:t.currentIndex,type:t.type,sortList:t.sortList,ref:"customSortModalRef"},null,8,["item","index","type","sortList"]),e.createVNode(E,{item:t.currentItem,index:t.currentIndex,type:t.type,ref:"customGroupModalRef"},null,8,["item","index","type"]),e.createVNode(T,{item:t.currentItem,index:t.currentIndex,type:t.type,ref:"filterModalRef"},null,8,["item","index","type"]),e.createVNode(V,{index:t.currentIndex,type:t.type,ref:"configNameRef"},null,8,["index","type"]),e.createVNode(N,{index:t.currentIndex,type:t.type,ref:"sortByCpntRef"},null,8,["index","type"]),e.createVNode(I,{index:t.currentIndex,type:t.type,ref:"dimByCountRef"},null,8,["index","type"]),e.createVNode(M,{type:t.type,item:t.currentItem,index:t.currentIndex,mode:t.calculationModalMode,ref:"calculationModalRef"},null,8,["type","item","index","mode"])]),_:1},8,["head-style"]))}const Ld=ne(ad,[["render",Vd],["__scopeId","data-v-57291191"]]),Bd={classificationList:{title:"分类"},seriesList:{title:"系列"},leftAxisList:{title:"左值轴"},rightAxisList:{title:"右值轴"},indicators:{title:"数值"},queryColumnList:{title:"查询列"},rowHeaderList:{title:"行表头"},formFields:{title:"字段"},dimensionList:{title:"维度"}},Od=e.defineComponent({name:"DataConfigGroup",components:{DataConfigCard:Ld},setup(){const t=e.inject(Ye),o=e.computed(()=>{var l;return(l=e.unref(t))==null?void 0:l.type}),n=e.computed(()=>{var l;return!!((l=e.unref(t))!=null&&l.isGroupTable)}),a=e.ref({}),r=e.reactive([]),i=e.inject(xe),c=(l,s)=>Object.prototype.hasOwnProperty.call(l,s);return(()=>{var g,w;const l=ee.cloneDeep((g=e.unref(t))==null?void 0:g.graphicConfig),s=["classificationList","seriesList","leftAxisList","rightAxisList","indicators","rowHeaderList","queryColumnList"],p={pie:["classificationList","indicators"],circulate:["classificationList","indicators"],bar:["classificationList","seriesList","leftAxisList"],line:["classificationList","seriesList","leftAxisList"],comboGraph:["classificationList","seriesList","leftAxisList","rightAxisList"],radar:["classificationList","seriesList","leftAxisList"],table:n.value?["rowHeaderList","indicators"]:["queryColumnList","indicators"],text:["dimensionList","indicators"],proportion:["indicators"],select:["classificationList","formFields"],dataSelect:["classificationList","indicators","formFields"],checkbox:["classificationList","formFields"],radio:["classificationList","formFields"],list:["classificationList","indicators"],counter:["indicators"],scatter:["classificationList","indicators","formFields"],pivotTable:["queryColumnList","indicators"],valueLine:["classificationList","indicators","formFields"]},u="ecan";let m=e.unref(o);if(m.startsWith(u)){const C=u.length;m=((w=m.slice(C,C+1))==null?void 0:w.toLowerCase())+m.slice(C+1)}const b=p[m],h=Bd,f=(b==null?void 0:b.length)||0;for(let C=0;C<f;C++){const x=b[C];if(!x)break;r.push({...h[x],type:x})}for(const C of s)c(l,C)&&!b.find(x=>x===C)&&(l[C]=[]);i(l)})(),{cardsMap:a,cards:r}}}),Im="",Fm="",Dd={class:"data-group"};function Id(t,o,n,a,r,i){const c=e.resolveComponent("data-config-card");return e.openBlock(),e.createElementBlock("div",Dd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.cards,d=>(e.openBlock(),e.createBlock(c,e.mergeProps({key:d.type,class:"data-config-card",type:d.type},d),null,16,["type"]))),128))])}const Fd=ne(Od,[["render",Id],["__scopeId","data-v-e7f85d47"]]),$d=[{title:"基本属性",props:["name","width","height","colors"]},{title:"系列",props:["seriesTypes"]},{title:"表格",onlyType:["table"],props:["size","allOverflow","hoverRow","hoverColor","boderList","columnDropEnable","showTotalBool","totalName","expandAll"]},{title:"折线图",onlyType:["line","comboGraph"],props:["areaStyleOpacity","smooth","lineStyleWidth","symbolSize"]},{title:"柱状图",onlyType:["bar","comboGraph"],props:["barWidth","isUseHorizontalAxis","axisInverse","isStack","labelShow"]},{title:"饼图",onlyType:"pie",props:["centerTop","centerLeft","innerRadius","outerRadius","roseType","minAngle"]},{title:"布局",props:["gridTop","gridBottom","gridLeft","gridRight","gridContainLabel"]},{title:"x轴",props:["xAxisLabelColor","xAxisLineStyleColor","xAxisLabelWidth","xAxisLabelOverflow","xAxisLabelRotate","xAxisTickShow","xAxisSplitLineShow","xAxisSplitLineStyleColor","xAxisLabelFormatter","xAxisInverse","xAxisMinInterval","xAxisLabelInterval"]},{title:"y轴",props:["yAxisLabelColor","yAxisLineStyleColor","yAxisLineAlwaysDisplay","yAxisLabelWidth","yAxisLabelOverflow","yAxisLabelRotate","yAxisSplitLineShow","yAxisSplitLineStyleColor","yAxisLabelFormatter","yAxisInverse","yAxisMinInterval","yAxis"]},{title:"标签",enableProps:"labelShow",props:["labelFormatter","labelColor","isUseLabelColors","labelFontSize","labelPosition"]},{title:"标签引导线",enableProps:"labelLineShow",props:["labelLineLength","labelLineLength2"]},{title:"图例",enableProps:"legendShow",props:["legendTextStyleColor","legendTop","legendLeft","legendOrient"]},{title:"提示框",enableProps:"tooltipShow",props:["tooltipTrigger","tooltipFormatter","tooltipTextStyleColor"]},{title:"工具栏",enableProps:"toolboxShow",props:["toolboxOrient","toolboxItemSize","toolboxItemGap","toolboxLeft","toolboxTop","toolboxDataZoomShow","toolboxInfoShow"]}],Pd={name:{label:"控件别名",component:"input"},title:{label:"标题",component:"input"},width:{label:"宽度",component:"input-number",props:{suffix:"px",min:0}},height:{label:"高度",component:"input-number",props:{suffix:"px",min:10}},colors:{label:"颜色",component:"color-group-pick"},centerLeft:{label:"水平位置",component:"input-number",props:{suffix:"%",min:0,max:100}},centerTop:{label:"垂直位置",component:"input-number",props:{suffix:"%",min:0,max:100}},innerRadius:{label:"内半径",component:"input-number",props:{suffix:"%",min:0,max:100}},outerRadius:{label:"外半径",component:"input-number",props:{suffix:"%",min:0,max:100}},tooltipTrigger:{label:"触发条件",component:"radio-group",props:{options:[{label:"图形",value:"item"},{label:"坐标轴",value:"axis"},{label:"无",value:"none"}]}},tooltipTextStyleColor:{label:"颜色",component:"color-pick"},tooltipFormatter:{label:"格式化",component:"textarea"},legendTextStyleColor:{label:"颜色",component:"color-pick"},legendTop:{label:"垂直位置",component:"radio-group",props:{options:[{label:"上",value:"top"},{label:"中",value:"middle"},{label:"下",value:"bottom"}]}},legendLeft:{label:"水平位置",component:"radio-group",props:{options:[{label:"左",value:"left"},{label:"中",value:"center"},{label:"右",value:"right"}]}},legendOrient:{label:"布局",component:"radio-group",props:{options:[{label:"垂直",value:"vertical"},{label:"水平",value:"horizontal"}]}},labelFormatter:{label:"格式化",component:"input"},labelColor:{label:"标签颜色",component:"color-pick"},isUseLabelColors:{label:"系列色",component:"switch"},labelFontSize:{label:"字体大小",component:"input-number",props:{min:12,suffix:"px"}},labelPosition:[{label:"位置",component:"radio-group",onlyType:"pie",props:{options:[{label:"外侧",value:"outside"},{label:"内侧",value:"inside"},{label:"中心",value:"center"}]}},{label:"位置",component:"select",onlyType:"bar",props:{options:[{label:"上",value:"top"},{label:"中",value:"inside"},{label:"下",value:"bottom"},{label:"右",value:"right"},{label:"左",value:"left"}]}}],labelLineLength:{label:"第一段",component:"input-number",props:{min:0}},labelLineLength2:{label:"第二段",component:"input-number",props:{min:0}},symbolSize:{label:"标记点尺寸",component:"input-number",props:{min:0}},smooth:{label:"线条光滑",component:"switch"},lineStyleWidth:{label:"线条宽度",component:"input-number",props:{min:0}},xAxisSplitLineShow:{label:"分割线",component:"switch"},xAxisSplitLineStyleColor:{label:"分割线颜色",component:"color-pick"},xAxisLabelColor:{label:"名称颜色",component:"color-pick"},xAxisLineStyleColor:{label:"横边颜色",component:"color-pick"},xAxisTickShow:{label:"显示刻度",component:"switch"},xAxisLabelFormatter:{label:"格式化",component:"input"},yAxisSplitLineShow:{label:"分割线",component:"switch"},yAxisLineAlwaysDisplay:{label:"显示竖边",component:"switch"},yAxisSplitLineStyleColor:{label:"分割线颜色",component:"color-pick"},yAxisLabelColor:{label:"名称颜色",component:"color-pick"},yAxisLineStyleColor:{label:"竖边颜色",component:"color-pick"},yAxisLabelFormatter:{label:"格式化",component:"input"},roseType:{label:"玫瑰图",component:"radio-group",props:{options:[{label:"不展示",value:""},{label:"圆心角",value:"area"},{label:"半径",value:"radius"}]}},yAxis:{label:"系列",component:"form-group",layout:"vertical",props:{max:2,format:[{label:["左轴","右轴"],type:"input",value:"axisLabelFormatter",props:{options:[{label:"柱状图",value:"bar"},{label:"折线图",value:"line"}]}}]}},seriesTypes:{label:"系列",component:"form-group",layout:"vertical",props:{format:[{label:"系列",type:"select",value:"type",useLabelIndex:!0,props:{options:[{label:"柱状图",value:"bar"},{label:"折线图",value:"line"}]}},{label:"对应轴",type:"select",value:"axisIndex",props:{options:[{label:"左轴",value:0},{label:"右轴",value:1}]}},{label:"提示框格式化",type:"input",value:"tooltipFormatter"}]}},barWidth:{label:"宽度",component:"input-number",props:{suffix:"%",min:0}},gridTop:{label:"上侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridBottom:{label:"下侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridLeft:{label:"左侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridRight:{label:"右侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridContainLabel:{label:"包含刻度标签",component:"switch"},toolboxOrient:{label:"排版",component:"radio-group",props:{options:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}]}},toolboxItemSize:{label:"图标大小",component:"input-number"},toolboxItemGap:{label:"图标间距",component:"input-number"},toolboxLeft:{label:"水平位置",component:"radio-group",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},toolboxTop:{label:"垂直位置",component:"radio-group",props:{options:[{label:"顶部",value:"top"},{label:"居中",value:"middle"},{label:"底部",value:"bottom"}]}},toolboxDownloadUrl:{label:"下载文件地址",component:"input"},toolboxInfoText:{label:"说明信息内容",component:"input"},isUseHorizontalAxis:{label:"横向排列",component:"switch"},axisInverse:{label:"倒叙排列",component:"switch"},xAxisInverse:{label:"图形反转",component:"switch"},yAxisInverse:{label:"图形反转",component:"switch"},areaStyleOpacity:{label:"面积透明度",component:"input-number",props:{step:.1,min:0,max:1}},xAxisLabelWidth:{label:"名称宽度",component:"input-number",props:{min:0}},xAxisLabelOverflow:{label:"名称溢出",component:"radio-group",props:{optionType:"button",options:[{label:"无",value:"none"},{label:"换行",value:"break"},{label:"省略号",value:"truncate"}]}},xAxisLabelRotate:{label:"名称旋转",component:"input-number"},yAxisLabelWidth:{label:"名称宽度",component:"input-number",props:{min:0}},yAxisLabelOverflow:{label:"名称溢出",component:"radio-group",props:{optionType:"button",options:[{label:"无",value:"none"},{label:"换行",value:"break"},{label:"省略号",value:"truncate"}]}},yAxisLabelRotate:{label:"名称旋转",component:"input-number"},isStack:{label:"是否堆叠",component:"switch"},labelShow:{label:"展示标签",component:"switch"},xAxisMinInterval:{label:"最小间距",component:"input-number",props:{min:0}},yAxisMinInterval:{label:"最小间距",component:"input-number",props:{min:0}},minAngle:{label:"最小角度",component:"input-number",props:{min:0,max:360}},xAxisLabelInterval:{label:"标签间隔",component:"input-number",props:{min:-1}},toolboxLocation:{label:"快速定位",component:"switch"},toolboxDownloadShow:{label:"使用数据下载",component:"switch"},toolboxDataZoomShow:{label:"使用放大",component:"switch"},toolboxInfoShow:{label:"指标信息",component:"switch"},size:{label:"尺寸",onlyType:"table",component:"radio-group",props:{options:[{label:"大",value:"medium"},{label:"中",value:"small"},{label:"小",value:"mini"}]}},allOverflow:{label:"表内容超出",onlyType:"table",component:"radio-group",props:{options:[{label:"换行",value:"false"},{label:"省略号",value:"ellipsis"},{label:"省略号+title显示",value:"title"},{label:"省略号+tooltip显示",value:"tooltip"}]}},hoverRow:{onlyType:"table",label:"点击行高亮",component:"switch"},hoverColor:{onlyType:"table",label:"hover行颜色",component:"color-pick"},boderList:{label:"边框不显示",component:"select",onlyType:"table",props:{mode:"multiple",options:[{label:"表格上边框",value:"top"},{label:"表格下边框",value:"bottom"},{label:"表格左边框",value:"left"},{label:"表格右边框",value:"right"},{label:"表格内容边框",value:"middle"},{label:"列按钮边框",value:"button"}]}},columnDropEnable:{onlyType:"table",label:"列拖拽",component:"switch"},showTotalBool:{onlyType:"table",label:"显示汇总行",component:"switch"},totalName:{onlyType:"table",label:"汇总行名",component:"input"},expandAll:{onlyType:"table",label:"展开所有节点",component:"switch"}},Md=e.defineComponent({name:"Input",directives:{focus},props:{value:{type:String,default:""},disabled:{type:Boolean,default:!1}},components:{AInput:P.Input},emits:["change"],setup(t,{emit:o}){return{onInputChange:a=>{o("change",a.target.value)}}}});function jd(t,o,n,a,r,i){const c=e.resolveComponent("a-input"),d=e.resolveDirective("focus");return e.withDirectives((e.openBlock(),e.createBlock(c,{value:t.value,disabled:t.disabled,onChange:t.onInputChange},null,8,["value","disabled","onChange"])),[[d]])}const vd=ne(Md,[["render",jd]]),Rd=e.defineComponent({name:"InputNumber",props:{value:{type:[String,Number,Object],default:""},valueKey:{type:String,default:"value"},prefixValueKey:{type:String,default:"prefix"},prefix:{type:[String,Array],default:""},suffixValueKey:{type:String,default:"suffix"},suffix:{type:[String,Array],default:""},min:{type:Number,default:-1/0},max:{type:Number,default:1/0},step:{type:[String,Number],default:1},useBlurEvent:{type:Boolean,default:!0}},components:{AInputNumber:P.InputNumber,ASelect:P.Select,ASelectOption:P.SelectOption},emits:["change"],setup(t,{emit:o}){const n=e.computed(()=>{const u=t.value;return typeof u=="string"?parseFloat(u):typeof u=="object"&&u!=null?u[t.valueKey]:u}),a=u=>t.value!=null&&typeof t.value=="object"?t.value[t[`${u}ValueKey`]]:Array.isArray(t[u])?t[u][0]&&t[u][0].value:null,r=e.ref(a("prefix")),i=e.ref(a("suffix"));return{inputValue:n,onInputChange:u=>{const m=t.suffix;Array.isArray(t.prefix)||Array.isArray(t.suffix)?o("change",{[t.valueKey]:u,[t.prefixValueKey]:e.unref(r),[t.suffixValueKey]:e.unref(i)}):m===""||u==null?o("change",u):o("change",`${u}${m}`)},parser:u=>typeof t.suffix=="string"?u.replace(t.suffix,""):Array.isArray(t.suffix)&&t.value!=null&&typeof t.value=="object"?u.replace(t.value[t.suffixValueKey],""):u,onInputBlur:()=>{t.useBlurEvent&&o("change",null,!1)},prefixValue:r,suffixValue:i,onPrefixChange:()=>{Array.isArray(t.prefix)&&o("change",{[t.valueKey]:e.unref(n),[t.prefixValueKey]:e.unref(r),[t.suffixValueKey]:e.unref(i)})},onSuffixChange:()=>{Array.isArray(t.suffix)&&o("change",{[t.valueKey]:e.unref(n),[t.prefixValueKey]:e.unref(r),[t.suffixValueKey]:e.unref(i)})}}}});function Ud(t,o,n,a,r,i){const c=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-input-number");return e.openBlock(),e.createBlock(l,{value:t.inputValue,min:t.min,max:t.max,step:t.step,parser:t.parser,"addon-before":Array.isArray(t.prefix)?void 0:t.prefix,"addon-after":Array.isArray(t.suffix)?void 0:t.prefix,onChange:t.onInputChange,onBlur:t.onInputBlur},e.createSlots({_:2},[Array.isArray(t.prefix)&&t.prefix.length>0?{name:"addonBefore",fn:e.withCtx(()=>[e.createVNode(d,{value:t.prefixValue,"onUpdate:value":o[0]||(o[0]=s=>t.prefixValue=s),onChange:t.onPrefixChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.prefix,({label:s,value:p},u)=>(e.openBlock(),e.createBlock(c,{key:u,value:p},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])]),key:"0"}:void 0,Array.isArray(t.suffix)&&t.suffix.length>0?{name:"addonAfter",fn:e.withCtx(()=>[e.createVNode(d,{value:t.suffixValue,"onUpdate:value":o[1]||(o[1]=s=>t.suffixValue=s),onChange:t.onSuffixChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.suffix,({label:s,value:p},u)=>(e.openBlock(),e.createBlock(c,{key:u,value:p},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])]),key:"1"}:void 0]),1032,["value","min","max","step","parser","addon-before","addon-after","onChange","onBlur"])}const _a=ne(Rd,[["render",Ud]]),Gd=e.defineComponent({name:"RadioGroup",props:{value:{type:[String,Number],default:""},options:{type:Array,default:()=>[]},optionType:{type:String,default:"default"},size:{type:String,default:"default"}},components:{ARadioGroup:P.RadioGroup,ARadioButton:P.RadioButton},emits:["change"],setup(t,{emit:o}){return{onRadioChange:a=>{o("change",a.target.value)}}}});function zd(t,o,n,a,r,i){const c=e.resolveComponent("a-radio-button"),d=e.resolveComponent("a-radio-group");return e.openBlock(),e.createBlock(d,{value:t.value,optionType:t.optionType,onChange:t.onRadioChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,l=>(e.openBlock(),e.createBlock(c,{key:l.value,value:l.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","optionType","onChange"])}const Hd=ne(Gd,[["render",zd]]),Yd=e.defineComponent({name:"Select",props:{value:{type:[String,Number,Array,Array],default:""},options:{type:Array,default:()=>[]}},components:{ASelect:P.Select,ASelectOption:P.SelectOption},emits:["change"],setup(t,{emit:o}){return{onSelectChange:a=>{o("change",a)}}}});function Wd(t,o,n,a,r,i){const c=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select");return e.openBlock(),e.createBlock(d,{value:t.value,onChange:t.onSelectChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,l=>(e.openBlock(),e.createBlock(c,{key:l.value,value:l.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])}const qd=ne(Yd,[["render",Wd]]),Kd=e.defineComponent({name:"Switch",props:{value:{type:Boolean,default:!1},width:{type:[String,Number],default:150},disabled:{type:Boolean,default:!1}},components:{ASwitch:P.Switch},emit:["change"],setup(t,{emit:o}){return{onSwitchChange:a=>{o("change",a)}}}});function Qd(t,o,n,a,r,i){const c=e.resolveComponent("a-switch");return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({width:`${t.width}px`})},[e.createVNode(c,{disabled:t.disabled,checked:t.value,onChange:t.onSwitchChange},null,8,["disabled","checked","onChange"])],4)}const Xd=ne(Kd,[["render",Qd]]);var Ne="top",Fe="bottom",$e="right",Ae="left",Jo="auto",Bt=[Ne,Fe,$e,Ae],bt="start",Ot="end",Jd="clippingParents",Sa="viewport",Dt="popper",Zd="reference",xa=Bt.reduce(function(t,o){return t.concat([o+"-"+bt,o+"-"+Ot])},[]),Na=[].concat(Bt,[Jo]).reduce(function(t,o){return t.concat([o,o+"-"+bt,o+"-"+Ot])},[]),ep="beforeRead",tp="read",op="afterRead",np="beforeMain",ap="main",rp="afterMain",lp="beforeWrite",ip="write",sp="afterWrite",cp=[ep,tp,op,np,ap,rp,lp,ip,sp];function Ue(t){return t?(t.nodeName||"").toLowerCase():null}function Ve(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var o=t.ownerDocument;return o&&o.defaultView||window}return t}function lt(t){var o=Ve(t).Element;return t instanceof o||t instanceof Element}function Pe(t){var o=Ve(t).HTMLElement;return t instanceof o||t instanceof HTMLElement}function Zo(t){if(typeof ShadowRoot>"u")return!1;var o=Ve(t).ShadowRoot;return t instanceof o||t instanceof ShadowRoot}function dp(t){var o=t.state;Object.keys(o.elements).forEach(function(n){var a=o.styles[n]||{},r=o.attributes[n]||{},i=o.elements[n];!Pe(i)||!Ue(i)||(Object.assign(i.style,a),Object.keys(r).forEach(function(c){var d=r[c];d===!1?i.removeAttribute(c):i.setAttribute(c,d===!0?"":d)}))})}function pp(t){var o=t.state,n={popper:{position:o.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(o.elements.popper.style,n.popper),o.styles=n,o.elements.arrow&&Object.assign(o.elements.arrow.style,n.arrow),function(){Object.keys(o.elements).forEach(function(a){var r=o.elements[a],i=o.attributes[a]||{},c=Object.keys(o.styles.hasOwnProperty(a)?o.styles[a]:n[a]),d=c.reduce(function(l,s){return l[s]="",l},{});!Pe(r)||!Ue(r)||(Object.assign(r.style,d),Object.keys(i).forEach(function(l){r.removeAttribute(l)}))})}}const up={name:"applyStyles",enabled:!0,phase:"write",fn:dp,effect:pp,requires:["computeStyles"]};function Ge(t){return t.split("-")[0]}var it=Math.max,eo=Math.min,Ct=Math.round;function en(){var t=navigator.userAgentData;return t!=null&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(o){return o.brand+"/"+o.version}).join(" "):navigator.userAgent}function Aa(){return!/^((?!chrome|android).)*safari/i.test(en())}function wt(t,o,n){o===void 0&&(o=!1),n===void 0&&(n=!1);var a=t.getBoundingClientRect(),r=1,i=1;o&&Pe(t)&&(r=t.offsetWidth>0&&Ct(a.width)/t.offsetWidth||1,i=t.offsetHeight>0&&Ct(a.height)/t.offsetHeight||1);var c=lt(t)?Ve(t):window,d=c.visualViewport,l=!Aa()&&n,s=(a.left+(l&&d?d.offsetLeft:0))/r,p=(a.top+(l&&d?d.offsetTop:0))/i,u=a.width/r,m=a.height/i;return{width:u,height:m,top:p,right:s+u,bottom:p+m,left:s,x:s,y:p}}function tn(t){var o=wt(t),n=t.offsetWidth,a=t.offsetHeight;return Math.abs(o.width-n)<=1&&(n=o.width),Math.abs(o.height-a)<=1&&(a=o.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:a}}function Ta(t,o){var n=o.getRootNode&&o.getRootNode();if(t.contains(o))return!0;if(n&&Zo(n)){var a=o;do{if(a&&t.isSameNode(a))return!0;a=a.parentNode||a.host}while(a)}return!1}function qe(t){return Ve(t).getComputedStyle(t)}function fp(t){return["table","td","th"].indexOf(Ue(t))>=0}function ot(t){return((lt(t)?t.ownerDocument:t.document)||window.document).documentElement}function to(t){return Ue(t)==="html"?t:t.assignedSlot||t.parentNode||(Zo(t)?t.host:null)||ot(t)}function Ea(t){return!Pe(t)||qe(t).position==="fixed"?null:t.offsetParent}function mp(t){var o=/firefox/i.test(en()),n=/Trident/i.test(en());if(n&&Pe(t)){var a=qe(t);if(a.position==="fixed")return null}var r=to(t);for(Zo(r)&&(r=r.host);Pe(r)&&["html","body"].indexOf(Ue(r))<0;){var i=qe(r);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||o&&i.willChange==="filter"||o&&i.filter&&i.filter!=="none")return r;r=r.parentNode}return null}function It(t){for(var o=Ve(t),n=Ea(t);n&&fp(n)&&qe(n).position==="static";)n=Ea(n);return n&&(Ue(n)==="html"||Ue(n)==="body"&&qe(n).position==="static")?o:n||mp(t)||o}function on(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function Ft(t,o,n){return it(t,eo(o,n))}function hp(t,o,n){var a=Ft(t,o,n);return a>n?n:a}function Va(){return{top:0,right:0,bottom:0,left:0}}function La(t){return Object.assign({},Va(),t)}function Ba(t,o){return o.reduce(function(n,a){return n[a]=t,n},{})}var yp=function(o,n){return o=typeof o=="function"?o(Object.assign({},n.rects,{placement:n.placement})):o,La(typeof o!="number"?o:Ba(o,Bt))};function gp(t){var o,n=t.state,a=t.name,r=t.options,i=n.elements.arrow,c=n.modifiersData.popperOffsets,d=Ge(n.placement),l=on(d),s=[Ae,$e].indexOf(d)>=0,p=s?"height":"width";if(!(!i||!c)){var u=yp(r.padding,n),m=tn(i),b=l==="y"?Ne:Ae,h=l==="y"?Fe:$e,f=n.rects.reference[p]+n.rects.reference[l]-c[l]-n.rects.popper[p],g=c[l]-n.rects.reference[l],w=It(i),C=w?l==="y"?w.clientHeight||0:w.clientWidth||0:0,x=f/2-g/2,A=u[b],y=C-m[p]-u[h],_=C/2-m[p]/2+x,E=Ft(A,_,y),T=l;n.modifiersData[a]=(o={},o[T]=E,o.centerOffset=E-_,o)}}function bp(t){var o=t.state,n=t.options,a=n.element,r=a===void 0?"[data-popper-arrow]":a;r!=null&&(typeof r=="string"&&(r=o.elements.popper.querySelector(r),!r)||Ta(o.elements.popper,r)&&(o.elements.arrow=r))}const Cp={name:"arrow",enabled:!0,phase:"main",fn:gp,effect:bp,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function kt(t){return t.split("-")[1]}var wp={top:"auto",right:"auto",bottom:"auto",left:"auto"};function kp(t,o){var n=t.x,a=t.y,r=o.devicePixelRatio||1;return{x:Ct(n*r)/r||0,y:Ct(a*r)/r||0}}function Oa(t){var o,n=t.popper,a=t.popperRect,r=t.placement,i=t.variation,c=t.offsets,d=t.position,l=t.gpuAcceleration,s=t.adaptive,p=t.roundOffsets,u=t.isFixed,m=c.x,b=m===void 0?0:m,h=c.y,f=h===void 0?0:h,g=typeof p=="function"?p({x:b,y:f}):{x:b,y:f};b=g.x,f=g.y;var w=c.hasOwnProperty("x"),C=c.hasOwnProperty("y"),x=Ae,A=Ne,y=window;if(s){var _=It(n),E="clientHeight",T="clientWidth";if(_===Ve(n)&&(_=ot(n),qe(_).position!=="static"&&d==="absolute"&&(E="scrollHeight",T="scrollWidth")),_=_,r===Ne||(r===Ae||r===$e)&&i===Ot){A=Fe;var V=u&&_===y&&y.visualViewport?y.visualViewport.height:_[E];f-=V-a.height,f*=l?1:-1}if(r===Ae||(r===Ne||r===Fe)&&i===Ot){x=$e;var N=u&&_===y&&y.visualViewport?y.visualViewport.width:_[T];b-=N-a.width,b*=l?1:-1}}var I=Object.assign({position:d},s&&wp),M=p===!0?kp({x:b,y:f},Ve(n)):{x:b,y:f};if(b=M.x,f=M.y,l){var j;return Object.assign({},I,(j={},j[A]=C?"0":"",j[x]=w?"0":"",j.transform=(y.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",j))}return Object.assign({},I,(o={},o[A]=C?f+"px":"",o[x]=w?b+"px":"",o.transform="",o))}function _p(t){var o=t.state,n=t.options,a=n.gpuAcceleration,r=a===void 0?!0:a,i=n.adaptive,c=i===void 0?!0:i,d=n.roundOffsets,l=d===void 0?!0:d,s={placement:Ge(o.placement),variation:kt(o.placement),popper:o.elements.popper,popperRect:o.rects.popper,gpuAcceleration:r,isFixed:o.options.strategy==="fixed"};o.modifiersData.popperOffsets!=null&&(o.styles.popper=Object.assign({},o.styles.popper,Oa(Object.assign({},s,{offsets:o.modifiersData.popperOffsets,position:o.options.strategy,adaptive:c,roundOffsets:l})))),o.modifiersData.arrow!=null&&(o.styles.arrow=Object.assign({},o.styles.arrow,Oa(Object.assign({},s,{offsets:o.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-placement":o.placement})}const Sp={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:_p,data:{}};var oo={passive:!0};function xp(t){var o=t.state,n=t.instance,a=t.options,r=a.scroll,i=r===void 0?!0:r,c=a.resize,d=c===void 0?!0:c,l=Ve(o.elements.popper),s=[].concat(o.scrollParents.reference,o.scrollParents.popper);return i&&s.forEach(function(p){p.addEventListener("scroll",n.update,oo)}),d&&l.addEventListener("resize",n.update,oo),function(){i&&s.forEach(function(p){p.removeEventListener("scroll",n.update,oo)}),d&&l.removeEventListener("resize",n.update,oo)}}const Np={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:xp,data:{}};var Ap={left:"right",right:"left",bottom:"top",top:"bottom"};function no(t){return t.replace(/left|right|bottom|top/g,function(o){return Ap[o]})}var Tp={start:"end",end:"start"};function Da(t){return t.replace(/start|end/g,function(o){return Tp[o]})}function nn(t){var o=Ve(t),n=o.pageXOffset,a=o.pageYOffset;return{scrollLeft:n,scrollTop:a}}function an(t){return wt(ot(t)).left+nn(t).scrollLeft}function Ep(t,o){var n=Ve(t),a=ot(t),r=n.visualViewport,i=a.clientWidth,c=a.clientHeight,d=0,l=0;if(r){i=r.width,c=r.height;var s=Aa();(s||!s&&o==="fixed")&&(d=r.offsetLeft,l=r.offsetTop)}return{width:i,height:c,x:d+an(t),y:l}}function Vp(t){var o,n=ot(t),a=nn(t),r=(o=t.ownerDocument)==null?void 0:o.body,i=it(n.scrollWidth,n.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),c=it(n.scrollHeight,n.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),d=-a.scrollLeft+an(t),l=-a.scrollTop;return qe(r||n).direction==="rtl"&&(d+=it(n.clientWidth,r?r.clientWidth:0)-i),{width:i,height:c,x:d,y:l}}function rn(t){var o=qe(t),n=o.overflow,a=o.overflowX,r=o.overflowY;return/auto|scroll|overlay|hidden/.test(n+r+a)}function Ia(t){return["html","body","#document"].indexOf(Ue(t))>=0?t.ownerDocument.body:Pe(t)&&rn(t)?t:Ia(to(t))}function $t(t,o){var n;o===void 0&&(o=[]);var a=Ia(t),r=a===((n=t.ownerDocument)==null?void 0:n.body),i=Ve(a),c=r?[i].concat(i.visualViewport||[],rn(a)?a:[]):a,d=o.concat(c);return r?d:d.concat($t(to(c)))}function ln(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Lp(t,o){var n=wt(t,!1,o==="fixed");return n.top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(t,o,n){return o===Sa?ln(Ep(t,n)):lt(o)?Lp(o,n):ln(Vp(ot(t)))}function Bp(t){var o=$t(to(t)),n=["absolute","fixed"].indexOf(qe(t).position)>=0,a=n&&Pe(t)?It(t):t;return lt(a)?o.filter(function(r){return lt(r)&&Ta(r,a)&&Ue(r)!=="body"}):[]}function Op(t,o,n,a){var r=o==="clippingParents"?Bp(t):[].concat(o),i=[].concat(r,[n]),c=i[0],d=i.reduce(function(l,s){var p=Fa(t,s,a);return l.top=it(p.top,l.top),l.right=eo(p.right,l.right),l.bottom=eo(p.bottom,l.bottom),l.left=it(p.left,l.left),l},Fa(t,c,a));return d.width=d.right-d.left,d.height=d.bottom-d.top,d.x=d.left,d.y=d.top,d}function $a(t){var o=t.reference,n=t.element,a=t.placement,r=a?Ge(a):null,i=a?kt(a):null,c=o.x+o.width/2-n.width/2,d=o.y+o.height/2-n.height/2,l;switch(r){case Ne:l={x:c,y:o.y-n.height};break;case Fe:l={x:c,y:o.y+o.height};break;case $e:l={x:o.x+o.width,y:d};break;case Ae:l={x:o.x-n.width,y:d};break;default:l={x:o.x,y:o.y}}var s=r?on(r):null;if(s!=null){var p=s==="y"?"height":"width";switch(i){case bt:l[s]=l[s]-(o[p]/2-n[p]/2);break;case Ot:l[s]=l[s]+(o[p]/2-n[p]/2);break}}return l}function Pt(t,o){o===void 0&&(o={});var n=o,a=n.placement,r=a===void 0?t.placement:a,i=n.strategy,c=i===void 0?t.strategy:i,d=n.boundary,l=d===void 0?Jd:d,s=n.rootBoundary,p=s===void 0?Sa:s,u=n.elementContext,m=u===void 0?Dt:u,b=n.altBoundary,h=b===void 0?!1:b,f=n.padding,g=f===void 0?0:f,w=La(typeof g!="number"?g:Ba(g,Bt)),C=m===Dt?Zd:Dt,x=t.rects.popper,A=t.elements[h?C:m],y=Op(lt(A)?A:A.contextElement||ot(t.elements.popper),l,p,c),_=wt(t.elements.reference),E=$a({reference:_,element:x,strategy:"absolute",placement:r}),T=ln(Object.assign({},x,E)),V=m===Dt?T:_,N={top:y.top-V.top+w.top,bottom:V.bottom-y.bottom+w.bottom,left:y.left-V.left+w.left,right:V.right-y.right+w.right},I=t.modifiersData.offset;if(m===Dt&&I){var M=I[r];Object.keys(N).forEach(function(j){var B=[$e,Fe].indexOf(j)>=0?1:-1,F=[Ne,Fe].indexOf(j)>=0?"y":"x";N[j]+=M[F]*B})}return N}function Dp(t,o){o===void 0&&(o={});var n=o,a=n.placement,r=n.boundary,i=n.rootBoundary,c=n.padding,d=n.flipVariations,l=n.allowedAutoPlacements,s=l===void 0?Na:l,p=kt(a),u=p?d?xa:xa.filter(function(h){return kt(h)===p}):Bt,m=u.filter(function(h){return s.indexOf(h)>=0});m.length===0&&(m=u);var b=m.reduce(function(h,f){return h[f]=Pt(t,{placement:f,boundary:r,rootBoundary:i,padding:c})[Ge(f)],h},{});return Object.keys(b).sort(function(h,f){return b[h]-b[f]})}function Ip(t){if(Ge(t)===Jo)return[];var o=no(t);return[Da(t),o,Da(o)]}function Fp(t){var o=t.state,n=t.options,a=t.name;if(!o.modifiersData[a]._skip){for(var r=n.mainAxis,i=r===void 0?!0:r,c=n.altAxis,d=c===void 0?!0:c,l=n.fallbackPlacements,s=n.padding,p=n.boundary,u=n.rootBoundary,m=n.altBoundary,b=n.flipVariations,h=b===void 0?!0:b,f=n.allowedAutoPlacements,g=o.options.placement,w=Ge(g),C=w===g,x=l||(C||!h?[no(g)]:Ip(g)),A=[g].concat(x).reduce(function(z,W){return z.concat(Ge(W)===Jo?Dp(o,{placement:W,boundary:p,rootBoundary:u,padding:s,flipVariations:h,allowedAutoPlacements:f}):W)},[]),y=o.rects.reference,_=o.rects.popper,E=new Map,T=!0,V=A[0],N=0;N<A.length;N++){var I=A[N],M=Ge(I),j=kt(I)===bt,B=[Ne,Fe].indexOf(M)>=0,F=B?"width":"height",O=Pt(o,{placement:I,boundary:p,rootBoundary:u,altBoundary:m,padding:s}),G=B?j?$e:Ae:j?Fe:Ne;y[F]>_[F]&&(G=no(G));var R=no(G),S=[];if(i&&S.push(O[M]<=0),d&&S.push(O[G]<=0,O[R]<=0),S.every(function(z){return z})){V=I,T=!1;break}E.set(I,S)}if(T)for(var L=h?3:1,k=function(W){var Q=A.find(function(Z){var oe=E.get(Z);if(oe)return oe.slice(0,W).every(function(ie){return ie})});if(Q)return V=Q,"break"},D=L;D>0;D--){var $=k(D);if($==="break")break}o.placement!==V&&(o.modifiersData[a]._skip=!0,o.placement=V,o.reset=!0)}}const $p={name:"flip",enabled:!0,phase:"main",fn:Fp,requiresIfExists:["offset"],data:{_skip:!1}};function Pa(t,o,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-o.height-n.y,right:t.right-o.width+n.x,bottom:t.bottom-o.height+n.y,left:t.left-o.width-n.x}}function Ma(t){return[Ne,$e,Fe,Ae].some(function(o){return t[o]>=0})}function Pp(t){var o=t.state,n=t.name,a=o.rects.reference,r=o.rects.popper,i=o.modifiersData.preventOverflow,c=Pt(o,{elementContext:"reference"}),d=Pt(o,{altBoundary:!0}),l=Pa(c,a),s=Pa(d,r,i),p=Ma(l),u=Ma(s);o.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:s,isReferenceHidden:p,hasPopperEscaped:u},o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-reference-hidden":p,"data-popper-escaped":u})}const Mp={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Pp};function jp(t,o,n){var a=Ge(t),r=[Ae,Ne].indexOf(a)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},o,{placement:t})):n,c=i[0],d=i[1];return c=c||0,d=(d||0)*r,[Ae,$e].indexOf(a)>=0?{x:d,y:c}:{x:c,y:d}}function vp(t){var o=t.state,n=t.options,a=t.name,r=n.offset,i=r===void 0?[0,0]:r,c=Na.reduce(function(p,u){return p[u]=jp(u,o.rects,i),p},{}),d=c[o.placement],l=d.x,s=d.y;o.modifiersData.popperOffsets!=null&&(o.modifiersData.popperOffsets.x+=l,o.modifiersData.popperOffsets.y+=s),o.modifiersData[a]=c}const Rp={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vp};function Up(t){var o=t.state,n=t.name;o.modifiersData[n]=$a({reference:o.rects.reference,element:o.rects.popper,strategy:"absolute",placement:o.placement})}const Gp={name:"popperOffsets",enabled:!0,phase:"read",fn:Up,data:{}};function zp(t){return t==="x"?"y":"x"}function Hp(t){var o=t.state,n=t.options,a=t.name,r=n.mainAxis,i=r===void 0?!0:r,c=n.altAxis,d=c===void 0?!1:c,l=n.boundary,s=n.rootBoundary,p=n.altBoundary,u=n.padding,m=n.tether,b=m===void 0?!0:m,h=n.tetherOffset,f=h===void 0?0:h,g=Pt(o,{boundary:l,rootBoundary:s,padding:u,altBoundary:p}),w=Ge(o.placement),C=kt(o.placement),x=!C,A=on(w),y=zp(A),_=o.modifiersData.popperOffsets,E=o.rects.reference,T=o.rects.popper,V=typeof f=="function"?f(Object.assign({},o.rects,{placement:o.placement})):f,N=typeof V=="number"?{mainAxis:V,altAxis:V}:Object.assign({mainAxis:0,altAxis:0},V),I=o.modifiersData.offset?o.modifiersData.offset[o.placement]:null,M={x:0,y:0};if(_){if(i){var j,B=A==="y"?Ne:Ae,F=A==="y"?Fe:$e,O=A==="y"?"height":"width",G=_[A],R=G+g[B],S=G-g[F],L=b?-T[O]/2:0,k=C===bt?E[O]:T[O],D=C===bt?-T[O]:-E[O],$=o.elements.arrow,z=b&&$?tn($):{width:0,height:0},W=o.modifiersData["arrow#persistent"]?o.modifiersData["arrow#persistent"].padding:Va(),Q=W[B],Z=W[F],oe=Ft(0,E[O],z[O]),ie=x?E[O]/2-L-oe-Q-N.mainAxis:k-oe-Q-N.mainAxis,se=x?-E[O]/2+L+oe+Z+N.mainAxis:D+oe+Z+N.mainAxis,je=o.elements.arrow&&It(o.elements.arrow),ct=je?A==="y"?je.clientTop||0:je.clientLeft||0:0,He=(j=I==null?void 0:I[A])!=null?j:0,pe=G+ie-He-ct,Te=G+se-He,nt=Ft(b?eo(R,pe):R,G,b?it(S,Te):S);_[A]=nt,M[A]=nt-G}if(d){var Ut,Nt=A==="x"?Ne:Ae,dt=A==="x"?Fe:$e,Le=_[y],Qe=y==="y"?"height":"width",Xe=Le+g[Nt],Je=Le-g[dt],Be=[Ne,Ae].indexOf(w)!==-1,pt=(Ut=I==null?void 0:I[y])!=null?Ut:0,Ze=Be?Xe:Le-E[Qe]-T[Qe]-pt+N.altAxis,at=Be?Le+E[Qe]+T[Qe]-pt-N.altAxis:Je,ut=b&&Be?hp(Ze,Le,at):Ft(b?Ze:Xe,Le,b?at:Je);_[y]=ut,M[y]=ut-Le}o.modifiersData[a]=M}}const Yp={name:"preventOverflow",enabled:!0,phase:"main",fn:Hp,requiresIfExists:["offset"]};function Wp(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function qp(t){return t===Ve(t)||!Pe(t)?nn(t):Wp(t)}function Kp(t){var o=t.getBoundingClientRect(),n=Ct(o.width)/t.offsetWidth||1,a=Ct(o.height)/t.offsetHeight||1;return n!==1||a!==1}function Qp(t,o,n){n===void 0&&(n=!1);var a=Pe(o),r=Pe(o)&&Kp(o),i=ot(o),c=wt(t,r,n),d={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(a||!a&&!n)&&((Ue(o)!=="body"||rn(i))&&(d=qp(o)),Pe(o)?(l=wt(o,!0),l.x+=o.clientLeft,l.y+=o.clientTop):i&&(l.x=an(i))),{x:c.left+d.scrollLeft-l.x,y:c.top+d.scrollTop-l.y,width:c.width,height:c.height}}function Xp(t){var o=new Map,n=new Set,a=[];t.forEach(function(i){o.set(i.name,i)});function r(i){n.add(i.name);var c=[].concat(i.requires||[],i.requiresIfExists||[]);c.forEach(function(d){if(!n.has(d)){var l=o.get(d);l&&r(l)}}),a.push(i)}return t.forEach(function(i){n.has(i.name)||r(i)}),a}function Jp(t){var o=Xp(t);return cp.reduce(function(n,a){return n.concat(o.filter(function(r){return r.phase===a}))},[])}function Zp(t){var o;return function(){return o||(o=new Promise(function(n){Promise.resolve().then(function(){o=void 0,n(t())})})),o}}function eu(t){var o=t.reduce(function(n,a){var r=n[a.name];return n[a.name]=r?Object.assign({},r,a,{options:Object.assign({},r.options,a.options),data:Object.assign({},r.data,a.data)}):a,n},{});return Object.keys(o).map(function(n){return o[n]})}var ja={placement:"bottom",modifiers:[],strategy:"absolute"};function va(){for(var t=arguments.length,o=new Array(t),n=0;n<t;n++)o[n]=arguments[n];return!o.some(function(a){return!(a&&typeof a.getBoundingClientRect=="function")})}function tu(t){t===void 0&&(t={});var o=t,n=o.defaultModifiers,a=n===void 0?[]:n,r=o.defaultOptions,i=r===void 0?ja:r;return function(d,l,s){s===void 0&&(s=i);var p={placement:"bottom",orderedModifiers:[],options:Object.assign({},ja,i),modifiersData:{},elements:{reference:d,popper:l},attributes:{},styles:{}},u=[],m=!1,b={state:p,setOptions:function(w){var C=typeof w=="function"?w(p.options):w;f(),p.options=Object.assign({},i,p.options,C),p.scrollParents={reference:lt(d)?$t(d):d.contextElement?$t(d.contextElement):[],popper:$t(l)};var x=Jp(eu([].concat(a,p.options.modifiers)));return p.orderedModifiers=x.filter(function(A){return A.enabled}),h(),b.update()},forceUpdate:function(){if(!m){var w=p.elements,C=w.reference,x=w.popper;if(va(C,x)){p.rects={reference:Qp(C,It(x),p.options.strategy==="fixed"),popper:tn(x)},p.reset=!1,p.placement=p.options.placement,p.orderedModifiers.forEach(function(N){return p.modifiersData[N.name]=Object.assign({},N.data)});for(var A=0;A<p.orderedModifiers.length;A++){if(p.reset===!0){p.reset=!1,A=-1;continue}var y=p.orderedModifiers[A],_=y.fn,E=y.options,T=E===void 0?{}:E,V=y.name;typeof _=="function"&&(p=_({state:p,options:T,name:V,instance:b})||p)}}}},update:Zp(function(){return new Promise(function(g){b.forceUpdate(),g(p)})}),destroy:function(){f(),m=!0}};if(!va(d,l))return b;b.setOptions(s).then(function(g){!m&&s.onFirstUpdate&&s.onFirstUpdate(g)});function h(){p.orderedModifiers.forEach(function(g){var w=g.name,C=g.options,x=C===void 0?{}:C,A=g.effect;if(typeof A=="function"){var y=A({state:p,name:w,instance:b,options:x}),_=function(){};u.push(y||_)}})}function f(){u.forEach(function(g){return g()}),u=[]}return b}}var ou=[Np,Gp,Sp,up,Rp,$p,Yp,Cp,Mp],nu=tu({defaultModifiers:ou});function sn(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function Ra(t,o){if(t){if(typeof t=="string")return sn(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?sn(t,o):void 0}}function au(t){return function(o){if(Array.isArray(o))return sn(o)}(t)||function(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}(t)||Ra(t)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
62
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function _t(t){return _t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},_t(t)}function Ua(t,o,n,a,r,i,c){try{var d=t[i](c),l=d.value}catch(s){return void n(s)}d.done?o(l):Promise.resolve(l).then(a,r)}function Ga(t){return function(){var o=this,n=arguments;return new Promise(function(a,r){var i=t.apply(o,n);function c(l){Ua(i,a,r,c,d,"next",l)}function d(l){Ua(i,a,r,c,d,"throw",l)}c(void 0)})}}var za={exports:{}},Ha={exports:{}};(function(t){function o(n){return t.exports=o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},t.exports.__esModule=!0,t.exports.default=t.exports,o(n)}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports})(Ha),function(t){var o=Ha.exports.default;function n(){t.exports=n=function(){return r},t.exports.__esModule=!0,t.exports.default=t.exports;var a,r={},i=Object.prototype,c=i.hasOwnProperty,d=Object.defineProperty||function(S,L,k){S[L]=k.value},l=typeof Symbol=="function"?Symbol:{},s=l.iterator||"@@iterator",p=l.asyncIterator||"@@asyncIterator",u=l.toStringTag||"@@toStringTag";function m(S,L,k){return Object.defineProperty(S,L,{value:k,enumerable:!0,configurable:!0,writable:!0}),S[L]}try{m({},"")}catch{m=function(L,k,D){return L[k]=D}}function b(S,L,k,D){var $=L&&L.prototype instanceof A?L:A,z=Object.create($.prototype),W=new G(D||[]);return d(z,"_invoke",{value:j(S,k,W)}),z}function h(S,L,k){try{return{type:"normal",arg:S.call(L,k)}}catch(D){return{type:"throw",arg:D}}}r.wrap=b;var f="suspendedStart",g="suspendedYield",w="executing",C="completed",x={};function A(){}function y(){}function _(){}var E={};m(E,s,function(){return this});var T=Object.getPrototypeOf,V=T&&T(T(R([])));V&&V!==i&&c.call(V,s)&&(E=V);var N=_.prototype=A.prototype=Object.create(E);function I(S){["next","throw","return"].forEach(function(L){m(S,L,function(k){return this._invoke(L,k)})})}function M(S,L){function k($,z,W,Q){var Z=h(S[$],S,z);if(Z.type!=="throw"){var oe=Z.arg,ie=oe.value;return ie&&o(ie)=="object"&&c.call(ie,"__await")?L.resolve(ie.__await).then(function(se){k("next",se,W,Q)},function(se){k("throw",se,W,Q)}):L.resolve(ie).then(function(se){oe.value=se,W(oe)},function(se){return k("throw",se,W,Q)})}Q(Z.arg)}var D;d(this,"_invoke",{value:function($,z){function W(){return new L(function(Q,Z){k($,z,Q,Z)})}return D=D?D.then(W,W):W()}})}function j(S,L,k){var D=f;return function($,z){if(D===w)throw new Error("Generator is already running");if(D===C){if($==="throw")throw z;return{value:a,done:!0}}for(k.method=$,k.arg=z;;){var W=k.delegate;if(W){var Q=B(W,k);if(Q){if(Q===x)continue;return Q}}if(k.method==="next")k.sent=k._sent=k.arg;else if(k.method==="throw"){if(D===f)throw D=C,k.arg;k.dispatchException(k.arg)}else k.method==="return"&&k.abrupt("return",k.arg);D=w;var Z=h(S,L,k);if(Z.type==="normal"){if(D=k.done?C:g,Z.arg===x)continue;return{value:Z.arg,done:k.done}}Z.type==="throw"&&(D=C,k.method="throw",k.arg=Z.arg)}}}function B(S,L){var k=L.method,D=S.iterator[k];if(D===a)return L.delegate=null,k==="throw"&&S.iterator.return&&(L.method="return",L.arg=a,B(S,L),L.method==="throw")||k!=="return"&&(L.method="throw",L.arg=new TypeError("The iterator does not provide a '"+k+"' method")),x;var $=h(D,S.iterator,L.arg);if($.type==="throw")return L.method="throw",L.arg=$.arg,L.delegate=null,x;var z=$.arg;return z?z.done?(L[S.resultName]=z.value,L.next=S.nextLoc,L.method!=="return"&&(L.method="next",L.arg=a),L.delegate=null,x):z:(L.method="throw",L.arg=new TypeError("iterator result is not an object"),L.delegate=null,x)}function F(S){var L={tryLoc:S[0]};1 in S&&(L.catchLoc=S[1]),2 in S&&(L.finallyLoc=S[2],L.afterLoc=S[3]),this.tryEntries.push(L)}function O(S){var L=S.completion||{};L.type="normal",delete L.arg,S.completion=L}function G(S){this.tryEntries=[{tryLoc:"root"}],S.forEach(F,this),this.reset(!0)}function R(S){if(S||S===""){var L=S[s];if(L)return L.call(S);if(typeof S.next=="function")return S;if(!isNaN(S.length)){var k=-1,D=function $(){for(;++k<S.length;)if(c.call(S,k))return $.value=S[k],$.done=!1,$;return $.value=a,$.done=!0,$};return D.next=D}}throw new TypeError(o(S)+" is not iterable")}return y.prototype=_,d(N,"constructor",{value:_,configurable:!0}),d(_,"constructor",{value:y,configurable:!0}),y.displayName=m(_,u,"GeneratorFunction"),r.isGeneratorFunction=function(S){var L=typeof S=="function"&&S.constructor;return!!L&&(L===y||(L.displayName||L.name)==="GeneratorFunction")},r.mark=function(S){return Object.setPrototypeOf?Object.setPrototypeOf(S,_):(S.__proto__=_,m(S,u,"GeneratorFunction")),S.prototype=Object.create(N),S},r.awrap=function(S){return{__await:S}},I(M.prototype),m(M.prototype,p,function(){return this}),r.AsyncIterator=M,r.async=function(S,L,k,D,$){$===void 0&&($=Promise);var z=new M(b(S,L,k,D),$);return r.isGeneratorFunction(L)?z:z.next().then(function(W){return W.done?W.value:z.next()})},I(N),m(N,u,"Generator"),m(N,s,function(){return this}),m(N,"toString",function(){return"[object Generator]"}),r.keys=function(S){var L=Object(S),k=[];for(var D in L)k.push(D);return k.reverse(),function $(){for(;k.length;){var z=k.pop();if(z in L)return $.value=z,$.done=!1,$}return $.done=!0,$}},r.values=R,G.prototype={constructor:G,reset:function(S){if(this.prev=0,this.next=0,this.sent=this._sent=a,this.done=!1,this.delegate=null,this.method="next",this.arg=a,this.tryEntries.forEach(O),!S)for(var L in this)L.charAt(0)==="t"&&c.call(this,L)&&!isNaN(+L.slice(1))&&(this[L]=a)},stop:function(){this.done=!0;var S=this.tryEntries[0].completion;if(S.type==="throw")throw S.arg;return this.rval},dispatchException:function(S){if(this.done)throw S;var L=this;function k(Z,oe){return z.type="throw",z.arg=S,L.next=Z,oe&&(L.method="next",L.arg=a),!!oe}for(var D=this.tryEntries.length-1;D>=0;--D){var $=this.tryEntries[D],z=$.completion;if($.tryLoc==="root")return k("end");if($.tryLoc<=this.prev){var W=c.call($,"catchLoc"),Q=c.call($,"finallyLoc");if(W&&Q){if(this.prev<$.catchLoc)return k($.catchLoc,!0);if(this.prev<$.finallyLoc)return k($.finallyLoc)}else if(W){if(this.prev<$.catchLoc)return k($.catchLoc,!0)}else{if(!Q)throw new Error("try statement without catch or finally");if(this.prev<$.finallyLoc)return k($.finallyLoc)}}}},abrupt:function(S,L){for(var k=this.tryEntries.length-1;k>=0;--k){var D=this.tryEntries[k];if(D.tryLoc<=this.prev&&c.call(D,"finallyLoc")&&this.prev<D.finallyLoc){var $=D;break}}$&&(S==="break"||S==="continue")&&$.tryLoc<=L&&L<=$.finallyLoc&&($=null);var z=$?$.completion:{};return z.type=S,z.arg=L,$?(this.method="next",this.next=$.finallyLoc,x):this.complete(z)},complete:function(S,L){if(S.type==="throw")throw S.arg;return S.type==="break"||S.type==="continue"?this.next=S.arg:S.type==="return"?(this.rval=this.arg=S.arg,this.method="return",this.next="end"):S.type==="normal"&&L&&(this.next=L),x},finish:function(S){for(var L=this.tryEntries.length-1;L>=0;--L){var k=this.tryEntries[L];if(k.finallyLoc===S)return this.complete(k.completion,k.afterLoc),O(k),x}},catch:function(S){for(var L=this.tryEntries.length-1;L>=0;--L){var k=this.tryEntries[L];if(k.tryLoc===S){var D=k.completion;if(D.type==="throw"){var $=D.arg;O(k)}return $}}throw new Error("illegal catch attempt")},delegateYield:function(S,L,k){return this.delegate={iterator:R(S),resultName:L,nextLoc:k},this.method==="next"&&(this.arg=a),x}},r}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}(za);var ao=za.exports(),ro=ao;try{regeneratorRuntime=ao}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=ao:Function("r","regeneratorRuntime = r")(ao)}function ru(t){var o=function(n,a){if(_t(n)!=="object"||n===null)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var i=r.call(n,a||"default");if(_t(i)!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(a==="string"?String:Number)(n)}(t,"string");return _t(o)==="symbol"?o:String(o)}function cn(t,o,n){return(o=ru(o))in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var lo=e.defineComponent({name:"Saturation",props:{size:{type:Number,default:160},hue:{type:Number,default:0},saturation:{type:Number,default:0},value:{type:Number,default:0}},emits:["change"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return{width:"".concat(t.size,"px"),height:"".concat(t.size,"px"),background:"hsl(".concat(t.hue,", 100%, 50%)")}});return{saturationStyle:a,sliderStyle:e.computed(function(){return{top:"".concat((100-t.value)/100*t.size-5,"px"),left:"".concat(t.saturation*t.size/100-5,"px"),width:"".concat(10,"px"),height:"".concat(10,"px")}}),onSelect:function(r){var i=r.target.getBoundingClientRect(),c=i.left,d=i.top,l=function(s){var p=s.clientX,u=s.clientY,m=p-c,b=u-d;m<0&&(m=0),b<0&&(b=0),m>t.size&&(m=t.size),b>t.size&&(b=t.size);var h=m/t.size*100,f=100-b/t.size*100;n("change",h,f)};l(r),document.addEventListener("mousemove",l),document.addEventListener("mouseup",function s(){document.removeEventListener("mousemove",l),document.removeEventListener("mouseup",s)})}}}}),Ya=function(t){return e.pushScopeId("data-v-24517fec"),t=t(),e.popScopeId(),t},lu=Ya(function(){return e.createElementVNode("div",{class:"saturation-white"},null,-1)}),iu=Ya(function(){return e.createElementVNode("div",{class:"saturation-black"},null,-1)});function Ke(t,o){o===void 0&&(o={});var n=o.insertAt;if(t&&typeof document<"u"){var a=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&a.firstChild?a.insertBefore(r,a.firstChild):a.appendChild(r),r.styleSheet?r.styleSheet.cssText=t:r.appendChild(document.createTextNode(t))}}Ke(".saturation[data-v-24517fec]{position:relative}.saturation-black[data-v-24517fec],.saturation-white[data-v-24517fec]{cursor:pointer;height:100%;left:0;position:absolute;top:0;width:100%}.saturation-white[data-v-24517fec]{background:linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.saturation-black[data-v-24517fec]{background:linear-gradient(0deg,#000,transparent)}.slider[data-v-24517fec]{border:1px solid #fff;border-radius:50%;box-shadow:0 0 1px 1px rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;top:0;z-index:1}"),lo.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",{class:"saturation",style:e.normalizeStyle(t.saturationStyle),onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[lu,iu,e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],36)},lo.__scopeId="data-v-24517fec",lo.__file="src/picker/Saturation.vue";var io=e.defineComponent({name:"Hue",props:{width:{type:Number,default:15},height:{type:Number,default:160},hue:{type:Number,default:0}},emits:["change"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return{top:"".concat((1-t.hue/360)*t.height-2,"px"),height:"".concat(4,"px")}}),r=e.ref();return e.onMounted(function(){(function(){r.value.width=t.width,r.value.height=t.height;var i=r.value.getContext("2d"),c=i.createLinearGradient(0,0,0,t.height);c.addColorStop(0,"#FF0000"),c.addColorStop(.17,"#FF00FF"),c.addColorStop(.34,"#0000FF"),c.addColorStop(.51,"#00FFFF"),c.addColorStop(.68,"#00FF00"),c.addColorStop(.17*5,"#FFFF00"),c.addColorStop(1,"#FF0000"),i.fillStyle=c,i.fillRect(0,0,t.width,t.height)})()}),{canvas:r,sliderStyle:a,onSelect:function(i){var c=i.target.getBoundingClientRect().top,d=function(l){var s=l.clientY-c;s<0&&(s=0),s>t.height&&(s=t.height);var p=-100*s/t.height+100;n("change",360*p/100)};d(i),document.addEventListener("mousemove",d),document.addEventListener("mouseup",function l(){document.removeEventListener("mousemove",d),document.removeEventListener("mouseup",l)})}}}}),su={ref:"canvas"};Ke(".hue[data-v-78b9f4f0]{position:relative}.slider[data-v-78b9f4f0]{background:#fff;box-shadow:0 0 1px 0 rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;width:100%;z-index:1}"),io.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",{class:"hue",onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[e.createElementVNode("canvas",su,null,512),e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],32)},io.__scopeId="data-v-78b9f4f0",io.__file="src/picker/Hue.vue";var so=e.defineComponent({name:"Alpha",props:{width:{type:Number,default:15},height:{type:Number,default:160},color:{type:String,default:"#000000"},alpha:{type:Number,default:1}},setup:function(t,o){var n=o.emit,a=e.computed(function(){return{top:"".concat(t.alpha*t.height-2,"px"),height:"".concat(4,"px")}}),r=e.ref(),i=function(){var c=r.value.getContext("2d");r.value.width=t.width,r.value.height=t.height;var d=function(s){var p=document.createElement("canvas"),u=p.getContext("2d"),m=2*s;return p.width=m,p.height=m,u.fillStyle="#ffffff",u.fillRect(0,0,m,m),u.fillStyle="#ccd5db",u.fillRect(0,0,s,s),u.fillRect(s,s,s,s),p}(5);c.fillStyle=c.createPattern(d,"repeat"),c.fillRect(0,0,t.width,t.height);var l=c.createLinearGradient(0,0,0,t.height);l.addColorStop(.01,"rgba(255,255,255,0)"),l.addColorStop(.99,t.color),c.fillStyle=l,c.fillRect(0,0,t.width,t.height)};return e.watch(function(){return t.color},function(){i()}),e.onMounted(function(){i()}),{canvas:r,sliderStyle:a,onSelect:function(c){var d=c.target.getBoundingClientRect().top,l=function(s){var p=s.clientY-d;p<0&&(p=0),p>t.height&&(p=t.height);var u=parseFloat((p/t.height).toFixed(2));n("change",u)};l(c),document.addEventListener("mousemove",l),document.addEventListener("mouseup",function s(){document.removeEventListener("mousemove",l),document.removeEventListener("mouseup",s)})}}}}),cu={ref:"canvas"};Ke(".alpha[data-v-24dc9656]{position:relative}.slider[data-v-24dc9656]{background:#fff;box-shadow:0 0 1px 0 rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;width:100%;z-index:1}"),so.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",{class:"alpha",onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[e.createElementVNode("canvas",cu,null,512),e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],32)},so.__scopeId="data-v-24dc9656",so.__file="src/picker/Alpha.vue";var co=e.defineComponent({name:"Input",props:{label:{type:String,default:"RGBA"},value:{type:String,default:""},width:{type:Number,default:168}},emits:["change","focus","blur","enter"],setup:function(t,o){var n=o.emit;return{onInput:function(a){var r;n("change",(r=a.target)===null||r===void 0?void 0:r.value)},valueStyle:e.computed(function(){return{minWidth:"".concat(t.width,"px"),maxWidth:"".concat(t.width,"px"),width:"".concat(t.width,"px")}}),onFocus:function(){n("focus")},onBlur:function(){n("blur")},onEnter:function(){n("enter")}}}}),du={class:"input"},pu={class:"label"},uu=[".value"];function Mt(t,o){return function(n){if(Array.isArray(n))return n}(t)||function(n,a){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var i,c,d,l,s=[],p=!0,u=!1;try{if(d=(r=r.call(n)).next,a===0){if(Object(r)!==r)return;p=!1}else for(;!(p=(i=d.call(r)).done)&&(s.push(i.value),s.length!==a);p=!0);}catch(m){u=!0,c=m}finally{try{if(!p&&r.return!=null&&(l=r.return(),Object(l)!==l))return}finally{if(u)throw c}}return s}}(t,o)||Ra(t,o)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
63
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Wa(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),n.push.apply(n,a)}return n}function Me(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?Wa(Object(n),!0).forEach(function(a){cn(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Wa(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}Ke(".input[data-v-d52a4d02]{display:inline-block;font-size:12px}.label[data-v-d52a4d02]{align-items:center;background:#e7e8e9;color:#999;display:flex;float:left;font-weight:500;height:30px;justify-content:center;width:45px}[pick-colors-theme=dark] .label[data-v-d52a4d02]{background:#252930;color:#999}.value[data-v-d52a4d02]{background:#eceef0;border:1px solid #eceef0;box-sizing:border-box;color:#666;flex:1;height:30px;text-align:center}[pick-colors-theme=dark] .value[data-v-d52a4d02]{background:#2e333a;border:1px solid #2e333a;color:#fff}.value[data-v-d52a4d02]:focus{border:1px solid #1890ff;outline:none}"),co.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",du,[e.createElementVNode("span",pu,e.toDisplayString(t.label),1),e.createElementVNode("input",{class:"value",style:e.normalizeStyle(t.valueStyle),".value":t.value,onFocus:o[0]||(o[0]=function(){return t.onFocus&&t.onFocus.apply(t,arguments)}),onInput:o[1]||(o[1]=function(){return t.onInput&&t.onInput.apply(t,arguments)}),onBlur:o[2]||(o[2]=function(){return t.onBlur&&t.onBlur.apply(t,arguments)}),onKeydown:o[3]||(o[3]=e.withKeys(function(){return t.onEnter&&t.onEnter.apply(t,arguments)},["enter"]))},null,44,uu)])},co.__scopeId="data-v-d52a4d02",co.__file="src/picker/InputValue.vue";var qa=function(t,o,n){return[t,o*n/((t=(2-o)*n)<1?t:2-t)||0,t/2]},Ka={10:"A",11:"B",12:"C",13:"D",14:"E",15:"F"},po=function(t){t=Math.min(Math.round(t),255);var o=Math.floor(t/16),n=t%16;return"".concat(Ka[o]||o).concat(Ka[n]||n)},Qa=function(t){var o=t.r,n=t.g,a=t.b;return isNaN(o)||isNaN(n)||isNaN(a)?"":"#".concat(po(o)).concat(po(n)).concat(po(a))},St=function(t,o){var n;typeof(n=t)=="string"&&n.indexOf(".")!==-1&&parseFloat(n)===1&&(t="100%");var a=function(r){return typeof r=="string"&&r.indexOf("%")!==-1}(t);return t=Math.min(o,Math.max(0,parseFloat("".concat(t)))),a&&(t=parseInt("".concat(t*o),10)/100),Math.abs(t-o)<1e-6?1:t%o/parseFloat(o)},jt=function(t,o,n){t=6*St(t,360),o=St(o,100),n=St(n,100);var a=Math.floor(t),r=t-a,i=n*(1-o),c=n*(1-r*o),d=n*(1-(1-r)*o),l=a%6,s=[n,c,i,i,d,n][l],p=[d,n,n,c,i,i][l],u=[i,i,d,n,n,c][l];return{r:Math.round(255*s),g:Math.round(255*p),b:Math.round(255*u)}},Xa=function(t,o,n){var a=t.h,r=t.s,i=t.v,c=t.a;if(n)switch(o){case"hsl":var d=qa(a,r/100,i/100);return"hsla(".concat(a.toFixed(0),", ").concat(Math.round(100*d[1]),"%, ").concat(Math.round(100*d[2]),"%, ").concat(c,")");case"hsv":return"hsva(".concat(a.toFixed(0),", ").concat(Math.round(r),"%, ").concat(Math.round(i),"%, ").concat(c,")");case"rgb":var l=jt(a,r,i),s=l.r,p=l.g,u=l.b;return"rgba(".concat(s,", ").concat(p,", ").concat(u,", ").concat(c,")");default:return"".concat(Qa(jt(a,r,i))).concat(po(255*c))}else switch(o){case"hsl":var m=qa(a,r/100,i/100);return"hsl(".concat(a.toFixed(0),", ").concat(Math.round(100*m[1]),"%, ").concat(Math.round(100*m[2]),"%)");case"hsv":return"hsv(".concat(a.toFixed(0),", ").concat(Math.round(r),"%, ").concat(Math.round(i),"%)");case"rgb":var b=jt(a,r,i),h=b.r,f=b.g,g=b.b;return"rgb(".concat(h,", ").concat(f,", ").concat(g,")");default:return Qa(jt(a,r,i))}},uo=function(t){var o=t.r,n=t.g,a=t.b;o=St(o,255),n=St(n,255),a=St(a,255);var r,i=Math.max(o,n,a),c=Math.min(o,n,a),d=i,l=i-c,s=i===0?0:l/i;if(i===c)r=0;else{switch(i){case o:r=(n-a)/l+(n<a?6:0);break;case n:r=(a-o)/l+2;break;case a:r=(o-n)/l+4}r/=6}return{h:360*r,s:100*s,v:100*d}},Ja=function(t){var o=t.h,n=t.s,a=t.l;a/=100;var r=n/=100,i=Math.max(a,.01);return n*=(a*=2)<=1?a:2-a,r*=i<=1?i:2-i,{h:+o,s:100*(a===0?2*r/(i+r):2*n/(a+n)),v:100*((a+n)/2)}},Za=function(t){var o=[];if(t.match(/^#([0-9a-fA-f]{3,4})$/g))for(var n=1;n<t.length;n++)o.push(parseInt("0x"+t[n].repeat(2)));else if(t.match(/^#([0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/g))for(var a=1;a<t.length;a+=2)o.push(parseInt("0x"+t.slice(a,a+2)));return{r:o[0],g:o[1],b:o[2],a:o[3]}},dn=function(t,o,n){if(typeof t=="string"&&t!==""){var a=pn(t,un(t),n),r=nr(a);return Xa(r,o,n)}return""},er=function(t){var o=Mt(t.match(/(\d(\.\d+)?)+/g),4);return{r:o[0],g:o[1],b:o[2],a:o[3]}},tr=function(t){var o=Mt(t.match(/(\d(\.\d+)?)+/g),4),n=o[0],a=o[1],r=o[2],i=o[3];return{h:n,s:parseFloat(a),l:parseFloat(r),a:i}},or=function(t){var o=Mt(t.match(/(\d(\.\d+)?)+/g),4),n=o[0],a=o[1],r=o[2],i=o[3];return{h:parseFloat(n),s:parseFloat(a),v:parseFloat(r),a:parseFloat(i)}},pn=function(t,o){if(!(arguments.length>2&&arguments[2]!==void 0)||arguments[2])switch(o){case"rgb":var n=er(t),a=n.r,r=n.g,i=n.b,c=n.a;return Me(Me({},uo({r:a,g:r,b:i})),{},{a:+c});case"hsv":var d=or(t);return{h:d.h,s:d.s,v:d.v,a:d.a};case"hsl":var l=tr(t),s=l.h,p=l.s,u=l.l,m=l.a;return Me(Me({},Ja({h:s,s:p,l:u})),{},{a:+m});default:var b=Za(t),h=b.r,f=b.g,g=b.b,w=b.a;return Me(Me({},uo({r:h,g:f,b:g})),{},{a:w/255})}else switch(o){case"rgb":return Me(Me({},uo(er(t))),{},{a:1});case"hsv":var C=or(t);return{h:C.h,s:C.s,v:C.v,a:1};case"hsl":return Me(Me({},Ja(tr(t))),{},{a:1});default:return Me(Me({},uo(Za(t))),{},{a:1})}},un=function(t){return t.match(/^#/)?"hex":t.match(/^rgb/)?"rgb":t.match(/^hsl/)?"hsl":t.match(/^hsv/)?"hsv":"hex"},nr=function(t){var o=t.h,n=t.s,a=t.v,r=t.a;return isNaN(o)&&(o=0),isNaN(n)&&(n=0),isNaN(a)&&(a=0),isNaN(r)&&(r=1),{h:o,s:n,v:a,a:r}},vt=e.defineComponent({name:"ColorItem",props:{size:{type:[Number,String],default:20},width:{type:[Number,String]},height:{type:[Number,String]},value:{type:String,default:""},border:{type:Boolean,default:!0},borderRadius:{type:Number,default:5},selected:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1}},emits:["select"],setup:function(t){var o=e.ref(),n=e.inject("theme",{theme:"light"}).theme,a=e.computed(function(){return parseFloat((t.width||t.size)+"")}),r=e.computed(function(){return parseFloat((t.height||t.size)+"")}),i=e.computed(function(){return{width:"".concat(e.unref(a),"px"),height:"".concat(e.unref(r),"px"),border:t.border?"1px solid ".concat(e.unref(n)==="dark"?"#434345":"#d9d9d9"):"",borderRadius:"".concat(t.borderRadius,"px"),boxShadow:t.selected?"0 0 3px 2px ".concat(e.unref(n)==="dark"?"#2681ff":"#1890ff"):""}}),c=function(){var d=o.value.getContext("2d");o.value.width=e.unref(a),o.value.height=e.unref(r);var l=function(s){var p=document.createElement("canvas"),u=p.getContext("2d"),m=2*s;return p.width=m,p.height=m,u.fillStyle="#ffffff",u.fillRect(0,0,m,m),u.fillStyle="#ccd5db",u.fillRect(0,0,s,s),u.fillRect(s,s,s,s),p}(5);d.fillStyle=d.createPattern(l,"repeat"),d.fillRect(0,0,e.unref(a),e.unref(r)),d.fillStyle=t.value,d.fillRect(0,0,e.unref(a),e.unref(r))};return e.watch(function(){return t.value},function(){c()}),e.onMounted(function(){c()}),{canvas:o,colorItemStyle:i}}}),fu=["draggable"];Ke(".color-item[data-v-02da71fd]{display:inline-block;vertical-align:top}"),vt.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("canvas",{class:"color-item",style:e.normalizeStyle(t.colorItemStyle),ref:"canvas",draggable:t.draggable},null,12,fu)},vt.__scopeId="data-v-02da71fd",vt.__file="src/color-item/ColorItem.vue";var fo=e.defineComponent({name:"Colors",components:{ColorItem:vt},props:{colors:{type:Array,default:function(){return[]}},selectedIndex:{type:Number,default:-1}},emits:["change"],setup:function(t,o){var n=o.emit;return{onSelectColor:function(a,r){n("change",a,r)},useColors:e.computed(function(){return t.colors.map(function(a){return dn(a,"hex",!0)})})}}}),mu={class:"colors"};function ar(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),n.push.apply(n,a)}return n}function ze(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?ar(Object(n),!0).forEach(function(a){cn(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ar(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}Ke(".colors[data-v-0f8b52a8]{align-items:center;display:flex;flex-wrap:wrap;margin-top:5px}.color-item[data-v-0f8b52a8]{margin:5px}"),fo.render=function(t,o,n,a,r,i){var c=e.resolveComponent("color-item");return e.openBlock(),e.createElementBlock("div",mu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.useColors,function(d,l){return e.openBlock(),e.createBlock(c,{key:l,class:"color-item",size:16,value:d,border:!1,"border-radius":3,selected:t.selectedIndex===l,onClick:e.withModifiers(function(s){return t.onSelectColor(d,+l)},["stop","prevent"])},null,8,["value","selected","onClick"])}),128))])},fo.__scopeId="data-v-0f8b52a8",fo.__file="src/picker/Colors.vue";var mo=e.defineComponent({name:"Picker",components:{Colors:fo,Saturation:lo,Hue:io,Alpha:so,InputValue:co},props:{format:{type:String,default:"hex"},showAlpha:{type:Boolean,default:!1},value:{type:String,default:""},colors:{type:Array,default:function(){return[]}},style:{type:Object,default:function(){return{}}}},emits:["change","update:value"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return ze(ze({},t.style),{},{width:t.showAlpha?"230px":"205px"})}),r=e.computed(function(){return t.showAlpha?165:140}),i=e.ref(),c=e.ref(),d=e.ref(),l=function(){var C,x=(C=t.value)===null||C===void 0?void 0:C.trim();if(x!=null&&x!==""){var A=un(x);return nr(pn(x,A,t.showAlpha))}return null};e.watch(function(){return t.value},function(){t.value!==e.unref(d)&&(i.value=l())},{immediate:!0}),e.watch(i,function(C,x){var A="";C!=null?(A=Xa(ze({},C),t.format,t.showAlpha),c.value=ze({},C)):c.value=null,d.value=A;var y=l();JSON.stringify(C)!==JSON.stringify(y)&&JSON.stringify(C)!==JSON.stringify(x)&&n("change",A)},{immediate:!0});var s=e.computed(function(){var C;return((C=e.unref(i))===null||C===void 0?void 0:C.h)||0}),p=e.computed(function(){var C;return((C=e.unref(i))===null||C===void 0?void 0:C.s)||0}),u=e.computed(function(){var C;return((C=e.unref(i))===null||C===void 0?void 0:C.v)||0}),m=e.computed(function(){var C,x;return((C=e.unref(i))===null||C===void 0?void 0:C.a)!=null?(x=e.unref(i))===null||x===void 0?void 0:x.a:1}),b=e.computed(function(){return jt(e.unref(s),e.unref(p),e.unref(u))}),h=e.computed(function(){return"rgb(".concat(e.unref(b).r,", ").concat(e.unref(b).g,", ").concat(e.unref(b).b,")")}),f=e.computed(function(){var C=t.format;if(t.showAlpha)switch(C){case"hsv":return"HSVA";case"hsl":return"HSLA";case"rgb":return"RGBA";default:return"HEX"}else switch(C){case"hsv":return"HSV";case"hsl":return"HSL";case"rgb":return"RGB";default:return"HEX"}}),g=e.ref(-1),w=function(C,x,A){if(C.length!==0){var y=pn(C,x,A),_=y.h,E=y.s,T=y.v;if(!(isNaN(_)||isNaN(E)||isNaN(T))){var V=1,N=y.a;isNaN(N)||(V=N),i.value={h:_,s:E,v:T,a:V}}}};return{h:s,s:p,v:u,a:m,rgbStr:h,onSelectSaturation:function(C,x){g.value=-1,e.unref(i)==null?i.value={h:e.unref(s),s:C,v:x,a:e.unref(m)}:i.value=ze(ze({},e.unref(i)),{},{s:C,v:x})},onSelectHue:function(C){g.value=-1,e.unref(i)==null&&(i.value={h:C,s:e.unref(p),v:e.unref(u),a:e.unref(m)}),i.value=ze(ze({},e.unref(i)),{},{h:C})},onSelectAlpha:function(C){g.value=-1,e.unref(i)==null?i.value={h:e.unref(s),s:e.unref(p),v:e.unref(u),a:C}:i.value=ze(ze({},e.unref(i)),{},{a:C})},label:f,colorValue:d,pickerStyle:a,inputWidth:r,onInputChange:function(C){g.value=-1,d.value=C},handleChange:function(){var C,x=(C=e.unref(d))===null||C===void 0?void 0:C.trim();if(x!==""){var A=t.showAlpha,y=t.format,_=function(E,T,V){if(V)switch(T){case"rgb":return/^[rR][gG][Bb][Aa][(]([\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\s]*,){3}[\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*[)]{1}$/.test(E);case"hsv":return/^[hH][Ss][Vv][Aa][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,){2}([\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*)[)]$/.test(E);case"hsl":return/^[hH][Ss][Ll][Aa][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,){2}([\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*)[)]$/.test(E);default:return/^#([0-9a-fA-f]{4}|[0-9a-fA-F]{8})$/g.test(E)}else switch(T){case"rgb":return/^[rR][gG][Bb][(]([\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\s]*,){2}[\s]*(2[0-4]\d|25[0-5]|[01]?\d\d?)[\s]*[)]{1}$/.test(E);case"hsv":return/^[hH][Ss][Vv][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*)[)]$/.test(E);case"hsl":return/^[hH][Ss][Ll][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*)[)]$/.test(E);default:return/^#([0-9a-fA-f]{3}|[0-9a-fA-F]{6})$/g.test(E)}}(x,y,A);_?w(x,y,A):e.unref(c)!=null?i.value=e.unref(c):d.value=""}else i.value=null},selectColorIndex:g,onSelectColor:function(C,x){if(g.value=x,(C=C.trim())==="")i.value=null;else{var A=un(C);A?w(C,A,!0):i.value=null}}}}}),hu={class:"picker-inner"},yu={class:"picker-header"};Ke(".picker[data-v-6ceadec6]{background:#f7f8f9;border-radius:4px;box-shadow:0 0 16px 0 rgba(0,0,0,.16)}.picker-inner[data-v-6ceadec6]{padding:10px}[pick-colors-theme=dark] .picker-inner[data-v-6ceadec6]{background:#1d2024;box-shadow:0 0 16px 0 rgba(0,0,0,.16)}.picker-header[data-v-6ceadec6]{display:flex;margin-bottom:5px}.alpha[data-v-6ceadec6],.hue[data-v-6ceadec6]{margin-left:10px}.colors[data-v-6ceadec6]{margin-top:5px}"),mo.render=function(t,o,n,a,r,i){var c=e.resolveComponent("saturation"),d=e.resolveComponent("hue"),l=e.resolveComponent("alpha"),s=e.resolveComponent("input-value"),p=e.resolveComponent("Colors");return e.openBlock(),e.createElementBlock("div",{class:"picker",style:e.normalizeStyle(t.pickerStyle)},[e.createElementVNode("div",hu,[e.createElementVNode("div",yu,[e.createVNode(c,{class:"saturation",hue:t.h,saturation:t.s,value:t.v,onChange:t.onSelectSaturation},null,8,["hue","saturation","value","onChange"]),e.createVNode(d,{class:"hue",hue:t.h,onChange:t.onSelectHue},null,8,["hue","onChange"]),t.showAlpha?(e.openBlock(),e.createBlock(l,{key:0,class:"alpha",alpha:t.a,color:t.rgbStr,onChange:t.onSelectAlpha},null,8,["alpha","color","onChange"])):e.createCommentVNode("v-if",!0)]),e.createVNode(s,{label:t.label,value:t.colorValue,width:t.inputWidth,onChange:t.onInputChange,onBlur:t.handleChange,onEnter:t.handleChange},null,8,["label","value","width","onChange","onBlur","onEnter"]),t.colors.length>0?(e.openBlock(),e.createBlock(p,{key:0,class:"colors",colors:t.colors,"selected-index":t.selectColorIndex,onChange:t.onSelectColor},null,8,["colors","selected-index","onChange"])):e.createCommentVNode("v-if",!0)])],4)},mo.__scopeId="data-v-6ceadec6",mo.__file="src/picker/Picker.vue";var ho=e.defineComponent({name:"AddColorItem",props:{size:{type:Number,default:20},selected:{type:Boolean,default:!1}},setup:function(t){var o=e.inject("theme",{theme:"light"}).theme;return{addColorItemStyle:e.computed(function(){return{width:"".concat(t.size,"px"),height:"".concat(t.size,"px"),lineHeight:"".concat(t.size,"px"),boxShadow:t.selected?"0 0 3px 2px ".concat(e.unref(o)==="dark"?"#2681ff":"#1890ff"):""}})}}}),gu=[function(t){return e.pushScopeId("data-v-ceb1719c"),t=t(),e.popScopeId(),t}(function(){return e.createElementVNode("g",{class:"container"},[e.createElementVNode("path",{d:"M544 464V160h-80v304H160v80h304v304h80V544h304v-80z"})],-1)})];function rr(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),n.push.apply(n,a)}return n}function fn(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?rr(Object(n),!0).forEach(function(a){cn(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):rr(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}Ke(".add-color-item[data-v-ceb1719c]{background:#fff;border:1px solid #d9d9d9;border-radius:5px;vertical-align:top}.container[data-v-ceb1719c]{pointer-events:none;transform:scale(.9);transform-origin:center}[pick-colors-theme=dark] .add-color-item[data-v-ceb1719c]{background:#141414;border:1px solid #434343}path[data-v-ceb1719c]{fill:#000}[pick-colors-theme=dark] path[data-v-ceb1719c]{fill:#fff}"),ho.render=function(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("svg",{style:e.normalizeStyle(t.addColorItemStyle),class:"add-color-item",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"},[].concat(gu),4)},ho.__scopeId="data-v-ceb1719c",ho.__file="src/add-color-item/AddColorItem.vue";var st=null,xt=e.defineComponent({name:"ColorPicker",components:{ColorItem:vt,Picker:mo,AddColorItem:ho},props:{value:{type:[String,Array]},theme:{type:String,default:"light"},size:{type:[Number,String],default:20},width:{type:[Number,String]},height:{type:[Number,String]},format:{type:String,default:"hex"},showPicker:{type:Boolean,default:void 0},showAlpha:{type:Boolean,default:!1},addColor:{type:Boolean,default:!1},deleteColor:{type:Boolean,default:!0},max:{type:Number,default:13},popupContainer:{type:[String,Object,Boolean]},zIndex:{type:Number,default:1e3},colors:{type:Array,default:function(){return["#ff4500","#ff8c00","#ffd700","#90ee90","#00ced1","#1e90ff","#c71585","#ff4500","#ff7d4d","#00babd","#1f93ff","#fa64c3"]}}},emits:["change","update:value","update:showPicker","overflowMax","closePicker"],setup:function(t,o){var n=o.emit,a=e.ref([]),r=e.computed(function(){return e.unref(a).map(function(B){return dn(B,"hex",t.showAlpha)})});e.watch(function(){return t.value},function(){var B=t.value||"",F=Array.isArray(B)?B:[B];a.value=F.map(function(O){return dn(O,t.format,t.showAlpha)})},{immediate:!0});var i=e.ref(void 0),c=e.computed(function(){return e.unref(a)[e.unref(i)]}),d=e.ref(!1);e.watch(function(){return t.showPicker},function(){d.value=t.showPicker},{immediate:!0});var l,s,p,u,m,b,h,f=e.ref(null),g=e.ref(null),w=(l=f,s=g,p={zIndex:t.zIndex},u=e.ref({}),m={strategy:"absolute",placement:"auto",onFirstUpdate:function(){st.update()},modifiers:[{name:"offset",options:{offset:[0,5]}},{name:"computeStyles",options:{gpuAcceleration:!1,adaptive:!0}},{name:"flip",options:{fallbackPlacements:["top"],allowedAutoPlacements:["top","bottom"]}},{name:"applyStyles",enabled:!1},{name:"updateState",enabled:!0,phase:"write",requires:["computeStyles"],fn:function(B){var F=B.state,O=F.styles,G=F.placement,R=O.popper;u.value=fn(fn(fn({},R),p),{},{transformOrigin:G==="top"?"center bottom":""})}}]},e.watch(function(){return[e.unref(l),e.unref(s)]},function(B,F){var O,G=Mt(B,2),R=G[0],S=G[1],L=Mt(F,2),k=L[0],D=L[1];if(R&&S&&(k!==R||D!==k)){(O=st)===null||O===void 0||O.destroy();var $=R.$el||R,z=S.$el||S;e.nextTick(function(){st=nu($,z,m)})}}),e.onBeforeUnmount(function(){var B;st&&((B=st)===null||B===void 0||B.destroy(),st=null)}),{instance:st,style:u}),C=w.style,x=function(){e.unref(f)==null&&(f.value=e.unref(j)[0],i.value=0),t.showPicker===void 0?d.value=!0:n("update:showPicker",!0)},A=function(){i.value=void 0,t.showPicker===void 0?d.value=!1:n("update:showPicker",!1),n("closePicker",e.toRaw(Array.isArray(t.value)||t.addColor?e.unref(a):e.unref(a)[0]))},y=e.ref(),_=function(){var B=Ga(ro.mark(function F(O){var G,R,S,L;return ro.wrap(function(k){for(;;)switch(k.prev=k.next){case 0:if(R=O.target,(S=(G=R.dataset)===null||G===void 0?void 0:G.index)!=null&&S!==""){k.next=4;break}return k.abrupt("return");case 4:if(L=+S,e.unref(i)!==L){k.next=7;break}return k.abrupt("return");case 7:e.unref(i)!=null&&e.unref(i)!==L?(A(),b&&clearTimeout(b),b=setTimeout(function(){x(),clearTimeout(b)},100)):x(),i.value=L,f.value=R;case 10:case"end":return k.stop()}},F)}));return function(F){return B.apply(this,arguments)}}(),E=function(){var B=Ga(ro.mark(function F(O){var G,R,S,L,k;return ro.wrap(function(D){for(;;)switch(D.prev=D.next){case 0:if(L=O.target,!(!((G=e.unref(y))!==null&&G!==void 0&&G.isEqualNode(L))&&(!((R=e.unref(y))===null||R===void 0)&&R.contains(L)))){D.next=4;break}return D.abrupt("return");case 4:if(k=(S=e.unref(g))===null||S===void 0?void 0:S.$el,!(k!=null&&k.contains(L))){D.next=8;break}return D.abrupt("return");case 8:h&&clearTimeout(h),h=setTimeout(function(){e.unref(d)&&A()},0);case 10:case"end":return D.stop()}},F)}));return function(F){return B.apply(this,arguments)}}();e.watch(d,function(){e.unref(d)&&(x(),clearTimeout(h))});var T,V=e.ref(t.max>e.unref(a).length),N=e.computed(function(){return typeof t.popupContainer=="string"||_t(t.popupContainer)==="object"&&t.popupContainer!=null?t.popupContainer:"body"}),I=e.computed(function(){return typeof t.popupContainer=="boolean"&&t.popupContainer===!1}),M=e.computed(function(){return t.theme});e.watch(function(){return[t.theme,e.unref(g)]},function(){e.nextTick(function(){var B,F;(B=e.unref(y))===null||B===void 0||B.setAttribute("pick-colors-theme",e.unref(M)),(F=e.unref(g))===null||F===void 0||(F=F.$el)===null||F===void 0||F.setAttribute("pick-colors-theme",e.unref(M))})},{immediate:!0}),e.provide("theme",{theme:M});var j=e.ref([]);return e.onMounted(function(){document.addEventListener("mouseup",E,!1),t.showPicker&&x()}),e.onUnmounted(function(){document.removeEventListener("mouseup",E,!1),b&&(clearTimeout(b),b=null),h&&(clearTimeout(h),h=null)}),{valueList:a,colorItemSelected:function(B){return(t.addColor?e.unref(a).length>0:e.unref(a).length>1)&&e.unref(i)===B},selectedColor:c,selectedIndex:i,isShowPicker:d,addColorItemShow:V,onPickerChange:function(B){var F=e.unref(i),O=e.unref(a).slice(),G=e.unref(a).length;if(F!=null){F>=0?O[F]=B:(i.value=G,O.push(B));var R="";R=Array.isArray(t.value)||t.addColor?O:B,t.value===void 0?a.value=Array.isArray(R)?R:[R]:(n("update:value",R),n("change",R,B,F)),t.addColor&&G>=t.max&&(V.value=!1,n("overflowMax"))}},colorPicker:y,onColorClick:_,pickerRef:g,onColorItemDragStart:function(B){B.dataTransfer.effectAllowed="move";var F=B.target;T=+F.dataset.index},onColorItemDragOver:function(B){},onColorItemDrop:function(B){var F=+B.target.dataset.index,O=au(e.unref(a)),G=O[T];O.splice(T,1);var R=O.slice(0,F),S=O.splice(F),L=R.concat([G]).concat(S);n("update:value",L),n("change",L,L[T],T)},colorItemsRef:j,pickerStyle:C,values:r,teleportDisabled:I,toPopupContainer:N}}});Ke(".color-picker[data-v-3c43ade8]{display:inline-block}.color-item[data-v-3c43ade8]{margin:5px}.add-color-item[data-v-3c43ade8]{display:inline-block;margin:5px}.picker[data-v-3c43ade8]{overflow:hidden}.v-enter-active[data-v-3c43ade8],.v-leave-active[data-v-3c43ade8]{opacity:1;transform:scaleY(1);transform-origin:center top;transition:opacity .2s ease-in-out,transform .2s ease-in-out}.v-enter-from[data-v-3c43ade8],.v-leave-to[data-v-3c43ade8]{opacity:0;transform:scaleY(0)}"),xt.render=function(t,o,n,a,r,i){var c=e.resolveComponent("color-item"),d=e.resolveComponent("add-color-item"),l=e.resolveComponent("picker");return e.openBlock(),e.createElementBlock("div",{class:"color-picker",ref:"colorPicker",onDragstart:o[0]||(o[0]=e.withModifiers(function(){return t.onColorItemDragStart&&t.onColorItemDragStart.apply(t,arguments)},["stop"])),onDragover:o[1]||(o[1]=e.withModifiers(function(){return t.onColorItemDragOver&&t.onColorItemDragOver.apply(t,arguments)},["prevent","stop"])),onDrop:o[2]||(o[2]=e.withModifiers(function(){return t.onColorItemDrop&&t.onColorItemDrop.apply(t,arguments)},["prevent","stop"])),onClick:o[3]||(o[3]=e.withModifiers(function(){return t.onColorClick&&t.onColorClick.apply(t,arguments)},["stop"]))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,function(s,p){return e.openBlock(),e.createBlock(c,{class:"color-item",key:p,ref_for:!0,ref:function(u){return t.colorItemsRef[p]=u},size:t.size,width:t.width,height:t.height,value:s,selected:t.colorItemSelected(p),"data-index":p,draggable:t.valueList.length>1,format:t.format},null,8,["size","width","height","value","selected","data-index","draggable","format"])}),128)),t.addColor&&t.addColorItemShow?(e.openBlock(),e.createBlock(d,{key:0,class:"add-color-item",ref:"addColorItem",selected:t.colorItemSelected(-1),"data-index":-1},null,8,["selected"])):e.createCommentVNode("v-if",!0),(e.openBlock(),e.createBlock(e.Teleport,{to:t.toPopupContainer,disabled:t.teleportDisabled},[e.createVNode(e.Transition,null,{default:e.withCtx(function(){return[t.isShowPicker?(e.openBlock(),e.createBlock(l,{key:0,class:"picker",style:e.normalizeStyle(t.pickerStyle),ref:"pickerRef",value:t.selectedColor,format:t.format,"show-alpha":t.showAlpha,colors:t.colors,onChange:t.onPickerChange},null,8,["style","value","format","show-alpha","colors","onChange"])):e.createCommentVNode("v-if",!0)]}),_:1})],8,["to","disabled"]))],544)},xt.__scopeId="data-v-3c43ade8",xt.__file="src/ColorPicker.vue";const bu=e.defineComponent({name:"ColorPick",components:{PickColors:xt,AInput:P.Input},props:{value:{type:String,require:!0}},emits:["change"],setup(t,o){const n=e.computed({get:()=>t.value,set:r=>{o.emit("change",r)}});return{colorValue:n,onChangColor:r=>{n.value=r.hex}}}}),$m="",Cu={class:"color-pick"};function wu(t,o,n,a,r,i){const c=e.resolveComponent("a-input"),d=e.resolveComponent("pick-colors");return e.openBlock(),e.createElementBlock("div",Cu,[e.createVNode(c,{class:"input",value:t.colorValue,"onUpdate:value":o[0]||(o[0]=l=>t.colorValue=l)},null,8,["value"]),e.createVNode(d,{class:"pick-colors",value:t.colorValue,"onUpdate:value":o[1]||(o[1]=l=>t.colorValue=l),size:25},null,8,["value"])])}const ku=ne(bu,[["render",wu],["__scopeId","data-v-e2113f43"]]),_u=e.defineComponent({name:"ColorGroupPick",components:{PickColors:xt},props:{value:{type:Array,default:()=>[]}},emits:["change"],setup(t,{emit:o}){const n=i=>{o("change",i)},a=e.ref(13);return{onColorsChange:n,max:a,onOverflowMax:()=>{P.message.warn(`已经超出最大添加个数:${a.value}`)}}}}),Pm="",Su={class:"color-group-pick"};function xu(t,o,n,a,r,i){const c=e.resolveComponent("pick-colors");return e.openBlock(),e.createElementBlock("div",Su,[e.createVNode(c,{value:t.value,"add-color":"",max:t.max,onChange:t.onColorsChange,onOverflowMax:t.onOverflowMax},null,8,["value","max","onChange","onOverflowMax"])])}const Nu=ne(_u,[["render",xu],["__scopeId","data-v-b2be8322"]]),Au=e.defineComponent({name:"FormGroup",components:{Draggable:mt,AppstoreAddOutlined:Oo,MinusCircleOutlined:ni,PickColors:xt,InputNumber:_a,PlusCircleOutlined:ii},props:{value:{type:Array,default:()=>[]},format:{type:Array,default:()=>[]},useLabelIndex:{type:Boolean,default:!1},max:{type:Number,default:-1}},emits:["change"],setup(t,{emit:o}){const n=e.computed({get:()=>t.value,set:s=>{o("change",s)}});return{myValue:n,onAdd:()=>{var u;const s=(u=t.value)==null?void 0:u.slice();if(!Array.isArray(s))return;const p=s.length;if(t.max===-1||t.max>p){const m=s[0];if(Object.prototype.toString.call(m)==="[object Object]"){const b=Object.keys(m),h={};b.forEach(f=>{h[f]=""}),s.push(h)}else typeof m=="string"&&s.push(m);n.value=s}else P.message.warn("已达到最大上限")},useComponentType:s=>({input:"aInput",select:"aSelect",color:"pickColors","input-number":"inputNumber",switch:"aSwitch"})[s],onValueChange:(s,p,u)=>{var b;const m=(b=t.value)==null?void 0:b.slice();if(Array.isArray(m)){const h=s==null?void 0:s.target,f=(h==null?void 0:h.value)!=null?h==null?void 0:h.value:s;u?m[p][u]=f:m[p]=f,n.value=m}},onDelete:s=>{var u;const p=(u=t.value)==null?void 0:u.slice();if(Array.isArray(p)){if(p.length===1){P.message.warn("已经是最后一条数据,无法删除");return}p.splice(s,1),n.value=p}},theme:"light",formatTypeValue:s=>s||"value"}}}),Mm="",Tu={class:"form-group"},Eu={class:"form-row"},Vu={key:0,class:"label"},Lu={key:1,class:"label"},Bu={class:"icon-group"};function Ou(t,o,n,a,r,i){const c=e.resolveComponent("appstore-add-outlined"),d=e.resolveComponent("draggable"),l=e.resolveComponent("minus-circle-outlined");return e.openBlock(),e.createElementBlock("div",Tu,[e.createVNode(c,{class:"icon add",onClick:t.onAdd},null,8,["onClick"]),e.createVNode(d,{class:"form",modelValue:t.myValue,"onUpdate:modelValue":o[0]||(o[0]=s=>t.myValue=s),"item-key":"id"},{item:e.withCtx(({element:s,index:p})=>[e.createElementVNode("div",Eu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.format,(u,m)=>(e.openBlock(),e.createElementBlock("div",{class:"form-item",key:m},[Array.isArray(u.label)?(e.openBlock(),e.createElementBlock("span",Vu,e.toDisplayString(u.useLabelIndex?u.label[p]+(p+1):u.label[p]),1)):(e.openBlock(),e.createElementBlock("span",Lu,e.toDisplayString(u.useLabelIndex?u.label+(p+1):u.label),1)),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.useComponentType(u.type)),e.mergeProps({class:"value",[t.formatTypeValue(u.typeValue)||""]:typeof s=="string"?s:s[u.value]??u.defaultValue,style:{width:!["color","switch"].includes(u.type)&&t.format.length>1?"110px":""}},u.props,{theme:t.theme,"use-blur-event":!1,onChange:b=>t.onValueChange(b,p,u.value)}),null,16,["style","theme","onChange"]))]))),128))])]),_:1},8,["modelValue"]),e.createElementVNode("div",Bu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.myValue,(s,p)=>(e.openBlock(),e.createElementBlock("div",{class:"icon-item",key:p},[e.createVNode(l,{class:"icon delete",onClick:u=>t.onDelete(p)},null,8,["onClick"])]))),128))])])}const Du=ne(Au,[["render",Ou],["__scopeId","data-v-f0c0ab4d"]]),Iu=e.defineComponent({name:"Textarea",props:{value:{type:String,default:""},disabled:{type:Boolean,default:!1}},components:{ATextarea:P.Textarea},emits:["change"],setup(t,{emit:o}){return{onTextareaChange:a=>{o("change",a.target.value)}}}});function Fu(t,o,n,a,r,i){const c=e.resolveComponent("a-textarea");return e.openBlock(),e.createBlock(c,{value:t.value,disabled:t.disabled,autoSize:{minRows:3},onChange:t.onTextareaChange},null,8,["value","disabled","onChange"])}const $u=ne(Iu,[["render",Fu]]),Pu=e.defineComponent({name:"PropsToForm",components:{Input:vd,InputNumber:_a,RadioGroup:Hd,Select:qd,Switch:Xd,ColorPick:ku,ColorGroupPick:Nu,FormGroup:Du,Textarea:$u},props:{props:{type:Object,require:!0},disabled:{type:Boolean,default:!1},componentType:{type:String,default:""}},setup(t){const o=e.inject(Yt),n=e.inject(bo),a=e.inject(Co),r=e.computed(()=>{var l;return(l=e.unref(o))==null?void 0:l.type}),i=l=>{t.componentType&&t.componentType==="table"?a(l):n(l)},c=l=>{const{result:s,mapAttributeProp:p,key:u,value:m}=l;if(s==null||typeof s!="object")return;const{valueProp:b="value",changeValueEventName:h="change",events:f}=p;s[u]={...p,valueProp:b,value:m,events:{[h]:(g,w=!0)=>{i(w?{[u]:g}:{})},...f}}};return{formProps:e.computed(()=>{const l=t.props;return l==null||typeof l!="object"?{}:ee.reduce(l,(s,p,u)=>{const m=Pd[u];if(Array.isArray(m)){const b=m.find(h=>{const{onlyType:f,excludeType:g}=h;return f==null&&g==null?!0:f?ge(e.unref(r),f):g?!ge(e.unref(r),g):!1});b&&c({result:s,value:p,key:u,mapAttributeProp:b})}else c({result:s,value:p,key:u,mapAttributeProp:m});return s},{})}),lowerCaseIncludes:ge}}}),jm="",Mu={class:"props-to-form"},ju={class:"label"},vu={class:"component-wrapper"};function Ru(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",Mu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formProps,(c,d)=>(e.openBlock(),e.createElementBlock("div",{key:d,class:"prop-item"},[e.createElementVNode("span",ju,e.toDisplayString(c.label),1),e.createElementVNode("div",vu,[Array.isArray(c)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(c,(l,s)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.component),e.mergeProps({key:s,class:"component",style:l.style,disabled:t.disabled},l.props,e.toHandlers(l.events)),null,16,["style","disabled"]))),128)):e.createCommentVNode("",!0),Array.isArray(c)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[c.component?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c.component),e.mergeProps({key:0,class:"component",[c.valueProp||""]:c.value,style:c.style,disabled:t.disabled},c.props,e.toHandlers(c.events)),null,16,["style","disabled"])):e.createCommentVNode("",!0)],64))])]))),128))])}const Uu=ne(Pu,[["render",Ru],["__scopeId","data-v-c6fb2484"]]);function Gu(){return new Worker("/assets/editor.worker-02df2e61.js")}function zu(){return new Worker("/assets/json.worker-867823a6.js")}function Hu(){return new Worker("/assets/ts.worker-7254b425.js")}const Yu=e.defineComponent({name:"Editor",props:{valueData:{type:String,default:""},options:{type:Object,default:()=>({})},language:{type:String,default:"json"},isUseMinimap:{type:Boolean,default:!1},UseSuggestions:{type:Boolean,default:!1},autoFormat:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["change","update:valueData"],setup(t,{emit:o}){window.MonacoEnvironment={getWorker(i,c){return c==="json"?new zu:c==="typescript"||c==="javascript"?new Hu:new Gu}};const n=e.ref();let a=null;const r={light:"vs",dark:"vs-dark"};return e.onMounted(()=>{a=fr.editor.create(n.value,{language:t.language,tabSize:2,automaticLayout:!0,scrollBeyondLastLine:!1,theme:r.light,wordWrap:"off",lineDecorationsWidth:3,lineHeight:15,lineNumbersMinChars:3,formatOnPaste:!0,formatOnType:!0,wordBasedSuggestions:!1,quickSuggestions:t.UseSuggestions,snippetSuggestions:"none",suggestOnTriggerCharacters:!1,scrollbar:{verticalScrollbarSize:6,horizontalScrollbarSize:6,alwaysConsumeMouseWheel:!1,arrowSize:0},autoIndent:"advanced",glyphMargin:!1,fontSize:13,contextmenu:!1,minimap:{enabled:t.isUseMinimap},readOnly:t.readonly,...t.options}),a==null||a.setValue(t.valueData),t.autoFormat&&setTimeout(()=>{a==null||a.getAction("editor.action.formatDocument").run()},200),a.onDidChangeModelContent(ee.debounce(()=>{const i=a==null?void 0:a.getValue();o("change",i)},300)),a.onDidBlurEditorText(()=>{const i=a==null?void 0:a.getValue();o("update:valueData",i)})}),e.watch(()=>t.valueData,i=>{if(a){const c=a.getPosition();a.setValue(i),t.autoFormat&&a.getAction("editor.action.formatDocument").run(),c!=null&&a.setPosition(c)}}),e.onUnmounted(()=>{a==null||a.dispose()}),{dom:n}}}),vm="",Wu={class:"editor",ref:"dom"};function qu(t,o,n,a,r,i){return e.openBlock(),e.createElementBlock("div",Wu,null,512)}const lr=ne(Yu,[["render",qu],["__scopeId","data-v-71e88372"]]),Ku=[{title:"列名",dataIndex:"label",fixed:"left",ellipsis:!0,width:135},{title:"参数",dataIndex:"prop",fixed:"left",ellipsis:!0,width:135},{title:"列自定义",dataIndex:"style",align:"center",ellipsis:!0,width:100},{title:"列宽度(px/%)",dataIndex:"width",ellipsis:!0,width:135},{title:"列自定义函数",dataIndex:"renderText",ellipsis:!0,width:170},{title:"列表头自定义函数",dataIndex:"headerTemplate",ellipsis:!0,width:170},{title:"数据格式化",dataIndex:"dataFormat",ellipsis:!0,width:225},{title:"保留小数位数",dataIndex:"retentiondigit",ellipsis:!0,width:135},{title:"表头/表尾列对齐方式",dataIndex:"headerAlign",ellipsis:!0,width:170},{title:"内容列对齐方式",dataIndex:"align",ellipsis:!0,width:170},{title:"固定当前列",dataIndex:"fixed",ellipsis:!0,width:170}],Qu=e.defineComponent({name:"TableColumnConfig",components:{ATable:P.Table,AModal:P.Modal,ACheckbox:P.Checkbox,AInput:P.Input,AInputNumber:P.InputNumber,ASelect:P.Select,ASelectOption:P.SelectOption,Editor:lr},setup(){const t=e.inject(Ye),o=e.computed(()=>{var f;return!!((f=e.unref(t))!=null&&f.isGroupTable)}),n=e.computed(()=>{var f;return((f=e.unref(t))==null?void 0:f.graphicConfig)||{}}),a=e.computed(()=>{var f;return((f=e.unref(t))==null?void 0:f.tableColumns)||[]}),r=e.ref([]);let i=null,c="";const d=e.ref(""),l=e.ref(""),s=e.ref(!1);e.watch(n,()=>{p()},{deep:!0,flush:"post"});const p=()=>{var g,w,C;let f=[];if(r.value=[],!o.value)f=((g=e.unref(n))==null?void 0:g.queryColumnList)||[];else{const x=((w=e.unref(n))==null?void 0:w.rowHeaderList)||[],A=((C=e.unref(n))==null?void 0:C.indicators)||[];f=[...x,...A]}f.forEach(x=>{var y;let A=(y=e.unref(a))==null?void 0:y.find(_=>_.prop===x.name);A||(A={label:x.label,prop:x.name,style:!1,width:"",renderText:"",headerTemplate:"",headerAlign:"left",align:"left",fixed:"",dataFormat:[],retentiondigit:null}),r.value.push(A)}),t.value.tableColumns=r.value};return e.onMounted(()=>{p()}),{configColumns:Ku,configData:r,editorTitle:l,editorVisible:s,optionCode:d,handleOk:()=>{i&&c&&(i[c]=d.value),d.value="",s.value=!1},renderSave:(f,g,w)=>{f&&g&&(i=f,c=g,d.value=f[g]||"",s.value=!0,l.value=w)},onEditorChange:f=>{try{d.value=f}catch(g){console.error(g)}},changeRenderBool:(f,g)=>{f.style=g.target.checked,f.style?f.renderBool===void 0&&(f.renderBool=!1):delete f.renderBool}}}}),Rm="",Xu={class:"table-column-config"};function Ju(t,o,n,a,r,i){const c=e.resolveComponent("a-checkbox"),d=e.resolveComponent("a-input"),l=e.resolveComponent("a-select-option"),s=e.resolveComponent("a-select"),p=e.resolveComponent("a-input-number"),u=e.resolveComponent("a-table"),m=e.resolveComponent("editor"),b=e.resolveComponent("a-modal");return e.openBlock(),e.createElementBlock("div",Xu,[e.createVNode(u,{class:"column-table",columns:t.configColumns,"data-source":t.configData,scroll:{x:"100%",y:400},pagination:!1,bordered:""},{bodyCell:e.withCtx(({column:h,text:f,record:g})=>[h.dataIndex==="style"?(e.openBlock(),e.createBlock(c,{key:0,onChange:w=>t.changeRenderBool(g,w),checked:g.style},null,8,["onChange","checked"])):h.dataIndex==="width"?(e.openBlock(),e.createBlock(d,{key:1,value:g.width,"onUpdate:value":w=>g.width=w,valueModifiers:{trim:!0}},null,8,["value","onUpdate:value"])):h.dataIndex==="renderText"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[g.style?(e.openBlock(),e.createBlock(d,{key:1,value:g.renderText,"onUpdate:value":w=>g.renderText=w,readOnly:!0,onClick:w=>t.renderSave(g,"renderText","列自定义函数")},null,8,["value","onUpdate:value","onClick"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(f),1)],64))],64)):h.dataIndex==="headerTemplate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[g.style?(e.openBlock(),e.createBlock(d,{key:1,value:g.headerTemplate,"onUpdate:value":w=>g.headerTemplate=w,readOnly:!0,onClick:w=>t.renderSave(g,"headerTemplate","列表头自定义函数")},null,8,["value","onUpdate:value","onClick"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(f),1)],64))],64)):h.dataIndex==="headerAlign"?(e.openBlock(),e.createBlock(s,{key:4,style:{width:"100%"},size:"small",value:g.headerAlign,"onUpdate:value":w=>g.headerAlign=w},{default:e.withCtx(()=>[e.createVNode(l,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("左对齐")]),_:1}),e.createVNode(l,{value:"center"},{default:e.withCtx(()=>[e.createTextVNode("居中")]),_:1}),e.createVNode(l,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("右对齐")]),_:1})]),_:2},1032,["value","onUpdate:value"])):h.dataIndex==="align"?(e.openBlock(),e.createBlock(s,{key:5,style:{width:"100%"},size:"small",value:g.align,"onUpdate:value":w=>g.align=w},{default:e.withCtx(()=>[e.createVNode(l,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("左对齐")]),_:1}),e.createVNode(l,{value:"center"},{default:e.withCtx(()=>[e.createTextVNode("居中")]),_:1}),e.createVNode(l,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("右对齐")]),_:1})]),_:2},1032,["value","onUpdate:value"])):h.dataIndex==="fixed"?(e.openBlock(),e.createBlock(s,{key:6,style:{width:"100%"},size:"small",value:g.fixed,"onUpdate:value":w=>g.fixed=w},{default:e.withCtx(()=>[e.createVNode(l,{value:""},{default:e.withCtx(()=>[e.createTextVNode("不固定")]),_:1}),e.createVNode(l,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("靠左")]),_:1}),e.createVNode(l,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("靠右")]),_:1})]),_:2},1032,["value","onUpdate:value"])):h.dataIndex==="dataFormat"?(e.openBlock(),e.createBlock(s,{key:7,value:g.dataFormat,"onUpdate:value":w=>g.dataFormat=w,style:{width:"100%"},mode:"multiple",allowClear:"",maxTagCount:1},{default:e.withCtx(()=>[e.createVNode(l,{value:"#,000"},{default:e.withCtx(()=>[e.createTextVNode("千分位")]),_:1}),e.createVNode(l,{value:"#.00"},{default:e.withCtx(()=>[e.createTextVNode("保留小数")]),_:1}),e.createVNode(l,{value:"#"},{default:e.withCtx(()=>[e.createTextVNode("保留有效位")]),_:1})]),_:2},1032,["value","onUpdate:value"])):h.dataIndex==="retentiondigit"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[g.dataFormat&&g.dataFormat.includes("#.00")?(e.openBlock(),e.createBlock(p,{key:0,value:g.retentiondigit,"onUpdate:value":w=>g.retentiondigit=w,min:0,max:10},null,8,["value","onUpdate:value"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)]),_:1},8,["columns","data-source"]),e.createVNode(b,{title:t.editorTitle,visible:t.editorVisible,"onUpdate:visible":o[0]||(o[0]=h=>t.editorVisible=h),"destroy-on-close":"",width:"700px",bodyStyle:{height:"500px",overflow:"auto"},centered:"",zIndex:1020,okText:"保存",cancelText:"取消",onOk:t.handleOk},{default:e.withCtx(()=>[e.createVNode(m,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.optionCode,onChange:t.onEditorChange},null,8,["valueData","onChange"])]),_:1},8,["title","visible","onOk"])])}const Zu=ne(Qu,[["render",Ju],["__scopeId","data-v-afebddc0"]]),ef=e.defineComponent({name:"StyleConfigGroup",props:{componentType:{type:String,default:""},isGroupTable:{type:Boolean,default:!1}},components:{PropsToForm:Uu,TableColumnConfig:Zu,Editor:lr,AFormItem:P.FormItem,ASelect:P.Select,ASelectOption:P.SelectOption,ACollapse:P.Collapse,ACollapsePanel:P.CollapsePanel,ASwitch:P.Switch},setup(t){const o=e.ref([]),n=e.ref(["表格"]),a=e.inject(Yt),r=e.inject(bn),i=e.inject(bo),c=e.inject(Co),d=e.inject(gn),l=y=>{i({...Sn[y]},!1),d()},s=e.computed(()=>{var y;return(y=e.unref(a))==null?void 0:y.type}),p=["showTotalBool","totalName","expandAll"],u=e.computed(()=>$d.map(y=>{const{props:_,title:E,enableProps:T,onlyType:V,excludeType:N}=y,I=[];_.forEach(B=>{typeof B=="string"&&(p.includes(B)?t.isGroupTable&&I.push(B):I.push(B))});let M,j;return t.componentType==="table"&&(V!=null&&V.includes(t.componentType))?(M=typeof T=="string"&&r.value?r.value[T]:void 0,j=ee.pick(e.unref(r),I)):(M=typeof T=="string"&&a.value?a.value[T]:void 0,j=ee.pick(e.unref(a),I)),{title:E,enableProps:M,enablePropsName:T,onlyType:V,excludeType:N,props:j}}).filter(({props:y})=>Object.keys(y).length>0)),m=(y,_)=>{const{onlyType:E,excludeType:T}=y;return E==null&&T==null?!0:E?ge(_,E):T?!ge(_,T):!1},b=(y,_)=>(_==null||_.stopPropagation(),y),h=(y,_)=>{_!=null&&i({[_]:y})},f=e.computed(()=>JSON.stringify(e.unref(a),null,2)),g=y=>{try{const _=JSON.parse(y||"{}");i(_,!1)}catch(_){console.error(_)}},w=e.ref(""),C=y=>{try{w.value=y}catch(_){console.error(_)}},x=(y,_)=>{try{c({[_]:y})}catch(E){console.error(E)}},A=e.computed(()=>{var y;return["customGraph"].includes((y=e.unref(a))==null?void 0:y.type)});return{type:s,handleChangeType:l,activePanel:o,tablePanel:n,ComponentString:f,updateComponentOptions:g,tableOptions:r,optionCode:w,onEditorChange:C,tableEditorChange:x,onSwitchClick:b,onSwitchChange:h,detailPropsGroups:u,isRenderForm:m,isShowOptionEditor:A}}}),Um="",Gm="",tf={class:"style-group"};function of(t,o,n,a,r,i){const c=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-form-item"),s=e.resolveComponent("a-switch"),p=e.resolveComponent("props-to-form"),u=e.resolveComponent("a-collapse-panel"),m=e.resolveComponent("editor"),b=e.resolveComponent("a-collapse"),h=e.resolveComponent("table-column-config");return e.openBlock(),e.createElementBlock("div",tf,[t.componentType!=="table"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(l,{label:"图表类型"},{default:e.withCtx(()=>[e.createVNode(d,{value:t.type,"onUpdate:value":o[0]||(o[0]=f=>t.type=f),style:{width:"100%"},onChange:t.handleChangeType},{default:e.withCtx(()=>[e.createVNode(c,{value:"line"},{default:e.withCtx(()=>[e.createTextVNode("折线图")]),_:1}),e.createVNode(c,{value:"bar"},{default:e.withCtx(()=>[e.createTextVNode("柱状图")]),_:1}),e.createVNode(c,{value:"pie"},{default:e.withCtx(()=>[e.createTextVNode("饼图")]),_:1}),e.createVNode(c,{value:"comboGraph"},{default:e.withCtx(()=>[e.createTextVNode("组合图表")]),_:1}),e.createVNode(c,{value:"customGraph"},{default:e.withCtx(()=>[e.createTextVNode("自定义图表")]),_:1})]),_:1},8,["value","onChange"])]),_:1}),e.createVNode(b,{activeKey:t.activePanel,"onUpdate:activeKey":o[1]||(o[1]=f=>t.activePanel=f)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.detailPropsGroups,f=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:f.title},[t.isRenderForm(f,t.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[f.title?(e.openBlock(),e.createBlock(u,{header:f.title,key:f.title},{extra:e.withCtx(()=>[typeof f.enableProps=="boolean"?(e.openBlock(),e.createBlock(s,{key:0,checked:f.enableProps,onChange:g=>t.onSwitchChange(g,f.enablePropsName),onClick:t.onSwitchClick},null,8,["checked","onChange","onClick"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createVNode(p,{props:f.props,disabled:typeof f.enableProps=="boolean"?!f.enableProps:!1},null,8,["props","disabled"])]),_:2},1032,["header"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],64))),128)),t.isShowOptionEditor?(e.openBlock(),e.createBlock(u,{key:"custom-option",header:"自定义option配置"},{default:e.withCtx(()=>[e.createVNode(m,{class:"option-editor",language:"typescript",valueData:t.optionCode,onChange:t.onEditorChange},null,8,["valueData","onChange"])]),_:1})):e.createCommentVNode("",!0)]),_:1},8,["activeKey"])],64)):(e.openBlock(),e.createBlock(b,{key:1,activeKey:t.tablePanel,"onUpdate:activeKey":o[4]||(o[4]=f=>t.tablePanel=f)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.detailPropsGroups,f=>{var g;return e.openBlock(),e.createElementBlock(e.Fragment,{key:f.title},[f.title&&((g=f.onlyType)!=null&&g.includes(t.componentType))?(e.openBlock(),e.createBlock(u,{header:f.title,key:f.title},{default:e.withCtx(()=>[e.createVNode(p,{componentType:t.componentType,props:f.props,disabled:typeof f.enableProps=="boolean"?!f.enableProps:!1},null,8,["componentType","props","disabled"])]),_:2},1032,["header"])):e.createCommentVNode("",!0)],64)}),128)),e.createVNode(u,{key:"tableColumn",header:"表格列配置"},{default:e.withCtx(()=>[e.createVNode(h)]),_:1}),e.createVNode(u,{key:"headerCellStyleMethod",header:"表头单元格样式"},{default:e.withCtx(()=>[e.createVNode(m,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.tableOptions.headerCellStyleMethod,onChange:o[2]||(o[2]=f=>t.tableEditorChange(f,"headerCellStyleMethod"))},null,8,["valueData"])]),_:1}),e.createVNode(u,{key:"rowStyleMethod",header:"行样式"},{default:e.withCtx(()=>[e.createVNode(m,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.tableOptions.rowStyleMethod,onChange:o[3]||(o[3]=f=>t.tableEditorChange(f,"rowStyleMethod"))},null,8,["valueData"])]),_:1})]),_:1},8,["activeKey"]))])}const nf=ne(ef,[["render",of],["__scopeId","data-v-2fb3e2ad"]]),af=e.defineComponent({name:"Card",components:{CloseOutlined:Jt,MenuOutlined:na,ADropdown:P.Dropdown,AMenu:P.Menu,AMenuItem:P.MenuItem},props:{index:{type:Number,require:!0},control:{type:Object,default:()=>({})},intersection:{type:Array,default:()=>[]},path:{type:String,default:""}},emits:["delete","update"],setup(t){const o=e.inject(ve),n=e.inject(Wt),a=e.inject(kn),{onUpdateControl:r,onDeleteControl:i,onAddMenuControl:c}=e.inject("CHANGE_CONTROL",{onUpdateControl:k=>{},onDeleteControl:k=>{},onAddMenuControl:(k,D,$)=>{}}),d=e.computed(()=>{var k;return(k=e.unref(o))==null?void 0:k.filter(D=>D.keyName!=="")}),l=e.computed(()=>[{keyName:"父页面",id:"PARENT"},...e.unref(d)]),s=e.computed(()=>{var $,z;const k=[],D=($=e.unref(d))==null?void 0:$.find(W=>{var Q;return W.id===((Q=t.control)==null?void 0:Q.id)});if(D){const W=D.type,Q=ee.pick(D,["value","startTime","endTime"]);(z=Object.keys(Q))!=null&&z.length||(Q.value="");for(const Z in Q)if(Object.prototype.hasOwnProperty.call(Q,Z)){const oe=e.unref(a)[Z];if(Array.isArray(oe)){const ie=oe.find(se=>ge(W,se.onlyType));ie&&k.push({label:ie.label,value:Z})}else k.push({label:oe.label,value:Z})}}return k}),p=()=>{i({index:t.index,path:t.path}),m(t.control.id)},u=({key:k})=>{c(t.path,t.index,k==="2"?"||":"&&")};function m(k){const D=e.unref(d).find($=>$.id===k);if(D){const{type:$,id:z,events:W=[]}=D,Q=Zt($),Z=W.findIndex(oe=>{var ie;return oe.on===Q&&oe.target===((ie=e.unref(_))==null?void 0:ie.id)&&oe.emit==="refreshData"});Z!==-1&&(W.splice(Z,1),n({id:z,events:W}))}}const b=k=>{const D={...t.control};if(D.id=k,D.customValue="",k){const $=e.unref(d).find(z=>z.id===k);$&&(D.keyName=$.keyName,V($,k))}delete D.prop,r({control:D,index:t.index,path:t.path})},h=e.ref(""),f=()=>{h.value=t.control.id},g=k=>{r({control:{...t.control,prop:k},index:t.index,path:t.path})},w=k=>{r({control:{...t.control,prop:k.target.value},index:t.index,path:t.path})},C=k=>{r({control:{...t.control,rule:k},index:t.index,path:t.path})},x=k=>{const D={...t.control};D.modelKey&&(D.modelKey=""),D.prop&&(D.prop=""),D.format&&(D.format=""),r({control:{...D,dataType:k,customValue:"",id:"",keyName:""},index:t.index,path:t.path})},A=k=>{r({control:{...t.control,customValue:k.target.value},index:t.index,path:t.path})},y=k=>{const D={...t.control};k==null?delete D.mode:D.mode=k,delete D.conditionLabel,delete D.conditionName,delete D.conditionKey,delete D.conditionValueType,r({control:D,index:t.index,path:t.path})},_=e.inject(Ye),E=e.inject(Ce),T=e.computed(()=>{var He;const{classificationList:k=[],seriesList:D=[],leftAxisList:$=[],rightAxisList:z=[],indicators:W=[],rowHeaderList:Q=[],queryColumnList:Z=[]}=e.unref(E),oe=ee.cloneDeep([...k,...D,...$,...z,...W,...Q,...Z]);if(oe!=null&&oe.length)for(const pe of oe)pe.id=pe.name;const ie=[{label:"日期",name:"日期",id:"the_date",genericType:"DATE",typeGuid:"the_date",indexCode:null},{label:"HRP单位编号",name:"HRP单位编号",id:"hbdwbh",genericType:"TEXT",typeGuid:"hbdwbh",indexCode:null},{label:"HRP单位名称",name:"HRP单位名称",id:"hbdwbh_name",genericType:"TEXT",typeGuid:"hbdwbh_name",indexCode:null},...t.intersection.map(pe=>({...pe,id:pe.name,label:pe.title||pe.label})),...oe];if(((He=e.unref(_))==null?void 0:He.type)==="ecanSelect"){const{selectFieldOptions:pe=[]}=e.unref(E);if(ie.unshift({label:"上级编码",name:"上级编码",id:"parentCode",genericType:"TEXT"}),pe!=null&&pe.length)for(const Te of pe)ie.unshift({label:Te.label,name:Te.value,id:Te.value,genericType:"TEXT"})}const se=new Map,je=ie.length;for(let pe=0;pe<je;pe++){const Te=ie[pe],{id:nt}=Te||{};se.set(nt,Te)}return[...se].map(([pe,Te])=>Te)});function V(k,D){var Z,oe;const{type:$,id:z,events:W=[]}=k,Q=Zt($);e.unref(h)&&D!==e.unref(h)&&(tt(((Z=e.unref(E))==null?void 0:Z.controlList)||[]).find(se=>se.id===e.unref(h))||m(e.unref(h))),W.find(ie=>{var se;return ie.on===Q&&ie.target===((se=e.unref(_))==null?void 0:se.id)&&ie.emit==="refreshData"})||n({id:z,events:[...W,{on:Q,target:(oe=e.unref(_))==null?void 0:oe.id,emit:"refreshData"}].reverse()})}const N=(k,D)=>{if(k){const{label:$,name:z,id:W,genericType:Q,indexCode:Z,typeGuid:oe,indexCodeNum:ie}=D||{},se={...t.control,conditionKey:W,conditionLabel:$,conditionName:z,conditionValueType:Q,indexCode:Z,typeGuid:oe,indexCodeNum:ie};gt(se,"rule")||(se.rule="EQUAL"),gt(se,"dataType")||(se.dataType="component"),r({control:se,index:t.index,path:t.path})}else{const $={...t.control};delete $.conditionLabel,delete $.conditionName,delete $.conditionKey,delete $.conditionValueType,r({control:$,index:t.index,path:t.path})}},I=(k,D)=>{var $;return($=D==null?void 0:D.keyName)==null?void 0:$.toLowerCase().includes(k==null?void 0:k.toLowerCase())},M=(k,D)=>{var $;return($=D==null?void 0:D.label)==null?void 0:$.toLowerCase().includes(k==null?void 0:k.toLowerCase())},j=e.computed(()=>{const k=e.unref(T).find($=>$.id===t.control.conditionKey);let D="";return k&&(D=(k==null?void 0:k.genericType)||""),D==="TEXT"||D==="0"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"包含",value:"LIKE"},{label:"不包含",value:"NOT_LIKE"},{label:"开头是",value:"LIKE%"},{label:"结尾是",value:"%LIKE"},{label:"等于",value:"EQUAL"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"}]:D==="NUMBER"||D==="1"?[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:D==="DATE"||D==="2"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:[]}),B=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],F=e.computed(()=>{let k=!1;const{id:D="",dataType:$="component"}=t.control;if(D&&$==="component"){const z=e.unref(d).find(Q=>Q.id===D),W=["table","bar","combograph","line","pie","radar","scatter","list","circulate"];ge(z==null?void 0:z.type,W)&&(k=!0)}return D==="PARENT"&&(k=!0),k}),O=e.computed(()=>{let k=!1;const{id:D="",dataType:$="component"}=t.control;if(D&&$==="component"){const z=e.unref(d).find(W=>W.id===D);(z==null?void 0:z.type)==="ecanRangePicker"&&(k=!0)}return D==="PARENT"&&(k=!0),k}),G=e.computed(()=>{let k=!1;const{id:D="",dataType:$="component"}=t.control;if(D&&$==="component"){const z=e.unref(d).find(W=>W.id===D);["ecanDatePicker","ecanRangePicker"].includes(z==null?void 0:z.type)&&(k=!0)}return k});return{propOptions:s,usedComponentList:d,onDelete:p,onIdChange:b,onIdFocus:f,onPropChange:g,onParentPropChange:w,onModeChange:y,onRuleChange:C,onDataTypeChange:x,onCustomValueChange:A,conditionKeyOptions:T,onConditionKeyChange:N,idFilterOption:I,filterOption:M,onFormatChange:k=>{r({control:{...t.control,format:k},index:t.index,path:t.path})},onModelPropChange:k=>{r({control:{...t.control,modelKey:k.target.value},index:t.index,path:t.path})},clickConditionMenu:u,ruleOption:j,dataTypeOption:B,isShowProp:O,isShowFormat:G,isShowModelProp:F,formatOptions:[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}],keyNameOptions:l}}}),zm="",Hm="",rf={class:"control-card"};function lf(t,o,n,a,r,i){const c=e.resolveComponent("a-select"),d=e.resolveComponent("a-input"),l=e.resolveComponent("menu-outlined"),s=e.resolveComponent("a-menu-item"),p=e.resolveComponent("a-menu"),u=e.resolveComponent("a-dropdown"),m=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",rf,[e.createVNode(c,{class:"field-name",value:t.control.conditionKey,options:t.conditionKeyOptions,fieldNames:{value:"id"},"allow-clear":"","show-search":"",onChange:t.onConditionKeyChange,"filter-option":t.filterOption},null,8,["value","options","onChange","filter-option"]),e.createVNode(c,{class:"field-name",value:t.control.rule,options:t.ruleOption,style:{"max-width":"100px"},onChange:t.onRuleChange},null,8,["value","options","onChange"]),e.createVNode(c,{class:"field-name",value:t.control.dataType,options:t.dataTypeOption,style:{"max-width":"100px"},onChange:t.onDataTypeChange},null,8,["value","options","onChange"]),t.control.dataType===""?(e.openBlock(),e.createBlock(d,{key:0,class:"field-name",value:t.control.customValue,style:{"max-width":"180px"},onInput:t.onCustomValueChange},null,8,["value","onInput"])):e.createCommentVNode("",!0),t.control.dataType==="component"?(e.openBlock(),e.createBlock(c,{key:1,class:"field-name",value:t.control.id,options:t.keyNameOptions,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption,style:{"max-width":"180px"},onChange:t.onIdChange,onClick:t.onIdFocus},null,8,["value","options","filter-option","onChange","onClick"])):e.createCommentVNode("",!0),t.isShowModelProp?(e.openBlock(),e.createBlock(d,{key:2,class:"field-name",value:t.control.modelKey,onInput:t.onModelPropChange,placeholder:t.control.id==="PARENT"?"请输入组件别名":""},null,8,["value","onInput","placeholder"])):e.createCommentVNode("",!0),t.isShowProp?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.control.id==="PARENT"?(e.openBlock(),e.createBlock(d,{key:0,class:"field-name",value:t.control.prop,onInput:t.onParentPropChange,placeholder:"请输入属性名"},null,8,["value","onInput"])):(e.openBlock(),e.createBlock(c,{key:1,class:"field-name",value:t.control.prop,options:t.propOptions,onChange:t.onPropChange},null,8,["value","options","onChange"]))],64)):e.createCommentVNode("",!0),t.isShowFormat?(e.openBlock(),e.createBlock(c,{key:4,class:"field-name",value:t.control.format,options:t.formatOptions,onChange:t.onFormatChange},null,8,["value","options","onChange"])):e.createCommentVNode("",!0),e.createVNode(u,{trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.clickConditionMenu},{default:e.withCtx(()=>[e.createVNode(s,{key:"1"},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(s,{key:"2"},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(l,{class:"more-icon"})]),_:1}),e.createVNode(m,{class:"delete-icon",onClick:t.onDelete},null,8,["onClick"])])}const sf=ne(af,[["render",lf],["__scopeId","data-v-1e33ff6f"]]),cf=e.defineComponent({name:"ControlList",props:{list:{type:Array,default:()=>[]},level:{type:Number,default:0},path:{type:String,default:""},intersection:{type:Array,default:()=>[]}},components:{ControlCard:sf}}),Ym="",df={key:0,class:"condition-list"},pf={key:0,class:"condition-container"},uf={key:0,class:"condition-text"},ff={key:1,class:"condition-text"},mf={class:"conditions"};function hf(t,o,n,a,r,i){const c=e.resolveComponent("control-list",!0),d=e.resolveComponent("control-card");return Array.isArray(t.list)?(e.openBlock(),e.createElementBlock("div",df,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.list,(l,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[l.join&&l.conditions&&Array.isArray(l.conditions)?(e.openBlock(),e.createElementBlock("div",pf,[l.conditions.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.join==="||"?(e.openBlock(),e.createElementBlock("div",uf,"或")):e.createCommentVNode("",!0),l.join==="&&"?(e.openBlock(),e.createElementBlock("div",ff,"且")):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createElementVNode("div",mf,[l.conditions.length>0?(e.openBlock(),e.createBlock(c,{key:0,level:t.level+1,path:`${t.path?t.path+"-":""}${s}`,list:l.conditions,intersection:t.intersection},null,8,["level","path","list","intersection"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(d,{class:"condition",key:l.keyValue||`${t.level}-${s}`,control:l,index:s,path:t.path||"",intersection:t.intersection},null,8,["control","index","path","intersection"]))],64))),128))])):e.createCommentVNode("",!0)}const yf=ne(cf,[["render",hf],["__scopeId","data-v-916ff9bd"]]),gf=e.defineComponent({name:"ControlGroup",props:{intersection:{type:Array,default:()=>[]}},components:{ControlList:yf,AButton:P.Button},setup(){const t=e.inject(ve),o=e.inject(Ce),n=e.inject(xe),a=e.computed(()=>{var u,m;const p=((u=e.unref(o))==null?void 0:u.controlList)||[];for(const b of p)b.conditionKey&&(gt(b,"rule")||(b.prop==="startTime"?b.rule="GREATER_EQUAL":b.prop==="endTime"?b.rule="LESS_EQUAL":b.rule="EQUAL"),gt(b,"dataType")||(b.dataType="component"));return(p==null?void 0:p.length)>1&&!((m=p[0])!=null&&m.join)?[{join:"&&",conditions:p}]:p}),r=e.ref(null),i=p=>{const u={...e.unref(o),...p,sqlConditions:da({...e.unref(o),...p},e.unref(t))};n(u)},c=p=>{var m;const u=(m=e.unref(a))==null?void 0:m.slice();u==null||(u==null?void 0:u.length)===0?i({controlList:[{keyValue:Se()}]}):u[0]!=null&&(u[0].conditions==null||u[0].join!==p?i({controlList:[{join:p,conditions:[u[0],{keyValue:Se()}]}]}):u[0].conditions.length>1&&u[0].join===p&&(u[0].conditions.push({keyValue:Se()}),i({controlList:u})))},d=p=>{var g,w,C,x;const{index:u,path:m}=p;let b=ee.cloneDeep((g=e.unref(a))==null?void 0:g.slice()),h=b;const f=m.split("-");if(f!=null&&f.length){for(const A of f)if(h[A])h=(w=h[A])==null?void 0:w.conditions;else break;if(Array.isArray(h)&&h[u])if(h.splice(u,1),h.length===1){if(f.length>0){const A=f.length-1,y=f[A],_=f.slice(0,A);let E=b,T="";for(const V of _)if(E[V])T=(C=E[V])==null?void 0:C.join,E=(x=E[V])==null?void 0:x.conditions;else break;if(T===h[0].join){if(Array.isArray(h[0].conditions)){const V=ee.cloneDeep(h[0].conditions);E.splice(+y,1),E.splice(+y,0,...V)}}else E[y]=h[0]}}else h.length===0&&(b=[]);i({controlList:b})}},l=p=>{var w,C;const{control:u,index:m,path:b}=p,h=ee.cloneDeep((w=e.unref(a))==null?void 0:w.slice());let f=h;const g=b.split("-");if(g!=null&&g.length)for(const x of g)if(f[x])f=(C=f[x])==null?void 0:C.conditions;else break;Array.isArray(f)&&f[m]&&(f[m]=u),i({controlList:h})},s=(p,u,m)=>{var w,C,x;const b=ee.cloneDeep((w=e.unref(a))==null?void 0:w.slice());let h=b,f="";const g=p.split("-");if(g!=null&&g.length){for(const A of g)if(h[A])f=(C=h[A])==null?void 0:C.join,h=(x=h[A])==null?void 0:x.conditions;else break;if(f===m)h.splice(u+1,0,{keyValue:Se()});else{const A=ee.cloneDeep(h[u]);h[u]={join:m,conditions:[A,{keyValue:Se()}]}}i({controlList:b})}};return e.provide("CHANGE_CONTROL",{onDeleteControl:d,onUpdateControl:l,onAddMenuControl:s}),{controlList:a,bindComponentId:r,onAddControl:c}}}),Wm="",bf={class:"control-group"},Cf={class:"control-group-header"},wf={class:"control-group-content"};function kf(t,o,n,a,r,i){const c=e.resolveComponent("a-button"),d=e.resolveComponent("control-list");return e.openBlock(),e.createElementBlock("div",bf,[e.createElementVNode("div",Cf,[Array.isArray(t.controlList)&&t.controlList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(c,{onClick:o[0]||(o[0]=l=>t.onAddControl("&&"))},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(c,{onClick:o[1]||(o[1]=l=>t.onAddControl("||")),style:{"margin-left":"15px"}},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})],64)):(e.openBlock(),e.createBlock(c,{key:1,onClick:o[2]||(o[2]=l=>t.onAddControl())},{default:e.withCtx(()=>[e.createTextVNode("添加条件")]),_:1}))]),e.createElementVNode("div",wf,[e.createVNode(d,{class:"condition-list",list:t.controlList,level:0,intersection:t.intersection},null,8,["list","intersection"])])])}const _f=ne(gf,[["render",kf],["__scopeId","data-v-1e37d2d3"]]),Sf=e.defineComponent({name:"VariableCard",props:{item:{type:Object,default:()=>({})},index:{type:Number,require:!0},label:String},components:{CloseOutlined:Jt,AppstoreAddOutlined:Oo,ASelect:P.Select,ASelectOption:P.SelectOption,AInput:P.Input,APopover:P.Popover,ATabs:P.Tabs,ATabPane:P.TabPane,AInputNumber:P.InputNumber},setup(t,{emit:o}){const n=e.ref(!1),a=e.inject(ve),r=e.computed(()=>{var A;return(A=e.unref(a))==null?void 0:A.filter(y=>y.keyName!=="")}),i=[{label:"TEXT",value:"TEXT"},{label:"NUMBER",value:"NUMBER"},{label:"DATE",value:"DATE"}],c=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],d=[{label:"间隔值",value:"rangeValue"},{label:"开始时间",value:"startTime"},{label:"结束时间",value:"endTime"}],l=e.ref(ee.cloneDeep(t.item));e.watch(l,A=>{o("update",{...A,label:t.label},t.index)},{deep:!0});const s=e.computed(()=>{var y;let A=null;if(((y=e.unref(l))==null?void 0:y.dataType)==="component"){const _=e.unref(r).find(E=>{var T;return E.id===((T=e.unref(l))==null?void 0:T.id)});_&&(A=_)}return A}),p=e.computed(()=>{var y;let A=!1;return((y=e.unref(l))==null?void 0:y.variableType)==="DATE"&&(A=!0),A}),u=e.computed(()=>{let A=!1;return e.unref(s)&&(A=ge(e.unref(s).type,"range")),A}),m=e.computed(()=>{let A=!1;return e.unref(s)&&(ge(e.unref(s).type,"range")?["startTime","endTime"].includes(e.unref(l).dateTypeValue)&&(A=!0):ge(e.unref(s).type,"date")&&(A=!0)),A}),b=(A,y)=>{A&&(e.unref(l).keyName=y.keyName)},h=()=>{o("delete",t.index)},f=e.computed(()=>e.unref(p)?[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}]:[]),g=()=>{e.unref(l).id=null,e.unref(l).keyName="",e.unref(l).dateTypeValue=null,e.unref(l).variableValue=""},w=()=>{e.unref(l).format=null},C=(A,y)=>{var _;return(_=y==null?void 0:y.keyName)==null?void 0:_.toLowerCase().includes(A==null?void 0:A.toLowerCase())};return e.watch(m,A=>{A&&(e.unref(l).operateType||(e.unref(l).operateType="add"),e.unref(l).operateMode||(e.unref(l).operateMode="year"),e.unref(l).operateValue||(e.unref(l).operateValue=0),e.unref(l).activeOperateKey||(e.unref(l).activeOperateKey=1))},{immediate:!0}),{variableData:l,typeOption:i,dataTypeOption:c,usedComponentList:r,formatOptions:f,rangeTypeOptions:d,isShowFormat:p,isDateRangeComponent:u,isShowDateOperate:m,popoverVisible:n,idFilterOption:C,onChangeComponent:b,onDelete:h,onChangeDataType:g,onChangeVariableType:w,changeTab:A=>{e.unref(l).activeOperateKey=A,A===1?e.unref(l).operateValue=0:A===2&&(e.unref(l).operateValue="rangeValue")}}}}),qm="",xf={class:"variable-item"},Nf=["title"],Af={class:"popover-content-wrap"},Tf={style:{display:"flex"}};function Ef(t,o,n,a,r,i){const c=e.resolveComponent("a-input"),d=e.resolveComponent("a-select"),l=e.resolveComponent("a-select-option"),s=e.resolveComponent("a-input-number"),p=e.resolveComponent("a-tab-pane"),u=e.resolveComponent("a-tabs"),m=e.resolveComponent("appstore-add-outlined"),b=e.resolveComponent("a-popover"),h=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",xf,[t.variableData.randomKey?(e.openBlock(),e.createElementBlock("div",{key:0,class:"var-indicator",title:t.label},e.toDisplayString(t.label),9,Nf)):e.createCommentVNode("",!0),e.createVNode(c,{class:"field-name",value:t.variableData.variableName,"onUpdate:value":o[0]||(o[0]=f=>t.variableData.variableName=f),placeholder:"请输入变量名",disabled:!!t.variableData.randomKey},null,8,["value","disabled"]),e.createVNode(d,{class:"field-name",value:t.variableData.variableType,"onUpdate:value":o[1]||(o[1]=f=>t.variableData.variableType=f),options:t.typeOption,disabled:t.variableData.disabled,style:{"max-width":"120px"},placeholder:"请选择变量类型",onChange:t.onChangeVariableType},null,8,["value","options","disabled","onChange"]),e.createVNode(d,{class:"field-name",value:t.variableData.dataType,"onUpdate:value":o[2]||(o[2]=f=>t.variableData.dataType=f),options:t.dataTypeOption,style:{"max-width":"120px"},onChange:t.onChangeDataType},null,8,["value","options","onChange"]),t.variableData.dataType==="component"?(e.openBlock(),e.createBlock(d,{key:1,class:"field-name",value:t.variableData.id,"onUpdate:value":o[3]||(o[3]=f=>t.variableData.id=f),options:t.usedComponentList,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption,style:{"max-width":"180px"},placeholder:"请选择组件",onChange:t.onChangeComponent},null,8,["value","options","filter-option","onChange"])):(e.openBlock(),e.createBlock(c,{key:2,class:"field-name",style:{"max-width":"180px"},value:t.variableData.variableValue,"onUpdate:value":o[4]||(o[4]=f=>t.variableData.variableValue=f),placeholder:"请输入变量值"},null,8,["value"])),t.isDateRangeComponent?(e.openBlock(),e.createBlock(d,{key:3,class:"field-name",value:t.variableData.dateTypeValue,"onUpdate:value":o[5]||(o[5]=f=>t.variableData.dateTypeValue=f),options:t.rangeTypeOptions,placeholder:"请选择取值类型"},null,8,["value","options"])):e.createCommentVNode("",!0),e.createVNode(d,{class:"field-name",value:t.variableData.format,"onUpdate:value":o[6]||(o[6]=f=>t.variableData.format=f),options:t.formatOptions,placeholder:"请选择值格式"},null,8,["value","options"]),t.isShowDateOperate?(e.openBlock(),e.createBlock(b,{key:4,visible:t.popoverVisible,"onUpdate:visible":o[14]||(o[14]=f=>t.popoverVisible=f),trigger:"click",placement:"bottomRight"},{content:e.withCtx(()=>[e.createElementVNode("div",Af,[e.createVNode(u,{defaultActiveKey:t.variableData.activeOperateKey,onChange:t.changeTab},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(p,{tab:"日期偏移",key:1},{default:e.withCtx(()=>[e.createVNode(s,{class:"field-name",min:"0",value:t.variableData.operateValue,"onUpdate:value":o[9]||(o[9]=f=>t.variableData.operateValue=f),style:{"max-width":"180px",flex:"auto"}},{addonBefore:e.withCtx(()=>[e.createVNode(d,{value:t.variableData.operateType,"onUpdate:value":o[7]||(o[7]=f=>t.variableData.operateType=f),style:{width:"60px"}},{default:e.withCtx(()=>[e.createVNode(l,{value:"add"},{default:e.withCtx(()=>[e.createTextVNode("加")]),_:1}),e.createVNode(l,{value:"minus"},{default:e.withCtx(()=>[e.createTextVNode("减")]),_:1})]),_:1},8,["value"])]),addonAfter:e.withCtx(()=>[e.createVNode(d,{value:t.variableData.operateMode,"onUpdate:value":o[8]||(o[8]=f=>t.variableData.operateMode=f),style:{width:"60px"}},{default:e.withCtx(()=>[e.createVNode(l,{value:"year"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(l,{value:"month"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(l,{value:"week"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(l,{value:"day"},{default:e.withCtx(()=>[e.createTextVNode("日")]),_:1}),e.createVNode(l,{value:"hour"},{default:e.withCtx(()=>[e.createTextVNode("时")]),_:1}),e.createVNode(l,{value:"minute"},{default:e.withCtx(()=>[e.createTextVNode("分")]),_:1})]),_:1},8,["value"])]),_:1},8,["value"])]),_:1})),t.isDateRangeComponent?(e.openBlock(),e.createBlock(p,{tab:"自定义",key:2},{default:e.withCtx(()=>[e.createElementVNode("div",Tf,[e.createVNode(d,{value:t.variableData.operateValue,"onUpdate:value":o[10]||(o[10]=f=>t.variableData.operateValue=f),allowClear:"",style:{width:"120px","margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(l,{value:"rangeValue"},{default:e.withCtx(()=>[e.createTextVNode("范围差值")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.variableData.operateMode,"onUpdate:value":o[11]||(o[11]=f=>t.variableData.operateMode=f),style:{"margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(l,{value:"year"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(l,{value:"month"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(l,{value:"week"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(l,{value:"day"},{default:e.withCtx(()=>[e.createTextVNode("日")]),_:1}),e.createVNode(l,{value:"hour"},{default:e.withCtx(()=>[e.createTextVNode("时")]),_:1}),e.createVNode(l,{value:"minute"},{default:e.withCtx(()=>[e.createTextVNode("分")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.variableData.operateType,"onUpdate:value":o[12]||(o[12]=f=>t.variableData.operateType=f)},{default:e.withCtx(()=>[e.createVNode(l,{value:"minus"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(l,{value:"add"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value"])])]),_:1})):e.createCommentVNode("",!0)]),_:1},8,["defaultActiveKey","onChange"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:"calendar-wrap",onClick:o[13]||(o[13]=f=>{t.popoverVisible=!0})},[e.createVNode(m)])]),_:1},8,["visible"])):e.createCommentVNode("",!0),t.variableData.randomKey?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(h,{key:5,class:"delete-icon",onClick:t.onDelete},null,8,["onClick"]))])}const Vf=ne(Sf,[["render",Ef],["__scopeId","data-v-75ccc065"]]),Lf=e.defineComponent({name:"VariableGroup",components:{VariableItem:Vf},setup(){const t=e.inject(Ce),o=e.inject(xe),n=e.inject(ve),a=e.computed(()=>{var s;return((s=e.unref(t))==null?void 0:s.variableList)||[]}),r=l=>{o({...e.unref(t),variableConditions:Lt(l,n),variableList:l})};return{variableList:a,onAddVariable:()=>{const l=ee.cloneDeep(e.unref(a));l.push({keyValue:Se(),variableType:"TEXT",dataType:"",id:null,dateTypeValue:null,format:null,operateType:"add",operateMode:"year",operateValue:0,activeOperateKey:1}),r(l)},onUpdateItem:(l,s)=>{if(s>=0){const p=ee.cloneDeep(e.unref(a));p[s]=l,r(p)}},onDeleteItem:l=>{if(l>=0){const s=ee.cloneDeep(e.unref(a));s.splice(l,1),r(s)}}}}}),Km="",Bf={class:"variable-group"},Of={class:"variable-group-header"},Df={class:"variable-group-content"};function If(t,o,n,a,r,i){const c=e.resolveComponent("a-button"),d=e.resolveComponent("variable-item");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",Bf,[e.createElementVNode("div",Of,[e.createVNode(c,{onClick:t.onAddVariable},{default:e.withCtx(()=>[e.createTextVNode("添加变量")]),_:1},8,["onClick"])])]),e.createElementVNode("div",Df,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.variableList,(l,s)=>(e.openBlock(),e.createBlock(d,{key:l.keyValue,item:l,index:s,label:l.label,onUpdate:t.onUpdateItem,onDelete:t.onDeleteItem},null,8,["item","index","label","onUpdate","onDelete"]))),128))])],64)}const Ff=ne(Lf,[["render",If],["__scopeId","data-v-fd60cd09"]]),$f=(t={})=>{console.log(t,"reqpp");const o=(c={})=>{const{label:d,name:l,location:s,show:p,indexCode:u}=c;return{label:d,columnName:l,location:s,show:p,calcType:"COLUMN",hrpIndexCode:u}},n=(c,d)=>Object.prototype.hasOwnProperty.call(c,d),a=c=>{n(c,"dataType")&&(c.fieldType==="DATE"&&(c.label=c.fieldName,c.dataType==="component"&&(c.fieldValue="${"+c.fieldValue+"}")),delete c.dataType),n(c,"activeKey")&&delete c.activeKey,n(c,"radioValue")&&delete c.radioValue},r=c=>{const d=[];return c!=null&&c.length&&c.forEach(l=>{if(l.join&&l.conditions){const s=!l.conditions.some(p=>p.join&&p.conditions);l.conditions.forEach((p,u)=>{a(p),s?u<l.conditions.length-1?d.push({join:l.join,...p}):d.push(p):p.join&&p.conditions?d.push({conditions:r([p]),join:l.join}):d.push(p)})}else a(l),d.push(l)}),d},i=(c={})=>{const{label:d,name:l,location:s,show:p,indexCode:u,calcType:m="COLUMN",builtInFormula:b,builtInValueSource:h,builtInCalcWay:f,formula:g,conditions:w,aggregate:C}=c;let x;return w&&(x=r(w)),{label:d.trim(),columnName:l,location:s,show:p,calcType:m,hrpIndexCode:u,aggregate:C,builtInFormula:b,builtInValueSource:h,builtInCalcWay:f,formula:g,conditions:x}};return async()=>{const{graphicConfig:c,type:d,request:l}=t;let{source:s,dataViewId:p,plugin:u="1",layer:m,chartType:b,classificationList:h=[],seriesList:f=[],leftAxisList:g=[],rightAxisList:w=[],queryColumnList:C=[],indicators:x=[],dataSourceId:A,idxLibMode:y,preview:_=!1}=c||{};m==null&&(ge(d,"table")?m="1":m="2");let E;if(Array.isArray(h)&&h.length>0){const I=h.length;for(let M=0;M<I;M++){const j=h[M]||{},{label:B="",name:F="",show:O=!1,sort:G,customGroup:R,conditions:S}=j;if(O||I===1){E={label:B.trim(),columnName:F,show:O,sort:G,customGroup:R,conditions:r(S)};break}}}let T;if(Array.isArray(f)&&f.length>0){const I=f.length;for(let M=0;M<I;M++){const j=f[M]||{},{label:B="",name:F="",show:O=!1,sort:G,customGroup:R,conditions:S}=j;if(O||I===1){T={label:B.trim(),columnName:F,show:O,sort:G,customGroup:R,conditions:r(S)};break}}}const V=[];C==null||C.forEach(I=>{V.push(o(I))});const N=[];if(g==null||g.forEach(I=>{I.location="LEFT",N.push(i(I))}),w==null||w.forEach(I=>{I.location="RIGHT",N.push(i(I))}),x==null||x.forEach(I=>{I.location="LEFT",N.push(i(I))}),!(m==="1"&&V.length===0)&&!(m==="2"&&N.length===0))try{return await l.post("/diagram",{source:s,dataViewId:p,plugin:u,layer:m,chartType:b,classification:E,series:T,indicatorList:N,queryColumns:V,pageFlag:!0,sqlConditions:[],dataSourceId:A,idxLibMode:y,preview:_})}catch(I){console.error(I)}}},ir=(t,o)=>{const n={dayjs:ue,...o};let a="";const r=[];for(const d in n)a+=`${d},`,r.push(n[d]);a=a.replace(/,$/,"");const i=`function (${a}){return ${t}}`;let c;try{c=Function(`"use strict";return (${i})`)()(...r)}catch{return t}return c},yo=(t="",{textData:o,codeData:n}={},{useNewline:a=!1,useSpace:r=!1}={})=>{const i={...o},c=t.match(/\{(.+?)\}/g);if(c==null||c.length===0)return t;for(let d=0;d<c.length;d++){const l=c[d];let s=l.slice(1,-1).trim();const p=/[\u4e00-\u9fa5a-z-_A-Z0-9]*/g,u=s.match(p);for(let m=0;m<u.length;m++){const b=u[m],h=i[b];h!=null&&(s=s.replace(b,h))}(/\(.*\)/g.test(s)||/[+/\\*]/g.test(s))&&(s=ir(s,n)),t=t.replace(l,s)}return a&&(t=t==null?void 0:t.replace(/\n|\\n/g,"<br/>")),r&&(t=t==null?void 0:t.replace(/\s{2,}?/g,"&nbsp;&nbsp;")),t},Rt=(t,o)=>{var r;if(t==null)return o;const n=t.match(/\{.*\}/g);if(n==null||n.length===0)return o;const a=n.length;for(let i=0;i<a;i++){const c=n[i];if(c==null||c==="")break;let d=(r=c.slice(1,-1))==null?void 0:r.trim();d=d==null?void 0:d.replace(/value/g,o);try{let l=d;(/\(.*\)/g.test(d)||/[+/\\*]/g.test(d))&&(l=ir(d)),t=t.replace(c,l)}catch{t=t.replace(c,d)}}return t},Pf=(t,o,n)=>{switch(t.type){case"bar":return Mf(t,o,n);case"line":return jf(t,o,n);case"pie":return vf(t,o,n);case"comboGraph":return Rf(t,o,n);default:return{}}},Mf=(t,o,n)=>{const a=t.yAxisLabelFormatter,r=t.xAxisLabelFormatter,{dimensions:i=[],dataset:c=[]}=o,d=e.computed(()=>{const s=c,p=s.length,u=[];for(let m=0;m<p;m++){const b={...s[m],type:"bar",barWidth:t.barWidth};t.isStack&&(b.stack="stack"),b.label={show:t.labelShow,fontSize:t.labelFontSize,position:t.labelPosition,color:t.labelColor},u.push(b)}return u}),l=e.computed(()=>i.map(s=>{let p={};return s&&typeof s=="object"?p={...s,textStyle:{fontSize:n}}:p={value:s,textStyle:{fontSize:n}},p}));return{tooltip:{trigger:"axis",show:t.tooltipShow,formatter:s=>{const p=s.length;let u="",m=t.tooltipFormatter;m===""&&(m="{marker} {a} {c}");for(let b=0;b<p;b++){const{marker:h,seriesName:f,name:g,value:w,data:C}=s[b]||{};b===0&&(u+=`${g}<br/>`),u+=yo(m,{textData:{marker:h,name:g,value:w,a:f,b:g,c:w,...C}},{useNewline:!0,useSpace:!0}),u+="<br/>"}return u},textStyle:{color:t.tooltipTextStyleColor,fontSize:n}},legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{color:t.legendTextStyleColor,fontSize:n}},xAxis:{type:t.isUseHorizontalAxis?"value":"category",data:t.isUseHorizontalAxis?null:e.unref(l),inverse:t.isUseHorizontalAxis?t.xAxisInverse:t.axisInverse,minInterval:t.xAxisMinInterval,splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor}},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow,formatter(s){return Rt(r,s)}},axisLine:{lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow}},yAxis:{type:t.isUseHorizontalAxis?"category":"value",data:t.isUseHorizontalAxis?i:null,inverse:t.isUseHorizontalAxis?t.axisInverse:t.yAxisInverse,minInterval:t.yAxisMinInterval,splitLine:{show:t.yAxisSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor}},axisLabel:{fontSize:n,color:t.yAxisLabelColor,rotate:t.yAxisLabelRotate,width:t.yAxisLabelWidth,overflow:t.yAxisLabelOverflow,formatter(s){return Rt(a,s)}},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}}},series:e.unref(d)}},jf=(t,o,n)=>{const a=t.yAxisLabelFormatter,r=t.xAxisLabelFormatter,{dimensions:i=[],dataset:c=[]}=o,d=e.computed(()=>i.map(s=>{let p={};return s&&typeof s=="object"?p={...s,textStyle:{fontSize:n}}:p={value:s,textStyle:{fontSize:n}},p})),l=e.computed(()=>{const s=[],p=c.length;for(let u=0;u<p;u++)s.push({type:"line",...c[u],symbolSize:t.symbolSize,smooth:t.smooth,lineStyle:{width:t.lineStyleWidth}});return s});return{tooltip:{trigger:"axis",textStyle:{fontSize:n},show:t.tooltipShow,formatter:s=>{const p=s.length;let u="",m=t.tooltipFormatter;m===""&&(m="{marker} {a} {c}");for(let b=0;b<p;b++){const{marker:h,seriesName:f,name:g,value:w,data:C}=s[b]||{};b===0&&(u+=`${g}<br/>`),u+=yo(m,{textData:{marker:h,name:g,value:w,a:f,b:g,c:w,...C}},{useNewline:!0,useSpace:!0}),u+="<br/>"}return u}},xAxis:{type:"category",data:e.unref(d),minInterval:t.xAxisMinInterval,splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor}},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow,formatter(s){return Rt(r,s)}},axisLine:{lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow}},yAxis:{type:"value",minInterval:t.yAxisMinInterval,splitLine:{show:t.yAxisSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor}},axisLabel:{fontSize:n,color:t.yAxisLabelColor,formatter(s){return Rt(a,s)}},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}}},legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{fontSize:n}},series:e.unref(l)}},vf=(t,o,n)=>{const{dataset:a=[]}=o;let{data:r=[]}=a[0]||{};if(Array.isArray(t.colors)){const i=t.isUseLabelColors,c=t.colors;r=r.map((d,l)=>({label:i?{color:c[l]}:{},...d}))}return{tooltip:{show:t.tooltipShow,trigger:t.tooltipTrigger,formatter:i=>{const{marker:c,seriesName:d,name:l,value:s,percent:p,data:u}=i||{};return yo(t.tooltipFormatter,{textData:{marker:c,name:l,value:s,percent:p,a:d,b:l,c:s,d:p,...u}},{useNewline:!0,useSpace:!0})},textStyle:{color:t.tooltipTextStyleColor}},legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{color:t.legendTextStyleColor,fontSize:n===18?n:t.labelFontSize}},series:[{data:r,type:"pie",radius:[t.innerRadius,t.outerRadius],center:[t.centerLeft,t.centerTop],roseType:t.roseType,avoidLabelOverlap:!1,minAngle:t.minAngle,label:{show:t.labelPosition!=="center"&&t.labelShow,color:t.labelColor,fontSize:n===18?n:t.labelFontSize,position:t.labelPosition,formatter:xi(t.labelFormatter)},labelLine:{show:t.labelLineShow,length:t.labelLineLength,length2:t.labelLineLength2},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"},label:{}}}]}},Rf=(t,o,n)=>{const{dimensions:a=[],dataset:r=[]}=o,i=e.computed(()=>a.map(l=>{let s={};return l&&typeof l=="object"?s={...l,textStyle:{fontSize:n}}:s={value:l,textStyle:{fontSize:n}},s})),c=e.computed(()=>{const l=[],s=r.length,p=t.seriesTypes;for(let u=0;u<s;u++){const m=p[u];l.push({type:m==null?void 0:m.type,yAxisIndex:m==null?void 0:m.axisIndex,...r[u]})}return l}),d=e.computed(()=>{const l=t.yAxis;return l==null?void 0:l.map(s=>({type:"value",minInterval:t.yAxisMinInterval,splitLine:{show:t.yAxisSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor}},axisLabel:{fontSize:n,color:t.yAxisLabelColor,formatter(p){return Rt(s.axisLabelFormatter,p)}},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}}}))});return{legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{color:t.legendTextStyleColor,fontSize:n}},tooltip:{trigger:"axis",show:t.tooltipShow,formatter:l=>{const s=l.length;let p="",u=t.tooltipFormatter;u===""&&(u="{marker} {a} {c}");const m=t.seriesTypes;for(let b=0;b<s;b++){const h=m[b],{tooltipFormatter:f}=h||{},{marker:g,seriesName:w,name:C,value:x,data:A}=l[b]||{};b===0&&(p+=`${C}<br/>`),p+=yo(f||u,{textData:{marker:g,name:C,value:x,seriesName:w,a:w,b:C,c:x,...A}},{useNewline:!0,useSpace:!0}),p+="<br/>"}return p},textStyle:{color:t.tooltipTextStyleColor,fontSize:n}},xAxis:{minInterval:t.xAxisMinInterval,type:"category",data:e.unref(i),splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor}},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow},axisLine:{lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow}},yAxis:e.unref(d),series:e.unref(c)}},Uf=(t=[],o)=>{let{name:n="name",types:a=[]}=o||{};n=(n==null?void 0:n.trim())||n;const r=new Set,i=new Map,c=t.length,d=a.length;if(c===1){const p=[];for(let m=0;m<d;m++){const b=a[m],{label:h,value:f}=b,g={...t[0],value:t[0][f]};r.add(h),p.push(g)}const u=t[0][n]||"";i.set(u,p)}else for(let p=0;p<c;p++){const u=t[p],m=u[n];r.add(m);for(let b=0;b<d;b++){const h=a[b],{label:f,value:g}=h,w={...u,value:u[g]};if(i.has(f)){const C=i.get(f);C.push(w),i.set(f,C)}else i.set(f,[w])}}const l=Array.from(r),s=[];for(const[p,u]of i)s.push({name:p,data:u});return{dimensions:l,dataset:s}},Gf=(t,o)=>{let{name:n="name",value:a="value",type:r="type"}=o||{};n=n==null?void 0:n.trim(),a=a==null?void 0:a.trim(),r=r==null?void 0:r.trim();const i=new Set,c=new Map,d=t.length;for(let p=0;p<d;p++){const u=t[p],m=u[n]||"",b=u[a]||"",h=u[r]||"";if(i.add(m),c.has(h)){const f=c.get(h);f.push({name:m,value:b,...u}),c.set(h,f)}else c.set(h,[{name:m,value:b,...u}])}const l=Array.from(i),s=[];for(const[p,u]of c)s.push({name:p,data:u});return{dimensions:l,dataset:s}},zf=e.defineComponent({name:"ChartGraph",components:{ASpin:P.Spin},props:{graphicConfig:{type:Object,default:()=>{}},chartsOptions:{type:Object,default:()=>{}}},setup(t,{expose:o}){const n=e.computed(()=>t.chartsOptions?e.unref(t.chartsOptions):l),a=e.computed(()=>t.graphicConfig?e.unref(t.graphicConfig):d),r=e.inject(Oe);let i=null;const c=e.inject(De)||"",d=e.inject(Ce)||{},l=e.inject(Yt)||{},s=e.ref(null),p=e.ref(null),u=e.ref(),m=e.ref(!1),b=e.ref(!1),h=e.computed(()=>b.value?gr:12),f=e.ref({}),g=e.ref(),w=e.computed(()=>{const V=e.unref(n.value);if((V==null?void 0:V.type)==="customGraph")return g.value;const N=Pf(V,e.unref(f),h.value);return{toolbox:{show:V.toolboxShow,left:V.toolboxLeft,top:V.toolboxTop,itemSize:V.toolboxItemSize,itemGap:V.toolboxItemGap,feature:{myDataZoom:{show:b.value?!1:V.toolboxDataZoomShow,title:"放大",icon:"path://M932.42 902.246667L792 761.793333A403.84 403.84 0 0 0 896 490.666667c0-223.86-181.473333-405.333333-405.333333-405.333334S85.333333 266.806667 85.333333 490.666667s181.473333 405.333333 405.333334 405.333333a403.84 403.84 0 0 0 271.126666-104l140.453334 140.453333a21.333333 21.333333 0 0 0 30.173333-30.173333zM128 490.666667c0-200.293333 162.373333-362.666667 362.666667-362.666667s362.666667 162.373333 362.666666 362.666667-162.373333 362.666667-362.666666 362.666666-362.666667-162.373333-362.666667-362.666666z m512 0a21.333333 21.333333 0 0 1-21.333333 21.333333H512v106.666667a21.333333 21.333333 0 0 1-42.666667 0V512H362.666667a21.333333 21.333333 0 0 1 0-42.666667h106.666666V362.666667a21.333333 21.333333 0 0 1 42.666667 0v106.666666h106.666667a21.333333 21.333333 0 0 1 21.333333 21.333334z",onclick(){}},myInfo:{show:V.toolboxInfoShow,title:"说明信息",icon:"path://M512.50142 958.397886c-119.320573 0-231.499491-46.465265-315.871087-130.837884C112.258737 743.188406 65.792449 631.010511 65.792449 511.688915c0-119.319549 46.466288-231.499491 130.837884-315.871087C281.002952 111.445208 393.180847 64.979944 512.50142 64.979944s231.499491 46.465265 315.871087 130.837884c84.372619 84.372619 130.837884 196.551538 130.837884 315.871087 0 119.321596-46.465265 231.499491-130.837884 315.871087C744.000911 911.932622 631.821993 958.397886 512.50142 958.397886zM512.50142 105.962334c-223.718271 0-405.726581 182.00831-405.726581 405.726581s182.00831 405.726581 405.726581 405.726581c223.718271 0 405.727605-182.00831 405.727605-405.726581S736.220714 105.962334 512.50142 105.962334z M510.150886 775.953647c-18.107403 0-32.745798-14.678304-32.745798-32.785707L477.405087 452.191846c0-18.108426 14.638395-32.785707 32.745798-32.785707 18.107403 0 32.745798 14.678304 32.745798 32.785707l0 290.976094C542.896684 761.275343 528.258289 775.953647 510.150886 775.953647z M511.357364 296.458969m-45.080731 0a44.054 44.054 0 1 0 90.161463 0 44.054 44.054 0 1 0-90.161463 0Z",onclick(){}}}},title:{text:V.titleText,subtext:V.titleSubtext,left:"center"},grid:{top:V.gridTop,bottom:V.gridBottom,left:V.gridLeft,right:V.gridRight,containLabel:V.gridContainLabel},color:V.colors,...N}}),C=(V=[],N,I=!1)=>{const M=I?N:null;f.value=Uf(V,M)},x=(V=[],N)=>{f.value=Gf(V,N)},A=async()=>{var V,N,I;try{const M=$f({graphicConfig:e.unref(a.value),type:(V=e.unref(n.value))==null?void 0:V.type,request:r,indicatorToken:c});m.value=!0;const j=await M(),{columns:B=[],rows:F=[]}=((N=j==null?void 0:j.data)==null?void 0:N.data)??{};if(((I=e.unref(n.value))==null?void 0:I.type)==="pie"){let O=[];if(B.length>0){const G=B[0],R=B[1];O=F.map(S=>({name:S[G],value:S[R]}))}x(O)}else{let O;B.length>0&&(O={name:B[0],types:B.slice(1).map(G=>({label:G,value:G}))}),C(F,O,!0)}}catch(M){console.error(M)}finally{m.value=!1}},y={title:{text:"暂无数据",x:"center",y:"center",textStyle:{fontSize:14,fontWeight:"normal"}}},_=()=>{e.unref(f).dataset.length===0?u.value.setOption(y):u.value.setOption(w.value)},E=()=>{e.unref(n.value).type!=="customGraph"&&A()},T=()=>{var V;(V=u.value)==null||V.resize()};return e.watch(w,()=>{_()},{deep:!0}),e.watch(()=>e.unref(n.value).optionCode,V=>{try{const N=eval;g.value=N(V)}catch(N){console.error(N)}},{immediate:!0}),e.onMounted(()=>{p.value&&(i=new ResizeObserver(T),i.observe(p.value)),u.value=yr.init(s.value)}),e.onBeforeUnmount(()=>{u.value.dispose(),i&&(i.disconnect(),i=null)}),o({refreshData:E}),{echartRef:s,loading:m}}}),Qm="",Hf={class:"ecan-chart-graph",ref:"chartWrapRef"},Yf={style:{width:"100%",height:"100%"},ref:"echartRef"};function Wf(t,o,n,a,r,i){const c=e.resolveComponent("a-spin");return e.openBlock(),e.createElementBlock("div",Hf,[e.createVNode(c,{spinning:t.loading,wrapperClassName:"chart-spin",tip:"数据加载中..."},{default:e.withCtx(()=>[e.createElementVNode("div",Yf,null,512)]),_:1},8,["spinning"])],512)}const sr=ne(zf,[["render",Wf],["__scopeId","data-v-8049fed2"]]),qf=e.defineComponent({name:"DataConfig",components:{DataGroup:Fd,StyleGroup:nf,ChartGraph:sr,ATabs:P.Tabs,ATabPane:P.TabPane,ControlGroup:_f,VariableGroup:Ff,AButton:P.Button,ReloadOutlined:Ci},setup(){var E;const t=e.ref("1"),o=e.ref([0,1,2]),n=e.ref(),a=e.inject(Ye),r=e.inject(yn),i=e.inject(Ce),c=e.inject(ve),d=e.inject(_n),l=["text","proportion","select","checkbox","radio","radar","circulate"],s=e.computed(()=>{const T=ee.cloneDeep(e.unref(a));p(T);const V=ee.pick(T,ee.without(Object.keys(T),"position","top","left","width","height"));ge(T.type,l)?(V.height=T.height,V.width=T.width):V.height="290px";const N=ee.cloneDeep(e.unref(i));return N.pageMode="design",N.componentList=c,N.preview=!0,N.pageConfig=d,{...V,graphicConfig:N,toolboxShow:!1,sourceLeft:T.left,sourceTop:T.top}});function p(T){var V,N,I,M;["#ffffff","#fff"].includes((V=T==null?void 0:T.color)==null?void 0:V.toLowerCase())&&(T.color="#000"),["#ffffff","#fff"].includes((N=T==null?void 0:T.variableColor)==null?void 0:N.toLowerCase())&&(T.variableColor="#000"),["#ffffff","#fff"].includes((I=T==null?void 0:T.increaseColor)==null?void 0:I.toLowerCase())&&(T.increaseColor="#000"),["#ffffff","#fff"].includes((M=T==null?void 0:T.declineColor)==null?void 0:M.toLowerCase())&&(T.declineColor="#000")}const u=e.computed(()=>{let T=!0;return ge(e.unref(s).type,l)&&(T=!1),T}),m=e.computed(()=>{var T;return(T=e.unref(s))==null?void 0:T.type}),b=e.computed(()=>{var T;return!!((T=e.unref(s))!=null&&T.isGroupTable)}),h=T=>{const V=T==="1";V&&m.value==="table"&&A(),window.changeShowTable&&window.changeShowTable(V),T==="3"&&x()},f=e.ref(),g=e.inject(Oe),w=e.unref(e.inject(De)),C=(E=window==null?void 0:window.config)==null?void 0:E.pageId;function x(){var B;const{leftAxisList:T=[],rightAxisList:V=[],queryColumnList:N=[],indicators:I=[]}=e.unref(i),M=[...T,...V,...N,...I],j={};for(const F of M){const{id:O="",indexCode:G=""}=F;O&&!gt(F,"calcType")&&!j[O]&&(j[O]=G)}if((B=Object.keys(j))!=null&&B.length){const F=[];for(const O in j)F.push(new Promise((G,R)=>{g.post(`${_e}/diagram/hrpIndexWithComplex`,{pageId:C,indexGuid:O,indexCode:j[O],dataSourceId:""},{headers:{Authentication:w,operateContext:"ygt"}}).then(S=>{var D;const{success:L,data:k=[]}=S.data;L&&((D=k==null?void 0:k.dataViewColumns)!=null&&D.length)?G(k.dataViewColumns):R(k)}).catch(S=>{R(S)})}));Promise.all(F).then(O=>{if(O!=null&&O.length){const G=O.reduce((R,S)=>R.filter(L=>S.find(k=>k.typeGuid===L.typeGuid)));f.value=G.filter(R=>R.typeGuid)}})}}const A=()=>{var V;let T;r&&m.value==="table"?T=window.updateConfig:T=(V=e.unref(n))==null?void 0:V.refreshData,typeof T=="function"&&T()},y=e.inject(xe),_=()=>{var T;y({variableConditions:Lt(((T=e.unref(i))==null?void 0:T.variableList)||[],c)})};return e.provide(gn,A),e.watch(i,()=>{A()},{deep:!0,flush:"post"}),{isShowStyleConfig:r,activeKey:t,activePanel:o,componentRef:n,type:m,isGroupTable:b,onChange:h,component:s,fullWidth:u,renderUsedComponents:c,intersection:f,refreshData:A,refreshAction:_}}}),Xm="",Kf={class:"data-config"},Qf={key:0,id:"table-wrap",class:"chart-component",ref:"tableWrapRef",style:{width:"100%",height:"290px"}};function Xf(t,o,n,a,r,i){const c=e.resolveComponent("data-group"),d=e.resolveComponent("a-tab-pane"),l=e.resolveComponent("style-group"),s=e.resolveComponent("control-group"),p=e.resolveComponent("variable-group"),u=e.resolveComponent("reload-outlined"),m=e.resolveComponent("a-button"),b=e.resolveComponent("a-tabs"),h=e.resolveComponent("chart-graph");return e.openBlock(),e.createElementBlock("div",Kf,[e.createVNode(b,{activeKey:t.activeKey,"onUpdate:activeKey":o[0]||(o[0]=f=>t.activeKey=f),onChange:t.onChange},{rightExtra:e.withCtx(()=>[e.createVNode(m,{onClick:t.refreshAction},{icon:e.withCtx(()=>[e.createVNode(u)]),default:e.withCtx(()=>[e.createTextVNode(" 刷新 ")]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(d,{key:"1",tab:"数据配置"},{default:e.withCtx(()=>[e.createVNode(c),t.isShowStyleConfig?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.type),e.mergeProps({key:0,class:["chart-component",t.fullWidth?"full-width":""]},t.component,{ref:"componentRef"}),null,16,["class"]))]),_:1}),t.isShowStyleConfig?(e.openBlock(),e.createBlock(d,{key:"2",tab:"样式配置","force-render":""},{default:e.withCtx(()=>[e.createVNode(l,{componentType:t.type,isGroupTable:t.isGroupTable},null,8,["componentType","isGroupTable"])]),_:1})):e.createCommentVNode("",!0),t.renderUsedComponents?(e.openBlock(),e.createBlock(d,{key:"3",tab:"全局过滤","force-render":""},{default:e.withCtx(()=>[e.createVNode(s,{ref:"controlGroup",intersection:t.intersection},null,8,["intersection"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(d,{key:"4",tab:"全局变量","force-render":""},{default:e.withCtx(()=>[e.createVNode(p)]),_:1})]),_:1},8,["activeKey","onChange"]),t.isShowStyleConfig?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.type==="table"&&t.activeKey==="1"?(e.openBlock(),e.createElementBlock("div",Qf,null,512)):e.withDirectives((e.openBlock(),e.createBlock(h,{key:1,class:e.normalizeClass(["chart-component",t.fullWidth?"full-width":""]),ref:"componentRef",style:{width:"100%",height:"290px"}},null,8,["class"])),[[e.vShow,t.activeKey==="1"]])],64)):e.createCommentVNode("",!0)])}const Jf=ne(qf,[["render",Xf],["__scopeId","data-v-d85f4e1e"]]),Zf=e.defineComponent({name:"IndicatorLibrary",components:{DataList:ns,DataConfig:Jf},props:{isShowStyleConfig:{type:Boolean,default:!1},sourceType:{type:String,default:""},indicatorToken:{type:String,default:""},selectedComponent:{type:Object,default:()=>{}},request:{default:null},renderUsedComponentList:{type:Array,default:()=>[]},mapAttributeProps:{type:Object,default:()=>{}},pageConfig:{type:Object,default:()=>{}}},setup(t,{expose:o,emit:n}){const a=e.ref(!1),r=e.computed(()=>t.sourceType),i=e.computed(()=>t.indicatorToken||""),c=e.computed(()=>t.selectedComponent),d=e.computed(()=>{var y;return((y=e.unref(c))==null?void 0:y.tableColumns)||[]}),l=e.computed(()=>t.isShowStyleConfig);let s=e.unref(c).graphicConfig?ee.cloneDeep(e.unref(c).graphicConfig):e.ref({});s=e.ref(s);let p=e.unref(c).chartsOptions?ee.cloneDeep(e.unref(c).chartsOptions):e.ref(ee.cloneDeep(Sn.line));p=e.ref(p);let u=e.unref(c).tableOptions?ee.cloneDeep(e.unref(c).tableOptions):e.ref(ee.cloneDeep(br));u=e.ref(u);const m=e.ref([]),b=y=>{m.value=y},h=y=>{s.value={...e.unref(s),...e.unref(y)}},f=(y,_=!0)=>{_?p.value={...e.unref(p),...e.unref(y)}:p.value={...e.unref(y)}},g=y=>{u.value={...e.unref(u),...e.unref(y)}},w=()=>m,C=()=>{a.value=!0,e.unref(c).graphicConfig&&(s.value=ee.cloneDeep(e.unref(c).graphicConfig)),e.unref(c).chartsOptions&&(p.value=ee.cloneDeep(e.unref(c).chartsOptions)),e.nextTick(()=>{a.value=!1})},x=()=>({graphicConfig:e.unref(s),chartsOptions:e.unref(p),tableOptions:e.unref(u),tableColumns:e.unref(d)});window.getIndicatorData=x,t.request&&e.provide(Oe,t.request),e.provide(hn,{setDataList:b,getDataList:w});const A=y=>{n("updateUsedComponent",y)};return e.provide(Ye,c),e.provide(Ce,s),e.provide(Yt,p),e.provide(bn,u),e.provide(At,r),e.provide(yn,l),e.provide(De,i),e.provide(xe,h),e.provide(bo,f),e.provide(Co,g),e.provide(ve,t.renderUsedComponentList),e.provide(Wt,A),e.provide(kn,t.mapAttributeProps),e.provide(_n,t.pageConfig),o({graphicConfig:s,chartsOptions:p,updateIndicatorData:C}),{isUpdate:a}}}),Jm="",em={key:0,class:"config-modal"},tm={class:"config-modal-left"},om={class:"config-modal-right"};function nm(t,o,n,a,r,i){const c=e.resolveComponent("data-list"),d=e.resolveComponent("data-config");return t.isUpdate?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",em,[e.createElementVNode("div",tm,[e.createVNode(c)]),e.createElementVNode("div",om,[e.createVNode(d)])]))}const cr=mn(ne(Zf,[["render",nm],["__scopeId","data-v-23d542ce"]])),dr=mn(sr),pr=Object.freeze(Object.defineProperty({__proto__:null,EcanChartGraph:dr,EcanIndicatorLibrary:cr},Symbol.toStringTag,{value:"Module"})),am={install:(t,o)=>{const{request:n}=o;t.provide("$request",n),Object.keys(pr).forEach(a=>{const r=pr[a];r.install&&t.use(r)})}};ke.EcanChartGraph=dr,ke.EcanIndicatorLibrary=cr,ke.default=am,Object.defineProperties(ke,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
56
+ `,Ea=!1,Bi=function(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ei;e.nextTick(function(){Ea||(typeof window<"u"&&window.document&&window.document.documentElement&&Ni(o,{prepend:!0}),Ea=!0)})},Vi=["icon","primaryColor","secondaryColor"];function Li(t,o){if(t==null)return{};var n=vi(t,o),a,l;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(l=0;l<r.length;l++)a=r[l],!(o.indexOf(a)>=0)&&Object.prototype.propertyIsEnumerable.call(t,a)&&(n[a]=t[a])}return n}function vi(t,o){if(t==null)return{};var n={},a=Object.keys(t),l,r;for(r=0;r<a.length;r++)l=a[r],!(o.indexOf(l)>=0)&&(n[l]=t[l]);return n}function No(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){$i(t,l,n[l])})}return t}function $i(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Kt={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function Fi(t){var o=t.primaryColor,n=t.secondaryColor;Kt.primaryColor=o,Kt.secondaryColor=n||Aa(o),Kt.calculated=!!n}function Ii(){return No({},Kt)}var Bt=function(o,n){var a=No({},o,n.attrs),l=a.icon,r=a.primaryColor,s=a.secondaryColor,d=Li(a,Vi),i=Kt;if(r&&(i={primaryColor:r,secondaryColor:s||Aa(r)}),Bi(),Oi(Ta(l),"icon should be icon definiton, but got ".concat(l)),!Ta(l))return null;var c=l;return c&&typeof c.icon=="function"&&(c=No({},c,{icon:c.icon(i.primaryColor,i.secondaryColor)})),an(c.icon,"svg-".concat(c.name),No({},d,{"data-icon":c.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"}))};Bt.props={icon:Object,primaryColor:String,secondaryColor:String,focusable:String},Bt.inheritAttrs=!1,Bt.displayName="IconBase",Bt.getTwoToneColors=Ii,Bt.setTwoToneColors=Fi;const ln=Bt;function Di(t,o){return Ri(t)||ji(t,o)||Pi(t,o)||Mi()}function Mi(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
57
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Pi(t,o){if(t){if(typeof t=="string")return Ba(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ba(t,o)}}function Ba(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function ji(t,o){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a=[],l=!0,r=!1,s,d;try{for(n=n.call(t);!(l=(s=n.next()).done)&&(a.push(s.value),!(o&&a.length===o));l=!0);}catch(i){r=!0,d=i}finally{try{!l&&n.return!=null&&n.return()}finally{if(r)throw d}}return a}}function Ri(t){if(Array.isArray(t))return t}function Va(t){var o=Oa(t),n=Di(o,2),a=n[0],l=n[1];return ln.setTwoToneColors({primaryColor:a,secondaryColor:l})}function Ui(){var t=ln.getTwoToneColors();return t.calculated?[t.primaryColor,t.secondaryColor]:t.primaryColor}var zi=["class","icon","spin","rotate","tabindex","twoToneColor","onClick"];function Gi(t,o){return qi(t)||Yi(t,o)||Wi(t,o)||Hi()}function Hi(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
58
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wi(t,o){if(t){if(typeof t=="string")return La(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return La(t,o)}}function La(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function Yi(t,o){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a=[],l=!0,r=!1,s,d;try{for(n=n.call(t);!(l=(s=n.next()).done)&&(a.push(s.value),!(o&&a.length===o));l=!0);}catch(i){r=!0,d=i}finally{try{!l&&n.return!=null&&n.return()}finally{if(r)throw d}}return a}}function qi(t){if(Array.isArray(t))return t}function va(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){rn(t,l,n[l])})}return t}function rn(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}function Ki(t,o){if(t==null)return{};var n=Xi(t,o),a,l;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(l=0;l<r.length;l++)a=r[l],!(o.indexOf(a)>=0)&&Object.prototype.propertyIsEnumerable.call(t,a)&&(n[a]=t[a])}return n}function Xi(t,o){if(t==null)return{};var n={},a=Object.keys(t),l,r;for(r=0;r<a.length;r++)l=a[r],!(o.indexOf(l)>=0)&&(n[l]=t[l]);return n}Va("#1890ff");var Vt=function(o,n){var a,l=va({},o,n.attrs),r=l.class,s=l.icon,d=l.spin,i=l.rotate,c=l.tabindex,p=l.twoToneColor,u=l.onClick,f=Ki(l,zi),y=(a={anticon:!0},rn(a,"anticon-".concat(s.name),!!s.name),rn(a,r,r),a),h=d===""||d||s.name==="loading"?"anticon-spin":"",b=c;b===void 0&&u&&(b=-1,f.tabindex=b);var m=i?{msTransform:"rotate(".concat(i,"deg)"),transform:"rotate(".concat(i,"deg)")}:void 0,w=Oa(p),g=Gi(w,2),S=g[0],C=g[1];return e.createVNode("span",va({role:"img","aria-label":s.name},f,{onClick:u,class:y}),[e.createVNode(ln,{class:h,icon:s,primaryColor:S,secondaryColor:C,style:m},null)])};Vt.props={spin:Boolean,rotate:Number,icon:Object,twoToneColor:String},Vt.displayName="AntdIcon",Vt.inheritAttrs=!1,Vt.getTwoToneColor=Ui,Vt.setTwoToneColor=Va;const xe=Vt;var Qi={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H212V212h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H612V212h200v200zm52 132H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H612V612h200v200zM424 712H296V584c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v128H104c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h128v128c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V776h128c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}}]},name:"appstore-add",theme:"outlined"};const Ji=Qi;function $a(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Zi(t,l,n[l])})}return t}function Zi(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var sn=function(o,n){var a=$a({},o,n.attrs);return e.createVNode(xe,$a({},a,{icon:Ji}),null)};sn.displayName="AppstoreAddOutlined",sn.inheritAttrs=!1;const cn=sn;var es={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"outlined"};const ts=es;function Fa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){os(t,l,n[l])})}return t}function os(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var dn=function(o,n){var a=Fa({},o,n.attrs);return e.createVNode(xe,Fa({},a,{icon:ts}),null)};dn.displayName="CaretDownOutlined",dn.inheritAttrs=!1;const Ia=dn;var ns={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M715.8 493.5L335 165.1c-14.2-12.2-35-1.2-35 18.5v656.8c0 19.7 20.8 30.7 35 18.5l380.8-328.4c10.9-9.4 10.9-27.6 0-37z"}}]},name:"caret-right",theme:"outlined"};const as=ns;function Da(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){ls(t,l,n[l])})}return t}function ls(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var pn=function(o,n){var a=Da({},o,n.attrs);return e.createVNode(xe,Da({},a,{icon:as}),null)};pn.displayName="CaretRightOutlined",pn.inheritAttrs=!1;const Ma=pn;var rs={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"};const is=rs;function Pa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){ss(t,l,n[l])})}return t}function ss(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var un=function(o,n){var a=Pa({},o,n.attrs);return e.createVNode(xe,Pa({},a,{icon:is}),null)};un.displayName="CloseOutlined",un.inheritAttrs=!1;const Xt=un;var cs={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M516 673c0 4.4 3.4 8 7.5 8h185c4.1 0 7.5-3.6 7.5-8v-48c0-4.4-3.4-8-7.5-8h-185c-4.1 0-7.5 3.6-7.5 8v48zm-194.9 6.1l192-161c3.8-3.2 3.8-9.1 0-12.3l-192-160.9A7.95 7.95 0 00308 351v62.7c0 2.4 1 4.6 2.9 6.1L420.7 512l-109.8 92.2a8.1 8.1 0 00-2.9 6.1V673c0 6.8 7.9 10.5 13.1 6.1zM880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"code",theme:"outlined"};const ds=cs;function ja(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){ps(t,l,n[l])})}return t}function ps(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var fn=function(o,n){var a=ja({},o,n.attrs);return e.createVNode(xe,ja({},a,{icon:ds}),null)};fn.displayName="CodeOutlined",fn.inheritAttrs=!1;const us=fn;var fs={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M832 64H296c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h496v688c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V96c0-17.7-14.3-32-32-32zM704 192H192c-17.7 0-32 14.3-32 32v530.7c0 8.5 3.4 16.6 9.4 22.6l173.3 173.3c2.2 2.2 4.7 4 7.4 5.5v1.9h4.2c3.5 1.3 7.2 2 11 2H704c17.7 0 32-14.3 32-32V224c0-17.7-14.3-32-32-32zM350 856.2L263.9 770H350v86.2zM664 888H414V746c0-22.1-17.9-40-40-40H232V264h432v624z"}}]},name:"copy",theme:"outlined"};const ms=fs;function Ra(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){hs(t,l,n[l])})}return t}function hs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var mn=function(o,n){var a=Ra({},o,n.attrs);return e.createVNode(xe,Ra({},a,{icon:ms}),null)};mn.displayName="CopyOutlined",mn.inheritAttrs=!1;const bs=mn;var ys={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};const gs=ys;function Ua(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Cs(t,l,n[l])})}return t}function Cs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var hn=function(o,n){var a=Ua({},o,n.attrs);return e.createVNode(xe,Ua({},a,{icon:gs}),null)};hn.displayName="DeleteOutlined",hn.inheritAttrs=!1;const za=hn;var ws={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"};const ks=ws;function Ga(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){xs(t,l,n[l])})}return t}function xs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var bn=function(o,n){var a=Ga({},o,n.attrs);return e.createVNode(xe,Ga({},a,{icon:ks}),null)};bn.displayName="DoubleRightOutlined",bn.inheritAttrs=!1;const _s=bn;var Ss={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};const Ns=Ss;function Ha(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Ts(t,l,n[l])})}return t}function Ts(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var yn=function(o,n){var a=Ha({},o,n.attrs);return e.createVNode(xe,Ha({},a,{icon:Ns}),null)};yn.displayName="DownOutlined",yn.inheritAttrs=!1;const As=yn;var Os={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"};const Es=Os;function Wa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Bs(t,l,n[l])})}return t}function Bs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var gn=function(o,n){var a=Wa({},o,n.attrs);return e.createVNode(xe,Wa({},a,{icon:Es}),null)};gn.displayName="InfoCircleOutlined",gn.inheritAttrs=!1;const Vs=gn;var Ls={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};const vs=Ls;function Ya(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){$s(t,l,n[l])})}return t}function $s(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Cn=function(o,n){var a=Ya({},o,n.attrs);return e.createVNode(xe,Ya({},a,{icon:vs}),null)};Cn.displayName="LoadingOutlined",Cn.inheritAttrs=!1;const Fs=Cn;var Is={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M904 160H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8zm0 624H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8zm0-312H120c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8z"}}]},name:"menu",theme:"outlined"};const Ds=Is;function qa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Ms(t,l,n[l])})}return t}function Ms(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var wn=function(o,n){var a=qa({},o,n.attrs);return e.createVNode(xe,qa({},a,{icon:Ds}),null)};wn.displayName="MenuOutlined",wn.inheritAttrs=!1;const kn=wn;var Ps={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"minus-circle",theme:"outlined"};const js=Ps;function Ka(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Rs(t,l,n[l])})}return t}function Rs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var xn=function(o,n){var a=Ka({},o,n.attrs);return e.createVNode(xe,Ka({},a,{icon:js}),null)};xn.displayName="MinusCircleOutlined",xn.inheritAttrs=!1;const Us=xn;var zs={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"plus-circle",theme:"outlined"};const Gs=zs;function Xa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Hs(t,l,n[l])})}return t}function Hs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var _n=function(o,n){var a=Xa({},o,n.attrs);return e.createVNode(xe,Xa({},a,{icon:Gs}),null)};_n.displayName="PlusCircleOutlined",_n.inheritAttrs=!1;const Ws=_n;var Ys={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"};const qs=Ys;function Qa(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Ks(t,l,n[l])})}return t}function Ks(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Sn=function(o,n){var a=Qa({},o,n.attrs);return e.createVNode(xe,Qa({},a,{icon:qs}),null)};Sn.displayName="PlusOutlined",Sn.inheritAttrs=!1;const Xs=Sn;var Qs={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"};const Js=Qs;function Ja(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){Zs(t,l,n[l])})}return t}function Zs(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Nn=function(o,n){var a=Ja({},o,n.attrs);return e.createVNode(xe,Ja({},a,{icon:Js}),null)};Nn.displayName="QuestionCircleOutlined",Nn.inheritAttrs=!1;const ec=Nn;var tc={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.1 209.3l-56.4 44.1C775.8 155.1 656.2 92 521.9 92 290 92 102.3 279.5 102 511.5 101.7 743.7 289.8 932 521.9 932c181.3 0 335.8-115 394.6-276.1 1.5-4.2-.7-8.9-4.9-10.3l-56.7-19.5a8 8 0 00-10.1 4.8c-1.8 5-3.8 10-5.9 14.9-17.3 41-42.1 77.8-73.7 109.4A344.77 344.77 0 01655.9 829c-42.3 17.9-87.4 27-133.8 27-46.5 0-91.5-9.1-133.8-27A341.5 341.5 0 01279 755.2a342.16 342.16 0 01-73.7-109.4c-17.9-42.4-27-87.4-27-133.9s9.1-91.5 27-133.9c17.3-41 42.1-77.8 73.7-109.4 31.6-31.6 68.4-56.4 109.3-73.8 42.3-17.9 87.4-27 133.8-27 46.5 0 91.5 9.1 133.8 27a341.5 341.5 0 01109.3 73.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.6 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c-.1-6.6-7.8-10.3-13-6.2z"}}]},name:"reload",theme:"outlined"};const oc=tc;function Za(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){nc(t,l,n[l])})}return t}function nc(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Tn=function(o,n){var a=Za({},o,n.attrs);return e.createVNode(xe,Za({},a,{icon:oc}),null)};Tn.displayName="ReloadOutlined",Tn.inheritAttrs=!1;const ac=Tn;var lc={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z"}}]},name:"setting",theme:"outlined"};const rc=lc;function el(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?Object(arguments[o]):{},a=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(a=a.concat(Object.getOwnPropertySymbols(n).filter(function(l){return Object.getOwnPropertyDescriptor(n,l).enumerable}))),a.forEach(function(l){ic(t,l,n[l])})}return t}function ic(t,o,n){return o in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var An=function(o,n){var a=el({},o,n.attrs);return e.createVNode(xe,el({},a,{icon:rc}),null)};An.displayName="SettingOutlined",An.inheritAttrs=!1;const sc=An,tl=()=>{},On=Object.assign,ol=Array.isArray,To=t=>typeof t=="function",cc=t=>typeof t=="symbol";let nl;const En=()=>nl||(nl=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),al=t=>{const o=new Set(t);return o.w=0,o.n=0,o},ll=t=>(t.w&rt)>0,rl=t=>(t.n&rt)>0;let Qt=0,rt=1,Le;class dc{constructor(o,n=null,a){this.fn=o,this.scheduler=n,this.active=!0,this.deps=[],this.parent=void 0,function(l,r){r&&r.active&&r.effects.push(l)}(this,a)}run(){if(!this.active)return this.fn();let o=Le,n=mt;for(;o;){if(o===this)return;o=o.parent}try{return this.parent=Le,Le=this,mt=!0,rt=1<<++Qt,Qt<=30?(({deps:a})=>{if(a.length)for(let l=0;l<a.length;l++)a[l].w|=rt})(this):il(this),this.fn()}finally{Qt<=30&&(a=>{const{deps:l}=a;if(l.length){let r=0;for(let s=0;s<l.length;s++){const d=l[s];ll(d)&&!rl(d)?d.delete(a):l[r++]=d,d.w&=~rt,d.n&=~rt}l.length=r}})(this),rt=1<<--Qt,Le=this.parent,mt=n,this.parent=void 0,this.deferStop&&this.stop()}}stop(){Le===this?this.deferStop=!0:this.active&&(il(this),this.onStop&&this.onStop(),this.active=!1)}}function il(t){const{deps:o}=t;if(o.length){for(let n=0;n<o.length;n++)o[n].delete(t);o.length=0}}let mt=!0;const sl=[];function cl(t,o){let n=!1;Qt<=30?rl(t)||(t.n|=rt,n=!ll(t)):n=!t.has(Le),n&&(t.add(Le),Le.deps.push(t),process.env.NODE_ENV!=="production"&&Le.onTrack&&Le.onTrack(On({effect:Le},o)))}function dl(t,o){const n=ol(t)?t:[...t];for(const a of n)a.computed&&pl(a,o);for(const a of n)a.computed||pl(a,o)}function pl(t,o){(t!==Le||t.allowRecurse)&&(process.env.NODE_ENV!=="production"&&t.onTrigger&&t.onTrigger(On({effect:t},o)),t.scheduler?t.scheduler():t.run())}function Lt(t){const o=t&&t.__v_raw;return o?Lt(o):t}function ul(t){return!(!t||t.__v_isRef!==!0)}function it(t){return ul(t)?t.value:t}new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(cc));class pc{constructor(o,n,a,l){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new dc(o,()=>{this._dirty||(this._dirty=!0,function(r,s){const d=(r=Lt(r)).dep;d&&(process.env.NODE_ENV!=="production"?dl(d,{target:r,type:"set",key:"value",newValue:s}):dl(d))}(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!l,this.__v_isReadonly=a}get value(){const o=Lt(this);var n;return n=o,mt&&Le&&(n=Lt(n),process.env.NODE_ENV!=="production"?cl(n.dep||(n.dep=al()),{target:n,type:"get",key:"value"}):cl(n.dep||(n.dep=al()))),!o._dirty&&o._cacheable||(o._dirty=!1,o._value=o.effect.run()),o._value}set value(o){this._setter(o)}}const ht=[];function Bn(t,...o){if(process.env.NODE_ENV==="production")return;sl.push(mt),mt=!1;const n=ht.length?ht[ht.length-1].component:null,a=n&&n.appContext.config.warnHandler,l=function(){let r=ht[ht.length-1];if(!r)return[];const s=[];for(;r;){const d=s[0];d&&d.vnode===r?d.recurseCount++:s.push({vnode:r,recurseCount:0});const i=r.component&&r.component.parent;r=i&&i.vnode}return s}();if(a)Vn(a,n,11,[t+o.join(""),n&&n.proxy,l.map(({vnode:r})=>`at <${kl(n,r.type)}>`).join(`
59
+ `),l]);else{const r=[`[Vue warn]: ${t}`,...o];l.length&&r.push(`
60
+ `,...function(s){const d=[];return s.forEach((i,c)=>{d.push(...c===0?[]:[`
61
+ `],...function({vnode:p,recurseCount:u}){const f=u>0?`... (${u} recursive calls)`:"",y=!!p.component&&p.component.parent==null,h=` at <${kl(p.component,p.type,y)}`,b=">"+f;return p.props?[h,...uc(p.props),b]:[h+b]}(i))}),d}(l)),console.warn(...r)}(function(){const r=sl.pop();mt=r===void 0||r})()}function uc(t){const o=[],n=Object.keys(t);return n.slice(0,3).forEach(a=>{o.push(...fl(a,t[a]))}),n.length>3&&o.push(" ..."),o}function fl(t,o,n){return typeof o=="string"?(o=JSON.stringify(o),n?o:[`${t}=${o}`]):typeof o=="number"||typeof o=="boolean"||o==null?n?o:[`${t}=${o}`]:ul(o)?(o=fl(t,Lt(o.value),!0),n?o:[`${t}=Ref<`,o,">"]):To(o)?[`${t}=fn${o.name?`<${o.name}>`:""}`]:(o=Lt(o),n?o:[`${t}=`,o])}const ml={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/core"};function Vn(t,o,n,a){let l;try{l=a?t(...a):t()}catch(r){(function(s,d,i,c=!0){const p=d?d.vnode:null;if(d){let u=d.parent;const f=d.proxy,y=process.env.NODE_ENV!=="production"?ml[i]:i;for(;u;){const b=u.ec;if(b){for(let m=0;m<b.length;m++)if(b[m](s,f,y)===!1)return}u=u.parent}const h=d.appContext.config.errorHandler;if(h)return void Vn(h,null,10,[s,f,y])}(function(u,f,y,h=!0){if(process.env.NODE_ENV!=="production"){const m=ml[f];if(y&&(b=y,ht.push(b)),Bn("Unhandled error"+(m?` during execution of ${m}`:"")),y&&ht.pop(),h)throw u;console.error(u)}else console.error(u);var b})(s,i,p,c)})(r,o,n)}return l}let Ao=!1,Ln=!1;const Ge=[];let st=0;const vt=[];let He=null,ct=0;const fc=Promise.resolve();function mc(t){Ge.length&&Ge.includes(t,Ao&&t.allowRecurse?st+1:st)||(t.id==null?Ge.push(t):Ge.splice(function(o){let n=st+1,a=Ge.length;for(;n<a;){const l=n+a>>>1,r=Ge[l],s=Jt(r);s<o||s===o&&r.pre?n=l+1:a=l}return n}(t.id),0,t),hl())}function hl(){Ao||Ln||(Ln=!0,fc.then(bl))}const Jt=t=>t.id==null?1/0:t.id,hc=(t,o)=>{const n=Jt(t)-Jt(o);if(n===0){if(t.pre&&!o.pre)return-1;if(o.pre&&!t.pre)return 1}return n};function bl(t){Ln=!1,Ao=!0,process.env.NODE_ENV!=="production"&&(t=t||new Map),Ge.sort(hc);const o=process.env.NODE_ENV!=="production"?n=>yl(t,n):tl;try{for(st=0;st<Ge.length;st++){const n=Ge[st];if(n&&n.active!==!1){if(process.env.NODE_ENV!=="production"&&o(n))continue;Vn(n,null,14)}}}finally{st=0,Ge.length=0,function(n){if(vt.length){const a=[...new Set(vt)];if(vt.length=0,He)return void He.push(...a);for(He=a,process.env.NODE_ENV!=="production"&&(n=n||new Map),He.sort((l,r)=>Jt(l)-Jt(r)),ct=0;ct<He.length;ct++)process.env.NODE_ENV!=="production"&&yl(n,He[ct])||He[ct]();He=null,ct=0}}(t),Ao=!1,(Ge.length||vt.length)&&bl(t)}}function yl(t,o){if(t.has(o)){const n=t.get(o);if(n>100){const a=o.ownerInstance,l=a&&wl(a.type);return Bn(`Maximum recursive updates exceeded${l?` in component <${l}>`:""}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`),!0}t.set(o,n+1)}else t.set(o,1)}const Zt=new Set;process.env.NODE_ENV!=="production"&&(En().__VUE_HMR_RUNTIME__={createRecord:vn(function(t,o){return Oo.has(t)?!1:(Oo.set(t,{initialDef:eo(o),instances:new Set}),!0)}),rerender:vn(function(t,o){const n=Oo.get(t);n&&(n.initialDef.render=o,[...n.instances].forEach(a=>{o&&(a.render=o,eo(a.type).render=o),a.renderCache=[],a.update()}))}),reload:vn(function(t,o){const n=Oo.get(t);if(!n)return;o=eo(o),gl(n.initialDef,o);const a=[...n.instances];for(const r of a){const s=eo(r.type);Zt.has(s)||(s!==n.initialDef&&gl(s,o),Zt.add(s)),r.appContext.propsCache.delete(r.type),r.appContext.emitsCache.delete(r.type),r.appContext.optionsCache.delete(r.type),r.ceReload?(Zt.add(s),r.ceReload(o.styles),Zt.delete(s)):r.parent?mc(r.parent.update):r.appContext.reload?r.appContext.reload():typeof window<"u"?window.location.reload():console.warn("[HMR] Root or manually mounted instance modified. Full reload required.")}l=()=>{for(const r of a)Zt.delete(eo(r.type))},ol(l)?vt.push(...l):He&&He.includes(l,l.allowRecurse?ct+1:ct)||vt.push(l),hl();var l})});const Oo=new Map;function eo(t){return To(o=t)&&"__vccOpts"in o?t.__vccOpts:t;var o}function gl(t,o){On(t,o);for(const n in t)n==="__file"||n in o||delete t[n]}function vn(t){return(o,n)=>{try{return t(o,n)}catch(a){console.error(a),console.warn("[HMR] Something went wrong during Vue component hot-reload. Full reload required.")}}}let $n;process.env.NODE_ENV;let Cl="__VUE_INSTANCE_SETTERS__";($n=En()[Cl])||($n=En()[Cl]=[]),$n.push(t=>t);const bc=/(?:^|[-_])(\w)/g,yc=t=>t.replace(bc,o=>o.toUpperCase()).replace(/[-_]/g,"");function wl(t,o=!0){return To(t)?t.displayName||t.name:t.name||o&&t.__name}function kl(t,o,n=!1){let a=wl(o);if(!a&&o.__file){const l=o.__file.match(/([^/\\]+)\.\w+$/);l&&(a=l[1])}if(!a&&t&&t.parent){const l=r=>{for(const s in r)if(r[s]===o)return s};a=l(t.components||t.parent.type.components)||l(t.appContext.components)}return a?yc(a):n?"App":"Anonymous"}const bt=(t,o)=>function(n,a,l=!1){let r,s;const d=To(n);return d?(r=n,s=process.env.NODE_ENV!=="production"?()=>{console.warn("Write operation failed: computed value is readonly")}:tl):(r=n.get,s=n.set),new pc(r,s,d||!s,l)}(t,0,!1);function gc(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var xl,_l={exports:{}};function Cc(){return xl||(xl=1,_l.exports=function(){var t=1e3,o=6e4,n=36e5,a="millisecond",l="second",r="minute",s="hour",d="day",i="week",c="month",p="quarter",u="year",f="date",y="Invalid Date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,b=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,m={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(I){var $=["th","st","nd","rd"],x=I%100;return"["+I+($[(x-20)%10]||$[x]||$[0])+"]"}},w=function(I,$,x){var V=String(I);return!V||V.length>=$?I:""+Array($+1-V.length).join(x)+I},g={s:w,z:function(I){var $=-I.utcOffset(),x=Math.abs($),V=Math.floor(x/60),T=x%60;return($<=0?"+":"-")+w(V,2,"0")+":"+w(T,2,"0")},m:function I($,x){if($.date()<x.date())return-I(x,$);var V=12*(x.year()-$.year())+(x.month()-$.month()),T=$.clone().add(V,c),P=x-T<0,R=$.clone().add(V+(P?-1:1),c);return+(-(V+(x-T)/(P?T-R:R-T))||0)},a:function(I){return I<0?Math.ceil(I)||0:Math.floor(I)},p:function(I){return{M:c,y:u,w:i,d,D:f,h:s,m:r,s:l,ms:a,Q:p}[I]||String(I||"").toLowerCase().replace(/s$/,"")},u:function(I){return I===void 0}},S="en",C={};C[S]=m;var k="$isDayjsObject",_=function(I){return I instanceof L||!(!I||!I[k])},E=function I($,x,V){var T;if(!$)return S;if(typeof $=="string"){var P=$.toLowerCase();C[P]&&(T=P),x&&(C[P]=x,T=P);var R=$.split("-");if(!T&&R.length>1)return I(R[0])}else{var N=$.name;C[N]=$,T=N}return!V&&T&&(S=T),T||!V&&S},O=function(I,$){if(_(I))return I.clone();var x=typeof $=="object"?$:{};return x.date=I,x.args=arguments,new L(x)},B=g;B.l=E,B.i=_,B.w=function(I,$){return O(I,{locale:$.$L,utc:$.$u,x:$.$x,$offset:$.$offset})};var L=function(){function I(x){this.$L=E(x.locale,null,!0),this.parse(x),this.$x=this.$x||x.x||{},this[k]=!0}var $=I.prototype;return $.parse=function(x){this.$d=function(V){var T=V.date,P=V.utc;if(T===null)return new Date(NaN);if(B.u(T))return new Date;if(T instanceof Date)return new Date(T);if(typeof T=="string"&&!/Z$/i.test(T)){var R=T.match(h);if(R){var N=R[2]-1||0,v=(R[7]||"0").substring(0,3);return P?new Date(Date.UTC(R[1],N,R[3]||1,R[4]||0,R[5]||0,R[6]||0,v)):new Date(R[1],N,R[3]||1,R[4]||0,R[5]||0,R[6]||0,v)}}return new Date(T)}(x),this.init()},$.init=function(){var x=this.$d;this.$y=x.getFullYear(),this.$M=x.getMonth(),this.$D=x.getDate(),this.$W=x.getDay(),this.$H=x.getHours(),this.$m=x.getMinutes(),this.$s=x.getSeconds(),this.$ms=x.getMilliseconds()},$.$utils=function(){return B},$.isValid=function(){return this.$d.toString()!==y},$.isSame=function(x,V){var T=O(x);return this.startOf(V)<=T&&T<=this.endOf(V)},$.isAfter=function(x,V){return O(x)<this.startOf(V)},$.isBefore=function(x,V){return this.endOf(V)<O(x)},$.$g=function(x,V,T){return B.u(x)?this[V]:this.set(T,x)},$.unix=function(){return Math.floor(this.valueOf()/1e3)},$.valueOf=function(){return this.$d.getTime()},$.startOf=function(x,V){var T=this,P=!!B.u(V)||V,R=B.p(x),N=function(Q,Z){var ae=B.w(T.$u?Date.UTC(T.$y,Z,Q):new Date(T.$y,Z,Q),T);return P?ae:ae.endOf(d)},v=function(Q,Z){return B.w(T.toDate()[Q].apply(T.toDate("s"),(P?[0,0,0,0]:[23,59,59,999]).slice(Z)),T)},A=this.$W,F=this.$M,M=this.$D,G="set"+(this.$u?"UTC":"");switch(R){case u:return P?N(1,0):N(31,11);case c:return P?N(1,F):N(0,F+1);case i:var W=this.$locale().weekStart||0,X=(A<W?A+7:A)-W;return N(P?M-X:M+(6-X),F);case d:case f:return v(G+"Hours",0);case s:return v(G+"Minutes",1);case r:return v(G+"Seconds",2);case l:return v(G+"Milliseconds",3);default:return this.clone()}},$.endOf=function(x){return this.startOf(x,!1)},$.$set=function(x,V){var T,P=B.p(x),R="set"+(this.$u?"UTC":""),N=(T={},T[d]=R+"Date",T[f]=R+"Date",T[c]=R+"Month",T[u]=R+"FullYear",T[s]=R+"Hours",T[r]=R+"Minutes",T[l]=R+"Seconds",T[a]=R+"Milliseconds",T)[P],v=P===d?this.$D+(V-this.$W):V;if(P===c||P===u){var A=this.clone().set(f,1);A.$d[N](v),A.init(),this.$d=A.set(f,Math.min(this.$D,A.daysInMonth())).$d}else N&&this.$d[N](v);return this.init(),this},$.set=function(x,V){return this.clone().$set(x,V)},$.get=function(x){return this[B.p(x)]()},$.add=function(x,V){var T,P=this;x=Number(x);var R=B.p(V),N=function(F){var M=O(P);return B.w(M.date(M.date()+Math.round(F*x)),P)};if(R===c)return this.set(c,this.$M+x);if(R===u)return this.set(u,this.$y+x);if(R===d)return N(1);if(R===i)return N(7);var v=(T={},T[r]=o,T[s]=n,T[l]=t,T)[R]||1,A=this.$d.getTime()+x*v;return B.w(A,this)},$.subtract=function(x,V){return this.add(-1*x,V)},$.format=function(x){var V=this,T=this.$locale();if(!this.isValid())return T.invalidDate||y;var P=x||"YYYY-MM-DDTHH:mm:ssZ",R=B.z(this),N=this.$H,v=this.$m,A=this.$M,F=T.weekdays,M=T.months,G=T.meridiem,W=function(Z,ae,le,_e){return Z&&(Z[ae]||Z(V,P))||le[ae].slice(0,_e)},X=function(Z){return B.s(N%12||12,Z,"0")},Q=G||function(Z,ae,le){var _e=Z<12?"AM":"PM";return le?_e.toLowerCase():_e};return P.replace(b,function(Z,ae){return ae||function(le){switch(le){case"YY":return String(V.$y).slice(-2);case"YYYY":return B.s(V.$y,4,"0");case"M":return A+1;case"MM":return B.s(A+1,2,"0");case"MMM":return W(T.monthsShort,A,M,3);case"MMMM":return W(M,A);case"D":return V.$D;case"DD":return B.s(V.$D,2,"0");case"d":return String(V.$W);case"dd":return W(T.weekdaysMin,V.$W,F,2);case"ddd":return W(T.weekdaysShort,V.$W,F,3);case"dddd":return F[V.$W];case"H":return String(N);case"HH":return B.s(N,2,"0");case"h":return X(1);case"hh":return X(2);case"a":return Q(N,v,!0);case"A":return Q(N,v,!1);case"m":return String(v);case"mm":return B.s(v,2,"0");case"s":return String(V.$s);case"ss":return B.s(V.$s,2,"0");case"SSS":return B.s(V.$ms,3,"0");case"Z":return R}return null}(Z)||R.replace(":","")})},$.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},$.diff=function(x,V,T){var P,R=this,N=B.p(V),v=O(x),A=(v.utcOffset()-this.utcOffset())*o,F=this-v,M=function(){return B.m(R,v)};switch(N){case u:P=M()/12;break;case c:P=M();break;case p:P=M()/3;break;case i:P=(F-A)/6048e5;break;case d:P=(F-A)/864e5;break;case s:P=F/n;break;case r:P=F/o;break;case l:P=F/t;break;default:P=F}return T?P:B.a(P)},$.daysInMonth=function(){return this.endOf(c).$D},$.$locale=function(){return C[this.$L]},$.locale=function(x,V){if(!x)return this.$L;var T=this.clone(),P=E(x,V,!0);return P&&(T.$L=P),T},$.clone=function(){return B.w(this.$d,this)},$.toDate=function(){return new Date(this.valueOf())},$.toJSON=function(){return this.isValid()?this.toISOString():null},$.toISOString=function(){return this.$d.toISOString()},$.toString=function(){return this.$d.toUTCString()},I}(),D=L.prototype;return O.prototype=D,[["$ms",a],["$s",l],["$m",r],["$H",s],["$W",d],["$M",c],["$y",u],["$D",f]].forEach(function(I){D[I[1]]=function($){return this.$g($,I[0],I[1])}}),O.extend=function(I,$){return I.$i||(I($,L,O),I.$i=!0),O},O.locale=E,O.isDayjs=_,O.unix=function(I){return O(1e3*I)},O.en=C[S],O.Ls=C,O.p={},O}()),_l.exports}var wc=gc(Cc()),Sl=typeof global=="object"&&global&&global.Object===Object&&global,kc=typeof self=="object"&&self&&self.Object===Object&&self,Je=Sl||kc||Function("return this")(),$t=Je.Symbol,Nl=Object.prototype,xc=Nl.hasOwnProperty,_c=Nl.toString,to=$t?$t.toStringTag:void 0,Sc=Object.prototype.toString,Tl=$t?$t.toStringTag:void 0;function Eo(t){return t==null?t===void 0?"[object Undefined]":"[object Null]":Tl&&Tl in Object(t)?function(o){var n=xc.call(o,to),a=o[to];try{o[to]=void 0;var l=!0}catch{}var r=_c.call(o);return l&&(n?o[to]=a:delete o[to]),r}(t):function(o){return Sc.call(o)}(t)}function Al(t){return t!=null&&typeof t=="object"}function Ol(t){var o=typeof t;return t!=null&&(o=="object"||o=="function")}function Nc(t){if(!Ol(t))return!1;var o=Eo(t);return o=="[object Function]"||o=="[object GeneratorFunction]"||o=="[object AsyncFunction]"||o=="[object Proxy]"}var El,Fn=Je["__core-js_shared__"],Bl=(El=/[^.]+$/.exec(Fn&&Fn.keys&&Fn.keys.IE_PROTO||""))?"Symbol(src)_1."+El:"",Tc=Function.prototype.toString;function yt(t){if(t!=null){try{return Tc.call(t)}catch{}try{return t+""}catch{}}return""}var Ac=/^\[object .+?Constructor\]$/,Oc=Function.prototype,Ec=Object.prototype,Bc=Oc.toString,Vc=Ec.hasOwnProperty,Lc=RegExp("^"+Bc.call(Vc).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function vc(t){return!(!Ol(t)||(o=t,Bl&&Bl in o))&&(Nc(t)?Lc:Ac).test(yt(t));var o}function gt(t,o){var n=function(a,l){return a==null?void 0:a[l]}(t,o);return vc(n)?n:void 0}var In=gt(Je,"WeakMap");(function(){try{var t=gt(Object,"defineProperty");return t({},"",{}),t}catch{}})();function Vl(t){return Al(t)&&Eo(t)=="[object Arguments]"}var Ll=Object.prototype,$c=Ll.hasOwnProperty,Fc=Ll.propertyIsEnumerable;Vl(function(){return arguments}());var vl=typeof me=="object"&&me&&!me.nodeType&&me,$l=vl&&typeof module=="object"&&module&&!module.nodeType&&module,Fl=$l&&$l.exports===vl?Je.Buffer:void 0;Fl&&Fl.isBuffer;var Il=typeof me=="object"&&me&&!me.nodeType&&me,oo=Il&&typeof module=="object"&&module&&!module.nodeType&&module,Dn=oo&&oo.exports===Il&&Sl.process,Ft=function(){try{var t=oo&&oo.require&&oo.require("util").types;return t||Dn&&Dn.binding&&Dn.binding("util")}catch{}}();Ft&&Ft.isTypedArray,gt(Object,"create");var Mn=gt(Je,"Map"),Pn=gt(Je,"DataView"),jn=gt(Je,"Promise"),Rn=gt(Je,"Set"),Dl="[object Map]",Ml="[object Promise]",Pl="[object Set]",jl="[object WeakMap]",Rl="[object DataView]",Ic=yt(Pn),Dc=yt(Mn),Mc=yt(jn),Pc=yt(Rn),jc=yt(In),It=Eo;(Pn&&It(new Pn(new ArrayBuffer(1)))!=Rl||Mn&&It(new Mn)!=Dl||jn&&It(jn.resolve())!=Ml||Rn&&It(new Rn)!=Pl||In&&It(new In)!=jl)&&(It=function(t){var o=Eo(t),n=o=="[object Object]"?t.constructor:void 0,a=n?yt(n):"";if(a)switch(a){case Ic:return Rl;case Dc:return Dl;case Mc:return Ml;case Pc:return Pl;case jc:return jl}return o}),Je.Uint8Array;var Ul=$t?$t.prototype:void 0;Ul&&Ul.valueOf,Ft&&Ft.isMap,Ft&&Ft.isSet;const zl=(t,o)=>{const n=Object.assign({dayjs:wc},o);let a="";const l=[];for(const d in n)a+=`${d},`,l.push(n[d]);a=a.replace(/,$/,"");const r=`function (${a}){return ${t}}`;let s;try{s=Function(`"use strict";return (${r})`)()(...l)}catch{return t}return s},Dt=(t="",{textData:o,codeData:n}={},{useNewline:a=!1,useSpace:l=!1}={})=>{const r=Object.assign({},o),s=(t||"").match(/\{(.+?)\}/g);if(s==null||s.length===0)return t;for(let d=0;d<s.length;d++){const i=s[d];let c=i.slice(1,-1).trim();const p=/[\u4e00-\u9fa5a-z-_A-Z0-9]*/g,u=c.match(p);for(let f=0;f<u.length;f++){const y=u[f],h=r[y];h!=null&&typeof h!="function"&&(c=c.replace(y,h))}(/\(.*\)/g.test(c)||/[+/\\*]/g.test(c))&&(c=zl(c,n)),t=t.replace(i,c)}return a&&(t=t==null?void 0:t.replace(/\n|\\n/g,"<br/>")),l&&(t=t==null?void 0:t.replace(/\s{2,}?/g,"&nbsp;&nbsp;")),t=t.replace(/Qfw\((.*?)\)/,(d,i)=>o!=null&&o.Qfw?o==null?void 0:o.Qfw(i):i)},we=(t,o)=>{if(typeof t=="string"&&typeof o=="string")return t.toLocaleLowerCase().includes(o.toLocaleLowerCase());if(typeof t=="string"&&Array.isArray(o)){const n=o.length;for(let a=0;a<n;a++){const l=o[a];if(typeof l=="string"&&t.toLocaleLowerCase().includes(l.toLocaleLowerCase()))return!0}}return!1},We=(t,o)=>Object.prototype.hasOwnProperty.call(t,o);function Rc(t){let o="",n="",a="",l="";t.indexOf(".")>-1?(n=t.split(".")[0],a=t.split(".")[1]):n=t;let r=0,s=0;for(s=n.length-1;s>=0;)r%3==0&&r!==0?n[s]==="-"?o+=n[s]:o+=","+n[s]:o+=n[s],s--,r++;return o=o.split("").reverse().join(""),l=t.indexOf(".")>-1?o+"."+a:o,l}const Uc=(t=[],o,n=!1)=>{let{name:a="name",types:l=[]}=o||{};a=(a==null?void 0:a.trim())||a;const r=new Set,s=new Map,d=t.length,i=l.length;if(d!==1||n)for(let u=0;u<d;u++){const f=t[u],y=f[a];r.add(y);for(let h=0;h<i;h++){const b=l[h],{label:m,value:w}=b,g=Object.assign(Object.assign({},f),{value:f[w]});if(s.has(m)){const S=s.get(m);S.push(g),s.set(m,S)}else s.set(m,[g])}}else{const u=[];for(let y=0;y<i;y++){const h=l[y],{label:b,value:m}=h,w=Object.assign(Object.assign({},t[0]),{value:t[0][m]});r.add(b),u.push(w)}const f=t[0][a]||"";s.set(f,u)}const c=Array.from(r),p=[];for(const[u,f]of s)p.push({name:u,data:f});return{dimensions:c,dataset:p}},zc=(t,o)=>{let{name:n="name",value:a="value",type:l="type"}=o||{};n=n==null?void 0:n.trim(),a=a==null?void 0:a.trim(),l=l==null?void 0:l.trim();const r=new Map,s=t.length;for(let c=0;c<s;c++){const p=t[c],u=p[n]||"",f=p[a]||"",y=p[l]||"";if(r.has(y)){const h=r.get(y);h.push(Object.assign({name:u,value:f},p)),r.set(y,h)}else r.set(y,[Object.assign({name:u,value:f},p)])}const d=[],i=[];for(const[c,p]of r)if(i.push({name:c,data:p}),p==null?void 0:p.length)if(d.length)for(const u of p)d.includes(u.name)||d.push(u.name);else d.push(...p.map(u=>u.name));return{dimensions:d,dataset:i}},Mt=(t,o)=>{var n;if(t==null)return o;const a=t.match(/\{.*\}/g);if(a==null||a.length===0)return o;const l=a.length;for(let r=0;r<l;r++){const s=a[r];if(s==null||s==="")break;let d=(n=s.slice(1,-1))===null||n===void 0?void 0:n.trim();d=d==null?void 0:d.replace(/value/g,o);try{let i=d;(/\(.*\)/g.test(d)||/[+/\\*]/g.test(d))&&(i=zl(d)),t=t.replace(s,i)}catch{t=t.replace(s,d)}}return t};function Gc(t){return t.isShowMarkLine?{markLine:{data:[{type:t.markLineType}]}}:{}}const Hc=(t,o,n)=>{const a=t.yAxisLabelFormatter,l=t.xAxisLabelFormatter,{dimensions:r=[],dataset:s=[]}=o,d=bt(()=>{const{gradientShow:c,gradientColors:p,gradientOffset:u,barBorderRadius:f}=t,y=s,h=y.length,b=[];for(let m=0;m<h;m++){const w=Object.assign(Object.assign({},y[m]),{type:"bar",barWidth:t.barWidth,showBackground:t.showBarBackground}),{isStack:g,stackColumns:S}=t;if(g&&S.includes(y[m].name||!S)&&(w.stack="stack"),w.label={show:t.labelShow,fontSize:t.labelFontSize,position:t.labelPosition,color:t.labelColor,width:t.labelWidth,overflow:t.labelOverflow,formatter:C=>{let k="",_=t.labelFormatter;_===""&&(_="{c}");const{seriesName:E,name:O,value:B,data:L}=C||{};return k+=Dt(_,{textData:Object.assign({name:O,value:B,a:E,b:O,c:B||0},L)},{useNewline:!0,useSpace:!0}),k}},w.itemStyle={},c&&(w.itemStyle={color:{x:t.isUseHorizontalAxis?1:0,y:0,x2:0,y2:t.isUseHorizontalAxis?0:1,colorStops:[{offset:0,color:t.colors[m]},{offset:u,color:p[m]},{offset:1,color:p[m]}]}}),f){const C=f.split(",");if(C!=null&&C.length){const k=[];for(const _ of C){const E=parseFloat(_);isNaN(E)||k.push(E)}w.itemStyle.barBorderRadius=k}}t.isShowMarkLine&&(w.markLine={data:[{type:t.markLineType}]}),b.push(w)}return b}),i=bt(()=>r.map(c=>{let p={};return p=c&&typeof c=="object"?Object.assign(Object.assign({},c),{textStyle:{fontSize:n}}):{value:c,textStyle:{fontSize:n}},p}));return{tooltip:{trigger:"axis",show:t.tooltipShow,formatter:c=>{const p=c.length;let u="",f=t.tooltipFormatter;f===""&&(f="{marker} {a} {c}");for(let y=0;y<p;y++){const{marker:h,seriesName:b,name:m,value:w,data:g}=c[y]||{};if(y===0){let S=m;typeof m!="string"||m[0]!=="0"||isNaN(+m)||(S=(+m).toString()),u+=`${Mt(l,S)}<br/>`}u+=Dt(f,{textData:Object.assign({marker:h,name:m,value:w,Qfw:Rc,a:b,b:m,c:w||0},g)},{useNewline:!0,useSpace:!0}),u+="<br/>"}return u},textStyle:{color:t.tooltipTextStyleColor,fontSize:n},position:t.tooltipPosition||void 0,backgroundColor:t.tooltipBackgroundColor||"#fff"},legend:{type:t.legendScroll?"scroll":"plain",width:t.legendWidth,height:t.legendHeight,show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{rich:{text:{width:t.legendTextWidth,color:t.legendTextStyleColor,fontSize:t.legendFontSize}}},itemHeight:t.legendItemHeight,itemWidth:t.legendItemWidth,itemGap:t.legendItemGap,data:s.map((c,p)=>({name:c.name,itemStyle:{color:t.colors[p]},icon:t.legendType})),formatter:c=>((p="",u)=>{var f;const y=p.match(/\{(.+?)\}/g),h=((f=p.split(`
62
+ `))===null||f===void 0?void 0:f.length)-1;let b="";if(h)for(let w=0;w<h;w++)b+=`
63
+ `;let m=p;if(y!=null&&y.length){for(const w of y){const g=Dt(w,{textData:u},{useNewline:!1,useSpace:!1});g&&(m=m.replace(w,g))}return`${b}{text|${m}}`}return p})(t.legendFormatter,{name:c})},xAxis:{type:t.isUseHorizontalAxis?"value":"category",data:t.isUseHorizontalAxis?null:it(i),inverse:t.isUseHorizontalAxis?t.xAxisInverse:t.axisInverse,minInterval:t.xAxisMinInterval,splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor,type:t.xAxisSplitLineType},interval:t.xAxisSplitLineInterval},splitArea:{show:t.xAxisSplitAreaShow},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow,fontSize:t.xAxisLabelFontSize,formatter:c=>(typeof c!="string"||c[0]!=="0"||isNaN(+c)||(c=(+c).toString()),Mt(l,c))},axisLine:{show:t.xAxisLineShow,lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow},name:t.xAxisName,nameTextStyle:{fontSize:t.xAxisLabelFontSize,color:t.xAxisLabelColor,align:"left"},max:t.xAxisMaxValue||null},yAxis:{type:t.isUseHorizontalAxis?"category":"value",data:t.isUseHorizontalAxis?it(r):null,inverse:t.isUseHorizontalAxis?t.axisInverse:t.yAxisInverse,minInterval:t.yAxisMinInterval,splitLine:{show:t.yAxisSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor,type:t.yAxisSplitLineType}},splitArea:{show:t.yAxisSplitAreaShow},axisLabel:{show:t.yAxisLabelShow,fontSize:t.yAxisLabelFontSize,color:t.yAxisLabelColor,rotate:t.yAxisLabelRotate,width:t.yAxisLabelWidth,overflow:t.yAxisLabelOverflow,formatter:c=>Mt(a,c)},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}},name:t.yAxisName,nameTextStyle:{fontSize:t.yAxisLabelFontSize,color:t.yAxisLabelColor,align:"right"},max:t.yAxisMaxValue||null},series:it(d)}},Wc=(t,o,n)=>{const a=t.yAxisLabelFormatter,l=t.xAxisLabelFormatter,{dimensions:r=[],dataset:s=[]}=o,d=bt(()=>r.map(c=>{let p={};return p=c&&typeof c=="object"?Object.assign(Object.assign({},c),{textStyle:{fontSize:n}}):{value:c,textStyle:{fontSize:n}},p})),i=bt(()=>{const c=[],p=s.length;for(let u=0;u<p;u++){const f={};t.shadowColor&&(f.shadowColor=t.shadowColor,f.shadowBlur=t.shadowBlur,f.shadowOffsetY=t.shadowOffsetY,f.shadowOffsetX=t.shadowOffsetX),c.push(Object.assign(Object.assign(Object.assign({type:"line"},s[u]),{symbolSize:t.symbolSize,smooth:t.smooth,areaStyle:{color:t.areaGradientShow?{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:t.colors[u]},{offset:1,color:t.areaGradientColor||"transparent"}],global:!1}:t.colors[u],opacity:t.areaStyleOpacity},lineStyle:Object.assign({width:t.lineStyleWidth},f)}),Gc(t)))}return c});return{tooltip:{trigger:"axis",show:t.tooltipShow,formatter:c=>{const p=c.length;let u="",f=t.tooltipFormatter;f===""&&(f="{marker} {a} {c}");for(let y=0;y<p;y++){const{marker:h,seriesName:b,name:m,value:w,data:g}=c[y]||{};y===0&&(u+=`${m}<br/>`),u+=Dt(f,{textData:Object.assign({marker:h,name:m,value:w,a:b,b:m,c:w},g)},{useNewline:!0,useSpace:!0}),u+="<br/>"}return u},textStyle:{color:t.tooltipTextStyleColor,fontSize:n.value},position:t.tooltipPosition||void 0,backgroundColor:t.tooltipBackgroundColor||"#fff"},xAxis:{name:t.xAxisName,type:"category",data:it(d),minInterval:t.xAxisMinInterval,splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor}},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow,formatter:c=>Mt(l,c)},axisLine:{lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow}},yAxis:{type:"value",name:t.yAxisName,minInterval:t.yAxisMinInterval,splitLine:{show:t.yAxisSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor}},axisLabel:{fontSize:n,color:t.yAxisLabelColor,formatter:c=>Mt(a,c)},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}}},legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{fontSize:n}},series:it(i)}},Yc=(t,o,n)=>{const{dataset:a=[]}=o;let{data:l=[]}=a[0]||{};if(Array.isArray(t.colors)){const s=t.isUseLabelColors,d=t.colors;l=l.map((i,c)=>Object.assign({label:s?{color:d[c]}:{}},i))}return{title:{text:t.titleText,subtext:t.titleSubtext,textStyle:{fontSize:t.titleFontSize,fontWeight:t.fontWeight,color:t.titleColor},left:t.textAlign||"center"},tooltip:{show:t.tooltipShow,trigger:t.tooltipTrigger,formatter:s=>{const{marker:d,seriesName:i,name:c,value:p,percent:u,data:f}=s||{};return Dt(t.tooltipFormatter,{textData:Object.assign({marker:d,name:c,value:p,percent:u,a:i,b:c,c:p,d:u},f)},{useNewline:!0,useSpace:!0})},textStyle:{color:t.tooltipTextStyleColor||"#333"},backgroundColor:t.tooltipBackgroundColor||"#fff",borderColor:t.tooltipBorderColor||"#eee"},legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{color:t.legendTextStyleColor,fontSize:n===18?n:t.labelFontSize}},series:[{data:l,type:"pie",radius:[t.innerRadius,t.outerRadius],center:[t.centerLeft,t.centerTop],roseType:t.roseType,avoidLabelOverlap:!1,minAngle:t.minAngle,label:{show:t.labelPosition!=="center"&&t.labelShow,color:t.labelColor,fontSize:n===18?n:t.labelFontSize,position:t.labelPosition,formatter:(r=t.labelFormatter,r.replace(/\\n/g,`
64
+ `))},labelLine:{show:t.labelLineShow,length:t.labelLineLength,length2:t.labelLineLength2},emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"},label:{}}}]};var r},qc=(t,o,n)=>{const{dimensions:a=[],dataset:l=[]}=o,r=bt(()=>a.map(i=>{let c={};return c=i&&typeof i=="object"?Object.assign(Object.assign({},i),{textStyle:{fontSize:n}}):{value:i,textStyle:{fontSize:n}},c})),s=bt(()=>{const i=[],c=l.length,p=t.seriesTypes;for(let u=0;u<c;u++){const f=p[u],{type:y,axisIndex:h}=f||{};let b=Object.assign({type:y,yAxisIndex:h},l[u]);if(y==="line"){const m={};t.shadowColor&&(m.shadowColor=t.shadowColor,m.shadowBlur=t.shadowBlur,m.shadowOffsetY=t.shadowOffsetY,m.shadowOffsetX=t.shadowOffsetX),b=Object.assign(Object.assign({},b),{symbolSize:t.symbolSize,smooth:t.smooth,itemStyle:{color:t.colors[u]},areaStyle:{color:t.areaGradientShow?{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:t.colors[u]},{offset:1,color:t.areaGradientColor||"transparent"}],global:!1}:t.colors[u],opacity:t.areaStyleOpacity},lineStyle:Object.assign({width:t.lineStyleWidth},m)})}if(y==="bar"){const{gradientShow:m,gradientColors:w,gradientOffset:g}=t,S={};if(t.barBorderRadius){const C=t.barBorderRadius.split(",");if(C!=null&&C.length){const k=[];for(const _ of C){const E=parseFloat(_);isNaN(E)||k.push(E)}S.borderRadius=k}}m&&(S.color={x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:t.colors[u]},{offset:g,color:w[u]},{offset:1,color:w[u]}]}),b=Object.assign(Object.assign({},b),{barWidth:t.barWidth,itemStyle:S})}t.isShowMarkLine&&(b.markLine={data:[{type:t.markLineType}]}),i.push(b)}return i}),d=bt(()=>{const i=t.yAxis;return i==null?void 0:i.map((c,p)=>({type:"value",minInterval:t.yAxisMinInterval,splitLine:{show:p===0?t.yAxisLeftSplitLineShow:t.yAxisRightSplitLineShow,lineStyle:{color:t.yAxisSplitLineStyleColor,type:p===0?t.yAxisLeftSplitLineType:t.yAxisRightSplitLineType}},splitArea:{show:t.yAxisSplitAreaShow},axisLabel:{fontSize:n,show:t.yAxisLabelShow,color:t.yAxisLabelColor,formatter:u=>Mt(c.axisLabelFormatter,u)},axisLine:{show:t.yAxisLineAlwaysDisplay,lineStyle:{color:t.yAxisLineStyleColor}},name:p===0?t.yAxisLeftName:t.yAxisRightName,nameTextStyle:{fontSize:t.yAxisLabelFontSize,color:t.yAxisLabelColor,align:p===0?"right":"left"},max:t.yAxisMaxValue||null}))});return{legend:{show:t.legendShow,orient:t.legendOrient,top:t.legendTop,left:t.legendLeft,textStyle:{color:t.legendTextStyleColor,fontSize:n}},tooltip:{trigger:"axis",show:t.tooltipShow,formatter:i=>{const c=i.length;let p="",u=t.tooltipFormatter;u===""&&(u="{marker} {a} {c}");const f=t.seriesTypes;for(let y=0;y<c;y++){const h=f[y],{tooltipFormatter:b}=h||{},{marker:m,seriesName:w,name:g,value:S,data:C}=i[y]||{};y===0&&(p+=`${g}<br/>`),p+=Dt(b||u,{textData:Object.assign({marker:m,name:g,value:S,seriesName:w,a:w,b:g,c:S},C)},{useNewline:!0,useSpace:!0}),p+="<br/>"}return p},textStyle:{color:t.tooltipTextStyleColor||"#333",fontSize:n},backgroundColor:t.tooltipBackgroundColor||"#fff",borderColor:t.tooltipBorderColor||"#eee"},xAxis:{name:t.xAxisName,minInterval:t.xAxisMinInterval,type:"category",data:it(r),splitLine:{show:t.xAxisSplitLineShow,lineStyle:{color:t.xAxisSplitLineStyleColor}},axisLabel:{color:t.xAxisLabelColor,interval:t.xAxisLabelInterval||0,rotate:t.xAxisLabelRotate,width:t.xAxisLabelWidth,overflow:t.xAxisLabelOverflow},axisLine:{lineStyle:{color:t.xAxisLineStyleColor}},axisTick:{show:t.xAxisTickShow}},yAxis:it(d),series:it(s)}},Kc=(t,o,n=12)=>Object.assign(Object.assign({},(a=>({title:{text:a.titleText,subtext:a.titleSubtext,textStyle:{fontSize:a.titleFontSize,fontWeight:a.fontWeight,color:a.titleColor},left:a.textAlign||"center"},grid:{top:a.gridTop,bottom:a.gridBottom,left:a.gridLeft,right:a.gridRight,containLabel:a.gridContainLabel},color:a.colors}))(t)),((a,l,r)=>{switch(a.type){case"bar":return Hc(a,l,r);case"line":return Wc(a,l,r);case"pie":return Yc(a,l,r);case"comboGraph":return qc(a,l,r);default:return{}}})(t,o,n)),dt=t=>{const o=[];if(t!=null&&t.length)for(const n of t)n.conditions?o.push(...dt(n.conditions)):(n==null?void 0:n.dataType)==="component"&&o.push(n);return o},Gl=(t,o)=>{var b;const n=J.cloneDeep((t==null?void 0:t.controlList)||[]),{classificationList:a=[],rowHeaderList:l=[],dimensionList:r=[],seriesList:s=[],leftAxisList:d=[],rightAxisList:i=[],queryColumnList:c=[],indicators:p=[]}=t;Wl(n,o);const u=n,f=[...a,...l,...r,...s,...d,...i,...c,...p],y=[];for(const m of f){const w=dt((m==null?void 0:m.conditions)||[]);if(w!=null&&w.length){const g=w.filter(S=>Yl(S,o)?(S==null?void 0:S.dataType)==="component":!1).map(S=>{const C=Yl(S,o),k={};return S!=null&&S.dateFormat&&(k.format=S.dateFormat),{conditionKey:S.fieldName,conditionLabel:S.fieldName,conditionName:S.fieldName,conditionValueType:S.fieldType,id:C.id,keyName:S.fieldValue,rule:S.rule,notGlobal:!0,indexCode:S.indexCode,typeGuid:S.typeGuid,indexCodeNum:S.indexCodeNum,...k}});if(g!=null&&g.length)for(const S of g)y.find(C=>C.keyName===S.keyName)||y.push(S)}}const h=y.length;for(let m=0;m<h;m++){const w=y[m];if(w&&!((b=Object.keys(w))!=null&&b.length)||(w==null?void 0:w.conditionKey)==="parentCode")continue;const{id:g,keyName:S,prop:C,format:k,dataType:_="component",customValue:E}=w,O=Hl(w);Un({sqlCondition:O,renderUsedComponents:o,id:g,dateFormat:k,prop:C,keyName:S,dataType:_,customValue:E}),u.push(O)}for(let m=u.length-1;m>=0;m--){const w=u[m];w.globalCondition||dt(u).find(S=>S.alias===w.alias&&S.globalCondition)&&u.splice(m,1)}return u},no=(t,o)=>{const n=[];if(t!=null&&t.length){for(const a of t)if(a.variableName){const l={variateName:a.variableName,globalCondition:!1,valueType:a.variableType,alias:a.keyName||""};Un({sqlCondition:l,renderUsedComponents:o,id:a.id,dateFormat:a.format,prop:a.dateTypeValue,keyName:a.keyName,dataType:a.dataType,customValue:a.variableValue,operateType:a.operateType,operateMode:a.operateMode,operateValue:a.operateValue}),a.format&&(l.dateFormat=a.format),a.label&&(l.label=a.label),n.push(l)}}return n};function Hl(t){const{id:o,keyName:n,conditionLabel:a,conditionKey:l,conditionValueType:r,prop:s,rule:d="NONE",notGlobal:i=!1,indexCode:c,indexCodeNum:p,typeGuid:u,dataType:f="component"}=t;let y=n||o;return y&&s&&(y+=`-${s}`),{rule:d,label:a,fieldName:l,fieldValue:"",valueType:r,alias:y,globalCondition:!i,indexCode:c,indexCodeNum:p,typeGuid:u,dataType:f}}const Xc=["keyValue","conditionKey","conditionLabel","conditionName","conditionValueType","customValue","id","keyName"];function Wl(t,o){if(t!=null&&t.length)for(const n of t)if(n!=null&&n.conditions)Wl(n.conditions,o);else{const{id:a,keyName:l,prop:r,format:s,dataType:d="component",customValue:i}=n,c=Hl(n);Un({sqlCondition:c,renderUsedComponents:o,id:a,dateFormat:s,prop:r,keyName:l,dataType:d,customValue:i});for(const p in c)n[p]=c[p];for(const p of Xc)delete n[p]}}function Un(t){const{sqlCondition:o,renderUsedComponents:n,id:a,dateFormat:l,prop:r,keyName:s,dataType:d,customValue:i,operateValue:c,operateMode:p,operateType:u}=t,f=n.find(S=>S.id===a),{value:y,format:h="YYYY-MM-DD",operate:b,type:m="",useCurrentTime:w}=f||{},g=l||h;if(we(m,"date")){let S;if(w?S=he():S=he(y),b&&y){const{mode:C,type:k,value:_}=b;if(_)switch(k){case"add":S=S.add(_,C);break;case"minus":S=S.subtract(_,C);break}}if(c&&p&&u)switch(u){case"add":S=S.add(c,p);break;case"minus":S=S.subtract(c,p);break}o.fieldValue=(S==null?void 0:S.format(g))||"",o.dateFormat=g}else if(m==="ecanRangePicker"){const{interval:S,intervalUnit:C,startTime:k,endTime:_}=f||{};let E=r;if(!r){const B=s==null?void 0:s.split("-");B!=null&&B.length&&(E=B[B.length-1])}if(!E)return;let O=null;if(w&&(E==="startTime"?O=he().subtract(S,C):E==="endTime"&&(O=he())),f[E]&&(O=he(f[E])),b){const{type:B,value:L,mode:D}=b;switch(B){case"add":O=O&&O.add(L,D);break;case"minus":O=O&&O.subtract(L,D)}}if(c&&p&&u){if(c==="rangeValue"){if(k&&_){const B=he(_).diff(he(k),p)+1;switch(u){case"add":O=O&&O.add(B,p);break;case"minus":O=O&&O.subtract(B,p)}}}else if(!isNaN(+c))switch(u){case"add":O=O&&O.add(c,p);break;case"minus":O=O&&O.subtract(c,p)}}if(O&&(o.fieldValue=O==null?void 0:O.format(g)),E==="rangeValue"&&k&&_){const B=Qc(g);B&&(o.fieldValue=he(_).diff(he(k),B)+1)}o.dateFormat=g}else{const S=y&&y.match(/\{(.+?)\}/g);S!=null&&S.length?o.fieldValue="":o.fieldValue=y}d===""&&(o.fieldValue=i||"")}const Bo=t=>{let o="";switch(t){case"ecanDatePicker":case"ecanRangePicker":o="dateChange";break;case"ecanTimeDisplay":o="timeChange";break;case"ecanSelect":case"ecanTreeSelect":o="selectChange";break;case"ecanTabs":o="tabChange";break;case"ecanInput":o="inputChange";break;case"ecanCheckbox":case"ecanRadio":o="checkboxChange";break;case"ecanText":o="valueChange";break;case"ecanImage":o="click";break}return o};function Yl(t,o){var n;if(t.componentId)return o.find(a=>a.id===t.componentId);if(t.dataType==="component")if(t.fieldType==="DATE"){const a=(n=t.fieldValue)==null?void 0:n.split("-");return a!=null&&a.length?a[0]:null}else return o.find(a=>a.keyName===t.fieldValue);else return null}function Qc(t){const o=t.split("-");let n="";if(o!=null&&o.length)switch(o[o.length-1]){case"YYYY":n="year";break;case"MM":n="month";break;case"DD":n="day";break}return n}function Jc(t,o){let n=t[o.label];if((n||n===0)&&n!==""&&o.dataFormat&&o.dataFormat.length!==0){if(o.dataFormat.includes("#.00")&&(typeof n!="number"&&(n=n.replace(/,/g,"")),Number(n)||Number(n)===0)){const a=o.retentiondigit?o.retentiondigit-0:o.retentiondigit;n=Number(n).toFixed(a)}if(o.dataFormat.includes("#,000")){const a=n.toString();a.includes(",")||(n=Zc(a))}}return n}function Zc(t){let o="",n="",a="",l="";t.indexOf(".")>-1?(n=t.split(".")[0],a=t.split(".")[1]):n=t;let r=0,s=0;for(s=n.length-1;s>=0;)r%3===0&&r!==0?n[s]==="-"?o+=n[s]:o+=","+n[s]:o+=n[s],s--,r++;return o=o.split("").reverse().join(""),t.indexOf(".")>-1?l=o+"."+a:l=o,l}const ql=t=>({DIM:"维度",BUILT_IN_DIM:"维度",IDX:"指标",BUILT_IN_IDX:"指标",FIELD:"数据集"})[t],Kl=t=>({0:"文本",1:"数值",2:"日期"})[t],Xl=t=>t==="0"?"手工录入":t==="1"?"系统取数":t==="2"?"运算加工":"",Ql=t=>{let o="";switch(t){case"1":o="人力系统";break;case"2":o="绩效系统";break;case"3":o="预算系统";break;case"4":o="财务系统";break;case"5":o="成本系统";break;case"6":o="物流系统";break;case"7":o="固定资产系统";break;case"8":o="OA办公系统";break;case"9":o="电子档案系统";break;case"10":o="个人收入系统";break;case"11":o="奖金二次分配系统";break;case"12":o="财务管理系统";break;case"13":o="报销系统";break;case"14":o="科研管理系统";break;case"15":o="审计系统";break;case"16":o="分组器系统";break}return o},Jl=t=>t==="0"?"指标库":t==="1"?"视图":t==="2"?"数据集":"其他",ed=e.defineComponent({name:"IndSourceList",components:{CaretRightOutlined:Ma,CaretDownOutlined:Ia,LoadingOutlined:Fs,Draggable:Et,ATooltip:j.Tooltip},props:{data:{type:Array,default:()=>[]},source:{type:String,default:""},isSub:{type:Boolean,default:!1},hasChildren:{type:Boolean,default:!1},total:{type:Number,default:0},graphicConfig:{type:Object,default:()=>({})}},setup(t,{emit:o,expose:n}){var k;const a=(k=window==null?void 0:window.config)==null?void 0:k.pageId,l=e.inject(Ee),r=e.unref(e.inject(Be)),s=e.inject("setItemDisabled",_=>!1),d=e.ref([]),i=e.ref(),c=e.reactive({pageSize:20,currentPage:1,totalResult:0}),p=e.ref(!1),u=e.ref(""),f=e.ref(!1);e.watch(()=>t.data,_=>{t.isSub&&(_==null||_.forEach(E=>{var O;E!=null&&E.isLeaf||(O=E.dataViewColumns)==null||O.forEach(B=>{B.show=!0,B.edit=!1,B.title&&(B.label=B.title)})}),d.value=_)},{deep:!0,immediate:!0});const y=()=>{var _;t.isSub||(_=e.unref(i))==null||_.removeEventListener("scroll",g)},h=async _=>{var B;if(e.unref(p))return;const E=t.graphicConfig?t.graphicConfig.dataSourceId:"";p.value=!0;const O={source:t.source,pageId:a,dataSourceId:E,indexName:u.value};_?(_.loading=!0,O.indexTypeGuid=_.indexTypeGuid,O.isLeaf=_.isLeaf):c&&(O.queryRequest={pageSize:c.pageSize,pageNum:c.currentPage});try{const L=await l.post(`${Se}/diagram/sourceList`,O,{headers:{Authentication:r,operateContext:"ygt"}}),{success:D,data:I={}}=L.data;if(D){const{rows:$=[],total:x=0}=I;$==null||$.forEach(V=>{var T;(_==null?void 0:_.isLeaf)==="1"||t.graphicConfig.dataSourceId?(T=V.dataViewColumns)==null||T.forEach(P=>{P.show=!0,P.edit=!1,P.title&&(P.label=P.title)}):V.show=!1}),_?(_.children=$,_.show=!0,$!=null&&$.length||(_.noData=!0)):(d.value=e.unref(d).concat($),c.totalResult=+x,((B=e.unref(d))==null?void 0:B.length)>=x&&y())}_&&(_.loading=!1),p.value=!1}catch{_&&(_.loading=!1),p.value=!1}},b=async _=>{const E=d.value[_],{children:O=[]}=E;O!=null&&O.length?E.show=!E.show:!E.noData&&E.isLeaf?h(E):E.noData&&(E.show=!E.show)},m=(_,E)=>{o("onDragStart",_,E)},w=_=>{_.show=!_.show},g=_=>{_.target.scrollTop+_.target.clientHeight+20>=_.target.scrollHeight&&(c.currentPage++,h())},S=async()=>{await h(),e.nextTick(async()=>{e.unref(i).scrollHeight===e.unref(i).clientHeight&&c.totalResult>e.unref(d).length&&(c.currentPage++,S())})},C=async _=>{var E;y(),f.value=!0,c.currentPage=1,c.totalResult=0,d.value=[],u.value=_,await S(),f.value=!1,(E=e.unref(i))==null||E.addEventListener("scroll",g)};return e.onMounted(async()=>{var _;t.isSub||(S(),(_=e.unref(i))==null||_.addEventListener("scroll",g))}),e.onUnmounted(()=>{y()}),n({handleSearch:C}),{columnRef:i,sourceList:d,searchLoading:f,onToggleGroup:b,onToggleSource:w,setItemDisabled:s,onDragStart:m,mapDataSetScope:Kl,mapScope:ql,getLoadType:Xl,getUseType:Ql,getSourceType:Jl}}}),xy="",td={key:0,class:"no-data"},od={class:"column-item"},nd=["onClick"],ad={key:3,class:"item-name"},ld={key:0},rd={class:"column-item"},id={key:0},sd={key:1},cd={key:2},dd=["onClick"],pd={class:"column-child-item"},ud={class:"field"},fd={class:"column-child-item-name"};function md(t,o,n,a,l,r){const s=e.resolveComponent("loading-outlined"),d=e.resolveComponent("caret-down-outlined"),i=e.resolveComponent("caret-right-outlined"),c=e.resolveComponent("ind-source-list",!0),p=e.resolveComponent("a-tooltip"),u=e.resolveComponent("draggable"),f=e.resolveComponent("a-spin");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["columns",t.isSub?"sub-columns":""]),ref:"columnRef"},[e.createVNode(f,{spinning:t.searchLoading,tip:"数据源加载中..."},{default:e.withCtx(()=>{var y;return[!((y=t.sourceList)!=null&&y.length)&&!t.searchLoading?(e.openBlock(),e.createElementBlock("div",td,"暂无数据")):t.hasChildren?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.sourceList,(h,b)=>(e.openBlock(),e.createElementBlock("div",{key:h.indexTypeGuid||h.id},[e.createElementVNode("div",od,[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:m=>t.onToggleGroup(b)},[h.loading?(e.openBlock(),e.createBlock(s,{key:0})):h.show?(e.openBlock(),e.createBlock(d,{key:1})):(e.openBlock(),e.createBlock(i,{key:2})),h.isLeaf?(e.openBlock(),e.createElementBlock("span",ad,e.toDisplayString(h.indexTypeCode+"."+h.indexTypeName),1)):e.createCommentVNode("",!0)],8,nd)]),h.show?(e.openBlock(),e.createElementBlock("div",ld,[e.createVNode(c,{data:h.children,isSub:!0,hasChildren:h.isLeaf==="0",source:"INDICATOR_LIB",onOnDragStart:t.onDragStart},null,8,["data","hasChildren","onOnDragStart"])])):e.createCommentVNode("",!0)]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(t.sourceList,h=>(e.openBlock(),e.createElementBlock("div",{key:h.id,class:e.normalizeClass(t.setItemDisabled(h.dataViewColumns)?"column-disabled":"")},[e.createElementVNode("div",rd,[e.createVNode(p,null,{title:e.withCtx(()=>[e.createElementVNode("div",null,"加载类型:"+e.toDisplayString(t.getLoadType(h.loadType)),1),h.useType?(e.openBlock(),e.createElementBlock("div",id,"数据使用系统:"+e.toDisplayString(t.getUseType(h.useType)),1)):e.createCommentVNode("",!0),h.systemSource?(e.openBlock(),e.createElementBlock("div",sd,"制度出处:"+e.toDisplayString(h.systemSource),1)):e.createCommentVNode("",!0),h.dataTo?(e.openBlock(),e.createElementBlock("div",cd,"数据来源:"+e.toDisplayString(t.getSourceType(h.dataTo)),1)):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:b=>t.onToggleSource(h)},[h.show?(e.openBlock(),e.createBlock(d,{key:0})):(e.openBlock(),e.createBlock(i,{key:1})),e.createTextVNode(" "+e.toDisplayString((h.indexCode?h.indexCode:"")+" "+h.name),1)],8,dd)]),_:2},1024)]),h.show?(e.openBlock(),e.createBlock(u,{key:0,modelValue:h.dataViewColumns,"onUpdate:modelValue":b=>h.dataViewColumns=b,group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,disabled:t.setItemDisabled(h.dataViewColumns),onStart:b=>t.onDragStart(b,h)},{item:e.withCtx(({element:b})=>[e.createElementVNode("div",pd,[e.createElementVNode("span",ud," 【"+e.toDisplayString(b.scope==="FIELD"?t.mapDataSetScope(b.genericType):t.mapScope(b.scope))+"】 ",1),e.createElementVNode("span",fd,e.toDisplayString(b.label),1)])]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","onStart"])):e.createCommentVNode("",!0)],2))),128))]}),_:1},8,["spinning"])],2)}const hd=oe(ed,[["render",md],["__scopeId","data-v-e2cb0767"]]),bd=e.defineComponent({name:"DataSourceList",components:{CaretRightOutlined:Ma,CaretDownOutlined:Ia,IndSourceList:hd,AInputSearch:j.InputSearch,ASpin:j.Spin,APagination:j.Pagination,Draggable:Et,ATooltip:j.Tooltip},setup(){var k;const t=(k=window==null?void 0:window.config)==null?void 0:k.pageId,o=e.inject(Ee),n=e.unref(e.inject(Be)),a=e.inject(Ie),l=e.computed(()=>{var _;return(_=e.unref(a))==null?void 0:_.graphicConfig}),r=e.computed(()=>{var _;return(_=e.unref(l))==null?void 0:_.dataSourceId}),s=e.ref([]),d=e.ref(!1),i=e.ref(),c=e.reactive({pageSize:20,currentPage:1,totalResult:0}),p=e.inject(Wt),u=e.ref(""),f=async()=>{if(e.unref(w).source==="INDICATOR_LIB")return;d.value=!0;const _={source:e.unref(p),indexName:e.unref(u),pageId:t,dataSourceId:e.unref(r),queryRequest:{pageSize:c.pageSize,pageNum:c.currentPage}};_.source==="EDV_DATA_SET"&&(_.edvDataSetName=_.indexName,delete _.indexName);try{const E=await o.post(`${Se}/diagram/sourceList`,_,{headers:{Authentication:n,operateContext:"ygt"}});d.value=!1;const{success:O,data:B={}}=E.data;if(O){const{rows:L=[],total:D=0}=B;L==null||L.forEach(I=>{var $;I.show=!1,($=I.dataViewColumns)==null||$.forEach(x=>{x.show=!0,x.edit=!1,x.title&&(x.label=x.title)})}),s.value=L,c.totalResult=+D}}catch{d.value=!1}},y=_=>{s.value[_].show=!s.value[_].show},h=()=>{var _;c.currentPage=1,f(),e.unref(w).source==="INDICATOR_LIB"&&((_=e.unref(i))==null||_.handleSearch(e.unref(u)))},b=J.debounce(()=>{c.currentPage=1,f()},200),m=(_,E)=>{c.pageSize=E,c.currentPage=_,f()};e.onMounted(()=>{f()});const w=e.inject(Ce),g=e.computed(()=>{const _=["classificationList","rowHeaderList","dimensionList","queryColumnList"];let E=[];for(const O in e.unref(w))if(Object.prototype.hasOwnProperty.call(e.unref(w),O)&&_.includes(O)){const B=e.unref(w)[O];Array.isArray(B)&&(E=E.concat(B))}return E}),S=(_=[])=>{let E=!1;if(e.unref(p)==="EDV_DATA_SET"){for(const O of e.unref(g))if(!_.find(L=>L.parentId===O.parentId)){E=!0;break}}else for(const O of e.unref(g))if(!_.find(L=>L.typeGuid===O.typeGuid)){E=!0;break}return E};return e.provide("setItemDisabled",S),{dataSourceList:s,dataSourceLoading:d,pagination:c,onToggleGroup:y,mapScope:ql,mapDataSetScope:Kl,onSearch:h,onChange:b,source:p,onPaginationChange:m,searchText:u,setItemDisabled:S,onDragStart:(_,E)=>{const O=E.dataViewColumns[_.oldIndex];let B={};E.dataSetParams&&(B=E.dataSetParams),O&&(sessionStorage.setItem("indicator-list-item",JSON.stringify({...O,dataTo:E.dataTo,dataSetParams:B})),E.dataTo==="1"&&(E!=null&&E.hrpIndexVariates)&&sessionStorage.setItem("indicator-variates",JSON.stringify(E.hrpIndexVariates)),E.dataTo==="2"&&(E!=null&&E.dataSetParams)&&sessionStorage.setItem("indicator-variates",JSON.stringify(E.dataSetParams)))},getSourceType:Jl,getLoadType:Xl,getUseType:Ql,graphicConfig:w,indSourceRef:i}}}),_y="",yd={class:"data-source-list"},gd={class:"columns"},Cd={class:"column-item"},wd={key:0},kd={key:1},xd=["onClick"],_d={key:0},Sd={class:"column-child-item"},Nd={class:"column-child-item-name"};function Td(t,o,n,a,l,r){const s=e.resolveComponent("a-input-search"),d=e.resolveComponent("ind-source-list"),i=e.resolveComponent("caret-down-outlined"),c=e.resolveComponent("caret-right-outlined"),p=e.resolveComponent("a-tooltip"),u=e.resolveComponent("draggable"),f=e.resolveComponent("a-spin"),y=e.resolveComponent("a-pagination");return e.openBlock(),e.createElementBlock("div",yd,[e.createVNode(s,{value:t.searchText,"onUpdate:value":o[0]||(o[0]=h=>t.searchText=h),placeholder:"请输入关键字",style:{width:"100%"},onChange:t.onChange,onSearch:t.onSearch},null,8,["value","onChange","onSearch"]),t.graphicConfig.source==="INDICATOR_LIB"?(e.openBlock(),e.createBlock(d,{key:0,ref:"indSourceRef",data:t.dataSourceList,hasChildren:!t.graphicConfig.dataSourceId,isSub:!1,graphicConfig:t.graphicConfig,source:"INDICATOR_LIB",onSetItemDisabled:t.setItemDisabled,onOnDragStart:t.onDragStart},null,8,["data","hasChildren","graphicConfig","onSetItemDisabled","onOnDragStart"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",gd,[e.createVNode(f,{spinning:t.dataSourceLoading,tip:"数据源加载中..."},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dataSourceList,(h,b)=>(e.openBlock(),e.createElementBlock("div",{key:h.id,class:e.normalizeClass(t.setItemDisabled(h.dataViewColumns)?"column-disabled":"")},[e.createElementVNode("div",Cd,[e.createVNode(p,null,{title:e.withCtx(()=>[e.createElementVNode("div",null,"加载类型:"+e.toDisplayString(t.getLoadType(h.loadType)),1),h.useType?(e.openBlock(),e.createElementBlock("div",wd,"数据使用系统:"+e.toDisplayString(t.getUseType(h.useType)),1)):e.createCommentVNode("",!0),h.systemSource?(e.openBlock(),e.createElementBlock("div",kd,"制度出处:"+e.toDisplayString(h.systemSource),1)):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createElementVNode("span",{style:{cursor:"pointer"},onClick:m=>t.onToggleGroup(b)},[h.show?(e.openBlock(),e.createBlock(i,{key:0})):(e.openBlock(),e.createBlock(c,{key:1})),e.createTextVNode(" "+e.toDisplayString((h.indexCode?h.indexCode:"")+" "+h.name)+"【"+e.toDisplayString(t.getSourceType(h.dataTo))+"】 ",1)],8,xd)]),_:2},1024)]),h.show?(e.openBlock(),e.createElementBlock("div",_d,[e.createVNode(u,{modelValue:h.dataViewColumns,"onUpdate:modelValue":m=>h.dataViewColumns=m,group:{name:"cardItem",pull:"clone",put:!1},"item-key":"id",sort:!1,disabled:t.setItemDisabled(h.dataViewColumns),onStart:m=>t.onDragStart(m,h)},{item:e.withCtx(({element:m})=>[e.createElementVNode("div",Sd,[e.createTextVNode(" 【"+e.toDisplayString(m.scope==="FIELD"?t.mapDataSetScope(m.genericType):t.mapScope(m.scope))+"】 ",1),e.createElementVNode("span",Nd,e.toDisplayString(m.label),1)])]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","onStart"])])):e.createCommentVNode("",!0)],2))),128))]),_:1},8,["spinning"])]),e.createVNode(y,{size:"small","show-quick-jumper":"",pageSize:t.pagination.pageSize,"onUpdate:pageSize":o[1]||(o[1]=h=>t.pagination.pageSize=h),total:t.pagination.totalResult,"show-total":h=>`共 ${h} 条`,current:t.pagination.currentPage,"onUpdate:current":o[2]||(o[2]=h=>t.pagination.currentPage=h),onChange:t.onPaginationChange},null,8,["pageSize","total","show-total","current","onChange"])],64))])}const Ad=oe(bd,[["render",Td],["__scopeId","data-v-cac5fe5f"]]),Od=e.defineComponent({name:"DataList",components:{DataSourceList:Ad,DataViewList:ri},setup(){return{source:e.inject(Wt)}}});function Ed(t,o,n,a,l,r){const s=e.resolveComponent("data-view-list"),d=e.resolveComponent("data-source-list");return e.openBlock(),e.createElementBlock(e.Fragment,null,[t.source==="SQL_VIEW"?(e.openBlock(),e.createBlock(s,{key:0})):e.createCommentVNode("",!0),t.source==="INDICATOR_LIB"||t.source==="EDV_DATA_SET"?(e.openBlock(),e.createBlock(d,{key:1})):e.createCommentVNode("",!0)],64)}const Bd=oe(Od,[["render",Ed]]),Zl={mounted(t){t.focus()}},Vd=e.defineComponent({name:"CustomSortModal",props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""},sortList:{type:Array,default:()=>[]}},components:{Draggable:Et,AModal:j.Modal,AButton:j.Button,ASelect:j.Select,ASelectOption:j.SelectOption,DeleteOutlined:za},setup(t,{expose:o}){var B;const n=(B=window==null?void 0:window.config)==null?void 0:B.pageId,a=e.inject(Ee),l=e.unref(e.inject(Be)),r=e.inject(Ce),s=e.inject(Ne),d=e.computed(()=>e.unref(r).source),i=e.computed(()=>e.unref(r).dataViewId),c=e.ref([]),p=e.ref("1"),u=e.ref([]),f=L=>{const D=t.sortList.filter($=>!e.unref(u).find(x=>x.columnName===$.name)||L.columnName===$.name),I=[];return D.forEach(($,x)=>{I.includes($.name)?$.name=`${$.name}_ecanrepeat_${x}`:I.push($.name)}),D},y=async()=>{try{const L=await a.post(`${Se}/diagram/groupvalue`,{source:e.unref(d),dataViewId:e.unref(i),groupColumn:t.item.name,hrpIndexTypeGuid:t.item.typeGuid,pageId:n,pageFlag:!0,edvDataSetId:e.unref(r).edvDataSetId||""},{headers:{Authentication:l,operateContext:"ygt"}}),{success:D,data:I=[]}=L.data;D&&(c.value=I==null?void 0:I.slice(0,200))}catch(L){console.error(L)}},h=()=>{var x,V;const L=((x=e.unref(r)[t.type])==null?void 0:x.slice())||[],D=L[t.index],{label:I,name:$}=t.item;e.unref(p)==="2"?D.sort={label:I,columnName:$,type:"CUSTOM",customOrderColumns:e.unref(c)}:e.unref(p)==="1"&&((V=e.unref(u))!=null&&V.length?D.sort=J.cloneDeep(e.unref(u)):delete D.sort),s({[t.type]:L})};let b=!1;const m=()=>{b=!0},w=e.ref(!1),g=L=>{var I;const{sort:D}=L;D?Array.isArray(D)?(p.value=((I=D[0])==null?void 0:I.type)==="CUSTOM"?"2":"1",e.unref(p)==="1"?u.value=J.cloneDeep(D):u.value=[]):(p.value=(D==null?void 0:D.type)==="CUSTOM"?"2":"1",e.unref(p)==="1"?u.value=[J.cloneDeep(D)]:u.value=[]):u.value=[],w.value=!0},S=()=>{w.value=!1},C=()=>{e.unref(p)==="2"?(b&&h(),b=!1):h(),S()};return o({showModal:g}),e.watch(w,L=>{var D,I;if(L){const $=(I=(D=t.item)==null?void 0:D.sort)==null?void 0:I.customOrderColumns;$==null?y():c.value=$}else c.value=[];window.changeShowTable&&window.changeShowTable(!L)},{flush:"post"}),{visible:w,customSortList:c,activeKey:p,combSortList:u,getSortOptions:f,onChange:m,onDeleteConfig:()=>{var I;const L=((I=e.unref(r)[t.type])==null?void 0:I.slice())||[],D=L[t.index];delete D.sort,s({[t.type]:L}),S()},onCancel:C,onAddSort:()=>{e.unref(u).push({label:"",columnName:null,type:"COMBINATION",order:null})},handleDeleteSort:L=>{u.value.splice(L,1)},onColumnChange:L=>{const D=e.unref(u).find(I=>I.columnName===L);if(D){const I=t.sortList.find($=>$.name===L);I&&(D.label=I.label,I.defaultCode?D.defaultCode=I.defaultCode:delete D.defaultCode)}}}}}),Sy="",Ld={class:"button-wrapper"},vd={class:"list-wrapper"},$d={class:"button-wrapper"},Fd={class:"sort-item"};function Id(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-select-option"),c=e.resolveComponent("delete-outlined"),p=e.resolveComponent("a-tab-pane"),u=e.resolveComponent("draggable"),f=e.resolveComponent("a-tabs"),y=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(y,{title:"排序配置",visible:t.visible,"destroy-on-close":"",width:"50%",onCancel:t.onCancel,bodyStyle:{height:"70vh",overflow:"auto",padding:"10px 24px"},footer:null},{default:e.withCtx(()=>[e.createVNode(f,{activeKey:t.activeKey,"onUpdate:activeKey":o[1]||(o[1]=h=>t.activeKey=h)},{default:e.withCtx(()=>[e.createVNode(p,{key:"1",tab:"组合排序"},{default:e.withCtx(()=>[e.createElementVNode("div",Ld,[e.createVNode(s,{primary:"",onClick:t.onAddSort},{default:e.withCtx(()=>[e.createTextVNode(" 新增 ")]),_:1},8,["onClick"])]),e.createElementVNode("div",vd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.combSortList,(h,b)=>(e.openBlock(),e.createElementBlock("div",{class:"sort-row",key:b},[e.createVNode(d,{value:h.columnName,"onUpdate:value":m=>h.columnName=m,style:{width:"200px"},placeholder:"维度/指标",options:t.getSortOptions(h),fieldNames:{label:"label",value:"name"},onChange:t.onColumnChange},null,8,["value","onUpdate:value","options","onChange"]),e.createVNode(d,{value:h.order,"onUpdate:value":m=>h.order=m,style:{"margin-left":"10px",width:"100px"},placeholder:"升/降序"},{default:e.withCtx(()=>[e.createVNode(i,{value:"ASC"},{default:e.withCtx(()=>[e.createTextVNode("升序")]),_:1}),e.createVNode(i,{value:"DESC"},{default:e.withCtx(()=>[e.createTextVNode("降序")]),_:1})]),_:2},1032,["value","onUpdate:value"]),e.createVNode(c,{style:{color:"red","margin-left":"10px"},onClick:m=>t.handleDeleteSort(b)},null,8,["onClick"])]))),128))])]),_:1}),e.createVNode(p,{key:"2",tab:"自定义排序","force-render":""},{default:e.withCtx(()=>[e.createElementVNode("div",$d,[e.createVNode(s,{danger:"",onClick:t.onDeleteConfig},{default:e.withCtx(()=>[e.createTextVNode(" 删除配置 ")]),_:1},8,["onClick"])]),e.createVNode(u,{modelValue:t.customSortList,"onUpdate:modelValue":o[0]||(o[0]=h=>t.customSortList=h),class:"custom-sort-list","item-key":"id",put:!1,onChange:t.onChange},{item:e.withCtx(({element:h})=>[e.createElementVNode("div",Fd,e.toDisplayString(h),1)]),_:1},8,["modelValue","onChange"])]),_:1})]),_:1},8,["activeKey"])]),_:1},8,["visible","onCancel"])}const Dd=oe(Vd,[["render",Id],["__scopeId","data-v-6a468e35"]]),Md=e.defineComponent({name:"CustomGroupModal",directives:{focus:Zl},components:{CloseOutlined:Xt,AModal:j.Modal,ASelect:j.Select,ASelectOption:j.SelectOption,AButton:j.Button,AInput:j.Input,ACheckbox:j.Checkbox,ACollapse:j.Collapse,ACollapsePanel:j.CollapsePanel,ATag:j.Tag,ACheckableTag:j.CheckableTag},props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""}},setup(t,{expose:o}){var R;const n=e.inject(Ee),a=(R=window==null?void 0:window.config)==null?void 0:R.pageId,l=e.unref(e.inject(Be));let r=!1;const s=e.computed(()=>`自定义分组-${t.item.label}`),d=e.ref(null),i=e.ref([]),c=e.ref([]),p=e.computed(()=>{const N=e.unref(c).map(v=>v.title);return new Set(N)}),u=e.ref([]);e.watch(()=>e.unref(c).length,N=>{u.value=new Array(N).fill(!1)});const f=e.computed(()=>{let N=0;return e.unref(c).forEach(v=>{var A;(A=v.data)==null||A.forEach(F=>{F.checked&&N++})}),N}),y=()=>{const N=e.unref(d);if(!N){j.message.error("创建分组名不能空");return}e.unref(p).has(N)?j.message.error("分组名已存在,请重新命名"):(e.unref(c).push({title:N,data:[]}),r=!0)},h=N=>{e.unref(c).splice(N,1),r=!0},b=e.ref(null),m=()=>{if(e.unref(f)===0){j.message.error("当前移入分组已选个数为0");return}const N=e.unref(b);if(N==null){j.message.error("请选择移入分组");return}if(!e.unref(c)[N]){j.message.error("移入分组不存在,请重新选择");return}const v=[],A=e.unref(c).length;for(let F=0;F<A;F++){const M=e.unref(c)[F];e.unref(c)[F].data=M.data.filter(G=>(G.checked&&v.push({...G,checked:!1}),!G.checked))}e.unref(c)[N].data=[...v,...e.unref(c)[N].data],r=!0},w=N=>{e.unref(u)[N]=!0},g=N=>{e.unref(u)[N]=!1},S=(N,v)=>{const A=N.target.value;e.unref(p).has(A)&&j.message.error("组名不能相同,请修改"),e.unref(c)[v].title=A,r=!0},C=e.inject(Ce),k=e.inject(Ne),_=e.computed(()=>e.unref(C).source),E=e.computed(()=>e.unref(C).dataViewId),O=e.ref(!1),B=()=>{var W,X;const N=e.unref(c);let v="";e.unref(O)&&(v=(W=N[0])==null?void 0:W.title);const A=N==null?void 0:N.length,F={};for(let Q=1;Q<A;Q++){const Z=N[Q]||{},{title:ae,data:le}=Z;F[ae]=(le==null?void 0:le.map(_e=>_e.label))||[]}const M=((X=e.unref(C)[t.type])==null?void 0:X.slice())||[],G=M[t.index];G.customGroup={groupInfoMap:F,otherGroupName:v},k({[t.type]:M})},L=e.ref(!1),D=()=>{L.value=!0},I=()=>{L.value=!1},$=()=>{I(),r&&B(),r=!1},x=()=>{r=!0},V=new Set,T=async()=>{const N=t.item.customGroup||{},v=N.otherGroupName,A=N.groupInfoMap;(v===""||v==null)&&(O.value=!1),e.unref(c)[0]={title:v||"未分组",data:[]};let F=1;for(const M in A)if(Object.prototype.hasOwnProperty.call(A,M)){const W=A[M].map(X=>(V.add(X),{label:X,checked:!1}));e.unref(c)[F]={title:M,data:W},F++}await P()},P=async()=>{var N;try{const v=await n.post(`${Se}/diagram/groupvalue`,{source:e.unref(_),dataViewId:e.unref(E),groupColumn:t.item.name,hrpIndexTypeGuid:t.item.typeGuid,pageId:a,pageFlag:!0,edvDataSetId:e.unref(C).edvDataSetId||""},{headers:{Authentication:l,operateContext:"ygt"}}),{success:A,data:F=[]}=v.data;if(A){const M=[];(N=F==null?void 0:F.slice(0,200))==null||N.forEach(G=>{V.has(G)||M.push({label:G,checked:!1})}),e.unref(c)[0].data=M}}catch(v){console.error(v)}};return e.watch(L,N=>{N&&T(),window.changeShowTable&&window.changeShowTable(!N)},{flush:"post"}),o({showModal:D}),{visible:L,title:s,activeKey:i,customGroupList:c,onCancel:$,useOtherGroup:O,selectCount:f,createGroupTitle:d,onAddGroup:y,onDeleteGroup:h,onMoveInGroup:m,selectGroupIndex:b,onEditTitle:w,onTitleChange:S,onFinishEditTitle:g,onUseOtherGroup:x,customGroupEditTitleList:u}}}),Ny="",Ty="",Pd={class:"custom-group-header"},jd={class:"move-and-create"},Rd={class:"select-tip"},Ud={class:"select-count"},zd={class:"create-group"},Gd={class:"custom-group-content"},Hd=["onClick"],Wd={class:"extra"},Yd={class:"custom-group-list"},qd={class:"text"};function Kd(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-button"),c=e.resolveComponent("a-input"),p=e.resolveComponent("a-checkbox"),u=e.resolveComponent("a-tag"),f=e.resolveComponent("close-outlined"),y=e.resolveComponent("a-checkable-tag"),h=e.resolveComponent("a-collapse-panel"),b=e.resolveComponent("a-collapse"),m=e.resolveComponent("a-modal"),w=e.resolveDirective("focus");return e.openBlock(),e.createBlock(m,{title:t.title,visible:t.visible,"destroy-on-close":"",width:"50%",bodyStyle:{height:"70vh",overflow:"auto",display:"flex",flexDirection:"column"},footer:null,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",Pd,[e.createElementVNode("div",jd,[e.createElementVNode("div",null,[e.createElementVNode("span",Rd,[e.createTextVNode(" 已选"),e.createElementVNode("span",Ud,e.toDisplayString(t.selectCount),1),e.createTextVNode("个 ")]),e.createVNode(d,{value:t.selectGroupIndex,"onUpdate:value":o[0]||(o[0]=g=>t.selectGroupIndex=g),class:"select-group",placeholder:"请选择移入分组"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.customGroupList,(g,S)=>(e.openBlock(),e.createBlock(s,{key:S},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(g.title),1)]),_:2},1024))),128))]),_:1},8,["value"]),e.createVNode(i,{onClick:t.onMoveInGroup},{default:e.withCtx(()=>[e.createTextVNode("移入分组")]),_:1},8,["onClick"])]),e.createElementVNode("div",zd,[e.createTextVNode(" 创建分组: "),e.createVNode(c,{class:"create-group-name",value:t.createGroupTitle,"onUpdate:value":o[1]||(o[1]=g=>t.createGroupTitle=g),placeholder:"请输入创建分组名",onPressEnter:t.onAddGroup},null,8,["value","onPressEnter"])])]),e.createElementVNode("div",null,[e.createVNode(p,{checked:t.useOtherGroup,"onUpdate:checked":o[2]||(o[2]=g=>t.useOtherGroup=g),onChange:t.onUseOtherGroup},{default:e.withCtx(()=>[e.createTextVNode(" 将未分组设为其他分组 ")]),_:1},8,["checked","onChange"])])]),e.createElementVNode("div",Gd,[e.createVNode(b,{activeKey:t.activeKey,"onUpdate:activeKey":o[3]||(o[3]=g=>t.activeKey=g),ghost:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.customGroupList,(g,S)=>(e.openBlock(),e.createBlock(h,{key:S},{header:e.withCtx(()=>[t.customGroupEditTitleList[S]?e.withDirectives((e.openBlock(),e.createBlock(c,{key:1,class:"edit-title-input",value:g.title,size:"small",onChange:C=>t.onTitleChange(C,S),onBlur:C=>t.onFinishEditTitle(S),onPressEnter:C=>t.onFinishEditTitle(S)},null,8,["value","onChange","onBlur","onPressEnter"])),[[w]]):(e.openBlock(),e.createElementBlock("div",{key:0,onClick:e.withModifiers(C=>t.onEditTitle(S),["prevent","stop"])},e.toDisplayString(g.title),9,Hd))]),extra:e.withCtx(()=>[e.createElementVNode("div",Wd,[S===0&&t.useOtherGroup?(e.openBlock(),e.createBlock(u,{key:0,class:"tag",color:"blue"},{default:e.withCtx(()=>[e.createTextVNode(" 其他组 ")]),_:1})):e.createCommentVNode("",!0),S!==0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(u,{class:"tag",color:"green"},{default:e.withCtx(()=>[e.createTextVNode(" 自定义组 ")]),_:1}),e.createVNode(f,{onClick:e.withModifiers(C=>t.onDeleteGroup(S),["prevent","stop"])},null,8,["onClick"])],64)):e.createCommentVNode("",!0)])]),default:e.withCtx(()=>[e.createElementVNode("div",Yd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.data,(C,k)=>(e.openBlock(),e.createBlock(y,{color:"red",checked:C.checked,"onUpdate:checked":_=>C.checked=_,class:"custom-group",key:k},{default:e.withCtx(()=>[e.createElementVNode("span",qd,e.toDisplayString(C.label),1)]),_:2},1032,["checked","onUpdate:checked"]))),128))])]),_:2},1024))),128))]),_:1},8,["activeKey"])])]),_:1},8,["title","visible","onCancel"])}const Xd=oe(Md,[["render",Kd],["__scopeId","data-v-a0733a80"]]);let ge=(t=21)=>{let o="",n=crypto.getRandomValues(new Uint8Array(t));for(;t--;){let a=n[t]&63;a<36?o+=a.toString(36):a<62?o+=(a-26).toString(36).toUpperCase():a<63?o+="_":o+="-"}return o};var Qd=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},zn={},Jd={get exports(){return zn},set exports(t){zn=t}};(function(t,o){(function(n,a){t.exports=a()})(Qd,function(){var n="month",a="quarter";return function(l,r){var s=r.prototype;s.quarter=function(c){return this.$utils().u(c)?Math.ceil((this.month()+1)/3):this.month(this.month()%3+3*(c-1))};var d=s.add;s.add=function(c,p){return c=Number(c),this.$utils().p(p)===a?this.add(3*c,n):d.bind(this)(c,p)};var i=s.startOf;s.startOf=function(c,p){var u=this.$utils(),f=!!u.u(p)||p;if(u.p(c)===a){var y=this.quarter()-1;return f?this.month(3*y).startOf(n).startOf("day"):this.month(3*y+2).endOf(n).endOf("day")}return i.bind(this)(c,p)}}})})(Jd);const Zd=zn;he.extend(Zd);const ep=e.defineComponent({name:"Condition",components:{CloseOutlined:Xt,DownOutlined:As,AppstoreAddOutlined:cn,ASelect:j.Select,AInput:j.Input,ADatePicker:j.DatePicker,AButton:j.Button,ADropdown:j.Dropdown,AMenu:j.Menu,AMenuItem:j.MenuItem,ASubMenu:j.SubMenu,APopover:j.Popover,ATabs:j.Tabs,ATabPane:j.TabPane,ARadioGroup:j.RadioGroup,ARadio:j.Radio,AInputNumber:j.InputNumber,ASelectOption:j.SelectOption,MenuOutlined:kn},props:{data:{type:Object,default:()=>({})},level:{type:Number,default:0},index:{type:Number,default:0},type:{type:String,default:""},path:{type:String,default:""}},setup(t){var Ht,Nt,$e,tt,ot,nt,Fe,Tt,at,ft,At,Wo,bo,yo,go;const o=(Ht=window==null?void 0:window.config)==null?void 0:Ht.pageId,n=e.inject(Ce),a=e.inject(Ee),l=e.unref(e.inject(Be)),r=e.inject(ua),s=e.inject(Ue),d=e.ref(!1),i=he(),c=e.computed(()=>{var q;const H=[];return(q=e.unref(s))==null||q.forEach(ee=>{const{keyName:ne="",id:re="",type:ue}=ee;ue==="ecanRangePicker"?H.push({value:`${re}-startTime`,label:`${ne||re}-开始时间值`,keyName:`${ne||re}-startTime`,id:re},{value:`${re}-endTime`,label:`${ne||re}-结束时间值`,keyName:`${ne||re}-endTime`,id:re}):H.push({value:re,label:`${ne||re}`,keyName:`${ne||re}`,id:re})}),H}),p=e.computed(()=>[{label:"父页面",value:"PARENT",id:"PARENT",keyName:"PARENT"},...e.unref(c)]),u=e.computed(()=>{var H;return(H=e.unref(n))==null?void 0:H.dataViewId}),f=e.computed(()=>{var H;return(H=e.unref(n))==null?void 0:H.source}),y=e.ref(!1),h={display:"block",height:"34px",lineHeight:"34px",marginTop:"3px"},b=[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}],m=e.ref({expression:"rangeValue",unit:"YEAR",around:"before"}),w=e.ref([{key:0,value:"",label:"年",type:"years",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"年前",afterLabel:"年后",beforeText:"年初",afterText:"年末"},{key:1,value:"",label:"季度",type:"quarters",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"个季度前",afterLabel:"个季度后",beforeText:"季度初",afterText:"季度末"},{key:2,value:"",label:"月",type:"months",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"个月前",afterLabel:"个月后",beforeText:"月初",afterText:"月末"},{key:3,value:"",label:"周",type:"weeks",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"周前",afterLabel:"周后",beforeText:"",afterText:""},{key:4,value:"",label:"天",type:"days",radioValue:"1",beforeNum:0,afterNum:0,beforeLabel:"天前",afterLabel:"天后",beforeText:"今天",afterText:""}]),g=[{label:"年份",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"季的季度",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"月的月份",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"周的周",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"},{label:"天的日期",text:"年",yearNum:0,yearRule:"before",otherNum:0,otherRule:"before"}],S=[{label:"时间值",value:"time"},{label:"过滤组件值",value:"component"}],C=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],k=e.ref({fieldName:(Nt=t.data)==null?void 0:Nt.fieldName,fieldType:($e=t.data)==null?void 0:$e.fieldType,rule:(tt=t.data)==null?void 0:tt.rule,id:(ot=t.data)==null?void 0:ot.id,fieldValue:_(),label:(nt=t.data)==null?void 0:nt.label,targetSource:"",typeGuid:(Fe=t.data)==null?void 0:Fe.typeGuid,indexCode:(Tt=t.data)==null?void 0:Tt.indexCode,indexCodeNum:(at=t.data)==null?void 0:at.indexCodeNum,dataType:((ft=t.data)==null?void 0:ft.dataType)||"",componentId:((At=t.data)==null?void 0:At.componentId)||"",useCurrentTime:!!((Wo=t.data)!=null&&Wo.useCurrentTime),keyValue:(bo=t.data)==null?void 0:bo.keyValue,modelKey:(yo=t.data)==null?void 0:yo.modelKey,prop:(go=t.data)==null?void 0:go.prop});function _(){const{fieldType:H="",dataType:q="",fieldValue:ee=""}=t.data;if(H==="DATE"&&q==="time")return ee&&he(ee);if(q==="component"){const ne=e.unref(c).find(re=>re.keyName===ee);return ne?ne.value:ee}else return ee}const E=e.ref([]),O=e.ref(!1),B=e.computed(()=>k.value.fieldType==="DATE"),L=e.computed(()=>{const H=t.type,{source:q}=e.unref(n);let ee=[];const ne=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],re=["controlList","sqlConditions","variableList","variableConditions"];if(q==="EDV_DATA_SET")ee=E.value;else if(ne.includes(H)){let ue=[];for(const U in e.unref(n))if(Object.prototype.hasOwnProperty.call(e.unref(n),U)&&!re.includes(U)){const z=e.unref(n)[U];Array.isArray(z)&&(ne.includes(U)?ue=ue.concat(z.filter(Y=>Y.show)):ue=ue.concat(z))}ee=ue}else["leftAxisList","rightAxisList","indicators"].includes(H)&&(ee=e.unref(r));return ee.map(ue=>({...ue,label:ue.label||ue.title,value:ue.name}))}),{updateCondition:D,deleteCondition:I,addCondition:$}=e.inject(wo,{updateCondition:(H,q,ee)=>{},deleteCondition:(H,q)=>{},addCondition:(H,q,ee)=>{}}),x=()=>{I(t.index,t.path)};e.watch(k,H=>{const q=J.cloneDeep(H);H.fieldType==="DATE"&&H.dataType!=="component"&&H.fieldValue&&(q.fieldValue=H.fieldValue.format(H.dateFormat)),D(q,t.index,t.path)},{deep:!0}),e.watch(d,H=>{k.value.fieldValue="",k.value.useCurrentTime=H});const V=H=>{var ie;const q=e.unref(L).find(se=>se.value===H)||{},{name:ee,genericType:ne,id:re,edvDataSetId:ue,label:U,typeGuid:z,indexCode:Y,indexCodeNum:K}=q;k.value={id:re,fieldName:ee,fieldType:ne,label:U,rule:"",fieldValue:ne==="DATE"?null:void 0,targetSource:"",typeGuid:z,indexCode:Y,edvDataSetId:ue,indexCodeNum:K,dataType:"",useCurrentTime:!1,keyValue:((ie=e.unref(k))==null?void 0:ie.keyValue)||ge(),modelKey:"",prop:""}},T=H=>{const q=e.unref(c).find(ee=>ee.value===H)||{};e.unref(k).componentId=q.id||""},P=e.computed(()=>{const H=e.unref(k).fieldType;return H==="TEXT"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"包含",value:"LIKE"},{label:"不包含",value:"NOT_LIKE"},{label:"开头是",value:"LIKE%"},{label:"结尾是",value:"%LIKE"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"}]:H==="NUMBER"?[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:H==="DATE"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]}),R=e.computed(()=>{let H="";const q=e.unref(P).find(ee=>ee.value===e.unref(k).rule);return q&&(H=q.label),H}),N=e.computed(()=>{let H={fontSize:"12px"};return e.unref(R)||(H={...H,position:"absolute",right:"11px",top:"9px"}),H}),v=e.ref([]),A=async()=>{var H;if(!(e.unref(v).length>0))try{const q=await a.post(`${Se}/diagram/groupvalue`,{source:e.unref(f),dataViewId:e.unref(u),groupColumn:e.unref(k).fieldName,hrpIndexTypeGuid:e.unref(k).typeGuid,pageId:o,pageFlag:!0,edvDataSetId:e.unref(k).edvDataSetId||""},{headers:{Authentication:l,operateContext:"ygt"}}),{success:ee,data:ne=[]}=q.data;ee&&(v.value=(H=ne==null?void 0:ne.slice(0,200))==null?void 0:H.map(re=>({label:re,value:re})))}catch(q){console.error(q)}},F=H=>{e.unref(k).rule=H,e.unref(k).fieldValue=e.unref(k).fieldType==="DATE"?null:void 0,["IN","NOT_IN"].includes(H)&&A()},M=H=>{e.unref(k).dataType=H,e.unref(k).fieldValue="",e.unref(k).modelKey="",e.unref(k).prop=""},G=e.ref(),W=H=>{G.value=H,e.unref(k).fieldValue=(H==null?void 0:H.join(","))||""},X=H=>{const{keyPath:q}=H;e.unref(k).rule=q[0],e.unref(k).dataType=q[1],e.unref(k).dateFormat=q[2],e.unref(k).fieldValue="",e.unref(k).modelKey="",e.unref(k).prop=""};e.onMounted(async()=>{var re,ue,U,z,Y,K,ie,se,te,be;if(k.value.dataType=((re=t.data)==null?void 0:re.dataType)||"",k.value.componentId=((ue=t.data)==null?void 0:ue.componentId)||"",k.value.keyValue=(U=t.data)==null?void 0:U.keyValue,k.value.modelKey=(z=t.data)==null?void 0:z.modelKey,k.value.prop=(Y=t.data)==null?void 0:Y.prop,e.unref(k).fieldType==="DATE"){const{activeKey:de,dateCalcTypes:ce=[]}=t.data||{};if(e.unref(k).dateFormat=(K=t.data)==null?void 0:K.dateFormat,e.unref(k).activeKey=de,e.unref(k).calcWays=((ie=t.data)==null?void 0:ie.calcWays)||[],e.unref(k).dateCalcTypes=ce,e.unref(k).useCurrentTime&&e.unref(k).dataType!=="component"&&(d.value=!0),de===5){const ye=e.unref(k).calcWays[0];if(ye){const fe=ye.split("-");e.unref(m).expression=fe[0],e.unref(m).around=fe[1]}e.unref(m).unit=ce[0]||"YEAR"}else{e.unref(k).radioValue=((se=t.data)==null?void 0:se.radioValue)||"";const ye=e.unref(w).find(fe=>{var ke;return fe.key===((ke=t.data)==null?void 0:ke.activeKey)});ye&&Xe(ye,t.data)}}else G.value=((be=(te=t.data)==null?void 0:te.fieldValue)==null?void 0:be.split(","))||[];const{fieldType:H,fieldName:q,rule:ee}=k.value;H!=="DATE"&&q&&ee&&["IN","NOT_IN"].includes(ee)&&A();const{source:ne}=e.unref(n);ne==="EDV_DATA_SET"&&await a.get(`${Se}/dataset/`+e.unref(n).edvDataSetId||"",{headers:{Authentication:l,operateContext:"ygt"}}).then(de=>{de.data.success&&(console.log(de.data),E.value=de.data.data.column.map(ce=>({...ce,genericType:ce.columnCategory==="0"?"TEXT":ce.columnCategory==="1"?"NUMBER":"DATE",edvDataSetId:de.data.data.id,name:ce.columnName,label:ce.columnName})))}).catch(de=>{console.error(de)})});const Q=H=>{if(e.unref(k).activeKey===H){e.unref(w)[H].radioValue=e.unref(k).radioValue,e.unref(w)[e.unref(k).activeKey]&&(e.unref(w)[e.unref(k).activeKey].radioValue=e.unref(k).radioValue,e.unref(k).radioValue==="1"?e.unref(w)[H].beforeNum=e.unref(k).calcWays[0]:e.unref(k).radioValue==="2"&&(e.unref(w)[H].afterNum=e.unref(k).calcWays[0]));return}e.unref(w).forEach(q=>{q.beforeNum=0,q.afterNum=0,q.radioValue="1",q.value=""})},Z=(H,q)=>{y.value=!0;const ee=H.target.value,ne=q.type,re=e.unref(k).dateFormat,ue=Math.abs(q.beforeNum),U=q.afterNum;q.value=pe(ee,ne,re,ue,U)},ae=H=>{const q=e.unref(k).activeKey;if(H!==q)return;let ee="";q===0?ee="years":q===1?ee="quarters":q===2?ee="months":q===3?ee="weeks":q===4&&(ee="days");const ne=e.unref(k).dateFormat,re=e.unref(k).radioValue;let ue=0,U=0;return re==="1"?ue=Math.abs(e.unref(k).calcWays[0]):re==="2"&&(U=e.unref(k).calcWays[0]),pe(re,ee,ne,ue,U)},le=(H,q,ee,ne)=>{if(y.value=!0,q.radioValue===ne){const re=H.target.value;ee==="+"?q.value=he().add(re,q.type).format(e.unref(k).dateFormat):q.value=he().subtract(re,q.type).format(e.unref(k).dateFormat)}},_e=(H,q)=>{e.unref(k).calcWays||(e.unref(k).calcWays=[]),e.unref(k).activeKey=q,e.unref(k).radioValue=H.radioValue,H.radioValue==="1"?e.unref(k).calcWays[0]="-"+H.beforeNum:H.radioValue==="2"?e.unref(k).calcWays[0]=H.afterNum:H.radioValue==="3"?q===4?e.unref(k).calcWays[0]="0":e.unref(k).calcWays[0]="BEGIN":H.radioValue==="4"&&(e.unref(k).calcWays[0]="END"),q===0?e.unref(k).dateCalcTypes=["YEAR"]:q===1?e.unref(k).dateCalcTypes=["QUARTER"]:q===2?e.unref(k).dateCalcTypes=["MONTH"]:q===3?e.unref(k).dateCalcTypes=["WEEK"]:q===4&&(e.unref(k).dateCalcTypes=["DAY"]),O.value=!1},St=()=>{e.unref(k).activeKey=5,e.unref(k).dateCalcTypes=[e.unref(m).unit],e.unref(k).calcWays[0]=`${e.unref(m).expression}-${e.unref(m).around}`,O.value=!1};function Xe(H,q){const{radioValue:ee="",calcWays:ne=[]}=q;H.radioValue=ee,ne!=null&&ne.length&&(ee==="1"?H.beforeNum=Math.abs(ne[0]):ee==="2"&&(H.afterNum=ne[0]))}function pe(H,q,ee,ne,re){if(H==="1")return he().subtract(ne,q).format(ee);if(H==="2")return he().add(re,q).format(ee);if(H==="3"){if(q==="years")return he().startOf("year").format(ee);if(q==="quarters")return he().startOf("quarter").format(ee);if(q==="months")return he().startOf("month").format(ee);if(q==="days")return he().format(ee)}else if(H==="4"){if(q==="years")return he().endOf("year").format(ee);if(q==="quarters")return he().endOf("quarter").format(ee);if(q==="months")return he().endOf("month").format(ee)}return""}const Oe=(H,q)=>q.label.toLowerCase().indexOf(H.toLowerCase())>=0,ut=e.computed(()=>!["IN","NOT_IN"].includes(e.unref(k).rule));return{fieldOptions:L,ruleOptions:P,onFieldChange:V,condition:k,valueOptions:v,onRuleChange:F,onDataTypeChange:M,onFieldValueSelectChange:W,fieldValues:G,onDelete:x,isDateType:B,formatList:b,tabDateList:w,compareList:g,menuRule:S,dateBtnLabel:R,downIconStyle:N,popoverVisible:O,dateRadioStyle:h,showTime:y,controlList:c,keyNameOptions:p,dataTypeList:C,customTabData:m,isUseCurrentTime:d,currentTime:i,isShowCustomDataType:ut,handleMenuClick:X,changeTabInitDate:Q,changeRadioValue:Z,getFieldValue:ae,blurCompare:le,okDatePickConfig:_e,onChangeComponent:T,filterOption:Oe,okCustomConfig:St,clickConditionMenu:({key:H})=>{$(t.path,t.index,H==="2"?"||":"&&")},dataSetfieldOptions:E}}}),Ay="",Oy="",tp={class:"condition"},op=["title"],np={class:"rule"},ap={class:"data-type"},lp={key:0,class:"field-value",style:{display:"flex","align-items":"center"}},rp={class:"popover-content-wrap"},ip={key:0,class:"use-current-time"},sp={class:"tabFilterRadio"},cp={key:0},dp={key:1},pp={style:{"margin-left":"10px"}},up={style:{"margin-left":"10px"}},fp={style:{position:"absolute",bottom:"10px"}},mp={style:{display:"flex"}},hp={style:{position:"absolute",bottom:"10px",left:"0","text-align":"center",width:"100%"}};function bp(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-menu-item"),c=e.resolveComponent("a-sub-menu"),p=e.resolveComponent("a-menu"),u=e.resolveComponent("DownOutlined"),f=e.resolveComponent("a-button"),y=e.resolveComponent("a-dropdown"),h=e.resolveComponent("a-date-picker"),b=e.resolveComponent("a-input"),m=e.resolveComponent("a-checkbox"),w=e.resolveComponent("a-input-number"),g=e.resolveComponent("a-radio"),S=e.resolveComponent("a-radio-group"),C=e.resolveComponent("a-tab-pane"),k=e.resolveComponent("a-tabs"),_=e.resolveComponent("appstore-add-outlined"),E=e.resolveComponent("a-popover"),O=e.resolveComponent("menu-outlined"),B=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",tp,[e.createVNode(d,{class:"field-name",value:t.condition.fieldName,onChange:t.onFieldChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.fieldOptions,(L,D)=>(e.openBlock(),e.createBlock(s,{key:D,value:L.value},{default:e.withCtx(()=>[e.createElementVNode("span",{title:L.label},e.toDisplayString(L.label),9,op)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"]),e.createElementVNode("div",np,[t.isDateType?(e.openBlock(),e.createBlock(y,{key:0,class:"dropdown",trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.handleMenuClick},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.ruleOptions,L=>(e.openBlock(),e.createBlock(c,{key:L.value},{title:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===L.value?"color: #1890FF;":"")},e.toDisplayString(L.label),5)]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.menuRule,D=>{var I;return e.openBlock(),e.createBlock(c,{key:D.value,disabled:D.value==="component"&&!((I=t.controlList)!=null&&I.length)},{title:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===L.value&&t.condition.dataType===D.value?"color: #1890FF;":"")},e.toDisplayString(D.label),5)]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formatList,$=>(e.openBlock(),e.createBlock(i,{key:$.value},{default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(t.condition.rule===L.value&&t.condition.dataType===D.value&&t.condition.dateFormat===$.value?"color: #1890FF;":"")},e.toDisplayString($.label),5)]),_:2},1024))),128))]),_:2},1032,["disabled"])}),128))]),_:2},1024))),128))]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.dateBtnLabel)+" ",1),e.createVNode(u,{style:e.normalizeStyle(t.downIconStyle)},null,8,["style"])]),_:1})]),_:1})):(e.openBlock(),e.createBlock(d,{key:1,style:{width:"100%"},value:t.condition.rule,options:t.ruleOptions,onChange:t.onRuleChange},null,8,["value","options","onChange"]))]),e.withDirectives(e.createElementVNode("div",ap,[e.createVNode(d,{style:{width:"100%"},value:t.condition.dataType,onChange:t.onDataTypeChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dataTypeList,(L,D)=>(e.openBlock(),e.createBlock(s,{key:D,value:L.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(L.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])],512),[[e.vShow,(!t.condition.fieldType||["TEXT","NUMBER"].includes(t.condition.fieldType))&&t.isShowCustomDataType]]),t.isDateType?(e.openBlock(),e.createElementBlock("div",lp,[t.condition.dataType==="time"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.isUseCurrentTime?(e.openBlock(),e.createBlock(h,{key:0,disabled:"",style:{width:"calc(100% - 35px)","margin-right":"10px"},value:t.currentTime,format:t.condition.dateFormat},null,8,["value","format"])):(e.openBlock(),e.createBlock(h,{key:1,style:{width:"calc(100% - 35px)","margin-right":"10px"},value:t.condition.fieldValue,"onUpdate:value":o[0]||(o[0]=L=>t.condition.fieldValue=L),format:t.condition.dateFormat},null,8,["value","format"]))],64)):typeof t.condition.fieldValue=="string"?(e.openBlock(),e.createBlock(d,{key:1,"show-search":"",style:e.normalizeStyle({width:t.condition.fieldValue==="PARENT"?"":"calc(100% - 35px)",marginRight:"10px"}),value:t.condition.fieldValue,"onUpdate:value":o[1]||(o[1]=L=>t.condition.fieldValue=L),"filter-option":t.filterOption,options:t.keyNameOptions,onChange:t.onChangeComponent},null,8,["style","value","filter-option","options","onChange"])):e.createCommentVNode("",!0),t.condition.fieldValue==="PARENT"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(b,{class:"field-value",value:t.condition.modelKey,"onUpdate:value":o[2]||(o[2]=L=>t.condition.modelKey=L),placeholder:"组件别名",style:{margin:"0"}},null,8,["value"]),e.createVNode(b,{class:"field-value",value:t.condition.prop,"onUpdate:value":o[3]||(o[3]=L=>t.condition.prop=L),placeholder:"属性名"},null,8,["value"])],64)):e.createCommentVNode("",!0),e.createVNode(E,{visible:t.popoverVisible,"onUpdate:visible":o[11]||(o[11]=L=>t.popoverVisible=L),trigger:"click",placement:"bottomRight"},{content:e.withCtx(()=>[e.createElementVNode("div",rp,[t.condition.dataType!=="component"?(e.openBlock(),e.createElementBlock("div",ip,[e.createVNode(m,{checked:t.isUseCurrentTime,"onUpdate:checked":o[4]||(o[4]=L=>t.isUseCurrentTime=L)},{default:e.withCtx(()=>[e.createTextVNode("使用当前时间")]),_:1},8,["checked"])])):e.createCommentVNode("",!0),e.createVNode(k,{defaultActiveKey:t.condition.activeKey,onChange:t.changeTabInitDate},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tabDateList,(L,D)=>(e.openBlock(),e.createBlock(C,{key:D,tab:L.label},{default:e.withCtx(()=>[e.createElementVNode("div",sp,[e.createVNode(S,{value:L.radioValue,"onUpdate:value":I=>L.radioValue=I,onChange:I=>t.changeRadioValue(I,L)},{default:e.withCtx(()=>[t.showTime?(e.openBlock(),e.createElementBlock("div",cp,"相对当前时间:"+e.toDisplayString(L.value),1)):(e.openBlock(),e.createElementBlock("div",dp,"相对当前时间:"+e.toDisplayString(t.getFieldValue(D)),1)),e.createVNode(g,{style:e.normalizeStyle(t.dateRadioStyle),value:"1"},{default:e.withCtx(()=>[e.createVNode(w,{value:L.beforeNum,"onUpdate:value":I=>L.beforeNum=I,min:0,onBlur:I=>t.blurCompare(I,L,"-","1")},null,8,["value","onUpdate:value","onBlur"]),e.createElementVNode("span",pp,e.toDisplayString(L.beforeLabel),1)]),_:2},1032,["style"]),e.createVNode(g,{style:e.normalizeStyle(t.dateRadioStyle),value:"2"},{default:e.withCtx(()=>[e.createVNode(w,{value:L.afterNum,"onUpdate:value":I=>L.afterNum=I,min:0,onBlur:I=>t.blurCompare(I,L,"+","2")},null,8,["value","onUpdate:value","onBlur"]),e.createElementVNode("span",up,e.toDisplayString(L.afterLabel),1)]),_:2},1032,["style"]),L.beforeText?(e.openBlock(),e.createBlock(g,{key:2,style:e.normalizeStyle(t.dateRadioStyle),value:"3"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(L.beforeText),1)]),_:2},1032,["style"])):e.createCommentVNode("",!0),L.afterText?(e.openBlock(),e.createBlock(g,{key:3,style:e.normalizeStyle(t.dateRadioStyle),value:"4"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(L.afterText),1)]),_:2},1032,["style"])):e.createCommentVNode("",!0)]),_:2},1032,["value","onUpdate:value","onChange"]),e.createElementVNode("div",fp,[e.createVNode(f,{style:{"margin-right":"12px"},onClick:o[5]||(o[5]=I=>t.popoverVisible=!1)},{default:e.withCtx(()=>[e.createTextVNode("取消")]),_:1}),e.createVNode(f,{onClick:I=>t.okDatePickConfig(L,D)},{default:e.withCtx(()=>[e.createTextVNode("确定")]),_:2},1032,["onClick"])])])]),_:2},1032,["tab"]))),128)),(e.openBlock(),e.createBlock(C,{tab:"自定义",key:5},{default:e.withCtx(()=>[e.createElementVNode("div",mp,[e.createVNode(d,{value:t.customTabData.expression,"onUpdate:value":o[6]||(o[6]=L=>t.customTabData.expression=L),allowClear:"",style:{width:"120px","margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(s,{value:"rangeValue"},{default:e.withCtx(()=>[e.createTextVNode("范围差值")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.customTabData.unit,"onUpdate:value":o[7]||(o[7]=L=>t.customTabData.unit=L),style:{"margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(s,{value:"YEAR"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(s,{value:"QUARTER"},{default:e.withCtx(()=>[e.createTextVNode("季度")]),_:1}),e.createVNode(s,{value:"MONTH"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(s,{value:"WEEK"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(s,{value:"DAY"},{default:e.withCtx(()=>[e.createTextVNode("天")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.customTabData.around,"onUpdate:value":o[8]||(o[8]=L=>t.customTabData.around=L)},{default:e.withCtx(()=>[e.createVNode(s,{value:"before"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(s,{value:"after"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value"])]),e.createElementVNode("div",hp,[e.createVNode(f,{style:{"margin-right":"12px"},onClick:o[9]||(o[9]=L=>t.popoverVisible=!1)},{default:e.withCtx(()=>[e.createTextVNode("取消")]),_:1}),e.createVNode(f,{onClick:t.okCustomConfig},{default:e.withCtx(()=>[e.createTextVNode("确定")]),_:1},8,["onClick"])])]),_:1}))]),_:1},8,["defaultActiveKey","onChange"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:"calendar-wrap",onClick:o[10]||(o[10]=L=>{t.popoverVisible=!0})},[e.createVNode(_)])]),_:1},8,["visible"])])):["IN","NOT_IN"].includes(t.condition.rule||"")?(e.openBlock(),e.createBlock(d,{key:1,class:"field-value",value:t.fieldValues,mode:"multiple",options:t.valueOptions,onChange:t.onFieldValueSelectChange},null,8,["value","options","onChange"])):(!t.condition.fieldType||["TEXT","NUMBER"].includes(t.condition.fieldType))&&t.isShowCustomDataType&&t.condition.dataType==="component"?(e.openBlock(),e.createBlock(d,{key:2,class:"field-value","show-search":"",value:t.condition.fieldValue,"onUpdate:value":o[12]||(o[12]=L=>t.condition.fieldValue=L),"filter-option":t.filterOption,options:t.keyNameOptions,onChange:t.onChangeComponent},null,8,["value","filter-option","options","onChange"])):(e.openBlock(),e.createBlock(b,{key:3,class:"field-value",value:t.condition.fieldValue,"onUpdate:value":o[13]||(o[13]=L=>t.condition.fieldValue=L)},null,8,["value"])),!t.isDateType&&t.condition.fieldValue==="PARENT"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createVNode(b,{class:"field-value",value:t.condition.modelKey,"onUpdate:value":o[14]||(o[14]=L=>t.condition.modelKey=L),placeholder:"组件别名",style:{margin:"0"}},null,8,["value"]),e.createVNode(b,{class:"field-value",value:t.condition.prop,"onUpdate:value":o[15]||(o[15]=L=>t.condition.prop=L),placeholder:"属性名"},null,8,["value"])],64)):e.createCommentVNode("",!0),e.createVNode(y,{trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.clickConditionMenu},{default:e.withCtx(()=>[e.createVNode(i,{key:"1"},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(i,{key:"2"},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(O,{class:"more-icon"})]),_:1}),e.createVNode(B,{class:"delete-icon",onClick:t.onDelete},null,8,["onClick"])])}const yp=oe(ep,[["render",bp],["__scopeId","data-v-29a39def"]]),gp=e.defineComponent({name:"ConditionList",props:{list:{type:Array,default:()=>[]},level:{type:Number,default:0},type:{type:String,default:""},path:{type:String,default:""}},components:{Condition:yp}}),Ey="",Cp={key:0,class:"condition-list"},wp={key:0,class:"condition-container"},kp={key:0,class:"condition-text"},xp={key:1,class:"condition-text"},_p={class:"conditions"};function Sp(t,o,n,a,l,r){const s=e.resolveComponent("condition-list",!0),d=e.resolveComponent("condition");return Array.isArray(t.list)?(e.openBlock(),e.createElementBlock("div",Cp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.list,(i,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c},[i.join&&i.conditions&&Array.isArray(i.conditions)?(e.openBlock(),e.createElementBlock("div",wp,[i.conditions.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i.join==="||"?(e.openBlock(),e.createElementBlock("div",kp,"或")):e.createCommentVNode("",!0),i.join==="&&"?(e.openBlock(),e.createElementBlock("div",xp,"且")):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createElementVNode("div",_p,[i.conditions.length>0?(e.openBlock(),e.createBlock(s,{key:0,level:t.level+1,path:`${t.path?t.path+"-":""}${c}`,list:i.conditions,type:t.type},null,8,["level","path","list","type"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(d,{class:"condition",key:i.keyValue||`${t.level}-${c}`,data:i,level:t.level,index:c,path:t.path||"",type:t.type},null,8,["data","level","index","path","type"]))],64))),128))])):e.createCommentVNode("",!0)}const Np=oe(gp,[["render",Sp],["__scopeId","data-v-553c1496"]]),Tp=e.defineComponent({name:"TruncationList",props:{list:{type:Array,default:()=>[]}},components:{ASelect:j.Select,AInput:j.Input,AInputNumber:j.InputNumber},setup(t,{emit:o}){const n=[{label:"前N个",value:"TOP"},{label:"后N个",value:"BOTTOM"}],a=e.ref([]);return e.watch(a,r=>{r!=null&&r.length&&o("update",r)},{deep:!0}),e.onMounted(()=>{var r;(r=t.list)!=null&&r.length?a.value=J.cloneDeep(t.list):a.value=[{num:0,rule:"",name:"其他"}]}),{ruleOptions:n,truncationList:a,clearData:r=>{r.rule="",r.num=0,r.name=""}}}}),By="",er=t=>(e.pushScopeId("data-v-f543c690"),t=t(),e.popScopeId(),t),Ap={class:"truncations"},Op={class:"rule"},Ep={class:"field-value"},Bp={class:"field-value"},Vp=er(()=>e.createElementVNode("div",{class:"text"},"将其余项设为",-1)),Lp=er(()=>e.createElementVNode("div",{class:"text"},"分组",-1)),vp=["onClick"];function $p(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-input-number"),i=e.resolveComponent("a-input");return e.openBlock(),e.createElementBlock("div",Ap,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.truncationList,(c,p)=>(e.openBlock(),e.createElementBlock("div",{class:"item",key:p},[e.createElementVNode("div",Op,[e.createVNode(s,{style:{width:"100%"},value:c.rule,"onUpdate:value":u=>c.rule=u,options:t.ruleOptions},null,8,["value","onUpdate:value","options"])]),e.createElementVNode("div",Ep,[e.createTextVNode(" N= "),e.createVNode(d,{value:c.num,"onUpdate:value":u=>c.num=u,min:0},null,8,["value","onUpdate:value"])]),e.createElementVNode("div",Bp,[Vp,e.createVNode(i,{value:c.name,"onUpdate:value":u=>c.name=u,style:{width:"100px",margin:"0 10px"}},null,8,["value","onUpdate:value"]),Lp]),e.createElementVNode("div",{class:"clear-truncation",onClick:u=>t.clearData(c)},"清空",8,vp)]))),128))])}const Fp=oe(Tp,[["render",$p],["__scopeId","data-v-f543c690"]]),Ip=e.defineComponent({name:"FilterModal",props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""}},components:{ConditionList:Np,TruncationList:Fp,AModal:j.Modal,AButton:j.Button,ATabs:j.Tabs,ATabPane:j.TabPane},setup(t,{expose:o}){var x;const n=e.ref("1"),a=()=>{var V;return`添加过滤条件-${((V=t.item)==null?void 0:V.label)||""}`},l=e.inject(Ce),r=e.inject(Ne),s=e.inject(Ue),d=e.computed(()=>{var V;return(V=e.unref(l))==null?void 0:V.dataSourceId}),i=e.inject(Ie),c=e.inject(ko),p=e.ref([]),u=e.ref([]),f=e.ref(!1),y=e.inject(Wt),h=V=>{var T;for(const P of V)(T=P.conditions)!=null&&T.length?h(P.conditions):P.keyValue=ge()};e.watch(f,V=>{var T,P,R,N;if(V){if(Array.isArray((T=t.item)==null?void 0:T.conditions)){const v=J.cloneDeep(((P=t.item)==null?void 0:P.conditions)||[]);h(v),p.value=v}Array.isArray((R=t.item)==null?void 0:R.truncations)?u.value=J.cloneDeep((N=t.item)==null?void 0:N.truncations)||[]:u.value=[{rule:"",num:0,name:"其他"}]}window.changeShowTable&&window.changeShowTable(!V)},{flush:"post"});let b=!1;const m=V=>{var T;b=!0,e.unref(p)==null||((T=e.unref(p))==null?void 0:T.length)===0?p.value=[{}]:e.unref(p)[0]!=null&&(e.unref(p)[0].conditions==null||e.unref(p)[0].join!==V?p.value=[{join:V,conditions:[e.unref(p)[0],{keyValue:ge()}]}]:e.unref(p)[0].conditions.length>1&&e.unref(p)[0].join===V&&p.value[0].conditions.push({keyValue:ge()}))};e.provide(wo,{updateCondition(V,T,P){var v;b=!0;let R=e.unref(p);const N=P.split("-");if(N!=null&&N.length)for(const A of N)if(R[A])R=(v=R[A])==null?void 0:v.conditions;else break;Array.isArray(R)&&R[T]&&(R[T]=V)},deleteCondition(V,T){var N,v,A;b=!0;let P=e.unref(p);const R=T.split("-");if(R!=null&&R.length){for(const F of R)if(P[F])P=(N=P[F])==null?void 0:N.conditions;else break;if(Array.isArray(P)&&P[V])if(P.splice(V,1),P.length===1){if(R.length>0){const F=R.length-1,M=R[F],G=R.slice(0,F);let W=e.unref(p),X="";for(const Q of G)if(W[Q])X=(v=W[Q])==null?void 0:v.join,W=(A=W[Q])==null?void 0:A.conditions;else break;if(X===P[0].join){if(Array.isArray(P[0].conditions)){const Q=J.cloneDeep(P[0].conditions);W.splice(+M,1),W.splice(+M,0,...Q)}}else W[M]=P[0]}}else P.length===0&&(p.value=[])}},addCondition(V,T,P){var A,F;b=!0;let R=e.unref(p),N="";const v=V.split("-");if(v!=null&&v.length){for(const M of v)if(R[M])N=(A=R[M])==null?void 0:A.join,R=(F=R[M])==null?void 0:F.conditions;else break;if(N===P)R.splice(T+1,0,{keyValue:ge()});else{const M=J.cloneDeep(R[T]);R[T]={join:P,conditions:[M,{keyValue:ge()}]}}}}});const w=V=>{b=!0,u.value=V},g=e.computed(()=>{var T;const V=[];return(T=e.unref(s))==null||T.forEach(P=>{const{keyName:R="",id:N="",type:v}=P;v==="ecanRangePicker"?V.push({value:`${N}-startTime`,label:`${R||N}-开始时间值`,keyName:`${R||N}-startTime`},{value:`${N}-endTime`,label:`${R||N}-结束时间值`,keyName:`${R||N}-endTime`}):V.push({value:N,label:`${R||N}`,keyName:`${R||N}`})}),V}),S=()=>{var A,F,M;const V=dt(((A=e.unref(l))==null?void 0:A.controlList)||[]),T=((F=e.unref(l)[t.type])==null?void 0:F.slice())||[],P=dt(J.cloneDeep(T[t.index].conditions));T[t.index].conditions=e.unref(p),["classificationList","rowHeaderList","dimensionList"].includes(t.type)&&((M=e.unref(u))!=null&&M.length)&&(T[t.index].truncations=e.unref(u));const R=dt(e.unref(p));for(const G of R)if(G.dataType==="component"&&G.fieldValue){const W=e.unref(g).find(X=>X.value===G.fieldValue);W&&(G.fieldValue=W.keyName)}const N=P.filter(G=>!R.find(W=>W.componentId===G.componentId)).filter(G=>!V.find(W=>W.id===G.componentId)),v=R.filter(G=>!P.find(W=>W.componentId===G.componentId));C(N,v),r({[t.type]:T,sqlConditions:Gl({...e.unref(l),[t.type]:T},e.unref(s))})};function C(V,T){var R;const P=V.map(N=>({...N,delete:!0})).concat(T.map(N=>({...N,add:!0})));for(const N of P){const v=e.unref(s).find(A=>A.id===N.componentId);if(v){const{type:A,id:F,events:M=[]}=v,G=Bo(A);if(N.add)M.find(W=>{var X;return W.on===G&&W.target===((X=e.unref(i))==null?void 0:X.id)&&W.emit==="refreshData"})||c({id:F,events:[...M,{on:G,target:(R=e.unref(i))==null?void 0:R.id,emit:"refreshData"}].reverse()});else if(N.delete){const W=M.findIndex(X=>{var Q;return X.on===G&&X.target===((Q=e.unref(i))==null?void 0:Q.id)&&X.emit==="refreshData"});W!==-1&&(M.splice(W,1),c({id:F,events:M}))}}}}const k=()=>{f.value=!0},_=()=>{p.value=[],f.value=!1},E=()=>{b&&S(),b=!1,_()},O=()=>{_()},B=e.inject(Ee),L=e.unref(e.inject(Be)),D=(x=window==null?void 0:window.config)==null?void 0:x.pageId,I=e.ref([]);e.provide(ua,I);const $=async V=>{var T;if(["leftAxisList","rightAxisList","indicators","queryColumnList"].includes(t.type))try{const{id:P,indexCode:R}=V,N=await B.post(`${Se}/diagram/hrpIndexWithComplex`,{pageId:D,dataSourceId:e.unref(d),indexGuid:P,indexCode:R},{headers:{Authentication:L,operateContext:"ygt"}}),{success:v,data:A=[]}=N.data;v&&((T=A==null?void 0:A.dataViewColumns)!=null&&T.length)&&(I.value=A.dataViewColumns.map(F=>({...F,label:F.title||F.label})))}catch(P){console.error(P)}};return e.watch(()=>t.item,V=>{V&&f.value&&e.unref(y)!=="EDV_DATA_SET"&&$(V)}),o({showModal:k}),{visible:f,onOk:E,onCancel:O,handleTitle:a,conditionList:p,truncationList:u,addCondition:m,onUpdatetruncation:w,activeKey:n,source:y}}}),Vy="",Dp={class:"header"},Mp={class:"header"};function Pp(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("condition-list"),i=e.resolveComponent("a-tab-pane"),c=e.resolveComponent("truncation-list"),p=e.resolveComponent("a-tabs"),u=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(u,{title:t.handleTitle(),visible:t.visible,"destroy-on-close":"",width:"55%",bodyStyle:{height:"70vh",overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[["classificationList","rowHeaderList","dimensionList"].includes(t.type)?(e.openBlock(),e.createBlock(p,{key:0,activeKey:t.activeKey,"onUpdate:activeKey":o[3]||(o[3]=f=>t.activeKey=f)},{default:e.withCtx(()=>[e.createVNode(i,{key:"1",tab:"过滤条件",style:{overflow:"auto"}},{default:e.withCtx(()=>[e.createElementVNode("div",Dp,[Array.isArray(t.conditionList)&&t.conditionList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(s,{class:"add-and-condition",onClick:o[0]||(o[0]=f=>t.addCondition("&&"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加且条件 ")]),_:1}),e.createVNode(s,{class:"add-or-condition",onClick:o[1]||(o[1]=f=>t.addCondition("||"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加或条件 ")]),_:1})],64)):(e.openBlock(),e.createBlock(s,{key:1,onClick:o[2]||(o[2]=f=>t.addCondition())},{default:e.withCtx(()=>[e.createTextVNode(" 添加条件 ")]),_:1}))]),e.createVNode(d,{class:"condition-list",list:t.conditionList,level:0,type:t.type},null,8,["list","type"])]),_:1}),e.createVNode(i,{key:"2",tab:"截断配置"},{default:e.withCtx(()=>[e.createVNode(c,{list:t.truncationList,onUpdate:t.onUpdatetruncation},null,8,["list","onUpdate"])]),_:1})]),_:1},8,["activeKey"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",Mp,[Array.isArray(t.conditionList)&&t.conditionList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(s,{class:"add-and-condition",onClick:o[4]||(o[4]=f=>t.addCondition("&&"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加且条件 ")]),_:1}),e.createVNode(s,{class:"add-or-condition",onClick:o[5]||(o[5]=f=>t.addCondition("||"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加或条件 ")]),_:1})],64)):(e.openBlock(),e.createBlock(s,{key:1,onClick:o[6]||(o[6]=f=>t.addCondition())},{default:e.withCtx(()=>[e.createTextVNode(" 添加条件 ")]),_:1}))]),e.createVNode(d,{class:"condition-list",list:t.conditionList,level:0,type:t.type},null,8,["list","type"])],64))]),_:1},8,["title","visible","onOk","onCancel"])}const jp=oe(Ip,[["render",Pp],["__scopeId","data-v-38f115c6"]]),Rp=e.defineComponent({name:"ConfigName",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{AInput:j.Input,AModal:j.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),l=e.inject(Ne),r=e.ref(),s=p=>{const{showLabel:u="",label:f=""}=p;r.value=u||f||"",n.value=!0},d=()=>{n.value=!1},i=()=>{var u;const p=((u=e.unref(a)[t.type])==null?void 0:u.slice())||[];p[t.index].showLabel=r.value,l({[t.type]:p}),d()},c=()=>{d()};return o({showModal:s}),{visible:n,onOk:i,onCancel:c,fieldName:r}}}),Ly="",Up=t=>(e.pushScopeId("data-v-de6a1755"),t=t(),e.popScopeId(),t),zp={class:"config-name"},Gp=Up(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"名称:",-1));function Hp(t,o,n,a,l,r){const s=e.resolveComponent("a-input"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置展示名称",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",zp,[Gp,e.createVNode(s,{value:t.fieldName,"onUpdate:value":o[0]||(o[0]=i=>t.fieldName=i)},null,8,["value"])])]),_:1},8,["visible","onOk","onCancel"])}const Wp=oe(Rp,[["render",Hp],["__scopeId","data-v-de6a1755"]]),Yp=e.defineComponent({name:"SortByCpnt",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{ASelect:j.Select,AModal:j.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),l=e.inject(Ne),r=e.inject(Ue),s=e.inject(Ie),d=e.inject(ko),i=e.ref(),c=e.computed(()=>{var w;return(w=e.unref(r))==null?void 0:w.filter(g=>g.keyName!=="")});let p=[];const u=w=>{const{sortCpnts:g=[]}=w;p=J.cloneDeep(g),i.value=J.cloneDeep(g),n.value=!0},f=()=>{n.value=!1},y=()=>{var k,_;const w=dt(((k=e.unref(a))==null?void 0:k.controlList)||[]),g=p.filter(E=>!e.unref(i).includes(E)).filter(E=>!w.find(O=>O.id===E)),S=e.unref(i).filter(E=>!p.includes(E)).filter(E=>!w.find(O=>O.id===E)),C=g.map(E=>({componentId:E,delete:!0})).concat(S.map(E=>({componentId:E,add:!0})));for(const E of C){const O=e.unref(r).find(B=>B.id===E.componentId);if(O){const{type:B,id:L,events:D=[]}=O,I=Bo(B);if(E.add)D.find($=>{var x;return $.on===I&&$.target===((x=e.unref(s))==null?void 0:x.id)&&$.emit==="refreshData"})||d({id:L,events:[...D,{on:I,target:(_=e.unref(s))==null?void 0:_.id,emit:"refreshData"}].reverse()});else if(E.delete){const $=D.findIndex(x=>{var V;return x.on===I&&x.target===((V=e.unref(s))==null?void 0:V.id)&&x.emit==="refreshData"});$!==-1&&(D.splice($,1),d({id:L,events:D}))}}}},h=()=>{var g;y();const w=((g=e.unref(a)[t.type])==null?void 0:g.slice())||[];w[t.index].sortCpnts=i.value,l({[t.type]:w}),f()},b=()=>{f()},m=(w,g)=>{var S;return(S=g==null?void 0:g.keyName)==null?void 0:S.toLowerCase().includes(w==null?void 0:w.toLowerCase())};return o({showModal:u}),{visible:n,onOk:h,onCancel:b,idFilterOption:m,fieldName:i,usedComponentList:c}}}),vy="",qp=t=>(e.pushScopeId("data-v-08af1ef8"),t=t(),e.popScopeId(),t),Kp={class:"sort-by-cpnt"},Xp=qp(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"控件:",-1));function Qp(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置关联组件排序",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",Kp,[Xp,e.createVNode(s,{class:"field-name",value:t.fieldName,"onUpdate:value":o[0]||(o[0]=i=>t.fieldName=i),mode:"multiple",style:{width:"100%"},options:t.usedComponentList,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption},null,8,["value","options","filter-option"])])]),_:1},8,["visible","onOk","onCancel"])}const Jp=oe(Yp,[["render",Qp],["__scopeId","data-v-08af1ef8"]]),Zp=e.defineComponent({name:"DimByCount",props:{index:{type:Number,default:0},type:{type:String,default:""}},components:{ASelect:j.Select,AModal:j.Modal},setup(t,{expose:o}){const n=e.ref(!1),a=e.inject(Ce),l=e.inject(Ne),r=e.ref(),s=e.ref([]),d=(f,y)=>{const{dimByCount:h=""}=f;r.value=h,s.value=y.filter(b=>["DIM","BUILT_IN_DIM","FIELD"].includes(b.scope)).map(b=>({label:b.title||b.name,value:b.typeGuid})),n.value=!0},i=()=>{n.value=!1},c=()=>{var y;const f=((y=e.unref(a)[t.type])==null?void 0:y.slice())||[];f[t.index].dimByCount=r.value,l({[t.type]:f}),i()},p=()=>{i()},u=(f,y)=>{var h;return(h=y==null?void 0:y.label)==null?void 0:h.toLowerCase().includes(f==null?void 0:f.toLowerCase())};return o({showModal:d}),{visible:n,onOk:c,onCancel:p,idFilterOption:u,fieldName:r,dimensionList:s}}}),$y="",eu=t=>(e.pushScopeId("data-v-aa1c298e"),t=t(),e.popScopeId(),t),tu={class:"dim-by-count"},ou=eu(()=>e.createElementVNode("div",{style:{"word-break":"keep-all"}},"维度:",-1));function nu(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(d,{title:"配置关联维度",visible:t.visible,"destroy-on-close":"",width:"30%",bodyStyle:{overflow:"auto",display:"flex",flexDirection:"column",position:"relative",paddingTop:"10px"},closable:!1,onOk:t.onOk,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createElementVNode("div",tu,[ou,e.createVNode(s,{class:"field-name",value:t.fieldName,"onUpdate:value":o[0]||(o[0]=i=>t.fieldName=i),style:{width:"100%"},options:t.dimensionList,"show-search":"","filter-option":t.idFilterOption},null,8,["value","options","filter-option"])])]),_:1},8,["visible","onOk","onCancel"])}const au=oe(Zp,[["render",nu],["__scopeId","data-v-aa1c298e"]]),Gn=(t,o)=>{let n;for(let a=0;a<o.length;a++){const l=o[a];l.children&&(l.children.some(r=>r.key===t)?n=l.key:Gn(t,l.children)&&(n=Gn(t,l.children)))}return n},lu=e.defineComponent({name:"FormulaCalculation",props:{value:{type:String,default:""},item:{type:Object,default:()=>({})},mode:{type:String,default:"add"}},components:{ARow:j.Row,ACol:j.Col,ATextarea:j.Textarea,APopover:j.Popover,AInputSearch:j.InputSearch,ATree:j.Tree,ARadioGroup:j.RadioGroup,ARadioButton:j.RadioButton,DoubleRightOutlined:_s},emits:["update:value","change"],setup(t,{emit:o}){const n=e.inject(Ee),a=e.unref(e.inject(Be)),l=e.inject(Ce),r=e.computed(()=>e.unref(l).leftAxisList||[]),s=e.computed(()=>e.unref(l).variableList||[]),d=e.computed(()=>e.unref(l).rightAxisList||[]),i=e.computed(()=>e.unref(l).indicators||[]),c=e.computed(()=>e.unref(l).queryColumnList||[]),p=e.computed(()=>{const B=e.unref(r).concat(e.unref(d)).concat(e.unref(i)).concat(e.unref(c));return t.mode==="edit"?(B==null?void 0:B.filter(L=>{var D;return L.id!==((D=t.item)==null?void 0:D.id)}))||[]:B||[]}),u=e.computed(()=>s.value.filter(B=>!B.randomKey)),f=e.computed({get:()=>t.value||"",set:B=>{o("update:value",B),o("change",B)}}),y=e.ref("1"),h=e.ref(""),b=B=>{const L=document.getElementById("calTextArea");let D=f.value;if(document.selection){const I=document.selection.createRange();I.text=B}else if(typeof L.selectionStart=="number"&&typeof L.selectionEnd=="number"){const I=L.selectionStart,$=L.selectionEnd;let x=I;D=D.substring(0,I)+B+D.substring($,D.length),x+=B.length,L.selectionStart=L.selectionEnd=x}else D+=B;f.value=D},m=["+","-","*","/","(",")"],w=(B,L)=>{let D="";switch(L){case"name":{D="${"+B+"}";break}case"function":{D=B+"()";break}default:D=B}b(D)},g=[],S=e.ref([]),C=e.ref(!0),k=e.ref([]),_=B=>{var L;for(const D of B)(L=D==null?void 0:D.children)!=null&&L.length?_(D.children):g.push({key:D.key,title:D.title})},E=async()=>{try{const B=await n.get(`${Se}/diagram/funcdescs`,{},{headers:{Authentication:a,operateContext:"ygt"}}),{success:L,data:D=[]}=B.data;L&&(D!=null&&D.length)&&(_(D),k.value=D)}catch(B){console.error(B)}},O=B=>{S.value=B,C.value=!1};return e.watch(h,B=>{const L=g.map(D=>D.title.indexOf(B)>-1?Gn(D.key,k.value):null).filter((D,I,$)=>D&&$.indexOf(D)===I);S.value=L,h.value=B,C.value=!0}),e.onMounted(()=>{E()}),{fieldList:p,varList:u,myValue:f,calculMethods:m,funcDescsData:k,searchFuncValue:h,expandedKeys:S,autoExpandParent:C,activeKey:y,selectedElem:w,onExpand:O}}}),Fy="",Iy="",tr=t=>(e.pushScopeId("data-v-69040cfb"),t=t(),e.popScopeId(),t),ru={class:"formula-calculation"},iu={class:"field-area"},su={style:{"text-align":"center",padding:"10px 0"}},cu=["onClick"],du=["onClick"],pu={class:"cal_right_bottom"},uu={class:"cal_fu"},fu=["onClick"],mu={class:"function-wrap"},hu={class:"wrap-search"},bu={class:"tree-box"},yu=tr(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"描述:",-1)),gu=tr(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"示例:",-1)),Cu={key:0},wu={style:{color:"#f50"}},ku={key:1},xu=["onClick"],_u={class:"cal_a"};function Su(t,o,n,a,l,r){const s=e.resolveComponent("a-radio-button"),d=e.resolveComponent("a-radio-group"),i=e.resolveComponent("a-col"),c=e.resolveComponent("a-textarea"),p=e.resolveComponent("a-input-search"),u=e.resolveComponent("a-tooltip"),f=e.resolveComponent("a-tree"),y=e.resolveComponent("double-right-outlined"),h=e.resolveComponent("a-popover"),b=e.resolveComponent("a-row");return e.openBlock(),e.createElementBlock("div",ru,[e.createVNode(b,{style:{height:"100%"}},{default:e.withCtx(()=>[e.createVNode(i,{span:6},{default:e.withCtx(()=>[e.createElementVNode("div",iu,[e.createElementVNode("div",su,[e.createVNode(d,{value:t.activeKey,"onUpdate:value":o[0]||(o[0]=m=>t.activeKey=m),size:"small"},{default:e.withCtx(()=>[e.createVNode(s,{value:"1"},{default:e.withCtx(()=>[e.createTextVNode("数值字段("+e.toDisplayString(t.fieldList.length)+")",1)]),_:1}),e.createVNode(s,{value:"2"},{default:e.withCtx(()=>[e.createTextVNode("全局变量("+e.toDisplayString(t.varList.length)+")",1)]),_:1})]),_:1},8,["value"])]),t.activeKey==="1"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.fieldList,(m,w)=>(e.openBlock(),e.createElementBlock("div",{class:"field",key:w,onClick:g=>t.selectedElem(m.label,"name")},e.toDisplayString(m.label),9,cu))),128)):e.createCommentVNode("",!0),t.activeKey==="2"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.varList,(m,w)=>(e.openBlock(),e.createElementBlock("div",{class:"field",key:w,onClick:g=>t.selectedElem(m.variableName,"name")},e.toDisplayString(m.variableName),9,du))),128)):e.createCommentVNode("",!0)])]),_:1}),e.createVNode(i,{span:18},{default:e.withCtx(()=>[e.createVNode(c,{class:"textarea",id:"calTextArea",value:t.myValue,"onUpdate:value":o[1]||(o[1]=m=>t.myValue=m),autoSize:{minRows:13,maxRows:13},placeholder:"示例: ${指标} * 3"},null,8,["value"]),e.createElementVNode("div",pu,[e.createElementVNode("ul",uu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.calculMethods,(m,w)=>(e.openBlock(),e.createElementBlock("li",{onClick:g=>t.selectedElem(m,"symbol"),key:w},e.toDisplayString(m),9,fu))),128))]),e.createVNode(h,{placement:"topRight",trigger:"click",overlayClassName:"func-popover"},{content:e.withCtx(()=>[e.createElementVNode("div",mu,[e.createElementVNode("div",hu,[e.createVNode(p,{value:t.searchFuncValue,"onUpdate:value":o[2]||(o[2]=m=>t.searchFuncValue=m),style:{"margin-bottom":"8px"},placeholder:"请输入关键字搜索"},null,8,["value"])]),e.createElementVNode("div",bu,[e.createVNode(f,{"expanded-keys":t.expandedKeys,"auto-expand-parent":t.autoExpandParent,"tree-data":t.funcDescsData,onExpand:t.onExpand},{title:e.withCtx(({title:m,leaf:w,describe:g,exp:S})=>[e.createVNode(u,{placement:"top"},e.createSlots({default:e.withCtx(()=>[m.indexOf(t.searchFuncValue)>-1?(e.openBlock(),e.createElementBlock("span",Cu,[e.createTextVNode(e.toDisplayString(m.substr(0,m.indexOf(t.searchFuncValue)))+" ",1),e.createElementVNode("span",wu,e.toDisplayString(t.searchFuncValue),1),e.createTextVNode(" "+e.toDisplayString(m.substr(m.indexOf(t.searchFuncValue)+t.searchFuncValue.length)),1)])):(e.openBlock(),e.createElementBlock("span",ku,e.toDisplayString(m),1)),w?(e.openBlock(),e.createElementBlock("span",{key:2,class:"insertsty",onClick:C=>t.selectedElem(m,"function")},"插入",8,xu)):e.createCommentVNode("",!0)]),_:2},[w?{name:"title",fn:e.withCtx(()=>[e.createElementVNode("div",null,[yu,e.createElementVNode("span",null,e.toDisplayString(g),1)]),e.createElementVNode("div",null,[gu,e.createElementVNode("span",null,e.toDisplayString(S),1)])]),key:"0"}:void 0]),1024)]),_:1},8,["expanded-keys","auto-expand-parent","tree-data","onExpand"])])])]),default:e.withCtx(()=>[e.createElementVNode("span",_u,[e.createTextVNode(" 更多函数 "),e.createVNode(y,{style:{"font-size":"12px",margin:"2px 0 0 2px",color:"#1890ff"}})])]),_:1})])]),_:1})]),_:1})])}const Nu=oe(lu,[["render",Su],["__scopeId","data-v-69040cfb"]]),Tu=e.defineComponent({name:"CalculationModal",components:{FormulaCalculation:Nu,AForm:j.Form,AModal:j.Modal,AFormItem:j.FormItem,AInput:j.Input,ASelect:j.Select,ASelectOption:j.SelectOption,ATextarea:j.Textarea,AInputNumber:j.InputNumber,ATooltip:j.Tooltip,QuestionCircleOutlined:ec},props:{item:{type:Object,default:()=>({})},index:{type:Number,default:0},type:{type:String,default:""},mode:{type:String,default:"add"}},setup(t,{expose:o}){const n=e.inject(Ue),a=e.inject(Ce),l=e.inject(Ne),r=e.computed(()=>e.unref(n)),s=e.computed(()=>e.unref(a)[t.type]||[]),d=e.computed(()=>{const $=["leftAxisList","rightAxisList","queryColumnList","indicators"];let x=[];for(const V of $)Object.prototype.hasOwnProperty.call(e.unref(a),V)&&(x=x.concat(e.unref(a)[V]));return x}),i={span:4},c={span:18},p={label:"",calcType:"FORMULA",formula:void 0,builtInValueSource:void 0,builtInFormula:void 0,builtInCalcWay:void 0},u={value:0,unit:"YEAR",around:"before"},f=e.ref({}),y=e.ref(),h=e.ref(!1),b=e.ref();e.watch(h,$=>{if($)if(t.mode==="edit"){const{label:x,calcType:V,formula:T,builtInValueSource:P,builtInFormula:R,builtInCalcWay:N}=t.item;if(b.value={label:x,calcType:V,formula:T,builtInValueSource:P,builtInFormula:R,builtInCalcWay:N},R==="DATE_OFFSET"){const v=N.split("-");(v==null?void 0:v.length)===3&&(f.value={value:v[0],unit:v[1],around:v[2]})}}else t.mode==="add"&&(b.value=J.cloneDeep(p),f.value=J.cloneDeep(u));else b.value=J.cloneDeep(p),f.value=J.cloneDeep(u);window.changeShowTable&&window.changeShowTable(!$)},{immediate:!0,deep:!0});let m=!1;const w=()=>{m=!0},g=$=>{const x=e.unref(r).find(V=>V.id===$);x&&(b.value.builtInCalcWay=x.keyName),m=!0},S=()=>{var P;const $=((P=e.unref(a)[t.type])==null?void 0:P.slice())||[],{label:x,builtInFormula:V}=e.unref(b)||{},T={};if(V==="DATE_OFFSET"&&(T.builtInCalcWay=`${e.unref(f).value}-${e.unref(f).unit}-${e.unref(f).around}`),t.mode==="add"){const R=ge();$.push({...e.unref(b),...T,id:R,show:!0,name:x})}else t.mode==="edit"&&($[t.index]={...$[t.index],...e.unref(b),...T,name:x});l({[t.type]:$})},C=()=>{h.value=!0},k=()=>{h.value=!1},_=async($,x)=>{if(x==="")return Promise.reject(new Error("请输入指标名"));{const V=e.unref(d).find(T=>T.label===x);return V?V.id===t.item.id?Promise.resolve():Promise.reject(new Error("指标名不能重复")):Promise.resolve()}},E=e.computed(()=>{let $={label:[{required:!0,validator:_,trigger:"change"}]};return b.value.calcType==="BUILT_IN"&&($={...$,builtInFormula:[{required:!0,message:"请选择内置公式"}],builtInValueSource:[{required:!0,message:"请选择数值来自"}],builtInCalcWay:[{required:!0,message:"请选择取数原则"}]}),$}),O=()=>{y.value.validate().then(()=>{m&&S(),m=!1,k()})},B=()=>{y.value.clearValidate(),k()},L=()=>{m=!0,e.unref(b).builtInCalcWay=""},D=e.computed(()=>{let $="";const x=e.unref(b).builtInCalcWay,V=e.unref(b).builtInValueSource;if(!V||!x)return $;switch(e.unref(b).builtInFormula){case"BUILT_IN_RANK":{x==="ASC"?$="【"+V+"】由小到大在所有值中的排名":$="【"+V+"】由大到小在所有值中的排名";break}case"BUILT_IN_RANK_IN_GROUPO":{$=`所有【】的
65
+ `,x==="ASC"?$=$+"【"+V+"】由小到大的组内的排名":$=$+"【"+V+"】由大到小的组内的排名";break}case"BUILT_IN_ALL_VALUE":{let T="";switch(x){case"SUM":{T="求和";break}case"AVG":{T="求平均值";break}case"MIN":{T="求最小值";break}case"MAX":{T="求最大值";break}}$="将所有【"+V+"】"+T;break}case"BUILT_IN_ALL_VALUE_IN_GROUPO":{let T="";switch($=`所有【】的
66
+ `,x){case"SUM":{T="求和";break}case"AVG":{T="求平均值";break}case"MIN":{T="求最小值";break}case"MAX":{T="求最大值";break}}$=$+"将所有【"+V+"】"+T;break}}return $}),I=($,x)=>x.keyName.toLowerCase().indexOf($.toLowerCase())>=0;return o({showModal:C}),{visible:h,onCancel:B,labelCol:i,wrapperCol:c,formState:b,builtInValueSourceList:s,onOK:O,onChange:w,formRules:E,accessLogic:D,formRef:y,onChangeBuiltInFormula:L,componentList:r,onChangeComponent:g,filterOption:I,offsetConfig:f}}}),Dy="",My="",Au={key:0,class:"accesstip"},Ou={style:{display:"flex","align-items":"center"}};function Eu(t,o,n,a,l,r){const s=e.resolveComponent("a-input"),d=e.resolveComponent("a-form-item"),i=e.resolveComponent("a-select-option"),c=e.resolveComponent("a-select"),p=e.resolveComponent("formula-calculation"),u=e.resolveComponent("a-textarea"),f=e.resolveComponent("a-input-number"),y=e.resolveComponent("question-circle-outlined"),h=e.resolveComponent("a-tooltip"),b=e.resolveComponent("a-form"),m=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(m,{title:`${t.mode==="add"?"新增":"编辑"}计算指标`,visible:t.visible,width:"50%",bodyStyle:{height:"55vh",overflow:"auto",display:"flex",flexDirection:"column"},closable:!1,onOk:t.onOK,onCancel:t.onCancel},{default:e.withCtx(()=>[e.createVNode(b,{model:t.formState,rules:t.formRules,ref:"formRef"},{default:e.withCtx(()=>[e.createVNode(d,{label:"指标名","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"label"},{default:e.withCtx(()=>[e.createVNode(s,{value:t.formState.label,"onUpdate:value":o[0]||(o[0]=w=>t.formState.label=w),onChange:t.onChange},null,8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),e.createVNode(d,{label:"计算方式","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[e.createVNode(c,{value:t.formState.calcType,"onUpdate:value":o[1]||(o[1]=w=>t.formState.calcType=w),onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(i,{value:"FORMULA"},{default:e.withCtx(()=>[e.createTextVNode("公式")]),_:1}),e.createVNode(i,{value:"BUILT_IN"},{default:e.withCtx(()=>[e.createTextVNode("内置公式")]),_:1}),e.createVNode(i,{value:"COMPONENT"},{default:e.withCtx(()=>[e.createTextVNode("固定值")]),_:1})]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),t.formState.calcType==="FORMULA"?(e.openBlock(),e.createBlock(p,{key:0,value:t.formState.formula,"onUpdate:value":o[2]||(o[2]=w=>t.formState.formula=w),item:t.item,mode:t.mode,onChange:t.onChange},null,8,["value","item","mode","onChange"])):e.createCommentVNode("",!0),t.formState.calcType==="BUILT_IN"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(d,{label:"内置公式","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInFormula"},{default:e.withCtx(()=>[e.createVNode(c,{value:t.formState.builtInFormula,"onUpdate:value":o[3]||(o[3]=w=>t.formState.builtInFormula=w),onChange:t.onChangeBuiltInFormula},{default:e.withCtx(()=>[e.createVNode(i,{value:"BUILT_IN_ALL_VALUE"},{default:e.withCtx(()=>[e.createTextVNode("所有值")]),_:1}),e.createVNode(i,{value:"BUILT_IN_ALL_VALUE_IN_GROUPO"},{default:e.withCtx(()=>[e.createTextVNode("组内所有值")]),_:1}),e.createVNode(i,{value:"BUILT_IN_RANK"},{default:e.withCtx(()=>[e.createTextVNode("排名")]),_:1}),e.createVNode(i,{value:"BUILT_IN_RANK_IN_GROUPO"},{default:e.withCtx(()=>[e.createTextVNode("组内排名")]),_:1}),e.createVNode(i,{value:"FIRST_ROW_RATE"},{default:e.withCtx(()=>[e.createTextVNode("首行占比")]),_:1}),e.createVNode(i,{value:"DATE_OFFSET"},{default:e.withCtx(()=>[e.createTextVNode("日期偏移")]),_:1})]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),e.createVNode(d,{label:"数值来自","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(c,{value:t.formState.builtInValueSource,"onUpdate:value":o[4]||(o[4]=w=>t.formState.builtInValueSource=w),onChange:t.onChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.builtInValueSourceList,(w,g)=>(e.openBlock(),e.createBlock(i,{key:g,value:w.label,disabled:t.mode==="edit"&&t.item.label===w.name},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(w.label),1)]),_:2},1032,["value","disabled"]))),128))]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"]),["FIRST_ROW_RATE","DATE_OFFSET"].includes(t.formState.builtInFormula)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:0,label:"取数原则","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(c,{value:t.formState.builtInCalcWay,"onUpdate:value":o[5]||(o[5]=w=>t.formState.builtInCalcWay=w),onChange:t.onChange},{default:e.withCtx(()=>[["BUILT_IN_ALL_VALUE","BUILT_IN_ALL_VALUE_IN_GROUPO"].includes(t.formState.builtInFormula||"")?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(i,{value:"SUM"},{default:e.withCtx(()=>[e.createTextVNode("求和")]),_:1}),e.createVNode(i,{value:"AVG"},{default:e.withCtx(()=>[e.createTextVNode("求平均")]),_:1}),e.createVNode(i,{value:"MAX"},{default:e.withCtx(()=>[e.createTextVNode("求最大值")]),_:1}),e.createVNode(i,{value:"MIN"},{default:e.withCtx(()=>[e.createTextVNode("求最小值")]),_:1})],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(i,{value:"ASC"},{default:e.withCtx(()=>[e.createTextVNode("升序")]),_:1}),e.createVNode(i,{value:"DESC"},{default:e.withCtx(()=>[e.createTextVNode("降序")]),_:1})],64))]),_:1},8,["value","onChange"])]),_:1},8,["label-col","wrapper-col"])),["FIRST_ROW_RATE","DATE_OFFSET"].includes(t.formState.builtInFormula)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:1,label:"取数逻辑","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[["BUILT_IN_RANK_IN_GROUPO","BUILT_IN_ALL_VALUE_IN_GROUPO"].includes(t.formState.builtInFormula)&&t.formState.builtInValueSource?(e.openBlock(),e.createElementBlock("div",Au," 蓝色字段跟随您后续维度设置的顺序而变化,以获取相应的"+e.toDisplayString(t.formState.builtInValueSource),1)):e.createCommentVNode("",!0),e.createVNode(u,{value:t.accessLogic,rows:6,disabled:""},null,8,["value"])]),_:1},8,["label-col","wrapper-col"]))],64)):e.createCommentVNode("",!0),t.formState.calcType==="COMPONENT"?(e.openBlock(),e.createBlock(d,{key:2,label:"数值来自","label-col":t.labelCol,"wrapper-col":t.wrapperCol,name:"builtInValueSource"},{default:e.withCtx(()=>[e.createVNode(c,{"show-search":"",value:t.formState.builtInValueSource,"onUpdate:value":o[6]||(o[6]=w=>t.formState.builtInValueSource=w),"filter-option":t.filterOption,options:t.componentList,fieldNames:{value:"id",label:"keyName"},onChange:t.onChangeComponent},null,8,["value","filter-option","options","onChange"])]),_:1},8,["label-col","wrapper-col"])):e.createCommentVNode("",!0),t.formState.builtInFormula==="DATE_OFFSET"?(e.openBlock(),e.createBlock(d,{key:3,label:"偏移设置","label-col":t.labelCol,"wrapper-col":t.wrapperCol},{default:e.withCtx(()=>[e.createElementVNode("div",Ou,[e.createVNode(f,{value:t.offsetConfig.value,"onUpdate:value":o[7]||(o[7]=w=>t.offsetConfig.value=w),style:{width:"120px","margin-right":"10px"},onChange:t.onChange},null,8,["value","onChange"]),e.createVNode(c,{value:t.offsetConfig.unit,"onUpdate:value":o[8]||(o[8]=w=>t.offsetConfig.unit=w),style:{width:"120px","margin-right":"10px"},onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(i,{value:"YEAR"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(i,{value:"MONTH"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(i,{value:"DAY"},{default:e.withCtx(()=>[e.createTextVNode("天")]),_:1})]),_:1},8,["value","onChange"]),e.createVNode(c,{value:t.offsetConfig.around,"onUpdate:value":o[9]||(o[9]=w=>t.offsetConfig.around=w),style:{width:"120px"},onChange:t.onChange},{default:e.withCtx(()=>[e.createVNode(i,{value:"before"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(i,{value:"after"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value","onChange"]),e.createVNode(h,{title:"内置公式【日期偏移】,依赖于【全局过滤】中的时间条件,若没有配置则不会进行偏移计算",overlayClassName:"question-tooltip",color:"#fff"},{default:e.withCtx(()=>[e.createVNode(y,{class:"icon",style:{color:"#40a9ff","font-size":"18px",cursor:"pointer","margin-left":"10px"}})]),_:1})])]),_:1},8,["label-col","wrapper-col"])):e.createCommentVNode("",!0)]),_:1},8,["model","rules"])]),_:1},8,["title","visible","onOk","onCancel"])}const Bu=oe(Tu,[["render",Eu],["__scopeId","data-v-33575cd9"]]),Vu=e.defineComponent({name:"DataConfigCard",directives:{focus:Zl},components:{CalculationModal:Bu,FilterModal:jp,CustomGroupModal:Xd,SettingOutlined:sc,DeleteOutlined:za,CopyOutlined:bs,InfoCircleOutlined:Vs,CustomSortModal:Dd,PlusOutlined:Xs,ACard:j.Card,ACheckbox:j.Checkbox,AInput:j.Input,ADropdown:j.Dropdown,AMenu:j.Menu,ASubMenu:j.SubMenu,AMenuItem:j.MenuItem,AMenuDivider:j.MenuDivider,ASelect:j.Select,APopover:j.Popover,Draggable:Et,ConfigName:Wp,SortByCpnt:Jp,DimByCount:au},props:{title:{type:String,default:""},type:{type:String,default:""}},setup(t){const o=[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"}],n=e.inject(Ce),a=e.inject(Ne),l=e.inject(Ue),r=["leftAxisList","rightAxisList","indicators"],s=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],d=e.inject(Wt),i=e.ref(),c=(U={})=>{var K;const{type:z}=t;if(e.unref(d)==="SQL_VIEW")return!0;e.unref(d)==="EDV_DATA_SET"&&a({edvDataSetId:U.parentId});let Y=!1;if(U.scope==="FIELD"&&(Y=!0,U.genericType==="0"&&r.includes(z)&&(Y=!1)),["IDX","BUILT_IN_IDX"].includes(U.scope)?r.includes(z)&&(Y=!0):["DIM","BUILT_IN_DIM"].includes(U.scope)&&s.includes(z)&&(Y=!0),z==="dimensionList"){const ie=((K=e.unref(n)[z])==null?void 0:K.slice())||[];(ie==null?void 0:ie.length)===1&&(Y=!1)}return Y},p=e.computed(()=>e.unref(ne).type==="ecanDataSelect"&&t.type==="indicators"),u=(U="{}")=>{var z,Y;try{const K=JSON.parse(U);if(!c(K))return;const ie=((z=e.unref(n)[t.type])==null?void 0:z.slice())||[];(t.type==="seriesList"||t.type==="classificationList"&&!we(e.unref(ne).type,["list","circulate","scatter"])||e.unref(p))&&ie.forEach(be=>{be.show=!1}),y(ie,K),K.randomKey=ge(),ie.push(K);const{type:se}=t,te={};if(["IDX","BUILT_IN_IDX","FIELD"].includes(K.scope)){const be=((Y=e.unref(n))==null?void 0:Y.variableList)||[];let de=sessionStorage.getItem("indicator-variates");if(K.scope==="FIELD"&&!r.includes(se)&&(de="[]"),de){const ce=JSON.parse(de);if(ce!=null&&ce.length)for(const ye of ce)be.unshift({...ye,dataType:"",id:null,variableValue:e.unref(d)==="EDV_DATA_SET"?ye.defaultValue:null,dateTypeValue:null,format:ye.valueFormat&&ye.valueFormat.toUpperCase()||null,variableName:ye.name,variableType:ye.valueType,label:K.label,randomKey:K.randomKey,keyValue:ge(),disabled:e.unref(d)==="EDV_DATA_SET"})}te.variableList=be,te.variableConditions=no(be,l)}a({[t.type]:ie,...te}),sessionStorage.setItem("indicator-list-item",""),sessionStorage.setItem("indicator-variates","")}catch(K){console.error(K)}},f=(U="{}")=>{var z;try{const{cardItem:Y,type:K,index:ie}=JSON.parse(U);if(!c(Y)||K===t.type)return;const se=((z=e.unref(n)[t.type])==null?void 0:z.slice())||[];y(se,Y),se.push(Y);const te=e.unref(n)[K].slice()||[];te.splice(ie,1),a({[t.type]:se,[K]:te})}catch(Y){console.error(Y)}};function y(U,z){const Y=[];if(U.forEach(K=>{K.label.includes(z.label)&&Y.push(K.label.split(z.label)[1])}),Y.length>=1){for(let K=1;K<=Y.length;K++)if(!Y.includes(K+"")){z.label=z.label+K;break}}}const h=(U,z)=>{var ie,se;const Y=(ie=U.target)==null?void 0:ie.checked,K=((se=e.unref(n)[t.type])==null?void 0:se.slice())||[];(t.type==="seriesList"||t.type==="classificationList"&&!we(e.unref(ne).type,["list","circulate"])||e.unref(p))&&K.forEach(te=>{te.show=!1}),K[z].show=Y,a({[t.type]:K})},b=U=>{var Y;const z=((Y=e.unref(n)[t.type])==null?void 0:Y.slice())||[];z.splice(U,1),a({[t.type]:z})},m=()=>{sessionStorage.setItem("indicator-card-item","")},w=U=>{const z=sessionStorage.getItem("indicator-list-item"),Y=sessionStorage.getItem("indicator-card-item");z?u(z):Y&&f(Y)},g=U=>{var be,de;const{newIndex:z,oldIndex:Y,from:K,to:ie}=U,se=K.id,te=ie.id;if(z>=0&&Y>=0){if(se===te){const ce=((be=e.unref(n)[t.type])==null?void 0:be.slice())||[],ye=ce.splice(Y,1)[0];ye&&(ce.splice(z,0,ye),a({[t.type]:ce}))}else if(t.type===te){const ce=((de=e.unref(n)[te])==null?void 0:de.slice())||[];if(ce!=null&&ce.length){const ye=ce.splice(ce.length-1,1)[0];ye&&(ce.splice(z,0,ye),a({[t.type]:ce}))}}}},S=(U,z)=>{const Y=U.oldIndex,K=z[Y];K&&sessionStorage.setItem("indicator-card-item",JSON.stringify({cardItem:K,type:t.type,index:Y}))},C=e.computed(()=>e.unref(n)[t.type]||[]),k=e.ref([]);let _=!1;e.watch(()=>e.unref(C).length,U=>{k.value=new Array(U).fill(!1)},{flush:"post",immediate:!0});const E=U=>{var Y,K,ie;const z=((Y=e.unref(n)[t.type])==null?void 0:Y.slice())||[];if((K=z[U])!=null&&K.randomKey){const se=((ie=e.unref(n))==null?void 0:ie.variableList)||[];for(let te=se.length-1;te>=0;te--)se[te].randomKey===z[U].randomKey&&se.splice(te,1);a({variableConditions:no(se,l),variableList:se})}z.splice(U,1),a({[t.type]:z})},O=U=>{k.value[U]=!0},B=()=>{_=!0},L=(U,z,Y)=>{var K,ie,se,te;if(k.value[z]=!1,_){const be=(K=U.target)==null?void 0:K.value,de=((ie=e.unref(n)[t.type])==null?void 0:ie.slice())||[],ce=de.filter(fe=>{var ke;return(ke=fe==null?void 0:fe.formula)==null?void 0:ke.includes(Y)}).map(fe=>fe.id),ye=de.filter(fe=>{var ke;return(ke=fe==null?void 0:fe.builtInValueSource)==null?void 0:ke.includes(Y)}).map(fe=>fe.id);if(ce!=null&&ce.length)for(const fe of ce){const ke=de.find(Ot=>Ot.id===fe);ke.formula=ke.formula.replaceAll(Y,be)}if(ye!=null&&ye.length)for(const fe of ye){const ke=de.find(Ot=>Ot.id===fe);ke.builtInValueSource=ke.builtInValueSource.replaceAll(Y,be)}if(de[z].label=be,(se=de[z])!=null&&se.randomKey){const fe=((te=e.unref(n))==null?void 0:te.variableList)||[],ke=fe.filter(Ot=>Ot.randomKey===de[z].randomKey);ke!=null&&ke.length&&ke.forEach(Ot=>{Ot.label=be}),a({variableConditions:no(fe,l),variableList:fe})}a({[t.type]:de})}_=!1},D="DEFAULT",I=e.computed(()=>{const U=[],{scope:z}=e.unref(i)||{},Y=e.unref(n)[t.type]||[];if(z==="DIM"&&!e.unref(i).typeGuid.includes("_code")){const te=J.cloneDeep(e.unref(i));delete te.show,delete te.truncations,delete te.conditions,te.hrpIndexComplexid+="_code",te.id+="_code",te.typeGuid+="_code",te.label=te.name+"_编码",te.name=te.typeGuid,te.defaultCode=te.typeGuid,U.push(te)}const{leftAxisList:K=[],rightAxisList:ie=[],indicators:se=[]}=e.unref(n)||{};return[...Y,...U,...K,...ie,...se]}),$=(U={},z,Y="ASC")=>{var de;const{label:K,name:ie,id:se,defaultCode:te}=U,be=((de=e.unref(n)[t.type])==null?void 0:de.slice())||[];se===D?delete be[z].sort:be[z].sort={label:K,columnName:ie,type:"NORMAL",order:Y,defaultCode:te},a({[t.type]:be})},x=(U={},z="ASC")=>{const K={ASC:"升序",DESC:"降序"}[z],{sort:ie}=U,{label:se,order:te}=ie||{};return se&&te===z?`${K}(${se})`:K},V=e.ref(),T=e.ref(),P=e.ref(),R=e.ref(),N=(U={},z)=>{var Y;V.value=U,T.value=z,(Y=e.unref(P))==null||Y.showModal(U)},v=U=>"排序"+(U!=null&&U.sort?"(已配置)":""),A=(U={},z)=>{var Y;V.value=U,T.value=z,(Y=e.unref(R))==null||Y.showModal()},F=U=>"自定义分组"+((U==null?void 0:U.customGroup)!=null?"(已配置)":""),M=[{name:"总和",value:"SUM"},{name:"平均数",value:"AVG"},{name:"最小值",value:"MIN"},{name:"最大值",value:"MAX"},{name:"计数",value:"COUNT"}],G=[{name:"是",value:1},{name:"否",value:0}],W=(U,z)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[z].aggregate=U,a({[t.type]:Y})},X=(U,z)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[z].distinct=U,a({[t.type]:Y})},Q=(U,z)=>{var K;const Y=((K=e.unref(n)[t.type])==null?void 0:K.slice())||[];Y[z].dateFormat=U,a({[t.type]:Y})},Z=(U="SUM")=>`汇总方式(${{SUM:"总和",AVG:"平均数",MIN:"最小值",MAX:"最大值",COUNT:"计数"}[U]})`,ae=U=>`是否去重(${{0:"否",1:"是"}[U]||"否"})`,le=(U={})=>{var z;return"过滤"+(U!=null&&U.conditions&&((z=U==null?void 0:U.conditions)==null?void 0:z.length)>0?"(已配置)":"")},_e=e.ref(),St=e.ref(),Xe=e.ref(),pe=e.ref(),Oe=(U={},z)=>{V.value=U,T.value=z,e.unref(_e).showModal()},ut=(U={},z)=>{V.value=U,T.value=z,e.unref(St).showModal(U)},ho=(U={},z)=>{V.value=U,T.value=z,e.unref(Xe).showModal(U)},Ht=(U={},z)=>{V.value=U,T.value=z,e.unref(pe).showModal(U,e.unref(go))},Nt=e.ref(),$e=e.ref("add"),tt=(U,z,Y)=>{var K;$e.value=U,U==="edit"&&(V.value=z,T.value=Y),(K=e.unref(Nt))==null||K.showModal()},ot=e.inject(Ee),nt=e.unref(e.inject(Be)),Fe=e.ref([]),Tt=e.computed(()=>e.unref(n)[t.type]||{});e.watch(n,()=>{var U;we(e.unref(ne).type,["scatter","valueline"])&&((U=e.unref(n))!=null&&U.indicators)&&(Fe.value=e.unref(n).indicators.map(z=>({label:z.label,value:z.label})))}),e.watch(()=>n.value.classificationList,()=>{ft()});const at=e.ref(""),ft=async()=>{const{source:U}=e.unref(n);if(U!=="EDV_DATA_SET"||!we(e.unref(ne).type,"select"))return;const{classificationList:z=[]}=e.unref(n),Y=z.find(te=>te.show);if(Y!=null&&Y.parentId){if(e.unref(at)===Y.parentId)return;at.value=Y.parentId}else{e.unref(n).selectFieldOptions=[],Fe.value=[],at.value="";return}const K=await ot.get(`${Se}/dataset/`+Y.parentId,{headers:{Authentication:nt,operateContext:"ygt"}}),{success:ie,data:se=[]}=K.data;if(ie){const te=se.column.map(be=>({label:be.columnName,value:be.columnName}));e.unref(n).selectFieldOptions=te,Fe.value=te}},At=async()=>{const{source:U}=e.unref(n);if(!we(e.unref(ne).type,["scatter","valueline"]))try{if(U==="EDV_DATA_SET")await ft();else{const z=await ot.post(`${Se}/diagram/dimFields`,{},{headers:{Authentication:nt,operateContext:"ygt"}}),{success:Y,data:K=[]}=z.data;Y&&(e.unref(n).selectFieldOptions=K||[],Fe.value=K)}}catch(z){console.error(z)}},Wo=(U,z)=>{const Y=e.unref(n)[t.type]||{};Y[z]=U,a({[t.type]:Y})},bo=["classificationList","seriesList","rowHeaderList","queryColumnList","dimensionList"],yo=e.ref({}),go=e.ref([]),H=async(U,z)=>{var K;const{name:Y}=z;if(!bo.includes(t.type)&&U&&We(z,"indexCode")){const ie=await ot.post(`${Se}/diagram/hrpIndexWithComplex`,{dataSourceId:"",indexGuid:z.id,indexCode:z.indexCode,pageId:(K=window==null?void 0:window.config)==null?void 0:K.pageId},{headers:{Authentication:nt,operateContext:"ygt"}}),{success:se,data:te}=ie.data;se&&te&&(go.value=(te==null?void 0:te.dataViewColumns)||[],yo.value[Y]={name:te.name,code:te.indexCode})}},q=U=>{i.value=U},ee=U=>{const z=document.createElement("input");document.body.appendChild(z),z.setAttribute("value",U),z.select(),document.execCommand("copy"),document.body.removeChild(z),j.message.success("复制成功")},ne=e.inject(Ie),re=e.computed(()=>t.type==="indicators"&&e.unref(ne).type==="ecanTable"),ue=e.computed(()=>!!["indicators","classificationList","leftAxisList","rightAxisList"].includes(t.type));return e.onMounted(()=>{t.type==="formFields"&&(e.unref(ne).type==="ecanDataSelect"?Fe.value=[{label:"维度编码",value:"_code"},{label:"维度值",value:"_value"}]:At())}),{onCheckboxChange:h,onDropEnd:b,onDragItemEnd:m,onDragItemAdd:w,onDragItemSort:g,onDragItemStart:S,cardItemList:C,onDelete:E,onEdit:O,onCommitLabelChange:L,sortList:I,onSort:$,handleSortTitle:x,showCustomSortModal:N,customSortModalRef:P,currentItem:V,currentIndex:T,handleCustomSortTitle:v,handleCustomGroupTitle:F,customGroupModalRef:R,showCustomGroupModal:A,editLabelList:k,onLabelChange:B,aggregateList:M,distinctList:G,onAggregateChange:W,onDistinctChange:X,onDateFormatChange:Q,handleAggregateTitle:Z,handleDistinctTitle:ae,onShowCalculationModal:tt,handleFilterTitle:le,filterModalRef:_e,configNameRef:St,sortByCpntRef:Xe,dimByCountRef:pe,showFilterModal:Oe,calculationModalRef:Nt,calculationModalMode:$e,formatList:o,fieldOptions:Fe,fieldData:Tt,onFieldChange:Wo,onVisibleChange:H,onClickSetting:q,copyDataViewName:ee,dataViewMap:yo,isShowConfigName:re,showConfigNameModal:ut,dimensionType:bo,isShowSortByCpnt:ue,showSortByCpntModal:ho,dataSelectIndicators:p,showDimByCountModal:Ht,selectedComponent:ne,lowerCaseIncludes:we}}}),Py="",jy="",Ct=t=>(e.pushScopeId("data-v-73e39b35"),t=t(),e.popScopeId(),t),Lu={class:"title"},vu={class:"title-text"},$u={class:"field-wrap"},Fu={class:"field-item"},Iu=Ct(()=>e.createElementVNode("div",{class:"item-label"},"名称:",-1)),Du={class:"field-item"},Mu=Ct(()=>e.createElementVNode("div",{class:"item-label"},"值:",-1)),Pu={key:0,class:"field-item"},ju=Ct(()=>e.createElementVNode("div",{class:"item-label",style:{width:"20px"}},null,-1)),Ru={class:"title"},Uu={class:"title-text"},zu=Ct(()=>e.createElementVNode("p",null,"配置了维度后,会使用返回数据的第一条中以【维度名】为key的值作为显示值",-1)),Gu=Ct(()=>e.createElementVNode("span",null,"添加计算指标",-1)),Hu={class:"card-item-wrap"},Wu={class:"card-item-inner"},Yu=["onClick"],qu=["onClick"],Ku=["onClick"],Xu={style:{display:"flex","align-items":"center"}},Qu=["title"],Ju=Ct(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"指标名:",-1)),Zu={style:{display:"flex","align-items":"center"}},ef=["title"],tf=Ct(()=>e.createElementVNode("span",{style:{"font-weight":"bold"}},"指标编码:",-1));function of(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-checkbox"),i=e.resolveComponent("a-card"),c=e.resolveComponent("info-circle-outlined"),p=e.resolveComponent("a-popover"),u=e.resolveComponent("plus-outlined"),f=e.resolveComponent("a-input"),y=e.resolveComponent("setting-outlined"),h=e.resolveComponent("a-menu-item"),b=e.resolveComponent("a-menu-divider"),m=e.resolveComponent("a-sub-menu"),w=e.resolveComponent("copy-outlined"),g=e.resolveComponent("a-menu"),S=e.resolveComponent("a-dropdown"),C=e.resolveComponent("delete-outlined"),k=e.resolveComponent("draggable"),_=e.resolveComponent("custom-sort-modal"),E=e.resolveComponent("custom-group-modal"),O=e.resolveComponent("filter-modal"),B=e.resolveComponent("config-name"),L=e.resolveComponent("sort-by-cpnt"),D=e.resolveComponent("dim-by-count"),I=e.resolveComponent("calculation-modal"),$=e.resolveDirective("focus");return t.type==="formFields"?(e.openBlock(),e.createBlock(i,{key:0,class:"data-config-card","head-style":{backgroundColor:"rgba(161,212,230,0.3)",height:"58px",padding:"0 10px"}},{title:e.withCtx(()=>[e.createElementVNode("div",Lu,[e.createElementVNode("div",vu,e.toDisplayString(t.title),1)])]),default:e.withCtx(()=>[e.createElementVNode("div",$u,[e.createElementVNode("div",Fu,[Iu,e.createVNode(s,{style:{width:"70%"},class:"item-select",value:t.fieldData.labelField,options:t.fieldOptions,onChange:o[0]||(o[0]=x=>t.onFieldChange(x,"labelField"))},null,8,["value","options"])]),e.createElementVNode("div",Du,[Mu,e.createVNode(s,{style:{width:"70%"},class:"item-select",value:t.fieldData.valueField,options:t.fieldOptions,mode:t.lowerCaseIncludes(t.selectedComponent.type,"valueline")?"multiple":void 0,onChange:o[1]||(o[1]=x=>t.onFieldChange(x,"valueField"))},null,8,["value","options","mode"])]),t.selectedComponent.type==="ecanSelect"?(e.openBlock(),e.createElementBlock("div",Pu,[ju,e.createVNode(d,{checked:t.fieldData.hasAllOption,"onUpdate:checked":o[2]||(o[2]=x=>t.fieldData.hasAllOption=x)},{default:e.withCtx(()=>[e.createTextVNode(" 显示【全部】选项 ")]),_:1},8,["checked"])])):e.createCommentVNode("",!0)])]),_:1},8,["head-style"])):(e.openBlock(),e.createBlock(i,{key:1,class:"data-config-card","head-style":{backgroundColor:"rgba(161,212,230,0.3)",height:"58px",padding:"0 10px"}},{title:e.withCtx(()=>[e.createElementVNode("div",Ru,[e.createElementVNode("div",Uu,[e.createTextVNode(e.toDisplayString(t.title)+" ",1),t.type==="dimensionList"?(e.openBlock(),e.createBlock(p,{key:0,title:"提示",placement:"topLeft"},{content:e.withCtx(()=>[zu]),default:e.withCtx(()=>[e.createVNode(c,{style:{color:"#919191",cursor:"pointer"}})]),_:1})):e.createCommentVNode("",!0)]),!t.dimensionType.includes(t.type)&&!t.dataSelectIndicators?(e.openBlock(),e.createElementBlock("div",{key:0,class:"add-calculation",onClick:o[3]||(o[3]=e.withModifiers(x=>t.onShowCalculationModal("add"),["prevent","stop"]))},[e.createVNode(u,{class:"add-calculation-icon"}),Gu])):e.createCommentVNode("",!0)])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(t.type+"-list"),style:{height:"100%",padding:"10px"}},[e.createVNode(k,{modelValue:t.cardItemList,"onUpdate:modelValue":o[4]||(o[4]=x=>t.cardItemList=x),class:"chart-column",id:t.type,group:"cardItem","item-key":"index",onAdd:t.onDragItemAdd,onSort:t.onDragItemSort,onEnd:t.onDragItemEnd,onStart:o[5]||(o[5]=x=>t.onDragItemStart(x,t.cardItemList))},{item:e.withCtx(({element:x,index:V})=>[e.createElementVNode("div",Hu,[e.createVNode(d,{class:"card-item",checked:x.show,onChange:T=>t.onCheckboxChange(T,V)},{default:e.withCtx(()=>[e.createElementVNode("div",Wu,[!t.editLabelList[V]&&x.label?(e.openBlock(),e.createElementBlock("div",{key:0,class:"name",onClick:e.withModifiers(T=>t.onEdit(V),["prevent","stop"])},e.toDisplayString(x.label),9,Yu)):e.createCommentVNode("",!0),!t.editLabelList[V]&&!x.label?(e.openBlock(),e.createElementBlock("div",{key:1,class:"name placeholder",onClick:e.withModifiers(T=>t.onEdit(V),["prevent","stop"])}," 请点击填入名字 ",8,qu)):e.createCommentVNode("",!0),t.editLabelList[V]?e.withDirectives((e.openBlock(),e.createBlock(f,{key:2,"default-value":x.label,size:"small",onBlur:T=>t.onCommitLabelChange(T,V,x.label),onPressEnter:T=>t.onCommitLabelChange(T,V,x.label),onChange:t.onLabelChange},null,8,["default-value","onBlur","onPressEnter","onChange"])),[[$]]):e.createCommentVNode("",!0),["FORMULA","BUILT_IN","COMPONENT"].includes(x.calcType)?(e.openBlock(),e.createElementBlock("span",{key:3,class:"calculation-icon",onClick:e.withModifiers(T=>t.onShowCalculationModal("edit",x,V),["prevent","stop"])}," fx ",8,Ku)):e.createCommentVNode("",!0),e.createVNode(S,{trigger:["click"],onVisibleChange:T=>t.onVisibleChange(T,x)},{overlay:e.withCtx(()=>[e.createVNode(g,null,{default:e.withCtx(()=>[t.dimensionType.includes(t.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(h,{onClick:T=>t.showCustomSortModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleCustomSortTitle(x)),1)]),_:2},1032,["onClick"]),e.createVNode(b),e.createVNode(h,{onClick:T=>t.showCustomGroupModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleCustomGroupTitle(x)),1)]),_:2},1032,["onClick"]),e.createVNode(b),x.genericType==="DATE"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(m,{title:"日期格式化"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formatList,T=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:T.value,onClick:P=>t.onDateFormatChange(T.value,V)},{default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(x.dateFormat===T.value||!x.dateFormat&&T.value==="YYYY-MM"?"color: #1890FF;":"")},e.toDisplayString(T.label),5)]),_:2},1032,["onClick"]))),128))]),_:2},1024),e.createVNode(b)],64)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createVNode(h,{onClick:T=>t.showFilterModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.handleFilterTitle(x)),1)]),_:2},1032,["onClick"]),e.createVNode(b),["classificationList","seriesList"].includes(t.type)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(m,{title:t.handleAggregateTitle(x.aggregate)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.aggregateList,T=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:T.value,onClick:P=>t.onAggregateChange(T.value,V)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(T.name),1)]),_:2},1032,["onClick"]))),128))]),_:2},1032,["title"]),e.createVNode(b)],64)),t.isShowConfigName?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(h,{onClick:T=>t.showConfigNameModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(" 修改展示名称 ")]),_:2},1032,["onClick"]),e.createVNode(b)],64)):e.createCommentVNode("",!0),t.isShowSortByCpnt?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createVNode(h,{onClick:T=>t.showSortByCpntModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(" 关联组件排序 ")]),_:2},1032,["onClick"]),e.createVNode(b)],64)):e.createCommentVNode("",!0),x.name==="the_count"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createVNode(h,{onClick:T=>t.showDimByCountModal(x,V)},{default:e.withCtx(()=>[e.createTextVNode(" 关联维度 ")]),_:2},1032,["onClick"]),e.createVNode(b),e.createVNode(m,{title:t.handleDistinctTitle(x.distinct)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.distinctList,T=>(e.openBlock(),e.createBlock(h,{style:{"white-space":"nowrap"},key:T.value,onClick:P=>t.onDistinctChange(T.value,V)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(T.name),1)]),_:2},1032,["onClick"]))),128))]),_:2},1032,["title"]),e.createVNode(b)],64)):e.createCommentVNode("",!0),t.dimensionType.includes(t.type)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[t.dataViewMap[x.name]?(e.openBlock(),e.createBlock(h,{key:0,onClick:T=>t.copyDataViewName(t.dataViewMap[x.name].name)},{default:e.withCtx(()=>[e.createElementVNode("div",Xu,[e.createElementVNode("span",{class:"data-view-name",title:t.dataViewMap[x.name].name},[Ju,e.createTextVNode(" "+e.toDisplayString(t.dataViewMap[x.name].name),1)],8,Qu),e.createVNode(w,{style:{color:"#52C41A","margin-left":"10px"},title:"点击复制"})])]),_:2},1032,["onClick"])):e.createCommentVNode("",!0),t.dataViewMap[x.name]?(e.openBlock(),e.createBlock(h,{key:1,onClick:T=>t.copyDataViewName(t.dataViewMap[x.name].code)},{default:e.withCtx(()=>[e.createElementVNode("div",Zu,[e.createElementVNode("span",{class:"data-view-name",title:t.dataViewMap[x.name].code},[tf,e.createTextVNode(" "+e.toDisplayString(t.dataViewMap[x.name].code),1)],8,ef),e.createVNode(w,{style:{color:"#52C41A","margin-left":"10px"},title:"点击复制"})])]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)],64))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(y,{class:"setting-icon",onClick:T=>t.onClickSetting(x)},null,8,["onClick"])]),_:2},1032,["onVisibleChange"]),e.createVNode(C,{class:"delete-icon",onClick:e.withModifiers(T=>t.onDelete(V),["prevent"])},null,8,["onClick"])])]),_:2},1032,["checked","onChange"])])]),_:1},8,["modelValue","id","onAdd","onSort","onEnd"])],2),e.createVNode(_,{item:t.currentItem,index:t.currentIndex,type:t.type,sortList:t.sortList,ref:"customSortModalRef"},null,8,["item","index","type","sortList"]),e.createVNode(E,{item:t.currentItem,index:t.currentIndex,type:t.type,ref:"customGroupModalRef"},null,8,["item","index","type"]),e.createVNode(O,{item:t.currentItem,index:t.currentIndex,type:t.type,ref:"filterModalRef"},null,8,["item","index","type"]),e.createVNode(B,{index:t.currentIndex,type:t.type,ref:"configNameRef"},null,8,["index","type"]),e.createVNode(L,{index:t.currentIndex,type:t.type,ref:"sortByCpntRef"},null,8,["index","type"]),e.createVNode(D,{index:t.currentIndex,type:t.type,ref:"dimByCountRef"},null,8,["index","type"]),e.createVNode(I,{type:t.type,item:t.currentItem,index:t.currentIndex,mode:t.calculationModalMode,ref:"calculationModalRef"},null,8,["type","item","index","mode"])]),_:1},8,["head-style"]))}const nf=oe(Vu,[["render",of],["__scopeId","data-v-73e39b35"]]),af={classificationList:{title:"分类"},seriesList:{title:"系列"},leftAxisList:{title:"左值轴"},rightAxisList:{title:"右值轴"},indicators:{title:"数值"},queryColumnList:{title:"查询列"},rowHeaderList:{title:"行表头"},formFields:{title:"字段"},dimensionList:{title:"维度"}},lf=e.defineComponent({name:"DataConfigGroup",components:{DataConfigCard:nf},setup(){const t=["classificationList","seriesList","leftAxisList","rightAxisList","indicators","rowHeaderList","queryColumnList"],o=e.inject(Ie),n=e.computed(()=>{var i;return(i=e.unref(o))==null?void 0:i.type}),a=e.computed(()=>{var i;return!!((i=e.unref(o))!=null&&i.isGroupTable)}),l=e.ref({}),r=e.reactive([]),s=e.inject(Ne),d=()=>{var b,m;const i=J.cloneDeep((b=e.unref(o))==null?void 0:b.graphicConfig),c={card:["rowHeaderList","indicators"],pie:["classificationList","indicators"],circulate:["classificationList","indicators"],bar:["classificationList","seriesList","leftAxisList"],line:["classificationList","seriesList","leftAxisList"],comboGraph:["classificationList","seriesList","leftAxisList","rightAxisList"],radar:["classificationList","seriesList","leftAxisList"],table:a.value?["rowHeaderList","indicators"]:["queryColumnList","indicators"],text:["dimensionList","indicators"],proportion:["indicators"],select:["classificationList","formFields"],dataSelect:["classificationList","indicators","formFields"],checkbox:["classificationList","formFields"],radio:["classificationList","formFields"],list:["classificationList","indicators"],counter:["indicators"],scatter:["classificationList","indicators","formFields"],pivotTable:["queryColumnList","indicators"],valueLine:["classificationList","indicators","formFields"]},p="ecan";let u=e.unref(n);if(u.startsWith(p)){const w=p.length;u=((m=u.slice(w,w+1))==null?void 0:m.toLowerCase())+u.slice(w+1)}const f=c[u],y=af,h=(f==null?void 0:f.length)||0;for(let w=0;w<h;w++){const g=f[w];if(!g)break;r.push({...y[g],type:g})}for(const w of t)We(i,w)&&!f.find(g=>g===w)?i[w]=[]:delete i[w];s(i)};return d(),e.watch(()=>n.value,()=>{r.length=0,d()}),{cardsMap:l,cards:r}}}),Ry="",Uy="",rf={class:"data-group"};function sf(t,o,n,a,l,r){const s=e.resolveComponent("data-config-card");return e.openBlock(),e.createElementBlock("div",rf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.cards,d=>(e.openBlock(),e.createBlock(s,e.mergeProps({key:d.type,class:"data-config-card",type:d.type},d),null,16,["type"]))),128))])}const cf=oe(lf,[["render",sf],["__scopeId","data-v-0436e5bb"]]),df=[{title:"基本属性",props:["keyName","left","top","width","height","colors","textShadow","backgroundColor","backgroundImage","backgroundSize","theme","pageFontFamily","contextRequestUrl","graphicType"]},{title:"定时跳转",props:["jumpType","jumpTime","jumpPage","jumpLink"]},{title:"弹窗",onlyType:"modal",props:["position","fullModal","isShowCloseBtn","centered","destroyOnClose","closeBtnColor","borderRadius","borderWidth","borderColor","boxShadow"]},{title:"图片",props:["borderRadius","isAnimation","animationSource","isHoverStyle","imgUrl"]},{title:"链接",props:["linkPage","href","target","transParams"]},{title:"系列",props:["seriesTypes"]},{title:"折线图",onlyType:["line","comboGraph"],props:["areaStyleOpacity","areaGradientShow","areaGradientColor","smooth","lineStyleWidth","symbolSize","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]},{title:"散点图",onlyType:["scatter"],props:["symbolSize","symbolColor"]},{title:"雷达图",onlyType:["radar"],props:["areaStyleOpacity","lineStyleWidth","symbolSize","labelShow","axisNameColor"]},{title:"单选框",onlyType:["radio"],props:["value","optionType","tabFontSize","tabHorizontalPadding","tabBarGutter","tabFlexDirection","tabTextAlign","tabColor","activeTabColor","tabBackgroundImage","activeTabBackgroundImage"]},{title:"柱状图",onlyType:["bar","comboGraph"],props:["barWidth","barBorderRadius","isUseHorizontalAxis","axisInverse","isStack","stackColumns","labelShow","showBarBackground"]},{title:"饼图",onlyType:"pie",props:["centerTop","centerLeft","innerRadius","outerRadius","roseType","minAngle"]},{title:"布局",props:["gridTop","gridBottom","gridLeft","gridRight","gridContainLabel"]},{title:"标签边距",props:["gridTopPx","gridBottomPx","gridLeftPx","gridRightPx"]},{title:"标题",onlyType:["bar","combo-graph","line","pie","radar","scatter"],props:["titleText","titleFontSize","titleColor","fontWeight","textAlign"]},{title:"x轴",props:["xAxisLabelColor","xAxisLineStyleColor","xAxisLabelWidth","xAxisLabelOverflow","xAxisLabelRotate","xAxisTickShow","xAxisSplitLineShow","xAxisSplitLineType","xAxisSplitAreaShow","xAxisLineShow","isBoundaryGap","xAxisSplitLineInterval","xAxisSplitLineStyleColor","xAxisLabelFormatter","xAxisInverse","xAxisMinInterval","xAxisLabelInterval","xAxisLabelFontSize","xAxisName","xAxisMaxValue","showXAxisLineArrow","xAxisLineInverse"]},{title:"y轴",props:["yAxisLabelColor","yAxisLineStyleColor","yAxisLineAlwaysDisplay","yAxisLabelWidth","yAxisLabelOverflow","yAxisLabelRotate","yAxisTickShow","yAxisSplitLineShow","yAxisSplitLineType","yAxisLeftSplitLineShow","yAxisLeftSplitLineType","yAxisRightSplitLineShow","yAxisRightSplitLineType","yAxisSplitAreaShow","yAxisLabelShow","yAxisSplitLineStyleColor","yAxisLabelFormatter","yAxisInverse","yAxisMinInterval","yAxis","yAxisLabelFontSize","yAxisName","yAxisLeftName","yAxisRightName","yAxisMaxValue","showYAxisLineArrow","yAxisLineInverse"]},{title:"标签",enableProps:"labelShow",excludeType:"map",props:["labelFormatter","labelWidth","labelColor","isUseLabelColors","labelFontSize","labelPosition","labelOverflow"]},{title:"标签引导线",enableProps:"labelLineShow",props:["labelLineLength","labelLineLength2"]},{title:"图例",enableProps:"legendShow",props:["legendFormatter","legendWidth","legendHeight","legendTextWidth","legendTextStyleColor","legendFontSize","legendTop","legendLeft","legendOrient","legendType","legendItemGap","legendItemWidth","legendItemHeight","legendScroll"]},{title:"提示框",enableProps:"tooltipShow",props:["tooltipTrigger","tooltipFormatter","tooltipTextStyleColor","tooltipBackgroundColor","tooltipRequestData","tooltipPosition"]},{title:"渐变",enableProps:"gradientShow",showSwitch:!0,onlyType:["bar","proportion","border","comboGraph","text","radar"],props:["isTransparent","gradientColor","gradientColors","gradientOffset","gradientAngle"]},{title:"图表标线",enableProps:"isShowMarkLine",showSwitch:!0,onlyType:["line","bar","comboGraph","scatter"],props:["markLineType"]},{title:"图表标线",onlyType:["scatter"],props:["xAxisMarkLineValue","yAxisMarkLineValue"]},{title:"图表标域",onlyType:["scatter"],props:["axisMarkArea"]},{title:"默认范围值",enableProps:"defaultRangeValue",showSwitch:!0,onlyType:["bar","comboGraph"],props:["startValue","endValue"]},{title:"单位",enableProps:"unitShow",onlyType:["text"],props:["unitText","unitFontSize","unitFontWeight","unitColor","unitTop","unitLeft"]},{title:"目标值",enableProps:"targetShow",onlyType:["text"],props:["targetRule","targetValue","notExpectColor"]},{title:"时间",onlyType:["date","time","range"],props:["picker","optionFontSize","format","show","limitInterval","startTime","endTime","value","showTime","useCurrentTime","isAllowSpanYear","interval","intervalUnit","updateInterval","operate","limitStartTime","limitEndTime"]},{title:"选择器",onlyType:"select",props:["value","mode","multiple","treeCheckable","maxTagCount","autoClearSearchValue","isAllowClear","placeholder","valueType","optionFontSize"]},{title:"表格",onlyType:"table",props:["size","allOverflow","hoverRow","hoverColor","boderList","columnDropEnable","showTotalBool","totalName","expandAll"]},{title:"列表",onlyType:"list",props:["columns","sliceCount","itemWidth","itemHeight","itemColSpan","itemPadding","itemRowSpan","useTitle","isAutoScroll","scrollSpeed"]},{title:"小计",onlyType:"table",props:["subTotalName","subTotalColumn"]},{title:"序号列",onlyType:["table","list"],enableProps:"isUseSeq",props:["seqWidth","seqName","seqIcon","seqFontSize","seqIndexFormatter"]},{title:"序号图标",onlyType:["list"],enableProps:"seqIcon",props:["seqIconConfig","seqIconWidth","seqIconHeight","seqIconOffsetX","seqIconOffsetY"]},{title:"操作列",onlyType:"table",enableProps:"isUseAction",props:["actionList","actionColumnWidth"]},{title:"分页",enableProps:"paginationShow",props:["paginationPageSize","simple","pageSizeShow","showQuickJumper","paginationPosition","isPageBottom","isShowTotal","paginationColor","paginationBgColor","activePaginationColor","activePaginationBgColor"]},{title:"循环列表",onlyType:"circulate",props:["colNum","unitInterval","isAutoScroll","scrollSpeed","scrollDirection","keyFieldMap"]},{title:"计数器",onlyType:"counter",props:["digits","unitInterval","unitWidth","unitHeight","counterBackgroundImage"]},{title:"边框",onlyType:["border","circulate"],props:["mode","borderWidth","borderRadius","borderColor","useBorderModify","borderStyle","titleMode"]},{title:"标签页",onlyType:"tabs",props:["tabType","tabWidth","activeKey","tabFontSize","tabFontWeight","tabHorizontalPadding","tabBarGutter","tabOuterMargin","tabFlexDirection","tabAlignItems","tabJustifyContent","tabColor","activeTabColor","tabBackgroundImage","activeTabBackgroundImage","autoSwitch","autoSwitchInterval","hideTabs"]},{title:"进度条",onlyType:"proportion",props:["strokeWidth","strokeType","strokeLinecap","strokeColor","trailColor"]},{title:"地图数据",onlyType:"map",props:["mapJson","geoCenter"]},{title:"地图样式",onlyType:"map",props:["geoRoam","geoZoom","geoLabelColor","geoLabelShow","geoLabelFontSize","geoBackgroundImage","geoBackgroundImageRepeat","geoItemStyleAreaColor","geoItemStyleBorderColor","geoItemStyleBorderWidth","geoItemStyleShadowColor","geoItemStyleShadowOffsetX","geoItemStyleShadowOffsetY","geoItemStyleShadowBlur","symbolImage","symbolWidth","symbolHeight"]},{title:"悬停地图样式",onlyType:"map",props:["geoEmphasisDisabled","geoEmphasisLabelColor","geoEmphasisItemStyleAreaColor","geoEmphasisItemStyleBorderColor"]},{title:"按钮",onlyType:"button",props:["mode","danger","shape","tooltipTextStyleColor","borderColor","buttonBackgroundColor"]},{title:"输入框",onlyType:"input",props:["value","placeholder","optionFontSize"]},{title:"网页",onlyType:"iframe",props:["link","linkType"]}],or=[{label:"思源黑体",value:'"SansSc"'},{label:"黑体",value:'"SimHei","STHeiti"'},{label:"楷体",value:'"KaiTi","STKaiti"'},{label:"宋体",value:'"SimSun","STSong"'},{label:"仿宋",value:'"FangSong","STFangsong"'}].map(t=>({value:t.value,label:e.createVNode("span",{style:{fontFamily:t.value}},[t.label])})),pf={keyName:{label:"控件别名",component:"input",props:{isKeyName:!0}},text:{label:"文本",component:"textarea"},title:{label:"标题",component:"input"},textShadow:{label:"阴影",component:"input"},width:[{label:"页面宽度",updateMode:"page",component:"input-number",onlyType:"page",props:{suffix:"px",disabled:!1}},{label:"弹窗宽度",onlyType:"modal",component:"input-number",props:{suffix:"px",max:1920,min:0}},{label:"宽度",component:"input-number",props:{suffix:"px",min:0}}],height:[{label:"页面高度",updateMode:"page",onlyType:"page",component:"input-number",props:{suffix:"px",disabled:!1}},{label:"弹窗高度",onlyType:"modal",component:"input-number",props:{suffix:"px",max:1080,min:10}},{label:"高度",component:"input-number",props:{suffix:"px",min:1}}],backgroundImage:[{label:"背景图",component:"image-pick",updateMode:"page",onlyType:"page"},{label:"背景图",component:"image-pick"}],backgroundSize:[{label:"背景尺寸",component:"radio-group",updateMode:"page",onlyType:"page",props:{options:[{label:"覆盖",value:"cover"},{label:"铺满",value:"100% 100%"}]}}],backgroundColor:[{label:"背景颜色",component:"color-pick",updateMode:"page",onlyType:"page"},{label:"背景颜色",component:"color-pick"}],contextRequestUrl:{label:"请求地址",component:"input",updateMode:"page"},theme:{label:"主题",component:"select",props:{options:[{label:"默认",value:"light"},{label:"暗蓝",value:"darkBlue"}]},updateMode:"page"},pageFontFamily:{label:"字体",component:"select",updateMode:"page",onlyType:"page",props:{options:[{label:"无",value:""},...or]}},value:[{label:"时间值",component:"time-pick",onlyType:"date"},{label:"默认值",component:"input",onlyType:"select"},{label:"默认值",component:"input",onlyType:"tabs"},{label:"默认值",component:"input",onlyType:"input"},{label:"默认值",component:"checkbox",onlyType:"checkbox"},{label:"默认值",component:"input",onlyType:"radio"}],placeholder:[{label:"占位文字",component:"input"}],imgUrl:{label:"图片",component:"image-pick",show:[{match:"isAnimation",value:!1}]},linkUrl:{label:"链接地址",component:"input"},linkMethod:{label:"打开方式",component:"radio-group",props:{options:[{label:"本窗口",value:"_self"},{label:"新窗口",value:"_blank"}]}},linkPage:{label:"链接项目页面",component:"page-pick"},fontSize:{label:"字号",component:"input-number",props:{suffix:"px",min:12,max:100}},variableFontSize:{label:"变量字号",component:"input-number",props:{suffix:"px",min:12,max:100}},percentageSide:{label:"涨跌幅图标",component:"radio-group",props:{optionType:"button",options:[{label:"左",value:"left"},{label:"右",value:"right"}]}},left:{label:"x轴",component:"input-number",props:{suffix:"px"}},top:{label:"y轴",component:"input-number",props:{suffix:"px"}},textAlign:{label:"水平对齐",component:"radio-group",props:{optionType:"button",options:[{label:"左",value:"left"},{label:"中",value:"center"},{label:"右",value:"right"}]}},verticalAlign:{label:"垂直对齐",component:"radio-group",props:{optionType:"button",options:[{label:"上",value:"top"},{label:"中",value:"middle"},{label:"下",value:"bottom"}]}},justifyContent:{label:"水平对齐",component:"radio-group",props:{optionType:"button",options:[{label:"左",value:"flex-start"},{label:"中",value:"center"},{label:"右",value:"flex-end"}]}},alignItems:{label:"垂直对齐",component:"radio-group",props:{optionType:"button",options:[{label:"上",value:"flex-start"},{label:"中",value:"center"},{label:"下",value:"flex-end"}]}},fontFamily:{label:"字体",component:"select",props:{options:[{label:"无",value:""},...or]}},tabFontWeight:{label:"字体粗细",component:"radio-group",props:{options:[{label:"细",value:100},{label:"正常",value:400},{label:"粗",value:700}],isTransformNumber:!0}},headerFontWeight:{label:"字体粗细",component:"radio-group",props:{options:[{label:"细",value:100},{label:"正常",value:400},{label:"粗",value:700}],isTransformNumber:!0}},fontWeight:{label:"字体粗细",component:"radio-group",props:{options:[{label:"细",value:100},{label:"正常",value:400},{label:"粗",value:700}],isTransformNumber:!0}},fontStyle:{label:"字体风格",component:"radio-group",props:{options:[{label:"正常",value:"normal"},{label:"倾斜",value:"italic"}],isTransformNumber:!0}},color:{label:"颜色",component:"color-pick"},colors:{label:"颜色",component:"color-group-pick"},centerLeft:{label:"水平位置",component:"input-number",props:{suffix:"%",min:0,max:100}},centerTop:{label:"垂直位置",component:"input-number",props:{suffix:"%",min:0,max:100}},lineHeight:{label:"行高",component:"input-number",props:{suffix:"px",min:0,step:.1}},innerRadius:{label:"内半径",component:"input-number",props:{suffix:"%",min:0,max:100}},outerRadius:{label:"外半径",component:"input-number",props:{suffix:"%",min:0,max:100}},titleText:{label:"标题",component:"input"},titleSubtext:{label:"副标题",component:"input"},tooltipTrigger:{label:"触发条件",component:"radio-group",props:{options:[{label:"图形",value:"item"},{label:"坐标轴",value:"axis"},{label:"无",value:"none"}]}},tooltipTextStyleColor:{label:"文字颜色",component:"color-pick"},tooltipFormatter:{label:"格式化",component:"textarea"},legendTextStyleColor:{label:"颜色",component:"color-pick"},legendTop:{label:"垂直位置",component:"radio-group",props:{options:[{label:"上",value:"top"},{label:"中",value:"middle"},{label:"下",value:"bottom"}]}},legendLeft:{label:"水平位置",component:"radio-group",props:{options:[{label:"左",value:"left"},{label:"中",value:"center"},{label:"右",value:"right"}]}},legendOrient:{label:"布局",component:"radio-group",props:{options:[{label:"垂直",value:"vertical"},{label:"水平",value:"horizontal"}]}},labelFormatter:{label:"格式化",component:"input"},labelColor:{label:"标签颜色",component:"color-pick"},isUseLabelColors:{label:"系列色",component:"switch"},labelFontSize:{label:"字体大小",component:"input-number",props:{min:12,suffix:"px"}},labelPosition:[{label:"位置",component:"radio-group",onlyType:"pie",props:{options:[{label:"外侧",value:"outside"},{label:"内侧",value:"inside"},{label:"中心",value:"center"}]}},{label:"位置",component:"select",onlyType:["bar","radar"],props:{options:[{label:"上",value:"top"},{label:"中",value:"inside"},{label:"下",value:"bottom"},{label:"右",value:"right"},{label:"左",value:"left"}]}}],labelLineLength:{label:"第一段",component:"input-number",props:{min:0}},labelLineLength2:{label:"第二段",component:"input-number",props:{min:0}},symbolSize:{label:"标记点尺寸",component:"input-number",props:{min:0}},symbolColor:{label:"标记点颜色",component:"color-pick"},symbolWidth:{label:"图标宽",component:"input-number",props:{min:0}},symbolHeight:{label:"图标高",component:"input-number",props:{min:0}},smooth:{label:"线条光滑",component:"switch"},lineStyleWidth:{label:"线条宽度",component:"input-number",props:{min:0}},picker:{label:"选择类型",component:"select",props:{options:[{label:"日期",value:"date"},{label:"年份",value:"year"},{label:"月份",value:"month"},{label:"星期",value:"week"},{label:"季度",value:"quarter"}]}},format:[{label:"格式化",onlyType:"text",component:"select",props:{options:[{label:"无",value:""},{label:"百分比",value:"percent"},{label:"涨跌幅",value:"percentage"},{label:"金额",value:"money"},{label:"千分位",value:"thousands"}]}},{label:"格式化",component:"input",onlyType:["date","range","time"]}],showTime:{label:"展示时间",component:"switch"},xAxisSplitLineShow:{label:"分割线",component:"switch"},xAxisSplitAreaShow:{label:"分隔区域",component:"switch"},xAxisLineShow:{label:"显示轴线",component:"switch"},isBoundaryGap:{label:"两边留白",component:"switch"},xAxisSplitLineInterval:{label:"分割线间隔",component:"input-number",props:{suffix:"",min:0}},xAxisSplitLineStyleColor:{label:"分割线颜色",component:"color-pick"},xAxisLabelColor:{label:"名称颜色",component:"color-pick"},xAxisLineStyleColor:{label:"横边颜色",component:"color-pick"},xAxisTickShow:{label:"显示刻度",component:"switch"},yAxisTickShow:{label:"显示刻度",component:"switch"},xAxisLabelFormatter:{label:"格式化",component:"input"},yAxisSplitLineShow:{label:"分割线",component:"switch"},yAxisLeftSplitLineShow:{label:"分割线-左轴",component:"switch"},yAxisRightSplitLineShow:{label:"分割线-右轴",component:"switch"},yAxisSplitLineType:{label:"分割线类型",component:"radio-group",props:{optionType:"button",options:[{label:"实线",value:"solid"},{label:"虚线",value:"dashed"},{label:"点状",value:"dotted"}]}},yAxisLeftSplitLineType:{label:"分割线类型-左轴",component:"radio-group",props:{optionType:"button",options:[{label:"实线",value:"solid"},{label:"虚线",value:"dashed"},{label:"点状",value:"dotted"}]}},yAxisRightSplitLineType:{label:"分割线类型-左轴",component:"radio-group",props:{optionType:"button",options:[{label:"实线",value:"solid"},{label:"虚线",value:"dashed"},{label:"点状",value:"dotted"}]}},xAxisSplitLineType:{label:"分割线类型",component:"radio-group",props:{optionType:"button",options:[{label:"实线",value:"solid"},{label:"虚线",value:"dashed"},{label:"点状",value:"dotted"}]}},yAxisSplitAreaShow:{label:"分隔区域",component:"switch"},yAxisLabelShow:{label:"刻度标签",component:"switch"},yAxisLineAlwaysDisplay:{label:"显示轴线",component:"switch"},yAxisSplitLineStyleColor:{label:"分割线颜色",component:"color-pick"},yAxisLabelColor:{label:"名称颜色",component:"color-pick"},yAxisLineStyleColor:{label:"竖边颜色",component:"color-pick"},yAxisLabelFormatter:{label:"格式化",component:"input"},roseType:{label:"玫瑰图",component:"radio-group",props:{options:[{label:"不展示",value:""},{label:"圆心角",value:"area"},{label:"半径",value:"radius"}]}},fullModal:{label:"全屏",component:"switch"},seqIconConfig:[{label:"图标索引",component:"icon-config",layout:"vertical",onlyType:"list"}],columns:[{label:"表格列",component:"form-collapse",onlyType:"table",props:{format:[{label:"名称",value:"title",type:"input"},{label:"索引",value:"dataIndex",type:"input"},{label:"宽度",value:"width",type:"input-number",props:{suffix:"%",min:0,max:100}},{label:"头部对齐",value:"headerCellAlign",type:"select",defaultValue:"center",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},{label:"单元格对齐",value:"cellAlign",type:"select",defaultValue:"center",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},{label:"格式化",value:"format",type:"select",defaultValue:"",props:{options:[{label:"无",value:""},{label:"金额",value:"money"},{label:"百分比",value:"percentage"},{label:"布尔值",value:"boolean"},{label:"对比",value:"contrast"},{label:"进度条",value:"progress"},{label:"保留小数",value:"decimals"},{label:"自定义",value:"custom"}]}},{label:"保留位数",value:"retentiondigit",type:"input-number",show:{match:"format",value:"decimals"},props:{min:0}},{label:"自定义格式化",value:"customFormatter",type:"input",defaultValue:"{value}",show:{match:"format",value:["custom","contrast"]}},{label:"涨幅颜色",value:"increaseColor",type:"color",defaultValue:"#ff512e",show:{match:"format",value:"contrast"}},{label:"跌幅颜色",value:"declineColor",type:"color",defaultValue:"#39cf93",show:{match:"format",value:"contrast"}},{label:"进度条颜色",value:"progressColor",type:"color",defaultValue:"#1890ff",show:{match:"format",value:"progress"}},{label:"进度条文字颜色",value:"progressTextColor",type:"color",defaultValue:"#333",show:{match:"format",value:"progress"}},{label:"进度条完成文字颜色",value:"progressFinishedTextColor",type:"color",defaultValue:"#fff",show:{match:"format",value:"progress"}},{label:"进度条文字保留小数位",value:"progressTextDecimalPlaces",type:"input-number",defaultValue:"2",props:{min:0},show:{match:"format",value:"progress"}},{label:"进度条线宽度",value:"progressWidth",type:"input-number",defaultValue:"18",props:{suffix:"px",min:0},show:{match:"format",value:"progress"}},{label:"默认值",value:"defaultVal",type:"input",defaultValue:""},{label:"内容超出时",value:"overflow",type:"select",defaultValue:"wrap",props:{options:[{label:"换行",value:"wrap"},{label:"省略号",value:"ellipsis"}]}},{label:"排序",value:"sorter",type:"switch",typeValue:"checked"},{label:"小计",value:"isCalcTotal",type:"switch",typeValue:"checked"},{label:"过滤",value:"tableFilter",type:"switch",typeValue:"checked"},{label:"隐藏",value:"isHidden",type:"switch",typeValue:"checked"}]}},{label:"列索引",component:"form-group",layout:"vertical",onlyType:"list",props:{format:[{label:"索引",value:"key",type:"input"},{label:"标题",value:"title",type:"input"},{label:"宽度",value:"width",type:"input-number",props:{suffix:"%",min:1}},{label:"对齐",value:"align",type:"select",defaultValue:"left",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},{label:"内容对齐",value:"cellAlign",type:"select",defaultValue:"left",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},{label:"背景颜色",value:"cellColor",type:"color",defaultValue:""},{label:"字体大小",value:"fontSize",type:"input-number",props:{suffix:"px",min:12}},{label:"字体颜色",value:"color",type:"color",defaultValue:""},{label:"字体粗细",value:"fontWeight",type:"select",defaultValue:"normal",props:{options:[{label:"较细",value:"lighter"},{label:"正常",value:"normal"},{label:"较粗",value:"bold"}]}},{label:"标题字体颜色",value:"titleColor",type:"color",defaultValue:""},{label:"格式化",value:"format",type:"select",defaultValue:"",props:{options:[{label:"无",value:""},{label:"金额",value:"money"},{label:"百分比",value:"percentage"},{label:"对比",value:"contrast"},{label:"进度条",value:"progress"},{label:"自定义",value:"custom"}]}},{label:"进度条颜色",value:"progressColor",type:"color",defaultValue:"#1890ff",show:{match:"format",value:"progress"}},{label:"进度条渐变色",value:"progressGradientColor",type:"color",defaultValue:"#1890ff",show:{match:"format",value:"progress"}},{label:"进度条底色",value:"progressBaseColor",type:"color",defaultValue:"",show:{match:"format",value:"progress"}},{label:"进度条线宽度",value:"progressWidth",type:"input-number",defaultValue:"14",props:{suffix:"px",min:0},show:{match:"format",value:"progress"}},{label:"自定义格式化",value:"customFormatter",type:"input",defaultValue:"{value}",show:{match:"format",value:["custom"]}}]}}],bordered:{label:"边框",component:"switch"},size:[{label:"尺寸",onlyType:"table",component:"radio-group",props:{options:[{label:"默认",value:"default"},{label:"中等",value:"middle"},{label:"小号",value:"small"}]}}],allOverflow:{label:"表内容超出",onlyType:"table",component:"radio-group",props:{options:[{label:"换行",value:"false"},{label:"省略号",value:"ellipsis"},{label:"省略号+title显示",value:"title"},{label:"省略号+tooltip显示",value:"tooltip"}]}},hoverRow:{onlyType:"table",label:"点击行高亮",component:"switch"},hoverColor:{onlyType:"table",label:"hover行颜色",component:"color-pick"},boderList:{label:"边框不显示",component:"select",onlyType:"table",props:{mode:"multiple",options:[{label:"表格上边框",value:"top"},{label:"表格下边框",value:"bottom"},{label:"表格左边框",value:"left"},{label:"表格右边框",value:"right"},{label:"表格内容边框",value:"middle"},{label:"列按钮边框",value:"button"}]}},columnDropEnable:{onlyType:"table",label:"列拖拽",component:"switch"},showTotalBool:{onlyType:"table",label:"显示汇总行",component:"switch"},totalName:{onlyType:"table",label:"汇总行名",component:"input"},expandAll:{onlyType:"table",label:"展开所有节点",component:"switch"},isUseSeq:{label:"使用序列",component:"switch"},centered:{label:"居中",component:"switch"},columnsFixedNum:{label:"左固定列数",component:"input-number",props:{min:0,step:1}},scrollX:{label:"滚动宽度",component:"input-number",props:{min:0,step:1}},variableColor:{label:"变量颜色",component:"color-pick"},mode:[{label:"类型",component:"select",onlyType:"border",props:{options:[{label:"无标题",value:"no-title"},{label:"上标题",value:"top-title"},{label:"左标题",value:"left-title"}]}},{label:"类型",component:"radio-group",onlyType:"tabs",props:{options:[{label:"线条",value:"line"},{label:"卡片",value:"card"}]}},{label:"类型",component:"select",onlyType:"button",props:{options:[{label:"默认",value:"default"},{label:"主要",value:"primary"},{label:"虚线",value:"dashed"},{label:"链接",value:"link"},{label:"文本",value:"text"}]}},{label:"模式",onlyType:"select",component:"radio-group",props:{options:[{label:"单选",value:""},{label:"多选",value:"multiple"}]}}],tabColor:{label:"字体颜色",component:"color-pick"},activeTabColor:{label:"激活颜色",component:"color-pick"},tabBackgroundImage:{label:"背景图",component:"image-pick"},activeTabBackgroundImage:{label:"激活背景图",component:"image-pick"},tabBarGutter:{label:"标签间隔",component:"input-number",props:{suffix:"px",min:0}},tabFontSize:{label:"字体大小",component:"input-number",props:{suffix:"px",min:12}},simple:{label:"简单分页",component:"switch"},pageSizeShow:{label:"每页条数",component:"switch"},sliceCount:{label:"截取条数",component:"input-number",props:{min:1}},useRanking:{label:"使用排行",component:"switch"},headerBackgroundColor:{label:"表头背景",component:"color-pick"},cellBackgroundColor:{label:"单元格背景",component:"color-pick"},borderColor:{label:"边框颜色",component:"color-pick"},useBorderModify:{label:"边框(四角)",component:"switch"},useTitle:{label:"使用标题",component:"switch"},paginationPosition:{label:"位置",component:"select",props:{options:[{label:"上左",value:"topLeft"},{label:"上中",value:"topCenter"},{label:"上右",value:"topRight"},{label:"下左",value:"bottomLeft"},{label:"下中",value:"bottomCenter"},{label:"下右",value:"bottomRight"}]}},paginationPageSize:{label:"分页数",component:"input-number"},destroyOnClose:{label:"关闭销毁",component:"switch"},position:[{label:"位置",onlyType:"modal",component:"select",props:{options:[{label:"默认",value:"default"},{label:"顶部",value:"top"},{label:"居中",value:"middle"},{label:"底部",value:"bottom"}]}}],yAxis:{label:"系列",component:"form-group",layout:"vertical",props:{max:2,format:[{label:["左轴","右轴"],type:"input",value:"axisLabelFormatter",props:{options:[{label:"柱状图",value:"bar"},{label:"折线图",value:"line"}]}}]}},seriesTypes:{label:"系列",component:"form-group",layout:"vertical",props:{format:[{label:"系列",type:"select",value:"type",useLabelIndex:!0,props:{options:[{label:"柱状图",value:"bar"},{label:"折线图",value:"line"}]}},{label:"对应轴",type:"select",value:"axisIndex",props:{options:[{label:"左轴",value:0},{label:"右轴",value:1}]}},{label:"提示框格式化",type:"input",value:"tooltipFormatter"}]}},startTime:{label:"开始时间值",component:"time-pick"},endTime:{label:"结束时间值",component:"time-pick"},limitStartTime:{label:"限制开始时间",component:"time-pick"},limitEndTime:{label:"限制结束时间",component:"time-pick"},strokeColor:{label:"完成颜色",component:"color-pick"},trailColor:{label:"未完成颜色",component:"color-pick"},strokeType:{label:"类型",component:"radio-group",props:{options:[{label:"环形",value:"circle"},{label:"仪表盘",value:"dashboard"},{label:"直线",value:"line"}]}},strokeLinecap:{label:"进度条样式",component:"radio-group",props:{options:[{label:"圆形",value:"round"},{label:"方角",value:"square"}]}},strokeWidth:{label:"进度条宽度",component:"input-number",props:{min:1}},strokeTextWidth:{label:"文本宽度",component:"input-number",props:{suffix:"%",min:20}},geoBackgroundImage:{label:"填充背景",component:"image-pick"},geoItemStyleAreaColor:{label:"板块颜色",component:"color-pick"},geoItemStyleBorderColor:{label:"边框颜色",component:"color-pick"},geoEmphasisLabelColor:{label:"字体颜色",component:"color-pick"},geoEmphasisItemStyleAreaColor:{label:"板块颜色",component:"color-pick"},geoEmphasisItemStyleBorderColor:{label:"边框颜色",component:"color-pick"},symbolImage:{label:"坐标点图标",component:"image-pick"},mapJson:{label:"上传数据",component:"file-pick"},barWidth:{label:"宽度",component:"input-number",props:{suffix:"%",min:0}},columnCount:{label:"并行数",component:"input-number",props:{min:0}},itemHeight:{label:"高度",component:"input-number",props:{suffix:"px",min:0}},itemColSpan:{label:"边距",component:"input-number",props:{suffix:"px",min:0}},itemPadding:{label:"内填充",component:"input-number",props:{suffix:"px",min:0}},itemRowSpan:{label:"行距",component:"input-number",props:{suffix:"px",min:0}},geoLabelColor:{label:"标签颜色",component:"color-pick"},geoLabelFontSize:{label:"标签大小",component:"input-number",props:{min:12,max:100}},geoItemStyleShadowColor:{label:"阴影颜色",component:"color-pick"},geoItemStyleBorderWidth:{label:"边框宽度",component:"input-number"},geoItemStyleShadowBlur:{label:"阴影模糊",component:"input-number"},geoItemStyleShadowOffsetX:{label:"阴影水平偏移",component:"input-number"},geoItemStyleShadowOffsetY:{label:"阴影垂直偏移",component:"input-number"},geoZoom:{label:"缩放大小",component:"input-number"},geoRoam:{label:"手动缩放",component:"switch"},geoCenter:{label:"中心位置",component:"input"},geoBackgroundImageRepeat:{label:"背景图片",component:"select",props:{options:[{label:"重复",value:"repeat"},{label:"水平重复",value:"repeat-x"},{label:"垂直重复",value:"repeat-y"},{label:"不重复",value:"no-repeat"}]}},titleColor:{label:"字体颜色",component:"color-pick"},titleFontSize:{label:"字体大小",component:"input-number",props:{suffix:"px",min:12,max:100}},headerFontSize:{label:"字体大小",component:"input-number",props:{suffix:"px",min:12,max:100}},geoEmphasisDisabled:{label:"禁用",component:"switch"},gridTop:{label:"上侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridBottom:{label:"下侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridLeft:{label:"左侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridRight:{label:"右侧距离",component:"input-number",props:{suffix:"%",min:0,max:100}},gridContainLabel:{label:"包含刻度标签",component:"switch"},geoLabelShow:{label:"展示文字",component:"switch"},toolboxOrient:{label:"排版",component:"radio-group",props:{options:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}]}},toolboxItemSize:{label:"图标大小",component:"input-number"},toolboxItemGap:{label:"图标间距",component:"input-number"},toolboxLeft:{label:"水平位置",component:"radio-group",props:{options:[{label:"居左",value:"left"},{label:"居中",value:"center"},{label:"居右",value:"right"}]}},toolboxTop:{label:"垂直位置",component:"radio-group",props:{options:[{label:"顶部",value:"top"},{label:"居中",value:"middle"},{label:"底部",value:"bottom"}]}},toolboxDownloadUrl:{label:"下载文件地址",component:"input"},toolboxInfoText:{label:"说明信息内容",component:"input"},shape:{label:"形状",component:"radio-group",props:{options:[{label:"默认",value:"default"},{label:"角圆",value:"round"},{label:"圆形",value:"circle"}]}},danger:{label:"危险模式",component:"switch"},href:{label:"链接",component:"textarea",show:[{match:"linkPage",value:""}]},target:{label:"链接方式",component:"radio-group",props:{options:[{label:"当前窗口",value:"self"},{label:"新窗口",value:"blank"},{label:"事件",value:"event"}]}},transParams:{label:"传递参数",component:"unit-config",layout:"vertical",props:{indexTip:`【参数名】是跳转链接上携带参数的key值;
67
+ 【参数值】是跳转链接上携带参数的value值。`,keyName:"参数名",fieldName:"参数值",layout:"vertical"}},borderWidth:{label:"边框宽度",component:"input-number",props:{suffix:"px"}},borderRadius:{label:"圆角",component:"input"},activeKey:{label:"激活标签页",component:"input-number"},isUseAction:{label:"使用操作列",component:"switch"},actionColumnWidth:{label:"操作列宽",component:"input-number"},actionList:{label:"操作列",component:"form-group",layout:"vertical",props:{format:[{label:"名称",value:"title",type:"input"},{label:"链接地址",value:"href",type:"input"},{label:"链接方式",value:"target",type:"select",props:{options:[{label:"本窗口",value:"self"},{label:"新窗口",value:"blank"},{label:"事件",value:"event"}]}},{label:"颜色",value:"color",type:"color"}]}},barBorderRadius:{label:"圆角",component:"input"},isUseHorizontalAxis:{label:"横向排列",component:"switch"},axisInverse:{label:"倒叙排列",component:"switch"},xAxisInverse:{label:"图形反转",component:"switch"},yAxisInverse:{label:"图形反转",component:"switch"},decimalFormat:{label:"保留小数",component:"switch"},variableDefaultValue:{label:"变量默认值",component:"input"},strokeTextShow:{label:"显示文本",component:"switch"},areaStyleOpacity:{label:"面积透明度",component:"input-number",props:{step:.1,min:0,max:1}},areaGradientShow:{label:"面积渐变",component:"switch"},areaGradientColor:{label:"渐变颜色",component:"color-pick"},tabHorizontalPadding:{label:"内水平边距",component:"input-number",props:{suffix:"px",min:0}},xAxisLabelWidth:{label:"名称宽度",component:"input-number",props:{min:0}},xAxisLabelOverflow:{label:"名称溢出",component:"radio-group",props:{optionType:"button",options:[{label:"无",value:"none"},{label:"换行",value:"break"},{label:"省略号",value:"truncate"}]}},xAxisLabelRotate:{label:"名称旋转",component:"input-number"},yAxisLabelWidth:{label:"名称宽度",component:"input-number",props:{min:0}},yAxisLabelOverflow:{label:"名称溢出",component:"radio-group",props:{optionType:"button",options:[{label:"无",value:"none"},{label:"换行",value:"break"},{label:"省略号",value:"truncate"}]}},yAxisLabelRotate:{label:"名称旋转",component:"input-number"},isStack:{label:"是否堆叠",component:"switch",effectVal(t,o,n,a){const{leftAxisList:l=[]}=a,r=o?l.map(s=>s.label):[];n({stackColumns:r})}},stackColumns:{label:"堆叠列配置",component:"select",props:{mode:"multiple",options:t=>{const{leftAxisList:o=[]}=t;return o.map(n=>({label:n.label,value:n.label}))}},effect:{hide:{props:[{props:"isStack",value:!1,rule:"==="}]}}},clickHighlight:{label:"点击高亮",component:"switch"},labelShow:{label:"展示标签",component:"switch"},isReverse:{label:"是否反转",component:"switch"},link:{label:"链接",component:"textarea"},linkType:{onlyType:"iframe",label:"链接类型",component:"radio-group",props:{options:[{label:"网页",value:"web"},{label:"报表工程",value:"erd"}]}},maxTagCount:{label:"显示最大数",component:"input-number"},tabAlignItems:{label:"垂直位置",component:"radio-group",props:{options:[{label:"上",value:"flex-start"},{label:"中",value:"center"},{label:"下",value:"flex-end"}]}},tabJustifyContent:{label:"水平位置",component:"radio-group",props:{options:[{label:"左",value:"flex-start"},{label:"中",value:"center"},{label:"右",value:"flex-end"}]}},tabFlexDirection:{label:"布局",component:"radio-group",props:{options:[{label:"水平",value:"row"},{label:"垂直",value:"column"}]}},filterDropdownHeight:{label:"过滤面板高度",component:"input-number",props:{suffix:"px",min:0}},stripedShow:{label:"斑马线条纹",component:"switch"},useCurrentTime:{label:"使用当前时间",component:"switch"},interval:{label:"时间间隔",component:"input-number",props:{min:0}},intervalUnit:{label:"时间间隔单位",component:"select",props:{options:[{label:"年",value:"year"},{label:"月",value:"month"},{label:"周",value:"week"},{label:"日",value:"day"},{label:"时",value:"hour"},{label:"分",value:"minute"}]}},operate:{label:"操作",component:"input-number",props:{min:0,prefixValueKey:"type",prefix:[{label:"加",value:"add"},{label:"减",value:"minus"}],suffixValueKey:"mode",suffix:[{label:"年",value:"year"},{label:"月",value:"month"},{label:"周",value:"week"},{label:"日",value:"day"},{label:"时",value:"hour"},{label:"分",value:"minute"}]}},updateInterval:{label:"更新间隔",component:"input-number",props:{min:1,suffixValueKey:"mode",suffix:[{label:"秒",value:"second"},{label:"分",value:"minute"},{label:"时",value:"hour"},{label:"天",value:"day"}]}},xAxisMinInterval:{label:"最小间距",component:"input-number",props:{min:0}},yAxisMinInterval:{label:"最小间距",component:"input-number",props:{min:0}},minAngle:{label:"最小角度",component:"input-number",props:{min:0,max:360}},autoSwitch:{label:"自动切换",component:"switch"},autoSwitchInterval:{label:"切换间隔",component:"input-number",props:{min:0}},xAxisLabelInterval:{label:"标签间隔",component:"input-number",props:{min:-1}},isUseExport:{label:"导出数据",component:"switch"},autoClearSearchValue:{label:"选中清空搜索",component:"switch"},toolboxLocation:{label:"快速定位",component:"switch"},toolboxDownloadShow:{label:"使用数据下载",component:"switch"},toolboxDataZoomShow:{label:"使用放大",component:"switch"},toolboxInfoShow:{label:"使用说明信息",component:"switch"},multiple:{label:"多选模式",component:"switch"},treeCheckable:{label:"复选框模式",component:"switch"},selectFirstOption:{label:"选择首选项",component:"switch"},gradientColor:{label:"渐变颜色",component:"color-pick"},gradientOffset:{label:"渐变度",component:"slider"},legendItemGap:{label:"图例项间隔",component:"input-number",props:{min:1}},legendItemWidth:{label:"图例图形宽度",component:"input-number",props:{min:1}},legendItemHeight:{label:"图例图形高度",component:"input-number",props:{min:1}},showBarBackground:{label:"背景色",component:"switch"},gradientColors:{label:"颜色",onlyType:"bar",component:"color-group-pick"},increaseColor:{label:"涨幅颜色 ",component:"color-pick"},declineColor:{label:"跌幅颜色",component:"color-pick"},legendType:{label:"图例类型 ",component:"select",props:{options:[{label:"默认",value:""},{label:"圆形",value:"circle"},{label:"矩形",value:"rect"},{label:"圆角矩形",value:"roundRect"},{label:"三角形",value:"triangle"},{label:"菱形",value:"diamond"},{label:"箭头",value:"arrow"}]}},optionType:{label:"单选类型",component:"select",props:{options:[{label:"默认",value:"default"},{label:"框组",value:"button"}]}},minusSignShow:{label:"涨跌幅负号",component:"switch"},gradientAngle:{label:"渐变角度",component:"input-number",props:{suffix:"deg"}},stripedColor:{label:"条纹颜色",component:"color-pick"},axisNameColor:{label:"名称颜色",component:"color-pick"},shadowColor:{label:"阴影颜色",component:"color-pick"},shadowBlur:{label:"阴影模糊度",component:"input-number",props:{min:0}},shadowOffsetX:{label:"阴影偏移(X)",component:"input-number",props:{min:0}},shadowOffsetY:{label:"阴影偏移(Y)",component:"input-number",props:{min:0}},borderStyle:{label:"边框线类型",component:"radio-group",props:{optionType:"button",options:[{label:"实线",value:"solid"},{label:"虚线",value:"dashed"},{label:"点状",value:"dotted"}]}},unitText:{label:"文本",component:"input"},unitFontSize:{label:"字号",component:"input-number",props:{suffix:"px",min:12,max:100}},unitFontWeight:{label:"字体粗细",component:"radio-group",props:{options:[{label:"细",value:100},{label:"正常",value:400},{label:"粗",value:700}],isTransformNumber:!0}},unitColor:{label:"颜色",component:"color-pick"},unitTop:{label:"上侧距离",component:"input-number",props:{suffix:"%"}},unitLeft:{label:"左侧距离",component:"input-number",props:{suffix:"%"}},legendFormatter:{label:"格式化",component:"textarea"},titleMode:{label:"标题背景",component:"select",props:{options:[{label:"类型一",value:"type-1"},{label:"类型二",value:"type-2"}]}},legendFontSize:{label:"字体大小",component:"input-number",props:{min:1,suffix:"px"}},valueType:{label:"传值类型",component:"select",props:{options:[{label:"值",value:"value"},{label:"名称",value:"label"}]}},isGroupTable:{label:"分组表格",component:"switch"},xAxisLabelFontSize:{label:"字体大小",component:"input-number",props:{min:1,suffix:"px"}},yAxisLabelFontSize:{label:"字体大小",component:"input-number",props:{min:1,suffix:"px"}},tooltipRequestData:{label:"配置请求",component:"tooltip-request"},tooltipBackgroundColor:{label:"背景颜色",component:"color-pick"},seqWidth:{label:"宽度",component:"input-number",props:{min:0,max:100,suffix:"%"}},isAllowClear:{label:"支持清除",component:"switch"},isSummaryFixed:{label:"固定小计行",component:"switch"},labelWidth:{label:"标签宽度",component:"input-number",props:{min:0}},labelOverflow:{label:"标签溢出",component:"radio-group",props:{optionType:"button",options:[{label:"无",value:"none"},{label:"换行",value:"break"},{label:"省略号",value:"truncate"}]}},isPageBottom:{label:"固定在底部",component:"switch"},optionFontSize:{label:"字体大小",component:"input-number",props:{min:12,suffix:"px"}},isShowTotal:{label:"显示总数",component:"switch"},graphicType:{label:"图表类型",component:"select",props:{options:[{label:"饼图",value:"ecanPie"},{label:"折线图",value:"ecanLine"},{label:"柱状图",value:"ecanBar"},{label:"散点图",value:"ecanScatter"},{label:"组合图表",value:"ecanComboGraph"},{label:"自定义图表",value:"ecanCustomGraph"},{label:"雷达图",value:"ecanRadar"}],graphic:!0}},isAllowSpanYear:{label:"允许跨年",component:"switch"},tabType:{label:"类型",component:"select",props:{options:[{label:"标签",value:"tabs"},{label:"下拉框",value:"select"}]}},targetRule:{label:"规则",component:"select",props:{options:[{label:"等于",value:"equal"},{label:"大于",value:"greater"},{label:"大于等于",value:"greater_equal"},{label:"小于",value:"less"},{label:"小于等于",value:"less_equal"}]}},targetValue:{label:"值",component:"input"},notExpectColor:{label:"颜色",component:"color-pick"},buttonBackgroundColor:{label:"背景色",component:"color-pick"},tabWidth:{label:"标签宽度",component:"input-number",props:{min:50,suffix:"px"}},headerFontColor:{label:"文字颜色",component:"color-pick"},cellFontColor:{label:"文字颜色",component:"color-pick"},isTransparent:{label:"透明色",component:"switch"},hideTableHeader:{label:"隐藏",component:"switch"},closeBtnColor:{label:"关闭按钮颜色",component:"color-pick"},paginationColor:{label:"页码颜色",component:"color-pick"},paginationBgColor:{label:"页码背景色",component:"color-pick"},activePaginationColor:{label:"当前页颜色",component:"color-pick"},activePaginationBgColor:{label:"当前页背景色",component:"color-pick"},hoverBackgroundColor:{label:"hover行颜色",component:"color-pick"},tooltipPosition:{label:"位置",component:"select",props:{options:[{label:"默认",value:""},{label:"左侧",value:"left"},{label:"右侧",value:"right"}]}},tabTextAlign:{label:"对齐方式",component:"radio-group",props:{options:[{label:"默认",value:""},{label:"居中",value:"center"}]}},seqName:{label:"名称",component:"input"},seqIcon:{label:"显示图标",component:"switch"},isShowCloseBtn:{label:"显示关闭按钮",component:"switch"},markLineType:{label:"标线类型",component:"select",props:{options:[{label:"平均值",value:"average"},{label:"最小值",value:"min"},{label:"最大值",value:"max"},{label:"中位数",value:"median"}]}},seqFontSize:{label:"字体大小",component:"input-number",props:{min:1,suffix:"px"}},isAutoScroll:{label:"循环滚动",component:"switch"},scrollSpeed:{label:"滚动速度",component:"input-number",props:{min:.1}},isHoverStyle:{label:"悬浮效果",component:"switch",show:[{match:"isAnimation",value:!1}]},isAnimation:{label:"JSON动画",component:"switch"},animationSource:{label:"资源文件",component:"zip-pick",style:"width: auto;",show:[{match:"isAnimation",value:!0}]},subTotalColumn:{label:"放置列",component:"select",props:{options:[],dynamics:!0}},subTotalName:{label:"名称",component:"input"},isSortByFront:{label:"是否前端排序",component:"switch"},legendWidth:{label:"区域宽度",component:"input-number"},legendHeight:{label:"区域高度",component:"input-number"},legendTextWidth:{label:"文字宽度",component:"input-number"},legendScroll:{label:"分页",component:"switch"},boxShadow:{label:"阴影",component:"textarea"},limitInterval:{label:"限制范围",component:"input-number",props:{min:0,suffixValueKey:"mode",suffix:[{label:"年",value:"year"},{label:"月",value:"month"},{label:"周",value:"week"},{label:"日",value:"day"},{label:"时",value:"hour"},{label:"分",value:"minute"}]}},xAxisName:{label:"坐标轴名称",component:"input"},yAxisName:{label:"坐标轴名称",component:"input"},yAxisLeftName:{label:"坐标轴名称-左轴",component:"input"},yAxisRightName:{label:"坐标轴名称-右轴",component:"input"},seqIconWidth:{label:"图标宽度",component:"input-number",props:{suffix:"px",min:0}},seqIconHeight:{label:"图标高度",component:"input-number",props:{suffix:"px",min:0}},seqIconOffsetX:{label:"横向偏移",component:"input-number",props:{suffix:"px"}},seqIconOffsetY:{label:"纵向偏移",component:"input-number",props:{suffix:"px"}},seqIndexFormatter:{label:"格式化",component:"textarea"},unitInterval:{label:"单位间隔",component:"input-number",props:{min:0}},keyFieldMap:{label:"数据配置",component:"unit-config",layout:"vertical",onlyType:"circulate",props:{indexTip:`【别名】是循环列表内部要循环的组件别名;
68
+ 【字段】是接口返回的数据字段;`,keyName:"别名",fieldName:"字段"}},itemWidth:{label:"宽度",component:"input-number",props:{suffix:"%",min:1,max:100}},startValue:{label:"开始值",component:"textarea"},endValue:{label:"结束值",component:"textarea"},colNum:{label:"列数量",component:"input-number"},digits:{label:"位数",component:"input-number",props:{min:0}},unitWidth:{label:"单位宽度",component:"input-number",props:{suffix:"px",min:10}},unitHeight:{label:"单位高度",component:"input-number",props:{suffix:"px",min:10}},counterBackgroundImage:{label:"背景图",component:"image-pick"},showEllipsis:{label:"超出省略号",component:"switch"},exceedConfig:{label:"内容超出时",component:"select",props:{options:[{label:"默认",value:""},{label:"换行",value:"wrap"},{label:"省略号",value:"ellipsis"}]}},xAxisMaxValue:{label:"最大值",component:"input-number",props:{min:0}},yAxisMaxValue:{label:"最大值",component:"input-number",props:{min:0}},scrollDirection:{label:"滚动方向",component:"radio-group",props:{options:[{label:"竖直",value:"vertical"},{label:"水平",value:"horizontal"}]}},hideTabs:{label:"隐藏标签",component:"switch"},jumpType:{label:"跳转类型",component:"select",updateMode:"page",onlyType:"page",props:{options:[{label:"当前项目页面",value:"page"},{label:"外部链接页面",value:"link"}]}},jumpTime:{label:"定时",component:"input-number",updateMode:"page",onlyType:"page",props:{min:0,suffix:[{label:"时",value:"hours"},{label:"分",value:"minute"},{label:"秒",value:"seconds"}]}},jumpPage:{label:"项目页面",component:"page-pick",updateMode:"page",onlyType:"page",show:[{match:"jumpType",value:"page"}]},jumpLink:{label:"链接",component:"textarea",updateMode:"page",onlyType:"page",show:[{match:"jumpType",value:"link"}]},gridTopPx:{label:"上侧距离",component:"input-number",props:{suffix:"px",min:0}},gridBottomPx:{label:"下侧距离",component:"input-number",props:{suffix:"px",min:0}},gridLeftPx:{label:"左侧距离",component:"input-number",props:{suffix:"px",min:0}},gridRightPx:{label:"右侧距离",component:"input-number",props:{suffix:"px",min:0}},showAnimation:{label:"动画",component:"switch",style:"width: auto;",props:{tooltip:"文本组件的值会以动画的形式发生变化(只有值为数字类型的时候才生效)"}},showXAxisLineArrow:{label:"显示箭头",component:"switch"},showYAxisLineArrow:{label:"显示箭头",component:"switch"},xAxisLineInverse:{label:"倒序",component:"switch"},yAxisLineInverse:{label:"倒序",component:"switch"},xAxisMarkLineValue:{label:"x轴标线",component:"mark-link-config",layout:"vertical",onlyType:"scatter",props:{indexTip:`【值】代表标线在x轴上的刻度。固定的值直接输入数字;动态的值可以输入表达式,系统提供了两个变量:max和min,
69
+ max表示x轴刻度最大值,min表示x轴刻度最小值。使用变量的时候需要用“{}”符号包裹变量,例如添加一根位于x轴正中间的标线可以这么写:({max} + {min}) / 2`}},yAxisMarkLineValue:{label:"y轴标线",component:"mark-link-config",layout:"vertical",onlyType:"scatter",props:{indexTip:`【值】代表标线在y轴上的刻度。固定的值直接输入数字;动态的值可以输入表达式,系统提供了两个变量:max和min,
70
+ max表示y轴刻度最大值,min表示y轴刻度最小值。使用变量的时候需要用“{}”符号包裹变量,例如添加一根位于y轴正中间的标线可以这么写:({max} + {min}) / 2`}},axisMarkArea:{label:"标域设置",component:"mark-area-config",layout:"vertical",onlyType:"scatter",props:{indexTip:`每个标域需要配置两个坐标点才能确定区域,所以需要填写两个坐标的x和y的值,即(x1, y1)、(x2, y2),这两个点需要配置为区域的对角两个点才能
71
+ 正确的标出区域。如果不设置标域颜色将会使用图表默认颜色。系统提供四个变量:xMax、xMin、yMax、yMin,xMax表示x轴刻度最大值,xMin表示x轴刻度最小值,
72
+ yMax表示y轴刻度最大值,yMin表示y轴刻度最小值。使用变量的时候需要用“{}”符号包裹变量`}}},uf=e.defineComponent({name:"Input",directives:{focus},props:{value:{type:String,default:""},disabled:{type:Boolean,default:!1}},components:{AInput:j.Input},emits:["change"],setup(t,{emit:o}){return{onInputChange:a=>{o("change",a.target.value)}}}});function ff(t,o,n,a,l,r){const s=e.resolveComponent("a-input"),d=e.resolveDirective("focus");return e.withDirectives((e.openBlock(),e.createBlock(s,{value:t.value,disabled:t.disabled,onChange:t.onInputChange},null,8,["value","disabled","onChange"])),[[d]])}const mf=oe(uf,[["render",ff]]),hf=e.defineComponent({name:"InputNumber",props:{value:{type:[String,Number,Object],default:""},valueKey:{type:String,default:"value"},prefixValueKey:{type:String,default:"prefix"},prefix:{type:[String,Array],default:""},suffixValueKey:{type:String,default:"suffix"},suffix:{type:[String,Array],default:""},min:{type:Number,default:-1/0},max:{type:Number,default:1/0},step:{type:[String,Number],default:1},useBlurEvent:{type:Boolean,default:!0}},components:{AInputNumber:j.InputNumber,ASelect:j.Select,ASelectOption:j.SelectOption},emits:["change"],setup(t,{emit:o}){const n=e.computed(()=>{const u=t.value;return typeof u=="string"?parseFloat(u):typeof u=="object"&&u!=null?u[t.valueKey]:u}),a=u=>t.value!=null&&typeof t.value=="object"?t.value[t[`${u}ValueKey`]]:Array.isArray(t[u])?t[u][0]&&t[u][0].value:null,l=e.ref(a("prefix")),r=e.ref(a("suffix"));return{inputValue:n,onInputChange:u=>{const f=t.suffix;Array.isArray(t.prefix)||Array.isArray(t.suffix)?o("change",{[t.valueKey]:u,[t.prefixValueKey]:e.unref(l),[t.suffixValueKey]:e.unref(r)}):f===""||u==null?o("change",u):o("change",`${u}${f}`)},parser:u=>typeof t.suffix=="string"?u.replace(t.suffix,""):Array.isArray(t.suffix)&&t.value!=null&&typeof t.value=="object"?u.replace(t.value[t.suffixValueKey],""):u,onInputBlur:()=>{t.useBlurEvent&&o("change",null,!1)},prefixValue:l,suffixValue:r,onPrefixChange:()=>{Array.isArray(t.prefix)&&o("change",{[t.valueKey]:e.unref(n),[t.prefixValueKey]:e.unref(l),[t.suffixValueKey]:e.unref(r)})},onSuffixChange:()=>{Array.isArray(t.suffix)&&o("change",{[t.valueKey]:e.unref(n),[t.prefixValueKey]:e.unref(l),[t.suffixValueKey]:e.unref(r)})}}}});function bf(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-input-number");return e.openBlock(),e.createBlock(i,{value:t.inputValue,min:t.min,max:t.max,step:t.step,parser:t.parser,"addon-before":Array.isArray(t.prefix)?void 0:t.prefix,"addon-after":Array.isArray(t.suffix)?void 0:t.prefix,onChange:t.onInputChange,onBlur:t.onInputBlur},e.createSlots({_:2},[Array.isArray(t.prefix)&&t.prefix.length>0?{name:"addonBefore",fn:e.withCtx(()=>[e.createVNode(d,{value:t.prefixValue,"onUpdate:value":o[0]||(o[0]=c=>t.prefixValue=c),onChange:t.onPrefixChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.prefix,({label:c,value:p},u)=>(e.openBlock(),e.createBlock(s,{key:u,value:p},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(c),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])]),key:"0"}:void 0,Array.isArray(t.suffix)&&t.suffix.length>0?{name:"addonAfter",fn:e.withCtx(()=>[e.createVNode(d,{value:t.suffixValue,"onUpdate:value":o[1]||(o[1]=c=>t.suffixValue=c),onChange:t.onSuffixChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.suffix,({label:c,value:p},u)=>(e.openBlock(),e.createBlock(s,{key:u,value:p},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(c),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])]),key:"1"}:void 0]),1032,["value","min","max","step","parser","addon-before","addon-after","onChange","onBlur"])}const nr=oe(hf,[["render",bf]]),yf=e.defineComponent({name:"RadioGroup",props:{value:{type:[String,Number],default:""},options:{type:Array,default:()=>[]},optionType:{type:String,default:"default"},size:{type:String,default:"default"}},components:{ARadioGroup:j.RadioGroup,ARadioButton:j.RadioButton},emits:["change"],setup(t,{emit:o}){return{onRadioChange:a=>{o("change",a.target.value)}}}});function gf(t,o,n,a,l,r){const s=e.resolveComponent("a-radio-button"),d=e.resolveComponent("a-radio-group");return e.openBlock(),e.createBlock(d,{value:t.value,optionType:t.optionType,onChange:t.onRadioChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,i=>(e.openBlock(),e.createBlock(s,{key:i.value,value:i.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","optionType","onChange"])}const Cf=oe(yf,[["render",gf]]),wf=e.defineComponent({name:"Select",props:{value:{type:[String,Number,Array,Array],default:""},options:{type:Array,default:()=>[]},customOption:{type:Function}},components:{ASelect:j.Select,ASelectOption:j.SelectOption},emits:["change"],setup(t,{emit:o}){return{onSelectChange:a=>{o("change",a)}}}});function kf(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select");return e.openBlock(),e.createBlock(d,{value:t.value,onChange:t.onSelectChange},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,i=>(e.openBlock(),e.createBlock(s,{key:i.value,value:i.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["value","onChange"])}const xf=oe(wf,[["render",kf]]),_f=e.defineComponent({name:"Switch",props:{value:{type:Boolean,default:!1},width:{type:[String,Number],default:150},disabled:{type:Boolean,default:!1}},components:{ASwitch:j.Switch},emit:["change"],setup(t,{emit:o}){return{onSwitchChange:a=>{o("change",a)}}}});function Sf(t,o,n,a,l,r){const s=e.resolveComponent("a-switch");return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({width:`${t.width}px`})},[e.createVNode(s,{disabled:t.disabled,checked:t.value,onChange:t.onSwitchChange},null,8,["disabled","checked","onChange"])],4)}const Nf=oe(_f,[["render",Sf]]);var Te="top",Me="bottom",Pe="right",Ae="left",Hn="auto",ao=[Te,Me,Pe,Ae],Pt="start",lo="end",Tf="clippingParents",ar="viewport",ro="popper",Af="reference",lr=ao.reduce(function(t,o){return t.concat([o+"-"+Pt,o+"-"+lo])},[]),rr=[].concat(ao,[Hn]).reduce(function(t,o){return t.concat([o,o+"-"+Pt,o+"-"+lo])},[]),Of="beforeRead",Ef="read",Bf="afterRead",Vf="beforeMain",Lf="main",vf="afterMain",$f="beforeWrite",Ff="write",If="afterWrite",Df=[Of,Ef,Bf,Vf,Lf,vf,$f,Ff,If];function Ye(t){return t?(t.nodeName||"").toLowerCase():null}function ve(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var o=t.ownerDocument;return o&&o.defaultView||window}return t}function wt(t){var o=ve(t).Element;return t instanceof o||t instanceof Element}function je(t){var o=ve(t).HTMLElement;return t instanceof o||t instanceof HTMLElement}function Wn(t){if(typeof ShadowRoot>"u")return!1;var o=ve(t).ShadowRoot;return t instanceof o||t instanceof ShadowRoot}function Mf(t){var o=t.state;Object.keys(o.elements).forEach(function(n){var a=o.styles[n]||{},l=o.attributes[n]||{},r=o.elements[n];!je(r)||!Ye(r)||(Object.assign(r.style,a),Object.keys(l).forEach(function(s){var d=l[s];d===!1?r.removeAttribute(s):r.setAttribute(s,d===!0?"":d)}))})}function Pf(t){var o=t.state,n={popper:{position:o.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(o.elements.popper.style,n.popper),o.styles=n,o.elements.arrow&&Object.assign(o.elements.arrow.style,n.arrow),function(){Object.keys(o.elements).forEach(function(a){var l=o.elements[a],r=o.attributes[a]||{},s=Object.keys(o.styles.hasOwnProperty(a)?o.styles[a]:n[a]),d=s.reduce(function(i,c){return i[c]="",i},{});!je(l)||!Ye(l)||(Object.assign(l.style,d),Object.keys(r).forEach(function(i){l.removeAttribute(i)}))})}}const jf={name:"applyStyles",enabled:!0,phase:"write",fn:Mf,effect:Pf,requires:["computeStyles"]};function qe(t){return t.split("-")[0]}var kt=Math.max,Vo=Math.min,jt=Math.round;function Yn(){var t=navigator.userAgentData;return t!=null&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(o){return o.brand+"/"+o.version}).join(" "):navigator.userAgent}function ir(){return!/^((?!chrome|android).)*safari/i.test(Yn())}function Rt(t,o,n){o===void 0&&(o=!1),n===void 0&&(n=!1);var a=t.getBoundingClientRect(),l=1,r=1;o&&je(t)&&(l=t.offsetWidth>0&&jt(a.width)/t.offsetWidth||1,r=t.offsetHeight>0&&jt(a.height)/t.offsetHeight||1);var s=wt(t)?ve(t):window,d=s.visualViewport,i=!ir()&&n,c=(a.left+(i&&d?d.offsetLeft:0))/l,p=(a.top+(i&&d?d.offsetTop:0))/r,u=a.width/l,f=a.height/r;return{width:u,height:f,top:p,right:c+u,bottom:p+f,left:c,x:c,y:p}}function qn(t){var o=Rt(t),n=t.offsetWidth,a=t.offsetHeight;return Math.abs(o.width-n)<=1&&(n=o.width),Math.abs(o.height-a)<=1&&(a=o.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:a}}function sr(t,o){var n=o.getRootNode&&o.getRootNode();if(t.contains(o))return!0;if(n&&Wn(n)){var a=o;do{if(a&&t.isSameNode(a))return!0;a=a.parentNode||a.host}while(a)}return!1}function Ze(t){return ve(t).getComputedStyle(t)}function Rf(t){return["table","td","th"].indexOf(Ye(t))>=0}function pt(t){return((wt(t)?t.ownerDocument:t.document)||window.document).documentElement}function Lo(t){return Ye(t)==="html"?t:t.assignedSlot||t.parentNode||(Wn(t)?t.host:null)||pt(t)}function cr(t){return!je(t)||Ze(t).position==="fixed"?null:t.offsetParent}function Uf(t){var o=/firefox/i.test(Yn()),n=/Trident/i.test(Yn());if(n&&je(t)){var a=Ze(t);if(a.position==="fixed")return null}var l=Lo(t);for(Wn(l)&&(l=l.host);je(l)&&["html","body"].indexOf(Ye(l))<0;){var r=Ze(l);if(r.transform!=="none"||r.perspective!=="none"||r.contain==="paint"||["transform","perspective"].indexOf(r.willChange)!==-1||o&&r.willChange==="filter"||o&&r.filter&&r.filter!=="none")return l;l=l.parentNode}return null}function io(t){for(var o=ve(t),n=cr(t);n&&Rf(n)&&Ze(n).position==="static";)n=cr(n);return n&&(Ye(n)==="html"||Ye(n)==="body"&&Ze(n).position==="static")?o:n||Uf(t)||o}function Kn(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function so(t,o,n){return kt(t,Vo(o,n))}function zf(t,o,n){var a=so(t,o,n);return a>n?n:a}function dr(){return{top:0,right:0,bottom:0,left:0}}function pr(t){return Object.assign({},dr(),t)}function ur(t,o){return o.reduce(function(n,a){return n[a]=t,n},{})}var Gf=function(o,n){return o=typeof o=="function"?o(Object.assign({},n.rects,{placement:n.placement})):o,pr(typeof o!="number"?o:ur(o,ao))};function Hf(t){var o,n=t.state,a=t.name,l=t.options,r=n.elements.arrow,s=n.modifiersData.popperOffsets,d=qe(n.placement),i=Kn(d),c=[Ae,Pe].indexOf(d)>=0,p=c?"height":"width";if(!(!r||!s)){var u=Gf(l.padding,n),f=qn(r),y=i==="y"?Te:Ae,h=i==="y"?Me:Pe,b=n.rects.reference[p]+n.rects.reference[i]-s[i]-n.rects.popper[p],m=s[i]-n.rects.reference[i],w=io(r),g=w?i==="y"?w.clientHeight||0:w.clientWidth||0:0,S=b/2-m/2,C=u[y],k=g-f[p]-u[h],_=g/2-f[p]/2+S,E=so(C,_,k),O=i;n.modifiersData[a]=(o={},o[O]=E,o.centerOffset=E-_,o)}}function Wf(t){var o=t.state,n=t.options,a=n.element,l=a===void 0?"[data-popper-arrow]":a;l!=null&&(typeof l=="string"&&(l=o.elements.popper.querySelector(l),!l)||sr(o.elements.popper,l)&&(o.elements.arrow=l))}const Yf={name:"arrow",enabled:!0,phase:"main",fn:Hf,effect:Wf,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Ut(t){return t.split("-")[1]}var qf={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Kf(t,o){var n=t.x,a=t.y,l=o.devicePixelRatio||1;return{x:jt(n*l)/l||0,y:jt(a*l)/l||0}}function fr(t){var o,n=t.popper,a=t.popperRect,l=t.placement,r=t.variation,s=t.offsets,d=t.position,i=t.gpuAcceleration,c=t.adaptive,p=t.roundOffsets,u=t.isFixed,f=s.x,y=f===void 0?0:f,h=s.y,b=h===void 0?0:h,m=typeof p=="function"?p({x:y,y:b}):{x:y,y:b};y=m.x,b=m.y;var w=s.hasOwnProperty("x"),g=s.hasOwnProperty("y"),S=Ae,C=Te,k=window;if(c){var _=io(n),E="clientHeight",O="clientWidth";if(_===ve(n)&&(_=pt(n),Ze(_).position!=="static"&&d==="absolute"&&(E="scrollHeight",O="scrollWidth")),_=_,l===Te||(l===Ae||l===Pe)&&r===lo){C=Me;var B=u&&_===k&&k.visualViewport?k.visualViewport.height:_[E];b-=B-a.height,b*=i?1:-1}if(l===Ae||(l===Te||l===Me)&&r===lo){S=Pe;var L=u&&_===k&&k.visualViewport?k.visualViewport.width:_[O];y-=L-a.width,y*=i?1:-1}}var D=Object.assign({position:d},c&&qf),I=p===!0?Kf({x:y,y:b},ve(n)):{x:y,y:b};if(y=I.x,b=I.y,i){var $;return Object.assign({},D,($={},$[C]=g?"0":"",$[S]=w?"0":"",$.transform=(k.devicePixelRatio||1)<=1?"translate("+y+"px, "+b+"px)":"translate3d("+y+"px, "+b+"px, 0)",$))}return Object.assign({},D,(o={},o[C]=g?b+"px":"",o[S]=w?y+"px":"",o.transform="",o))}function Xf(t){var o=t.state,n=t.options,a=n.gpuAcceleration,l=a===void 0?!0:a,r=n.adaptive,s=r===void 0?!0:r,d=n.roundOffsets,i=d===void 0?!0:d,c={placement:qe(o.placement),variation:Ut(o.placement),popper:o.elements.popper,popperRect:o.rects.popper,gpuAcceleration:l,isFixed:o.options.strategy==="fixed"};o.modifiersData.popperOffsets!=null&&(o.styles.popper=Object.assign({},o.styles.popper,fr(Object.assign({},c,{offsets:o.modifiersData.popperOffsets,position:o.options.strategy,adaptive:s,roundOffsets:i})))),o.modifiersData.arrow!=null&&(o.styles.arrow=Object.assign({},o.styles.arrow,fr(Object.assign({},c,{offsets:o.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:i})))),o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-placement":o.placement})}const Qf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Xf,data:{}};var vo={passive:!0};function Jf(t){var o=t.state,n=t.instance,a=t.options,l=a.scroll,r=l===void 0?!0:l,s=a.resize,d=s===void 0?!0:s,i=ve(o.elements.popper),c=[].concat(o.scrollParents.reference,o.scrollParents.popper);return r&&c.forEach(function(p){p.addEventListener("scroll",n.update,vo)}),d&&i.addEventListener("resize",n.update,vo),function(){r&&c.forEach(function(p){p.removeEventListener("scroll",n.update,vo)}),d&&i.removeEventListener("resize",n.update,vo)}}const Zf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Jf,data:{}};var em={left:"right",right:"left",bottom:"top",top:"bottom"};function $o(t){return t.replace(/left|right|bottom|top/g,function(o){return em[o]})}var tm={start:"end",end:"start"};function mr(t){return t.replace(/start|end/g,function(o){return tm[o]})}function Xn(t){var o=ve(t),n=o.pageXOffset,a=o.pageYOffset;return{scrollLeft:n,scrollTop:a}}function Qn(t){return Rt(pt(t)).left+Xn(t).scrollLeft}function om(t,o){var n=ve(t),a=pt(t),l=n.visualViewport,r=a.clientWidth,s=a.clientHeight,d=0,i=0;if(l){r=l.width,s=l.height;var c=ir();(c||!c&&o==="fixed")&&(d=l.offsetLeft,i=l.offsetTop)}return{width:r,height:s,x:d+Qn(t),y:i}}function nm(t){var o,n=pt(t),a=Xn(t),l=(o=t.ownerDocument)==null?void 0:o.body,r=kt(n.scrollWidth,n.clientWidth,l?l.scrollWidth:0,l?l.clientWidth:0),s=kt(n.scrollHeight,n.clientHeight,l?l.scrollHeight:0,l?l.clientHeight:0),d=-a.scrollLeft+Qn(t),i=-a.scrollTop;return Ze(l||n).direction==="rtl"&&(d+=kt(n.clientWidth,l?l.clientWidth:0)-r),{width:r,height:s,x:d,y:i}}function Jn(t){var o=Ze(t),n=o.overflow,a=o.overflowX,l=o.overflowY;return/auto|scroll|overlay|hidden/.test(n+l+a)}function hr(t){return["html","body","#document"].indexOf(Ye(t))>=0?t.ownerDocument.body:je(t)&&Jn(t)?t:hr(Lo(t))}function co(t,o){var n;o===void 0&&(o=[]);var a=hr(t),l=a===((n=t.ownerDocument)==null?void 0:n.body),r=ve(a),s=l?[r].concat(r.visualViewport||[],Jn(a)?a:[]):a,d=o.concat(s);return l?d:d.concat(co(Lo(s)))}function Zn(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function am(t,o){var n=Rt(t,!1,o==="fixed");return n.top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n}function br(t,o,n){return o===ar?Zn(om(t,n)):wt(o)?am(o,n):Zn(nm(pt(t)))}function lm(t){var o=co(Lo(t)),n=["absolute","fixed"].indexOf(Ze(t).position)>=0,a=n&&je(t)?io(t):t;return wt(a)?o.filter(function(l){return wt(l)&&sr(l,a)&&Ye(l)!=="body"}):[]}function rm(t,o,n,a){var l=o==="clippingParents"?lm(t):[].concat(o),r=[].concat(l,[n]),s=r[0],d=r.reduce(function(i,c){var p=br(t,c,a);return i.top=kt(p.top,i.top),i.right=Vo(p.right,i.right),i.bottom=Vo(p.bottom,i.bottom),i.left=kt(p.left,i.left),i},br(t,s,a));return d.width=d.right-d.left,d.height=d.bottom-d.top,d.x=d.left,d.y=d.top,d}function yr(t){var o=t.reference,n=t.element,a=t.placement,l=a?qe(a):null,r=a?Ut(a):null,s=o.x+o.width/2-n.width/2,d=o.y+o.height/2-n.height/2,i;switch(l){case Te:i={x:s,y:o.y-n.height};break;case Me:i={x:s,y:o.y+o.height};break;case Pe:i={x:o.x+o.width,y:d};break;case Ae:i={x:o.x-n.width,y:d};break;default:i={x:o.x,y:o.y}}var c=l?Kn(l):null;if(c!=null){var p=c==="y"?"height":"width";switch(r){case Pt:i[c]=i[c]-(o[p]/2-n[p]/2);break;case lo:i[c]=i[c]+(o[p]/2-n[p]/2);break}}return i}function po(t,o){o===void 0&&(o={});var n=o,a=n.placement,l=a===void 0?t.placement:a,r=n.strategy,s=r===void 0?t.strategy:r,d=n.boundary,i=d===void 0?Tf:d,c=n.rootBoundary,p=c===void 0?ar:c,u=n.elementContext,f=u===void 0?ro:u,y=n.altBoundary,h=y===void 0?!1:y,b=n.padding,m=b===void 0?0:b,w=pr(typeof m!="number"?m:ur(m,ao)),g=f===ro?Af:ro,S=t.rects.popper,C=t.elements[h?g:f],k=rm(wt(C)?C:C.contextElement||pt(t.elements.popper),i,p,s),_=Rt(t.elements.reference),E=yr({reference:_,element:S,strategy:"absolute",placement:l}),O=Zn(Object.assign({},S,E)),B=f===ro?O:_,L={top:k.top-B.top+w.top,bottom:B.bottom-k.bottom+w.bottom,left:k.left-B.left+w.left,right:B.right-k.right+w.right},D=t.modifiersData.offset;if(f===ro&&D){var I=D[l];Object.keys(L).forEach(function($){var x=[Pe,Me].indexOf($)>=0?1:-1,V=[Te,Me].indexOf($)>=0?"y":"x";L[$]+=I[V]*x})}return L}function im(t,o){o===void 0&&(o={});var n=o,a=n.placement,l=n.boundary,r=n.rootBoundary,s=n.padding,d=n.flipVariations,i=n.allowedAutoPlacements,c=i===void 0?rr:i,p=Ut(a),u=p?d?lr:lr.filter(function(h){return Ut(h)===p}):ao,f=u.filter(function(h){return c.indexOf(h)>=0});f.length===0&&(f=u);var y=f.reduce(function(h,b){return h[b]=po(t,{placement:b,boundary:l,rootBoundary:r,padding:s})[qe(b)],h},{});return Object.keys(y).sort(function(h,b){return y[h]-y[b]})}function sm(t){if(qe(t)===Hn)return[];var o=$o(t);return[mr(t),o,mr(o)]}function cm(t){var o=t.state,n=t.options,a=t.name;if(!o.modifiersData[a]._skip){for(var l=n.mainAxis,r=l===void 0?!0:l,s=n.altAxis,d=s===void 0?!0:s,i=n.fallbackPlacements,c=n.padding,p=n.boundary,u=n.rootBoundary,f=n.altBoundary,y=n.flipVariations,h=y===void 0?!0:y,b=n.allowedAutoPlacements,m=o.options.placement,w=qe(m),g=w===m,S=i||(g||!h?[$o(m)]:sm(m)),C=[m].concat(S).reduce(function(G,W){return G.concat(qe(W)===Hn?im(o,{placement:W,boundary:p,rootBoundary:u,padding:c,flipVariations:h,allowedAutoPlacements:b}):W)},[]),k=o.rects.reference,_=o.rects.popper,E=new Map,O=!0,B=C[0],L=0;L<C.length;L++){var D=C[L],I=qe(D),$=Ut(D)===Pt,x=[Te,Me].indexOf(I)>=0,V=x?"width":"height",T=po(o,{placement:D,boundary:p,rootBoundary:u,altBoundary:f,padding:c}),P=x?$?Pe:Ae:$?Me:Te;k[V]>_[V]&&(P=$o(P));var R=$o(P),N=[];if(r&&N.push(T[I]<=0),d&&N.push(T[P]<=0,T[R]<=0),N.every(function(G){return G})){B=D,O=!1;break}E.set(D,N)}if(O)for(var v=h?3:1,A=function(W){var X=C.find(function(Q){var Z=E.get(Q);if(Z)return Z.slice(0,W).every(function(ae){return ae})});if(X)return B=X,"break"},F=v;F>0;F--){var M=A(F);if(M==="break")break}o.placement!==B&&(o.modifiersData[a]._skip=!0,o.placement=B,o.reset=!0)}}const dm={name:"flip",enabled:!0,phase:"main",fn:cm,requiresIfExists:["offset"],data:{_skip:!1}};function gr(t,o,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-o.height-n.y,right:t.right-o.width+n.x,bottom:t.bottom-o.height+n.y,left:t.left-o.width-n.x}}function Cr(t){return[Te,Pe,Me,Ae].some(function(o){return t[o]>=0})}function pm(t){var o=t.state,n=t.name,a=o.rects.reference,l=o.rects.popper,r=o.modifiersData.preventOverflow,s=po(o,{elementContext:"reference"}),d=po(o,{altBoundary:!0}),i=gr(s,a),c=gr(d,l,r),p=Cr(i),u=Cr(c);o.modifiersData[n]={referenceClippingOffsets:i,popperEscapeOffsets:c,isReferenceHidden:p,hasPopperEscaped:u},o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-reference-hidden":p,"data-popper-escaped":u})}const um={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:pm};function fm(t,o,n){var a=qe(t),l=[Ae,Te].indexOf(a)>=0?-1:1,r=typeof n=="function"?n(Object.assign({},o,{placement:t})):n,s=r[0],d=r[1];return s=s||0,d=(d||0)*l,[Ae,Pe].indexOf(a)>=0?{x:d,y:s}:{x:s,y:d}}function mm(t){var o=t.state,n=t.options,a=t.name,l=n.offset,r=l===void 0?[0,0]:l,s=rr.reduce(function(p,u){return p[u]=fm(u,o.rects,r),p},{}),d=s[o.placement],i=d.x,c=d.y;o.modifiersData.popperOffsets!=null&&(o.modifiersData.popperOffsets.x+=i,o.modifiersData.popperOffsets.y+=c),o.modifiersData[a]=s}const hm={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:mm};function bm(t){var o=t.state,n=t.name;o.modifiersData[n]=yr({reference:o.rects.reference,element:o.rects.popper,strategy:"absolute",placement:o.placement})}const ym={name:"popperOffsets",enabled:!0,phase:"read",fn:bm,data:{}};function gm(t){return t==="x"?"y":"x"}function Cm(t){var o=t.state,n=t.options,a=t.name,l=n.mainAxis,r=l===void 0?!0:l,s=n.altAxis,d=s===void 0?!1:s,i=n.boundary,c=n.rootBoundary,p=n.altBoundary,u=n.padding,f=n.tether,y=f===void 0?!0:f,h=n.tetherOffset,b=h===void 0?0:h,m=po(o,{boundary:i,rootBoundary:c,padding:u,altBoundary:p}),w=qe(o.placement),g=Ut(o.placement),S=!g,C=Kn(w),k=gm(C),_=o.modifiersData.popperOffsets,E=o.rects.reference,O=o.rects.popper,B=typeof b=="function"?b(Object.assign({},o.rects,{placement:o.placement})):b,L=typeof B=="number"?{mainAxis:B,altAxis:B}:Object.assign({mainAxis:0,altAxis:0},B),D=o.modifiersData.offset?o.modifiersData.offset[o.placement]:null,I={x:0,y:0};if(_){if(r){var $,x=C==="y"?Te:Ae,V=C==="y"?Me:Pe,T=C==="y"?"height":"width",P=_[C],R=P+m[x],N=P-m[V],v=y?-O[T]/2:0,A=g===Pt?E[T]:O[T],F=g===Pt?-O[T]:-E[T],M=o.elements.arrow,G=y&&M?qn(M):{width:0,height:0},W=o.modifiersData["arrow#persistent"]?o.modifiersData["arrow#persistent"].padding:dr(),X=W[x],Q=W[V],Z=so(0,E[T],G[T]),ae=S?E[T]/2-v-Z-X-L.mainAxis:A-Z-X-L.mainAxis,le=S?-E[T]/2+v+Z+Q+L.mainAxis:F+Z+Q+L.mainAxis,_e=o.elements.arrow&&io(o.elements.arrow),St=_e?C==="y"?_e.clientTop||0:_e.clientLeft||0:0,Xe=($=D==null?void 0:D[C])!=null?$:0,pe=P+ae-Xe-St,Oe=P+le-Xe,ut=so(y?Vo(R,pe):R,P,y?kt(N,Oe):N);_[C]=ut,I[C]=ut-P}if(d){var ho,Ht=C==="x"?Te:Ae,Nt=C==="x"?Me:Pe,$e=_[k],tt=k==="y"?"height":"width",ot=$e+m[Ht],nt=$e-m[Nt],Fe=[Te,Ae].indexOf(w)!==-1,Tt=(ho=D==null?void 0:D[k])!=null?ho:0,at=Fe?ot:$e-E[tt]-O[tt]-Tt+L.altAxis,ft=Fe?$e+E[tt]+O[tt]-Tt-L.altAxis:nt,At=y&&Fe?zf(at,$e,ft):so(y?at:ot,$e,y?ft:nt);_[k]=At,I[k]=At-$e}o.modifiersData[a]=I}}const wm={name:"preventOverflow",enabled:!0,phase:"main",fn:Cm,requiresIfExists:["offset"]};function km(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function xm(t){return t===ve(t)||!je(t)?Xn(t):km(t)}function _m(t){var o=t.getBoundingClientRect(),n=jt(o.width)/t.offsetWidth||1,a=jt(o.height)/t.offsetHeight||1;return n!==1||a!==1}function Sm(t,o,n){n===void 0&&(n=!1);var a=je(o),l=je(o)&&_m(o),r=pt(o),s=Rt(t,l,n),d={scrollLeft:0,scrollTop:0},i={x:0,y:0};return(a||!a&&!n)&&((Ye(o)!=="body"||Jn(r))&&(d=xm(o)),je(o)?(i=Rt(o,!0),i.x+=o.clientLeft,i.y+=o.clientTop):r&&(i.x=Qn(r))),{x:s.left+d.scrollLeft-i.x,y:s.top+d.scrollTop-i.y,width:s.width,height:s.height}}function Nm(t){var o=new Map,n=new Set,a=[];t.forEach(function(r){o.set(r.name,r)});function l(r){n.add(r.name);var s=[].concat(r.requires||[],r.requiresIfExists||[]);s.forEach(function(d){if(!n.has(d)){var i=o.get(d);i&&l(i)}}),a.push(r)}return t.forEach(function(r){n.has(r.name)||l(r)}),a}function Tm(t){var o=Nm(t);return Df.reduce(function(n,a){return n.concat(o.filter(function(l){return l.phase===a}))},[])}function Am(t){var o;return function(){return o||(o=new Promise(function(n){Promise.resolve().then(function(){o=void 0,n(t())})})),o}}function Om(t){var o=t.reduce(function(n,a){var l=n[a.name];return n[a.name]=l?Object.assign({},l,a,{options:Object.assign({},l.options,a.options),data:Object.assign({},l.data,a.data)}):a,n},{});return Object.keys(o).map(function(n){return o[n]})}var wr={placement:"bottom",modifiers:[],strategy:"absolute"};function kr(){for(var t=arguments.length,o=new Array(t),n=0;n<t;n++)o[n]=arguments[n];return!o.some(function(a){return!(a&&typeof a.getBoundingClientRect=="function")})}function Em(t){t===void 0&&(t={});var o=t,n=o.defaultModifiers,a=n===void 0?[]:n,l=o.defaultOptions,r=l===void 0?wr:l;return function(d,i,c){c===void 0&&(c=r);var p={placement:"bottom",orderedModifiers:[],options:Object.assign({},wr,r),modifiersData:{},elements:{reference:d,popper:i},attributes:{},styles:{}},u=[],f=!1,y={state:p,setOptions:function(w){var g=typeof w=="function"?w(p.options):w;b(),p.options=Object.assign({},r,p.options,g),p.scrollParents={reference:wt(d)?co(d):d.contextElement?co(d.contextElement):[],popper:co(i)};var S=Tm(Om([].concat(a,p.options.modifiers)));return p.orderedModifiers=S.filter(function(C){return C.enabled}),h(),y.update()},forceUpdate:function(){if(!f){var w=p.elements,g=w.reference,S=w.popper;if(kr(g,S)){p.rects={reference:Sm(g,io(S),p.options.strategy==="fixed"),popper:qn(S)},p.reset=!1,p.placement=p.options.placement,p.orderedModifiers.forEach(function(L){return p.modifiersData[L.name]=Object.assign({},L.data)});for(var C=0;C<p.orderedModifiers.length;C++){if(p.reset===!0){p.reset=!1,C=-1;continue}var k=p.orderedModifiers[C],_=k.fn,E=k.options,O=E===void 0?{}:E,B=k.name;typeof _=="function"&&(p=_({state:p,options:O,name:B,instance:y})||p)}}}},update:Am(function(){return new Promise(function(m){y.forceUpdate(),m(p)})}),destroy:function(){b(),f=!0}};if(!kr(d,i))return y;y.setOptions(c).then(function(m){!f&&c.onFirstUpdate&&c.onFirstUpdate(m)});function h(){p.orderedModifiers.forEach(function(m){var w=m.name,g=m.options,S=g===void 0?{}:g,C=m.effect;if(typeof C=="function"){var k=C({state:p,name:w,instance:y,options:S}),_=function(){};u.push(k||_)}})}function b(){u.forEach(function(m){return m()}),u=[]}return y}}var Bm=[Zf,ym,Qf,jf,hm,dm,wm,Yf,um],Vm=Em({defaultModifiers:Bm});function ea(t,o){(o==null||o>t.length)&&(o=t.length);for(var n=0,a=new Array(o);n<o;n++)a[n]=t[n];return a}function xr(t,o){if(t){if(typeof t=="string")return ea(t,o);var n=Object.prototype.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ea(t,o):void 0}}function Lm(t){return function(o){if(Array.isArray(o))return ea(o)}(t)||function(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}(t)||xr(t)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
73
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function zt(t){return zt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},zt(t)}function _r(t,o,n,a,l,r,s){try{var d=t[r](s),i=d.value}catch(c){return void n(c)}d.done?o(i):Promise.resolve(i).then(a,l)}function Sr(t){return function(){var o=this,n=arguments;return new Promise(function(a,l){var r=t.apply(o,n);function s(i){_r(r,a,l,s,d,"next",i)}function d(i){_r(r,a,l,s,d,"throw",i)}s(void 0)})}}var Nr={exports:{}},Tr={exports:{}};(function(t){function o(n){return t.exports=o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},t.exports.__esModule=!0,t.exports.default=t.exports,o(n)}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports})(Tr),function(t){var o=Tr.exports.default;function n(){t.exports=n=function(){return l},t.exports.__esModule=!0,t.exports.default=t.exports;var a,l={},r=Object.prototype,s=r.hasOwnProperty,d=Object.defineProperty||function(N,v,A){N[v]=A.value},i=typeof Symbol=="function"?Symbol:{},c=i.iterator||"@@iterator",p=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function f(N,v,A){return Object.defineProperty(N,v,{value:A,enumerable:!0,configurable:!0,writable:!0}),N[v]}try{f({},"")}catch{f=function(v,A,F){return v[A]=F}}function y(N,v,A,F){var M=v&&v.prototype instanceof C?v:C,G=Object.create(M.prototype),W=new P(F||[]);return d(G,"_invoke",{value:$(N,A,W)}),G}function h(N,v,A){try{return{type:"normal",arg:N.call(v,A)}}catch(F){return{type:"throw",arg:F}}}l.wrap=y;var b="suspendedStart",m="suspendedYield",w="executing",g="completed",S={};function C(){}function k(){}function _(){}var E={};f(E,c,function(){return this});var O=Object.getPrototypeOf,B=O&&O(O(R([])));B&&B!==r&&s.call(B,c)&&(E=B);var L=_.prototype=C.prototype=Object.create(E);function D(N){["next","throw","return"].forEach(function(v){f(N,v,function(A){return this._invoke(v,A)})})}function I(N,v){function A(M,G,W,X){var Q=h(N[M],N,G);if(Q.type!=="throw"){var Z=Q.arg,ae=Z.value;return ae&&o(ae)=="object"&&s.call(ae,"__await")?v.resolve(ae.__await).then(function(le){A("next",le,W,X)},function(le){A("throw",le,W,X)}):v.resolve(ae).then(function(le){Z.value=le,W(Z)},function(le){return A("throw",le,W,X)})}X(Q.arg)}var F;d(this,"_invoke",{value:function(M,G){function W(){return new v(function(X,Q){A(M,G,X,Q)})}return F=F?F.then(W,W):W()}})}function $(N,v,A){var F=b;return function(M,G){if(F===w)throw new Error("Generator is already running");if(F===g){if(M==="throw")throw G;return{value:a,done:!0}}for(A.method=M,A.arg=G;;){var W=A.delegate;if(W){var X=x(W,A);if(X){if(X===S)continue;return X}}if(A.method==="next")A.sent=A._sent=A.arg;else if(A.method==="throw"){if(F===b)throw F=g,A.arg;A.dispatchException(A.arg)}else A.method==="return"&&A.abrupt("return",A.arg);F=w;var Q=h(N,v,A);if(Q.type==="normal"){if(F=A.done?g:m,Q.arg===S)continue;return{value:Q.arg,done:A.done}}Q.type==="throw"&&(F=g,A.method="throw",A.arg=Q.arg)}}}function x(N,v){var A=v.method,F=N.iterator[A];if(F===a)return v.delegate=null,A==="throw"&&N.iterator.return&&(v.method="return",v.arg=a,x(N,v),v.method==="throw")||A!=="return"&&(v.method="throw",v.arg=new TypeError("The iterator does not provide a '"+A+"' method")),S;var M=h(F,N.iterator,v.arg);if(M.type==="throw")return v.method="throw",v.arg=M.arg,v.delegate=null,S;var G=M.arg;return G?G.done?(v[N.resultName]=G.value,v.next=N.nextLoc,v.method!=="return"&&(v.method="next",v.arg=a),v.delegate=null,S):G:(v.method="throw",v.arg=new TypeError("iterator result is not an object"),v.delegate=null,S)}function V(N){var v={tryLoc:N[0]};1 in N&&(v.catchLoc=N[1]),2 in N&&(v.finallyLoc=N[2],v.afterLoc=N[3]),this.tryEntries.push(v)}function T(N){var v=N.completion||{};v.type="normal",delete v.arg,N.completion=v}function P(N){this.tryEntries=[{tryLoc:"root"}],N.forEach(V,this),this.reset(!0)}function R(N){if(N||N===""){var v=N[c];if(v)return v.call(N);if(typeof N.next=="function")return N;if(!isNaN(N.length)){var A=-1,F=function M(){for(;++A<N.length;)if(s.call(N,A))return M.value=N[A],M.done=!1,M;return M.value=a,M.done=!0,M};return F.next=F}}throw new TypeError(o(N)+" is not iterable")}return k.prototype=_,d(L,"constructor",{value:_,configurable:!0}),d(_,"constructor",{value:k,configurable:!0}),k.displayName=f(_,u,"GeneratorFunction"),l.isGeneratorFunction=function(N){var v=typeof N=="function"&&N.constructor;return!!v&&(v===k||(v.displayName||v.name)==="GeneratorFunction")},l.mark=function(N){return Object.setPrototypeOf?Object.setPrototypeOf(N,_):(N.__proto__=_,f(N,u,"GeneratorFunction")),N.prototype=Object.create(L),N},l.awrap=function(N){return{__await:N}},D(I.prototype),f(I.prototype,p,function(){return this}),l.AsyncIterator=I,l.async=function(N,v,A,F,M){M===void 0&&(M=Promise);var G=new I(y(N,v,A,F),M);return l.isGeneratorFunction(v)?G:G.next().then(function(W){return W.done?W.value:G.next()})},D(L),f(L,u,"Generator"),f(L,c,function(){return this}),f(L,"toString",function(){return"[object Generator]"}),l.keys=function(N){var v=Object(N),A=[];for(var F in v)A.push(F);return A.reverse(),function M(){for(;A.length;){var G=A.pop();if(G in v)return M.value=G,M.done=!1,M}return M.done=!0,M}},l.values=R,P.prototype={constructor:P,reset:function(N){if(this.prev=0,this.next=0,this.sent=this._sent=a,this.done=!1,this.delegate=null,this.method="next",this.arg=a,this.tryEntries.forEach(T),!N)for(var v in this)v.charAt(0)==="t"&&s.call(this,v)&&!isNaN(+v.slice(1))&&(this[v]=a)},stop:function(){this.done=!0;var N=this.tryEntries[0].completion;if(N.type==="throw")throw N.arg;return this.rval},dispatchException:function(N){if(this.done)throw N;var v=this;function A(Q,Z){return G.type="throw",G.arg=N,v.next=Q,Z&&(v.method="next",v.arg=a),!!Z}for(var F=this.tryEntries.length-1;F>=0;--F){var M=this.tryEntries[F],G=M.completion;if(M.tryLoc==="root")return A("end");if(M.tryLoc<=this.prev){var W=s.call(M,"catchLoc"),X=s.call(M,"finallyLoc");if(W&&X){if(this.prev<M.catchLoc)return A(M.catchLoc,!0);if(this.prev<M.finallyLoc)return A(M.finallyLoc)}else if(W){if(this.prev<M.catchLoc)return A(M.catchLoc,!0)}else{if(!X)throw new Error("try statement without catch or finally");if(this.prev<M.finallyLoc)return A(M.finallyLoc)}}}},abrupt:function(N,v){for(var A=this.tryEntries.length-1;A>=0;--A){var F=this.tryEntries[A];if(F.tryLoc<=this.prev&&s.call(F,"finallyLoc")&&this.prev<F.finallyLoc){var M=F;break}}M&&(N==="break"||N==="continue")&&M.tryLoc<=v&&v<=M.finallyLoc&&(M=null);var G=M?M.completion:{};return G.type=N,G.arg=v,M?(this.method="next",this.next=M.finallyLoc,S):this.complete(G)},complete:function(N,v){if(N.type==="throw")throw N.arg;return N.type==="break"||N.type==="continue"?this.next=N.arg:N.type==="return"?(this.rval=this.arg=N.arg,this.method="return",this.next="end"):N.type==="normal"&&v&&(this.next=v),S},finish:function(N){for(var v=this.tryEntries.length-1;v>=0;--v){var A=this.tryEntries[v];if(A.finallyLoc===N)return this.complete(A.completion,A.afterLoc),T(A),S}},catch:function(N){for(var v=this.tryEntries.length-1;v>=0;--v){var A=this.tryEntries[v];if(A.tryLoc===N){var F=A.completion;if(F.type==="throw"){var M=F.arg;T(A)}return M}}throw new Error("illegal catch attempt")},delegateYield:function(N,v,A){return this.delegate={iterator:R(N),resultName:v,nextLoc:A},this.method==="next"&&(this.arg=a),S}},l}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports}(Nr);var Fo=Nr.exports(),Io=Fo;try{regeneratorRuntime=Fo}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=Fo:Function("r","regeneratorRuntime = r")(Fo)}function vm(t){var o=function(n,a){if(zt(n)!=="object"||n===null)return n;var l=n[Symbol.toPrimitive];if(l!==void 0){var r=l.call(n,a||"default");if(zt(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(a==="string"?String:Number)(n)}(t,"string");return zt(o)==="symbol"?o:String(o)}function ta(t,o,n){return(o=vm(o))in t?Object.defineProperty(t,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[o]=n,t}var Do=e.defineComponent({name:"Saturation",props:{size:{type:Number,default:160},hue:{type:Number,default:0},saturation:{type:Number,default:0},value:{type:Number,default:0}},emits:["change"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return{width:"".concat(t.size,"px"),height:"".concat(t.size,"px"),background:"hsl(".concat(t.hue,", 100%, 50%)")}});return{saturationStyle:a,sliderStyle:e.computed(function(){return{top:"".concat((100-t.value)/100*t.size-5,"px"),left:"".concat(t.saturation*t.size/100-5,"px"),width:"".concat(10,"px"),height:"".concat(10,"px")}}),onSelect:function(l){var r=l.target.getBoundingClientRect(),s=r.left,d=r.top,i=function(c){var p=c.clientX,u=c.clientY,f=p-s,y=u-d;f<0&&(f=0),y<0&&(y=0),f>t.size&&(f=t.size),y>t.size&&(y=t.size);var h=f/t.size*100,b=100-y/t.size*100;n("change",h,b)};i(l),document.addEventListener("mousemove",i),document.addEventListener("mouseup",function c(){document.removeEventListener("mousemove",i),document.removeEventListener("mouseup",c)})}}}}),Ar=function(t){return e.pushScopeId("data-v-24517fec"),t=t(),e.popScopeId(),t},$m=Ar(function(){return e.createElementVNode("div",{class:"saturation-white"},null,-1)}),Fm=Ar(function(){return e.createElementVNode("div",{class:"saturation-black"},null,-1)});function et(t,o){o===void 0&&(o={});var n=o.insertAt;if(t&&typeof document<"u"){var a=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css",n==="top"&&a.firstChild?a.insertBefore(l,a.firstChild):a.appendChild(l),l.styleSheet?l.styleSheet.cssText=t:l.appendChild(document.createTextNode(t))}}et(".saturation[data-v-24517fec]{position:relative}.saturation-black[data-v-24517fec],.saturation-white[data-v-24517fec]{cursor:pointer;height:100%;left:0;position:absolute;top:0;width:100%}.saturation-white[data-v-24517fec]{background:linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.saturation-black[data-v-24517fec]{background:linear-gradient(0deg,#000,transparent)}.slider[data-v-24517fec]{border:1px solid #fff;border-radius:50%;box-shadow:0 0 1px 1px rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;top:0;z-index:1}"),Do.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",{class:"saturation",style:e.normalizeStyle(t.saturationStyle),onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[$m,Fm,e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],36)},Do.__scopeId="data-v-24517fec",Do.__file="src/picker/Saturation.vue";var Mo=e.defineComponent({name:"Hue",props:{width:{type:Number,default:15},height:{type:Number,default:160},hue:{type:Number,default:0}},emits:["change"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return{top:"".concat((1-t.hue/360)*t.height-2,"px"),height:"".concat(4,"px")}}),l=e.ref();return e.onMounted(function(){(function(){l.value.width=t.width,l.value.height=t.height;var r=l.value.getContext("2d"),s=r.createLinearGradient(0,0,0,t.height);s.addColorStop(0,"#FF0000"),s.addColorStop(.17,"#FF00FF"),s.addColorStop(.34,"#0000FF"),s.addColorStop(.51,"#00FFFF"),s.addColorStop(.68,"#00FF00"),s.addColorStop(.17*5,"#FFFF00"),s.addColorStop(1,"#FF0000"),r.fillStyle=s,r.fillRect(0,0,t.width,t.height)})()}),{canvas:l,sliderStyle:a,onSelect:function(r){var s=r.target.getBoundingClientRect().top,d=function(i){var c=i.clientY-s;c<0&&(c=0),c>t.height&&(c=t.height);var p=-100*c/t.height+100;n("change",360*p/100)};d(r),document.addEventListener("mousemove",d),document.addEventListener("mouseup",function i(){document.removeEventListener("mousemove",d),document.removeEventListener("mouseup",i)})}}}}),Im={ref:"canvas"};et(".hue[data-v-78b9f4f0]{position:relative}.slider[data-v-78b9f4f0]{background:#fff;box-shadow:0 0 1px 0 rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;width:100%;z-index:1}"),Mo.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",{class:"hue",onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[e.createElementVNode("canvas",Im,null,512),e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],32)},Mo.__scopeId="data-v-78b9f4f0",Mo.__file="src/picker/Hue.vue";var Po=e.defineComponent({name:"Alpha",props:{width:{type:Number,default:15},height:{type:Number,default:160},color:{type:String,default:"#000000"},alpha:{type:Number,default:1}},setup:function(t,o){var n=o.emit,a=e.computed(function(){return{top:"".concat(t.alpha*t.height-2,"px"),height:"".concat(4,"px")}}),l=e.ref(),r=function(){var s=l.value.getContext("2d");l.value.width=t.width,l.value.height=t.height;var d=function(c){var p=document.createElement("canvas"),u=p.getContext("2d"),f=2*c;return p.width=f,p.height=f,u.fillStyle="#ffffff",u.fillRect(0,0,f,f),u.fillStyle="#ccd5db",u.fillRect(0,0,c,c),u.fillRect(c,c,c,c),p}(5);s.fillStyle=s.createPattern(d,"repeat"),s.fillRect(0,0,t.width,t.height);var i=s.createLinearGradient(0,0,0,t.height);i.addColorStop(.01,"rgba(255,255,255,0)"),i.addColorStop(.99,t.color),s.fillStyle=i,s.fillRect(0,0,t.width,t.height)};return e.watch(function(){return t.color},function(){r()}),e.onMounted(function(){r()}),{canvas:l,sliderStyle:a,onSelect:function(s){var d=s.target.getBoundingClientRect().top,i=function(c){var p=c.clientY-d;p<0&&(p=0),p>t.height&&(p=t.height);var u=parseFloat((p/t.height).toFixed(2));n("change",u)};i(s),document.addEventListener("mousemove",i),document.addEventListener("mouseup",function c(){document.removeEventListener("mousemove",i),document.removeEventListener("mouseup",c)})}}}}),Dm={ref:"canvas"};et(".alpha[data-v-24dc9656]{position:relative}.slider[data-v-24dc9656]{background:#fff;box-shadow:0 0 1px 0 rgba(0,0,0,.3);left:0;pointer-events:none;position:absolute;width:100%;z-index:1}"),Po.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",{class:"alpha",onMousedown:o[0]||(o[0]=e.withModifiers(function(){return t.onSelect&&t.onSelect.apply(t,arguments)},["prevent","stop"]))},[e.createElementVNode("canvas",Dm,null,512),e.createElementVNode("div",{class:"slider",style:e.normalizeStyle(t.sliderStyle)},null,4)],32)},Po.__scopeId="data-v-24dc9656",Po.__file="src/picker/Alpha.vue";var jo=e.defineComponent({name:"Input",props:{label:{type:String,default:"RGBA"},value:{type:String,default:""},width:{type:Number,default:168}},emits:["change","focus","blur","enter"],setup:function(t,o){var n=o.emit;return{onInput:function(a){var l;n("change",(l=a.target)===null||l===void 0?void 0:l.value)},valueStyle:e.computed(function(){return{minWidth:"".concat(t.width,"px"),maxWidth:"".concat(t.width,"px"),width:"".concat(t.width,"px")}}),onFocus:function(){n("focus")},onBlur:function(){n("blur")},onEnter:function(){n("enter")}}}}),Mm={class:"input"},Pm={class:"label"},jm=[".value"];function uo(t,o){return function(n){if(Array.isArray(n))return n}(t)||function(n,a){var l=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(l!=null){var r,s,d,i,c=[],p=!0,u=!1;try{if(d=(l=l.call(n)).next,a===0){if(Object(l)!==l)return;p=!1}else for(;!(p=(r=d.call(l)).done)&&(c.push(r.value),c.length!==a);p=!0);}catch(f){u=!0,s=f}finally{try{if(!p&&l.return!=null&&(i=l.return(),Object(i)!==i))return}finally{if(u)throw s}}return c}}(t,o)||xr(t,o)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
74
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Or(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(l){return Object.getOwnPropertyDescriptor(t,l).enumerable})),n.push.apply(n,a)}return n}function Re(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?Or(Object(n),!0).forEach(function(a){ta(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Or(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}et(".input[data-v-d52a4d02]{display:inline-block;font-size:12px}.label[data-v-d52a4d02]{align-items:center;background:#e7e8e9;color:#999;display:flex;float:left;font-weight:500;height:30px;justify-content:center;width:45px}[pick-colors-theme=dark] .label[data-v-d52a4d02]{background:#252930;color:#999}.value[data-v-d52a4d02]{background:#eceef0;border:1px solid #eceef0;box-sizing:border-box;color:#666;flex:1;height:30px;text-align:center}[pick-colors-theme=dark] .value[data-v-d52a4d02]{background:#2e333a;border:1px solid #2e333a;color:#fff}.value[data-v-d52a4d02]:focus{border:1px solid #1890ff;outline:none}"),jo.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",Mm,[e.createElementVNode("span",Pm,e.toDisplayString(t.label),1),e.createElementVNode("input",{class:"value",style:e.normalizeStyle(t.valueStyle),".value":t.value,onFocus:o[0]||(o[0]=function(){return t.onFocus&&t.onFocus.apply(t,arguments)}),onInput:o[1]||(o[1]=function(){return t.onInput&&t.onInput.apply(t,arguments)}),onBlur:o[2]||(o[2]=function(){return t.onBlur&&t.onBlur.apply(t,arguments)}),onKeydown:o[3]||(o[3]=e.withKeys(function(){return t.onEnter&&t.onEnter.apply(t,arguments)},["enter"]))},null,44,jm)])},jo.__scopeId="data-v-d52a4d02",jo.__file="src/picker/InputValue.vue";var Er=function(t,o,n){return[t,o*n/((t=(2-o)*n)<1?t:2-t)||0,t/2]},Br={10:"A",11:"B",12:"C",13:"D",14:"E",15:"F"},Ro=function(t){t=Math.min(Math.round(t),255);var o=Math.floor(t/16),n=t%16;return"".concat(Br[o]||o).concat(Br[n]||n)},Vr=function(t){var o=t.r,n=t.g,a=t.b;return isNaN(o)||isNaN(n)||isNaN(a)?"":"#".concat(Ro(o)).concat(Ro(n)).concat(Ro(a))},Gt=function(t,o){var n;typeof(n=t)=="string"&&n.indexOf(".")!==-1&&parseFloat(n)===1&&(t="100%");var a=function(l){return typeof l=="string"&&l.indexOf("%")!==-1}(t);return t=Math.min(o,Math.max(0,parseFloat("".concat(t)))),a&&(t=parseInt("".concat(t*o),10)/100),Math.abs(t-o)<1e-6?1:t%o/parseFloat(o)},fo=function(t,o,n){t=6*Gt(t,360),o=Gt(o,100),n=Gt(n,100);var a=Math.floor(t),l=t-a,r=n*(1-o),s=n*(1-l*o),d=n*(1-(1-l)*o),i=a%6,c=[n,s,r,r,d,n][i],p=[d,n,n,s,r,r][i],u=[r,r,d,n,n,s][i];return{r:Math.round(255*c),g:Math.round(255*p),b:Math.round(255*u)}},Lr=function(t,o,n){var a=t.h,l=t.s,r=t.v,s=t.a;if(n)switch(o){case"hsl":var d=Er(a,l/100,r/100);return"hsla(".concat(a.toFixed(0),", ").concat(Math.round(100*d[1]),"%, ").concat(Math.round(100*d[2]),"%, ").concat(s,")");case"hsv":return"hsva(".concat(a.toFixed(0),", ").concat(Math.round(l),"%, ").concat(Math.round(r),"%, ").concat(s,")");case"rgb":var i=fo(a,l,r),c=i.r,p=i.g,u=i.b;return"rgba(".concat(c,", ").concat(p,", ").concat(u,", ").concat(s,")");default:return"".concat(Vr(fo(a,l,r))).concat(Ro(255*s))}else switch(o){case"hsl":var f=Er(a,l/100,r/100);return"hsl(".concat(a.toFixed(0),", ").concat(Math.round(100*f[1]),"%, ").concat(Math.round(100*f[2]),"%)");case"hsv":return"hsv(".concat(a.toFixed(0),", ").concat(Math.round(l),"%, ").concat(Math.round(r),"%)");case"rgb":var y=fo(a,l,r),h=y.r,b=y.g,m=y.b;return"rgb(".concat(h,", ").concat(b,", ").concat(m,")");default:return Vr(fo(a,l,r))}},Uo=function(t){var o=t.r,n=t.g,a=t.b;o=Gt(o,255),n=Gt(n,255),a=Gt(a,255);var l,r=Math.max(o,n,a),s=Math.min(o,n,a),d=r,i=r-s,c=r===0?0:i/r;if(r===s)l=0;else{switch(r){case o:l=(n-a)/i+(n<a?6:0);break;case n:l=(a-o)/i+2;break;case a:l=(o-n)/i+4}l/=6}return{h:360*l,s:100*c,v:100*d}},vr=function(t){var o=t.h,n=t.s,a=t.l;a/=100;var l=n/=100,r=Math.max(a,.01);return n*=(a*=2)<=1?a:2-a,l*=r<=1?r:2-r,{h:+o,s:100*(a===0?2*l/(r+l):2*n/(a+n)),v:100*((a+n)/2)}},$r=function(t){var o=[];if(t.match(/^#([0-9a-fA-f]{3,4})$/g))for(var n=1;n<t.length;n++)o.push(parseInt("0x"+t[n].repeat(2)));else if(t.match(/^#([0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/g))for(var a=1;a<t.length;a+=2)o.push(parseInt("0x"+t.slice(a,a+2)));return{r:o[0],g:o[1],b:o[2],a:o[3]}},oa=function(t,o,n){if(typeof t=="string"&&t!==""){var a=na(t,aa(t),n),l=Mr(a);return Lr(l,o,n)}return""},Fr=function(t){var o=uo(t.match(/(\d(\.\d+)?)+/g),4);return{r:o[0],g:o[1],b:o[2],a:o[3]}},Ir=function(t){var o=uo(t.match(/(\d(\.\d+)?)+/g),4),n=o[0],a=o[1],l=o[2],r=o[3];return{h:n,s:parseFloat(a),l:parseFloat(l),a:r}},Dr=function(t){var o=uo(t.match(/(\d(\.\d+)?)+/g),4),n=o[0],a=o[1],l=o[2],r=o[3];return{h:parseFloat(n),s:parseFloat(a),v:parseFloat(l),a:parseFloat(r)}},na=function(t,o){if(!(arguments.length>2&&arguments[2]!==void 0)||arguments[2])switch(o){case"rgb":var n=Fr(t),a=n.r,l=n.g,r=n.b,s=n.a;return Re(Re({},Uo({r:a,g:l,b:r})),{},{a:+s});case"hsv":var d=Dr(t);return{h:d.h,s:d.s,v:d.v,a:d.a};case"hsl":var i=Ir(t),c=i.h,p=i.s,u=i.l,f=i.a;return Re(Re({},vr({h:c,s:p,l:u})),{},{a:+f});default:var y=$r(t),h=y.r,b=y.g,m=y.b,w=y.a;return Re(Re({},Uo({r:h,g:b,b:m})),{},{a:w/255})}else switch(o){case"rgb":return Re(Re({},Uo(Fr(t))),{},{a:1});case"hsv":var g=Dr(t);return{h:g.h,s:g.s,v:g.v,a:1};case"hsl":return Re(Re({},vr(Ir(t))),{},{a:1});default:return Re(Re({},Uo($r(t))),{},{a:1})}},aa=function(t){return t.match(/^#/)?"hex":t.match(/^rgb/)?"rgb":t.match(/^hsl/)?"hsl":t.match(/^hsv/)?"hsv":"hex"},Mr=function(t){var o=t.h,n=t.s,a=t.v,l=t.a;return isNaN(o)&&(o=0),isNaN(n)&&(n=0),isNaN(a)&&(a=0),isNaN(l)&&(l=1),{h:o,s:n,v:a,a:l}},mo=e.defineComponent({name:"ColorItem",props:{size:{type:[Number,String],default:20},width:{type:[Number,String]},height:{type:[Number,String]},value:{type:String,default:""},border:{type:Boolean,default:!0},borderRadius:{type:Number,default:5},selected:{type:Boolean,default:!1},draggable:{type:Boolean,default:!1}},emits:["select"],setup:function(t){var o=e.ref(),n=e.inject("theme",{theme:"light"}).theme,a=e.computed(function(){return parseFloat((t.width||t.size)+"")}),l=e.computed(function(){return parseFloat((t.height||t.size)+"")}),r=e.computed(function(){return{width:"".concat(e.unref(a),"px"),height:"".concat(e.unref(l),"px"),border:t.border?"1px solid ".concat(e.unref(n)==="dark"?"#434345":"#d9d9d9"):"",borderRadius:"".concat(t.borderRadius,"px"),boxShadow:t.selected?"0 0 3px 2px ".concat(e.unref(n)==="dark"?"#2681ff":"#1890ff"):""}}),s=function(){var d=o.value.getContext("2d");o.value.width=e.unref(a),o.value.height=e.unref(l);var i=function(c){var p=document.createElement("canvas"),u=p.getContext("2d"),f=2*c;return p.width=f,p.height=f,u.fillStyle="#ffffff",u.fillRect(0,0,f,f),u.fillStyle="#ccd5db",u.fillRect(0,0,c,c),u.fillRect(c,c,c,c),p}(5);d.fillStyle=d.createPattern(i,"repeat"),d.fillRect(0,0,e.unref(a),e.unref(l)),d.fillStyle=t.value,d.fillRect(0,0,e.unref(a),e.unref(l))};return e.watch(function(){return t.value},function(){s()}),e.onMounted(function(){s()}),{canvas:o,colorItemStyle:r}}}),Rm=["draggable"];et(".color-item[data-v-02da71fd]{display:inline-block;vertical-align:top}"),mo.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("canvas",{class:"color-item",style:e.normalizeStyle(t.colorItemStyle),ref:"canvas",draggable:t.draggable},null,12,Rm)},mo.__scopeId="data-v-02da71fd",mo.__file="src/color-item/ColorItem.vue";var zo=e.defineComponent({name:"Colors",components:{ColorItem:mo},props:{colors:{type:Array,default:function(){return[]}},selectedIndex:{type:Number,default:-1}},emits:["change"],setup:function(t,o){var n=o.emit;return{onSelectColor:function(a,l){n("change",a,l)},useColors:e.computed(function(){return t.colors.map(function(a){return oa(a,"hex",!0)})})}}}),Um={class:"colors"};function Pr(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(l){return Object.getOwnPropertyDescriptor(t,l).enumerable})),n.push.apply(n,a)}return n}function Ke(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?Pr(Object(n),!0).forEach(function(a){ta(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Pr(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}et(".colors[data-v-0f8b52a8]{align-items:center;display:flex;flex-wrap:wrap;margin-top:5px}.color-item[data-v-0f8b52a8]{margin:5px}"),zo.render=function(t,o,n,a,l,r){var s=e.resolveComponent("color-item");return e.openBlock(),e.createElementBlock("div",Um,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.useColors,function(d,i){return e.openBlock(),e.createBlock(s,{key:i,class:"color-item",size:16,value:d,border:!1,"border-radius":3,selected:t.selectedIndex===i,onClick:e.withModifiers(function(c){return t.onSelectColor(d,+i)},["stop","prevent"])},null,8,["value","selected","onClick"])}),128))])},zo.__scopeId="data-v-0f8b52a8",zo.__file="src/picker/Colors.vue";var Go=e.defineComponent({name:"Picker",components:{Colors:zo,Saturation:Do,Hue:Mo,Alpha:Po,InputValue:jo},props:{format:{type:String,default:"hex"},showAlpha:{type:Boolean,default:!1},value:{type:String,default:""},colors:{type:Array,default:function(){return[]}},style:{type:Object,default:function(){return{}}}},emits:["change","update:value"],setup:function(t,o){var n=o.emit,a=e.computed(function(){return Ke(Ke({},t.style),{},{width:t.showAlpha?"230px":"205px"})}),l=e.computed(function(){return t.showAlpha?165:140}),r=e.ref(),s=e.ref(),d=e.ref(),i=function(){var g,S=(g=t.value)===null||g===void 0?void 0:g.trim();if(S!=null&&S!==""){var C=aa(S);return Mr(na(S,C,t.showAlpha))}return null};e.watch(function(){return t.value},function(){t.value!==e.unref(d)&&(r.value=i())},{immediate:!0}),e.watch(r,function(g,S){var C="";g!=null?(C=Lr(Ke({},g),t.format,t.showAlpha),s.value=Ke({},g)):s.value=null,d.value=C;var k=i();JSON.stringify(g)!==JSON.stringify(k)&&JSON.stringify(g)!==JSON.stringify(S)&&n("change",C)},{immediate:!0});var c=e.computed(function(){var g;return((g=e.unref(r))===null||g===void 0?void 0:g.h)||0}),p=e.computed(function(){var g;return((g=e.unref(r))===null||g===void 0?void 0:g.s)||0}),u=e.computed(function(){var g;return((g=e.unref(r))===null||g===void 0?void 0:g.v)||0}),f=e.computed(function(){var g,S;return((g=e.unref(r))===null||g===void 0?void 0:g.a)!=null?(S=e.unref(r))===null||S===void 0?void 0:S.a:1}),y=e.computed(function(){return fo(e.unref(c),e.unref(p),e.unref(u))}),h=e.computed(function(){return"rgb(".concat(e.unref(y).r,", ").concat(e.unref(y).g,", ").concat(e.unref(y).b,")")}),b=e.computed(function(){var g=t.format;if(t.showAlpha)switch(g){case"hsv":return"HSVA";case"hsl":return"HSLA";case"rgb":return"RGBA";default:return"HEX"}else switch(g){case"hsv":return"HSV";case"hsl":return"HSL";case"rgb":return"RGB";default:return"HEX"}}),m=e.ref(-1),w=function(g,S,C){if(g.length!==0){var k=na(g,S,C),_=k.h,E=k.s,O=k.v;if(!(isNaN(_)||isNaN(E)||isNaN(O))){var B=1,L=k.a;isNaN(L)||(B=L),r.value={h:_,s:E,v:O,a:B}}}};return{h:c,s:p,v:u,a:f,rgbStr:h,onSelectSaturation:function(g,S){m.value=-1,e.unref(r)==null?r.value={h:e.unref(c),s:g,v:S,a:e.unref(f)}:r.value=Ke(Ke({},e.unref(r)),{},{s:g,v:S})},onSelectHue:function(g){m.value=-1,e.unref(r)==null&&(r.value={h:g,s:e.unref(p),v:e.unref(u),a:e.unref(f)}),r.value=Ke(Ke({},e.unref(r)),{},{h:g})},onSelectAlpha:function(g){m.value=-1,e.unref(r)==null?r.value={h:e.unref(c),s:e.unref(p),v:e.unref(u),a:g}:r.value=Ke(Ke({},e.unref(r)),{},{a:g})},label:b,colorValue:d,pickerStyle:a,inputWidth:l,onInputChange:function(g){m.value=-1,d.value=g},handleChange:function(){var g,S=(g=e.unref(d))===null||g===void 0?void 0:g.trim();if(S!==""){var C=t.showAlpha,k=t.format,_=function(E,O,B){if(B)switch(O){case"rgb":return/^[rR][gG][Bb][Aa][(]([\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\s]*,){3}[\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*[)]{1}$/.test(E);case"hsv":return/^[hH][Ss][Vv][Aa][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,){2}([\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*)[)]$/.test(E);case"hsl":return/^[hH][Ss][Ll][Aa][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,){2}([\s]*(1|1.0|0|0.[0-9]|0.[0-9][0-9])[\s]*)[)]$/.test(E);default:return/^#([0-9a-fA-f]{4}|[0-9a-fA-F]{8})$/g.test(E)}else switch(O){case"rgb":return/^[rR][gG][Bb][(]([\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\s]*,){2}[\s]*(2[0-4]\d|25[0-5]|[01]?\d\d?)[\s]*[)]{1}$/.test(E);case"hsv":return/^[hH][Ss][Vv][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*)[)]$/.test(E);case"hsl":return/^[hH][Ss][Ll][(]([\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*,)([\s]*((100|[0-9][0-9]?)%|0)[\s]*)[)]$/.test(E);default:return/^#([0-9a-fA-f]{3}|[0-9a-fA-F]{6})$/g.test(E)}}(S,k,C);_?w(S,k,C):e.unref(s)!=null?r.value=e.unref(s):d.value=""}else r.value=null},selectColorIndex:m,onSelectColor:function(g,S){if(m.value=S,(g=g.trim())==="")r.value=null;else{var C=aa(g);C?w(g,C,!0):r.value=null}}}}}),zm={class:"picker-inner"},Gm={class:"picker-header"};et(".picker[data-v-6ceadec6]{background:#f7f8f9;border-radius:4px;box-shadow:0 0 16px 0 rgba(0,0,0,.16)}.picker-inner[data-v-6ceadec6]{padding:10px}[pick-colors-theme=dark] .picker-inner[data-v-6ceadec6]{background:#1d2024;box-shadow:0 0 16px 0 rgba(0,0,0,.16)}.picker-header[data-v-6ceadec6]{display:flex;margin-bottom:5px}.alpha[data-v-6ceadec6],.hue[data-v-6ceadec6]{margin-left:10px}.colors[data-v-6ceadec6]{margin-top:5px}"),Go.render=function(t,o,n,a,l,r){var s=e.resolveComponent("saturation"),d=e.resolveComponent("hue"),i=e.resolveComponent("alpha"),c=e.resolveComponent("input-value"),p=e.resolveComponent("Colors");return e.openBlock(),e.createElementBlock("div",{class:"picker",style:e.normalizeStyle(t.pickerStyle)},[e.createElementVNode("div",zm,[e.createElementVNode("div",Gm,[e.createVNode(s,{class:"saturation",hue:t.h,saturation:t.s,value:t.v,onChange:t.onSelectSaturation},null,8,["hue","saturation","value","onChange"]),e.createVNode(d,{class:"hue",hue:t.h,onChange:t.onSelectHue},null,8,["hue","onChange"]),t.showAlpha?(e.openBlock(),e.createBlock(i,{key:0,class:"alpha",alpha:t.a,color:t.rgbStr,onChange:t.onSelectAlpha},null,8,["alpha","color","onChange"])):e.createCommentVNode("v-if",!0)]),e.createVNode(c,{label:t.label,value:t.colorValue,width:t.inputWidth,onChange:t.onInputChange,onBlur:t.handleChange,onEnter:t.handleChange},null,8,["label","value","width","onChange","onBlur","onEnter"]),t.colors.length>0?(e.openBlock(),e.createBlock(p,{key:0,class:"colors",colors:t.colors,"selected-index":t.selectColorIndex,onChange:t.onSelectColor},null,8,["colors","selected-index","onChange"])):e.createCommentVNode("v-if",!0)])],4)},Go.__scopeId="data-v-6ceadec6",Go.__file="src/picker/Picker.vue";var Ho=e.defineComponent({name:"AddColorItem",props:{size:{type:Number,default:20},selected:{type:Boolean,default:!1}},setup:function(t){var o=e.inject("theme",{theme:"light"}).theme;return{addColorItemStyle:e.computed(function(){return{width:"".concat(t.size,"px"),height:"".concat(t.size,"px"),lineHeight:"".concat(t.size,"px"),boxShadow:t.selected?"0 0 3px 2px ".concat(e.unref(o)==="dark"?"#2681ff":"#1890ff"):""}})}}}),Hm=[function(t){return e.pushScopeId("data-v-ceb1719c"),t=t(),e.popScopeId(),t}(function(){return e.createElementVNode("g",{class:"container"},[e.createElementVNode("path",{d:"M544 464V160h-80v304H160v80h304v304h80V544h304v-80z"})],-1)})];function jr(t,o){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);o&&(a=a.filter(function(l){return Object.getOwnPropertyDescriptor(t,l).enumerable})),n.push.apply(n,a)}return n}function la(t){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?jr(Object(n),!0).forEach(function(a){ta(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):jr(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}et(".add-color-item[data-v-ceb1719c]{background:#fff;border:1px solid #d9d9d9;border-radius:5px;vertical-align:top}.container[data-v-ceb1719c]{pointer-events:none;transform:scale(.9);transform-origin:center}[pick-colors-theme=dark] .add-color-item[data-v-ceb1719c]{background:#141414;border:1px solid #434343}path[data-v-ceb1719c]{fill:#000}[pick-colors-theme=dark] path[data-v-ceb1719c]{fill:#fff}"),Ho.render=function(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("svg",{style:e.normalizeStyle(t.addColorItemStyle),class:"add-color-item",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"},[].concat(Hm),4)},Ho.__scopeId="data-v-ceb1719c",Ho.__file="src/add-color-item/AddColorItem.vue";var xt=null,_t=e.defineComponent({name:"ColorPicker",components:{ColorItem:mo,Picker:Go,AddColorItem:Ho},props:{value:{type:[String,Array]},theme:{type:String,default:"light"},size:{type:[Number,String],default:20},width:{type:[Number,String]},height:{type:[Number,String]},format:{type:String,default:"hex"},showPicker:{type:Boolean,default:void 0},showAlpha:{type:Boolean,default:!1},addColor:{type:Boolean,default:!1},deleteColor:{type:Boolean,default:!0},max:{type:Number,default:13},popupContainer:{type:[String,Object,Boolean]},zIndex:{type:Number,default:1e3},colors:{type:Array,default:function(){return["#ff4500","#ff8c00","#ffd700","#90ee90","#00ced1","#1e90ff","#c71585","#ff4500","#ff7d4d","#00babd","#1f93ff","#fa64c3"]}}},emits:["change","update:value","update:showPicker","overflowMax","closePicker"],setup:function(t,o){var n=o.emit,a=e.ref([]),l=e.computed(function(){return e.unref(a).map(function(x){return oa(x,"hex",t.showAlpha)})});e.watch(function(){return t.value},function(){var x=t.value||"",V=Array.isArray(x)?x:[x];a.value=V.map(function(T){return oa(T,t.format,t.showAlpha)})},{immediate:!0});var r=e.ref(void 0),s=e.computed(function(){return e.unref(a)[e.unref(r)]}),d=e.ref(!1);e.watch(function(){return t.showPicker},function(){d.value=t.showPicker},{immediate:!0});var i,c,p,u,f,y,h,b=e.ref(null),m=e.ref(null),w=(i=b,c=m,p={zIndex:t.zIndex},u=e.ref({}),f={strategy:"absolute",placement:"auto",onFirstUpdate:function(){xt.update()},modifiers:[{name:"offset",options:{offset:[0,5]}},{name:"computeStyles",options:{gpuAcceleration:!1,adaptive:!0}},{name:"flip",options:{fallbackPlacements:["top"],allowedAutoPlacements:["top","bottom"]}},{name:"applyStyles",enabled:!1},{name:"updateState",enabled:!0,phase:"write",requires:["computeStyles"],fn:function(x){var V=x.state,T=V.styles,P=V.placement,R=T.popper;u.value=la(la(la({},R),p),{},{transformOrigin:P==="top"?"center bottom":""})}}]},e.watch(function(){return[e.unref(i),e.unref(c)]},function(x,V){var T,P=uo(x,2),R=P[0],N=P[1],v=uo(V,2),A=v[0],F=v[1];if(R&&N&&(A!==R||F!==A)){(T=xt)===null||T===void 0||T.destroy();var M=R.$el||R,G=N.$el||N;e.nextTick(function(){xt=Vm(M,G,f)})}}),e.onBeforeUnmount(function(){var x;xt&&((x=xt)===null||x===void 0||x.destroy(),xt=null)}),{instance:xt,style:u}),g=w.style,S=function(){e.unref(b)==null&&(b.value=e.unref($)[0],r.value=0),t.showPicker===void 0?d.value=!0:n("update:showPicker",!0)},C=function(){r.value=void 0,t.showPicker===void 0?d.value=!1:n("update:showPicker",!1),n("closePicker",e.toRaw(Array.isArray(t.value)||t.addColor?e.unref(a):e.unref(a)[0]))},k=e.ref(),_=function(){var x=Sr(Io.mark(function V(T){var P,R,N,v;return Io.wrap(function(A){for(;;)switch(A.prev=A.next){case 0:if(R=T.target,(N=(P=R.dataset)===null||P===void 0?void 0:P.index)!=null&&N!==""){A.next=4;break}return A.abrupt("return");case 4:if(v=+N,e.unref(r)!==v){A.next=7;break}return A.abrupt("return");case 7:e.unref(r)!=null&&e.unref(r)!==v?(C(),y&&clearTimeout(y),y=setTimeout(function(){S(),clearTimeout(y)},100)):S(),r.value=v,b.value=R;case 10:case"end":return A.stop()}},V)}));return function(V){return x.apply(this,arguments)}}(),E=function(){var x=Sr(Io.mark(function V(T){var P,R,N,v,A;return Io.wrap(function(F){for(;;)switch(F.prev=F.next){case 0:if(v=T.target,!(!((P=e.unref(k))!==null&&P!==void 0&&P.isEqualNode(v))&&(!((R=e.unref(k))===null||R===void 0)&&R.contains(v)))){F.next=4;break}return F.abrupt("return");case 4:if(A=(N=e.unref(m))===null||N===void 0?void 0:N.$el,!(A!=null&&A.contains(v))){F.next=8;break}return F.abrupt("return");case 8:h&&clearTimeout(h),h=setTimeout(function(){e.unref(d)&&C()},0);case 10:case"end":return F.stop()}},V)}));return function(V){return x.apply(this,arguments)}}();e.watch(d,function(){e.unref(d)&&(S(),clearTimeout(h))});var O,B=e.ref(t.max>e.unref(a).length),L=e.computed(function(){return typeof t.popupContainer=="string"||zt(t.popupContainer)==="object"&&t.popupContainer!=null?t.popupContainer:"body"}),D=e.computed(function(){return typeof t.popupContainer=="boolean"&&t.popupContainer===!1}),I=e.computed(function(){return t.theme});e.watch(function(){return[t.theme,e.unref(m)]},function(){e.nextTick(function(){var x,V;(x=e.unref(k))===null||x===void 0||x.setAttribute("pick-colors-theme",e.unref(I)),(V=e.unref(m))===null||V===void 0||(V=V.$el)===null||V===void 0||V.setAttribute("pick-colors-theme",e.unref(I))})},{immediate:!0}),e.provide("theme",{theme:I});var $=e.ref([]);return e.onMounted(function(){document.addEventListener("mouseup",E,!1),t.showPicker&&S()}),e.onUnmounted(function(){document.removeEventListener("mouseup",E,!1),y&&(clearTimeout(y),y=null),h&&(clearTimeout(h),h=null)}),{valueList:a,colorItemSelected:function(x){return(t.addColor?e.unref(a).length>0:e.unref(a).length>1)&&e.unref(r)===x},selectedColor:s,selectedIndex:r,isShowPicker:d,addColorItemShow:B,onPickerChange:function(x){var V=e.unref(r),T=e.unref(a).slice(),P=e.unref(a).length;if(V!=null){V>=0?T[V]=x:(r.value=P,T.push(x));var R="";R=Array.isArray(t.value)||t.addColor?T:x,t.value===void 0?a.value=Array.isArray(R)?R:[R]:(n("update:value",R),n("change",R,x,V)),t.addColor&&P>=t.max&&(B.value=!1,n("overflowMax"))}},colorPicker:k,onColorClick:_,pickerRef:m,onColorItemDragStart:function(x){x.dataTransfer.effectAllowed="move";var V=x.target;O=+V.dataset.index},onColorItemDragOver:function(x){},onColorItemDrop:function(x){var V=+x.target.dataset.index,T=Lm(e.unref(a)),P=T[O];T.splice(O,1);var R=T.slice(0,V),N=T.splice(V),v=R.concat([P]).concat(N);n("update:value",v),n("change",v,v[O],O)},colorItemsRef:$,pickerStyle:g,values:l,teleportDisabled:D,toPopupContainer:L}}});et(".color-picker[data-v-3c43ade8]{display:inline-block}.color-item[data-v-3c43ade8]{margin:5px}.add-color-item[data-v-3c43ade8]{display:inline-block;margin:5px}.picker[data-v-3c43ade8]{overflow:hidden}.v-enter-active[data-v-3c43ade8],.v-leave-active[data-v-3c43ade8]{opacity:1;transform:scaleY(1);transform-origin:center top;transition:opacity .2s ease-in-out,transform .2s ease-in-out}.v-enter-from[data-v-3c43ade8],.v-leave-to[data-v-3c43ade8]{opacity:0;transform:scaleY(0)}"),_t.render=function(t,o,n,a,l,r){var s=e.resolveComponent("color-item"),d=e.resolveComponent("add-color-item"),i=e.resolveComponent("picker");return e.openBlock(),e.createElementBlock("div",{class:"color-picker",ref:"colorPicker",onDragstart:o[0]||(o[0]=e.withModifiers(function(){return t.onColorItemDragStart&&t.onColorItemDragStart.apply(t,arguments)},["stop"])),onDragover:o[1]||(o[1]=e.withModifiers(function(){return t.onColorItemDragOver&&t.onColorItemDragOver.apply(t,arguments)},["prevent","stop"])),onDrop:o[2]||(o[2]=e.withModifiers(function(){return t.onColorItemDrop&&t.onColorItemDrop.apply(t,arguments)},["prevent","stop"])),onClick:o[3]||(o[3]=e.withModifiers(function(){return t.onColorClick&&t.onColorClick.apply(t,arguments)},["stop"]))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,function(c,p){return e.openBlock(),e.createBlock(s,{class:"color-item",key:p,ref_for:!0,ref:function(u){return t.colorItemsRef[p]=u},size:t.size,width:t.width,height:t.height,value:c,selected:t.colorItemSelected(p),"data-index":p,draggable:t.valueList.length>1,format:t.format},null,8,["size","width","height","value","selected","data-index","draggable","format"])}),128)),t.addColor&&t.addColorItemShow?(e.openBlock(),e.createBlock(d,{key:0,class:"add-color-item",ref:"addColorItem",selected:t.colorItemSelected(-1),"data-index":-1},null,8,["selected"])):e.createCommentVNode("v-if",!0),(e.openBlock(),e.createBlock(e.Teleport,{to:t.toPopupContainer,disabled:t.teleportDisabled},[e.createVNode(e.Transition,null,{default:e.withCtx(function(){return[t.isShowPicker?(e.openBlock(),e.createBlock(i,{key:0,class:"picker",style:e.normalizeStyle(t.pickerStyle),ref:"pickerRef",value:t.selectedColor,format:t.format,"show-alpha":t.showAlpha,colors:t.colors,onChange:t.onPickerChange},null,8,["style","value","format","show-alpha","colors","onChange"])):e.createCommentVNode("v-if",!0)]}),_:1})],8,["to","disabled"]))],544)},_t.__scopeId="data-v-3c43ade8",_t.__file="src/ColorPicker.vue";const Wm=e.defineComponent({name:"ColorPick",components:{PickColors:_t,AInput:j.Input},props:{value:{type:String,require:!0}},emits:["change"],setup(t,o){const n=e.computed({get:()=>t.value,set:l=>{o.emit("change",l)}});return{colorValue:n,onChangColor:l=>{n.value=l.hex}}}}),Gy="",Ym={class:"color-pick"};function qm(t,o,n,a,l,r){const s=e.resolveComponent("a-input"),d=e.resolveComponent("pick-colors");return e.openBlock(),e.createElementBlock("div",Ym,[e.createVNode(s,{class:"input",value:t.colorValue,"onUpdate:value":o[0]||(o[0]=i=>t.colorValue=i)},null,8,["value"]),e.createVNode(d,{class:"pick-colors",value:t.colorValue,"onUpdate:value":o[1]||(o[1]=i=>t.colorValue=i),size:25,showAlpha:!0},null,8,["value"])])}const Km=oe(Wm,[["render",qm],["__scopeId","data-v-2ee2749b"]]),Xm=e.defineComponent({name:"ColorGroupPick",components:{PickColors:_t},props:{value:{type:Array,default:()=>[]}},emits:["change"],setup(t,{emit:o}){const n=r=>{o("change",r)},a=e.ref(13);return{onColorsChange:n,max:a,onOverflowMax:()=>{j.message.warn(`已经超出最大添加个数:${a.value}`)}}}}),Hy="",Qm={class:"color-group-pick"};function Jm(t,o,n,a,l,r){const s=e.resolveComponent("pick-colors");return e.openBlock(),e.createElementBlock("div",Qm,[e.createVNode(s,{value:t.value,"add-color":"",max:t.max,onChange:t.onColorsChange,onOverflowMax:t.onOverflowMax},null,8,["value","max","onChange","onOverflowMax"])])}const Zm=oe(Xm,[["render",Jm],["__scopeId","data-v-b2be8322"]]),eh=e.defineComponent({name:"FormGroup",components:{Draggable:Et,AppstoreAddOutlined:cn,MinusCircleOutlined:Us,PickColors:_t,InputNumber:nr,PlusCircleOutlined:Ws},props:{value:{type:Array,default:()=>[]},format:{type:Array,default:()=>[]},useLabelIndex:{type:Boolean,default:!1},max:{type:Number,default:-1}},emits:["change"],setup(t,{emit:o}){const n=e.computed({get:()=>t.value,set:c=>{o("change",c)}});return{myValue:n,onAdd:()=>{var u;const c=(u=t.value)==null?void 0:u.slice();if(!Array.isArray(c))return;const p=c.length;if(t.max===-1||t.max>p){const f=c[0];if(Object.prototype.toString.call(f)==="[object Object]"){const y=Object.keys(f),h={};y.forEach(b=>{h[b]=""}),c.push(h)}else typeof f=="string"&&c.push(f);n.value=c}else j.message.warn("已达到最大上限")},useComponentType:c=>({input:"aInput",select:"aSelect",color:"pickColors","input-number":"inputNumber",switch:"aSwitch"})[c],onValueChange:(c,p,u)=>{var y;const f=(y=t.value)==null?void 0:y.slice();if(Array.isArray(f)){const h=c==null?void 0:c.target,b=(h==null?void 0:h.value)!=null?h==null?void 0:h.value:c;u?f[p][u]=b:f[p]=b,n.value=f}},onDelete:c=>{var u;const p=(u=t.value)==null?void 0:u.slice();if(Array.isArray(p)){if(p.length===1){j.message.warn("已经是最后一条数据,无法删除");return}p.splice(c,1),n.value=p}},theme:"light",formatTypeValue:c=>c||"value"}}}),Wy="",th={class:"form-group"},oh={class:"form-row"},nh={key:0,class:"label"},ah={key:1,class:"label"},lh={class:"icon-group"};function rh(t,o,n,a,l,r){const s=e.resolveComponent("appstore-add-outlined"),d=e.resolveComponent("draggable"),i=e.resolveComponent("minus-circle-outlined");return e.openBlock(),e.createElementBlock("div",th,[e.createVNode(s,{class:"icon add",onClick:t.onAdd},null,8,["onClick"]),e.createVNode(d,{class:"form",modelValue:t.myValue,"onUpdate:modelValue":o[0]||(o[0]=c=>t.myValue=c),"item-key":"id"},{item:e.withCtx(({element:c,index:p})=>[e.createElementVNode("div",oh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.format,(u,f)=>(e.openBlock(),e.createElementBlock("div",{class:"form-item",key:f},[Array.isArray(u.label)?(e.openBlock(),e.createElementBlock("span",nh,e.toDisplayString(u.useLabelIndex?u.label[p]+(p+1):u.label[p]),1)):(e.openBlock(),e.createElementBlock("span",ah,e.toDisplayString(u.useLabelIndex?u.label+(p+1):u.label),1)),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.useComponentType(u.type)),e.mergeProps({class:"value",[t.formatTypeValue(u.typeValue)||""]:typeof c=="string"?c:c[u.value]??u.defaultValue,style:{width:!["color","switch"].includes(u.type)&&t.format.length>1?"110px":""}},u.props,{theme:t.theme,"use-blur-event":!1,onChange:y=>t.onValueChange(y,p,u.value)}),null,16,["style","theme","onChange"]))]))),128))])]),_:1},8,["modelValue"]),e.createElementVNode("div",lh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.myValue,(c,p)=>(e.openBlock(),e.createElementBlock("div",{class:"icon-item",key:p},[e.createVNode(i,{class:"icon delete",onClick:u=>t.onDelete(p)},null,8,["onClick"])]))),128))])])}const ih=oe(eh,[["render",rh],["__scopeId","data-v-f0c0ab4d"]]),sh=e.defineComponent({name:"Textarea",props:{value:{type:String,default:""},disabled:{type:Boolean,default:!1}},components:{ATextarea:j.Textarea},emits:["change"],setup(t,{emit:o}){return{onTextareaChange:a=>{o("change",a.target.value)}}}});function ch(t,o,n,a,l,r){const s=e.resolveComponent("a-textarea");return e.openBlock(),e.createBlock(s,{value:t.value,disabled:t.disabled,autoSize:{minRows:3},onChange:t.onTextareaChange},null,8,["value","disabled","onChange"])}const dh=oe(sh,[["render",ch]]),ph=e.defineComponent({name:"Slider",components:{ASlider:j.Slider,AInputNumber:j.InputNumber},props:{value:{type:Number,default:1}},emits:["change"],setup(t,{emit:o}){return{onChange:a=>{o("change",a)}}}});function uh(t,o,n,a,l,r){const s=e.resolveComponent("a-slider"),d=e.resolveComponent("a-col"),i=e.resolveComponent("a-input-number"),c=e.resolveComponent("a-row");return e.openBlock(),e.createBlock(c,null,{default:e.withCtx(()=>[e.createVNode(d,{span:16},{default:e.withCtx(()=>[e.createVNode(s,{value:t.value,min:0,max:1,step:.1,onChange:t.onChange},null,8,["value","onChange"])]),_:1}),e.createVNode(d,{span:8,style:{"padding-left":"10px"}},{default:e.withCtx(()=>[e.createVNode(i,{value:t.value,min:0,max:1,step:.1,style:{width:"100%"},onChange:t.onChange},null,8,["value","onChange"])]),_:1})]),_:1})}const fh=oe(ph,[["render",uh]]),mh=e.defineComponent({name:"PropsToForm",components:{Input:mf,InputNumber:nr,RadioGroup:Cf,Select:xf,Switch:Nf,ColorPick:Km,ColorGroupPick:Zm,FormGroup:ih,Textarea:dh,Slider:fh},props:{props:{type:Object,require:!0},disabled:{type:Boolean,default:!1},componentType:{type:String,default:""}},setup(t){const o=e.inject(Co),n=e.inject(Ce),a=e.inject(Yo),l=e.inject(qo),r=e.computed(()=>{var f;return(f=e.unref(o))==null?void 0:f.type}),s=f=>{t.componentType&&t.componentType==="table"?l(f):a(f)},d=f=>{const{result:y,mapAttributeProp:h,key:b,value:m}=f;if(y==null||typeof y!="object")return;const{valueProp:w="value",changeValueEventName:g="change",events:S,effect:C,effectVal:k,props:_}=h;y[b]={...h,valueProp:w,value:m,events:{[g]:(E,O=!0)=>{O?(s({[b]:E}),k&&k(b,E,s,e.unref(n))):s({})},...S},...c(C),props:{..._,...u(_,e.unref(n))}}},i=e.computed(()=>{const f=t.props;return f==null||typeof f!="object"?{}:J.reduce(f,(y,h,b)=>{const m=pf[b];if(Array.isArray(m)){const w=m.find(g=>{const{onlyType:S,excludeType:C}=g;return S==null&&C==null?!0:S?we(e.unref(r),S):C?!we(e.unref(r),C):!1});w&&d({result:y,value:h,key:b,mapAttributeProp:w})}else d({result:y,value:h,key:b,mapAttributeProp:m});return y},{})}),c=f=>{const y={};for(const h in f)y[h]=J.reduce(f[h].props,(b,m)=>f[h].joinType==="&&"?b&&p(m):b||p(m),!!f[h].default);return y},p=f=>{const y=t.props[f.props];let h;switch(f.rule){case"!==":h=y!==f.value;break;case"includes":h=y.includes(f.value);break;case"action":h=f.value(f,t.props);break;default:h=y===f.value}return h};function u(f={},y){const h={};for(const b in f)typeof f[b]=="function"&&(h[b]=f[b](y));return h}return{formProps:i,lowerCaseIncludes:we}}}),Yy="",hh={class:"props-to-form"},bh={key:0,class:"prop-item"},yh={class:"label"},gh={class:"component-wrapper"};function Ch(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",hh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.formProps,(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:d},[s.hide!==!0?(e.openBlock(),e.createElementBlock("div",bh,[e.createElementVNode("span",yh,e.toDisplayString(s.label),1),e.createElementVNode("div",gh,[Array.isArray(s)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(s,(i,c)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.component),e.mergeProps({key:c,class:"component",style:i.style,disabled:t.disabled||i.disabled},i.props,e.toHandlers(i.events)),null,16,["style","disabled"]))),128)):e.createCommentVNode("",!0),Array.isArray(s)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[s.component?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s.component),e.mergeProps({key:0,class:"component",[s.valueProp||""]:s.value,style:s.style,disabled:t.disabled||s.disabled},s.props,e.toHandlers(s.events)),null,16,["style","disabled"])):e.createCommentVNode("",!0)],64))])])):e.createCommentVNode("",!0)],64))),128))])}const wh=oe(mh,[["render",Ch],["__scopeId","data-v-62456472"]]);function kh(){return new Worker("/assets/editor.worker-02df2e61.js")}function xh(){return new Worker("/assets/json.worker-867823a6.js")}function _h(){return new Worker("/assets/ts.worker-7254b425.js")}const Sh=e.defineComponent({name:"Editor",props:{valueData:{type:String,default:""},options:{type:Object,default:()=>({})},language:{type:String,default:"json"},isUseMinimap:{type:Boolean,default:!1},UseSuggestions:{type:Boolean,default:!1},autoFormat:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["change","update:valueData"],setup(t,{emit:o}){window.MonacoEnvironment={getWorker(r,s){return s==="json"?new xh:s==="typescript"||s==="javascript"?new _h:new kh}};const n=e.ref();let a=null;const l={light:"vs",dark:"vs-dark"};return e.onMounted(()=>{a=qr.editor.create(n.value,{language:t.language,tabSize:2,automaticLayout:!0,scrollBeyondLastLine:!1,theme:l.light,wordWrap:"off",lineDecorationsWidth:3,lineHeight:15,lineNumbersMinChars:3,formatOnPaste:!0,formatOnType:!0,wordBasedSuggestions:!1,quickSuggestions:t.UseSuggestions,snippetSuggestions:"none",suggestOnTriggerCharacters:!1,scrollbar:{verticalScrollbarSize:6,horizontalScrollbarSize:6,alwaysConsumeMouseWheel:!1,arrowSize:0},autoIndent:"advanced",glyphMargin:!1,fontSize:13,contextmenu:!1,minimap:{enabled:t.isUseMinimap},readOnly:t.readonly,...t.options}),a==null||a.setValue(t.valueData),t.autoFormat&&setTimeout(()=>{a==null||a.getAction("editor.action.formatDocument").run()},200),a.onDidChangeModelContent(J.debounce(()=>{const r=a==null?void 0:a.getValue();o("change",r)},300)),a.onDidBlurEditorText(()=>{const r=a==null?void 0:a.getValue();o("update:valueData",r)})}),e.watch(()=>t.valueData,r=>{if(a){const s=a.getPosition();a.setValue(r),t.autoFormat&&a.getAction("editor.action.formatDocument").run(),s!=null&&a.setPosition(s)}}),e.onUnmounted(()=>{a==null||a.dispose()}),{dom:n}}}),qy="",Nh={class:"editor",ref:"dom"};function Th(t,o,n,a,l,r){return e.openBlock(),e.createElementBlock("div",Nh,null,512)}const Rr=oe(Sh,[["render",Th],["__scopeId","data-v-71e88372"]]),Ah=e.defineComponent({name:"Condition",components:{CloseOutlined:Xt,MenuOutlined:kn,AMenu:j.Menu,AMenuItem:j.MenuItem,AInput:j.Input,ASelect:j.Select,ADropdown:j.Dropdown},props:{data:{type:Object,default:()=>({})},level:{type:Number,default:0},index:{type:Number,default:0},path:{type:String,default:""}},setup(t){const o=[{label:"大于",value:">"},{label:"大于等于",value:">="},{label:"小于",value:"<"},{label:"小于等于",value:"<="},{label:"等于",value:"=="},{label:"不等于",value:"!="}],n=e.ref({rule:"==",value:"",key:""}),{updateCondition:a,deleteCondition:l,addCondition:r}=e.inject(wo,{updateCondition:(c,p,u)=>{},deleteCondition:(c,p)=>{},addCondition:(c,p,u)=>{}});e.watch(n,c=>{a(J.cloneDeep(c),t.index,t.path)},{deep:!0});const s=()=>{},d=c=>{r(t.path,t.index,c.key==="2"?"||":"&&")},i=()=>{l(t.index,t.path)};return e.onMounted(()=>{var c,p,u;e.unref(n).rule=((c=t.data)==null?void 0:c.rule)||"",e.unref(n).value=((p=t.data)==null?void 0:p.value)||"",e.unref(n).key=((u=t.data)==null?void 0:u.key)||ge()}),{ruleOptions:o,condition:n,onRuleChange:s,clickConditionMenu:d,onDelete:i}}}),Ky="",Oh={class:"condition"};function Eh(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-input"),i=e.resolveComponent("menu-outlined"),c=e.resolveComponent("a-menu-item"),p=e.resolveComponent("a-menu"),u=e.resolveComponent("a-dropdown"),f=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",Oh,[e.createVNode(s,{class:"field-name",value:t.condition.rule,"onUpdate:value":o[0]||(o[0]=y=>t.condition.rule=y),options:t.ruleOptions,onChange:t.onRuleChange},null,8,["value","options","onChange"]),e.createVNode(d,{class:"field-value",value:t.condition.value,"onUpdate:value":o[1]||(o[1]=y=>t.condition.value=y),placeholder:"请输入值"},null,8,["value"]),e.createVNode(u,{trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.clickConditionMenu},{default:e.withCtx(()=>[e.createVNode(c,{key:"1"},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(c,{key:"2"},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(i,{class:"more-icon"})]),_:1}),e.createVNode(f,{class:"delete-icon",onClick:t.onDelete},null,8,["onClick"])])}const Bh=oe(Ah,[["render",Eh],["__scopeId","data-v-9fcdf54d"]]),Vh=e.defineComponent({name:"ConditionList",props:{list:{type:Array,default:()=>[]},level:{type:Number,default:0},path:{type:String,default:""}},components:{Condition:Bh}}),Xy="",Lh={key:0,class:"condition-list"},vh={key:0,class:"condition-container"},$h={key:0,class:"condition-text"},Fh={key:1,class:"condition-text"},Ih={class:"conditions"};function Dh(t,o,n,a,l,r){const s=e.resolveComponent("condition-list",!0),d=e.resolveComponent("condition");return Array.isArray(t.list)?(e.openBlock(),e.createElementBlock("div",Lh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.list,(i,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c},[i.join&&i.conditions&&Array.isArray(i.conditions)?(e.openBlock(),e.createElementBlock("div",vh,[i.conditions.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i.join==="||"?(e.openBlock(),e.createElementBlock("div",$h,"或")):e.createCommentVNode("",!0),i.join==="&&"?(e.openBlock(),e.createElementBlock("div",Fh,"且")):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createElementVNode("div",Ih,[i.conditions.length>0?(e.openBlock(),e.createBlock(s,{key:0,level:t.level+1,path:`${t.path?t.path+"-":""}${c}`,list:i.conditions},null,8,["level","path","list"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(d,{class:"condition",key:i.key||`${t.level}-${c}`,data:i,level:t.level,index:c,path:t.path||""},null,8,["data","level","index","path"]))],64))),128))])):e.createCommentVNode("",!0)}const Mh=oe(Vh,[["render",Dh],["__scopeId","data-v-49c6481f"]]),Ph=e.defineComponent({components:{ConditionList:Mh,PickColors:_t,AButton:j.Button,AModal:j.Modal,ASelect:j.Select},props:{data:{type:Object,default:()=>({})},index:{type:Number,default:-1}},setup(t,{emit:o,expose:n}){const a=e.ref(!1),l=e.ref([]),r=e.ref({}),s=e.computed(()=>({pageId:e.unref("pageId")})),d=b=>{const m=[];for(const w of b)w.conditions?m.push(...d(w.conditions)):m.push(w);return m},i=()=>{if(d(e.unref(l)).find(m=>!m.value||!m.rule)){j.message.error("条件值或规则不能为空");return}o("save",{conditions:e.unref(l),attribute:e.unref(r)}),a.value=!1},c=b=>{var m;for(const w of b)(m=w.conditions)!=null&&m.length?c(w.conditions):w.key=ge()};e.watch(a,b=>{var m,w,g;if(b){if(Array.isArray((m=t.data)==null?void 0:m.conditions)){const S=J.cloneDeep(((w=t.data)==null?void 0:w.conditions)||[]);c(S),l.value=S}r.value=J.cloneDeep(((g=t.data)==null?void 0:g.attribute)||{}),e.unref(r).color||(r.value.color=""),e.unref(r).iconColor||(r.value.iconColor="")}else l.value=[],r.value={}},{flush:"post"});const p=()=>{a.value=!0},u=b=>{var m;e.unref(l)==null||((m=e.unref(l))==null?void 0:m.length)===0?l.value=[{key:ge()}]:e.unref(l)[0]!=null&&(e.unref(l)[0].conditions==null||e.unref(l)[0].join!==b?l.value=[{join:b,conditions:[e.unref(l)[0],{key:ge()}]}]:e.unref(l)[0].conditions.length>1&&e.unref(l)[0].join===b&&l.value[0].conditions.push({key:ge()}))};e.provide(wo,{updateCondition(b,m,w){var C;let g=l.value;const S=w.split("-");if(w&&(S!=null&&S.length))for(const k of S)if(g[+k])g=(C=g[+k])==null?void 0:C.conditions;else break;Array.isArray(g)&&g[m]&&(g[m]=b)},deleteCondition(b,m){var S,C,k;if(!m){l.value=[];return}let w=e.unref(l);const g=m.split("-");if(g!=null&&g.length){for(const _ of g)if(w[+_])w=(S=w[+_])==null?void 0:S.conditions;else break;if(Array.isArray(w)&&w[b])if(w.splice(b,1),w.length===1){if(g.length>0){const _=g.length-1,E=g[_],O=g.slice(0,_);let B=e.unref(l),L="";for(const D of O)if(B[+D])L=(C=B[+D])==null?void 0:C.join,B=(k=B[+D])==null?void 0:k.conditions;else break;if(L===w[0].join){if(Array.isArray(w[0].conditions)){const D=J.cloneDeep(w[0].conditions);B.splice(+E,1),B.splice(+E,0,...D)}}else B[+E]=w[0]}}else w.length===0&&(l.value=[])}},addCondition(b,m,w){var k,_;let g=e.unref(l),S="";const C=b.split("-");if(b&&(C!=null&&C.length))for(const E of C)if(g[+E])S=(k=g[+E])==null?void 0:k.join,g=(_=g[+E])==null?void 0:_.conditions;else break;if(S===w)g.splice(m+1,0,{key:ge()});else{const E=J.cloneDeep(g[m]);g[m]={join:w,conditions:[E,{key:ge()}]}}}});const f=b=>{r.value.icon=b},y=e.computed(()=>window.config.imgBaseUrl),h=e.ref([{label:"向下箭头",value:"/static/img/indicator-icon/arrow-down.svg"},{label:"向上箭头",value:"/static/img/indicator-icon/arrow-up.svg"}]);return n({showModal:p}),{params:s,visible:a,conditionList:l,attribute:r,handleOk:i,addCondition:u,onUploadChange:f,imgBaseUrl:y,iconOptions:h}}}),Qy="",ra=t=>(e.pushScopeId("data-v-a29d848a"),t=t(),e.popScopeId(),t),jh={class:"config-wrap"},Rh={class:"wrap-item left"},Uh={class:"title"},zh={class:"border"},Gh={class:"wrap-item right"},Hh=ra(()=>e.createElementVNode("div",{class:"title"},"属性配置",-1)),Wh={class:"border"},Yh={class:"row"},qh=ra(()=>e.createElementVNode("div",null,"字体颜色:",-1)),Kh={class:"row"},Xh=ra(()=>e.createElementVNode("div",null,"图标:",-1)),Qh={style:{display:"flex","align-items":"center","justify-items":"center"}};function Jh(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("condition-list"),i=e.resolveComponent("pick-colors"),c=e.resolveComponent("a-select"),p=e.resolveComponent("a-modal");return e.openBlock(),e.createBlock(p,{width:"60%",visible:t.visible,"onUpdate:visible":o[6]||(o[6]=u=>t.visible=u),title:"条件设置",destroyOnClose:!0,maskClosable:!1,bodyStyle:{height:"500px",overflow:"auto"},onOk:t.handleOk},{default:e.withCtx(()=>[e.createElementVNode("div",jh,[e.createElementVNode("div",Rh,[e.createElementVNode("div",Uh,[e.createTextVNode(" 条件配置 "),Array.isArray(t.conditionList)&&t.conditionList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(s,{class:"add-and-condition",onClick:o[0]||(o[0]=u=>t.addCondition("&&"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加且条件 ")]),_:1}),e.createVNode(s,{class:"add-or-condition",onClick:o[1]||(o[1]=u=>t.addCondition("||"))},{default:e.withCtx(()=>[e.createTextVNode(" 添加或条件 ")]),_:1})],64)):(e.openBlock(),e.createBlock(s,{key:1,style:{"margin-left":"15px"},onClick:o[2]||(o[2]=u=>t.addCondition())},{default:e.withCtx(()=>[e.createTextVNode(" 添加条件 ")]),_:1}))]),e.createElementVNode("div",zh,[e.createVNode(d,{class:"condition-list",list:t.conditionList,level:0},null,8,["list"])])]),e.createElementVNode("div",Gh,[Hh,e.createElementVNode("div",Wh,[e.createElementVNode("div",Yh,[qh,e.createVNode(i,{class:"pick-colors",value:t.attribute.color,"onUpdate:value":o[3]||(o[3]=u=>t.attribute.color=u),size:25},null,8,["value"])]),e.createElementVNode("div",Kh,[Xh,e.createElementVNode("div",Qh,[e.createVNode(c,{value:t.attribute.icon,"onUpdate:value":o[4]||(o[4]=u=>t.attribute.icon=u),options:t.iconOptions,style:{width:"160px"}},null,8,["value","options"]),e.createVNode(i,{class:"pick-colors",value:t.attribute.iconColor,"onUpdate:value":o[5]||(o[5]=u=>t.attribute.iconColor=u),size:25},null,8,["value"])])])])])])]),_:1},8,["visible","onOk"])}const Zh=oe(Ph,[["render",Jh],["__scopeId","data-v-a29d848a"]]),eb=e.defineComponent({components:{AModal:j.Modal,AButton:j.Button,ATable:j.Table,ConditionWrap:Zh,AInput:j.Input},setup(t,{expose:o,emit:n}){console.log(t);const a=e.ref(!1),l=e.ref(),r=e.ref(),s=e.ref(0),d=[{title:"条件标题",dataIndex:"name",align:"center",ellipsis:!0,width:100},{title:"条件内容",dataIndex:"conditionCode",align:"center",ellipsis:!0,width:250},{title:"条件设置",dataIndex:"operation",ellipsis:!0,width:160}],i=e.ref([]),c=e.ref(),p=(w,g="")=>{let S="";return w.forEach((C,k)=>{const{value:_,rule:E}=C;C.conditions?S+=`(${p(C.conditions,C.join)})`:_&&E&&(S+=`value ${E} '${_}'`),S+=`${k===w.length-1?"":g?" "+g+" ":""}`}),S},u=w=>{i.value=[],c.value=w;const{rules:g,conditionCode:S,conditions:C,attribute:k}=w;if(g)i.value=J.cloneDeep(g);else if(S){const _={conditionCode:S,conditions:C,attribute:k,name:"新条件"};i.value.push(J.cloneDeep(_)),delete w.conditionCode,delete w.conditions,delete w.attribute}a.value=!0},f=()=>{a.value=!1;for(const w of i.value)if(w.conditionCode==="")return"不能条件为空!";n("confirm",e.unref(i))},y=()=>{i.value.push({conditionCode:"",name:"新条件",condition:[],attribute:{}})},h=w=>{w.conditionCode=p(w.conditions),Object.assign(i.value[s.value],w)},b=(w,g)=>{e.unref(l).showModal(),r.value=J.cloneDeep(w),s.value=g},m=w=>{i.value.splice(w,1)};return o({open:u}),{visible:a,currentData:r,currentIndex:s,configColumns:d,conditionsRef:l,rules:i,open:u,close:f,addRule:y,openRuleModal:b,closeRuleModal:h,deleteRule:m}}});function tb(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("a-input"),i=e.resolveComponent("a-table"),c=e.resolveComponent("a-modal"),p=e.resolveComponent("condition-wrap");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(c,{width:"60%",visible:t.visible,"onUpdate:visible":o[0]||(o[0]=u=>t.visible=u),title:"条件列表",destroyOnClose:!0,maskClosable:!1,bodyStyle:{height:"500px",overflow:"auto"},onOk:t.close},{default:e.withCtx(()=>[e.createVNode(s,{onClick:t.addRule},{default:e.withCtx(()=>[e.createTextVNode("新增条件")]),_:1},8,["onClick"]),e.createVNode(i,{class:"column-table",size:"small",columns:t.configColumns,"data-source":t.rules,scroll:{x:"100%",y:400},pagination:!1,bordered:""},{bodyCell:e.withCtx(({column:u,record:f,index:y})=>[u.dataIndex==="name"?(e.openBlock(),e.createBlock(d,{key:0,size:"small",value:f.name,"onUpdate:value":h=>f.name=h},null,8,["value","onUpdate:value"])):e.createCommentVNode("",!0),u.dataIndex==="operation"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(s,{size:"small",onClick:h=>t.openRuleModal(f,y)},{default:e.withCtx(()=>[e.createTextVNode("编辑")]),_:2},1032,["onClick"]),e.createVNode(s,{size:"small",onClick:h=>t.deleteRule(y),style:{"margin-left":"6px"}},{default:e.withCtx(()=>[e.createTextVNode("删除")]),_:2},1032,["onClick"])],64)):e.createCommentVNode("",!0)]),_:1},8,["columns","data-source"])]),_:1},8,["visible","onOk"]),e.createVNode(p,{ref:"conditionsRef",data:t.currentData,index:t.currentIndex,onSave:t.closeRuleModal},null,8,["data","index","onSave"])],64)}const ob=oe(eb,[["render",tb]]),nb=[{title:"列名",dataIndex:"label",fixed:"left",ellipsis:!0,width:135},{title:"参数",dataIndex:"label",fixed:"left",ellipsis:!0,width:135},{title:"列自定义",dataIndex:"style",align:"center",ellipsis:!0,width:100},{title:"列宽度(px/%)",dataIndex:"width",ellipsis:!0,width:135},{title:"列自定义函数",dataIndex:"renderText",ellipsis:!0,width:170},{title:"列表头自定义函数",dataIndex:"headerTemplate",ellipsis:!0,width:170},{title:"数据格式化",dataIndex:"dataFormat",ellipsis:!0,width:225},{title:"保留小数位数",dataIndex:"retentiondigit",ellipsis:!0,width:135},{title:"表头/表尾列对齐方式",dataIndex:"headerAlign",ellipsis:!0,width:170},{title:"内容列对齐方式",dataIndex:"align",ellipsis:!0,width:170},{title:"固定当前列",dataIndex:"fixed",ellipsis:!0,width:170},{title:"计算行",dataIndex:"calculateShow",ellipsis:!0,width:180},{title:"条件设置",dataIndex:"conditions",ellipsis:!0,width:120}],ab=e.defineComponent({name:"TableColumnConfig",components:{ATable:j.Table,AModal:j.Modal,ACheckbox:j.Checkbox,AInput:j.Input,AInputNumber:j.InputNumber,ASelect:j.Select,ASelectOption:j.SelectOption,Editor:Rr,CodeOutlined:us,ConditionsTable:ob},setup(){const t=e.inject(Ie),o=e.inject(Ce),n=e.computed(()=>{var C;return!!((C=e.unref(t))!=null&&C.isGroupTable)}),a=e.computed(()=>{var C;return((C=e.unref(t))==null?void 0:C.tableColumns)||[]}),l=e.ref([]);let r=null,s="";const d=e.ref(""),i=e.ref(""),c=e.ref(!1);e.watch(o,()=>{p()},{deep:!0,flush:"post"});const p=()=>{var k,_,E,O;let C=[];if(l.value=[],n.value){const B=((E=e.unref(o))==null?void 0:E.rowHeaderList)||[],L=((O=e.unref(o))==null?void 0:O.indicators)||[];C=[...B,...L]}else{const B=((k=e.unref(o))==null?void 0:k.queryColumnList)||[],L=((_=e.unref(o))==null?void 0:_.indicators)||[];C=[...B,...L]}console.log("columns",C,a),C.forEach(B=>{var D;let L=(D=e.unref(a))==null?void 0:D.find(I=>I.label===B.label);L||(L={label:B.label,prop:B.label,style:!1,width:"",renderText:"",headerTemplate:"",headerAlign:"left",align:"left",fixed:"",dataFormat:[],retentiondigit:null,calculateShow:{sum:!1,avg:!1},conditions:[],attribute:{}}),L.calculateShow||(L.calculateShow={sum:!1,avg:!1}),l.value.push(L)}),t.value.tableColumns=l.value};e.onMounted(()=>{p()});const u=(C,k)=>{C.style=k.target.checked,C.style?C.renderBool===void 0&&(C.renderBool=!1):delete C.renderBool},f=(C,k,_)=>{C&&k&&(r=C,s=k,d.value=C[k]||"",c.value=!0,i.value=_)},y=C=>{try{d.value=C}catch(k){console.error(k)}},h=()=>{r&&s&&(r[s]=d.value),d.value="",c.value=!1},b=e.ref(),m=e.ref(0),w=e.ref();return{configColumns:nb,configData:l,editorTitle:i,editorVisible:c,optionCode:d,handleOk:h,renderSave:f,onEditorChange:y,changeRenderBool:u,openConditions:C=>{m.value=C,b.value=l.value[C],e.unref(w).open(l.value[C])},confirmConditions:C=>{b.value.rules=C},conditionsTableRef:w}}}),Jy="",lb={class:"table-column-config"};function rb(t,o,n,a,l,r){const s=e.resolveComponent("a-checkbox"),d=e.resolveComponent("a-input"),i=e.resolveComponent("a-select-option"),c=e.resolveComponent("a-select"),p=e.resolveComponent("a-input-number"),u=e.resolveComponent("code-outlined"),f=e.resolveComponent("a-table"),y=e.resolveComponent("editor"),h=e.resolveComponent("a-modal"),b=e.resolveComponent("conditions-table");return e.openBlock(),e.createElementBlock("div",lb,[e.createVNode(f,{class:"column-table",columns:t.configColumns,"data-source":t.configData,scroll:{x:"100%",y:400},pagination:!1,bordered:""},{bodyCell:e.withCtx(({column:m,text:w,record:g,index:S})=>[m.dataIndex==="style"?(e.openBlock(),e.createBlock(s,{key:0,onChange:C=>t.changeRenderBool(g,C),checked:g.style},null,8,["onChange","checked"])):m.dataIndex==="width"?(e.openBlock(),e.createBlock(d,{key:1,value:g.width,"onUpdate:value":C=>g.width=C,valueModifiers:{trim:!0}},null,8,["value","onUpdate:value"])):m.dataIndex==="renderText"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[g.style?(e.openBlock(),e.createBlock(d,{key:1,value:g.renderText,"onUpdate:value":C=>g.renderText=C,readOnly:!0,onClick:C=>t.renderSave(g,"renderText","列自定义函数")},null,8,["value","onUpdate:value","onClick"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(w),1)],64))],64)):m.dataIndex==="headerTemplate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[g.style?(e.openBlock(),e.createBlock(d,{key:1,value:g.headerTemplate,"onUpdate:value":C=>g.headerTemplate=C,readOnly:!0,onClick:C=>t.renderSave(g,"headerTemplate","列表头自定义函数")},null,8,["value","onUpdate:value","onClick"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(w),1)],64))],64)):m.dataIndex==="headerAlign"?(e.openBlock(),e.createBlock(c,{key:4,style:{width:"100%"},size:"small",value:g.headerAlign,"onUpdate:value":C=>g.headerAlign=C},{default:e.withCtx(()=>[e.createVNode(i,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("左对齐")]),_:1}),e.createVNode(i,{value:"center"},{default:e.withCtx(()=>[e.createTextVNode("居中")]),_:1}),e.createVNode(i,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("右对齐")]),_:1})]),_:2},1032,["value","onUpdate:value"])):m.dataIndex==="align"?(e.openBlock(),e.createBlock(c,{key:5,style:{width:"100%"},size:"small",value:g.align,"onUpdate:value":C=>g.align=C},{default:e.withCtx(()=>[e.createVNode(i,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("左对齐")]),_:1}),e.createVNode(i,{value:"center"},{default:e.withCtx(()=>[e.createTextVNode("居中")]),_:1}),e.createVNode(i,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("右对齐")]),_:1})]),_:2},1032,["value","onUpdate:value"])):m.dataIndex==="fixed"?(e.openBlock(),e.createBlock(c,{key:6,style:{width:"100%"},size:"small",value:g.fixed,"onUpdate:value":C=>g.fixed=C},{default:e.withCtx(()=>[e.createVNode(i,{value:""},{default:e.withCtx(()=>[e.createTextVNode("不固定")]),_:1}),e.createVNode(i,{value:"left"},{default:e.withCtx(()=>[e.createTextVNode("靠左")]),_:1}),e.createVNode(i,{value:"right"},{default:e.withCtx(()=>[e.createTextVNode("靠右")]),_:1})]),_:2},1032,["value","onUpdate:value"])):m.dataIndex==="dataFormat"?(e.openBlock(),e.createBlock(c,{key:7,value:g.dataFormat,"onUpdate:value":C=>g.dataFormat=C,style:{width:"100%"},mode:"multiple",allowClear:"",maxTagCount:1},{default:e.withCtx(()=>[e.createVNode(i,{value:"#,000"},{default:e.withCtx(()=>[e.createTextVNode("千分位")]),_:1}),e.createVNode(i,{value:"#.00"},{default:e.withCtx(()=>[e.createTextVNode("保留小数")]),_:1}),e.createVNode(i,{value:"#"},{default:e.withCtx(()=>[e.createTextVNode("保留有效位")]),_:1})]),_:2},1032,["value","onUpdate:value"])):m.dataIndex==="retentiondigit"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[g.dataFormat&&g.dataFormat.includes("#.00")?(e.openBlock(),e.createBlock(p,{key:0,value:g.retentiondigit,"onUpdate:value":C=>g.retentiondigit=C,min:0,max:10},null,8,["value","onUpdate:value"])):e.createCommentVNode("",!0)],64)):m.dataIndex==="calculateShow"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:9},[e.createVNode(s,{checked:g.calculateShow.sum,"onUpdate:checked":C=>g.calculateShow.sum=C},{default:e.withCtx(()=>[e.createTextVNode("合计")]),_:2},1032,["checked","onUpdate:checked"]),e.createVNode(s,{checked:g.calculateShow.avg,"onUpdate:checked":C=>g.calculateShow.avg=C},{default:e.withCtx(()=>[e.createTextVNode("平均")]),_:2},1032,["checked","onUpdate:checked"])],64)):m.dataIndex==="conditions"?(e.openBlock(),e.createBlock(u,{key:10,class:"icon",onClick:e.withModifiers(C=>t.openConditions(S),["stop"])},null,8,["onClick"])):e.createCommentVNode("",!0)]),_:1},8,["columns","data-source"]),e.createVNode(h,{title:t.editorTitle,visible:t.editorVisible,"onUpdate:visible":o[0]||(o[0]=m=>t.editorVisible=m),"destroy-on-close":"",width:"700px",bodyStyle:{height:"500px",overflow:"auto"},centered:"",zIndex:1020,okText:"保存",cancelText:"取消",onOk:t.handleOk},{default:e.withCtx(()=>[e.createVNode(y,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.optionCode,onChange:t.onEditorChange},null,8,["valueData","onChange"])]),_:1},8,["title","visible","onOk"]),e.createVNode(b,{onConfirm:t.confirmConditions,ref:"conditionsTableRef"},null,8,["onConfirm"])])}const ib=oe(ab,[["render",rb],["__scopeId","data-v-bb095396"]]),sb=[{title:"列名",dataIndex:"label",fixed:"left",ellipsis:!0,width:135},{title:"参数",dataIndex:"label",fixed:"left",ellipsis:!0,width:135},{title:"数据格式化",dataIndex:"dataFormat",ellipsis:!0,width:225},{title:"保留小数位数",dataIndex:"retentiondigit",ellipsis:!0,width:135}],cb=e.defineComponent({name:"TableColumnConfig",components:{ATable:j.Table,AInputNumber:j.InputNumber,ASelect:j.Select,ASelectOption:j.SelectOption,ACollapse:j.Collapse,ACollapsePanel:j.CollapsePanel},setup(){const t=e.inject(Ie),o=e.inject(Ce),n=e.ref(["cardFormat"]),a=()=>{var c;const r=((c=e.unref(o))==null?void 0:c.indicators)||[],s=t.value.columnsConfigMap||{},d={dataFormat:[],retentiondigit:""},i=r.reduce((p,u)=>({...p,[u.label]:{...d,...s[u.label]||{}}}),{});t.value.columnsConfigMap=i};e.watch(o,()=>{a()},{deep:!0,flush:"post"}),e.onMounted(()=>{a()});const l=e.computed(()=>t.value.columnsConfigMap||{});return{selectedComponent:t,configColumns:sb,graphicConfig:o,columnsConfigMap:l,activePanel:n}}}),Zy="";function db(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-input-number"),c=e.resolveComponent("a-table"),p=e.resolveComponent("a-collapse-panel"),u=e.resolveComponent("a-collapse");return e.openBlock(),e.createBlock(u,{activeKey:t.activePanel,"onUpdate:activeKey":o[0]||(o[0]=f=>t.activePanel=f)},{default:e.withCtx(()=>[e.createVNode(p,{key:"cardFormat",header:"数据格式化"},{default:e.withCtx(()=>[e.createVNode(c,{class:"column-table",columns:t.configColumns,"data-source":t.graphicConfig.indicators||[],scroll:{x:"100%",y:400},pagination:!1,bordered:""},{bodyCell:e.withCtx(({column:f,record:y})=>[f.dataIndex==="dataFormat"&&t.columnsConfigMap[y.label]?(e.openBlock(),e.createBlock(d,{key:0,value:t.columnsConfigMap[y.label].dataFormat,"onUpdate:value":h=>t.columnsConfigMap[y.label].dataFormat=h,style:{width:"100%"},mode:"multiple",allowClear:"",maxTagCount:1},{default:e.withCtx(()=>[e.createVNode(s,{value:"#,000"},{default:e.withCtx(()=>[e.createTextVNode("千分位")]),_:1}),e.createVNode(s,{value:"#.00"},{default:e.withCtx(()=>[e.createTextVNode("保留小数")]),_:1}),e.createVNode(s,{value:"#"},{default:e.withCtx(()=>[e.createTextVNode("保留有效位")]),_:1})]),_:2},1032,["value","onUpdate:value"])):f.dataIndex==="retentiondigit"&&t.columnsConfigMap[y.label]?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[t.columnsConfigMap[y.label].dataFormat&&t.columnsConfigMap[y.label].dataFormat.includes("#.00")?(e.openBlock(),e.createBlock(i,{key:0,value:t.columnsConfigMap[y.label].retentiondigit,"onUpdate:value":h=>t.columnsConfigMap[y.label].retentiondigit=h,min:0,max:10},null,8,["value","onUpdate:value"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)]),_:1},8,["columns","data-source"])]),_:1})]),_:1},8,["activeKey"])}const pb=oe(cb,[["render",db],["__scopeId","data-v-72761110"]]),ub=e.defineComponent({name:"StyleConfigGroup",props:{componentType:{type:String,default:""},isGroupTable:{type:Boolean,default:!1}},components:{PropsToForm:wh,TableColumnConfig:ib,Editor:Rr,AFormItem:j.FormItem,ASelect:j.Select,ASelectOption:j.SelectOption,ACollapse:j.Collapse,ACollapsePanel:j.CollapsePanel,ASwitch:j.Switch,IndicatorContainer:pb},setup(t){const o=e.ref([]),n=e.ref(["表格"]),a=e.inject(Co),l=e.inject(pa),r=e.inject(Yo),s=e.inject(qo),d=e.inject(da),i=e.inject(Ie),c=_=>{r({...Ko[_]},!1),e.unref(i).type=e.unref(p),d()},p=e.computed(()=>{var _;return(_=e.unref(a))==null?void 0:_.type}),u=["showTotalBool","totalName","expandAll"],f=e.computed(()=>df.map(_=>{const{props:E,title:O,enableProps:B,onlyType:L,excludeType:D}=_,I=[];E.forEach(V=>{typeof V=="string"&&(u.includes(V)?t.isGroupTable&&I.push(V):I.push(V))});let $,x;return t.componentType==="table"&&(L!=null&&L.includes(t.componentType))?($=typeof B=="string"&&l.value?l.value[B]:void 0,x=J.pick(e.unref(l),I)):($=typeof B=="string"&&a.value?a.value[B]:void 0,x=J.pick(e.unref(a),I)),{title:O,enableProps:$,enablePropsName:B,onlyType:L,excludeType:D,props:x}}).filter(({props:_})=>Object.keys(_).length>0)),y=(_,E)=>{const{onlyType:O,excludeType:B}=_;return O==null&&B==null?!0:O?we(E,O):B?!we(E,B):!1},h=(_,E)=>(E==null||E.stopPropagation(),_),b=(_,E)=>{E!=null&&r({[E]:_})},m=e.computed(()=>JSON.stringify(e.unref(a),null,2)),w=_=>{try{const E=JSON.parse(_||"{}");r(E,!1)}catch(E){console.error(E)}},g=e.ref(""),S=_=>{try{g.value=_}catch(E){console.error(E)}},C=(_,E)=>{try{s({[E]:_})}catch(O){console.error(O)}},k=e.computed(()=>{var _;return["customGraph"].includes((_=e.unref(a))==null?void 0:_.type)});return{type:p,handleChangeType:c,activePanel:o,tablePanel:n,ComponentString:m,updateComponentOptions:w,tableOptions:l,optionCode:g,onEditorChange:S,tableEditorChange:C,onSwitchClick:h,onSwitchChange:b,detailPropsGroups:f,isRenderForm:y,isShowOptionEditor:k}}}),eg="",tg="",fb={class:"style-group"};function mb(t,o,n,a,l,r){const s=e.resolveComponent("a-select-option"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-form-item"),c=e.resolveComponent("a-switch"),p=e.resolveComponent("props-to-form"),u=e.resolveComponent("a-collapse-panel"),f=e.resolveComponent("editor"),y=e.resolveComponent("a-collapse"),h=e.resolveComponent("table-column-config"),b=e.resolveComponent("indicator-container");return e.openBlock(),e.createElementBlock("div",fb,[t.componentType!=="table"&&t.componentType!=="card"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(i,{label:"图表类型"},{default:e.withCtx(()=>[e.createVNode(d,{value:t.type,"onUpdate:value":o[0]||(o[0]=m=>t.type=m),style:{width:"100%"},onChange:t.handleChangeType},{default:e.withCtx(()=>[e.createVNode(s,{value:"line"},{default:e.withCtx(()=>[e.createTextVNode("折线图")]),_:1}),e.createVNode(s,{value:"bar"},{default:e.withCtx(()=>[e.createTextVNode("柱状图")]),_:1}),e.createVNode(s,{value:"pie"},{default:e.withCtx(()=>[e.createTextVNode("饼图")]),_:1}),e.createVNode(s,{value:"comboGraph"},{default:e.withCtx(()=>[e.createTextVNode("组合图表")]),_:1}),e.createVNode(s,{value:"customGraph"},{default:e.withCtx(()=>[e.createTextVNode("自定义图表")]),_:1})]),_:1},8,["value","onChange"])]),_:1}),e.createVNode(y,{activeKey:t.activePanel,"onUpdate:activeKey":o[1]||(o[1]=m=>t.activePanel=m)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.detailPropsGroups,m=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m.title},[t.isRenderForm(m,t.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[m.title?(e.openBlock(),e.createBlock(u,{header:m.title,key:m.title},{extra:e.withCtx(()=>[typeof m.enableProps=="boolean"?(e.openBlock(),e.createBlock(c,{key:0,checked:m.enableProps,onChange:w=>t.onSwitchChange(w,m.enablePropsName),onClick:t.onSwitchClick},null,8,["checked","onChange","onClick"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[e.createVNode(p,{props:m.props,disabled:typeof m.enableProps=="boolean"?!m.enableProps:!1},null,8,["props","disabled"])]),_:2},1032,["header"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],64))),128)),t.isShowOptionEditor?(e.openBlock(),e.createBlock(u,{key:"custom-option",header:"自定义option配置"},{default:e.withCtx(()=>[e.createVNode(f,{class:"option-editor",language:"typescript",valueData:t.optionCode,onChange:t.onEditorChange},null,8,["valueData","onChange"])]),_:1})):e.createCommentVNode("",!0)]),_:1},8,["activeKey"])],64)):e.createCommentVNode("",!0),t.componentType==="table"?(e.openBlock(),e.createBlock(y,{key:1,activeKey:t.tablePanel,"onUpdate:activeKey":o[4]||(o[4]=m=>t.tablePanel=m)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.detailPropsGroups,m=>{var w;return e.openBlock(),e.createElementBlock(e.Fragment,{key:m.title},[m.title&&((w=m.onlyType)!=null&&w.includes(t.componentType))?(e.openBlock(),e.createBlock(u,{header:m.title,key:m.title},{default:e.withCtx(()=>[e.createVNode(p,{componentType:t.componentType,props:m.props,disabled:typeof m.enableProps=="boolean"?!m.enableProps:!1},null,8,["componentType","props","disabled"])]),_:2},1032,["header"])):e.createCommentVNode("",!0)],64)}),128)),e.createVNode(u,{key:"tableColumn",header:"表格列配置"},{default:e.withCtx(()=>[e.createVNode(h)]),_:1}),e.createVNode(u,{key:"headerCellStyleMethod",header:"表头单元格样式"},{default:e.withCtx(()=>[e.createVNode(f,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.tableOptions.headerCellStyleMethod,onChange:o[2]||(o[2]=m=>t.tableEditorChange(m,"headerCellStyleMethod"))},null,8,["valueData"])]),_:1}),e.createVNode(u,{key:"rowStyleMethod",header:"行样式"},{default:e.withCtx(()=>[e.createVNode(f,{class:"option-editor",language:"javascript",options:{fontSize:16,lineHeight:18},valueData:t.tableOptions.rowStyleMethod,onChange:o[3]||(o[3]=m=>t.tableEditorChange(m,"rowStyleMethod"))},null,8,["valueData"])]),_:1})]),_:1},8,["activeKey"])):e.createCommentVNode("",!0),t.componentType==="card"?(e.openBlock(),e.createBlock(b,{key:2})):e.createCommentVNode("",!0)])}const hb=oe(ub,[["render",mb],["__scopeId","data-v-9a2fa8f5"]]),bb=e.defineComponent({name:"Card",components:{CloseOutlined:Xt,AInput:j.Input,ASelect:j.Select,MenuOutlined:kn,ADropdown:j.Dropdown,AMenu:j.Menu,AMenuItem:j.MenuItem},props:{index:{type:Number,require:!0},control:{type:Object,default:()=>({})},intersection:{type:Array,default:()=>[]},path:{type:String,default:""}},emits:["delete","update"],setup(t){const o=e.inject(Ue),n=e.inject(ko),a=e.inject(fa),{onUpdateControl:l,onDeleteControl:r,onAddMenuControl:s}=e.inject("CHANGE_CONTROL",{onUpdateControl:A=>{},onDeleteControl:A=>{},onAddMenuControl:(A,F,M)=>{}}),d=e.computed(()=>{var A;return(A=e.unref(o))==null?void 0:A.filter(F=>F.keyName!=="")}),i=e.computed(()=>[{keyName:"父页面",id:"PARENT"},...e.unref(d)]),c=e.computed(()=>{var M,G;const A=[],F=(M=e.unref(d))==null?void 0:M.find(W=>{var X;return W.id===((X=t.control)==null?void 0:X.id)});if(F){const W=F.type,X=J.pick(F,["value","startTime","endTime"]);(G=Object.keys(X))!=null&&G.length||(X.value="");for(const Q in X)if(Object.prototype.hasOwnProperty.call(X,Q)){const Z=e.unref(a)[Q];if(Array.isArray(Z)){const ae=Z.find(le=>we(W,le.onlyType));ae&&A.push({label:ae.label,value:Q})}else A.push({label:Z.label,value:Q})}}return A}),p=()=>{r({index:t.index,path:t.path}),f(t.control.id)},u=({key:A})=>{s(t.path,t.index,A==="2"?"||":"&&")};function f(A){const F=e.unref(d).find(M=>M.id===A);if(F){const{type:M,id:G,events:W=[]}=F,X=Bo(M),Q=W.findIndex(Z=>{var ae;return Z.on===X&&Z.target===((ae=e.unref(_))==null?void 0:ae.id)&&Z.emit==="refreshData"});Q!==-1&&(W.splice(Q,1),n({id:G,events:W}))}}const y=A=>{const F={...t.control};if(F.id=A,F.customValue="",A){const M=e.unref(d).find(G=>G.id===A);M&&(F.keyName=M.keyName,B(M,A))}delete F.prop,l({control:F,index:t.index,path:t.path})},h=e.ref(""),b=()=>{h.value=t.control.id},m=A=>{l({control:{...t.control,prop:A},index:t.index,path:t.path})},w=A=>{l({control:{...t.control,prop:A.target.value},index:t.index,path:t.path})},g=A=>{l({control:{...t.control,rule:A},index:t.index,path:t.path})},S=A=>{const F={...t.control};F.modelKey&&(F.modelKey=""),F.prop&&(F.prop=""),F.format&&(F.format=""),l({control:{...F,dataType:A,customValue:"",id:"",keyName:""},index:t.index,path:t.path})},C=A=>{l({control:{...t.control,customValue:A.target.value},index:t.index,path:t.path})},k=A=>{const F={...t.control};A==null?delete F.mode:F.mode=A,delete F.conditionLabel,delete F.conditionName,delete F.conditionKey,delete F.conditionValueType,l({control:F,index:t.index,path:t.path})},_=e.inject(Ie),E=e.inject(Ce),O=e.computed(()=>{var Xe;const{classificationList:A=[],seriesList:F=[],leftAxisList:M=[],rightAxisList:G=[],indicators:W=[],rowHeaderList:X=[],queryColumnList:Q=[]}=e.unref(E),Z=J.cloneDeep([...A,...F,...M,...G,...W,...X,...Q]);if(Z!=null&&Z.length)for(const pe of Z)pe.id=pe.name;const ae=[{label:"日期",name:"日期",id:"the_date",genericType:"DATE",typeGuid:"the_date",indexCode:null},{label:"HRP单位编号",name:"HRP单位编号",id:"hbdwbh",genericType:"TEXT",typeGuid:"hbdwbh",indexCode:null},{label:"HRP单位名称",name:"HRP单位名称",id:"hbdwbh_name",genericType:"TEXT",typeGuid:"hbdwbh_name",indexCode:null},...t.intersection.map(pe=>({...pe,id:pe.name,label:pe.title||pe.label})),...Z];if(((Xe=e.unref(_))==null?void 0:Xe.type)==="ecanSelect"){const{selectFieldOptions:pe=[]}=e.unref(E);if(ae.unshift({label:"上级编码",name:"上级编码",id:"parentCode",genericType:"TEXT"}),pe!=null&&pe.length)for(const Oe of pe)ae.unshift({label:Oe.label,name:Oe.value,id:Oe.value,genericType:"TEXT"})}const le=new Map,_e=ae.length;for(let pe=0;pe<_e;pe++){const Oe=ae[pe],{id:ut}=Oe||{};le.set(ut,Oe)}return[...le].map(([pe,Oe])=>Oe)});function B(A,F){var Q,Z;const{type:M,id:G,events:W=[]}=A,X=Bo(M);e.unref(h)&&F!==e.unref(h)&&(dt(((Q=e.unref(E))==null?void 0:Q.controlList)||[]).find(le=>le.id===e.unref(h))||f(e.unref(h))),W.find(ae=>{var le;return ae.on===X&&ae.target===((le=e.unref(_))==null?void 0:le.id)&&ae.emit==="refreshData"})||n({id:G,events:[...W,{on:X,target:(Z=e.unref(_))==null?void 0:Z.id,emit:"refreshData"}].reverse()})}const L=(A,F)=>{if(A){const{label:M,name:G,id:W,genericType:X,indexCode:Q,typeGuid:Z,indexCodeNum:ae}=F||{},le={...t.control,conditionKey:W,conditionLabel:M,conditionName:G,conditionValueType:X,indexCode:Q,typeGuid:Z,indexCodeNum:ae};We(le,"rule")||(le.rule="EQUAL"),We(le,"dataType")||(le.dataType="component"),l({control:le,index:t.index,path:t.path})}else{const M={...t.control};delete M.conditionLabel,delete M.conditionName,delete M.conditionKey,delete M.conditionValueType,l({control:M,index:t.index,path:t.path})}},D=(A,F)=>{var M;return(M=F==null?void 0:F.keyName)==null?void 0:M.toLowerCase().includes(A==null?void 0:A.toLowerCase())},I=(A,F)=>{var M;return(M=F==null?void 0:F.label)==null?void 0:M.toLowerCase().includes(A==null?void 0:A.toLowerCase())},$=e.computed(()=>{const A=e.unref(O).find(M=>M.id===t.control.conditionKey);let F="";return A&&(F=(A==null?void 0:A.genericType)||""),F==="TEXT"||F==="0"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"包含",value:"LIKE"},{label:"不包含",value:"NOT_LIKE"},{label:"开头是",value:"LIKE%"},{label:"结尾是",value:"%LIKE"},{label:"等于",value:"EQUAL"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"}]:F==="NUMBER"||F==="1"?[{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:F==="DATE"||F==="2"?[{label:"属于",value:"IN"},{label:"不属于",value:"NOT_IN"},{label:"小于",value:"LESS"},{label:"小于等于",value:"LESS_EQUAL"},{label:"大于",value:"GREATER"},{label:"大于等于",value:"GREATER_EQUAL"},{label:"等于",value:"EQUAL"},{label:"不等于",value:"NOT_EQUAL"}]:[]}),x=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],V=e.computed(()=>{let A=!1;const{id:F="",dataType:M="component"}=t.control;if(F&&M==="component"){const G=e.unref(d).find(X=>X.id===F),W=["table","bar","combograph","line","pie","radar","scatter","list","circulate"];we(G==null?void 0:G.type,W)&&(A=!0)}return F==="PARENT"&&(A=!0),A}),T=e.computed(()=>{let A=!1;const{id:F="",dataType:M="component"}=t.control;if(F&&M==="component"){const G=e.unref(d).find(W=>W.id===F);(G==null?void 0:G.type)==="ecanRangePicker"&&(A=!0)}return F==="PARENT"&&(A=!0),A}),P=e.computed(()=>{let A=!1;const{id:F="",dataType:M="component"}=t.control;if(F&&M==="component"){const G=e.unref(d).find(W=>W.id===F);["ecanDatePicker","ecanRangePicker"].includes(G==null?void 0:G.type)&&(A=!0)}return A});return{propOptions:c,usedComponentList:d,onDelete:p,onIdChange:y,onIdFocus:b,onPropChange:m,onParentPropChange:w,onModeChange:k,onRuleChange:g,onDataTypeChange:S,onCustomValueChange:C,conditionKeyOptions:O,onConditionKeyChange:L,idFilterOption:D,filterOption:I,onFormatChange:A=>{l({control:{...t.control,format:A},index:t.index,path:t.path})},onModelPropChange:A=>{l({control:{...t.control,modelKey:A.target.value},index:t.index,path:t.path})},clickConditionMenu:u,ruleOption:$,dataTypeOption:x,isShowProp:T,isShowFormat:P,isShowModelProp:V,formatOptions:[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}],keyNameOptions:i}}}),og="",ng="",yb={class:"control-card"};function gb(t,o,n,a,l,r){const s=e.resolveComponent("a-select"),d=e.resolveComponent("a-input"),i=e.resolveComponent("menu-outlined"),c=e.resolveComponent("a-menu-item"),p=e.resolveComponent("a-menu"),u=e.resolveComponent("a-dropdown"),f=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",yb,[e.createVNode(s,{class:"field-name",value:t.control.conditionKey,options:t.conditionKeyOptions,fieldNames:{value:"id"},"allow-clear":"","show-search":"",onChange:t.onConditionKeyChange,"filter-option":t.filterOption},null,8,["value","options","onChange","filter-option"]),e.createVNode(s,{class:"field-name",value:t.control.rule,options:t.ruleOption,style:{"max-width":"100px"},onChange:t.onRuleChange},null,8,["value","options","onChange"]),e.createVNode(s,{class:"field-name",value:t.control.dataType,options:t.dataTypeOption,style:{"max-width":"100px"},onChange:t.onDataTypeChange},null,8,["value","options","onChange"]),t.control.dataType===""?(e.openBlock(),e.createBlock(d,{key:0,class:"field-name",value:t.control.customValue,style:{"max-width":"180px"},onInput:t.onCustomValueChange},null,8,["value","onInput"])):e.createCommentVNode("",!0),t.control.dataType==="component"?(e.openBlock(),e.createBlock(s,{key:1,class:"field-name",value:t.control.id,options:t.keyNameOptions,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption,style:{"max-width":"180px"},onChange:t.onIdChange,onClick:t.onIdFocus},null,8,["value","options","filter-option","onChange","onClick"])):e.createCommentVNode("",!0),t.isShowModelProp?(e.openBlock(),e.createBlock(d,{key:2,class:"field-name",value:t.control.modelKey,onInput:t.onModelPropChange,placeholder:t.control.id==="PARENT"?"请输入组件别名":""},null,8,["value","onInput","placeholder"])):e.createCommentVNode("",!0),t.isShowProp?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.control.id==="PARENT"?(e.openBlock(),e.createBlock(d,{key:0,class:"field-name",value:t.control.prop,onInput:t.onParentPropChange,placeholder:"请输入属性名"},null,8,["value","onInput"])):(e.openBlock(),e.createBlock(s,{key:1,class:"field-name",value:t.control.prop,options:t.propOptions,onChange:t.onPropChange},null,8,["value","options","onChange"]))],64)):e.createCommentVNode("",!0),t.isShowFormat?(e.openBlock(),e.createBlock(s,{key:4,class:"field-name",value:t.control.format,options:t.formatOptions,onChange:t.onFormatChange},null,8,["value","options","onChange"])):e.createCommentVNode("",!0),e.createVNode(u,{trigger:["click"]},{overlay:e.withCtx(()=>[e.createVNode(p,{onClick:t.clickConditionMenu},{default:e.withCtx(()=>[e.createVNode(c,{key:"1"},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(c,{key:"2"},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(i,{class:"more-icon"})]),_:1}),e.createVNode(f,{class:"delete-icon",onClick:t.onDelete},null,8,["onClick"])])}const Cb=oe(bb,[["render",gb],["__scopeId","data-v-b5a81113"]]),wb=e.defineComponent({name:"ControlList",props:{list:{type:Array,default:()=>[]},level:{type:Number,default:0},path:{type:String,default:""},intersection:{type:Array,default:()=>[]}},components:{ControlCard:Cb}}),ag="",kb={key:0,class:"condition-list"},xb={key:0,class:"condition-container"},_b={key:0,class:"condition-text"},Sb={key:1,class:"condition-text"},Nb={class:"conditions"};function Tb(t,o,n,a,l,r){const s=e.resolveComponent("control-list",!0),d=e.resolveComponent("control-card");return Array.isArray(t.list)?(e.openBlock(),e.createElementBlock("div",kb,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.list,(i,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c},[i.join&&i.conditions&&Array.isArray(i.conditions)?(e.openBlock(),e.createElementBlock("div",xb,[i.conditions.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i.join==="||"?(e.openBlock(),e.createElementBlock("div",_b,"或")):e.createCommentVNode("",!0),i.join==="&&"?(e.openBlock(),e.createElementBlock("div",Sb,"且")):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createElementVNode("div",Nb,[i.conditions.length>0?(e.openBlock(),e.createBlock(s,{key:0,level:t.level+1,path:`${t.path?t.path+"-":""}${c}`,list:i.conditions,intersection:t.intersection},null,8,["level","path","list","intersection"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(d,{class:"condition",key:i.keyValue||`${t.level}-${c}`,control:i,index:c,path:t.path||"",intersection:t.intersection},null,8,["control","index","path","intersection"]))],64))),128))])):e.createCommentVNode("",!0)}const Ab=oe(wb,[["render",Tb],["__scopeId","data-v-916ff9bd"]]),Ob=e.defineComponent({name:"ControlGroup",props:{intersection:{type:Array,default:()=>[]}},components:{ControlList:Ab,AButton:j.Button},setup(){const t=e.inject(Ue),o=e.inject(Ce),n=e.inject(Ne),a=e.computed(()=>{var u,f;const p=((u=e.unref(o))==null?void 0:u.controlList)||[];for(const y of p)y.conditionKey&&(We(y,"rule")||(y.prop==="startTime"?y.rule="GREATER_EQUAL":y.prop==="endTime"?y.rule="LESS_EQUAL":y.rule="EQUAL"),We(y,"dataType")||(y.dataType="component"));return(p==null?void 0:p.length)>1&&!((f=p[0])!=null&&f.join)?[{join:"&&",conditions:p}]:p}),l=e.ref(null),r=p=>{const u={...e.unref(o),...p,sqlConditions:Gl({...e.unref(o),...p},e.unref(t))};n(u)},s=p=>{var f;const u=(f=e.unref(a))==null?void 0:f.slice();u==null||(u==null?void 0:u.length)===0?r({controlList:[{keyValue:ge()}]}):u[0]!=null&&(u[0].conditions==null||u[0].join!==p?r({controlList:[{join:p,conditions:[u[0],{keyValue:ge()}]}]}):u[0].conditions.length>1&&u[0].join===p&&(u[0].conditions.push({keyValue:ge()}),r({controlList:u})))},d=p=>{var m,w,g,S;const{index:u,path:f}=p;let y=J.cloneDeep((m=e.unref(a))==null?void 0:m.slice()),h=y;const b=f.split("-");if(b!=null&&b.length){for(const C of b)if(h[C])h=(w=h[C])==null?void 0:w.conditions;else break;if(Array.isArray(h)&&h[u])if(h.splice(u,1),h.length===1){if(b.length>0){const C=b.length-1,k=b[C],_=b.slice(0,C);let E=y,O="";for(const B of _)if(E[B])O=(g=E[B])==null?void 0:g.join,E=(S=E[B])==null?void 0:S.conditions;else break;if(O===h[0].join){if(Array.isArray(h[0].conditions)){const B=J.cloneDeep(h[0].conditions);E.splice(+k,1),E.splice(+k,0,...B)}}else E[k]=h[0]}}else h.length===0&&(y=[]);r({controlList:y})}},i=p=>{var w,g;const{control:u,index:f,path:y}=p,h=J.cloneDeep((w=e.unref(a))==null?void 0:w.slice());let b=h;const m=y.split("-");if(m!=null&&m.length)for(const S of m)if(b[S])b=(g=b[S])==null?void 0:g.conditions;else break;Array.isArray(b)&&b[f]&&(b[f]=u),r({controlList:h})},c=(p,u,f)=>{var w,g,S;const y=J.cloneDeep((w=e.unref(a))==null?void 0:w.slice());let h=y,b="";const m=p.split("-");if(m!=null&&m.length){for(const C of m)if(h[C])b=(g=h[C])==null?void 0:g.join,h=(S=h[C])==null?void 0:S.conditions;else break;if(b===f)h.splice(u+1,0,{keyValue:ge()});else{const C=J.cloneDeep(h[u]);h[u]={join:f,conditions:[C,{keyValue:ge()}]}}r({controlList:y})}};return e.provide("CHANGE_CONTROL",{onDeleteControl:d,onUpdateControl:i,onAddMenuControl:c}),{controlList:a,bindComponentId:l,onAddControl:s}}}),lg="",Eb={class:"control-group"},Bb={class:"control-group-header"},Vb={class:"control-group-content"};function Lb(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("control-list");return e.openBlock(),e.createElementBlock("div",Eb,[e.createElementVNode("div",Bb,[Array.isArray(t.controlList)&&t.controlList.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(s,{onClick:o[0]||(o[0]=i=>t.onAddControl("&&"))},{default:e.withCtx(()=>[e.createTextVNode("添加且条件")]),_:1}),e.createVNode(s,{onClick:o[1]||(o[1]=i=>t.onAddControl("||")),style:{"margin-left":"15px"}},{default:e.withCtx(()=>[e.createTextVNode("添加或条件")]),_:1})],64)):(e.openBlock(),e.createBlock(s,{key:1,onClick:o[2]||(o[2]=i=>t.onAddControl())},{default:e.withCtx(()=>[e.createTextVNode("添加条件")]),_:1}))]),e.createElementVNode("div",Vb,[e.createVNode(d,{class:"condition-list",list:t.controlList,level:0,intersection:t.intersection},null,8,["list","intersection"])])])}const vb=oe(Ob,[["render",Lb],["__scopeId","data-v-69806ab9"]]),$b=e.defineComponent({name:"VariableCard",props:{item:{type:Object,default:()=>({})},index:{type:Number,require:!0},label:String},components:{CloseOutlined:Xt,AppstoreAddOutlined:cn,ASelect:j.Select,ASelectOption:j.SelectOption,AInput:j.Input,APopover:j.Popover,ATabs:j.Tabs,ATabPane:j.TabPane,AInputNumber:j.InputNumber},setup(t,{emit:o}){const n=e.ref(!1),a=e.inject(Ue),l=e.computed(()=>{var C;return(C=e.unref(a))==null?void 0:C.filter(k=>k.keyName!=="")}),r=[{label:"TEXT",value:"TEXT"},{label:"NUMBER",value:"NUMBER"},{label:"DATE",value:"DATE"}],s=[{label:"自定义值",value:""},{label:"组件值",value:"component"}],d=[{label:"间隔值",value:"rangeValue"},{label:"开始时间",value:"startTime"},{label:"结束时间",value:"endTime"}],i=e.ref(J.cloneDeep(t.item));e.watch(i,C=>{o("update",{...C,label:t.label},t.index)},{deep:!0});const c=e.computed(()=>{var k;let C=null;if(((k=e.unref(i))==null?void 0:k.dataType)==="component"){const _=e.unref(l).find(E=>{var O;return E.id===((O=e.unref(i))==null?void 0:O.id)});_&&(C=_)}return C}),p=e.computed(()=>{var k;let C=!1;return((k=e.unref(i))==null?void 0:k.variableType)==="DATE"&&(C=!0),C}),u=e.computed(()=>{let C=!1;return e.unref(c)&&(C=we(e.unref(c).type,"range")),C}),f=e.computed(()=>{let C=!1;return e.unref(c)&&(we(e.unref(c).type,"range")?["startTime","endTime"].includes(e.unref(i).dateTypeValue)&&(C=!0):we(e.unref(c).type,"date")&&(C=!0)),C}),y=(C,k)=>{C&&(e.unref(i).keyName=k.keyName)},h=()=>{o("delete",t.index)},b=e.computed(()=>e.unref(p)?[{label:"年",value:"YYYY"},{label:"年月",value:"YYYY-MM"},{label:"年月日",value:"YYYY-MM-DD"},{label:"年月日时",value:"YYYY-MM-DD HH"},{label:"年月日时分",value:"YYYY-MM-DD HH:mm"},{label:"年月日时分秒",value:"YYYY-MM-DD HH:mm:ss"}]:[]),m=()=>{e.unref(i).id=null,e.unref(i).keyName="",e.unref(i).dateTypeValue=null,e.unref(i).variableValue=""},w=()=>{e.unref(i).format=null},g=(C,k)=>{var _;return(_=k==null?void 0:k.keyName)==null?void 0:_.toLowerCase().includes(C==null?void 0:C.toLowerCase())};return e.watch(f,C=>{C&&(e.unref(i).operateType||(e.unref(i).operateType="add"),e.unref(i).operateMode||(e.unref(i).operateMode="year"),e.unref(i).operateValue||(e.unref(i).operateValue=0),e.unref(i).activeOperateKey||(e.unref(i).activeOperateKey=1))},{immediate:!0}),{variableData:i,typeOption:r,dataTypeOption:s,usedComponentList:l,formatOptions:b,rangeTypeOptions:d,isShowFormat:p,isDateRangeComponent:u,isShowDateOperate:f,popoverVisible:n,idFilterOption:g,onChangeComponent:y,onDelete:h,onChangeDataType:m,onChangeVariableType:w,changeTab:C=>{e.unref(i).activeOperateKey=C,C===1?e.unref(i).operateValue=0:C===2&&(e.unref(i).operateValue="rangeValue")}}}}),rg="",Fb={class:"variable-item"},Ib=["title"],Db={class:"popover-content-wrap"},Mb={style:{display:"flex"}};function Pb(t,o,n,a,l,r){const s=e.resolveComponent("a-input"),d=e.resolveComponent("a-select"),i=e.resolveComponent("a-select-option"),c=e.resolveComponent("a-input-number"),p=e.resolveComponent("a-tab-pane"),u=e.resolveComponent("a-tabs"),f=e.resolveComponent("appstore-add-outlined"),y=e.resolveComponent("a-popover"),h=e.resolveComponent("close-outlined");return e.openBlock(),e.createElementBlock("div",Fb,[t.variableData.randomKey?(e.openBlock(),e.createElementBlock("div",{key:0,class:"var-indicator",title:t.label},e.toDisplayString(t.label),9,Ib)):e.createCommentVNode("",!0),e.createVNode(s,{class:"field-name",value:t.variableData.variableName,"onUpdate:value":o[0]||(o[0]=b=>t.variableData.variableName=b),placeholder:"请输入变量名",disabled:!!t.variableData.randomKey},null,8,["value","disabled"]),e.createVNode(d,{class:"field-name",value:t.variableData.variableType,"onUpdate:value":o[1]||(o[1]=b=>t.variableData.variableType=b),options:t.typeOption,disabled:t.variableData.disabled,style:{"max-width":"120px"},placeholder:"请选择变量类型",onChange:t.onChangeVariableType},null,8,["value","options","disabled","onChange"]),e.createVNode(d,{class:"field-name",value:t.variableData.dataType,"onUpdate:value":o[2]||(o[2]=b=>t.variableData.dataType=b),options:t.dataTypeOption,style:{"max-width":"120px"},onChange:t.onChangeDataType},null,8,["value","options","onChange"]),t.variableData.dataType==="component"?(e.openBlock(),e.createBlock(d,{key:1,class:"field-name",value:t.variableData.id,"onUpdate:value":o[3]||(o[3]=b=>t.variableData.id=b),options:t.usedComponentList,fieldNames:{label:"keyName",value:"id"},"show-search":"","filter-option":t.idFilterOption,style:{"max-width":"180px"},placeholder:"请选择组件",onChange:t.onChangeComponent},null,8,["value","options","filter-option","onChange"])):(e.openBlock(),e.createBlock(s,{key:2,class:"field-name",style:{"max-width":"180px"},value:t.variableData.variableValue,"onUpdate:value":o[4]||(o[4]=b=>t.variableData.variableValue=b),placeholder:"请输入变量值"},null,8,["value"])),t.isDateRangeComponent?(e.openBlock(),e.createBlock(d,{key:3,class:"field-name",value:t.variableData.dateTypeValue,"onUpdate:value":o[5]||(o[5]=b=>t.variableData.dateTypeValue=b),options:t.rangeTypeOptions,placeholder:"请选择取值类型"},null,8,["value","options"])):e.createCommentVNode("",!0),e.createVNode(d,{class:"field-name",value:t.variableData.format,"onUpdate:value":o[6]||(o[6]=b=>t.variableData.format=b),options:t.formatOptions,placeholder:"请选择值格式"},null,8,["value","options"]),t.isShowDateOperate?(e.openBlock(),e.createBlock(y,{key:4,visible:t.popoverVisible,"onUpdate:visible":o[14]||(o[14]=b=>t.popoverVisible=b),trigger:"click",placement:"bottomRight"},{content:e.withCtx(()=>[e.createElementVNode("div",Db,[e.createVNode(u,{defaultActiveKey:t.variableData.activeOperateKey,onChange:t.changeTab},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(p,{tab:"日期偏移",key:1},{default:e.withCtx(()=>[e.createVNode(c,{class:"field-name",min:"0",value:t.variableData.operateValue,"onUpdate:value":o[9]||(o[9]=b=>t.variableData.operateValue=b),style:{"max-width":"180px",flex:"auto"}},{addonBefore:e.withCtx(()=>[e.createVNode(d,{value:t.variableData.operateType,"onUpdate:value":o[7]||(o[7]=b=>t.variableData.operateType=b),style:{width:"60px"}},{default:e.withCtx(()=>[e.createVNode(i,{value:"add"},{default:e.withCtx(()=>[e.createTextVNode("加")]),_:1}),e.createVNode(i,{value:"minus"},{default:e.withCtx(()=>[e.createTextVNode("减")]),_:1})]),_:1},8,["value"])]),addonAfter:e.withCtx(()=>[e.createVNode(d,{value:t.variableData.operateMode,"onUpdate:value":o[8]||(o[8]=b=>t.variableData.operateMode=b),style:{width:"60px"}},{default:e.withCtx(()=>[e.createVNode(i,{value:"year"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(i,{value:"month"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(i,{value:"week"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(i,{value:"day"},{default:e.withCtx(()=>[e.createTextVNode("日")]),_:1}),e.createVNode(i,{value:"hour"},{default:e.withCtx(()=>[e.createTextVNode("时")]),_:1}),e.createVNode(i,{value:"minute"},{default:e.withCtx(()=>[e.createTextVNode("分")]),_:1})]),_:1},8,["value"])]),_:1},8,["value"])]),_:1})),t.isDateRangeComponent?(e.openBlock(),e.createBlock(p,{tab:"自定义",key:2},{default:e.withCtx(()=>[e.createElementVNode("div",Mb,[e.createVNode(d,{value:t.variableData.operateValue,"onUpdate:value":o[10]||(o[10]=b=>t.variableData.operateValue=b),allowClear:"",style:{width:"120px","margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(i,{value:"rangeValue"},{default:e.withCtx(()=>[e.createTextVNode("范围差值")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.variableData.operateMode,"onUpdate:value":o[11]||(o[11]=b=>t.variableData.operateMode=b),style:{"margin-right":"10px"}},{default:e.withCtx(()=>[e.createVNode(i,{value:"year"},{default:e.withCtx(()=>[e.createTextVNode("年")]),_:1}),e.createVNode(i,{value:"month"},{default:e.withCtx(()=>[e.createTextVNode("月")]),_:1}),e.createVNode(i,{value:"week"},{default:e.withCtx(()=>[e.createTextVNode("周")]),_:1}),e.createVNode(i,{value:"day"},{default:e.withCtx(()=>[e.createTextVNode("日")]),_:1}),e.createVNode(i,{value:"hour"},{default:e.withCtx(()=>[e.createTextVNode("时")]),_:1}),e.createVNode(i,{value:"minute"},{default:e.withCtx(()=>[e.createTextVNode("分")]),_:1})]),_:1},8,["value"]),e.createVNode(d,{value:t.variableData.operateType,"onUpdate:value":o[12]||(o[12]=b=>t.variableData.operateType=b)},{default:e.withCtx(()=>[e.createVNode(i,{value:"minus"},{default:e.withCtx(()=>[e.createTextVNode("前")]),_:1}),e.createVNode(i,{value:"add"},{default:e.withCtx(()=>[e.createTextVNode("后")]),_:1})]),_:1},8,["value"])])]),_:1})):e.createCommentVNode("",!0)]),_:1},8,["defaultActiveKey","onChange"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:"calendar-wrap",onClick:o[13]||(o[13]=b=>{t.popoverVisible=!0})},[e.createVNode(f)])]),_:1},8,["visible"])):e.createCommentVNode("",!0),t.variableData.randomKey?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(h,{key:5,class:"delete-icon",onClick:t.onDelete},null,8,["onClick"]))])}const jb=oe($b,[["render",Pb],["__scopeId","data-v-0d77395a"]]),Rb=e.defineComponent({name:"VariableGroup",components:{VariableItem:jb},setup(){const t=e.inject(Ce),o=e.inject(Ne),n=e.inject(Ue),a=e.computed(()=>{var c;return((c=e.unref(t))==null?void 0:c.variableList)||[]}),l=i=>{o({...e.unref(t),variableConditions:no(i,n),variableList:i})};return{variableList:a,onAddVariable:()=>{const i=J.cloneDeep(e.unref(a));i.push({keyValue:ge(),variableType:"TEXT",dataType:"",id:null,dateTypeValue:null,format:null,operateType:"add",operateMode:"year",operateValue:0,activeOperateKey:1}),l(i)},onUpdateItem:(i,c)=>{if(c>=0){const p=J.cloneDeep(e.unref(a));p[c]=i,l(p)}},onDeleteItem:i=>{if(i>=0){const c=J.cloneDeep(e.unref(a));c.splice(i,1),l(c)}}}}}),ig="",Ub={class:"variable-group"},zb={class:"variable-group-header"},Gb={class:"variable-group-content"};function Hb(t,o,n,a,l,r){const s=e.resolveComponent("a-button"),d=e.resolveComponent("variable-item");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",Ub,[e.createElementVNode("div",zb,[e.createVNode(s,{onClick:t.onAddVariable},{default:e.withCtx(()=>[e.createTextVNode("添加变量")]),_:1},8,["onClick"])])]),e.createElementVNode("div",Gb,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.variableList,(i,c)=>(e.openBlock(),e.createBlock(d,{key:i.keyValue,item:i,index:c,label:i.label,onUpdate:t.onUpdateItem,onDelete:t.onDeleteItem},null,8,["item","index","label","onUpdate","onDelete"]))),128))])],64)}const Wb=oe(Rb,[["render",Hb],["__scopeId","data-v-fd60cd09"]]),Ur=(t={})=>{const o=(r={})=>{const{label:s,name:d,location:i,show:c,indexCode:p,typeGuid:u}=r;return{label:s,columnName:d,location:i,show:c,calcType:"COLUMN",hrpIndexCode:p,typeGuid:u}},n=r=>{We(r,"dataType")&&(r.fieldType==="DATE"&&(r.label=r.fieldName,r.dataType==="component"&&(r.fieldValue="${"+r.fieldValue+"}")),delete r.dataType),We(r,"activeKey")&&delete r.activeKey,We(r,"radioValue")&&delete r.radioValue},a=r=>{const s=[];return r!=null&&r.length&&r.forEach(d=>{if(d.join&&d.conditions){const i=!d.conditions.some(c=>c.join&&c.conditions);d.conditions.forEach((c,p)=>{n(c),i?p<d.conditions.length-1?s.push({join:d.join,...c}):s.push(c):c.join&&c.conditions?s.push({conditions:a([c]),join:d.join}):s.push(c)})}else n(d),s.push(d)}),s},l=(r={})=>{const{label:s,name:d,location:i,show:c,indexCode:p,calcType:u="COLUMN",builtInFormula:f,builtInValueSource:y,builtInCalcWay:h,formula:b,conditions:m,aggregate:w}=r;let g;return m&&(g=a(m)),{label:s.trim(),columnName:d,location:i,show:c,calcType:u,hrpIndexCode:p,aggregate:w,builtInFormula:f,builtInValueSource:y,builtInCalcWay:h,formula:b,conditions:g}};return async()=>{const{graphicConfig:r,type:s,request:d,isGroupTable:i}=t;let{source:c,dataViewId:p,plugin:u="1",layer:f,chartType:y,classificationList:h=[],seriesList:b=[],leftAxisList:m=[],rightAxisList:w=[],queryColumnList:g=[],indicators:S=[],dataSourceId:C,idxLibMode:k,preview:_=!1,sqlConditions:E=[],rowHeaderList:O=[]}=r||{};f==null&&(we(s,["table","card"])?f="1":f="2");let B;if(Array.isArray(h)&&h.length>0){const x=h.length;for(let V=0;V<x;V++){const T=h[V]||{},{label:P="",name:R="",show:N=!1,sort:v,customGroup:A,conditions:F,typeGuid:M}=T;if(N||x===1){B={label:P.trim(),columnName:R,show:N,sort:v,customGroup:A,typeGuid:M,conditions:a(F)};break}}}let L;if(Array.isArray(b)&&b.length>0){const x=b.length;for(let V=0;V<x;V++){const T=b[V]||{},{label:P="",name:R="",show:N=!1,sort:v,customGroup:A,conditions:F,typeGuid:M}=T;if(N||x===1){L={label:P.trim(),columnName:R,show:N,sort:v,customGroup:A,conditions:a(F),typeGuid:M};break}}}const D=[];if(Array.isArray(O)&&O.length>0){const x=O.length;for(let V=0;V<x;V++){const T=O[V]||{},{label:P="",name:R="",show:N=!1,sort:v,customGroup:A,conditions:F,typeGuid:M}=T;D.push({typeGuid:M,label:P.trim(),columnName:R,show:N,sort:v,customGroup:A,conditions:a(F)})}}const I=[];g==null||g.forEach(x=>{I.push(o(x))});const $=[];if(m==null||m.forEach(x=>{x.location="LEFT",$.push(l(x))}),w==null||w.forEach(x=>{x.location="RIGHT",$.push(l(x))}),S==null||S.forEach(x=>{x.location="LEFT",$.push(l(x))}),i||s==="card"){if(y="grouptable",$.length===0||D.length===0)return}else{if(f==="1"&&I.length===0)return;if(f==="2"&&$.length===0)return}try{return await d.post(`${Se}/diagram`,{source:c,dataViewId:p,plugin:u,layer:f,chartType:y,classification:B,series:L,indicatorList:$,queryColumns:I,pageFlag:!0,sqlConditions:E,rowHeaders:D,dataSourceId:C,idxLibMode:k,preview:_})}catch(x){console.error(x)}}},Yb=e.defineComponent({name:"ChartGraph",components:{ASpin:j.Spin},props:{graphicConfig:{type:Object,default:()=>{}},chartsOptions:{type:Object,default:()=>{}}},setup(t,{expose:o}){const n=e.computed(()=>t.chartsOptions?e.unref(t.chartsOptions):i),a=e.computed(()=>t.graphicConfig?e.unref(t.graphicConfig):d),l=e.inject(Ee);let r=null;const s=e.inject(Be)||"",d=e.inject(Ce)||{},i=e.inject(Co)||{},c=e.ref(null),p=e.ref(null),u=e.ref(),f=e.ref(!1),y=e.ref(!1),h=e.computed(()=>y.value?Jr:12),b=e.ref({}),m=e.ref(),w=e.computed(()=>{const B=e.unref(n.value);return(B==null?void 0:B.type)==="customGraph"?m.value:Kc(B,e.unref(b),h.value)}),g=(B=[],L,D=!1)=>{const I=D?L:null;b.value=Uc(B,I)},S=(B=[],L)=>{b.value=zc(B,L)},C=async()=>{var B,L,D;try{const I=Ur({graphicConfig:e.unref(a.value),type:(B=e.unref(n.value))==null?void 0:B.type,request:l,indicatorToken:s});f.value=!0;const $=await I(),{columns:x=[],rows:V=[]}=((L=$==null?void 0:$.data)==null?void 0:L.data)??{};if(((D=e.unref(n.value))==null?void 0:D.type)==="pie"){let T=[];if(x.length>0){const P=x[0],R=x[1];T=V.map(N=>({name:N[P],value:N[R]}))}S(T)}else{let T;x.length>0&&(T={name:x[0],types:x.slice(1).map(P=>({label:P,value:P}))}),g(V,T,!0)}}catch(I){console.error(I)}finally{f.value=!1}},k={title:{text:"暂无数据",x:"center",y:"center",textStyle:{fontSize:14,fontWeight:"normal"}}},_=()=>{e.unref(b).dataset.length===0?u.value.setOption(k,!0):u.value.setOption(w.value,!0)},E=()=>{e.unref(n.value).type!=="customGraph"&&C()},O=()=>{var B;(B=u.value)==null||B.resize()};return e.watch(w,()=>{_()},{deep:!0}),e.watch(()=>e.unref(n.value).optionCode,B=>{try{const L=eval;m.value=L(B)}catch(L){console.error(L)}},{immediate:!0}),e.onMounted(()=>{p.value&&(r=new ResizeObserver(O),r.observe(p.value)),u.value=Qr.init(c.value)}),e.onBeforeUnmount(()=>{u.value.dispose(),r&&(r.disconnect(),r=null)}),o({refreshData:E}),{echartRef:c,loading:f}}}),sg="",qb={class:"ecan-chart-graph",ref:"chartWrapRef"},Kb={style:{width:"100%",height:"100%"},ref:"echartRef"};function Xb(t,o,n,a,l,r){const s=e.resolveComponent("a-spin");return e.openBlock(),e.createElementBlock("div",qb,[e.createVNode(s,{spinning:t.loading,wrapperClassName:"chart-spin",tip:"数据加载中..."},{default:e.withCtx(()=>[e.createElementVNode("div",Kb,null,512)]),_:1},8,["spinning"])],512)}const zr=oe(Yb,[["render",Xb],["__scopeId","data-v-845f7ab1"]]),Qb=e.defineComponent({name:"TableGraph",components:{ATable:j.Table},props:{graphicConfig:{type:Object,default:()=>{}},type:{type:String},pagination:{type:Object,default:()=>({})}},setup(t){const o=e.inject(Ie),n=e.ref([]),a=e.ref([]),l=e.inject(Ee),r=e.inject(Be)||"",s=async()=>{var d;try{const c=await Ur({graphicConfig:t.graphicConfig,type:t.type,request:l,indicatorToken:r})(),{columns:p=[],rows:u=[]}=((d=c==null?void 0:c.data)==null?void 0:d.data)??{},f=e.unref(o).columnsConfigMap;a.value=p.map(y=>({title:y,dataIndex:y,label:y,...f[y]})),n.value=u}catch(i){console.error(i)}};return e.watch([()=>t.graphicConfig,()=>e.unref(o).columnsConfigMap],()=>{s()},{deep:!0,immediate:!0}),{tableData:n,tableColumns:a,handleFormat:Jc,columnsConfigMap:e.unref(o).columnsConfigMap}}}),Jb={key:0};function Zb(t,o,n,a,l,r){const s=e.resolveComponent("a-table");return e.openBlock(),e.createBlock(s,{style:{width:"100%"},scroll:{y:280},columns:t.tableColumns,"data-source":t.tableData,size:"small",pagination:t.pagination},{bodyCell:e.withCtx(({column:d,record:i})=>[d.retentiondigit!==void 0?(e.openBlock(),e.createElementBlock("span",Jb,e.toDisplayString(t.handleFormat(i,d)),1)):e.createCommentVNode("",!0)]),_:1},8,["columns","data-source","pagination"])}const ey=oe(Qb,[["render",Zb]]),ty=e.defineComponent({name:"DataConfig",components:{DataGroup:cf,StyleGroup:hb,ChartGraph:zr,ATabs:j.Tabs,ATabPane:j.TabPane,ControlGroup:vb,VariableGroup:Wb,AButton:j.Button,ReloadOutlined:ac,TableGraph:ey},setup(){var E;const t=e.ref("1"),o=e.ref([0,1,2]),n=e.ref(),a=e.inject(Ie),l=e.inject(ca),r=e.inject(Ce),s=e.inject(Ue),d=e.inject(ma),i=["text","proportion","select","checkbox","radio","radar","circulate"],c=e.computed(()=>{const O=J.cloneDeep(e.unref(a));p(O);const B=J.pick(O,J.without(Object.keys(O),"position","top","left","width","height"));we(O.type,i)?(B.height=O.height,B.width=O.width):B.height="290px";const L=J.cloneDeep(e.unref(r));return L.pageMode="design",L.componentList=s,L.preview=!0,L.pageConfig=d,{...B,graphicConfig:L,toolboxShow:!1,sourceLeft:O.left,sourceTop:O.top}});function p(O){var B,L,D,I;["#ffffff","#fff"].includes((B=O==null?void 0:O.color)==null?void 0:B.toLowerCase())&&(O.color="#000"),["#ffffff","#fff"].includes((L=O==null?void 0:O.variableColor)==null?void 0:L.toLowerCase())&&(O.variableColor="#000"),["#ffffff","#fff"].includes((D=O==null?void 0:O.increaseColor)==null?void 0:D.toLowerCase())&&(O.increaseColor="#000"),["#ffffff","#fff"].includes((I=O==null?void 0:O.declineColor)==null?void 0:I.toLowerCase())&&(O.declineColor="#000")}const u=e.computed(()=>{let O=!0;return we(e.unref(c).type,i)&&(O=!1),O}),f=e.computed(()=>{var O;return(O=e.unref(c))==null?void 0:O.type}),y=e.computed(()=>{var O;return!!((O=e.unref(c))!=null&&O.isGroupTable)}),h=O=>{const B=O==="1";B&&f.value==="table"&&C(),window.changeShowTable&&window.changeShowTable(B),O==="3"&&S()},b=e.ref(),m=e.inject(Ee),w=e.unref(e.inject(Be)),g=(E=window==null?void 0:window.config)==null?void 0:E.pageId;function S(){var x;const{leftAxisList:O=[],rightAxisList:B=[],queryColumnList:L=[],indicators:D=[]}=e.unref(r),I=[...O,...B,...L,...D],$={};for(const V of I){const{id:T="",indexCode:P=""}=V;T&&!We(V,"calcType")&&!$[T]&&($[T]=P)}if((x=Object.keys($))!=null&&x.length){const V=[];for(const T in $)V.push(new Promise((P,R)=>{m.post(`${Se}/diagram/hrpIndexWithComplex`,{pageId:g,indexGuid:T,indexCode:$[T],dataSourceId:""},{headers:{Authentication:w,operateContext:"ygt"}}).then(N=>{var F;const{success:v,data:A=[]}=N.data;v&&((F=A==null?void 0:A.dataViewColumns)!=null&&F.length)?P(A.dataViewColumns):R(A)}).catch(N=>{R(N)})}));Promise.all(V).then(T=>{if(T!=null&&T.length){const P=T.reduce((R,N)=>R.filter(v=>N.find(A=>A.typeGuid===v.typeGuid)));b.value=P.filter(R=>R.typeGuid)}})}}const C=()=>{var B;let O;l&&f.value==="table"?O=window.updateConfig:O=(B=e.unref(n))==null?void 0:B.refreshData,typeof O=="function"&&O()},k=e.inject(Ne),_=()=>{var O;k({variableConditions:no(((O=e.unref(r))==null?void 0:O.variableList)||[],s)})};return e.provide(da,C),e.watch(r,()=>{C()},{deep:!0,flush:"post"}),{isShowStyleConfig:l,activeKey:t,activePanel:o,componentRef:n,type:f,isGroupTable:y,onChange:h,component:c,fullWidth:u,renderUsedComponents:s,intersection:b,refreshData:C,refreshAction:_}}}),cg="",oy={class:"data-config"},ny={key:0,id:"table-wrap",class:"chart-component",ref:"tableWrapRef",style:{width:"100%",height:"290px"}};function ay(t,o,n,a,l,r){const s=e.resolveComponent("data-group"),d=e.resolveComponent("a-tab-pane"),i=e.resolveComponent("style-group"),c=e.resolveComponent("control-group"),p=e.resolveComponent("variable-group"),u=e.resolveComponent("reload-outlined"),f=e.resolveComponent("a-button"),y=e.resolveComponent("a-tabs"),h=e.resolveComponent("table-graph"),b=e.resolveComponent("chart-graph");return e.openBlock(),e.createElementBlock("div",oy,[e.createVNode(y,{activeKey:t.activeKey,"onUpdate:activeKey":o[0]||(o[0]=m=>t.activeKey=m),onChange:t.onChange},{rightExtra:e.withCtx(()=>[e.createVNode(f,{onClick:t.refreshAction},{icon:e.withCtx(()=>[e.createVNode(u)]),default:e.withCtx(()=>[e.createTextVNode(" 刷新 ")]),_:1},8,["onClick"])]),default:e.withCtx(()=>[e.createVNode(d,{key:"1",tab:"数据配置"},{default:e.withCtx(()=>[e.createVNode(s,{ref:"dataGroupRef"},null,512),t.isShowStyleConfig?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.type),e.mergeProps({key:0,class:["chart-component",t.fullWidth?"full-width":""]},t.component,{ref:"componentRef"}),null,16,["class"]))]),_:1}),t.isShowStyleConfig?(e.openBlock(),e.createBlock(d,{key:"2",tab:"样式配置","force-render":""},{default:e.withCtx(()=>[e.createVNode(i,{componentType:t.type,isGroupTable:t.isGroupTable},null,8,["componentType","isGroupTable"])]),_:1})):e.createCommentVNode("",!0),t.renderUsedComponents?(e.openBlock(),e.createBlock(d,{key:"3",tab:"全局过滤","force-render":""},{default:e.withCtx(()=>[e.createVNode(c,{ref:"controlGroup",intersection:t.intersection},null,8,["intersection"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(d,{key:"4",tab:"全局变量","force-render":""},{default:e.withCtx(()=>[e.createVNode(p)]),_:1})]),_:1},8,["activeKey","onChange"]),t.isShowStyleConfig?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.type==="table"&&t.activeKey==="1"?(e.openBlock(),e.createElementBlock("div",ny,null,512)):t.type==="card"?e.withDirectives((e.openBlock(),e.createBlock(h,e.mergeProps({key:1,class:"chart-component"},t.component),null,16)),[[e.vShow,t.activeKey==="1"]]):e.withDirectives((e.openBlock(),e.createBlock(b,{key:2,class:e.normalizeClass(["chart-component",t.fullWidth?"full-width":""]),ref:"componentRef",style:{width:"100%",height:"290px"}},null,8,["class"])),[[e.vShow,t.activeKey==="1"]])],64)):e.createCommentVNode("",!0)])}const ly=oe(ty,[["render",ay],["__scopeId","data-v-1f671261"]]),ry=e.defineComponent({name:"IndicatorLibrary",components:{DataList:Bd,DataConfig:ly},props:{isShowStyleConfig:{type:Boolean,default:!1},sourceType:{type:String,default:""},indicatorToken:{type:String,default:""},selectedComponent:{type:Object,default:()=>{}},request:{default:null},renderUsedComponentList:{type:Array,default:()=>[]},mapAttributeProps:{type:Object,default:()=>{}},pageConfig:{type:Object,default:()=>{}}},setup(t,{expose:o,emit:n}){const a=e.ref(!1),l=e.computed(()=>t.sourceType),r=e.computed(()=>t.indicatorToken||""),s=e.computed(()=>t.selectedComponent),d=e.computed(()=>{var k;return((k=e.unref(s))==null?void 0:k.tableColumns)||[]}),i=e.computed(()=>t.isShowStyleConfig);let c=e.unref(s).graphicConfig?J.cloneDeep(e.unref(s).graphicConfig):e.ref({});c=e.ref(c);let p=e.unref(s).chartsOptions?J.cloneDeep(e.unref(s).chartsOptions):e.ref(J.cloneDeep(Ko.line));p=e.ref(p);let u=e.unref(s).tableOptions?J.cloneDeep(e.unref(s).tableOptions):e.ref(J.cloneDeep(Zr));u=e.ref(u);const f=e.ref([]),y=k=>{f.value=k},h=k=>{c.value={...e.unref(c),...e.unref(k)}},b=(k,_=!0)=>{_?p.value={...e.unref(p),...e.unref(k)}:p.value={...e.unref(k)}},m=k=>{u.value={...e.unref(u),...e.unref(k)}},w=()=>f,g=()=>{a.value=!0,e.unref(s).graphicConfig&&(c.value=J.cloneDeep(e.unref(s).graphicConfig)),e.unref(s).chartsOptions&&(p.value=J.cloneDeep(e.unref(s).chartsOptions||Ko.line)),e.nextTick(()=>{a.value=!1})},S=()=>({graphicConfig:e.unref(c),chartsOptions:e.unref(p),tableOptions:e.unref(u),tableColumns:e.unref(d),columnsConfigMap:e.unref(s).columnsConfigMap});window.getIndicatorData=S,t.request&&e.provide(Ee,t.request),e.provide(sa,{setDataList:y,getDataList:w});const C=k=>{n("updateUsedComponent",k)};return e.provide(Ie,s),e.provide(Ce,c),e.provide(Co,p),e.provide(pa,u),e.provide(Wt,l),e.provide(ca,i),e.provide(Be,r),e.provide(Ne,h),e.provide(Yo,b),e.provide(qo,m),e.provide(Ue,t.renderUsedComponentList),e.provide(ko,C),e.provide(fa,t.mapAttributeProps),e.provide(ma,t.pageConfig),o({graphicConfig:c,chartsOptions:p,updateIndicatorData:g}),{isUpdate:a}}}),dg="",iy={key:0,class:"config-modal"},sy={class:"config-modal-left"},cy={class:"config-modal-right"};function dy(t,o,n,a,l,r){const s=e.resolveComponent("data-list"),d=e.resolveComponent("data-config");return t.isUpdate?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",iy,[e.createElementVNode("div",sy,[e.createVNode(s)]),e.createElementVNode("div",cy,[e.createVNode(d)])]))}const Gr=ia(oe(ry,[["render",dy],["__scopeId","data-v-0686deff"]])),Hr=ia(zr),Wr=Object.freeze(Object.defineProperty({__proto__:null,EcanChartGraph:Hr,EcanIndicatorLibrary:Gr},Symbol.toStringTag,{value:"Module"})),py={install:(t,o)=>{const{request:n}=o;t.provide("$request",n),Object.keys(Wr).forEach(a=>{const l=Wr[a];l.install&&t.use(l)})}};me.EcanChartGraph=Hr,me.EcanIndicatorLibrary=Gr,me.default=py,Object.defineProperties(me,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
64
75
  //# sourceMappingURL=index.umd.js.map