@hpcc-js/html 3.2.0 → 3.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -459,10 +459,10 @@ l = { __e: function(n, l2, u2, t) {
459
459
  var f = 0;
460
460
  function u(e, t, n, o, i, u2) {
461
461
  t || (t = {});
462
- var a, l$1 = t;
463
- "ref" in t && (a = t.ref, delete t.ref);
464
- var p = { type: e, props: l$1, key: n, ref: a, __k: null, __: null, __b: 0, __e: null, __d: void 0, __c: null, constructor: void 0, __v: --f, __i: -1, __u: 0, __source: i, __self: u2 };
465
- return l.vnode && l.vnode(p), p;
462
+ var a, c, p = t;
463
+ if ("ref" in p) for (c in p = {}, t) c == "ref" ? a = t[c] : p[c] = t[c];
464
+ var l$1 = { type: e, props: p, key: n, ref: a, __k: null, __: null, __b: 0, __e: null, __d: void 0, __c: null, constructor: void 0, __v: --f, __i: -1, __u: 0, __source: i, __self: u2 };
465
+ return l.vnode && l.vnode(l$1), l$1;
466
466
  }
467
467
  class VizComponent extends JSXWidget.Component {
468
468
  constructor() {
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../src/__package__.ts","../src/HTMLTooltip.ts","../src/SimpleTable.ts","../src/StyledTable.ts","../src/BreakdownTable.ts","../src/JSXWidget.ts","../src/reactD3.ts","../../../node_modules/preact/dist/preact.module.js","../../../node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js","../src/VizComponent.tsx","../src/VizInstance.tsx","../src/StatsTable.ts","../src/TitleBar.ts"],"sourcesContent":["export const PKG_NAME = \"@hpcc-js/html\";\nexport const PKG_VERSION = \"3.1.1\";\nexport const BUILD_VERSION = \"3.2.1\";\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\nimport { scopedLogger, ScopedLogging } from \"@hpcc-js/util\";\n\ntype Direction = \"n\" | \"s\" | \"e\" | \"w\" | \"ne\" | \"nw\" | \"se\" | \"sw\";\ntype Position = { x: number, y: number };\ntype DirectionalBBox = { [key in Direction]: Position; };\n\ntype Rectangle = { top: number, left: number, width: number, height: number };\nexport class HTMLTooltip extends HTMLWidget {\n\n public _triggerElement;\n public _contentNode;\n protected _prevContentNode;\n\n protected _tooltipElement;\n protected _arrowElement;\n protected _tooltipHTMLCallback = (data?) => \"<b>_tooltipHTMLCallback is undefined</b>\";\n protected _logger: ScopedLogging = scopedLogger(\"html/HTMLTooltip\");\n constructor() {\n super();\n this.visible(false);\n }\n\n tooltipHTML(_: (data?) => string): this {\n this._tooltipHTMLCallback = _;\n return this;\n }\n\n tooltipContent(_): this {\n if (!arguments.length) return this._contentNode;\n this._contentNode = _;\n return this;\n }\n\n triggerElement(_): this {\n this._triggerElement = _;\n return this;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n const body = d3Select(\"body\");\n this._tooltipElement = body.append(\"div\")\n .attr(\"class\", \"tooltip-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n this._arrowElement = body.append(\"div\")\n .attr(\"class\", \"arrow-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n if (this._contentNode !== this._prevContentNode) {\n const node = this._tooltipElement.node();\n [...node.querySelectorAll(\"*\")]\n .map(n => n.__data__)\n .filter(n => n)\n .forEach(w => {\n if (typeof w.target === \"function\") {\n w.target(null);\n }\n if (typeof w.exit === \"function\") {\n w.exit();\n }\n });\n node.innerHTML = \"\";\n node.appendChild(this._contentNode);\n this._prevContentNode = this._contentNode;\n }\n\n if (this._contentNode) {\n this.onShowContent(this._contentNode);\n } else {\n this._tooltipElement\n .html(() => {\n return this._tooltipHTMLCallback(this.data());\n });\n }\n if (this.fitContent()) {\n this._tooltipElement\n .style(\"width\", \"auto\")\n .style(\"height\", \"auto\")\n .style(\"padding\", \"0px\")\n .style(\"box-sizing\", \"content-box\")\n ;\n const rect = this._tooltipElement.node().getBoundingClientRect();\n this.tooltipWidth_default(rect.width);\n this.tooltipHeight_default(rect.height);\n }\n this._closing = false;\n this._tooltipElement\n .style(\"background-color\", this.tooltipColor())\n .style(\"color\", this.fontColor())\n .style(\"width\", this.tooltipWidth() + \"px\")\n .style(\"height\", this.tooltipHeight() + \"px\")\n .style(\"opacity\", 1)\n .style(\"padding\", this.padding() + \"px\")\n .style(\"pointer-events\", this.enablePointerEvents() ? \"all\" : \"none\")\n .style(\"box-sizing\", \"content-box\")\n ;\n this._arrowElement\n .style(\"opacity\", 1)\n .style(\"pointer-events\", \"none\")\n ;\n this.updateTooltipPosition();\n }\n\n onShowContent(node) {\n\n }\n\n protected updateTooltipPosition(): Position {\n const bbox = this.calcReferenceBBox();\n const direction = this.calcTooltipDirection(bbox);\n const box = bbox[direction];\n this._tooltipElement\n .style(\"top\", box.y + \"px\")\n .style(\"left\", box.x + \"px\")\n ;\n this.setArrowPosition(box, direction);\n return box;\n }\n\n protected calcTooltipDirection(bbox: DirectionalBBox): Direction {\n const directions: Direction[] = Object.keys(bbox) as Direction[];\n\n const defaultDirection = this.direction();\n directions.sort((a, b) => a === defaultDirection ? -1 : 1);\n const windowRect = {\n top: 0,\n left: 0,\n width: window.innerWidth,\n height: window.innerHeight\n };\n for (let i = 0; i < directions.length; i++) {\n const tooltipRect = {\n top: bbox[directions[i]].y,\n left: bbox[directions[i]].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n };\n if (this.rectFits(tooltipRect, windowRect)) {\n return directions[i];\n }\n }\n this._logger.warning(`Tooltip doesn't fit in the window for any of the directions. Defaulting to '${defaultDirection}'`);\n this._logger.debug(windowRect);\n this._logger.debug({\n top: bbox[defaultDirection].y,\n left: bbox[defaultDirection].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n });\n return defaultDirection;\n }\n\n protected rectFits(innerRect: Rectangle, outerRect: Rectangle): boolean {\n return (\n innerRect.top >= outerRect.top &&\n innerRect.left >= outerRect.left &&\n innerRect.width + innerRect.left <= outerRect.width + outerRect.left &&\n innerRect.height + innerRect.top <= outerRect.height + outerRect.top\n );\n }\n\n protected setArrowPosition(point: Position, direction: Direction) {\n let top;\n let left;\n let visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border\", `${this.arrowHeight()}px solid ${this.tooltipColor()}`)\n .style(\"border-top-color\", \"transparent\")\n .style(\"border-right-color\", \"transparent\")\n .style(\"border-bottom-color\", \"transparent\")\n .style(\"border-left-color\", \"transparent\")\n ;\n switch (direction) {\n case \"n\":\n top = point.y + this.tooltipHeight() + (this.padding() * 2);\n left = point.x + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2) + this.padding();\n visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowHeight()}px`)\n .style(\"border-bottom-width\", \"0px\")\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"s\":\n top = point.y - this.arrowHeight();\n left = point.x + this.padding() + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2);\n visibleBorderStyle = \"border-bottom-color\";\n this._arrowElement\n .style(\"border-top-width\", \"0px\")\n .style(\"border-bottom-width\", `${this.arrowHeight()}px`)\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"e\":\n top = point.y + (this.tooltipHeight() / 2) + this.padding() - (this.arrowWidth() / 2);\n left = point.x - this.arrowHeight();\n visibleBorderStyle = \"border-right-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", \"0px\")\n .style(\"border-right-width\", `${this.arrowHeight()}px`)\n ;\n break;\n case \"w\":\n top = point.y + (this.tooltipHeight() / 2) - (this.arrowWidth() / 2) + this.padding();\n left = point.x + this.tooltipWidth() + (this.padding() * 2);\n visibleBorderStyle = \"border-left-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", `${this.arrowHeight()}px`)\n .style(\"border-right-width\", \"0px\")\n ;\n break;\n }\n if (typeof top !== \"undefined\" && typeof left !== \"undefined\") {\n this._arrowElement\n .style(\"top\", top + \"px\")\n .style(\"left\", left + \"px\")\n .style(visibleBorderStyle, this.tooltipColor())\n .style(\"opacity\", 1)\n ;\n } else {\n this._arrowElement\n .style(\"opacity\", 0)\n ;\n }\n return point;\n }\n\n protected getReferenceNode() {\n if (!this._triggerElement) {\n return this.element().node().parentNode.parentNode;\n }\n return this._triggerElement.node();\n }\n public _cursorLoc;\n protected calcReferenceBBox() {\n const node = this.getReferenceNode();\n let { top, left, width, height } = node.getBoundingClientRect();\n const wholeW = this.tooltipWidth();\n const wholeH = this.tooltipHeight();\n const halfW = wholeW / 2;\n const halfH = wholeH / 2;\n const arrowH = this.arrowHeight();\n const p = this.padding();\n const p2 = p * 2;\n\n if (this.followCursor() && this._cursorLoc) {\n\n left = this._cursorLoc[0];\n top = this._cursorLoc[1];\n width = 1;\n height = 1;\n }\n const bbox = {\n n: {\n x: left + (width / 2) - halfW - p,\n y: top - wholeH - arrowH - p2\n },\n e: {\n x: left + width + arrowH,\n y: top + (height / 2) - halfH - p\n },\n s: {\n x: left + (width / 2) - halfW - p,\n y: top + height + arrowH\n },\n w: {\n x: left - wholeW - arrowH - p2,\n y: top + (height / 2) - halfH - p\n },\n nw: {\n x: left - wholeW - p2,\n y: top - wholeH - p2\n },\n ne: {\n x: left + width,\n y: top - wholeH - p2\n },\n se: {\n x: left + width,\n y: top + height\n },\n sw: {\n x: left - wholeW - p2,\n y: top + height\n }\n };\n return bbox;\n }\n\n private _closing = false;\n mouseout() {\n this._closing = true;\n this._tooltipElement.on(\"mouseover\", () => {\n this._closing = false;\n });\n this._tooltipElement.on(\"mouseout\", () => {\n this.mouseout();\n });\n setTimeout(() => {\n if (this._closing) {\n this.visible(false);\n }\n }, this.closeDelay());\n }\n\n visible(): boolean;\n visible(_: boolean): this;\n visible(_?: boolean): boolean | this {\n if (!arguments.length) return super.visible();\n if (this._arrowElement) {\n this._arrowElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n this._tooltipElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n }\n super.visible(_);\n return this;\n }\n\n exit(domNode, element) {\n if (this._arrowElement) {\n this._arrowElement.remove();\n this._tooltipElement.remove();\n }\n super.exit(domNode, element);\n }\n}\nHTMLTooltip.prototype._class += \" html_HTMLTooltip\";\n\nexport interface HTMLTooltip {\n padding(): number;\n padding(_: number): this;\n direction(): Direction;\n direction(_: Direction): this;\n arrowHeight(): number;\n arrowHeight(_: number): this;\n arrowWidth(): number;\n arrowWidth(_: number): this;\n fontColor(): string;\n fontColor(_: string): this;\n tooltipColor(): string;\n tooltipColor(_: string): this;\n tooltipWidth(): number;\n tooltipWidth(_: number): this;\n tooltipWidth_default(_: number);\n tooltipHeight(): number;\n tooltipHeight(_: number): this;\n tooltipHeight_default(_: number);\n followCursor(): boolean;\n followCursor(_: boolean): this;\n enablePointerEvents(): boolean;\n enablePointerEvents(_: boolean): this;\n closeDelay(): number;\n closeDelay(_: number): this;\n fitContent(): boolean;\n fitContent(_: boolean): this;\n\n}\n\nHTMLTooltip.prototype.publish(\"fitContent\", false, \"boolean\", \"If true, tooltip will grow to fit its html content\");\nHTMLTooltip.prototype.publish(\"followCursor\", false, \"boolean\", \"If true, tooltip will display relative to cursor location\");\nHTMLTooltip.prototype.publish(\"closeDelay\", 400, \"number\", \"Number of milliseconds to wait before closing tooltip (cancelled on tooltip mouseover event)\");\nHTMLTooltip.prototype.publish(\"direction\", \"n\", \"set\", \"Direction in which to display the tooltip\", [\"n\", \"s\", \"e\", \"w\", \"ne\", \"nw\", \"se\", \"sw\"]);\nHTMLTooltip.prototype.publish(\"padding\", 8, \"number\", \"Padding (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowWidth\", 16, \"number\", \"Width (or height depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowHeight\", 8, \"number\", \"Height (or width depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"fontColor\", \"#FFF\", \"html-color\", \"The default font color for text in the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipColor\", \"#000000EE\", \"html-color\", \"Background color of the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipWidth\", 200, \"number\", \"Width of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"tooltipHeight\", 200, \"number\", \"Height of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"enablePointerEvents\", false, \"boolean\", \"If true, the 'pointer-events: all' style will be used\");\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\n\nexport class SimpleTable extends HTMLWidget {\n protected _table;\n protected _tbody;\n protected _thead;\n protected _theadRow;\n constructor() {\n super();\n }\n\n protected transformData() {\n return this.data();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n\n this._table = element.append(\"table\");\n this._thead = this._table.append(\"thead\");\n this._theadRow = this._thead.append(\"tr\");\n this._tbody = this._table.append(\"tbody\");\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._table\n .style(\"width\", this.autoWidth() ? \"auto\" : \"100%\")\n ;\n const theadTrSelection = this._theadRow.selectAll(\"th\").data(this.columns());\n theadTrSelection.enter()\n .append(\"th\")\n .attr(\"class\", (n, i) => `th-${i}`)\n .merge(theadTrSelection)\n .text(_d => (_d).toString())\n ;\n theadTrSelection.exit().remove();\n const trSelection = this._tbody.selectAll(\"tr\").data(this.transformData());\n trSelection.enter()\n .append(\"tr\")\n .merge(trSelection)\n .each(function (this, d) {\n const tr = d3Select(this);\n const tdSelection = tr.selectAll(\"td\").data(d);\n tdSelection.enter()\n .append(\"td\")\n .attr(\"class\", (n, i) => `col-${i}`)\n .merge(tdSelection as any)\n .text(_d => (_d).toString())\n ;\n tdSelection.exit().remove();\n })\n ;\n trSelection.exit().remove();\n }\n}\nSimpleTable.prototype._class += \" html_SimpleTable\";\n\nexport interface SimpleTable {\n autoWidth(): boolean;\n autoWidth(_: boolean): this;\n}\nSimpleTable.prototype.publish(\"autoWidth\", false, \"boolean\", \"If true, table width will be set to 'auto'. If false, the width is set to '100%'\");\n","import { SimpleTable } from \"./SimpleTable.ts\";\n\nexport class StyledTable extends SimpleTable {\n constructor() {\n super();\n }\n\n protected applyStyleObject(selection, styleObject) {\n Object.keys(styleObject).forEach(styleName => {\n selection.style(styleName, styleObject[styleName]);\n });\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n element.selectAll(\"tr,th,td\")\n .attr(\"style\", \"\")\n .style(\"font-family\", this.fontFamily())\n .style(\"color\", this.fontColor())\n ;\n\n this.theadColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.select(`.th-${i}`), styleObj);\n });\n this.tbodyColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.selectAll(`.col-${i}`), styleObj);\n });\n const evenRowStylesExist = Object.keys(this.evenRowStyles()).length > 0;\n const lastRowStylesExist = Object.keys(this.lastRowStyles()).length > 0;\n const tbodyRows = element.selectAll(\"tbody > tr\");\n if (evenRowStylesExist) {\n const tbodyEvenRows = tbodyRows.select(function (this: HTMLElement, d, i) { return i % 2 ? this : null; });\n this.applyStyleObject(tbodyEvenRows, this.evenRowStyles());\n }\n if (lastRowStylesExist) {\n const tbodyLastRow = tbodyRows.select(function (this: HTMLElement, d, i, arr) { return i === arr.length - 1 ? this : null; });\n this.applyStyleObject(tbodyLastRow, this.lastRowStyles());\n }\n }\n}\nStyledTable.prototype._class += \" html_StyledTable\";\n\nexport interface StyledTable {\n fontFamily(): string;\n fontFamily(_: string): this;\n fontColor(): string;\n fontColor(_: string): this;\n tbodyColumnStyles(): Array<{ [styleID: string]: any }>;\n tbodyColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n tbodyColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles(): Array<{ [styleID: string]: any }>;\n theadColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n lastRowStyles(): { [styleID: string]: any };\n lastRowStyles(_: { [styleID: string]: any }): this;\n lastRowStyles_default(_: { [styleID: string]: any }): this;\n evenRowStyles(): { [styleID: string]: any };\n evenRowStyles(_: { [styleID: string]: any }): this;\n evenRowStyles_default(_: { [styleID: string]: any }): this;\n}\n\nStyledTable.prototype.publish(\"fontFamily\", \"Verdana\", \"string\", \"Base font-family used within the table\");\nStyledTable.prototype.publish(\"fontColor\", \"#333\", \"string\", \"Base font color used within the table\");\nStyledTable.prototype.publish(\"theadColumnStyles\", [], \"array\", 'Array of objects containing styles for the thead columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"tbodyColumnStyles\", [], \"array\", 'Array of objects containing styles for the tbody columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"lastRowStyles\", {}, \"object\", 'Object containing styles for the last row (ex: {\"color\":\"red\"})');\nStyledTable.prototype.publish(\"evenRowStyles\", {}, \"object\", 'Object containing styles for even rows (ex: {\"background-color\":\"#AAA\"})');\n","import { HTMLTooltip } from \"./HTMLTooltip.ts\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class BreakdownTable extends StyledTable {\n // protected _table;\n // protected _tbody;\n protected _tooltip: HTMLTooltip;\n constructor() {\n super();\n }\n\n protected transformData() {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n return this.breakdownData(rowCount);\n }\n\n protected breakdownData(limit: number): any[] {\n const len = this.data().length;\n const sum = this.data().reduce((acc, row) => acc + row[1], 0);\n const data = [];\n let percSum = 0;\n this.data().sort((a, b) => a[1] > b[1] ? -1 : 1);\n const hiddenRowCount = len - limit;\n const showOther = hiddenRowCount > 0;\n this.data()\n .filter((_, i) => showOther ? i < limit - 1 : true)\n .forEach(row => {\n const perc = Math.round((row[1] / sum) * 100);\n percSum += perc;\n data.push([row[0], perc + \"%\"]);\n });\n if (showOther) {\n const otherLabel = `${this.otherLabel()} (${len - limit + 1})`;\n const otherPercentage = \"~\" + (100 - percSum) + \"%\";\n data.push([otherLabel, otherPercentage]);\n }\n return data;\n }\n\n protected calculateRowCount(): number {\n const theadRowHeight = this.columns().length > 0 ? this.thFontSize() + 5 : 0;\n const tbodyRowHeight = this.fontSize() + 5;\n const tbodyAvailableHeight = this.height() - theadRowHeight;\n const rowCount = Math.floor(tbodyAvailableHeight / tbodyRowHeight);\n return rowCount;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._tooltip = new HTMLTooltip()\n .target(domNode)\n ;\n this._tooltip\n .tooltipHTML(data => {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n const rowHeight = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).height)) ?? this.fontSize();\n const widestLabel = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).width));\n const widestPerc = 30;\n const colCount = 2;\n const w = colCount * (widestLabel + widestPerc) + (this._tooltip.padding() * 2);\n const h = rowHeight * Math.ceil((data.length - rowCount) / colCount) + (this._tooltip.padding() * 2);\n this._tooltip.tooltipWidth(w);\n this._tooltip.tooltipHeight(h);\n const otherData = this.breakdownData(this.data().length).slice(rowCount - 1);\n return `<div style=\"\n width: 100%;\n height: 100%;\n font-size: ${this.fontSize()}px;\n \">${otherData.map(row =>\n `<div style=\"\n float:left;\n width:${Math.floor(99 / colCount)}%;\n \">${row[0]}: ${row[1]}</div>`\n ).join(\"\")\n }</div>`;\n })\n ;\n }\n\n update(domNode, element) {\n this.theadColumnStyles_default([\n {\n \"color\": this.thFirstColor(),\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"width\": \"1%\",\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.percentageAlignment(),\n \"padding\": \"0px\"\n }\n ]);\n this.tbodyColumnStyles_default([\n {\n \"color\": this.topLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.topPercentageColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n this.lastRowStyles_default([\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherLabelBold() ? \"bold\" : \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherPercentageBold() ? \"bold\" : \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n\n super.update(domNode, element);\n\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n if (rowCount < this.data().length) {\n const lastRow = element.select(\"tbody > tr:last-child\");\n const context = this;\n lastRow\n .on(\"mouseout.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .visible(false)\n .render()\n ;\n })\n .on(\"mouseenter.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .direction(\"n\")\n .data(context.data())\n .visible(true)\n .render()\n ;\n })\n ;\n }\n }\n\n}\nBreakdownTable.prototype._class += \" html_BreakdownTable\";\n\nexport interface BreakdownTable {\n useCalculatedRowCount(): boolean;\n useCalculatedRowCount(_: boolean): this;\n rowCount(): number;\n rowCount(_: number): this;\n fontSize(): number;\n fontSize(_: number): this;\n thFirstColor(): string;\n thFirstColor(_: string): this;\n thLastColor(): string;\n thLastColor(_: string): this;\n thFontSize(): number;\n thFontSize(_: number): this;\n thFontWeight(): string;\n thFontWeight(_: string): this;\n labelAlignment(): \"left\" | \"center\" | \"right\";\n labelAlignment(_: \"left\" | \"center\" | \"right\"): this;\n percentageAlignment(): \"left\" | \"center\" | \"right\";\n percentageAlignment(_: \"left\" | \"center\" | \"right\"): this;\n topLabelColor(): string;\n topLabelColor(_: string): this;\n topPercentageColor(): string;\n topPercentageColor(_: string): this;\n topPercentageBold(): boolean;\n topPercentageBold(_: boolean): this;\n otherLabel(): string;\n otherLabel(_: string): this;\n otherLabelColor(): string;\n otherLabelColor(_: string): this;\n otherLabelBold(): boolean;\n otherLabelBold(_: boolean): this;\n otherPercentageColor(): string;\n otherPercentageColor(_: string): this;\n otherPercentageBold(): boolean;\n otherPercentageBold(_: boolean): this;\n}\n\nBreakdownTable.prototype.publish(\"useCalculatedRowCount\", true, \"boolean\", \"If true, rowCount will be calculated and its default will be overwritten\");\nBreakdownTable.prototype.publish(\"rowCount\", 5, \"number\", \"Number of total rows to display (including the 'other' row)\", undefined, { disable: w => w.useCalculatedRowCount() });\nBreakdownTable.prototype.publish(\"fontSize\", 14, \"number\", \"Font size (pixels)\");\nBreakdownTable.prototype.publish(\"labelAlignment\", \"left\", \"set\", \"Alignment of the label column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"percentageAlignment\", \"center\", \"set\", \"Alignment of the percentage column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"topLabelColor\", \"#333\", \"html-color\", \"Color of displayed 'top' labels\");\nBreakdownTable.prototype.publish(\"topPercentageColor\", \"#1A99D5\", \"html-color\", \"Color of displayed 'top' percentages\");\nBreakdownTable.prototype.publish(\"topPercentageBold\", true, \"html-color\", \"If true, the 'top' percentages will be bold\");\nBreakdownTable.prototype.publish(\"otherLabel\", \"Other\", \"string\", \"Label text for the 'other' row\");\nBreakdownTable.prototype.publish(\"otherLabelColor\", \"#AAA\", \"html-color\", \"Color of the 'other' label\");\nBreakdownTable.prototype.publish(\"otherLabelBold\", false, \"html-color\", \"If true, the 'other' label will be bold\");\nBreakdownTable.prototype.publish(\"otherPercentageColor\", \"#AAA\", \"html-color\", \"Color of the 'other' percentage\");\nBreakdownTable.prototype.publish(\"otherPercentageBold\", false, \"html-color\", \"If true, the 'other' percentage will be bold\");\nBreakdownTable.prototype.publish(\"thFontWeight\", \"bold\", \"string\", \"Font weight for th elements\");\nBreakdownTable.prototype.publish(\"thFontSize\", 26, \"number\", \"Font size for th elements\");\nBreakdownTable.prototype.publish(\"thFirstColor\", \"#333\", \"html-color\", \"Text color of the first th element\");\nBreakdownTable.prototype.publish(\"thLastColor\", \"#333\", \"html-color\", \"Text color of the last th element\");\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { React } from \"@hpcc-js/react\";\n\nexport class JSXWidget extends HTMLWidget {\n static Component = React.Component;\n static createElement = React.createElement;\n protected rootNode;\n\n jsxRender(jsx, domNode) {\n this.rootNode = React.render(jsx, domNode, this.rootNode);\n }\n}\nJSXWidget.prototype._class += \" html_JSXWidget\";\n","import { select as d3Select } from \"@hpcc-js/common\";\n\nexport type ReactFn = (attrs: { [key: string]: string }) => VNode;\n\nexport type IVNode = new (attrs: { [key: string]: string }, children: VNode[]) => VNode;\n\nexport class VNode {\n protected _attrs: { [key: string]: string };\n protected _children: VNode[];\n\n constructor(attrs: { [key: string]: string }, children: VNode[]) {\n this._attrs = attrs;\n this._children = children;\n }\n\n type(): string {\n return \"div\";\n }\n\n attrs(): { [key: string]: string } {\n return this._attrs;\n }\n\n attr(key) {\n return this._attrs[key];\n }\n\n children(): VNode[] {\n return this._children;\n }\n\n update(targetElement) {\n for (const key in this._attrs) {\n targetElement.attr(key, this._attrs[key]);\n }\n }\n\n render(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(this.type())\n .attr(\"reactd3\", 0)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n\n renderChildren(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(d => document.createElement(d.type()))\n .attr(\"reactd3\", (_d, i) => i)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n}\n\nclass ConstVNode extends VNode {\n protected _type: string;\n\n constructor(type: string, attrs: { [key: string]: string }, children: VNode[]) {\n super(attrs, children);\n this._type = type;\n }\n\n type(): string {\n return this._type;\n }\n}\n\nclass TextVNode extends VNode {\n protected _text: string;\n\n constructor(text: string) {\n super({}, []);\n this._text = text;\n }\n\n type(): string {\n return \"span\";\n }\n\n update(targetElement) {\n super.update(targetElement);\n targetElement.text(this._text);\n }\n}\n\nfunction isReactFn(_): _ is ReactFn {\n return typeof _ === \"function\";\n}\n\nfunction isIVNode(_: any): _ is IVNode {\n return _.prototype && _.prototype instanceof VNode;\n}\n\nexport class ReactD3 {\n // static createElementXXX(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n static createElement(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n if (isIVNode(type)) {\n return new (type as any)(attrs);\n } else if (isReactFn(type)) {\n return type(attrs);\n }\n return new ConstVNode(type, attrs, children.map(child => {\n if (typeof child === \"string\") {\n return new TextVNode(child);\n }\n return child;\n }));\n }\n\n static render(vdom: VNode, targetElement) {\n vdom.render(targetElement);\n }\n}\n","var n,l,u,t,i,o,r,f,e,c,s,a,h={},v=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function _(l,u,t){var i,o,r,f={};for(r in u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),\"function\"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g(l,f,i,o,null)}function g(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function m(){return{current:null}}function b(n){return n.children}function k(n,l){this.props=n,this.context=l}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return\"function\"==typeof n.type?x(n):null}function C(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C(n)}}function S(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!M.__r++||o!==l.debounceRendering)&&((o=l.debounceRendering)||r)(M)}function M(){var n,u,t,o,r,e,c,s;for(i.sort(f);n=i.shift();)n.__d&&(u=i.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l.vnode&&l.vnode(o),O(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j(c,o,s),o.__e!=e&&C(o)),i.length>u&&i.sort(f));M.__r=0}function P(n,l,u,t,i,o,r,f,e,c,s){var a,p,y,d,w,_=t&&t.__k||v,g=l.length;for(u.__d=e,$(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&(p=-1===y.__i?h:_[y.__i]||h,y.__i=a,O(n,y,p,i,o,r,f,e,c,s),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&E(p.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||p.__k===y.__k?e=I(y,e,n):\"function\"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w}function $(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=l[t])&&\"boolean\"!=typeof i&&\"function\"!=typeof i?(r=t+a,(i=n.__k[t]=\"string\"==typeof i||\"number\"==typeof i||\"bigint\"==typeof i||i.constructor==String?g(null,i,null,null,null):y(i)?g(b,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=n,i.__b=n.__b+1,o=null,-1!==(f=i.__i=L(i,u,r,s))&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,\"function\"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a--:f==r+1?a++:(f>r?a--:a++,i.__u|=65536))):i=n.__k[t]=null;if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),N(o,o))}function I(n,l,u){var t,i;if(\"function\"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||\"boolean\"==typeof n||(y(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function L(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if((\"function\"!=typeof o||o===b||i)&&t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){\"-\"===l[0]?n.setProperty(l,null==u?\"\":u):n[l]=null==u?\"\":\"number\"!=typeof u||p.test(l)?u:u+\"px\"}function A(n,l,u,t,i){var o;n:if(\"style\"===l)if(\"string\"==typeof u)n.style.cssText=u;else{if(\"string\"==typeof t&&(n.style.cssText=t=\"\"),t)for(l in t)u&&l in u||T(n.style,l,\"\");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if(\"o\"===l[0]&&\"n\"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,\"$1\")),l=l.toLowerCase()in n||\"onFocusOut\"===l||\"onFocusIn\"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e,n.addEventListener(l,o?s:c,o)):n.removeEventListener(l,o?s:c,o);else{if(\"http://www.w3.org/2000/svg\"==i)l=l.replace(/xlink(H|:h)/,\"h\").replace(/sName$/,\"s\");else if(\"width\"!=l&&\"height\"!=l&&\"href\"!=l&&\"list\"!=l&&\"form\"!=l&&\"tabIndex\"!=l&&\"download\"!=l&&\"rowSpan\"!=l&&\"colSpan\"!=l&&\"role\"!=l&&\"popover\"!=l&&l in n)try{n[l]=null==u?\"\":u;break n}catch(n){}\"function\"==typeof u||(null==u||!1===u&&\"-\"!==l[4]?n.removeAttribute(l):n.setAttribute(l,\"popover\"==l&&1==u?\"\":u))}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e++;else if(u.t<t.u)return;return l.event&&(u=l.event(u)),\"handleEvent\"in t?t.handleEvent(u):t(u)}}}function O(n,u,t,i,o,r,f,e,c,s){var a,h,v,p,w,_,g,m,x,C,S,M,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if(\"function\"==typeof T)try{if(m=u.props,x=\"prototype\"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],S=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,S):(u.__c=h=new k(m,S),h.constructor=T,h.render=V),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=S,h.__n=i,v=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),p=h.props,w=h.state,h.__v=u,v)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else{if(x&&null==T.getDerivedStateFromProps&&m!==p&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,S),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,S)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.some(function(n){n&&(n.__=u)}),M=0;M<h._sb.length;M++)h.__h.push(h._sb[M]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,S),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(p,w,_)})}if(h.context=S,h.props=m,h.__P=n,h.__e=!1,$=l.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[]}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!v&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(p,w)),P(n,y(L=null!=a&&a.type===b&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null)}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:128;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e}else u.__e=t.__e,u.__k=t.__k;l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)E(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(u,t,i,o,r,f,e,c,s){var a,v,p,d,_,g,m,b=i.props,k=t.props,C=t.type;if(\"svg\"===C?r=\"http://www.w3.org/2000/svg\":\"math\"===C?r=\"http://www.w3.org/1998/Math/MathML\":r||(r=\"http://www.w3.org/1999/xhtml\"),null!=f)for(a=0;a<f.length;a++)if((_=f[a])&&\"setAttribute\"in _==!!C&&(C?_.localName===C:3===_.nodeType)){u=_,f[a]=null;break}if(null==u){if(null===C)return document.createTextNode(k);u=document.createElementNS(r,C,k.is&&k),c&&(l.__m&&l.__m(t,f),c=!1),f=null}if(null===C)b===k||c&&u.data===k||(u.data=k);else{if(f=f&&n.call(u.childNodes),b=i.props||h,!c&&null!=f)for(b={},a=0;a<u.attributes.length;a++)b[(_=u.attributes[a]).name]=_.value;for(a in b)if(_=b[a],\"children\"==a);else if(\"dangerouslySetInnerHTML\"==a)p=_;else if(!(a in k)){if(\"value\"==a&&\"defaultValue\"in k||\"checked\"==a&&\"defaultChecked\"in k)continue;A(u,a,null,_,r)}for(a in k)_=k[a],\"children\"==a?d=_:\"dangerouslySetInnerHTML\"==a?v=_:\"value\"==a?g=_:\"checked\"==a?m=_:c&&\"function\"!=typeof _||b[a]===_||A(u,a,_,b[a],r);if(v)c||p&&(v.__html===p.__html||v.__html===u.innerHTML)||(u.innerHTML=v.__html),t.__k=[];else if(p&&(u.innerHTML=\"\"),P(u,y(d)?d:[d],t,i,o,\"foreignObject\"===C?\"http://www.w3.org/1999/xhtml\":r,f,e,f?f[0]:i.__k&&x(i,0),c,s),null!=f)for(a=f.length;a--;)w(f[a]);c||(a=\"value\",\"progress\"===C&&null==g?u.removeAttribute(\"value\"):void 0!==g&&(g!==u[a]||\"progress\"===C&&!g||\"option\"===C&&g!==b[a])&&A(u,a,g,b[a],r),a=\"checked\",void 0!==m&&m!==u[a]&&A(u,a,m,b[a],r))}return u}function E(n,u,t){try{if(\"function\"==typeof n){var i=\"function\"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u))}else n.current=u}catch(n){l.__e(n,t)}}function N(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||E(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&N(i[o],u,t||\"function\"!=typeof n.type);t||w(n.__e),n.__c=n.__=n.__e=n.__d=void 0}function V(n,l,u){return this.constructor(n,u)}function q(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o=\"function\"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O(t,u=(!o&&i||t).__k=_(b,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j(f,u,e)}function B(n,l){q(n,l,B)}function D(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l=\"__cC\"+a++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=new Set,(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.forEach(function(n){n.__e=!0,S(n)})},this.sub=function(n){u.add(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.delete(n),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=v.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},u=0,t=function(n){return null!=n&&null==n.constructor},k.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),\"function\"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),S(this))},k.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),S(this))},k.prototype.render=b,i=[],r=\"function\"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f=function(n,l){return n.__v.__b-l.__v.__b},M.__r=0,e=0,c=F(!1),s=F(!0),a=0;export{k as Component,b as Fragment,D as cloneElement,G as createContext,_ as createElement,m as createRef,_ as h,B as hydrate,t as isValidElement,l as options,q as render,H as toChildArray};\n//# sourceMappingURL=preact.module.js.map\n","import{options as r,Fragment as e}from\"preact\";export{Fragment}from\"preact\";var t=/[\"&<]/;function n(r){if(0===r.length||!1===t.test(r))return r;for(var e=0,n=0,o=\"\",f=\"\";n<r.length;n++){switch(r.charCodeAt(n)){case 34:f=\"&quot;\";break;case 38:f=\"&amp;\";break;case 60:f=\"&lt;\";break;default:continue}n!==e&&(o+=r.slice(e,n)),o+=f,e=n+1}return n!==e&&(o+=r.slice(e,n)),o}var o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,f=0,i=Array.isArray;function u(e,t,n,o,i,u){t||(t={});var a,c,l=t;\"ref\"in t&&(a=t.ref,delete t.ref);var p={type:e,props:l,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u};if(\"function\"==typeof e&&(a=e.defaultProps))for(c in a)void 0===l[c]&&(l[c]=a[c]);return r.vnode&&r.vnode(p),p}function a(r){var t=u(e,{tpl:r,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var c={},l=/[A-Z]/g;function p(e,t){if(r.attr){var f=r.attr(e,t);if(\"string\"==typeof f)return f}if(\"ref\"===e||\"key\"===e)return\"\";if(\"style\"===e&&\"object\"==typeof t){var i=\"\";for(var u in t){var a=t[u];if(null!=a&&\"\"!==a){var p=\"-\"==u[0]?u:c[u]||(c[u]=u.replace(l,\"-$&\").toLowerCase()),_=\";\";\"number\"!=typeof a||p.startsWith(\"--\")||o.test(p)||(_=\"px;\"),i=i+p+\":\"+a+_}}return e+'=\"'+i+'\"'}return null==t||!1===t||\"function\"==typeof t||\"object\"==typeof t?\"\":!0===t?e:e+'=\"'+n(t)+'\"'}function _(r){if(null==r||\"boolean\"==typeof r||\"function\"==typeof r)return null;if(\"object\"==typeof r){if(void 0===r.constructor)return r;if(i(r)){for(var e=0;e<r.length;e++)r[e]=_(r[e]);return r}}return n(\"\"+r)}export{u as jsx,p as jsxAttr,u as jsxDEV,_ as jsxEscape,a as jsxTemplate,u as jsxs};\n//# sourceMappingURL=jsxRuntime.module.js.map\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizComponent extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = new (this as any).props.type()\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizInstance extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = (this as any).props.instance\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { format as d3Format } from \"d3-format\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class StatsTable extends StyledTable {\n\n protected transformData() {\n const totalRow = [[\"Total\", 0, 0]];\n const data = this.data();\n data.forEach(row => {\n totalRow[0][1] += row[1];\n totalRow[0][2] += row[2];\n });\n return data\n .concat(totalRow)\n .map(row => {\n return [\n row[0],\n this.secondColumnFormat_exists() ? d3Format(this.secondColumnFormat())(row[1]) : row[1],\n this.thirdColumnFormat_exists() ? d3Format(this.thirdColumnFormat())(row[2]) : row[2]\n ];\n })\n ;\n }\n\n update(domNode, element) {\n this.tbodyColumnStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\"\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\"\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\"\n }\n ]);\n this.evenRowStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n }\n ]);\n this.lastRowStyles_default({\n \"font-weight\": \"bold\"\n });\n super.update(domNode, element);\n }\n}\nStatsTable.prototype._class += \" html_StatsTable\";\n\nexport interface StatsTable {\n labelColor(): string;\n labelColor(_: string): this;\n primaryValueColor(): string;\n primaryValueColor(_: string): this;\n secondaryValueColor(): string;\n secondaryValueColor(_: string): this;\n evenRowFontColor(): string;\n evenRowFontColor(_: string): this;\n evenRowBackgroundColor(): string;\n evenRowBackgroundColor(_: string): this;\n firstColumnWidth(): string;\n firstColumnWidth(_: string): this;\n secondColumnWidth(): string;\n secondColumnWidth(_: string): this;\n thirdColumnWidth(): string;\n thirdColumnWidth(_: string): this;\n secondColumnFormat(): string;\n secondColumnFormat(_: string): this;\n secondColumnFormat_exists(): boolean;\n thirdColumnFormat(): string;\n thirdColumnFormat(_: string): this;\n thirdColumnFormat_exists(): boolean;\n}\nStatsTable.prototype.publish(\"labelColor\", \"#333\", \"html-color\", \"Color of the text in the first column\");\nStatsTable.prototype.publish(\"primaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the second column\");\nStatsTable.prototype.publish(\"secondaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the third column\");\nStatsTable.prototype.publish(\"evenRowBackgroundColor\", \"#333\", \"html-color\", \"Background color of the even rows\");\nStatsTable.prototype.publish(\"evenRowFontColor\", \"#333\", \"html-color\", \"Font color of the even rows\");\nStatsTable.prototype.publish(\"firstColumnWidth\", \"auto\", \"string\", \"CSS style applied as the 'width' for the first column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the second column (ex: 40px)\");\nStatsTable.prototype.publish(\"thirdColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the third column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnFormat\", \"$,.0f\", \"string\", \"d3-format specifier applied to the second column's values\", undefined, { optional: true });\nStatsTable.prototype.publish(\"thirdColumnFormat\", null, \"string\", \"d3-format specifier applied to the third column's values\", undefined, { optional: true });\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { JSXWidget } from \"./JSXWidget.ts\";\n\nimport \"../src/TitleBar.css\";\n\nexport interface IClickHandler {\n titleBarClick(src: Item, d, idx: number, groups): void;\n}\n\nexport class Item extends HTMLWidget {\n protected _owner: IClickHandler;\n\n constructor(owner: IClickHandler) {\n super();\n this._owner = owner;\n this._tag = \"a\";\n }\n}\nItem.prototype._class += \" html_Item\";\n\nexport class Button extends Item {\n private _icon: string;\n\n constructor(owner: IClickHandler, icon: string) {\n super(owner);\n this._icon = icon;\n }\n\n icon() {\n return this._icon;\n }\n\n enter(domNode: HTMLElement, element) {\n super.enter(domNode, element);\n element\n .attr(\"href\", \"#\")\n .on(\"click\", (d, idx, groups) => this._owner.titleBarClick(this, d, idx, groups))\n .append(\"i\")\n .attr(\"class\", `fa ${this._icon} fa-lg fa-fw`)\n ;\n }\n}\nButton.prototype._class += \" html_Button\";\n\nexport class ToggleButton extends Button {\n\n enter(domNode: HTMLElement, element) {\n element.on(\"click.sel\", (d, idx, groups) => {\n this.selected(!this.selected());\n this.render();\n });\n super.enter(domNode, element);\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._element.classed(\"selected\", this.selected());\n }\n}\nToggleButton.prototype._class += \" html_ToggleButton\";\nexport interface ToggleButton {\n selected(): boolean;\n selected(_: boolean): this;\n}\nToggleButton.prototype.publish(\"selected\", false, \"boolean\");\n\nexport class Spacer extends Item {\n\n enter(domNode, element) {\n super.enter(domNode, element);\n element\n .attr(\"class\", \"spacer\")\n .attr(\"href\", \"#\")\n .append(\"i\")\n ;\n }\n}\nSpacer.prototype._class += \" html_Spacer\";\n\nexport class TitleBar extends JSXWidget {\n protected _divMain;\n protected _divIconBar;\n protected _divTitle;\n\n constructor() {\n super();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._divMain = element.append(\"div\")\n .attr(\"class\", \"main\")\n ;\n this._divIconBar = this._divMain.append(\"div\")\n .attr(\"class\", \"icon-bar\")\n ;\n this._divTitle = this._divMain.append(\"div\")\n .attr(\"class\", \"title\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n this._divTitle.text(this.title());\n\n const icons = this._divIconBar.selectAll(\".icon-bar-item\").data(this.buttons());\n icons.enter().append(\"div\")\n .attr(\"class\", \"icon-bar-item\")\n .each(function (this: HTMLElement, d: Item) {\n d.target(this);\n })\n .merge(icons)\n .each(function (d: Item) {\n d.render();\n })\n ;\n icons.exit()\n .each(function (d: Item) {\n d.target(null);\n })\n .remove()\n ;\n icons.order();\n }\n}\nTitleBar.prototype._class += \" html_TitleBar\";\n\nexport interface TitleBar {\n title(): string;\n title(_: string): this;\n buttons(): Item[];\n buttons(items: Item[]): this;\n}\nTitleBar.prototype.publish(\"title\", \"\", \"string\");\nTitleBar.prototype.publish(\"buttons\", [], \"widgetArray\");\n"],"names":["d3Select","l","u","r","jsx","d3Format"],"mappings":";;;;;;AAAO,MAAM,WAAW,iBACX,cAAc,S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ACA,OAAO,GAEZ,MAAM,MAAM;AAAA,EAAA;AAEpB;AACA,SAAS,UAAU,UAAU;AAQ7B,SAAS,UAAU,QAAQ,SAAS,IAAI,QAAQ;AAChD,SAAS,UAAU,QAAQ,WAAW,CAAA,GAAI,aAAa;","x_google_ignoreList":[7,8]}
1
+ {"version":3,"file":"index.js","sources":["../src/__package__.ts","../src/HTMLTooltip.ts","../src/SimpleTable.ts","../src/StyledTable.ts","../src/BreakdownTable.ts","../src/JSXWidget.ts","../src/reactD3.ts","../../../node_modules/preact/dist/preact.module.js","../../../node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js","../src/VizComponent.tsx","../src/VizInstance.tsx","../src/StatsTable.ts","../src/TitleBar.ts"],"sourcesContent":["export const PKG_NAME = \"@hpcc-js/html\";\nexport const PKG_VERSION = \"3.1.1\";\nexport const BUILD_VERSION = \"3.2.1\";\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\nimport { scopedLogger, ScopedLogging } from \"@hpcc-js/util\";\n\ntype Direction = \"n\" | \"s\" | \"e\" | \"w\" | \"ne\" | \"nw\" | \"se\" | \"sw\";\ntype Position = { x: number, y: number };\ntype DirectionalBBox = { [key in Direction]: Position; };\n\ntype Rectangle = { top: number, left: number, width: number, height: number };\nexport class HTMLTooltip extends HTMLWidget {\n\n public _triggerElement;\n public _contentNode;\n protected _prevContentNode;\n\n protected _tooltipElement;\n protected _arrowElement;\n protected _tooltipHTMLCallback = (data?) => \"<b>_tooltipHTMLCallback is undefined</b>\";\n protected _logger: ScopedLogging = scopedLogger(\"html/HTMLTooltip\");\n constructor() {\n super();\n this.visible(false);\n }\n\n tooltipHTML(_: (data?) => string): this {\n this._tooltipHTMLCallback = _;\n return this;\n }\n\n tooltipContent(_): this {\n if (!arguments.length) return this._contentNode;\n this._contentNode = _;\n return this;\n }\n\n triggerElement(_): this {\n this._triggerElement = _;\n return this;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n const body = d3Select(\"body\");\n this._tooltipElement = body.append(\"div\")\n .attr(\"class\", \"tooltip-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n this._arrowElement = body.append(\"div\")\n .attr(\"class\", \"arrow-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n if (this._contentNode !== this._prevContentNode) {\n const node = this._tooltipElement.node();\n [...node.querySelectorAll(\"*\")]\n .map(n => n.__data__)\n .filter(n => n)\n .forEach(w => {\n if (typeof w.target === \"function\") {\n w.target(null);\n }\n if (typeof w.exit === \"function\") {\n w.exit();\n }\n });\n node.innerHTML = \"\";\n node.appendChild(this._contentNode);\n this._prevContentNode = this._contentNode;\n }\n\n if (this._contentNode) {\n this.onShowContent(this._contentNode);\n } else {\n this._tooltipElement\n .html(() => {\n return this._tooltipHTMLCallback(this.data());\n });\n }\n if (this.fitContent()) {\n this._tooltipElement\n .style(\"width\", \"auto\")\n .style(\"height\", \"auto\")\n .style(\"padding\", \"0px\")\n .style(\"box-sizing\", \"content-box\")\n ;\n const rect = this._tooltipElement.node().getBoundingClientRect();\n this.tooltipWidth_default(rect.width);\n this.tooltipHeight_default(rect.height);\n }\n this._closing = false;\n this._tooltipElement\n .style(\"background-color\", this.tooltipColor())\n .style(\"color\", this.fontColor())\n .style(\"width\", this.tooltipWidth() + \"px\")\n .style(\"height\", this.tooltipHeight() + \"px\")\n .style(\"opacity\", 1)\n .style(\"padding\", this.padding() + \"px\")\n .style(\"pointer-events\", this.enablePointerEvents() ? \"all\" : \"none\")\n .style(\"box-sizing\", \"content-box\")\n ;\n this._arrowElement\n .style(\"opacity\", 1)\n .style(\"pointer-events\", \"none\")\n ;\n this.updateTooltipPosition();\n }\n\n onShowContent(node) {\n\n }\n\n protected updateTooltipPosition(): Position {\n const bbox = this.calcReferenceBBox();\n const direction = this.calcTooltipDirection(bbox);\n const box = bbox[direction];\n this._tooltipElement\n .style(\"top\", box.y + \"px\")\n .style(\"left\", box.x + \"px\")\n ;\n this.setArrowPosition(box, direction);\n return box;\n }\n\n protected calcTooltipDirection(bbox: DirectionalBBox): Direction {\n const directions: Direction[] = Object.keys(bbox) as Direction[];\n\n const defaultDirection = this.direction();\n directions.sort((a, b) => a === defaultDirection ? -1 : 1);\n const windowRect = {\n top: 0,\n left: 0,\n width: window.innerWidth,\n height: window.innerHeight\n };\n for (let i = 0; i < directions.length; i++) {\n const tooltipRect = {\n top: bbox[directions[i]].y,\n left: bbox[directions[i]].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n };\n if (this.rectFits(tooltipRect, windowRect)) {\n return directions[i];\n }\n }\n this._logger.warning(`Tooltip doesn't fit in the window for any of the directions. Defaulting to '${defaultDirection}'`);\n this._logger.debug(windowRect);\n this._logger.debug({\n top: bbox[defaultDirection].y,\n left: bbox[defaultDirection].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n });\n return defaultDirection;\n }\n\n protected rectFits(innerRect: Rectangle, outerRect: Rectangle): boolean {\n return (\n innerRect.top >= outerRect.top &&\n innerRect.left >= outerRect.left &&\n innerRect.width + innerRect.left <= outerRect.width + outerRect.left &&\n innerRect.height + innerRect.top <= outerRect.height + outerRect.top\n );\n }\n\n protected setArrowPosition(point: Position, direction: Direction) {\n let top;\n let left;\n let visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border\", `${this.arrowHeight()}px solid ${this.tooltipColor()}`)\n .style(\"border-top-color\", \"transparent\")\n .style(\"border-right-color\", \"transparent\")\n .style(\"border-bottom-color\", \"transparent\")\n .style(\"border-left-color\", \"transparent\")\n ;\n switch (direction) {\n case \"n\":\n top = point.y + this.tooltipHeight() + (this.padding() * 2);\n left = point.x + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2) + this.padding();\n visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowHeight()}px`)\n .style(\"border-bottom-width\", \"0px\")\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"s\":\n top = point.y - this.arrowHeight();\n left = point.x + this.padding() + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2);\n visibleBorderStyle = \"border-bottom-color\";\n this._arrowElement\n .style(\"border-top-width\", \"0px\")\n .style(\"border-bottom-width\", `${this.arrowHeight()}px`)\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"e\":\n top = point.y + (this.tooltipHeight() / 2) + this.padding() - (this.arrowWidth() / 2);\n left = point.x - this.arrowHeight();\n visibleBorderStyle = \"border-right-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", \"0px\")\n .style(\"border-right-width\", `${this.arrowHeight()}px`)\n ;\n break;\n case \"w\":\n top = point.y + (this.tooltipHeight() / 2) - (this.arrowWidth() / 2) + this.padding();\n left = point.x + this.tooltipWidth() + (this.padding() * 2);\n visibleBorderStyle = \"border-left-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", `${this.arrowHeight()}px`)\n .style(\"border-right-width\", \"0px\")\n ;\n break;\n }\n if (typeof top !== \"undefined\" && typeof left !== \"undefined\") {\n this._arrowElement\n .style(\"top\", top + \"px\")\n .style(\"left\", left + \"px\")\n .style(visibleBorderStyle, this.tooltipColor())\n .style(\"opacity\", 1)\n ;\n } else {\n this._arrowElement\n .style(\"opacity\", 0)\n ;\n }\n return point;\n }\n\n protected getReferenceNode() {\n if (!this._triggerElement) {\n return this.element().node().parentNode.parentNode;\n }\n return this._triggerElement.node();\n }\n public _cursorLoc;\n protected calcReferenceBBox() {\n const node = this.getReferenceNode();\n let { top, left, width, height } = node.getBoundingClientRect();\n const wholeW = this.tooltipWidth();\n const wholeH = this.tooltipHeight();\n const halfW = wholeW / 2;\n const halfH = wholeH / 2;\n const arrowH = this.arrowHeight();\n const p = this.padding();\n const p2 = p * 2;\n\n if (this.followCursor() && this._cursorLoc) {\n\n left = this._cursorLoc[0];\n top = this._cursorLoc[1];\n width = 1;\n height = 1;\n }\n const bbox = {\n n: {\n x: left + (width / 2) - halfW - p,\n y: top - wholeH - arrowH - p2\n },\n e: {\n x: left + width + arrowH,\n y: top + (height / 2) - halfH - p\n },\n s: {\n x: left + (width / 2) - halfW - p,\n y: top + height + arrowH\n },\n w: {\n x: left - wholeW - arrowH - p2,\n y: top + (height / 2) - halfH - p\n },\n nw: {\n x: left - wholeW - p2,\n y: top - wholeH - p2\n },\n ne: {\n x: left + width,\n y: top - wholeH - p2\n },\n se: {\n x: left + width,\n y: top + height\n },\n sw: {\n x: left - wholeW - p2,\n y: top + height\n }\n };\n return bbox;\n }\n\n private _closing = false;\n mouseout() {\n this._closing = true;\n this._tooltipElement.on(\"mouseover\", () => {\n this._closing = false;\n });\n this._tooltipElement.on(\"mouseout\", () => {\n this.mouseout();\n });\n setTimeout(() => {\n if (this._closing) {\n this.visible(false);\n }\n }, this.closeDelay());\n }\n\n visible(): boolean;\n visible(_: boolean): this;\n visible(_?: boolean): boolean | this {\n if (!arguments.length) return super.visible();\n if (this._arrowElement) {\n this._arrowElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n this._tooltipElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n }\n super.visible(_);\n return this;\n }\n\n exit(domNode, element) {\n if (this._arrowElement) {\n this._arrowElement.remove();\n this._tooltipElement.remove();\n }\n super.exit(domNode, element);\n }\n}\nHTMLTooltip.prototype._class += \" html_HTMLTooltip\";\n\nexport interface HTMLTooltip {\n padding(): number;\n padding(_: number): this;\n direction(): Direction;\n direction(_: Direction): this;\n arrowHeight(): number;\n arrowHeight(_: number): this;\n arrowWidth(): number;\n arrowWidth(_: number): this;\n fontColor(): string;\n fontColor(_: string): this;\n tooltipColor(): string;\n tooltipColor(_: string): this;\n tooltipWidth(): number;\n tooltipWidth(_: number): this;\n tooltipWidth_default(_: number);\n tooltipHeight(): number;\n tooltipHeight(_: number): this;\n tooltipHeight_default(_: number);\n followCursor(): boolean;\n followCursor(_: boolean): this;\n enablePointerEvents(): boolean;\n enablePointerEvents(_: boolean): this;\n closeDelay(): number;\n closeDelay(_: number): this;\n fitContent(): boolean;\n fitContent(_: boolean): this;\n\n}\n\nHTMLTooltip.prototype.publish(\"fitContent\", false, \"boolean\", \"If true, tooltip will grow to fit its html content\");\nHTMLTooltip.prototype.publish(\"followCursor\", false, \"boolean\", \"If true, tooltip will display relative to cursor location\");\nHTMLTooltip.prototype.publish(\"closeDelay\", 400, \"number\", \"Number of milliseconds to wait before closing tooltip (cancelled on tooltip mouseover event)\");\nHTMLTooltip.prototype.publish(\"direction\", \"n\", \"set\", \"Direction in which to display the tooltip\", [\"n\", \"s\", \"e\", \"w\", \"ne\", \"nw\", \"se\", \"sw\"]);\nHTMLTooltip.prototype.publish(\"padding\", 8, \"number\", \"Padding (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowWidth\", 16, \"number\", \"Width (or height depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowHeight\", 8, \"number\", \"Height (or width depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"fontColor\", \"#FFF\", \"html-color\", \"The default font color for text in the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipColor\", \"#000000EE\", \"html-color\", \"Background color of the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipWidth\", 200, \"number\", \"Width of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"tooltipHeight\", 200, \"number\", \"Height of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"enablePointerEvents\", false, \"boolean\", \"If true, the 'pointer-events: all' style will be used\");\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\n\nexport class SimpleTable extends HTMLWidget {\n protected _table;\n protected _tbody;\n protected _thead;\n protected _theadRow;\n constructor() {\n super();\n }\n\n protected transformData() {\n return this.data();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n\n this._table = element.append(\"table\");\n this._thead = this._table.append(\"thead\");\n this._theadRow = this._thead.append(\"tr\");\n this._tbody = this._table.append(\"tbody\");\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._table\n .style(\"width\", this.autoWidth() ? \"auto\" : \"100%\")\n ;\n const theadTrSelection = this._theadRow.selectAll(\"th\").data(this.columns());\n theadTrSelection.enter()\n .append(\"th\")\n .attr(\"class\", (n, i) => `th-${i}`)\n .merge(theadTrSelection)\n .text(_d => (_d).toString())\n ;\n theadTrSelection.exit().remove();\n const trSelection = this._tbody.selectAll(\"tr\").data(this.transformData());\n trSelection.enter()\n .append(\"tr\")\n .merge(trSelection)\n .each(function (this, d) {\n const tr = d3Select(this);\n const tdSelection = tr.selectAll(\"td\").data(d);\n tdSelection.enter()\n .append(\"td\")\n .attr(\"class\", (n, i) => `col-${i}`)\n .merge(tdSelection as any)\n .text(_d => (_d).toString())\n ;\n tdSelection.exit().remove();\n })\n ;\n trSelection.exit().remove();\n }\n}\nSimpleTable.prototype._class += \" html_SimpleTable\";\n\nexport interface SimpleTable {\n autoWidth(): boolean;\n autoWidth(_: boolean): this;\n}\nSimpleTable.prototype.publish(\"autoWidth\", false, \"boolean\", \"If true, table width will be set to 'auto'. If false, the width is set to '100%'\");\n","import { SimpleTable } from \"./SimpleTable.ts\";\n\nexport class StyledTable extends SimpleTable {\n constructor() {\n super();\n }\n\n protected applyStyleObject(selection, styleObject) {\n Object.keys(styleObject).forEach(styleName => {\n selection.style(styleName, styleObject[styleName]);\n });\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n element.selectAll(\"tr,th,td\")\n .attr(\"style\", \"\")\n .style(\"font-family\", this.fontFamily())\n .style(\"color\", this.fontColor())\n ;\n\n this.theadColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.select(`.th-${i}`), styleObj);\n });\n this.tbodyColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.selectAll(`.col-${i}`), styleObj);\n });\n const evenRowStylesExist = Object.keys(this.evenRowStyles()).length > 0;\n const lastRowStylesExist = Object.keys(this.lastRowStyles()).length > 0;\n const tbodyRows = element.selectAll(\"tbody > tr\");\n if (evenRowStylesExist) {\n const tbodyEvenRows = tbodyRows.select(function (this: HTMLElement, d, i) { return i % 2 ? this : null; });\n this.applyStyleObject(tbodyEvenRows, this.evenRowStyles());\n }\n if (lastRowStylesExist) {\n const tbodyLastRow = tbodyRows.select(function (this: HTMLElement, d, i, arr) { return i === arr.length - 1 ? this : null; });\n this.applyStyleObject(tbodyLastRow, this.lastRowStyles());\n }\n }\n}\nStyledTable.prototype._class += \" html_StyledTable\";\n\nexport interface StyledTable {\n fontFamily(): string;\n fontFamily(_: string): this;\n fontColor(): string;\n fontColor(_: string): this;\n tbodyColumnStyles(): Array<{ [styleID: string]: any }>;\n tbodyColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n tbodyColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles(): Array<{ [styleID: string]: any }>;\n theadColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n lastRowStyles(): { [styleID: string]: any };\n lastRowStyles(_: { [styleID: string]: any }): this;\n lastRowStyles_default(_: { [styleID: string]: any }): this;\n evenRowStyles(): { [styleID: string]: any };\n evenRowStyles(_: { [styleID: string]: any }): this;\n evenRowStyles_default(_: { [styleID: string]: any }): this;\n}\n\nStyledTable.prototype.publish(\"fontFamily\", \"Verdana\", \"string\", \"Base font-family used within the table\");\nStyledTable.prototype.publish(\"fontColor\", \"#333\", \"string\", \"Base font color used within the table\");\nStyledTable.prototype.publish(\"theadColumnStyles\", [], \"array\", 'Array of objects containing styles for the thead columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"tbodyColumnStyles\", [], \"array\", 'Array of objects containing styles for the tbody columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"lastRowStyles\", {}, \"object\", 'Object containing styles for the last row (ex: {\"color\":\"red\"})');\nStyledTable.prototype.publish(\"evenRowStyles\", {}, \"object\", 'Object containing styles for even rows (ex: {\"background-color\":\"#AAA\"})');\n","import { HTMLTooltip } from \"./HTMLTooltip.ts\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class BreakdownTable extends StyledTable {\n // protected _table;\n // protected _tbody;\n protected _tooltip: HTMLTooltip;\n constructor() {\n super();\n }\n\n protected transformData() {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n return this.breakdownData(rowCount);\n }\n\n protected breakdownData(limit: number): any[] {\n const len = this.data().length;\n const sum = this.data().reduce((acc, row) => acc + row[1], 0);\n const data = [];\n let percSum = 0;\n this.data().sort((a, b) => a[1] > b[1] ? -1 : 1);\n const hiddenRowCount = len - limit;\n const showOther = hiddenRowCount > 0;\n this.data()\n .filter((_, i) => showOther ? i < limit - 1 : true)\n .forEach(row => {\n const perc = Math.round((row[1] / sum) * 100);\n percSum += perc;\n data.push([row[0], perc + \"%\"]);\n });\n if (showOther) {\n const otherLabel = `${this.otherLabel()} (${len - limit + 1})`;\n const otherPercentage = \"~\" + (100 - percSum) + \"%\";\n data.push([otherLabel, otherPercentage]);\n }\n return data;\n }\n\n protected calculateRowCount(): number {\n const theadRowHeight = this.columns().length > 0 ? this.thFontSize() + 5 : 0;\n const tbodyRowHeight = this.fontSize() + 5;\n const tbodyAvailableHeight = this.height() - theadRowHeight;\n const rowCount = Math.floor(tbodyAvailableHeight / tbodyRowHeight);\n return rowCount;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._tooltip = new HTMLTooltip()\n .target(domNode)\n ;\n this._tooltip\n .tooltipHTML(data => {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n const rowHeight = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).height)) ?? this.fontSize();\n const widestLabel = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).width));\n const widestPerc = 30;\n const colCount = 2;\n const w = colCount * (widestLabel + widestPerc) + (this._tooltip.padding() * 2);\n const h = rowHeight * Math.ceil((data.length - rowCount) / colCount) + (this._tooltip.padding() * 2);\n this._tooltip.tooltipWidth(w);\n this._tooltip.tooltipHeight(h);\n const otherData = this.breakdownData(this.data().length).slice(rowCount - 1);\n return `<div style=\"\n width: 100%;\n height: 100%;\n font-size: ${this.fontSize()}px;\n \">${otherData.map(row =>\n `<div style=\"\n float:left;\n width:${Math.floor(99 / colCount)}%;\n \">${row[0]}: ${row[1]}</div>`\n ).join(\"\")\n }</div>`;\n })\n ;\n }\n\n update(domNode, element) {\n this.theadColumnStyles_default([\n {\n \"color\": this.thFirstColor(),\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"width\": \"1%\",\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.percentageAlignment(),\n \"padding\": \"0px\"\n }\n ]);\n this.tbodyColumnStyles_default([\n {\n \"color\": this.topLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.topPercentageColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n this.lastRowStyles_default([\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherLabelBold() ? \"bold\" : \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherPercentageBold() ? \"bold\" : \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n\n super.update(domNode, element);\n\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n if (rowCount < this.data().length) {\n const lastRow = element.select(\"tbody > tr:last-child\");\n const context = this;\n lastRow\n .on(\"mouseout.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .visible(false)\n .render()\n ;\n })\n .on(\"mouseenter.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .direction(\"n\")\n .data(context.data())\n .visible(true)\n .render()\n ;\n })\n ;\n }\n }\n\n}\nBreakdownTable.prototype._class += \" html_BreakdownTable\";\n\nexport interface BreakdownTable {\n useCalculatedRowCount(): boolean;\n useCalculatedRowCount(_: boolean): this;\n rowCount(): number;\n rowCount(_: number): this;\n fontSize(): number;\n fontSize(_: number): this;\n thFirstColor(): string;\n thFirstColor(_: string): this;\n thLastColor(): string;\n thLastColor(_: string): this;\n thFontSize(): number;\n thFontSize(_: number): this;\n thFontWeight(): string;\n thFontWeight(_: string): this;\n labelAlignment(): \"left\" | \"center\" | \"right\";\n labelAlignment(_: \"left\" | \"center\" | \"right\"): this;\n percentageAlignment(): \"left\" | \"center\" | \"right\";\n percentageAlignment(_: \"left\" | \"center\" | \"right\"): this;\n topLabelColor(): string;\n topLabelColor(_: string): this;\n topPercentageColor(): string;\n topPercentageColor(_: string): this;\n topPercentageBold(): boolean;\n topPercentageBold(_: boolean): this;\n otherLabel(): string;\n otherLabel(_: string): this;\n otherLabelColor(): string;\n otherLabelColor(_: string): this;\n otherLabelBold(): boolean;\n otherLabelBold(_: boolean): this;\n otherPercentageColor(): string;\n otherPercentageColor(_: string): this;\n otherPercentageBold(): boolean;\n otherPercentageBold(_: boolean): this;\n}\n\nBreakdownTable.prototype.publish(\"useCalculatedRowCount\", true, \"boolean\", \"If true, rowCount will be calculated and its default will be overwritten\");\nBreakdownTable.prototype.publish(\"rowCount\", 5, \"number\", \"Number of total rows to display (including the 'other' row)\", undefined, { disable: w => w.useCalculatedRowCount() });\nBreakdownTable.prototype.publish(\"fontSize\", 14, \"number\", \"Font size (pixels)\");\nBreakdownTable.prototype.publish(\"labelAlignment\", \"left\", \"set\", \"Alignment of the label column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"percentageAlignment\", \"center\", \"set\", \"Alignment of the percentage column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"topLabelColor\", \"#333\", \"html-color\", \"Color of displayed 'top' labels\");\nBreakdownTable.prototype.publish(\"topPercentageColor\", \"#1A99D5\", \"html-color\", \"Color of displayed 'top' percentages\");\nBreakdownTable.prototype.publish(\"topPercentageBold\", true, \"html-color\", \"If true, the 'top' percentages will be bold\");\nBreakdownTable.prototype.publish(\"otherLabel\", \"Other\", \"string\", \"Label text for the 'other' row\");\nBreakdownTable.prototype.publish(\"otherLabelColor\", \"#AAA\", \"html-color\", \"Color of the 'other' label\");\nBreakdownTable.prototype.publish(\"otherLabelBold\", false, \"html-color\", \"If true, the 'other' label will be bold\");\nBreakdownTable.prototype.publish(\"otherPercentageColor\", \"#AAA\", \"html-color\", \"Color of the 'other' percentage\");\nBreakdownTable.prototype.publish(\"otherPercentageBold\", false, \"html-color\", \"If true, the 'other' percentage will be bold\");\nBreakdownTable.prototype.publish(\"thFontWeight\", \"bold\", \"string\", \"Font weight for th elements\");\nBreakdownTable.prototype.publish(\"thFontSize\", 26, \"number\", \"Font size for th elements\");\nBreakdownTable.prototype.publish(\"thFirstColor\", \"#333\", \"html-color\", \"Text color of the first th element\");\nBreakdownTable.prototype.publish(\"thLastColor\", \"#333\", \"html-color\", \"Text color of the last th element\");\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { React } from \"@hpcc-js/react\";\n\nexport class JSXWidget extends HTMLWidget {\n static Component = React.Component;\n static createElement = React.createElement;\n protected rootNode;\n\n jsxRender(jsx, domNode) {\n this.rootNode = React.render(jsx, domNode, this.rootNode);\n }\n}\nJSXWidget.prototype._class += \" html_JSXWidget\";\n","import { select as d3Select } from \"@hpcc-js/common\";\n\nexport type ReactFn = (attrs: { [key: string]: string }) => VNode;\n\nexport type IVNode = new (attrs: { [key: string]: string }, children: VNode[]) => VNode;\n\nexport class VNode {\n protected _attrs: { [key: string]: string };\n protected _children: VNode[];\n\n constructor(attrs: { [key: string]: string }, children: VNode[]) {\n this._attrs = attrs;\n this._children = children;\n }\n\n type(): string {\n return \"div\";\n }\n\n attrs(): { [key: string]: string } {\n return this._attrs;\n }\n\n attr(key) {\n return this._attrs[key];\n }\n\n children(): VNode[] {\n return this._children;\n }\n\n update(targetElement) {\n for (const key in this._attrs) {\n targetElement.attr(key, this._attrs[key]);\n }\n }\n\n render(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(this.type())\n .attr(\"reactd3\", 0)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n\n renderChildren(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(d => document.createElement(d.type()))\n .attr(\"reactd3\", (_d, i) => i)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n}\n\nclass ConstVNode extends VNode {\n protected _type: string;\n\n constructor(type: string, attrs: { [key: string]: string }, children: VNode[]) {\n super(attrs, children);\n this._type = type;\n }\n\n type(): string {\n return this._type;\n }\n}\n\nclass TextVNode extends VNode {\n protected _text: string;\n\n constructor(text: string) {\n super({}, []);\n this._text = text;\n }\n\n type(): string {\n return \"span\";\n }\n\n update(targetElement) {\n super.update(targetElement);\n targetElement.text(this._text);\n }\n}\n\nfunction isReactFn(_): _ is ReactFn {\n return typeof _ === \"function\";\n}\n\nfunction isIVNode(_: any): _ is IVNode {\n return _.prototype && _.prototype instanceof VNode;\n}\n\nexport class ReactD3 {\n // static createElementXXX(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n static createElement(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n if (isIVNode(type)) {\n return new (type as any)(attrs);\n } else if (isReactFn(type)) {\n return type(attrs);\n }\n return new ConstVNode(type, attrs, children.map(child => {\n if (typeof child === \"string\") {\n return new TextVNode(child);\n }\n return child;\n }));\n }\n\n static render(vdom: VNode, targetElement) {\n vdom.render(targetElement);\n }\n}\n","var n,l,u,t,i,o,r,f,e,c,s,a,h={},v=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function _(l,u,t){var i,o,r,f={};for(r in u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),\"function\"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g(l,f,i,o,null)}function g(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function m(){return{current:null}}function b(n){return n.children}function k(n,l){this.props=n,this.context=l}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return\"function\"==typeof n.type?x(n):null}function C(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C(n)}}function M(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!P.__r++||o!==l.debounceRendering)&&((o=l.debounceRendering)||r)(P)}function P(){var n,u,t,o,r,e,c,s;for(i.sort(f);n=i.shift();)n.__d&&(u=i.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l.vnode&&l.vnode(o),O(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j(c,o,s),o.__e!=e&&C(o)),i.length>u&&i.sort(f));P.__r=0}function S(n,l,u,t,i,o,r,f,e,c,s){var a,p,y,d,w,_=t&&t.__k||v,g=l.length;for(u.__d=e,$(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&(p=-1===y.__i?h:_[y.__i]||h,y.__i=a,O(n,y,p,i,o,r,f,e,c,s),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&N(p.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||p.__k===y.__k?e=I(y,e,n):\"function\"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w}function $(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=l[t])&&\"boolean\"!=typeof i&&\"function\"!=typeof i?(r=t+a,(i=n.__k[t]=\"string\"==typeof i||\"number\"==typeof i||\"bigint\"==typeof i||i.constructor==String?g(null,i,null,null,null):y(i)?g(b,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=n,i.__b=n.__b+1,o=null,-1!==(f=i.__i=L(i,u,r,s))&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,\"function\"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a--:f==r+1?a++:(f>r?a--:a++,i.__u|=65536))):i=n.__k[t]=null;if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V(o,o))}function I(n,l,u){var t,i;if(\"function\"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||\"boolean\"==typeof n||(y(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function L(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){\"-\"===l[0]?n.setProperty(l,null==u?\"\":u):n[l]=null==u?\"\":\"number\"!=typeof u||p.test(l)?u:u+\"px\"}function A(n,l,u,t,i){var o;n:if(\"style\"===l)if(\"string\"==typeof u)n.style.cssText=u;else{if(\"string\"==typeof t&&(n.style.cssText=t=\"\"),t)for(l in t)u&&l in u||T(n.style,l,\"\");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if(\"o\"===l[0]&&\"n\"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,\"$1\")),l=l.toLowerCase()in n||\"onFocusOut\"===l||\"onFocusIn\"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e,n.addEventListener(l,o?s:c,o)):n.removeEventListener(l,o?s:c,o);else{if(\"http://www.w3.org/2000/svg\"==i)l=l.replace(/xlink(H|:h)/,\"h\").replace(/sName$/,\"s\");else if(\"width\"!=l&&\"height\"!=l&&\"href\"!=l&&\"list\"!=l&&\"form\"!=l&&\"tabIndex\"!=l&&\"download\"!=l&&\"rowSpan\"!=l&&\"colSpan\"!=l&&\"role\"!=l&&\"popover\"!=l&&l in n)try{n[l]=null==u?\"\":u;break n}catch(n){}\"function\"==typeof u||(null==u||!1===u&&\"-\"!==l[4]?n.removeAttribute(l):n.setAttribute(l,\"popover\"==l&&1==u?\"\":u))}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e++;else if(u.t<t.u)return;return t(l.event?l.event(u):u)}}}function O(n,u,t,i,o,r,f,e,c,s){var a,h,v,p,w,_,g,m,x,C,M,P,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if(\"function\"==typeof T)try{if(m=u.props,x=\"prototype\"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],M=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,M):(u.__c=h=new k(m,M),h.constructor=T,h.render=q),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=M,h.__n=i,v=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),p=h.props,w=h.state,h.__v=u,v)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else{if(x&&null==T.getDerivedStateFromProps&&m!==p&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,M),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,M)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.some(function(n){n&&(n.__=u)}),P=0;P<h._sb.length;P++)h.__h.push(h._sb[P]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,M),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(p,w,_)})}if(h.context=M,h.props=m,h.__P=n,h.__e=!1,$=l.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[]}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!v&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(p,w)),S(n,y(L=null!=a&&a.type===b&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null)}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:32;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e}else u.__e=t.__e,u.__k=t.__k;l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(u,t,i,o,r,f,e,c,s){var a,v,p,d,_,g,m,b=i.props,k=t.props,C=t.type;if(\"svg\"===C?r=\"http://www.w3.org/2000/svg\":\"math\"===C?r=\"http://www.w3.org/1998/Math/MathML\":r||(r=\"http://www.w3.org/1999/xhtml\"),null!=f)for(a=0;a<f.length;a++)if((_=f[a])&&\"setAttribute\"in _==!!C&&(C?_.localName===C:3===_.nodeType)){u=_,f[a]=null;break}if(null==u){if(null===C)return document.createTextNode(k);u=document.createElementNS(r,C,k.is&&k),c&&(l.__m&&l.__m(t,f),c=!1),f=null}if(null===C)b===k||c&&u.data===k||(u.data=k);else{if(f=f&&n.call(u.childNodes),b=i.props||h,!c&&null!=f)for(b={},a=0;a<u.attributes.length;a++)b[(_=u.attributes[a]).name]=_.value;for(a in b)if(_=b[a],\"children\"==a);else if(\"dangerouslySetInnerHTML\"==a)p=_;else if(!(a in k)){if(\"value\"==a&&\"defaultValue\"in k||\"checked\"==a&&\"defaultChecked\"in k)continue;A(u,a,null,_,r)}for(a in k)_=k[a],\"children\"==a?d=_:\"dangerouslySetInnerHTML\"==a?v=_:\"value\"==a?g=_:\"checked\"==a?m=_:c&&\"function\"!=typeof _||b[a]===_||A(u,a,_,b[a],r);if(v)c||p&&(v.__html===p.__html||v.__html===u.innerHTML)||(u.innerHTML=v.__html),t.__k=[];else if(p&&(u.innerHTML=\"\"),S(u,y(d)?d:[d],t,i,o,\"foreignObject\"===C?\"http://www.w3.org/1999/xhtml\":r,f,e,f?f[0]:i.__k&&x(i,0),c,s),null!=f)for(a=f.length;a--;)w(f[a]);c||(a=\"value\",\"progress\"===C&&null==g?u.removeAttribute(\"value\"):void 0!==g&&(g!==u[a]||\"progress\"===C&&!g||\"option\"===C&&g!==b[a])&&A(u,a,g,b[a],r),a=\"checked\",void 0!==m&&m!==u[a]&&A(u,a,m,b[a],r))}return u}function N(n,u,t){try{if(\"function\"==typeof n){var i=\"function\"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u))}else n.current=u}catch(n){l.__e(n,t)}}function V(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&V(i[o],u,t||\"function\"!=typeof n.type);t||w(n.__e),n.__c=n.__=n.__e=n.__d=void 0}function q(n,l,u){return this.constructor(n,u)}function B(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o=\"function\"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O(t,u=(!o&&i||t).__k=_(b,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j(f,u,e)}function D(n,l){B(n,l,D)}function E(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l=\"__cC\"+a++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,M(n)})},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.splice(u.indexOf(n),1),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=v.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},u=0,t=function(n){return null!=n&&null==n.constructor},k.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),\"function\"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),M(this))},k.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),M(this))},k.prototype.render=b,i=[],r=\"function\"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f=function(n,l){return n.__v.__b-l.__v.__b},P.__r=0,e=0,c=F(!1),s=F(!0),a=0;export{k as Component,b as Fragment,E as cloneElement,G as createContext,_ as createElement,m as createRef,_ as h,D as hydrate,t as isValidElement,l as options,B as render,H as toChildArray};\n//# sourceMappingURL=preact.module.js.map\n","import{options as r,Fragment as e}from\"preact\";export{Fragment}from\"preact\";var t=/[\"&<]/;function n(r){if(0===r.length||!1===t.test(r))return r;for(var e=0,n=0,o=\"\",f=\"\";n<r.length;n++){switch(r.charCodeAt(n)){case 34:f=\"&quot;\";break;case 38:f=\"&amp;\";break;case 60:f=\"&lt;\";break;default:continue}n!==e&&(o+=r.slice(e,n)),o+=f,e=n+1}return n!==e&&(o+=r.slice(e,n)),o}var o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,f=0,i=Array.isArray;function u(e,t,n,o,i,u){t||(t={});var a,c,p=t;if(\"ref\"in p)for(c in p={},t)\"ref\"==c?a=t[c]:p[c]=t[c];var l={type:e,props:p,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u};if(\"function\"==typeof e&&(a=e.defaultProps))for(c in a)void 0===p[c]&&(p[c]=a[c]);return r.vnode&&r.vnode(l),l}function a(r){var t=u(e,{tpl:r,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var c={},p=/[A-Z]/g;function l(e,t){if(r.attr){var f=r.attr(e,t);if(\"string\"==typeof f)return f}if(\"ref\"===e||\"key\"===e)return\"\";if(\"style\"===e&&\"object\"==typeof t){var i=\"\";for(var u in t){var a=t[u];if(null!=a&&\"\"!==a){var l=\"-\"==u[0]?u:c[u]||(c[u]=u.replace(p,\"-$&\").toLowerCase()),_=\";\";\"number\"!=typeof a||l.startsWith(\"--\")||o.test(l)||(_=\"px;\"),i=i+l+\":\"+a+_}}return e+'=\"'+i+'\"'}return null==t||!1===t||\"function\"==typeof t||\"object\"==typeof t?\"\":!0===t?e:e+'=\"'+n(t)+'\"'}function _(r){if(null==r||\"boolean\"==typeof r||\"function\"==typeof r)return null;if(\"object\"==typeof r){if(void 0===r.constructor)return r;if(i(r)){for(var e=0;e<r.length;e++)r[e]=_(r[e]);return r}}return n(\"\"+r)}export{u as jsx,l as jsxAttr,u as jsxDEV,_ as jsxEscape,a as jsxTemplate,u as jsxs};\n//# sourceMappingURL=jsxRuntime.module.js.map\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizComponent extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = new (this as any).props.type()\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizInstance extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = (this as any).props.instance\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { format as d3Format } from \"d3-format\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class StatsTable extends StyledTable {\n\n protected transformData() {\n const totalRow = [[\"Total\", 0, 0]];\n const data = this.data();\n data.forEach(row => {\n totalRow[0][1] += row[1];\n totalRow[0][2] += row[2];\n });\n return data\n .concat(totalRow)\n .map(row => {\n return [\n row[0],\n this.secondColumnFormat_exists() ? d3Format(this.secondColumnFormat())(row[1]) : row[1],\n this.thirdColumnFormat_exists() ? d3Format(this.thirdColumnFormat())(row[2]) : row[2]\n ];\n })\n ;\n }\n\n update(domNode, element) {\n this.tbodyColumnStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\"\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\"\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\"\n }\n ]);\n this.evenRowStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n }\n ]);\n this.lastRowStyles_default({\n \"font-weight\": \"bold\"\n });\n super.update(domNode, element);\n }\n}\nStatsTable.prototype._class += \" html_StatsTable\";\n\nexport interface StatsTable {\n labelColor(): string;\n labelColor(_: string): this;\n primaryValueColor(): string;\n primaryValueColor(_: string): this;\n secondaryValueColor(): string;\n secondaryValueColor(_: string): this;\n evenRowFontColor(): string;\n evenRowFontColor(_: string): this;\n evenRowBackgroundColor(): string;\n evenRowBackgroundColor(_: string): this;\n firstColumnWidth(): string;\n firstColumnWidth(_: string): this;\n secondColumnWidth(): string;\n secondColumnWidth(_: string): this;\n thirdColumnWidth(): string;\n thirdColumnWidth(_: string): this;\n secondColumnFormat(): string;\n secondColumnFormat(_: string): this;\n secondColumnFormat_exists(): boolean;\n thirdColumnFormat(): string;\n thirdColumnFormat(_: string): this;\n thirdColumnFormat_exists(): boolean;\n}\nStatsTable.prototype.publish(\"labelColor\", \"#333\", \"html-color\", \"Color of the text in the first column\");\nStatsTable.prototype.publish(\"primaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the second column\");\nStatsTable.prototype.publish(\"secondaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the third column\");\nStatsTable.prototype.publish(\"evenRowBackgroundColor\", \"#333\", \"html-color\", \"Background color of the even rows\");\nStatsTable.prototype.publish(\"evenRowFontColor\", \"#333\", \"html-color\", \"Font color of the even rows\");\nStatsTable.prototype.publish(\"firstColumnWidth\", \"auto\", \"string\", \"CSS style applied as the 'width' for the first column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the second column (ex: 40px)\");\nStatsTable.prototype.publish(\"thirdColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the third column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnFormat\", \"$,.0f\", \"string\", \"d3-format specifier applied to the second column's values\", undefined, { optional: true });\nStatsTable.prototype.publish(\"thirdColumnFormat\", null, \"string\", \"d3-format specifier applied to the third column's values\", undefined, { optional: true });\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { JSXWidget } from \"./JSXWidget.ts\";\n\nimport \"../src/TitleBar.css\";\n\nexport interface IClickHandler {\n titleBarClick(src: Item, d, idx: number, groups): void;\n}\n\nexport class Item extends HTMLWidget {\n protected _owner: IClickHandler;\n\n constructor(owner: IClickHandler) {\n super();\n this._owner = owner;\n this._tag = \"a\";\n }\n}\nItem.prototype._class += \" html_Item\";\n\nexport class Button extends Item {\n private _icon: string;\n\n constructor(owner: IClickHandler, icon: string) {\n super(owner);\n this._icon = icon;\n }\n\n icon() {\n return this._icon;\n }\n\n enter(domNode: HTMLElement, element) {\n super.enter(domNode, element);\n element\n .attr(\"href\", \"#\")\n .on(\"click\", (d, idx, groups) => this._owner.titleBarClick(this, d, idx, groups))\n .append(\"i\")\n .attr(\"class\", `fa ${this._icon} fa-lg fa-fw`)\n ;\n }\n}\nButton.prototype._class += \" html_Button\";\n\nexport class ToggleButton extends Button {\n\n enter(domNode: HTMLElement, element) {\n element.on(\"click.sel\", (d, idx, groups) => {\n this.selected(!this.selected());\n this.render();\n });\n super.enter(domNode, element);\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._element.classed(\"selected\", this.selected());\n }\n}\nToggleButton.prototype._class += \" html_ToggleButton\";\nexport interface ToggleButton {\n selected(): boolean;\n selected(_: boolean): this;\n}\nToggleButton.prototype.publish(\"selected\", false, \"boolean\");\n\nexport class Spacer extends Item {\n\n enter(domNode, element) {\n super.enter(domNode, element);\n element\n .attr(\"class\", \"spacer\")\n .attr(\"href\", \"#\")\n .append(\"i\")\n ;\n }\n}\nSpacer.prototype._class += \" html_Spacer\";\n\nexport class TitleBar extends JSXWidget {\n protected _divMain;\n protected _divIconBar;\n protected _divTitle;\n\n constructor() {\n super();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._divMain = element.append(\"div\")\n .attr(\"class\", \"main\")\n ;\n this._divIconBar = this._divMain.append(\"div\")\n .attr(\"class\", \"icon-bar\")\n ;\n this._divTitle = this._divMain.append(\"div\")\n .attr(\"class\", \"title\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n this._divTitle.text(this.title());\n\n const icons = this._divIconBar.selectAll(\".icon-bar-item\").data(this.buttons());\n icons.enter().append(\"div\")\n .attr(\"class\", \"icon-bar-item\")\n .each(function (this: HTMLElement, d: Item) {\n d.target(this);\n })\n .merge(icons)\n .each(function (d: Item) {\n d.render();\n })\n ;\n icons.exit()\n .each(function (d: Item) {\n d.target(null);\n })\n .remove()\n ;\n icons.order();\n }\n}\nTitleBar.prototype._class += \" html_TitleBar\";\n\nexport interface TitleBar {\n title(): string;\n title(_: string): this;\n buttons(): Item[];\n buttons(items: Item[]): this;\n}\nTitleBar.prototype.publish(\"title\", \"\", \"string\");\nTitleBar.prototype.publish(\"buttons\", [], \"widgetArray\");\n"],"names":["d3Select","l","u","r","jsx","d3Format"],"mappings":";;;;;;AAAO,MAAM,WAAW,iBACX,cAAc,SACd,gBAAgB;ACMtB,MAAM,oBAAoB,WAAW;AAAA,EAUxC,cAAc;AACJ,UAAA;AATH;AACA;AACG;AAEA;AACA;AACA,gDAAuB,CAAC,SAAU;AAClC,mCAAyB,aAAa,kBAAkB;AAuO3D;AAwDC,oCAAW;AA5Rf,SAAK,QAAQ,EAAK;AAAA,EAAA;AAAA,EAGtB,YAAY,GAA4B;AACpC,gBAAK,uBAAuB,GACrB;AAAA,EAAA;AAAA,EAGX,eAAe,GAAS;AACpB,WAAK,UAAU,UACf,KAAK,eAAe,GACb,QAFuB,KAAK;AAAA,EAE5B;AAAA,EAGX,eAAe,GAAS;AACpB,gBAAK,kBAAkB,GAChB;AAAA,EAAA;AAAA,EAGX,MAAM,SAAS,SAAS;AACd,UAAA,MAAM,SAAS,OAAO;AACtB,UAAA,OAAOA,OAAS,MAAM;AAC5B,SAAK,kBAAkB,KAAK,OAAO,KAAK,EACn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EAGA;AAAA,EAGV,MAAM,SAAS,SAAS;AACd,UAAA,MAAM,SAAS,OAAO,GAC5B,KAAK,WAAW,QAAQ,OAAO,KAAK,EAC/B,KAAK,SAAS,MAAM,GAEpB,KAAA,cAAc,KAAK,SAAS,OAAO,KAAK,EACxC,KAAK,SAAS,UAAU,GAExB,KAAA,YAAY,KAAK,SAAS,OAAO,KAAK,EACtC,KAAK,SAAS,OAAO;AAAA,EAAA;AAAA,EAI9B,OAAO,SAAS,SAAS;AACf,UAAA,OAAO,SAAS,OAAO,GAE7B,KAAK,UAAU,KAAK,KAAK,MAAA,CAAO;AAE1B,UAAA,QAAQ,KAAK,YAAY,UAAU,gBAAgB,EAAE,KAAK,KAAK,SAAS;AACxE,UAAA,MAAA,EAAQ,OAAO,KAAK,EACrB,KAAK,SAAS,eAAe,EAC7B,KAAK,SAA6B,GAAS;AACxC,QAAE,OAAO,IAAI;AAAA,IAChB,CAAA,EACA,MAAM,KAAK,EACX,KAAK,SAAU,GAAS;AACrB,QAAE,OAAO;AAAA,IAAA,CACZ,GAEL,MAAM,KAAK,EACN,KAAK,SAAU,GAAS;AACrB,QAAE,OAAO,IAAI;AAAA,IAChB,CAAA,EACA,OAAO,GAEZ,MAAM,MAAM;AAAA,EAAA;AAEpB;AACA,SAAS,UAAU,UAAU;AAQ7B,SAAS,UAAU,QAAQ,SAAS,IAAI,QAAQ;AAChD,SAAS,UAAU,QAAQ,WAAW,CAAA,GAAI,aAAa;","x_google_ignoreList":[7,8]}
@@ -6,5 +6,5 @@
6
6
  ">${otherData.map(row=>`<div style="
7
7
  float:left;
8
8
  width:${Math.floor(99/colCount)}%;
9
- ">${row[0]}: ${row[1]}</div>`).join("")}</div>`})}update(domNode,element){if(this.theadColumnStyles_default([{color:this.thFirstColor(),"font-size":this.thFontSize()+"px","font-weight":this.thFontWeight(),"text-align":this.labelAlignment(),width:"auto",padding:"0px"},{width:"1%","font-size":this.thFontSize()+"px","font-weight":this.thFontWeight(),"text-align":this.percentageAlignment(),padding:"0px"}]),this.tbodyColumnStyles_default([{color:this.topLabelColor(),"font-size":this.fontSize()+"px","font-weight":"normal","text-align":this.labelAlignment(),width:"auto",padding:"0px"},{color:this.topPercentageColor(),"font-size":this.fontSize()+"px","font-weight":"normal","text-align":this.percentageAlignment(),width:"1%",padding:"0px"}]),this.lastRowStyles_default([{color:this.otherLabelColor(),"font-size":this.fontSize()+"px","font-weight":this.otherLabelBold()?"bold":"normal","text-align":this.labelAlignment(),width:"auto",padding:"0px"},{color:this.otherLabelColor(),"font-size":this.fontSize()+"px","font-weight":this.otherPercentageBold()?"bold":"normal","text-align":this.percentageAlignment(),width:"1%",padding:"0px"}]),super.update(domNode,element),(this.useCalculatedRowCount()?this.calculateRowCount():this.rowCount())<this.data().length){const lastRow=element.select("tbody > tr:last-child"),context=this;lastRow.on("mouseout.tooltip",d=>{context._tooltip._triggerElement=lastRow,context._tooltip.visible(!1).render()}).on("mouseenter.tooltip",d=>{context._tooltip._triggerElement=lastRow,context._tooltip.direction("n").data(context.data()).visible(!0).render()})}}}BreakdownTable.prototype._class+=" html_BreakdownTable",BreakdownTable.prototype.publish("useCalculatedRowCount",!0,"boolean","If true, rowCount will be calculated and its default will be overwritten"),BreakdownTable.prototype.publish("rowCount",5,"number","Number of total rows to display (including the 'other' row)",void 0,{disable:w=>w.useCalculatedRowCount()}),BreakdownTable.prototype.publish("fontSize",14,"number","Font size (pixels)"),BreakdownTable.prototype.publish("labelAlignment","left","set","Alignment of the label column text",["left","center","right"]),BreakdownTable.prototype.publish("percentageAlignment","center","set","Alignment of the percentage column text",["left","center","right"]),BreakdownTable.prototype.publish("topLabelColor","#333","html-color","Color of displayed 'top' labels"),BreakdownTable.prototype.publish("topPercentageColor","#1A99D5","html-color","Color of displayed 'top' percentages"),BreakdownTable.prototype.publish("topPercentageBold",!0,"html-color","If true, the 'top' percentages will be bold"),BreakdownTable.prototype.publish("otherLabel","Other","string","Label text for the 'other' row"),BreakdownTable.prototype.publish("otherLabelColor","#AAA","html-color","Color of the 'other' label"),BreakdownTable.prototype.publish("otherLabelBold",!1,"html-color","If true, the 'other' label will be bold"),BreakdownTable.prototype.publish("otherPercentageColor","#AAA","html-color","Color of the 'other' percentage"),BreakdownTable.prototype.publish("otherPercentageBold",!1,"html-color","If true, the 'other' percentage will be bold"),BreakdownTable.prototype.publish("thFontWeight","bold","string","Font weight for th elements"),BreakdownTable.prototype.publish("thFontSize",26,"number","Font size for th elements"),BreakdownTable.prototype.publish("thFirstColor","#333","html-color","Text color of the first th element"),BreakdownTable.prototype.publish("thLastColor","#333","html-color","Text color of the last th element");class JSXWidget extends common.HTMLWidget{constructor(){super(...arguments);__publicField(this,"rootNode")}jsxRender(jsx,domNode){this.rootNode=react.React.render(jsx,domNode,this.rootNode)}}__publicField(JSXWidget,"Component",react.React.Component),__publicField(JSXWidget,"createElement",react.React.createElement),JSXWidget.prototype._class+=" html_JSXWidget";class VNode{constructor(attrs,children){__publicField(this,"_attrs");__publicField(this,"_children");this._attrs=attrs,this._children=children}type(){return"div"}attrs(){return this._attrs}attr(key){return this._attrs[key]}children(){return this._children}update(targetElement){for(const key in this._attrs)targetElement.attr(key,this._attrs[key])}render(targetElement){const thisElement=targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);return thisElement.exit().remove(),thisElement.enter().append(this.type()).attr("reactd3",0).merge(thisElement).each(function(d){const element=common.select(this);d.update(element),d.renderChildren(element)})}renderChildren(targetElement){const thisElement=targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);return thisElement.exit().remove(),thisElement.enter().append(d=>document.createElement(d.type())).attr("reactd3",(_d,i)=>i).merge(thisElement).each(function(d){const element=common.select(this);d.update(element),d.renderChildren(element)})}}class ConstVNode extends VNode{constructor(type,attrs,children){super(attrs,children);__publicField(this,"_type");this._type=type}type(){return this._type}}class TextVNode extends VNode{constructor(text){super({},[]);__publicField(this,"_text");this._text=text}type(){return"span"}update(targetElement){super.update(targetElement),targetElement.text(this._text)}}function isReactFn(_){return typeof _=="function"}function isIVNode(_){return _.prototype&&_.prototype instanceof VNode}class ReactD3{static createElement(type,attrs,...children){return isIVNode(type)?new type(attrs):isReactFn(type)?type(attrs):new ConstVNode(type,attrs,children.map(child=>typeof child=="string"?new TextVNode(child):child))}static render(vdom,targetElement){vdom.render(targetElement)}}var l;l={__e:function(n,l2,u2,t){for(var i,o,r;l2=l2.__;)if((i=l2.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l3){n=l3}throw n}},typeof Promise=="function"&&Promise.prototype.then.bind(Promise.resolve());var f=0;function u(e,t,n,o,i,u2){t||(t={});var a,l$1=t;"ref"in t&&(a=t.ref,delete t.ref);var p={type:e,props:l$1,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u2};return l.vnode&&l.vnode(p),p}class VizComponent extends JSXWidget.Component{constructor(){super(...arguments);__publicField(this,"widget")}refreshProps(){for(const key in this.props)this.widget[key]&&typeof this.widget[key]=="function"&&this.widget[key](this.props[key])}componentDidMount(){this.widget=new this.props.type().target(this.base),this.refreshProps(),this.widget.render()}componentWillUnmount(){this.widget.target(null).render()}render(){return u("div",{style:this.props.style})}componentDidUpdate(){this.refreshProps(),this.widget.render()}}class VizInstance extends JSXWidget.Component{constructor(){super(...arguments);__publicField(this,"widget")}refreshProps(){for(const key in this.props)this.widget[key]&&typeof this.widget[key]=="function"&&this.widget[key](this.props[key])}componentDidMount(){this.widget=this.props.instance.target(this.base),this.refreshProps(),this.widget.render()}componentWillUnmount(){this.widget.target(null).render()}render(){return u("div",{style:this.props.style})}componentDidUpdate(){this.refreshProps(),this.widget.render()}}class StatsTable extends StyledTable{transformData(){const totalRow=[["Total",0,0]],data=this.data();return data.forEach(row=>{totalRow[0][1]+=row[1],totalRow[0][2]+=row[2]}),data.concat(totalRow).map(row=>[row[0],this.secondColumnFormat_exists()?common.format(this.secondColumnFormat())(row[1]):row[1],this.thirdColumnFormat_exists()?common.format(this.thirdColumnFormat())(row[2]):row[2]])}update(domNode,element){this.tbodyColumnStyles_default([{"font-weight":"bold",width:this.firstColumnWidth(),"text-align":"left"},{width:this.secondColumnWidth(),"text-align":"right"},{width:this.thirdColumnWidth(),"text-align":"right"}]),this.evenRowStyles_default([{"font-weight":"bold",width:this.firstColumnWidth(),"text-align":"left","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()},{width:this.secondColumnWidth(),"text-align":"right","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()},{width:this.thirdColumnWidth(),"text-align":"right","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()}]),this.lastRowStyles_default({"font-weight":"bold"}),super.update(domNode,element)}}StatsTable.prototype._class+=" html_StatsTable",StatsTable.prototype.publish("labelColor","#333","html-color","Color of the text in the first column"),StatsTable.prototype.publish("primaryValueColor","#333","html-color","Color of the text in the second column"),StatsTable.prototype.publish("secondaryValueColor","#333","html-color","Color of the text in the third column"),StatsTable.prototype.publish("evenRowBackgroundColor","#333","html-color","Background color of the even rows"),StatsTable.prototype.publish("evenRowFontColor","#333","html-color","Font color of the even rows"),StatsTable.prototype.publish("firstColumnWidth","auto","string","CSS style applied as the 'width' for the first column (ex: 40px)"),StatsTable.prototype.publish("secondColumnWidth","1%","string","CSS style applied as the 'width' for the second column (ex: 40px)"),StatsTable.prototype.publish("thirdColumnWidth","1%","string","CSS style applied as the 'width' for the third column (ex: 40px)"),StatsTable.prototype.publish("secondColumnFormat","$,.0f","string","d3-format specifier applied to the second column's values",void 0,{optional:!0}),StatsTable.prototype.publish("thirdColumnFormat",null,"string","d3-format specifier applied to the third column's values",void 0,{optional:!0});class Item extends common.HTMLWidget{constructor(owner){super();__publicField(this,"_owner");this._owner=owner,this._tag="a"}}Item.prototype._class+=" html_Item";class Button extends Item{constructor(owner,icon){super(owner);__publicField(this,"_icon");this._icon=icon}icon(){return this._icon}enter(domNode,element){super.enter(domNode,element),element.attr("href","#").on("click",(d,idx,groups)=>this._owner.titleBarClick(this,d,idx,groups)).append("i").attr("class",`fa ${this._icon} fa-lg fa-fw`)}}Button.prototype._class+=" html_Button";class ToggleButton extends Button{enter(domNode,element){element.on("click.sel",(d,idx,groups)=>{this.selected(!this.selected()),this.render()}),super.enter(domNode,element)}update(domNode,element){super.update(domNode,element),this._element.classed("selected",this.selected())}}ToggleButton.prototype._class+=" html_ToggleButton",ToggleButton.prototype.publish("selected",!1,"boolean");class Spacer extends Item{enter(domNode,element){super.enter(domNode,element),element.attr("class","spacer").attr("href","#").append("i")}}Spacer.prototype._class+=" html_Spacer";class TitleBar extends JSXWidget{constructor(){super();__publicField(this,"_divMain");__publicField(this,"_divIconBar");__publicField(this,"_divTitle")}enter(domNode,element){super.enter(domNode,element),this._divMain=element.append("div").attr("class","main"),this._divIconBar=this._divMain.append("div").attr("class","icon-bar"),this._divTitle=this._divMain.append("div").attr("class","title")}update(domNode,element){super.update(domNode,element),this._divTitle.text(this.title());const icons=this._divIconBar.selectAll(".icon-bar-item").data(this.buttons());icons.enter().append("div").attr("class","icon-bar-item").each(function(d){d.target(this)}).merge(icons).each(function(d){d.render()}),icons.exit().each(function(d){d.target(null)}).remove(),icons.order()}}TitleBar.prototype._class+=" html_TitleBar",TitleBar.prototype.publish("title","","string"),TitleBar.prototype.publish("buttons",[],"widgetArray"),exports2.BUILD_VERSION=BUILD_VERSION,exports2.BreakdownTable=BreakdownTable,exports2.Button=Button,exports2.HTMLTooltip=HTMLTooltip,exports2.Item=Item,exports2.JSXWidget=JSXWidget,exports2.PKG_NAME=PKG_NAME,exports2.PKG_VERSION=PKG_VERSION,exports2.ReactD3=ReactD3,exports2.SimpleTable=SimpleTable,exports2.Spacer=Spacer,exports2.StatsTable=StatsTable,exports2.StyledTable=StyledTable,exports2.TitleBar=TitleBar,exports2.ToggleButton=ToggleButton,exports2.VNode=VNode,exports2.VizComponent=VizComponent,exports2.VizInstance=VizInstance,Object.defineProperty(exports2,Symbol.toStringTag,{value:"Module"})});
9
+ ">${row[0]}: ${row[1]}</div>`).join("")}</div>`})}update(domNode,element){if(this.theadColumnStyles_default([{color:this.thFirstColor(),"font-size":this.thFontSize()+"px","font-weight":this.thFontWeight(),"text-align":this.labelAlignment(),width:"auto",padding:"0px"},{width:"1%","font-size":this.thFontSize()+"px","font-weight":this.thFontWeight(),"text-align":this.percentageAlignment(),padding:"0px"}]),this.tbodyColumnStyles_default([{color:this.topLabelColor(),"font-size":this.fontSize()+"px","font-weight":"normal","text-align":this.labelAlignment(),width:"auto",padding:"0px"},{color:this.topPercentageColor(),"font-size":this.fontSize()+"px","font-weight":"normal","text-align":this.percentageAlignment(),width:"1%",padding:"0px"}]),this.lastRowStyles_default([{color:this.otherLabelColor(),"font-size":this.fontSize()+"px","font-weight":this.otherLabelBold()?"bold":"normal","text-align":this.labelAlignment(),width:"auto",padding:"0px"},{color:this.otherLabelColor(),"font-size":this.fontSize()+"px","font-weight":this.otherPercentageBold()?"bold":"normal","text-align":this.percentageAlignment(),width:"1%",padding:"0px"}]),super.update(domNode,element),(this.useCalculatedRowCount()?this.calculateRowCount():this.rowCount())<this.data().length){const lastRow=element.select("tbody > tr:last-child"),context=this;lastRow.on("mouseout.tooltip",d=>{context._tooltip._triggerElement=lastRow,context._tooltip.visible(!1).render()}).on("mouseenter.tooltip",d=>{context._tooltip._triggerElement=lastRow,context._tooltip.direction("n").data(context.data()).visible(!0).render()})}}}BreakdownTable.prototype._class+=" html_BreakdownTable",BreakdownTable.prototype.publish("useCalculatedRowCount",!0,"boolean","If true, rowCount will be calculated and its default will be overwritten"),BreakdownTable.prototype.publish("rowCount",5,"number","Number of total rows to display (including the 'other' row)",void 0,{disable:w=>w.useCalculatedRowCount()}),BreakdownTable.prototype.publish("fontSize",14,"number","Font size (pixels)"),BreakdownTable.prototype.publish("labelAlignment","left","set","Alignment of the label column text",["left","center","right"]),BreakdownTable.prototype.publish("percentageAlignment","center","set","Alignment of the percentage column text",["left","center","right"]),BreakdownTable.prototype.publish("topLabelColor","#333","html-color","Color of displayed 'top' labels"),BreakdownTable.prototype.publish("topPercentageColor","#1A99D5","html-color","Color of displayed 'top' percentages"),BreakdownTable.prototype.publish("topPercentageBold",!0,"html-color","If true, the 'top' percentages will be bold"),BreakdownTable.prototype.publish("otherLabel","Other","string","Label text for the 'other' row"),BreakdownTable.prototype.publish("otherLabelColor","#AAA","html-color","Color of the 'other' label"),BreakdownTable.prototype.publish("otherLabelBold",!1,"html-color","If true, the 'other' label will be bold"),BreakdownTable.prototype.publish("otherPercentageColor","#AAA","html-color","Color of the 'other' percentage"),BreakdownTable.prototype.publish("otherPercentageBold",!1,"html-color","If true, the 'other' percentage will be bold"),BreakdownTable.prototype.publish("thFontWeight","bold","string","Font weight for th elements"),BreakdownTable.prototype.publish("thFontSize",26,"number","Font size for th elements"),BreakdownTable.prototype.publish("thFirstColor","#333","html-color","Text color of the first th element"),BreakdownTable.prototype.publish("thLastColor","#333","html-color","Text color of the last th element");class JSXWidget extends common.HTMLWidget{constructor(){super(...arguments);__publicField(this,"rootNode")}jsxRender(jsx,domNode){this.rootNode=react.React.render(jsx,domNode,this.rootNode)}}__publicField(JSXWidget,"Component",react.React.Component),__publicField(JSXWidget,"createElement",react.React.createElement),JSXWidget.prototype._class+=" html_JSXWidget";class VNode{constructor(attrs,children){__publicField(this,"_attrs");__publicField(this,"_children");this._attrs=attrs,this._children=children}type(){return"div"}attrs(){return this._attrs}attr(key){return this._attrs[key]}children(){return this._children}update(targetElement){for(const key in this._attrs)targetElement.attr(key,this._attrs[key])}render(targetElement){const thisElement=targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);return thisElement.exit().remove(),thisElement.enter().append(this.type()).attr("reactd3",0).merge(thisElement).each(function(d){const element=common.select(this);d.update(element),d.renderChildren(element)})}renderChildren(targetElement){const thisElement=targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);return thisElement.exit().remove(),thisElement.enter().append(d=>document.createElement(d.type())).attr("reactd3",(_d,i)=>i).merge(thisElement).each(function(d){const element=common.select(this);d.update(element),d.renderChildren(element)})}}class ConstVNode extends VNode{constructor(type,attrs,children){super(attrs,children);__publicField(this,"_type");this._type=type}type(){return this._type}}class TextVNode extends VNode{constructor(text){super({},[]);__publicField(this,"_text");this._text=text}type(){return"span"}update(targetElement){super.update(targetElement),targetElement.text(this._text)}}function isReactFn(_){return typeof _=="function"}function isIVNode(_){return _.prototype&&_.prototype instanceof VNode}class ReactD3{static createElement(type,attrs,...children){return isIVNode(type)?new type(attrs):isReactFn(type)?type(attrs):new ConstVNode(type,attrs,children.map(child=>typeof child=="string"?new TextVNode(child):child))}static render(vdom,targetElement){vdom.render(targetElement)}}var l;l={__e:function(n,l2,u2,t){for(var i,o,r;l2=l2.__;)if((i=l2.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l3){n=l3}throw n}},typeof Promise=="function"&&Promise.prototype.then.bind(Promise.resolve());var f=0;function u(e,t,n,o,i,u2){t||(t={});var a,c,p=t;if("ref"in p)for(c in p={},t)c=="ref"?a=t[c]:p[c]=t[c];var l$1={type:e,props:p,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u2};return l.vnode&&l.vnode(l$1),l$1}class VizComponent extends JSXWidget.Component{constructor(){super(...arguments);__publicField(this,"widget")}refreshProps(){for(const key in this.props)this.widget[key]&&typeof this.widget[key]=="function"&&this.widget[key](this.props[key])}componentDidMount(){this.widget=new this.props.type().target(this.base),this.refreshProps(),this.widget.render()}componentWillUnmount(){this.widget.target(null).render()}render(){return u("div",{style:this.props.style})}componentDidUpdate(){this.refreshProps(),this.widget.render()}}class VizInstance extends JSXWidget.Component{constructor(){super(...arguments);__publicField(this,"widget")}refreshProps(){for(const key in this.props)this.widget[key]&&typeof this.widget[key]=="function"&&this.widget[key](this.props[key])}componentDidMount(){this.widget=this.props.instance.target(this.base),this.refreshProps(),this.widget.render()}componentWillUnmount(){this.widget.target(null).render()}render(){return u("div",{style:this.props.style})}componentDidUpdate(){this.refreshProps(),this.widget.render()}}class StatsTable extends StyledTable{transformData(){const totalRow=[["Total",0,0]],data=this.data();return data.forEach(row=>{totalRow[0][1]+=row[1],totalRow[0][2]+=row[2]}),data.concat(totalRow).map(row=>[row[0],this.secondColumnFormat_exists()?common.format(this.secondColumnFormat())(row[1]):row[1],this.thirdColumnFormat_exists()?common.format(this.thirdColumnFormat())(row[2]):row[2]])}update(domNode,element){this.tbodyColumnStyles_default([{"font-weight":"bold",width:this.firstColumnWidth(),"text-align":"left"},{width:this.secondColumnWidth(),"text-align":"right"},{width:this.thirdColumnWidth(),"text-align":"right"}]),this.evenRowStyles_default([{"font-weight":"bold",width:this.firstColumnWidth(),"text-align":"left","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()},{width:this.secondColumnWidth(),"text-align":"right","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()},{width:this.thirdColumnWidth(),"text-align":"right","font-color":this.evenRowFontColor(),"background-color":this.evenRowBackgroundColor()}]),this.lastRowStyles_default({"font-weight":"bold"}),super.update(domNode,element)}}StatsTable.prototype._class+=" html_StatsTable",StatsTable.prototype.publish("labelColor","#333","html-color","Color of the text in the first column"),StatsTable.prototype.publish("primaryValueColor","#333","html-color","Color of the text in the second column"),StatsTable.prototype.publish("secondaryValueColor","#333","html-color","Color of the text in the third column"),StatsTable.prototype.publish("evenRowBackgroundColor","#333","html-color","Background color of the even rows"),StatsTable.prototype.publish("evenRowFontColor","#333","html-color","Font color of the even rows"),StatsTable.prototype.publish("firstColumnWidth","auto","string","CSS style applied as the 'width' for the first column (ex: 40px)"),StatsTable.prototype.publish("secondColumnWidth","1%","string","CSS style applied as the 'width' for the second column (ex: 40px)"),StatsTable.prototype.publish("thirdColumnWidth","1%","string","CSS style applied as the 'width' for the third column (ex: 40px)"),StatsTable.prototype.publish("secondColumnFormat","$,.0f","string","d3-format specifier applied to the second column's values",void 0,{optional:!0}),StatsTable.prototype.publish("thirdColumnFormat",null,"string","d3-format specifier applied to the third column's values",void 0,{optional:!0});class Item extends common.HTMLWidget{constructor(owner){super();__publicField(this,"_owner");this._owner=owner,this._tag="a"}}Item.prototype._class+=" html_Item";class Button extends Item{constructor(owner,icon){super(owner);__publicField(this,"_icon");this._icon=icon}icon(){return this._icon}enter(domNode,element){super.enter(domNode,element),element.attr("href","#").on("click",(d,idx,groups)=>this._owner.titleBarClick(this,d,idx,groups)).append("i").attr("class",`fa ${this._icon} fa-lg fa-fw`)}}Button.prototype._class+=" html_Button";class ToggleButton extends Button{enter(domNode,element){element.on("click.sel",(d,idx,groups)=>{this.selected(!this.selected()),this.render()}),super.enter(domNode,element)}update(domNode,element){super.update(domNode,element),this._element.classed("selected",this.selected())}}ToggleButton.prototype._class+=" html_ToggleButton",ToggleButton.prototype.publish("selected",!1,"boolean");class Spacer extends Item{enter(domNode,element){super.enter(domNode,element),element.attr("class","spacer").attr("href","#").append("i")}}Spacer.prototype._class+=" html_Spacer";class TitleBar extends JSXWidget{constructor(){super();__publicField(this,"_divMain");__publicField(this,"_divIconBar");__publicField(this,"_divTitle")}enter(domNode,element){super.enter(domNode,element),this._divMain=element.append("div").attr("class","main"),this._divIconBar=this._divMain.append("div").attr("class","icon-bar"),this._divTitle=this._divMain.append("div").attr("class","title")}update(domNode,element){super.update(domNode,element),this._divTitle.text(this.title());const icons=this._divIconBar.selectAll(".icon-bar-item").data(this.buttons());icons.enter().append("div").attr("class","icon-bar-item").each(function(d){d.target(this)}).merge(icons).each(function(d){d.render()}),icons.exit().each(function(d){d.target(null)}).remove(),icons.order()}}TitleBar.prototype._class+=" html_TitleBar",TitleBar.prototype.publish("title","","string"),TitleBar.prototype.publish("buttons",[],"widgetArray"),exports2.BUILD_VERSION=BUILD_VERSION,exports2.BreakdownTable=BreakdownTable,exports2.Button=Button,exports2.HTMLTooltip=HTMLTooltip,exports2.Item=Item,exports2.JSXWidget=JSXWidget,exports2.PKG_NAME=PKG_NAME,exports2.PKG_VERSION=PKG_VERSION,exports2.ReactD3=ReactD3,exports2.SimpleTable=SimpleTable,exports2.Spacer=Spacer,exports2.StatsTable=StatsTable,exports2.StyledTable=StyledTable,exports2.TitleBar=TitleBar,exports2.ToggleButton=ToggleButton,exports2.VNode=VNode,exports2.VizComponent=VizComponent,exports2.VizInstance=VizInstance,Object.defineProperty(exports2,Symbol.toStringTag,{value:"Module"})});
10
10
  //# sourceMappingURL=index.umd.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.umd.cjs","sources":["../src/__package__.ts","../src/HTMLTooltip.ts","../src/SimpleTable.ts","../src/StyledTable.ts","../src/BreakdownTable.ts","../src/JSXWidget.ts","../src/reactD3.ts","../../../node_modules/preact/dist/preact.module.js","../../../node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js","../src/VizComponent.tsx","../src/VizInstance.tsx","../src/StatsTable.ts","../src/TitleBar.ts"],"sourcesContent":["export const PKG_NAME = \"@hpcc-js/html\";\nexport const PKG_VERSION = \"3.1.1\";\nexport const BUILD_VERSION = \"3.2.1\";\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\nimport { scopedLogger, ScopedLogging } from \"@hpcc-js/util\";\n\ntype Direction = \"n\" | \"s\" | \"e\" | \"w\" | \"ne\" | \"nw\" | \"se\" | \"sw\";\ntype Position = { x: number, y: number };\ntype DirectionalBBox = { [key in Direction]: Position; };\n\ntype Rectangle = { top: number, left: number, width: number, height: number };\nexport class HTMLTooltip extends HTMLWidget {\n\n public _triggerElement;\n public _contentNode;\n protected _prevContentNode;\n\n protected _tooltipElement;\n protected _arrowElement;\n protected _tooltipHTMLCallback = (data?) => \"<b>_tooltipHTMLCallback is undefined</b>\";\n protected _logger: ScopedLogging = scopedLogger(\"html/HTMLTooltip\");\n constructor() {\n super();\n this.visible(false);\n }\n\n tooltipHTML(_: (data?) => string): this {\n this._tooltipHTMLCallback = _;\n return this;\n }\n\n tooltipContent(_): this {\n if (!arguments.length) return this._contentNode;\n this._contentNode = _;\n return this;\n }\n\n triggerElement(_): this {\n this._triggerElement = _;\n return this;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n const body = d3Select(\"body\");\n this._tooltipElement = body.append(\"div\")\n .attr(\"class\", \"tooltip-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n this._arrowElement = body.append(\"div\")\n .attr(\"class\", \"arrow-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n if (this._contentNode !== this._prevContentNode) {\n const node = this._tooltipElement.node();\n [...node.querySelectorAll(\"*\")]\n .map(n => n.__data__)\n .filter(n => n)\n .forEach(w => {\n if (typeof w.target === \"function\") {\n w.target(null);\n }\n if (typeof w.exit === \"function\") {\n w.exit();\n }\n });\n node.innerHTML = \"\";\n node.appendChild(this._contentNode);\n this._prevContentNode = this._contentNode;\n }\n\n if (this._contentNode) {\n this.onShowContent(this._contentNode);\n } else {\n this._tooltipElement\n .html(() => {\n return this._tooltipHTMLCallback(this.data());\n });\n }\n if (this.fitContent()) {\n this._tooltipElement\n .style(\"width\", \"auto\")\n .style(\"height\", \"auto\")\n .style(\"padding\", \"0px\")\n .style(\"box-sizing\", \"content-box\")\n ;\n const rect = this._tooltipElement.node().getBoundingClientRect();\n this.tooltipWidth_default(rect.width);\n this.tooltipHeight_default(rect.height);\n }\n this._closing = false;\n this._tooltipElement\n .style(\"background-color\", this.tooltipColor())\n .style(\"color\", this.fontColor())\n .style(\"width\", this.tooltipWidth() + \"px\")\n .style(\"height\", this.tooltipHeight() + \"px\")\n .style(\"opacity\", 1)\n .style(\"padding\", this.padding() + \"px\")\n .style(\"pointer-events\", this.enablePointerEvents() ? \"all\" : \"none\")\n .style(\"box-sizing\", \"content-box\")\n ;\n this._arrowElement\n .style(\"opacity\", 1)\n .style(\"pointer-events\", \"none\")\n ;\n this.updateTooltipPosition();\n }\n\n onShowContent(node) {\n\n }\n\n protected updateTooltipPosition(): Position {\n const bbox = this.calcReferenceBBox();\n const direction = this.calcTooltipDirection(bbox);\n const box = bbox[direction];\n this._tooltipElement\n .style(\"top\", box.y + \"px\")\n .style(\"left\", box.x + \"px\")\n ;\n this.setArrowPosition(box, direction);\n return box;\n }\n\n protected calcTooltipDirection(bbox: DirectionalBBox): Direction {\n const directions: Direction[] = Object.keys(bbox) as Direction[];\n\n const defaultDirection = this.direction();\n directions.sort((a, b) => a === defaultDirection ? -1 : 1);\n const windowRect = {\n top: 0,\n left: 0,\n width: window.innerWidth,\n height: window.innerHeight\n };\n for (let i = 0; i < directions.length; i++) {\n const tooltipRect = {\n top: bbox[directions[i]].y,\n left: bbox[directions[i]].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n };\n if (this.rectFits(tooltipRect, windowRect)) {\n return directions[i];\n }\n }\n this._logger.warning(`Tooltip doesn't fit in the window for any of the directions. Defaulting to '${defaultDirection}'`);\n this._logger.debug(windowRect);\n this._logger.debug({\n top: bbox[defaultDirection].y,\n left: bbox[defaultDirection].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n });\n return defaultDirection;\n }\n\n protected rectFits(innerRect: Rectangle, outerRect: Rectangle): boolean {\n return (\n innerRect.top >= outerRect.top &&\n innerRect.left >= outerRect.left &&\n innerRect.width + innerRect.left <= outerRect.width + outerRect.left &&\n innerRect.height + innerRect.top <= outerRect.height + outerRect.top\n );\n }\n\n protected setArrowPosition(point: Position, direction: Direction) {\n let top;\n let left;\n let visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border\", `${this.arrowHeight()}px solid ${this.tooltipColor()}`)\n .style(\"border-top-color\", \"transparent\")\n .style(\"border-right-color\", \"transparent\")\n .style(\"border-bottom-color\", \"transparent\")\n .style(\"border-left-color\", \"transparent\")\n ;\n switch (direction) {\n case \"n\":\n top = point.y + this.tooltipHeight() + (this.padding() * 2);\n left = point.x + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2) + this.padding();\n visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowHeight()}px`)\n .style(\"border-bottom-width\", \"0px\")\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"s\":\n top = point.y - this.arrowHeight();\n left = point.x + this.padding() + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2);\n visibleBorderStyle = \"border-bottom-color\";\n this._arrowElement\n .style(\"border-top-width\", \"0px\")\n .style(\"border-bottom-width\", `${this.arrowHeight()}px`)\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"e\":\n top = point.y + (this.tooltipHeight() / 2) + this.padding() - (this.arrowWidth() / 2);\n left = point.x - this.arrowHeight();\n visibleBorderStyle = \"border-right-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", \"0px\")\n .style(\"border-right-width\", `${this.arrowHeight()}px`)\n ;\n break;\n case \"w\":\n top = point.y + (this.tooltipHeight() / 2) - (this.arrowWidth() / 2) + this.padding();\n left = point.x + this.tooltipWidth() + (this.padding() * 2);\n visibleBorderStyle = \"border-left-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", `${this.arrowHeight()}px`)\n .style(\"border-right-width\", \"0px\")\n ;\n break;\n }\n if (typeof top !== \"undefined\" && typeof left !== \"undefined\") {\n this._arrowElement\n .style(\"top\", top + \"px\")\n .style(\"left\", left + \"px\")\n .style(visibleBorderStyle, this.tooltipColor())\n .style(\"opacity\", 1)\n ;\n } else {\n this._arrowElement\n .style(\"opacity\", 0)\n ;\n }\n return point;\n }\n\n protected getReferenceNode() {\n if (!this._triggerElement) {\n return this.element().node().parentNode.parentNode;\n }\n return this._triggerElement.node();\n }\n public _cursorLoc;\n protected calcReferenceBBox() {\n const node = this.getReferenceNode();\n let { top, left, width, height } = node.getBoundingClientRect();\n const wholeW = this.tooltipWidth();\n const wholeH = this.tooltipHeight();\n const halfW = wholeW / 2;\n const halfH = wholeH / 2;\n const arrowH = this.arrowHeight();\n const p = this.padding();\n const p2 = p * 2;\n\n if (this.followCursor() && this._cursorLoc) {\n\n left = this._cursorLoc[0];\n top = this._cursorLoc[1];\n width = 1;\n height = 1;\n }\n const bbox = {\n n: {\n x: left + (width / 2) - halfW - p,\n y: top - wholeH - arrowH - p2\n },\n e: {\n x: left + width + arrowH,\n y: top + (height / 2) - halfH - p\n },\n s: {\n x: left + (width / 2) - halfW - p,\n y: top + height + arrowH\n },\n w: {\n x: left - wholeW - arrowH - p2,\n y: top + (height / 2) - halfH - p\n },\n nw: {\n x: left - wholeW - p2,\n y: top - wholeH - p2\n },\n ne: {\n x: left + width,\n y: top - wholeH - p2\n },\n se: {\n x: left + width,\n y: top + height\n },\n sw: {\n x: left - wholeW - p2,\n y: top + height\n }\n };\n return bbox;\n }\n\n private _closing = false;\n mouseout() {\n this._closing = true;\n this._tooltipElement.on(\"mouseover\", () => {\n this._closing = false;\n });\n this._tooltipElement.on(\"mouseout\", () => {\n this.mouseout();\n });\n setTimeout(() => {\n if (this._closing) {\n this.visible(false);\n }\n }, this.closeDelay());\n }\n\n visible(): boolean;\n visible(_: boolean): this;\n visible(_?: boolean): boolean | this {\n if (!arguments.length) return super.visible();\n if (this._arrowElement) {\n this._arrowElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n this._tooltipElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n }\n super.visible(_);\n return this;\n }\n\n exit(domNode, element) {\n if (this._arrowElement) {\n this._arrowElement.remove();\n this._tooltipElement.remove();\n }\n super.exit(domNode, element);\n }\n}\nHTMLTooltip.prototype._class += \" html_HTMLTooltip\";\n\nexport interface HTMLTooltip {\n padding(): number;\n padding(_: number): this;\n direction(): Direction;\n direction(_: Direction): this;\n arrowHeight(): number;\n arrowHeight(_: number): this;\n arrowWidth(): number;\n arrowWidth(_: number): this;\n fontColor(): string;\n fontColor(_: string): this;\n tooltipColor(): string;\n tooltipColor(_: string): this;\n tooltipWidth(): number;\n tooltipWidth(_: number): this;\n tooltipWidth_default(_: number);\n tooltipHeight(): number;\n tooltipHeight(_: number): this;\n tooltipHeight_default(_: number);\n followCursor(): boolean;\n followCursor(_: boolean): this;\n enablePointerEvents(): boolean;\n enablePointerEvents(_: boolean): this;\n closeDelay(): number;\n closeDelay(_: number): this;\n fitContent(): boolean;\n fitContent(_: boolean): this;\n\n}\n\nHTMLTooltip.prototype.publish(\"fitContent\", false, \"boolean\", \"If true, tooltip will grow to fit its html content\");\nHTMLTooltip.prototype.publish(\"followCursor\", false, \"boolean\", \"If true, tooltip will display relative to cursor location\");\nHTMLTooltip.prototype.publish(\"closeDelay\", 400, \"number\", \"Number of milliseconds to wait before closing tooltip (cancelled on tooltip mouseover event)\");\nHTMLTooltip.prototype.publish(\"direction\", \"n\", \"set\", \"Direction in which to display the tooltip\", [\"n\", \"s\", \"e\", \"w\", \"ne\", \"nw\", \"se\", \"sw\"]);\nHTMLTooltip.prototype.publish(\"padding\", 8, \"number\", \"Padding (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowWidth\", 16, \"number\", \"Width (or height depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowHeight\", 8, \"number\", \"Height (or width depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"fontColor\", \"#FFF\", \"html-color\", \"The default font color for text in the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipColor\", \"#000000EE\", \"html-color\", \"Background color of the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipWidth\", 200, \"number\", \"Width of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"tooltipHeight\", 200, \"number\", \"Height of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"enablePointerEvents\", false, \"boolean\", \"If true, the 'pointer-events: all' style will be used\");\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\n\nexport class SimpleTable extends HTMLWidget {\n protected _table;\n protected _tbody;\n protected _thead;\n protected _theadRow;\n constructor() {\n super();\n }\n\n protected transformData() {\n return this.data();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n\n this._table = element.append(\"table\");\n this._thead = this._table.append(\"thead\");\n this._theadRow = this._thead.append(\"tr\");\n this._tbody = this._table.append(\"tbody\");\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._table\n .style(\"width\", this.autoWidth() ? \"auto\" : \"100%\")\n ;\n const theadTrSelection = this._theadRow.selectAll(\"th\").data(this.columns());\n theadTrSelection.enter()\n .append(\"th\")\n .attr(\"class\", (n, i) => `th-${i}`)\n .merge(theadTrSelection)\n .text(_d => (_d).toString())\n ;\n theadTrSelection.exit().remove();\n const trSelection = this._tbody.selectAll(\"tr\").data(this.transformData());\n trSelection.enter()\n .append(\"tr\")\n .merge(trSelection)\n .each(function (this, d) {\n const tr = d3Select(this);\n const tdSelection = tr.selectAll(\"td\").data(d);\n tdSelection.enter()\n .append(\"td\")\n .attr(\"class\", (n, i) => `col-${i}`)\n .merge(tdSelection as any)\n .text(_d => (_d).toString())\n ;\n tdSelection.exit().remove();\n })\n ;\n trSelection.exit().remove();\n }\n}\nSimpleTable.prototype._class += \" html_SimpleTable\";\n\nexport interface SimpleTable {\n autoWidth(): boolean;\n autoWidth(_: boolean): this;\n}\nSimpleTable.prototype.publish(\"autoWidth\", false, \"boolean\", \"If true, table width will be set to 'auto'. If false, the width is set to '100%'\");\n","import { SimpleTable } from \"./SimpleTable.ts\";\n\nexport class StyledTable extends SimpleTable {\n constructor() {\n super();\n }\n\n protected applyStyleObject(selection, styleObject) {\n Object.keys(styleObject).forEach(styleName => {\n selection.style(styleName, styleObject[styleName]);\n });\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n element.selectAll(\"tr,th,td\")\n .attr(\"style\", \"\")\n .style(\"font-family\", this.fontFamily())\n .style(\"color\", this.fontColor())\n ;\n\n this.theadColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.select(`.th-${i}`), styleObj);\n });\n this.tbodyColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.selectAll(`.col-${i}`), styleObj);\n });\n const evenRowStylesExist = Object.keys(this.evenRowStyles()).length > 0;\n const lastRowStylesExist = Object.keys(this.lastRowStyles()).length > 0;\n const tbodyRows = element.selectAll(\"tbody > tr\");\n if (evenRowStylesExist) {\n const tbodyEvenRows = tbodyRows.select(function (this: HTMLElement, d, i) { return i % 2 ? this : null; });\n this.applyStyleObject(tbodyEvenRows, this.evenRowStyles());\n }\n if (lastRowStylesExist) {\n const tbodyLastRow = tbodyRows.select(function (this: HTMLElement, d, i, arr) { return i === arr.length - 1 ? this : null; });\n this.applyStyleObject(tbodyLastRow, this.lastRowStyles());\n }\n }\n}\nStyledTable.prototype._class += \" html_StyledTable\";\n\nexport interface StyledTable {\n fontFamily(): string;\n fontFamily(_: string): this;\n fontColor(): string;\n fontColor(_: string): this;\n tbodyColumnStyles(): Array<{ [styleID: string]: any }>;\n tbodyColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n tbodyColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles(): Array<{ [styleID: string]: any }>;\n theadColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n lastRowStyles(): { [styleID: string]: any };\n lastRowStyles(_: { [styleID: string]: any }): this;\n lastRowStyles_default(_: { [styleID: string]: any }): this;\n evenRowStyles(): { [styleID: string]: any };\n evenRowStyles(_: { [styleID: string]: any }): this;\n evenRowStyles_default(_: { [styleID: string]: any }): this;\n}\n\nStyledTable.prototype.publish(\"fontFamily\", \"Verdana\", \"string\", \"Base font-family used within the table\");\nStyledTable.prototype.publish(\"fontColor\", \"#333\", \"string\", \"Base font color used within the table\");\nStyledTable.prototype.publish(\"theadColumnStyles\", [], \"array\", 'Array of objects containing styles for the thead columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"tbodyColumnStyles\", [], \"array\", 'Array of objects containing styles for the tbody columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"lastRowStyles\", {}, \"object\", 'Object containing styles for the last row (ex: {\"color\":\"red\"})');\nStyledTable.prototype.publish(\"evenRowStyles\", {}, \"object\", 'Object containing styles for even rows (ex: {\"background-color\":\"#AAA\"})');\n","import { HTMLTooltip } from \"./HTMLTooltip.ts\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class BreakdownTable extends StyledTable {\n // protected _table;\n // protected _tbody;\n protected _tooltip: HTMLTooltip;\n constructor() {\n super();\n }\n\n protected transformData() {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n return this.breakdownData(rowCount);\n }\n\n protected breakdownData(limit: number): any[] {\n const len = this.data().length;\n const sum = this.data().reduce((acc, row) => acc + row[1], 0);\n const data = [];\n let percSum = 0;\n this.data().sort((a, b) => a[1] > b[1] ? -1 : 1);\n const hiddenRowCount = len - limit;\n const showOther = hiddenRowCount > 0;\n this.data()\n .filter((_, i) => showOther ? i < limit - 1 : true)\n .forEach(row => {\n const perc = Math.round((row[1] / sum) * 100);\n percSum += perc;\n data.push([row[0], perc + \"%\"]);\n });\n if (showOther) {\n const otherLabel = `${this.otherLabel()} (${len - limit + 1})`;\n const otherPercentage = \"~\" + (100 - percSum) + \"%\";\n data.push([otherLabel, otherPercentage]);\n }\n return data;\n }\n\n protected calculateRowCount(): number {\n const theadRowHeight = this.columns().length > 0 ? this.thFontSize() + 5 : 0;\n const tbodyRowHeight = this.fontSize() + 5;\n const tbodyAvailableHeight = this.height() - theadRowHeight;\n const rowCount = Math.floor(tbodyAvailableHeight / tbodyRowHeight);\n return rowCount;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._tooltip = new HTMLTooltip()\n .target(domNode)\n ;\n this._tooltip\n .tooltipHTML(data => {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n const rowHeight = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).height)) ?? this.fontSize();\n const widestLabel = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).width));\n const widestPerc = 30;\n const colCount = 2;\n const w = colCount * (widestLabel + widestPerc) + (this._tooltip.padding() * 2);\n const h = rowHeight * Math.ceil((data.length - rowCount) / colCount) + (this._tooltip.padding() * 2);\n this._tooltip.tooltipWidth(w);\n this._tooltip.tooltipHeight(h);\n const otherData = this.breakdownData(this.data().length).slice(rowCount - 1);\n return `<div style=\"\n width: 100%;\n height: 100%;\n font-size: ${this.fontSize()}px;\n \">${otherData.map(row =>\n `<div style=\"\n float:left;\n width:${Math.floor(99 / colCount)}%;\n \">${row[0]}: ${row[1]}</div>`\n ).join(\"\")\n }</div>`;\n })\n ;\n }\n\n update(domNode, element) {\n this.theadColumnStyles_default([\n {\n \"color\": this.thFirstColor(),\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"width\": \"1%\",\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.percentageAlignment(),\n \"padding\": \"0px\"\n }\n ]);\n this.tbodyColumnStyles_default([\n {\n \"color\": this.topLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.topPercentageColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n this.lastRowStyles_default([\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherLabelBold() ? \"bold\" : \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherPercentageBold() ? \"bold\" : \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n\n super.update(domNode, element);\n\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n if (rowCount < this.data().length) {\n const lastRow = element.select(\"tbody > tr:last-child\");\n const context = this;\n lastRow\n .on(\"mouseout.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .visible(false)\n .render()\n ;\n })\n .on(\"mouseenter.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .direction(\"n\")\n .data(context.data())\n .visible(true)\n .render()\n ;\n })\n ;\n }\n }\n\n}\nBreakdownTable.prototype._class += \" html_BreakdownTable\";\n\nexport interface BreakdownTable {\n useCalculatedRowCount(): boolean;\n useCalculatedRowCount(_: boolean): this;\n rowCount(): number;\n rowCount(_: number): this;\n fontSize(): number;\n fontSize(_: number): this;\n thFirstColor(): string;\n thFirstColor(_: string): this;\n thLastColor(): string;\n thLastColor(_: string): this;\n thFontSize(): number;\n thFontSize(_: number): this;\n thFontWeight(): string;\n thFontWeight(_: string): this;\n labelAlignment(): \"left\" | \"center\" | \"right\";\n labelAlignment(_: \"left\" | \"center\" | \"right\"): this;\n percentageAlignment(): \"left\" | \"center\" | \"right\";\n percentageAlignment(_: \"left\" | \"center\" | \"right\"): this;\n topLabelColor(): string;\n topLabelColor(_: string): this;\n topPercentageColor(): string;\n topPercentageColor(_: string): this;\n topPercentageBold(): boolean;\n topPercentageBold(_: boolean): this;\n otherLabel(): string;\n otherLabel(_: string): this;\n otherLabelColor(): string;\n otherLabelColor(_: string): this;\n otherLabelBold(): boolean;\n otherLabelBold(_: boolean): this;\n otherPercentageColor(): string;\n otherPercentageColor(_: string): this;\n otherPercentageBold(): boolean;\n otherPercentageBold(_: boolean): this;\n}\n\nBreakdownTable.prototype.publish(\"useCalculatedRowCount\", true, \"boolean\", \"If true, rowCount will be calculated and its default will be overwritten\");\nBreakdownTable.prototype.publish(\"rowCount\", 5, \"number\", \"Number of total rows to display (including the 'other' row)\", undefined, { disable: w => w.useCalculatedRowCount() });\nBreakdownTable.prototype.publish(\"fontSize\", 14, \"number\", \"Font size (pixels)\");\nBreakdownTable.prototype.publish(\"labelAlignment\", \"left\", \"set\", \"Alignment of the label column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"percentageAlignment\", \"center\", \"set\", \"Alignment of the percentage column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"topLabelColor\", \"#333\", \"html-color\", \"Color of displayed 'top' labels\");\nBreakdownTable.prototype.publish(\"topPercentageColor\", \"#1A99D5\", \"html-color\", \"Color of displayed 'top' percentages\");\nBreakdownTable.prototype.publish(\"topPercentageBold\", true, \"html-color\", \"If true, the 'top' percentages will be bold\");\nBreakdownTable.prototype.publish(\"otherLabel\", \"Other\", \"string\", \"Label text for the 'other' row\");\nBreakdownTable.prototype.publish(\"otherLabelColor\", \"#AAA\", \"html-color\", \"Color of the 'other' label\");\nBreakdownTable.prototype.publish(\"otherLabelBold\", false, \"html-color\", \"If true, the 'other' label will be bold\");\nBreakdownTable.prototype.publish(\"otherPercentageColor\", \"#AAA\", \"html-color\", \"Color of the 'other' percentage\");\nBreakdownTable.prototype.publish(\"otherPercentageBold\", false, \"html-color\", \"If true, the 'other' percentage will be bold\");\nBreakdownTable.prototype.publish(\"thFontWeight\", \"bold\", \"string\", \"Font weight for th elements\");\nBreakdownTable.prototype.publish(\"thFontSize\", 26, \"number\", \"Font size for th elements\");\nBreakdownTable.prototype.publish(\"thFirstColor\", \"#333\", \"html-color\", \"Text color of the first th element\");\nBreakdownTable.prototype.publish(\"thLastColor\", \"#333\", \"html-color\", \"Text color of the last th element\");\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { React } from \"@hpcc-js/react\";\n\nexport class JSXWidget extends HTMLWidget {\n static Component = React.Component;\n static createElement = React.createElement;\n protected rootNode;\n\n jsxRender(jsx, domNode) {\n this.rootNode = React.render(jsx, domNode, this.rootNode);\n }\n}\nJSXWidget.prototype._class += \" html_JSXWidget\";\n","import { select as d3Select } from \"@hpcc-js/common\";\n\nexport type ReactFn = (attrs: { [key: string]: string }) => VNode;\n\nexport type IVNode = new (attrs: { [key: string]: string }, children: VNode[]) => VNode;\n\nexport class VNode {\n protected _attrs: { [key: string]: string };\n protected _children: VNode[];\n\n constructor(attrs: { [key: string]: string }, children: VNode[]) {\n this._attrs = attrs;\n this._children = children;\n }\n\n type(): string {\n return \"div\";\n }\n\n attrs(): { [key: string]: string } {\n return this._attrs;\n }\n\n attr(key) {\n return this._attrs[key];\n }\n\n children(): VNode[] {\n return this._children;\n }\n\n update(targetElement) {\n for (const key in this._attrs) {\n targetElement.attr(key, this._attrs[key]);\n }\n }\n\n render(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(this.type())\n .attr(\"reactd3\", 0)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n\n renderChildren(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(d => document.createElement(d.type()))\n .attr(\"reactd3\", (_d, i) => i)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n}\n\nclass ConstVNode extends VNode {\n protected _type: string;\n\n constructor(type: string, attrs: { [key: string]: string }, children: VNode[]) {\n super(attrs, children);\n this._type = type;\n }\n\n type(): string {\n return this._type;\n }\n}\n\nclass TextVNode extends VNode {\n protected _text: string;\n\n constructor(text: string) {\n super({}, []);\n this._text = text;\n }\n\n type(): string {\n return \"span\";\n }\n\n update(targetElement) {\n super.update(targetElement);\n targetElement.text(this._text);\n }\n}\n\nfunction isReactFn(_): _ is ReactFn {\n return typeof _ === \"function\";\n}\n\nfunction isIVNode(_: any): _ is IVNode {\n return _.prototype && _.prototype instanceof VNode;\n}\n\nexport class ReactD3 {\n // static createElementXXX(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n static createElement(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n if (isIVNode(type)) {\n return new (type as any)(attrs);\n } else if (isReactFn(type)) {\n return type(attrs);\n }\n return new ConstVNode(type, attrs, children.map(child => {\n if (typeof child === \"string\") {\n return new TextVNode(child);\n }\n return child;\n }));\n }\n\n static render(vdom: VNode, targetElement) {\n vdom.render(targetElement);\n }\n}\n","var n,l,u,t,i,o,r,f,e,c,s,a,h={},v=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function _(l,u,t){var i,o,r,f={};for(r in u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),\"function\"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g(l,f,i,o,null)}function g(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function m(){return{current:null}}function b(n){return n.children}function k(n,l){this.props=n,this.context=l}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return\"function\"==typeof n.type?x(n):null}function C(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C(n)}}function S(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!M.__r++||o!==l.debounceRendering)&&((o=l.debounceRendering)||r)(M)}function M(){var n,u,t,o,r,e,c,s;for(i.sort(f);n=i.shift();)n.__d&&(u=i.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l.vnode&&l.vnode(o),O(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j(c,o,s),o.__e!=e&&C(o)),i.length>u&&i.sort(f));M.__r=0}function P(n,l,u,t,i,o,r,f,e,c,s){var a,p,y,d,w,_=t&&t.__k||v,g=l.length;for(u.__d=e,$(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&(p=-1===y.__i?h:_[y.__i]||h,y.__i=a,O(n,y,p,i,o,r,f,e,c,s),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&E(p.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||p.__k===y.__k?e=I(y,e,n):\"function\"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w}function $(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=l[t])&&\"boolean\"!=typeof i&&\"function\"!=typeof i?(r=t+a,(i=n.__k[t]=\"string\"==typeof i||\"number\"==typeof i||\"bigint\"==typeof i||i.constructor==String?g(null,i,null,null,null):y(i)?g(b,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=n,i.__b=n.__b+1,o=null,-1!==(f=i.__i=L(i,u,r,s))&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,\"function\"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a--:f==r+1?a++:(f>r?a--:a++,i.__u|=65536))):i=n.__k[t]=null;if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),N(o,o))}function I(n,l,u){var t,i;if(\"function\"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||\"boolean\"==typeof n||(y(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function L(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if((\"function\"!=typeof o||o===b||i)&&t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){\"-\"===l[0]?n.setProperty(l,null==u?\"\":u):n[l]=null==u?\"\":\"number\"!=typeof u||p.test(l)?u:u+\"px\"}function A(n,l,u,t,i){var o;n:if(\"style\"===l)if(\"string\"==typeof u)n.style.cssText=u;else{if(\"string\"==typeof t&&(n.style.cssText=t=\"\"),t)for(l in t)u&&l in u||T(n.style,l,\"\");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if(\"o\"===l[0]&&\"n\"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,\"$1\")),l=l.toLowerCase()in n||\"onFocusOut\"===l||\"onFocusIn\"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e,n.addEventListener(l,o?s:c,o)):n.removeEventListener(l,o?s:c,o);else{if(\"http://www.w3.org/2000/svg\"==i)l=l.replace(/xlink(H|:h)/,\"h\").replace(/sName$/,\"s\");else if(\"width\"!=l&&\"height\"!=l&&\"href\"!=l&&\"list\"!=l&&\"form\"!=l&&\"tabIndex\"!=l&&\"download\"!=l&&\"rowSpan\"!=l&&\"colSpan\"!=l&&\"role\"!=l&&\"popover\"!=l&&l in n)try{n[l]=null==u?\"\":u;break n}catch(n){}\"function\"==typeof u||(null==u||!1===u&&\"-\"!==l[4]?n.removeAttribute(l):n.setAttribute(l,\"popover\"==l&&1==u?\"\":u))}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e++;else if(u.t<t.u)return;return l.event&&(u=l.event(u)),\"handleEvent\"in t?t.handleEvent(u):t(u)}}}function O(n,u,t,i,o,r,f,e,c,s){var a,h,v,p,w,_,g,m,x,C,S,M,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if(\"function\"==typeof T)try{if(m=u.props,x=\"prototype\"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],S=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,S):(u.__c=h=new k(m,S),h.constructor=T,h.render=V),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=S,h.__n=i,v=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),p=h.props,w=h.state,h.__v=u,v)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else{if(x&&null==T.getDerivedStateFromProps&&m!==p&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,S),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,S)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.some(function(n){n&&(n.__=u)}),M=0;M<h._sb.length;M++)h.__h.push(h._sb[M]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,S),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(p,w,_)})}if(h.context=S,h.props=m,h.__P=n,h.__e=!1,$=l.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[]}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!v&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(p,w)),P(n,y(L=null!=a&&a.type===b&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null)}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:128;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e}else u.__e=t.__e,u.__k=t.__k;l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)E(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(u,t,i,o,r,f,e,c,s){var a,v,p,d,_,g,m,b=i.props,k=t.props,C=t.type;if(\"svg\"===C?r=\"http://www.w3.org/2000/svg\":\"math\"===C?r=\"http://www.w3.org/1998/Math/MathML\":r||(r=\"http://www.w3.org/1999/xhtml\"),null!=f)for(a=0;a<f.length;a++)if((_=f[a])&&\"setAttribute\"in _==!!C&&(C?_.localName===C:3===_.nodeType)){u=_,f[a]=null;break}if(null==u){if(null===C)return document.createTextNode(k);u=document.createElementNS(r,C,k.is&&k),c&&(l.__m&&l.__m(t,f),c=!1),f=null}if(null===C)b===k||c&&u.data===k||(u.data=k);else{if(f=f&&n.call(u.childNodes),b=i.props||h,!c&&null!=f)for(b={},a=0;a<u.attributes.length;a++)b[(_=u.attributes[a]).name]=_.value;for(a in b)if(_=b[a],\"children\"==a);else if(\"dangerouslySetInnerHTML\"==a)p=_;else if(!(a in k)){if(\"value\"==a&&\"defaultValue\"in k||\"checked\"==a&&\"defaultChecked\"in k)continue;A(u,a,null,_,r)}for(a in k)_=k[a],\"children\"==a?d=_:\"dangerouslySetInnerHTML\"==a?v=_:\"value\"==a?g=_:\"checked\"==a?m=_:c&&\"function\"!=typeof _||b[a]===_||A(u,a,_,b[a],r);if(v)c||p&&(v.__html===p.__html||v.__html===u.innerHTML)||(u.innerHTML=v.__html),t.__k=[];else if(p&&(u.innerHTML=\"\"),P(u,y(d)?d:[d],t,i,o,\"foreignObject\"===C?\"http://www.w3.org/1999/xhtml\":r,f,e,f?f[0]:i.__k&&x(i,0),c,s),null!=f)for(a=f.length;a--;)w(f[a]);c||(a=\"value\",\"progress\"===C&&null==g?u.removeAttribute(\"value\"):void 0!==g&&(g!==u[a]||\"progress\"===C&&!g||\"option\"===C&&g!==b[a])&&A(u,a,g,b[a],r),a=\"checked\",void 0!==m&&m!==u[a]&&A(u,a,m,b[a],r))}return u}function E(n,u,t){try{if(\"function\"==typeof n){var i=\"function\"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u))}else n.current=u}catch(n){l.__e(n,t)}}function N(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||E(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&N(i[o],u,t||\"function\"!=typeof n.type);t||w(n.__e),n.__c=n.__=n.__e=n.__d=void 0}function V(n,l,u){return this.constructor(n,u)}function q(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o=\"function\"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O(t,u=(!o&&i||t).__k=_(b,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j(f,u,e)}function B(n,l){q(n,l,B)}function D(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l=\"__cC\"+a++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=new Set,(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.forEach(function(n){n.__e=!0,S(n)})},this.sub=function(n){u.add(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.delete(n),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=v.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},u=0,t=function(n){return null!=n&&null==n.constructor},k.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),\"function\"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),S(this))},k.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),S(this))},k.prototype.render=b,i=[],r=\"function\"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f=function(n,l){return n.__v.__b-l.__v.__b},M.__r=0,e=0,c=F(!1),s=F(!0),a=0;export{k as Component,b as Fragment,D as cloneElement,G as createContext,_ as createElement,m as createRef,_ as h,B as hydrate,t as isValidElement,l as options,q as render,H as toChildArray};\n//# sourceMappingURL=preact.module.js.map\n","import{options as r,Fragment as e}from\"preact\";export{Fragment}from\"preact\";var t=/[\"&<]/;function n(r){if(0===r.length||!1===t.test(r))return r;for(var e=0,n=0,o=\"\",f=\"\";n<r.length;n++){switch(r.charCodeAt(n)){case 34:f=\"&quot;\";break;case 38:f=\"&amp;\";break;case 60:f=\"&lt;\";break;default:continue}n!==e&&(o+=r.slice(e,n)),o+=f,e=n+1}return n!==e&&(o+=r.slice(e,n)),o}var o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,f=0,i=Array.isArray;function u(e,t,n,o,i,u){t||(t={});var a,c,l=t;\"ref\"in t&&(a=t.ref,delete t.ref);var p={type:e,props:l,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u};if(\"function\"==typeof e&&(a=e.defaultProps))for(c in a)void 0===l[c]&&(l[c]=a[c]);return r.vnode&&r.vnode(p),p}function a(r){var t=u(e,{tpl:r,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var c={},l=/[A-Z]/g;function p(e,t){if(r.attr){var f=r.attr(e,t);if(\"string\"==typeof f)return f}if(\"ref\"===e||\"key\"===e)return\"\";if(\"style\"===e&&\"object\"==typeof t){var i=\"\";for(var u in t){var a=t[u];if(null!=a&&\"\"!==a){var p=\"-\"==u[0]?u:c[u]||(c[u]=u.replace(l,\"-$&\").toLowerCase()),_=\";\";\"number\"!=typeof a||p.startsWith(\"--\")||o.test(p)||(_=\"px;\"),i=i+p+\":\"+a+_}}return e+'=\"'+i+'\"'}return null==t||!1===t||\"function\"==typeof t||\"object\"==typeof t?\"\":!0===t?e:e+'=\"'+n(t)+'\"'}function _(r){if(null==r||\"boolean\"==typeof r||\"function\"==typeof r)return null;if(\"object\"==typeof r){if(void 0===r.constructor)return r;if(i(r)){for(var e=0;e<r.length;e++)r[e]=_(r[e]);return r}}return n(\"\"+r)}export{u as jsx,p as jsxAttr,u as jsxDEV,_ as jsxEscape,a as jsxTemplate,u as jsxs};\n//# sourceMappingURL=jsxRuntime.module.js.map\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizComponent extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = new (this as any).props.type()\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizInstance extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = (this as any).props.instance\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { format as d3Format } from \"d3-format\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class StatsTable extends StyledTable {\n\n protected transformData() {\n const totalRow = [[\"Total\", 0, 0]];\n const data = this.data();\n data.forEach(row => {\n totalRow[0][1] += row[1];\n totalRow[0][2] += row[2];\n });\n return data\n .concat(totalRow)\n .map(row => {\n return [\n row[0],\n this.secondColumnFormat_exists() ? d3Format(this.secondColumnFormat())(row[1]) : row[1],\n this.thirdColumnFormat_exists() ? d3Format(this.thirdColumnFormat())(row[2]) : row[2]\n ];\n })\n ;\n }\n\n update(domNode, element) {\n this.tbodyColumnStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\"\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\"\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\"\n }\n ]);\n this.evenRowStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n }\n ]);\n this.lastRowStyles_default({\n \"font-weight\": \"bold\"\n });\n super.update(domNode, element);\n }\n}\nStatsTable.prototype._class += \" html_StatsTable\";\n\nexport interface StatsTable {\n labelColor(): string;\n labelColor(_: string): this;\n primaryValueColor(): string;\n primaryValueColor(_: string): this;\n secondaryValueColor(): string;\n secondaryValueColor(_: string): this;\n evenRowFontColor(): string;\n evenRowFontColor(_: string): this;\n evenRowBackgroundColor(): string;\n evenRowBackgroundColor(_: string): this;\n firstColumnWidth(): string;\n firstColumnWidth(_: string): this;\n secondColumnWidth(): string;\n secondColumnWidth(_: string): this;\n thirdColumnWidth(): string;\n thirdColumnWidth(_: string): this;\n secondColumnFormat(): string;\n secondColumnFormat(_: string): this;\n secondColumnFormat_exists(): boolean;\n thirdColumnFormat(): string;\n thirdColumnFormat(_: string): this;\n thirdColumnFormat_exists(): boolean;\n}\nStatsTable.prototype.publish(\"labelColor\", \"#333\", \"html-color\", \"Color of the text in the first column\");\nStatsTable.prototype.publish(\"primaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the second column\");\nStatsTable.prototype.publish(\"secondaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the third column\");\nStatsTable.prototype.publish(\"evenRowBackgroundColor\", \"#333\", \"html-color\", \"Background color of the even rows\");\nStatsTable.prototype.publish(\"evenRowFontColor\", \"#333\", \"html-color\", \"Font color of the even rows\");\nStatsTable.prototype.publish(\"firstColumnWidth\", \"auto\", \"string\", \"CSS style applied as the 'width' for the first column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the second column (ex: 40px)\");\nStatsTable.prototype.publish(\"thirdColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the third column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnFormat\", \"$,.0f\", \"string\", \"d3-format specifier applied to the second column's values\", undefined, { optional: true });\nStatsTable.prototype.publish(\"thirdColumnFormat\", null, \"string\", \"d3-format specifier applied to the third column's values\", undefined, { optional: true });\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { JSXWidget } from \"./JSXWidget.ts\";\n\nimport \"../src/TitleBar.css\";\n\nexport interface IClickHandler {\n titleBarClick(src: Item, d, idx: number, groups): void;\n}\n\nexport class Item extends HTMLWidget {\n protected _owner: IClickHandler;\n\n constructor(owner: IClickHandler) {\n super();\n this._owner = owner;\n this._tag = \"a\";\n }\n}\nItem.prototype._class += \" html_Item\";\n\nexport class Button extends Item {\n private _icon: string;\n\n constructor(owner: IClickHandler, icon: string) {\n super(owner);\n this._icon = icon;\n }\n\n icon() {\n return this._icon;\n }\n\n enter(domNode: HTMLElement, element) {\n super.enter(domNode, element);\n element\n .attr(\"href\", \"#\")\n .on(\"click\", (d, idx, groups) => this._owner.titleBarClick(this, d, idx, groups))\n .append(\"i\")\n .attr(\"class\", `fa ${this._icon} fa-lg fa-fw`)\n ;\n }\n}\nButton.prototype._class += \" html_Button\";\n\nexport class ToggleButton extends Button {\n\n enter(domNode: HTMLElement, element) {\n element.on(\"click.sel\", (d, idx, groups) => {\n this.selected(!this.selected());\n this.render();\n });\n super.enter(domNode, element);\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._element.classed(\"selected\", this.selected());\n }\n}\nToggleButton.prototype._class += \" html_ToggleButton\";\nexport interface ToggleButton {\n selected(): boolean;\n selected(_: boolean): this;\n}\nToggleButton.prototype.publish(\"selected\", false, \"boolean\");\n\nexport class Spacer extends Item {\n\n enter(domNode, element) {\n super.enter(domNode, element);\n element\n .attr(\"class\", \"spacer\")\n .attr(\"href\", \"#\")\n .append(\"i\")\n ;\n }\n}\nSpacer.prototype._class += \" html_Spacer\";\n\nexport class TitleBar extends JSXWidget {\n protected _divMain;\n protected _divIconBar;\n protected _divTitle;\n\n constructor() {\n super();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._divMain = element.append(\"div\")\n .attr(\"class\", \"main\")\n ;\n this._divIconBar = this._divMain.append(\"div\")\n .attr(\"class\", \"icon-bar\")\n ;\n this._divTitle = this._divMain.append(\"div\")\n .attr(\"class\", \"title\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n this._divTitle.text(this.title());\n\n const icons = this._divIconBar.selectAll(\".icon-bar-item\").data(this.buttons());\n icons.enter().append(\"div\")\n .attr(\"class\", \"icon-bar-item\")\n .each(function (this: HTMLElement, d: Item) {\n d.target(this);\n })\n .merge(icons)\n .each(function (d: Item) {\n d.render();\n })\n ;\n icons.exit()\n .each(function (d: Item) {\n d.target(null);\n })\n .remove()\n ;\n icons.order();\n }\n}\nTitleBar.prototype._class += \" html_TitleBar\";\n\nexport interface TitleBar {\n title(): string;\n title(_: string): this;\n buttons(): Item[];\n buttons(items: Item[]): this;\n}\nTitleBar.prototype.publish(\"title\", \"\", \"string\");\nTitleBar.prototype.publish(\"buttons\", [], \"widgetArray\");\n"],"names":["HTMLWidget","scopedLogger","d3Select","React","l","u","r","jsx","d3Format"],"mappings":"+vBAAO,MAAM,SAAW,gBACX,YAAc,QACd,cAAgB,QCMtB,MAAM,oBAAoBA,OAAAA,UAAW,CAUxC,aAAc,CACJ,MAAA,EATH,sCACA,mCACG,uCAEA,sCACA,oCACA,0CAAwB,MAAU,4CAClC,6BAAyBC,kBAAa,kBAAkB,GAuO3D,iCAwDC,8BAAW,IA5Rf,KAAK,QAAQ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AA,MAAA,EAAQ,OAAO,KAAK,EACrB,KAAK,QAAS,eAAe,EAC7B,KAAK,SAA6B,EAAS,CACxC,EAAE,OAAO,IAAI,CAChB,CAAA,EACA,MAAM,KAAK,EACX,KAAK,SAAU,EAAS,CACrB,EAAE,OAAO,CAAA,CACZ,EAEL,MAAM,KAAK,EACN,KAAK,SAAU,EAAS,CACrB,EAAE,OAAO,IAAI,CAChB,CAAA,EACA,OAAO,EAEZ,MAAM,MAAM,CAAA,CAEpB,CACA,SAAS,UAAU,QAAU,iBAQ7B,SAAS,UAAU,QAAQ,QAAS,GAAI,QAAQ,EAChD,SAAS,UAAU,QAAQ,UAAW,CAAA,EAAI,aAAa","x_google_ignoreList":[7,8]}
1
+ {"version":3,"file":"index.umd.cjs","sources":["../src/__package__.ts","../src/HTMLTooltip.ts","../src/SimpleTable.ts","../src/StyledTable.ts","../src/BreakdownTable.ts","../src/JSXWidget.ts","../src/reactD3.ts","../../../node_modules/preact/dist/preact.module.js","../../../node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js","../src/VizComponent.tsx","../src/VizInstance.tsx","../src/StatsTable.ts","../src/TitleBar.ts"],"sourcesContent":["export const PKG_NAME = \"@hpcc-js/html\";\nexport const PKG_VERSION = \"3.1.1\";\nexport const BUILD_VERSION = \"3.2.1\";\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\nimport { scopedLogger, ScopedLogging } from \"@hpcc-js/util\";\n\ntype Direction = \"n\" | \"s\" | \"e\" | \"w\" | \"ne\" | \"nw\" | \"se\" | \"sw\";\ntype Position = { x: number, y: number };\ntype DirectionalBBox = { [key in Direction]: Position; };\n\ntype Rectangle = { top: number, left: number, width: number, height: number };\nexport class HTMLTooltip extends HTMLWidget {\n\n public _triggerElement;\n public _contentNode;\n protected _prevContentNode;\n\n protected _tooltipElement;\n protected _arrowElement;\n protected _tooltipHTMLCallback = (data?) => \"<b>_tooltipHTMLCallback is undefined</b>\";\n protected _logger: ScopedLogging = scopedLogger(\"html/HTMLTooltip\");\n constructor() {\n super();\n this.visible(false);\n }\n\n tooltipHTML(_: (data?) => string): this {\n this._tooltipHTMLCallback = _;\n return this;\n }\n\n tooltipContent(_): this {\n if (!arguments.length) return this._contentNode;\n this._contentNode = _;\n return this;\n }\n\n triggerElement(_): this {\n this._triggerElement = _;\n return this;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n const body = d3Select(\"body\");\n this._tooltipElement = body.append(\"div\")\n .attr(\"class\", \"tooltip-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n this._arrowElement = body.append(\"div\")\n .attr(\"class\", \"arrow-div\")\n .style(\"z-index\", \"2147483638\")\n .style(\"position\", \"fixed\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n if (this._contentNode !== this._prevContentNode) {\n const node = this._tooltipElement.node();\n [...node.querySelectorAll(\"*\")]\n .map(n => n.__data__)\n .filter(n => n)\n .forEach(w => {\n if (typeof w.target === \"function\") {\n w.target(null);\n }\n if (typeof w.exit === \"function\") {\n w.exit();\n }\n });\n node.innerHTML = \"\";\n node.appendChild(this._contentNode);\n this._prevContentNode = this._contentNode;\n }\n\n if (this._contentNode) {\n this.onShowContent(this._contentNode);\n } else {\n this._tooltipElement\n .html(() => {\n return this._tooltipHTMLCallback(this.data());\n });\n }\n if (this.fitContent()) {\n this._tooltipElement\n .style(\"width\", \"auto\")\n .style(\"height\", \"auto\")\n .style(\"padding\", \"0px\")\n .style(\"box-sizing\", \"content-box\")\n ;\n const rect = this._tooltipElement.node().getBoundingClientRect();\n this.tooltipWidth_default(rect.width);\n this.tooltipHeight_default(rect.height);\n }\n this._closing = false;\n this._tooltipElement\n .style(\"background-color\", this.tooltipColor())\n .style(\"color\", this.fontColor())\n .style(\"width\", this.tooltipWidth() + \"px\")\n .style(\"height\", this.tooltipHeight() + \"px\")\n .style(\"opacity\", 1)\n .style(\"padding\", this.padding() + \"px\")\n .style(\"pointer-events\", this.enablePointerEvents() ? \"all\" : \"none\")\n .style(\"box-sizing\", \"content-box\")\n ;\n this._arrowElement\n .style(\"opacity\", 1)\n .style(\"pointer-events\", \"none\")\n ;\n this.updateTooltipPosition();\n }\n\n onShowContent(node) {\n\n }\n\n protected updateTooltipPosition(): Position {\n const bbox = this.calcReferenceBBox();\n const direction = this.calcTooltipDirection(bbox);\n const box = bbox[direction];\n this._tooltipElement\n .style(\"top\", box.y + \"px\")\n .style(\"left\", box.x + \"px\")\n ;\n this.setArrowPosition(box, direction);\n return box;\n }\n\n protected calcTooltipDirection(bbox: DirectionalBBox): Direction {\n const directions: Direction[] = Object.keys(bbox) as Direction[];\n\n const defaultDirection = this.direction();\n directions.sort((a, b) => a === defaultDirection ? -1 : 1);\n const windowRect = {\n top: 0,\n left: 0,\n width: window.innerWidth,\n height: window.innerHeight\n };\n for (let i = 0; i < directions.length; i++) {\n const tooltipRect = {\n top: bbox[directions[i]].y,\n left: bbox[directions[i]].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n };\n if (this.rectFits(tooltipRect, windowRect)) {\n return directions[i];\n }\n }\n this._logger.warning(`Tooltip doesn't fit in the window for any of the directions. Defaulting to '${defaultDirection}'`);\n this._logger.debug(windowRect);\n this._logger.debug({\n top: bbox[defaultDirection].y,\n left: bbox[defaultDirection].x,\n width: this.tooltipWidth(),\n height: this.tooltipHeight()\n });\n return defaultDirection;\n }\n\n protected rectFits(innerRect: Rectangle, outerRect: Rectangle): boolean {\n return (\n innerRect.top >= outerRect.top &&\n innerRect.left >= outerRect.left &&\n innerRect.width + innerRect.left <= outerRect.width + outerRect.left &&\n innerRect.height + innerRect.top <= outerRect.height + outerRect.top\n );\n }\n\n protected setArrowPosition(point: Position, direction: Direction) {\n let top;\n let left;\n let visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border\", `${this.arrowHeight()}px solid ${this.tooltipColor()}`)\n .style(\"border-top-color\", \"transparent\")\n .style(\"border-right-color\", \"transparent\")\n .style(\"border-bottom-color\", \"transparent\")\n .style(\"border-left-color\", \"transparent\")\n ;\n switch (direction) {\n case \"n\":\n top = point.y + this.tooltipHeight() + (this.padding() * 2);\n left = point.x + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2) + this.padding();\n visibleBorderStyle = \"border-top-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowHeight()}px`)\n .style(\"border-bottom-width\", \"0px\")\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"s\":\n top = point.y - this.arrowHeight();\n left = point.x + this.padding() + (this.tooltipWidth() / 2) - (this.arrowWidth() / 2);\n visibleBorderStyle = \"border-bottom-color\";\n this._arrowElement\n .style(\"border-top-width\", \"0px\")\n .style(\"border-bottom-width\", `${this.arrowHeight()}px`)\n .style(\"border-left-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-right-width\", `${this.arrowWidth() / 2}px`)\n ;\n break;\n case \"e\":\n top = point.y + (this.tooltipHeight() / 2) + this.padding() - (this.arrowWidth() / 2);\n left = point.x - this.arrowHeight();\n visibleBorderStyle = \"border-right-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", \"0px\")\n .style(\"border-right-width\", `${this.arrowHeight()}px`)\n ;\n break;\n case \"w\":\n top = point.y + (this.tooltipHeight() / 2) - (this.arrowWidth() / 2) + this.padding();\n left = point.x + this.tooltipWidth() + (this.padding() * 2);\n visibleBorderStyle = \"border-left-color\";\n this._arrowElement\n .style(\"border-top-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-bottom-width\", `${this.arrowWidth() / 2}px`)\n .style(\"border-left-width\", `${this.arrowHeight()}px`)\n .style(\"border-right-width\", \"0px\")\n ;\n break;\n }\n if (typeof top !== \"undefined\" && typeof left !== \"undefined\") {\n this._arrowElement\n .style(\"top\", top + \"px\")\n .style(\"left\", left + \"px\")\n .style(visibleBorderStyle, this.tooltipColor())\n .style(\"opacity\", 1)\n ;\n } else {\n this._arrowElement\n .style(\"opacity\", 0)\n ;\n }\n return point;\n }\n\n protected getReferenceNode() {\n if (!this._triggerElement) {\n return this.element().node().parentNode.parentNode;\n }\n return this._triggerElement.node();\n }\n public _cursorLoc;\n protected calcReferenceBBox() {\n const node = this.getReferenceNode();\n let { top, left, width, height } = node.getBoundingClientRect();\n const wholeW = this.tooltipWidth();\n const wholeH = this.tooltipHeight();\n const halfW = wholeW / 2;\n const halfH = wholeH / 2;\n const arrowH = this.arrowHeight();\n const p = this.padding();\n const p2 = p * 2;\n\n if (this.followCursor() && this._cursorLoc) {\n\n left = this._cursorLoc[0];\n top = this._cursorLoc[1];\n width = 1;\n height = 1;\n }\n const bbox = {\n n: {\n x: left + (width / 2) - halfW - p,\n y: top - wholeH - arrowH - p2\n },\n e: {\n x: left + width + arrowH,\n y: top + (height / 2) - halfH - p\n },\n s: {\n x: left + (width / 2) - halfW - p,\n y: top + height + arrowH\n },\n w: {\n x: left - wholeW - arrowH - p2,\n y: top + (height / 2) - halfH - p\n },\n nw: {\n x: left - wholeW - p2,\n y: top - wholeH - p2\n },\n ne: {\n x: left + width,\n y: top - wholeH - p2\n },\n se: {\n x: left + width,\n y: top + height\n },\n sw: {\n x: left - wholeW - p2,\n y: top + height\n }\n };\n return bbox;\n }\n\n private _closing = false;\n mouseout() {\n this._closing = true;\n this._tooltipElement.on(\"mouseover\", () => {\n this._closing = false;\n });\n this._tooltipElement.on(\"mouseout\", () => {\n this.mouseout();\n });\n setTimeout(() => {\n if (this._closing) {\n this.visible(false);\n }\n }, this.closeDelay());\n }\n\n visible(): boolean;\n visible(_: boolean): this;\n visible(_?: boolean): boolean | this {\n if (!arguments.length) return super.visible();\n if (this._arrowElement) {\n this._arrowElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n this._tooltipElement.style(\"visibility\", _ ? \"visible\" : \"hidden\");\n }\n super.visible(_);\n return this;\n }\n\n exit(domNode, element) {\n if (this._arrowElement) {\n this._arrowElement.remove();\n this._tooltipElement.remove();\n }\n super.exit(domNode, element);\n }\n}\nHTMLTooltip.prototype._class += \" html_HTMLTooltip\";\n\nexport interface HTMLTooltip {\n padding(): number;\n padding(_: number): this;\n direction(): Direction;\n direction(_: Direction): this;\n arrowHeight(): number;\n arrowHeight(_: number): this;\n arrowWidth(): number;\n arrowWidth(_: number): this;\n fontColor(): string;\n fontColor(_: string): this;\n tooltipColor(): string;\n tooltipColor(_: string): this;\n tooltipWidth(): number;\n tooltipWidth(_: number): this;\n tooltipWidth_default(_: number);\n tooltipHeight(): number;\n tooltipHeight(_: number): this;\n tooltipHeight_default(_: number);\n followCursor(): boolean;\n followCursor(_: boolean): this;\n enablePointerEvents(): boolean;\n enablePointerEvents(_: boolean): this;\n closeDelay(): number;\n closeDelay(_: number): this;\n fitContent(): boolean;\n fitContent(_: boolean): this;\n\n}\n\nHTMLTooltip.prototype.publish(\"fitContent\", false, \"boolean\", \"If true, tooltip will grow to fit its html content\");\nHTMLTooltip.prototype.publish(\"followCursor\", false, \"boolean\", \"If true, tooltip will display relative to cursor location\");\nHTMLTooltip.prototype.publish(\"closeDelay\", 400, \"number\", \"Number of milliseconds to wait before closing tooltip (cancelled on tooltip mouseover event)\");\nHTMLTooltip.prototype.publish(\"direction\", \"n\", \"set\", \"Direction in which to display the tooltip\", [\"n\", \"s\", \"e\", \"w\", \"ne\", \"nw\", \"se\", \"sw\"]);\nHTMLTooltip.prototype.publish(\"padding\", 8, \"number\", \"Padding (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowWidth\", 16, \"number\", \"Width (or height depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"arrowHeight\", 8, \"number\", \"Height (or width depending on direction) of the tooltip arrow (pixels)\");\nHTMLTooltip.prototype.publish(\"fontColor\", \"#FFF\", \"html-color\", \"The default font color for text in the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipColor\", \"#000000EE\", \"html-color\", \"Background color of the tooltip\");\nHTMLTooltip.prototype.publish(\"tooltipWidth\", 200, \"number\", \"Width of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"tooltipHeight\", 200, \"number\", \"Height of the tooltip (not including arrow) (pixels)\");\nHTMLTooltip.prototype.publish(\"enablePointerEvents\", false, \"boolean\", \"If true, the 'pointer-events: all' style will be used\");\n","import { HTMLWidget, select as d3Select } from \"@hpcc-js/common\";\n\nexport class SimpleTable extends HTMLWidget {\n protected _table;\n protected _tbody;\n protected _thead;\n protected _theadRow;\n constructor() {\n super();\n }\n\n protected transformData() {\n return this.data();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n\n this._table = element.append(\"table\");\n this._thead = this._table.append(\"thead\");\n this._theadRow = this._thead.append(\"tr\");\n this._tbody = this._table.append(\"tbody\");\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._table\n .style(\"width\", this.autoWidth() ? \"auto\" : \"100%\")\n ;\n const theadTrSelection = this._theadRow.selectAll(\"th\").data(this.columns());\n theadTrSelection.enter()\n .append(\"th\")\n .attr(\"class\", (n, i) => `th-${i}`)\n .merge(theadTrSelection)\n .text(_d => (_d).toString())\n ;\n theadTrSelection.exit().remove();\n const trSelection = this._tbody.selectAll(\"tr\").data(this.transformData());\n trSelection.enter()\n .append(\"tr\")\n .merge(trSelection)\n .each(function (this, d) {\n const tr = d3Select(this);\n const tdSelection = tr.selectAll(\"td\").data(d);\n tdSelection.enter()\n .append(\"td\")\n .attr(\"class\", (n, i) => `col-${i}`)\n .merge(tdSelection as any)\n .text(_d => (_d).toString())\n ;\n tdSelection.exit().remove();\n })\n ;\n trSelection.exit().remove();\n }\n}\nSimpleTable.prototype._class += \" html_SimpleTable\";\n\nexport interface SimpleTable {\n autoWidth(): boolean;\n autoWidth(_: boolean): this;\n}\nSimpleTable.prototype.publish(\"autoWidth\", false, \"boolean\", \"If true, table width will be set to 'auto'. If false, the width is set to '100%'\");\n","import { SimpleTable } from \"./SimpleTable.ts\";\n\nexport class StyledTable extends SimpleTable {\n constructor() {\n super();\n }\n\n protected applyStyleObject(selection, styleObject) {\n Object.keys(styleObject).forEach(styleName => {\n selection.style(styleName, styleObject[styleName]);\n });\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n element.selectAll(\"tr,th,td\")\n .attr(\"style\", \"\")\n .style(\"font-family\", this.fontFamily())\n .style(\"color\", this.fontColor())\n ;\n\n this.theadColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.select(`.th-${i}`), styleObj);\n });\n this.tbodyColumnStyles().forEach((styleObj, i) => {\n this.applyStyleObject(element.selectAll(`.col-${i}`), styleObj);\n });\n const evenRowStylesExist = Object.keys(this.evenRowStyles()).length > 0;\n const lastRowStylesExist = Object.keys(this.lastRowStyles()).length > 0;\n const tbodyRows = element.selectAll(\"tbody > tr\");\n if (evenRowStylesExist) {\n const tbodyEvenRows = tbodyRows.select(function (this: HTMLElement, d, i) { return i % 2 ? this : null; });\n this.applyStyleObject(tbodyEvenRows, this.evenRowStyles());\n }\n if (lastRowStylesExist) {\n const tbodyLastRow = tbodyRows.select(function (this: HTMLElement, d, i, arr) { return i === arr.length - 1 ? this : null; });\n this.applyStyleObject(tbodyLastRow, this.lastRowStyles());\n }\n }\n}\nStyledTable.prototype._class += \" html_StyledTable\";\n\nexport interface StyledTable {\n fontFamily(): string;\n fontFamily(_: string): this;\n fontColor(): string;\n fontColor(_: string): this;\n tbodyColumnStyles(): Array<{ [styleID: string]: any }>;\n tbodyColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n tbodyColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles(): Array<{ [styleID: string]: any }>;\n theadColumnStyles(_: Array<{ [styleID: string]: any }>): this;\n theadColumnStyles_default(_: Array<{ [styleID: string]: any }>): this;\n lastRowStyles(): { [styleID: string]: any };\n lastRowStyles(_: { [styleID: string]: any }): this;\n lastRowStyles_default(_: { [styleID: string]: any }): this;\n evenRowStyles(): { [styleID: string]: any };\n evenRowStyles(_: { [styleID: string]: any }): this;\n evenRowStyles_default(_: { [styleID: string]: any }): this;\n}\n\nStyledTable.prototype.publish(\"fontFamily\", \"Verdana\", \"string\", \"Base font-family used within the table\");\nStyledTable.prototype.publish(\"fontColor\", \"#333\", \"string\", \"Base font color used within the table\");\nStyledTable.prototype.publish(\"theadColumnStyles\", [], \"array\", 'Array of objects containing styles for the thead columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"tbodyColumnStyles\", [], \"array\", 'Array of objects containing styles for the tbody columns (ex: [{\"color\":\"red\"},{\"color\":\"blue\"}])');\nStyledTable.prototype.publish(\"lastRowStyles\", {}, \"object\", 'Object containing styles for the last row (ex: {\"color\":\"red\"})');\nStyledTable.prototype.publish(\"evenRowStyles\", {}, \"object\", 'Object containing styles for even rows (ex: {\"background-color\":\"#AAA\"})');\n","import { HTMLTooltip } from \"./HTMLTooltip.ts\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class BreakdownTable extends StyledTable {\n // protected _table;\n // protected _tbody;\n protected _tooltip: HTMLTooltip;\n constructor() {\n super();\n }\n\n protected transformData() {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n return this.breakdownData(rowCount);\n }\n\n protected breakdownData(limit: number): any[] {\n const len = this.data().length;\n const sum = this.data().reduce((acc, row) => acc + row[1], 0);\n const data = [];\n let percSum = 0;\n this.data().sort((a, b) => a[1] > b[1] ? -1 : 1);\n const hiddenRowCount = len - limit;\n const showOther = hiddenRowCount > 0;\n this.data()\n .filter((_, i) => showOther ? i < limit - 1 : true)\n .forEach(row => {\n const perc = Math.round((row[1] / sum) * 100);\n percSum += perc;\n data.push([row[0], perc + \"%\"]);\n });\n if (showOther) {\n const otherLabel = `${this.otherLabel()} (${len - limit + 1})`;\n const otherPercentage = \"~\" + (100 - percSum) + \"%\";\n data.push([otherLabel, otherPercentage]);\n }\n return data;\n }\n\n protected calculateRowCount(): number {\n const theadRowHeight = this.columns().length > 0 ? this.thFontSize() + 5 : 0;\n const tbodyRowHeight = this.fontSize() + 5;\n const tbodyAvailableHeight = this.height() - theadRowHeight;\n const rowCount = Math.floor(tbodyAvailableHeight / tbodyRowHeight);\n return rowCount;\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._tooltip = new HTMLTooltip()\n .target(domNode)\n ;\n this._tooltip\n .tooltipHTML(data => {\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n const rowHeight = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).height)) ?? this.fontSize();\n const widestLabel = Math.max(...data.map(row => this.textSize(row[0], this.fontFamily(), this.fontSize()).width));\n const widestPerc = 30;\n const colCount = 2;\n const w = colCount * (widestLabel + widestPerc) + (this._tooltip.padding() * 2);\n const h = rowHeight * Math.ceil((data.length - rowCount) / colCount) + (this._tooltip.padding() * 2);\n this._tooltip.tooltipWidth(w);\n this._tooltip.tooltipHeight(h);\n const otherData = this.breakdownData(this.data().length).slice(rowCount - 1);\n return `<div style=\"\n width: 100%;\n height: 100%;\n font-size: ${this.fontSize()}px;\n \">${otherData.map(row =>\n `<div style=\"\n float:left;\n width:${Math.floor(99 / colCount)}%;\n \">${row[0]}: ${row[1]}</div>`\n ).join(\"\")\n }</div>`;\n })\n ;\n }\n\n update(domNode, element) {\n this.theadColumnStyles_default([\n {\n \"color\": this.thFirstColor(),\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"width\": \"1%\",\n \"font-size\": this.thFontSize() + \"px\",\n \"font-weight\": this.thFontWeight(),\n \"text-align\": this.percentageAlignment(),\n \"padding\": \"0px\"\n }\n ]);\n this.tbodyColumnStyles_default([\n {\n \"color\": this.topLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.topPercentageColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n this.lastRowStyles_default([\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherLabelBold() ? \"bold\" : \"normal\",\n \"text-align\": this.labelAlignment(),\n \"width\": \"auto\",\n \"padding\": \"0px\"\n },\n {\n \"color\": this.otherLabelColor(),\n \"font-size\": this.fontSize() + \"px\",\n \"font-weight\": this.otherPercentageBold() ? \"bold\" : \"normal\",\n \"text-align\": this.percentageAlignment(),\n \"width\": \"1%\",\n \"padding\": \"0px\"\n }\n ]);\n\n super.update(domNode, element);\n\n const rowCount = this.useCalculatedRowCount() ? this.calculateRowCount() : this.rowCount();\n if (rowCount < this.data().length) {\n const lastRow = element.select(\"tbody > tr:last-child\");\n const context = this;\n lastRow\n .on(\"mouseout.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .visible(false)\n .render()\n ;\n })\n .on(\"mouseenter.tooltip\", d => {\n context._tooltip._triggerElement = lastRow;\n context._tooltip\n .direction(\"n\")\n .data(context.data())\n .visible(true)\n .render()\n ;\n })\n ;\n }\n }\n\n}\nBreakdownTable.prototype._class += \" html_BreakdownTable\";\n\nexport interface BreakdownTable {\n useCalculatedRowCount(): boolean;\n useCalculatedRowCount(_: boolean): this;\n rowCount(): number;\n rowCount(_: number): this;\n fontSize(): number;\n fontSize(_: number): this;\n thFirstColor(): string;\n thFirstColor(_: string): this;\n thLastColor(): string;\n thLastColor(_: string): this;\n thFontSize(): number;\n thFontSize(_: number): this;\n thFontWeight(): string;\n thFontWeight(_: string): this;\n labelAlignment(): \"left\" | \"center\" | \"right\";\n labelAlignment(_: \"left\" | \"center\" | \"right\"): this;\n percentageAlignment(): \"left\" | \"center\" | \"right\";\n percentageAlignment(_: \"left\" | \"center\" | \"right\"): this;\n topLabelColor(): string;\n topLabelColor(_: string): this;\n topPercentageColor(): string;\n topPercentageColor(_: string): this;\n topPercentageBold(): boolean;\n topPercentageBold(_: boolean): this;\n otherLabel(): string;\n otherLabel(_: string): this;\n otherLabelColor(): string;\n otherLabelColor(_: string): this;\n otherLabelBold(): boolean;\n otherLabelBold(_: boolean): this;\n otherPercentageColor(): string;\n otherPercentageColor(_: string): this;\n otherPercentageBold(): boolean;\n otherPercentageBold(_: boolean): this;\n}\n\nBreakdownTable.prototype.publish(\"useCalculatedRowCount\", true, \"boolean\", \"If true, rowCount will be calculated and its default will be overwritten\");\nBreakdownTable.prototype.publish(\"rowCount\", 5, \"number\", \"Number of total rows to display (including the 'other' row)\", undefined, { disable: w => w.useCalculatedRowCount() });\nBreakdownTable.prototype.publish(\"fontSize\", 14, \"number\", \"Font size (pixels)\");\nBreakdownTable.prototype.publish(\"labelAlignment\", \"left\", \"set\", \"Alignment of the label column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"percentageAlignment\", \"center\", \"set\", \"Alignment of the percentage column text\", [\"left\", \"center\", \"right\"]);\nBreakdownTable.prototype.publish(\"topLabelColor\", \"#333\", \"html-color\", \"Color of displayed 'top' labels\");\nBreakdownTable.prototype.publish(\"topPercentageColor\", \"#1A99D5\", \"html-color\", \"Color of displayed 'top' percentages\");\nBreakdownTable.prototype.publish(\"topPercentageBold\", true, \"html-color\", \"If true, the 'top' percentages will be bold\");\nBreakdownTable.prototype.publish(\"otherLabel\", \"Other\", \"string\", \"Label text for the 'other' row\");\nBreakdownTable.prototype.publish(\"otherLabelColor\", \"#AAA\", \"html-color\", \"Color of the 'other' label\");\nBreakdownTable.prototype.publish(\"otherLabelBold\", false, \"html-color\", \"If true, the 'other' label will be bold\");\nBreakdownTable.prototype.publish(\"otherPercentageColor\", \"#AAA\", \"html-color\", \"Color of the 'other' percentage\");\nBreakdownTable.prototype.publish(\"otherPercentageBold\", false, \"html-color\", \"If true, the 'other' percentage will be bold\");\nBreakdownTable.prototype.publish(\"thFontWeight\", \"bold\", \"string\", \"Font weight for th elements\");\nBreakdownTable.prototype.publish(\"thFontSize\", 26, \"number\", \"Font size for th elements\");\nBreakdownTable.prototype.publish(\"thFirstColor\", \"#333\", \"html-color\", \"Text color of the first th element\");\nBreakdownTable.prototype.publish(\"thLastColor\", \"#333\", \"html-color\", \"Text color of the last th element\");\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { React } from \"@hpcc-js/react\";\n\nexport class JSXWidget extends HTMLWidget {\n static Component = React.Component;\n static createElement = React.createElement;\n protected rootNode;\n\n jsxRender(jsx, domNode) {\n this.rootNode = React.render(jsx, domNode, this.rootNode);\n }\n}\nJSXWidget.prototype._class += \" html_JSXWidget\";\n","import { select as d3Select } from \"@hpcc-js/common\";\n\nexport type ReactFn = (attrs: { [key: string]: string }) => VNode;\n\nexport type IVNode = new (attrs: { [key: string]: string }, children: VNode[]) => VNode;\n\nexport class VNode {\n protected _attrs: { [key: string]: string };\n protected _children: VNode[];\n\n constructor(attrs: { [key: string]: string }, children: VNode[]) {\n this._attrs = attrs;\n this._children = children;\n }\n\n type(): string {\n return \"div\";\n }\n\n attrs(): { [key: string]: string } {\n return this._attrs;\n }\n\n attr(key) {\n return this._attrs[key];\n }\n\n children(): VNode[] {\n return this._children;\n }\n\n update(targetElement) {\n for (const key in this._attrs) {\n targetElement.attr(key, this._attrs[key]);\n }\n }\n\n render(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data([this]);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(this.type())\n .attr(\"reactd3\", 0)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n\n renderChildren(targetElement) {\n const thisElement = targetElement.selectAll(`${targetElement.node().tagName} > *`).data(this._children);\n thisElement.exit()\n .remove();\n return thisElement.enter().append(d => document.createElement(d.type()))\n .attr(\"reactd3\", (_d, i) => i)\n .merge(thisElement)\n .each(function (this: HTMLElement, d: VNode) {\n const element = d3Select(this);\n d.update(element);\n d.renderChildren(element);\n })\n ;\n }\n}\n\nclass ConstVNode extends VNode {\n protected _type: string;\n\n constructor(type: string, attrs: { [key: string]: string }, children: VNode[]) {\n super(attrs, children);\n this._type = type;\n }\n\n type(): string {\n return this._type;\n }\n}\n\nclass TextVNode extends VNode {\n protected _text: string;\n\n constructor(text: string) {\n super({}, []);\n this._text = text;\n }\n\n type(): string {\n return \"span\";\n }\n\n update(targetElement) {\n super.update(targetElement);\n targetElement.text(this._text);\n }\n}\n\nfunction isReactFn(_): _ is ReactFn {\n return typeof _ === \"function\";\n}\n\nfunction isIVNode(_: any): _ is IVNode {\n return _.prototype && _.prototype instanceof VNode;\n}\n\nexport class ReactD3 {\n // static createElementXXX(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n static createElement(type: string | ReactFn | IVNode, attrs: { [key: string]: string }, ...children: Array<string | VNode>): VNode {\n if (isIVNode(type)) {\n return new (type as any)(attrs);\n } else if (isReactFn(type)) {\n return type(attrs);\n }\n return new ConstVNode(type, attrs, children.map(child => {\n if (typeof child === \"string\") {\n return new TextVNode(child);\n }\n return child;\n }));\n }\n\n static render(vdom: VNode, targetElement) {\n vdom.render(targetElement);\n }\n}\n","var n,l,u,t,i,o,r,f,e,c,s,a,h={},v=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function _(l,u,t){var i,o,r,f={};for(r in u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),\"function\"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g(l,f,i,o,null)}function g(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function m(){return{current:null}}function b(n){return n.children}function k(n,l){this.props=n,this.context=l}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return\"function\"==typeof n.type?x(n):null}function C(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C(n)}}function M(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!P.__r++||o!==l.debounceRendering)&&((o=l.debounceRendering)||r)(P)}function P(){var n,u,t,o,r,e,c,s;for(i.sort(f);n=i.shift();)n.__d&&(u=i.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l.vnode&&l.vnode(o),O(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j(c,o,s),o.__e!=e&&C(o)),i.length>u&&i.sort(f));P.__r=0}function S(n,l,u,t,i,o,r,f,e,c,s){var a,p,y,d,w,_=t&&t.__k||v,g=l.length;for(u.__d=e,$(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&(p=-1===y.__i?h:_[y.__i]||h,y.__i=a,O(n,y,p,i,o,r,f,e,c,s),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&N(p.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||p.__k===y.__k?e=I(y,e,n):\"function\"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w}function $(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=l[t])&&\"boolean\"!=typeof i&&\"function\"!=typeof i?(r=t+a,(i=n.__k[t]=\"string\"==typeof i||\"number\"==typeof i||\"bigint\"==typeof i||i.constructor==String?g(null,i,null,null,null):y(i)?g(b,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=n,i.__b=n.__b+1,o=null,-1!==(f=i.__i=L(i,u,r,s))&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,\"function\"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a--:f==r+1?a++:(f>r?a--:a++,i.__u|=65536))):i=n.__k[t]=null;if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V(o,o))}function I(n,l,u){var t,i;if(\"function\"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||\"boolean\"==typeof n||(y(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function L(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){\"-\"===l[0]?n.setProperty(l,null==u?\"\":u):n[l]=null==u?\"\":\"number\"!=typeof u||p.test(l)?u:u+\"px\"}function A(n,l,u,t,i){var o;n:if(\"style\"===l)if(\"string\"==typeof u)n.style.cssText=u;else{if(\"string\"==typeof t&&(n.style.cssText=t=\"\"),t)for(l in t)u&&l in u||T(n.style,l,\"\");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if(\"o\"===l[0]&&\"n\"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,\"$1\")),l=l.toLowerCase()in n||\"onFocusOut\"===l||\"onFocusIn\"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e,n.addEventListener(l,o?s:c,o)):n.removeEventListener(l,o?s:c,o);else{if(\"http://www.w3.org/2000/svg\"==i)l=l.replace(/xlink(H|:h)/,\"h\").replace(/sName$/,\"s\");else if(\"width\"!=l&&\"height\"!=l&&\"href\"!=l&&\"list\"!=l&&\"form\"!=l&&\"tabIndex\"!=l&&\"download\"!=l&&\"rowSpan\"!=l&&\"colSpan\"!=l&&\"role\"!=l&&\"popover\"!=l&&l in n)try{n[l]=null==u?\"\":u;break n}catch(n){}\"function\"==typeof u||(null==u||!1===u&&\"-\"!==l[4]?n.removeAttribute(l):n.setAttribute(l,\"popover\"==l&&1==u?\"\":u))}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e++;else if(u.t<t.u)return;return t(l.event?l.event(u):u)}}}function O(n,u,t,i,o,r,f,e,c,s){var a,h,v,p,w,_,g,m,x,C,M,P,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if(\"function\"==typeof T)try{if(m=u.props,x=\"prototype\"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],M=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,M):(u.__c=h=new k(m,M),h.constructor=T,h.render=q),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=M,h.__n=i,v=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),p=h.props,w=h.state,h.__v=u,v)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else{if(x&&null==T.getDerivedStateFromProps&&m!==p&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,M),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,M)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.some(function(n){n&&(n.__=u)}),P=0;P<h._sb.length;P++)h.__h.push(h._sb[P]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,M),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(p,w,_)})}if(h.context=M,h.props=m,h.__P=n,h.__e=!1,$=l.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[]}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!v&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(p,w)),S(n,y(L=null!=a&&a.type===b&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null)}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:32;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e}else u.__e=t.__e,u.__k=t.__k;l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(u,t,i,o,r,f,e,c,s){var a,v,p,d,_,g,m,b=i.props,k=t.props,C=t.type;if(\"svg\"===C?r=\"http://www.w3.org/2000/svg\":\"math\"===C?r=\"http://www.w3.org/1998/Math/MathML\":r||(r=\"http://www.w3.org/1999/xhtml\"),null!=f)for(a=0;a<f.length;a++)if((_=f[a])&&\"setAttribute\"in _==!!C&&(C?_.localName===C:3===_.nodeType)){u=_,f[a]=null;break}if(null==u){if(null===C)return document.createTextNode(k);u=document.createElementNS(r,C,k.is&&k),c&&(l.__m&&l.__m(t,f),c=!1),f=null}if(null===C)b===k||c&&u.data===k||(u.data=k);else{if(f=f&&n.call(u.childNodes),b=i.props||h,!c&&null!=f)for(b={},a=0;a<u.attributes.length;a++)b[(_=u.attributes[a]).name]=_.value;for(a in b)if(_=b[a],\"children\"==a);else if(\"dangerouslySetInnerHTML\"==a)p=_;else if(!(a in k)){if(\"value\"==a&&\"defaultValue\"in k||\"checked\"==a&&\"defaultChecked\"in k)continue;A(u,a,null,_,r)}for(a in k)_=k[a],\"children\"==a?d=_:\"dangerouslySetInnerHTML\"==a?v=_:\"value\"==a?g=_:\"checked\"==a?m=_:c&&\"function\"!=typeof _||b[a]===_||A(u,a,_,b[a],r);if(v)c||p&&(v.__html===p.__html||v.__html===u.innerHTML)||(u.innerHTML=v.__html),t.__k=[];else if(p&&(u.innerHTML=\"\"),S(u,y(d)?d:[d],t,i,o,\"foreignObject\"===C?\"http://www.w3.org/1999/xhtml\":r,f,e,f?f[0]:i.__k&&x(i,0),c,s),null!=f)for(a=f.length;a--;)w(f[a]);c||(a=\"value\",\"progress\"===C&&null==g?u.removeAttribute(\"value\"):void 0!==g&&(g!==u[a]||\"progress\"===C&&!g||\"option\"===C&&g!==b[a])&&A(u,a,g,b[a],r),a=\"checked\",void 0!==m&&m!==u[a]&&A(u,a,m,b[a],r))}return u}function N(n,u,t){try{if(\"function\"==typeof n){var i=\"function\"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u))}else n.current=u}catch(n){l.__e(n,t)}}function V(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&V(i[o],u,t||\"function\"!=typeof n.type);t||w(n.__e),n.__c=n.__=n.__e=n.__d=void 0}function q(n,l,u){return this.constructor(n,u)}function B(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o=\"function\"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O(t,u=(!o&&i||t).__k=_(b,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j(f,u,e)}function D(n,l){B(n,l,D)}function E(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l=\"__cC\"+a++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,M(n)})},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.splice(u.indexOf(n),1),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=v.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},u=0,t=function(n){return null!=n&&null==n.constructor},k.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),\"function\"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),M(this))},k.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),M(this))},k.prototype.render=b,i=[],r=\"function\"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f=function(n,l){return n.__v.__b-l.__v.__b},P.__r=0,e=0,c=F(!1),s=F(!0),a=0;export{k as Component,b as Fragment,E as cloneElement,G as createContext,_ as createElement,m as createRef,_ as h,D as hydrate,t as isValidElement,l as options,B as render,H as toChildArray};\n//# sourceMappingURL=preact.module.js.map\n","import{options as r,Fragment as e}from\"preact\";export{Fragment}from\"preact\";var t=/[\"&<]/;function n(r){if(0===r.length||!1===t.test(r))return r;for(var e=0,n=0,o=\"\",f=\"\";n<r.length;n++){switch(r.charCodeAt(n)){case 34:f=\"&quot;\";break;case 38:f=\"&amp;\";break;case 60:f=\"&lt;\";break;default:continue}n!==e&&(o+=r.slice(e,n)),o+=f,e=n+1}return n!==e&&(o+=r.slice(e,n)),o}var o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,f=0,i=Array.isArray;function u(e,t,n,o,i,u){t||(t={});var a,c,p=t;if(\"ref\"in p)for(c in p={},t)\"ref\"==c?a=t[c]:p[c]=t[c];var l={type:e,props:p,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u};if(\"function\"==typeof e&&(a=e.defaultProps))for(c in a)void 0===p[c]&&(p[c]=a[c]);return r.vnode&&r.vnode(l),l}function a(r){var t=u(e,{tpl:r,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var c={},p=/[A-Z]/g;function l(e,t){if(r.attr){var f=r.attr(e,t);if(\"string\"==typeof f)return f}if(\"ref\"===e||\"key\"===e)return\"\";if(\"style\"===e&&\"object\"==typeof t){var i=\"\";for(var u in t){var a=t[u];if(null!=a&&\"\"!==a){var l=\"-\"==u[0]?u:c[u]||(c[u]=u.replace(p,\"-$&\").toLowerCase()),_=\";\";\"number\"!=typeof a||l.startsWith(\"--\")||o.test(l)||(_=\"px;\"),i=i+l+\":\"+a+_}}return e+'=\"'+i+'\"'}return null==t||!1===t||\"function\"==typeof t||\"object\"==typeof t?\"\":!0===t?e:e+'=\"'+n(t)+'\"'}function _(r){if(null==r||\"boolean\"==typeof r||\"function\"==typeof r)return null;if(\"object\"==typeof r){if(void 0===r.constructor)return r;if(i(r)){for(var e=0;e<r.length;e++)r[e]=_(r[e]);return r}}return n(\"\"+r)}export{u as jsx,l as jsxAttr,u as jsxDEV,_ as jsxEscape,a as jsxTemplate,u as jsxs};\n//# sourceMappingURL=jsxRuntime.module.js.map\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizComponent extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = new (this as any).props.type()\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { JSXWidget } from \"./JSXWidget.ts\";\n\nexport class VizInstance extends JSXWidget.Component<any, any> {\n widget;\n\n refreshProps() {\n for (const key in (this as any).props) {\n if (this.widget[key] && typeof this.widget[key] === \"function\") {\n this.widget[key]((this as any).props[key]);\n }\n }\n }\n\n componentDidMount() {\n this.widget = (this as any).props.instance\n .target((this as any).base)\n ;\n this.refreshProps();\n this.widget\n .render()\n ;\n }\n\n componentWillUnmount() {\n this.widget\n .target(null)\n .render()\n ;\n }\n\n render() {\n return <div style={(this as any).props.style} />;\n }\n\n componentDidUpdate() {\n this.refreshProps();\n this.widget.render();\n }\n}\n","import { format as d3Format } from \"d3-format\";\nimport { StyledTable } from \"./StyledTable.ts\";\n\nexport class StatsTable extends StyledTable {\n\n protected transformData() {\n const totalRow = [[\"Total\", 0, 0]];\n const data = this.data();\n data.forEach(row => {\n totalRow[0][1] += row[1];\n totalRow[0][2] += row[2];\n });\n return data\n .concat(totalRow)\n .map(row => {\n return [\n row[0],\n this.secondColumnFormat_exists() ? d3Format(this.secondColumnFormat())(row[1]) : row[1],\n this.thirdColumnFormat_exists() ? d3Format(this.thirdColumnFormat())(row[2]) : row[2]\n ];\n })\n ;\n }\n\n update(domNode, element) {\n this.tbodyColumnStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\"\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\"\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\"\n }\n ]);\n this.evenRowStyles_default([\n {\n \"font-weight\": \"bold\",\n \"width\": this.firstColumnWidth(),\n \"text-align\": \"left\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.secondColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n },\n {\n \"width\": this.thirdColumnWidth(),\n \"text-align\": \"right\",\n \"font-color\": this.evenRowFontColor(),\n \"background-color\": this.evenRowBackgroundColor()\n }\n ]);\n this.lastRowStyles_default({\n \"font-weight\": \"bold\"\n });\n super.update(domNode, element);\n }\n}\nStatsTable.prototype._class += \" html_StatsTable\";\n\nexport interface StatsTable {\n labelColor(): string;\n labelColor(_: string): this;\n primaryValueColor(): string;\n primaryValueColor(_: string): this;\n secondaryValueColor(): string;\n secondaryValueColor(_: string): this;\n evenRowFontColor(): string;\n evenRowFontColor(_: string): this;\n evenRowBackgroundColor(): string;\n evenRowBackgroundColor(_: string): this;\n firstColumnWidth(): string;\n firstColumnWidth(_: string): this;\n secondColumnWidth(): string;\n secondColumnWidth(_: string): this;\n thirdColumnWidth(): string;\n thirdColumnWidth(_: string): this;\n secondColumnFormat(): string;\n secondColumnFormat(_: string): this;\n secondColumnFormat_exists(): boolean;\n thirdColumnFormat(): string;\n thirdColumnFormat(_: string): this;\n thirdColumnFormat_exists(): boolean;\n}\nStatsTable.prototype.publish(\"labelColor\", \"#333\", \"html-color\", \"Color of the text in the first column\");\nStatsTable.prototype.publish(\"primaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the second column\");\nStatsTable.prototype.publish(\"secondaryValueColor\", \"#333\", \"html-color\", \"Color of the text in the third column\");\nStatsTable.prototype.publish(\"evenRowBackgroundColor\", \"#333\", \"html-color\", \"Background color of the even rows\");\nStatsTable.prototype.publish(\"evenRowFontColor\", \"#333\", \"html-color\", \"Font color of the even rows\");\nStatsTable.prototype.publish(\"firstColumnWidth\", \"auto\", \"string\", \"CSS style applied as the 'width' for the first column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the second column (ex: 40px)\");\nStatsTable.prototype.publish(\"thirdColumnWidth\", \"1%\", \"string\", \"CSS style applied as the 'width' for the third column (ex: 40px)\");\nStatsTable.prototype.publish(\"secondColumnFormat\", \"$,.0f\", \"string\", \"d3-format specifier applied to the second column's values\", undefined, { optional: true });\nStatsTable.prototype.publish(\"thirdColumnFormat\", null, \"string\", \"d3-format specifier applied to the third column's values\", undefined, { optional: true });\n","import { HTMLWidget } from \"@hpcc-js/common\";\nimport { JSXWidget } from \"./JSXWidget.ts\";\n\nimport \"../src/TitleBar.css\";\n\nexport interface IClickHandler {\n titleBarClick(src: Item, d, idx: number, groups): void;\n}\n\nexport class Item extends HTMLWidget {\n protected _owner: IClickHandler;\n\n constructor(owner: IClickHandler) {\n super();\n this._owner = owner;\n this._tag = \"a\";\n }\n}\nItem.prototype._class += \" html_Item\";\n\nexport class Button extends Item {\n private _icon: string;\n\n constructor(owner: IClickHandler, icon: string) {\n super(owner);\n this._icon = icon;\n }\n\n icon() {\n return this._icon;\n }\n\n enter(domNode: HTMLElement, element) {\n super.enter(domNode, element);\n element\n .attr(\"href\", \"#\")\n .on(\"click\", (d, idx, groups) => this._owner.titleBarClick(this, d, idx, groups))\n .append(\"i\")\n .attr(\"class\", `fa ${this._icon} fa-lg fa-fw`)\n ;\n }\n}\nButton.prototype._class += \" html_Button\";\n\nexport class ToggleButton extends Button {\n\n enter(domNode: HTMLElement, element) {\n element.on(\"click.sel\", (d, idx, groups) => {\n this.selected(!this.selected());\n this.render();\n });\n super.enter(domNode, element);\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n this._element.classed(\"selected\", this.selected());\n }\n}\nToggleButton.prototype._class += \" html_ToggleButton\";\nexport interface ToggleButton {\n selected(): boolean;\n selected(_: boolean): this;\n}\nToggleButton.prototype.publish(\"selected\", false, \"boolean\");\n\nexport class Spacer extends Item {\n\n enter(domNode, element) {\n super.enter(domNode, element);\n element\n .attr(\"class\", \"spacer\")\n .attr(\"href\", \"#\")\n .append(\"i\")\n ;\n }\n}\nSpacer.prototype._class += \" html_Spacer\";\n\nexport class TitleBar extends JSXWidget {\n protected _divMain;\n protected _divIconBar;\n protected _divTitle;\n\n constructor() {\n super();\n }\n\n enter(domNode, element) {\n super.enter(domNode, element);\n this._divMain = element.append(\"div\")\n .attr(\"class\", \"main\")\n ;\n this._divIconBar = this._divMain.append(\"div\")\n .attr(\"class\", \"icon-bar\")\n ;\n this._divTitle = this._divMain.append(\"div\")\n .attr(\"class\", \"title\")\n ;\n }\n\n update(domNode, element) {\n super.update(domNode, element);\n\n this._divTitle.text(this.title());\n\n const icons = this._divIconBar.selectAll(\".icon-bar-item\").data(this.buttons());\n icons.enter().append(\"div\")\n .attr(\"class\", \"icon-bar-item\")\n .each(function (this: HTMLElement, d: Item) {\n d.target(this);\n })\n .merge(icons)\n .each(function (d: Item) {\n d.render();\n })\n ;\n icons.exit()\n .each(function (d: Item) {\n d.target(null);\n })\n .remove()\n ;\n icons.order();\n }\n}\nTitleBar.prototype._class += \" html_TitleBar\";\n\nexport interface TitleBar {\n title(): string;\n title(_: string): this;\n buttons(): Item[];\n buttons(items: Item[]): this;\n}\nTitleBar.prototype.publish(\"title\", \"\", \"string\");\nTitleBar.prototype.publish(\"buttons\", [], \"widgetArray\");\n"],"names":["HTMLWidget","scopedLogger","d3Select","React","l","u","r","jsx","d3Format"],"mappings":"+vBAAO,MAAM,SAAW,gBACX,YAAc,QACd,cAAgB,QCMtB,MAAM,oBAAoBA,OAAAA,UAAW,CAUxC,aAAc,CACJ,MAAA,EATH,sCACA,mCACG,uCAEA,sCACA,oCACA,0CAAwB,MAAU,4CAClC,6BAAyBC,kBAAa,kBAAkB,GAuO3D,iCAwDC,8BAAW,IA5Rf,KAAK,QAAQ,EAAK,CAAA,CAGtB,YAAY,EAA4B,CACpC,YAAK,qBAAuB,EACrB,IAAA,CAGX,eAAe,EAAS,CAC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O,KAAK,EACrB,KAAK,QAAS,eAAe,EAC7B,KAAK,SAA6B,EAAS,CACxC,EAAE,OAAO,IAAI,CAChB,CAAA,EACA,MAAM,KAAK,EACX,KAAK,SAAU,EAAS,CACrB,EAAE,OAAO,CAAA,CACZ,EAEL,MAAM,KAAK,EACN,KAAK,SAAU,EAAS,CACrB,EAAE,OAAO,IAAI,CAChB,CAAA,EACA,OAAO,EAEZ,MAAM,MAAM,CAAA,CAEpB,CACA,SAAS,UAAU,QAAU,iBAQ7B,SAAS,UAAU,QAAQ,QAAS,GAAI,QAAQ,EAChD,SAAS,UAAU,QAAQ,UAAW,CAAA,EAAI,aAAa","x_google_ignoreList":[7,8]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hpcc-js/html",
3
- "version": "3.2.0",
3
+ "version": "3.2.2",
4
4
  "description": "hpcc-js - Viz HTML",
5
5
  "type": "module",
6
6
  "main": "./dist/index.umd.cjs",
@@ -37,12 +37,12 @@
37
37
  "update-major": "npx --yes npm-check-updates -u"
38
38
  },
39
39
  "dependencies": {
40
- "@hpcc-js/common": "^3.3.0",
41
- "@hpcc-js/react": "^3.2.0",
42
- "@hpcc-js/util": "^3.3.0"
40
+ "@hpcc-js/common": "^3.3.1",
41
+ "@hpcc-js/react": "^3.2.2",
42
+ "@hpcc-js/util": "^3.3.1"
43
43
  },
44
44
  "devDependencies": {
45
- "@hpcc-js/esbuild-plugins": "^1.4.0",
45
+ "@hpcc-js/esbuild-plugins": "^1.4.1",
46
46
  "d3-format": "^1",
47
47
  "d3-selection": "^1"
48
48
  },
@@ -57,5 +57,5 @@
57
57
  "url": "https://github.com/hpcc-systems/Visualization/issues"
58
58
  },
59
59
  "homepage": "https://github.com/hpcc-systems/Visualization",
60
- "gitHead": "145a4d4c8189c70f08e9804e63959d6dd398bd9f"
60
+ "gitHead": "521692e7cfd01c274d5cfff0c54e79d1686d3dd6"
61
61
  }