Liferay.Loader.define("data-engine-js-components-web@1.0.107/js/custom/form-report/components/chart/TooltipContent",["module","exports","require","liferay!frontend-js-react-web$react","../../utils/data"],(function(e,t,l){window;Object.defineProperty(t,"__esModule",{value:!0}),t.default=function TooltipContent({active:e,field:t,label:l,payload:n,roundBullet:o=!0,showBullet:u=!0,showHeader:c=!0,totalEntries:i=0}){if(e)return i||(i=n.reduce(((e,t)=>e+t.value),0)),a.default.createElement("div",{className:"custom-tooltip"},c?a.default.createElement("div",{className:"header"},a.default.createElement("div",{className:"title"},l)):null,a.default.createElement("ul",null,n.map((({dataKey:e,fill:l,payload:n,value:d},f)=>{var s;return e=c?(0,r.getColumnLabel)(e,t):n.label,l=null!==(s=n.fill)&&void 0!==s?s:l,a.default.createElement("li",{key:"tooltip-".concat(f)},u?a.default.createElement("svg",{height:"12",width:"12"},o?a.default.createElement("circle",{cx:"6",cy:"6",fill:l,r:"6",strokeWidth:"0"}):a.default.createElement("rect",{fill:l,height:"12",width:"12"})):null,a.default.createElement("div",{id:"tooltip-label"},"".concat(e,": ").concat(d," "),1===Number(d)?"".concat(Liferay.Language.get("entry").toLowerCase()," "):"".concat(Liferay.Language.get("entries").toLowerCase()," "),a.default.createElement("b",null,"(",(0,r.roundPercentage)((0,r.getPercentage)(d,i)),")")))}))));return null};var a=function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}(l("liferay!frontend-js-react-web$react")),r=l("../../utils/data")}));
//# sourceMappingURL=TooltipContent.js.map