import{a as J}from"./chunk-ISBJRZ42.js";import{a as l}from"./chunk-C7XZ7IYY.js";import{$c as A,Aa as D,Ba as i,Ca as o,Da as p,Ka as m,Kb as _,M as h,N as f,Ta as r,Va as v,Xc as M,Zc as F,_c as I,ab as c,ad as B,ba as n,ca as g,gb as x,gc as T,ha as b,hc as k,ma as y,oc as S,qa as s,qd as R,qe as E,rd as W,ya as C,za as w}from"./chunk-7SK34GC7.js";var u=()=>[];function L(a,d){if(a&1&&(r(0,`
        `),i(1,"span",6),r(2),o(),r(3,`
      `)),a&2){let t=m().$implicit;n(2),v(`
          `,t.report_data,`
        `)}}function H(a,d){a&1&&(i(0,"c-dropdown",7)(1,"button",8),h(),p(2,"svg",9),o(),f(),i(3,"ul",10)(4,"li")(5,"a",11),r(6,"Action"),o()(),i(7,"li")(8,"a",11),r(9,"Another action"),o()(),i(10,"li")(11,"a",11),r(12,"Something else here"),o()(),i(13,"li"),p(14,"hr",12),o(),i(15,"li")(16,"button",13),r(17,"Separated link"),o()()()()),a&2&&(n(),s("caret",!1),n(4),s("routerLink",c(4,u)),n(3),s("routerLink",c(5,u)),n(3),s("routerLink",c(6,u)))}function Q(a,d){if(a&1&&p(0,"c-chart",14),a&2){let t=m(2);s("data",t.data[0])("options",t.options[0])("type","line")}}function V(a,d){if(a&1&&(i(0,"c-col",1)(1,"c-widget-stat-a",2),y(2,L,4,1,"ng-template",3)(3,H,18,7,"ng-template",4)(4,Q,1,3,"ng-template",5),o()()),a&2){let t=d.$implicit;n(),s("title",t.title)}}var ee=(()=>{class a{constructor(t){this.changeDetectorRef=t,this.data=[],this.options=[],this.labels=["January","February","March","April","May","June","July","August","September","October","November","December","January","February","March","April"],this.datasets=[[{label:"My First dataset",backgroundColor:"transparent",borderColor:"rgba(255,255,255,.55)",pointBackgroundColor:l("--cui-primary"),pointHoverBorderColor:l("--cui-primary"),data:[65,59,84,84,51,55,40]}],[{label:"My Second dataset",backgroundColor:"transparent",borderColor:"rgba(255,255,255,.55)",pointBackgroundColor:l("--cui-info"),pointHoverBorderColor:l("--cui-info"),data:[1,18,9,17,34,22,11]}],[{label:"My Third dataset",backgroundColor:"rgba(255,255,255,.2)",borderColor:"rgba(255,255,255,.55)",pointBackgroundColor:l("--cui-warning"),pointHoverBorderColor:l("--cui-warning"),data:[78,81,80,45,34,12,40],fill:!0}],[{label:"My Fourth dataset",backgroundColor:"rgba(255,255,255,.2)",borderColor:"rgba(255,255,255,.55)",data:[78,81,80,45,34,12,40,85,65,23,12,98,34,84,67,82],barPercentage:.7}]],this.optionsDefault={plugins:{legend:{display:!1}},maintainAspectRatio:!1,scales:{x:{border:{display:!1},grid:{display:!1,drawBorder:!1},ticks:{display:!1}},y:{min:30,max:89,display:!1,grid:{display:!1},ticks:{display:!1}}},elements:{line:{borderWidth:1,tension:.4},point:{radius:4,hitRadius:10,hoverRadius:4}}}}ngOnInit(){this.setData()}ngAfterContentInit(){this.changeDetectorRef.detectChanges()}setData(){for(let t=0;t<4;t++)this.data[t]={labels:t<3?this.labels.slice(0,7):this.labels,datasets:this.datasets[t]};this.setOptions()}setOptions(){for(let t=0;t<4;t++){let e=JSON.parse(JSON.stringify(this.optionsDefault));switch(t){case 0:{this.options.push(e);break}case 1:{e.scales.y.min=-9,e.scales.y.max=39,e.elements.line.tension=0,this.options.push(e);break}case 2:{e.scales.x={display:!1},e.scales.y={display:!1},e.elements.line.borderWidth=2,e.elements.point.radius=0,this.options.push(e);break}case 3:{e.scales.x.grid={display:!1,drawTicks:!1},e.scales.x.grid={display:!1,drawTicks:!1,drawBorder:!1},e.scales.y.min=void 0,e.scales.y.max=void 0,e.elements={},this.options.push(e);break}}}}static{this.\u0275fac=function(e){return new(e||a)(g(x))}}static{this.\u0275cmp=b({type:a,selectors:[["app-widgets-dropdown"]],inputs:{statsData:"statsData"},decls:3,vars:0,consts:[[1,"g-4","mb-4"],["sm","6","xl","3"],["color","primary",3,"title"],["cTemplateId","widgetValueTemplate"],["cTemplateId","widgetActionTemplate"],["cTemplateId","widgetChartTemplate"],[1,"fw-normal",2,"font-size","40px"],["alignment","end","variant","btn-group"],["cButton","","cDropdownToggle","","color","transparent","aria-label","Open dropdown",1,"p-0","text-white",3,"caret"],["cIcon","","name","cilOptions"],["cDropdownMenu",""],["cDropdownItem","",3,"routerLink"],["cDropdownDivider",""],["cDropdownItem",""],["height","70",1,"mt-3","mx-3",3,"data","options","type"]],template:function(e,O){e&1&&(i(0,"c-row",0),w(1,V,5,1,"c-col",1,C),o()),e&2&&(n(),D(O.statsData))},dependencies:[W,R,E,k,T,A,S,I,F,B,_,M,J],encapsulation:2})}}return a})();export{ee as a};
