@bino-bi/bn-template-engine 1.0.0-alpha.2 → 1.0.0-alpha.3
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/bn-template-engine/bn-template-engine.esm.js +1 -1
- package/dist/bn-template-engine/{p-a95ccc16.entry.js → p-1970906d.entry.js} +1 -1
- package/dist/bn-template-engine/{p-0ca8dc17.entry.js → p-1dbd339c.entry.js} +1 -1
- package/dist/bn-template-engine/p-2e68cf09.entry.js +1 -0
- package/dist/bn-template-engine/{p-bc59ea5c.entry.js → p-31cc6a2d.entry.js} +1 -1
- package/dist/bn-template-engine/{p--PSoPbDM.js → p-8tsCnxIz.js} +1 -1
- package/dist/bn-template-engine/{p-dd9dd407.entry.js → p-997b2fe4.entry.js} +1 -1
- package/dist/bn-template-engine/{p-DgfL-ffj.js → p-B4ySv9KQ.js} +1 -1
- package/dist/bn-template-engine/{p-DVo6aZUE.js → p-BL8gyUwE.js} +1 -1
- package/dist/bn-template-engine/{p-CvXqez4D.js → p-C0yAPzJz.js} +1 -1
- package/dist/bn-template-engine/p-DtdQCMzj.js +1 -0
- package/dist/bn-template-engine/{p-e102a490.entry.js → p-a90f1cbe.entry.js} +1 -1
- package/dist/bn-template-engine/{p-35638ad0.entry.js → p-d7f0cbaf.entry.js} +1 -1
- package/dist/bn-template-engine/{p-1d9a3be9.entry.js → p-dfb61aa5.entry.js} +1 -1
- package/dist/bn-template-engine/{p-f89e55c6.entry.js → p-ece17f84.entry.js} +1 -1
- package/dist/bn-template-engine/p-fd427179.entry.js +1 -0
- package/dist/bn-template-engine/p-sqjrku2z.js +1 -0
- package/dist/cjs/{DataFormatDigits-CbIVfGEH.js → DataFormatDigits-DAmZzqbD.js} +1 -1
- package/dist/cjs/{DateStringFactory-CfkXYAMN.js → DateStringFactory-CcluhpGI.js} +1 -1
- package/dist/cjs/{Order-DtpbD8mQ.js → Order-BKoDS21t.js} +28 -0
- package/dist/cjs/{SVGVariancesStyleGroup-D-rTWlDo.js → SVGVariancesStyleGroup-DYYAU-81.js} +1 -1
- package/dist/cjs/{StringAdapter-ByCHdlDO.js → StringAdapter-Bneo8T4k.js} +1 -1
- package/dist/cjs/bn-body_4.cjs.entry.js +4 -4
- package/dist/cjs/bn-chart-structure.cjs.entry.js +3 -3
- package/dist/cjs/bn-chart-time.cjs.entry.js +3 -3
- package/dist/cjs/bn-context_5.cjs.entry.js +115 -44
- package/dist/cjs/bn-grid.cjs.entry.js +3 -3
- package/dist/cjs/bn-image.cjs.entry.js +3 -3
- package/dist/cjs/bn-template-engine.cjs.js +1 -1
- package/dist/cjs/bn-text.cjs.entry.js +3 -3
- package/dist/cjs/bn-tree.cjs.entry.js +3 -3
- package/dist/cjs/ibcs-chart-structure.cjs.entry.js +4 -4
- package/dist/cjs/ibcs-chart-time.cjs.entry.js +5 -5
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{withStyled-BBtMesx3.js → withStyled-CW30Bh6c.js} +6 -2
- package/dist/collection/components/bn-table/bn-table.js +63 -12
- package/dist/collection/components/bn-table/ibcs-table.css +7 -5
- package/dist/collection/components/bn-table/ibcs-table.js +22 -1
- package/dist/collection/components/bn-table/utils/elements/CellBarChart.js +56 -25
- package/dist/collection/components/bn-table/utils/elements/TableRow.js +3 -1
- package/dist/collection/components/bn-table/utils/factories/tableDataSetFactory.js +12 -3
- package/dist/collection/components/bn-table/utils/helper/ColumnStatistics.js +9 -1
- package/dist/collection/utils/constants.js +27 -0
- package/dist/collection/utils/validate.js +4 -1
- package/dist/components/DataFormatDigits.js +1 -1
- package/dist/components/DateStringFactory.js +1 -1
- package/dist/components/Order.js +1 -1
- package/dist/components/SVGVariancesStyleGroup.js +1 -1
- package/dist/components/bn-chart-structure.js +1 -1
- package/dist/components/bn-chart-time.js +1 -1
- package/dist/components/bn-table.js +1 -1
- package/dist/components/bn-title2.js +1 -1
- package/dist/components/ibcs-chart-structure2.js +1 -1
- package/dist/components/ibcs-chart-time2.js +1 -1
- package/dist/components/ibcs-table2.js +1 -1
- package/dist/components/ibcs-title2.js +1 -1
- package/dist/components/ibcsRuleSet.js +1 -1
- package/dist/components/validate.js +1 -1
- package/dist/esm/{DataFormatDigits-DYdbRX-1.js → DataFormatDigits--qIbKvXa.js} +1 -1
- package/dist/esm/{DateStringFactory-DRcbojUT.js → DateStringFactory-XWdUjsn8.js} +1 -1
- package/dist/esm/{Order-DdexOqTs.js → Order-sqjrku2z.js} +28 -1
- package/dist/esm/{SVGVariancesStyleGroup-D0Cwprv1.js → SVGVariancesStyleGroup-ibg3sLjM.js} +1 -1
- package/dist/esm/{StringAdapter-CTL-Dvzp.js → StringAdapter-BCLJpQQ8.js} +1 -1
- package/dist/esm/bn-body_4.entry.js +4 -4
- package/dist/esm/bn-chart-structure.entry.js +3 -3
- package/dist/esm/bn-chart-time.entry.js +3 -3
- package/dist/esm/bn-context_5.entry.js +115 -44
- package/dist/esm/bn-grid.entry.js +3 -3
- package/dist/esm/bn-image.entry.js +3 -3
- package/dist/esm/bn-template-engine.js +1 -1
- package/dist/esm/bn-text.entry.js +3 -3
- package/dist/esm/bn-tree.entry.js +3 -3
- package/dist/esm/ibcs-chart-structure.entry.js +4 -4
- package/dist/esm/ibcs-chart-time.entry.js +5 -5
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{withStyled-DCipbf2O.js → withStyled-D1fAWJ3g.js} +6 -3
- package/dist/types/components/bn-table/bn-table.d.ts +11 -7
- package/dist/types/components/bn-table/ibcs-table.d.ts +1 -0
- package/dist/types/components/bn-table/utils/elements/Cell.d.ts +1 -0
- package/dist/types/components/bn-table/utils/elements/CellBarChart.d.ts +3 -0
- package/dist/types/components.d.ts +22 -2
- package/dist/types/utils/constants.d.ts +15 -0
- package/dist/types/utils/validate.d.ts +1 -0
- package/package.json +1 -1
- package/dist/bn-template-engine/p-60a7fc59.entry.js +0 -1
- package/dist/bn-template-engine/p-DdexOqTs.js +0 -1
- package/dist/bn-template-engine/p-DyRaC0MB.js +0 -1
- package/dist/bn-template-engine/p-d279b578.entry.js +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -6,7 +6,7 @@ var appGlobals = require('./app-globals-V2Kpy_OQ.js');
|
|
|
6
6
|
const defineCustomElements = async (win, options) => {
|
|
7
7
|
if (typeof window === 'undefined') return undefined;
|
|
8
8
|
await appGlobals.globalScripts();
|
|
9
|
-
return index.bootstrapLazy(JSON.parse("[[\"bn-layout-page.cjs\",[[257,\"bn-layout-page\",{\"styles\":[1],\"messageText\":[1,\"message-text\"],\"messageImage\":[1,\"message-image\"],\"titleBusinessUnit\":[1,\"title-business-unit\"],\"titleScenarios\":[1,\"title-scenarios\"],\"titleVariances\":[1,\"title-variances\"],\"titleOrder\":[1,\"title-order\"],\"titleOrderDirection\":[1,\"title-order-direction\"],\"titleMeasures\":[1,\"title-measures\"],\"titleDateStart\":[1,\"title-date-start\"],\"titleDateEnd\":[1,\"title-date-end\"],\"titleDateFormat\":[1,\"title-date-format\"],\"titleDateLink\":[1,\"title-date-link\"],\"titleNamespace\":[1,\"title-namespace\"],\"pageFormat\":[1,\"page-format\"],\"pageOrientation\":[1,\"page-orientation\"],\"pageNumber\":[1,\"page-number\"],\"footerText\":[1,\"footer-text\"],\"footerDisplayPageNumber\":[4,\"footer-display-page-number\"],\"pageLayout\":[1,\"page-layout\"],\"pageCustomTemplate\":[1,\"page-custom-template\"],\"pageGridGap\":[1,\"page-grid-gap\"],\"pageFitToContent\":[4,\"page-fit-to-content\"],\"getNumberOfSlot\":[64]}]]],[\"bn-layout-card.cjs\",[[257,\"bn-layout-card\",{\"styles\":[1],\"titleImage\":[1,\"title-image\"],\"titleBusinessUnit\":[1,\"title-business-unit\"],\"titleScenarios\":[1,\"title-scenarios\"],\"titleVariances\":[1,\"title-variances\"],\"titleOrder\":[1,\"title-order\"],\"titleOrderDirection\":[1,\"title-order-direction\"],\"titleMeasures\":[1,\"title-measures\"],\"titleDateStart\":[1,\"title-date-start\"],\"titleDateEnd\":[1,\"title-date-end\"],\"titleDateFormat\":[1,\"title-date-format\"],\"titleDateLink\":[1,\"title-date-link\"],\"titleNamespace\":[1,\"title-namespace\"],\"footerText\":[1,\"footer-text\"],\"cardLayout\":[1,\"card-layout\"],\"cardCustomTemplate\":[1,\"card-custom-template\"],\"cardGridGap\":[1,\"card-grid-gap\"],\"cardFitToContent\":[4,\"card-fit-to-content\"],\"cardShowBorder\":[4,\"card-show-border\"],\"getNumberOfSlot\":[64]}]]],[\"bn-chart-structure.cjs\",[[1,\"bn-chart-structure\",{\"chartTitle\":[1,\"chart-title\"],\"filter\":[1],\"scenarios\":[1],\"variances\":[1],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"level\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"limit\":[2],\"showCategories\":[1,\"show-categories\"],\"measureScale\":[1,\"measure-scale\"],\"showMeasureScale\":[1,\"show-measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"stack\":[1],\"scale\":[1],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"level\":[{\"validateLevel\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"limit\":[{\"validateLimit\":0}],\"showCategories\":[{\"validateShowCategories\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"stack\":[{\"validateStack\":0}],\"scale\":[{\"validateScaling\":0}]}]]],[\"bn-chart-time.cjs\",[[1,\"bn-chart-time\",{\"chartTitle\":[1,\"chart-title\"],\"filter\":[1],\"scenarios\":[1],\"variances\":[1],\"syncSpaceLeft\":[2,\"sync-space-left\"],\"limit\":[2],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"level\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"dateInterval\":[1,\"date-interval\"],\"chartMode\":[1,\"chart-mode\"],\"maxBars\":[2,\"max-bars\"],\"stack\":[1],\"scale\":[1],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"axisLabelsMode\":[1,\"axis-labels-mode\"],\"lineFullWidth\":[1,\"line-full-width\"],\"showCategories\":[1,\"show-categories\"],\"measureScale\":[1,\"measure-scale\"],\"showMeasureScale\":[1,\"show-measure-scale\"],\"showOverlayAvg\":[1,\"show-overlay-avg\"],\"showOverlayMedian\":[1,\"show-overlay-median\"],\"measureUnit\":[1,\"measure-unit\"],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"syncSpaceLeft\":[{\"validateLeftSync\":0}],\"limit\":[{\"validateLimit\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"level\":[{\"validateLevel\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"dateInterval\":[{\"validateDateInterval\":0}],\"chartMode\":[{\"validateChartMode\":0}],\"maxBars\":[{\"validateMaxBars\":0}],\"stack\":[{\"validateStack\":0}],\"scale\":[{\"validateScaling\":0}],\"axisLabelsMode\":[{\"validateAxisLabelsMode\":0}],\"lineFullWidth\":[{\"validateLineFullWidth\":0}],\"showCategories\":[{\"validateShowCategories\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"showOverlayAvg\":[{\"validateShowOverlayAvg\":0}],\"showOverlayMedian\":[{\"validateShowOverlayMedian\":0}]}]]],[\"bn-asset.cjs\",[[1,\"bn-asset\",{\"name\":[1]}]]],[\"bn-component-style.cjs\",[[0,\"bn-component-style\",{\"name\":[1]}]]],[\"bn-dataset.cjs\",[[0,\"bn-dataset\",{\"name\":[1],\"datasources\":[1],\"static\":[4]},null,{\"name\":[{\"nameUpdated\":0}]}]]],[\"bn-grid.cjs\",[[257,\"bn-grid\",{\"chartTitle\":[1,\"chart-title\"],\"rowHeaders\":[1,\"row-headers\"],\"columnHeaders\":[1,\"column-headers\"],\"showRowHeaders\":[1,\"show-row-headers\"],\"showColumnHeaders\":[1,\"show-column-headers\"],\"showBorders\":[1,\"show-borders\"],\"rowHeaderWidth\":[1,\"row-header-width\"],\"cellGap\":[1,\"cell-gap\"],\"gridConfig\":[32]},null,{\"rowHeaders\":[{\"validateRowHeaders\":0}],\"columnHeaders\":[{\"validateColumnHeaders\":0}],\"showRowHeaders\":[{\"validateShowRowHeaders\":0}],\"showColumnHeaders\":[{\"validateShowColumnHeaders\":0}],\"showBorders\":[{\"validateShowBorders\":0}]}]]],[\"bn-image.cjs\",[[1,\"bn-image\",{\"source\":[1]}]]],[\"bn-internationalization.cjs\",[[0,\"bn-internationalization\",{\"code\":[1],\"namespace\":[1]}]]],[\"bn-template.cjs\",[[257,\"bn-template\",{\"templateId\":[1,\"template-id\"]}]]],[\"bn-text.cjs\",[[1,\"bn-text\",{\"value\":[1],\"scale\":[1],\"data\":[32]},null,{\"value\":[{\"validateValue\":0}],\"scale\":[{\"validateScaling\":0}]}]]],[\"bn-tree.cjs\",[[257,\"bn-tree\",{\"edges\":[1],\"direction\":[1],\"levelSpacing\":[2,\"level-spacing\"],\"nodeSpacing\":[2,\"node-spacing\"],\"edgeStyle\":[1,\"edge-style\"],\"showOperators\":[1,\"show-operators\"],\"treeConfig\":[32],\"layout\":[32],\"nodeRects\":[32],\"svgWidth\":[32],\"svgHeight\":[32]},null,{\"edges\":[{\"validateEdgesProp\":0}],\"direction\":[{\"validateDirection\":0}],\"levelSpacing\":[{\"validateLevelSpacing\":0}],\"nodeSpacing\":[{\"validateNodeSpacing\":0}],\"edgeStyle\":[{\"validateEdgeStyle\":0}],\"showOperators\":[{\"validateShowOperators\":0}]}]]],[\"editor-companion.cjs\",[[0,\"editor-companion\",{\"internationalizationKeys\":[64],\"getDistinctFromDataSource\":[64],\"getDistinctFromDataset\":[64]}]]],[\"bn-card.cjs\",[[257,\"bn-card\"]]],[\"bn-message.cjs\",[[1,\"bn-message\",{\"text\":[1025],\"image\":[1]}]]],[\"ibcs-chart-structure.cjs\",[[1,\"ibcs-chart-structure\",{\"data\":[16],\"chartTitle\":[1,\"chart-title\"],\"scenarios\":[16],\"variances\":[16],\"hideCategories\":[4,\"hide-categories\"],\"pixelPerUnit\":[2,\"pixel-per-unit\"],\"pixelPerPercentage\":[2,\"pixel-per-percentage\"],\"limit\":[2],\"styles\":[1040],\"i18n\":[1040],\"order\":[16],\"level\":[1],\"filter\":[1],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"dataFormatDigits\":[16],\"stackConfig\":[16],\"parentDimensions\":[16]}]]],[\"ibcs-chart-time.cjs\",[[1,\"ibcs-chart-time\",{\"data\":[16],\"chartTitle\":[1,\"chart-title\"],\"scenarios\":[16],\"variances\":[16],\"hideAxisLabels\":[4,\"hide-axis-labels\"],\"pixelPerUnit\":[2,\"pixel-per-unit\"],\"pixelPerPercentage\":[2,\"pixel-per-percentage\"],\"limit\":[2],\"leftSideOffsetForHorizontalSync\":[2,\"left-side-offset-for-horizontal-sync\"],\"styles\":[1040],\"i18n\":[1040],\"order\":[16],\"level\":[1],\"dateInterval\":[1,\"date-interval\"],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"axisLabelsMode\":[1,\"axis-labels-mode\"],\"filter\":[1],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"showOverlayMedian\":[4,\"show-overlay-median\"],\"showOverlayAvg\":[4,\"show-overlay-avg\"],\"chartMode\":[1,\"chart-mode\"],\"maxBars\":[2,\"max-bars\"],\"stackConfig\":[16],\"lineFullWidth\":[4,\"line-full-width\"],\"containerWidth\":[2,\"container-width\"],\"dataFormatDigits\":[16],\"parentDimensions\":[16]}]]],[\"bn-context_5.cjs\",[[1,\"bn-table\",{\"scale\":[1],\"tableTitle\":[1,\"table-title\"],\"filter\":[1],\"measureUnit\":[1,\"measure-unit\"],\"scenarios\":[1],\"variances\":[1],\"barColumns\":[1,\"bar-columns\"],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"dataFormat\":[1,\"data-format\"],\"grouped\":[1],\"showMeasureScale\":[1,\"show-measure-scale\"],\"showGroupTitle\":[1,\"show-group-title\"],\"type\":[1],\"limit\":[2],\"thereof\":[1],\"partof\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"measureType\":[1,\"measure-type\"],\"measureScale\":[1,\"measure-scale\"],\"dataFormatDigitsDecimal\":[2,\"data-format-digits-decimal\"],\"dataFormatDigitsPercent\":[2,\"data-format-digits-percent\"],\"categoryWidth\":[1,\"category-width\"],\"columnthereof\":[1],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scale\":[{\"validateScaling\":0}],\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"barColumns\":[{\"validateBarColumns\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"dataFormat\":[{\"validateDataFormat\":0}],\"grouped\":[{\"validateGrouped\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"showGroupTitle\":[{\"validateShowGroupTitle\":0}],\"type\":[{\"validateType\":0}],\"limit\":[{\"validateLimit\":0}],\"thereof\":[{\"validateThereOf\":0}],\"partof\":[{\"validatePartOf\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"measureType\":[{\"validateMeasureType\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"dataFormatDigitsDecimal\":[{\"validateDataFormatDigitsDecimal\":0}],\"dataFormatDigitsPercent\":[{\"validateDateFormatDigitsPercent\":0}],\"categoryWidth\":[{\"validateCategoryWidth\":0}],\"columnthereof\":[{\"validateColumnThereOf\":0}]}],[257,\"bn-context\",{\"locale\":[1]},null,{\"locale\":[{\"setLocale\":0}]}],[0,\"bn-datasource\",{\"name\":[1]}],[257,\"bn-page\",{\"format\":[1],\"orientation\":[1]},null,{\"format\":[{\"validateFormat\":0}],\"orientation\":[{\"validateOrientation\":0}]}],[1,\"ibcs-table\",{\"data\":[16],\"tableTitle\":[1,\"table-title\"],\"scenarios\":[16],\"scenariosDataFormat\":[1,\"scenarios-data-format\"],\"grouped\":[4],\"limit\":[2],\"showGroupTitle\":[4,\"show-group-title\"],\"thereof\":[16],\"partof\":[16],\"order\":[16],\"categorythereof\":[16],\"type\":[1],\"categoryWidth\":[1,\"category-width\"],\"dataFormatDigits\":[16],\"i18n\":[1040],\"i18nMode\":[1,\"i18n-mode\"],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"measureType\":[1,\"measure-type\"],\"filter\":[1],\"barColumns\":[16],\"unitScaling\":[2,\"unit-scaling\"],\"percentageScaling\":[2,\"percentage-scaling\"],\"scaleFactor\":[2,\"scale-factor\"]}]]],[\"bn-body_4.cjs\",[[1,\"bn-title\",{\"businessUnit\":[1,\"business-unit\"],\"scenarios\":[1],\"variances\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"measures\":[1],\"dateStart\":[1,\"date-start\"],\"dateEnd\":[1,\"date-end\"],\"dateFormat\":[1,\"date-format\"],\"dateLink\":[1,\"date-link\"]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"order\":[{\"validateOrder\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"measures\":[{\"validateMeasures\":0}],\"dateStart\":[{\"validateDateStart\":0}],\"dateEnd\":[{\"validateDateEnd\":0}],\"dateFormat\":[{\"validateDateFormat\":0}],\"dateLink\":[{\"validateDateLink\":0}]}],[257,\"bn-body\"],[1,\"bn-footer\",{\"pageNumber\":[1026,\"page-number\"],\"text\":[1025],\"code\":[1025],\"displayPageNumber\":[4,\"display-page-number\"]}],[1,\"ibcs-title\",{\"businessUnit\":[1537,\"business-unit\"],\"scenarios\":[16],\"measures\":[16],\"timeperiod\":[16],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"order\":[16],\"i18n\":[1040],\"i18nMode\":[1,\"i18n-mode\"],\"setBusinessUnit\":[64],\"setProps\":[64]}]]]]"), options);
|
|
9
|
+
return index.bootstrapLazy(JSON.parse("[[\"bn-layout-page.cjs\",[[257,\"bn-layout-page\",{\"styles\":[1],\"messageText\":[1,\"message-text\"],\"messageImage\":[1,\"message-image\"],\"titleBusinessUnit\":[1,\"title-business-unit\"],\"titleScenarios\":[1,\"title-scenarios\"],\"titleVariances\":[1,\"title-variances\"],\"titleOrder\":[1,\"title-order\"],\"titleOrderDirection\":[1,\"title-order-direction\"],\"titleMeasures\":[1,\"title-measures\"],\"titleDateStart\":[1,\"title-date-start\"],\"titleDateEnd\":[1,\"title-date-end\"],\"titleDateFormat\":[1,\"title-date-format\"],\"titleDateLink\":[1,\"title-date-link\"],\"titleNamespace\":[1,\"title-namespace\"],\"pageFormat\":[1,\"page-format\"],\"pageOrientation\":[1,\"page-orientation\"],\"pageNumber\":[1,\"page-number\"],\"footerText\":[1,\"footer-text\"],\"footerDisplayPageNumber\":[4,\"footer-display-page-number\"],\"pageLayout\":[1,\"page-layout\"],\"pageCustomTemplate\":[1,\"page-custom-template\"],\"pageGridGap\":[1,\"page-grid-gap\"],\"pageFitToContent\":[4,\"page-fit-to-content\"],\"getNumberOfSlot\":[64]}]]],[\"bn-layout-card.cjs\",[[257,\"bn-layout-card\",{\"styles\":[1],\"titleImage\":[1,\"title-image\"],\"titleBusinessUnit\":[1,\"title-business-unit\"],\"titleScenarios\":[1,\"title-scenarios\"],\"titleVariances\":[1,\"title-variances\"],\"titleOrder\":[1,\"title-order\"],\"titleOrderDirection\":[1,\"title-order-direction\"],\"titleMeasures\":[1,\"title-measures\"],\"titleDateStart\":[1,\"title-date-start\"],\"titleDateEnd\":[1,\"title-date-end\"],\"titleDateFormat\":[1,\"title-date-format\"],\"titleDateLink\":[1,\"title-date-link\"],\"titleNamespace\":[1,\"title-namespace\"],\"footerText\":[1,\"footer-text\"],\"cardLayout\":[1,\"card-layout\"],\"cardCustomTemplate\":[1,\"card-custom-template\"],\"cardGridGap\":[1,\"card-grid-gap\"],\"cardFitToContent\":[4,\"card-fit-to-content\"],\"cardShowBorder\":[4,\"card-show-border\"],\"getNumberOfSlot\":[64]}]]],[\"bn-chart-structure.cjs\",[[1,\"bn-chart-structure\",{\"chartTitle\":[1,\"chart-title\"],\"filter\":[1],\"scenarios\":[1],\"variances\":[1],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"level\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"limit\":[2],\"showCategories\":[1,\"show-categories\"],\"measureScale\":[1,\"measure-scale\"],\"showMeasureScale\":[1,\"show-measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"stack\":[1],\"scale\":[1],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"level\":[{\"validateLevel\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"limit\":[{\"validateLimit\":0}],\"showCategories\":[{\"validateShowCategories\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"stack\":[{\"validateStack\":0}],\"scale\":[{\"validateScaling\":0}]}]]],[\"bn-chart-time.cjs\",[[1,\"bn-chart-time\",{\"chartTitle\":[1,\"chart-title\"],\"filter\":[1],\"scenarios\":[1],\"variances\":[1],\"syncSpaceLeft\":[2,\"sync-space-left\"],\"limit\":[2],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"level\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"dateInterval\":[1,\"date-interval\"],\"chartMode\":[1,\"chart-mode\"],\"maxBars\":[2,\"max-bars\"],\"stack\":[1],\"scale\":[1],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"axisLabelsMode\":[1,\"axis-labels-mode\"],\"lineFullWidth\":[1,\"line-full-width\"],\"showCategories\":[1,\"show-categories\"],\"measureScale\":[1,\"measure-scale\"],\"showMeasureScale\":[1,\"show-measure-scale\"],\"showOverlayAvg\":[1,\"show-overlay-avg\"],\"showOverlayMedian\":[1,\"show-overlay-median\"],\"measureUnit\":[1,\"measure-unit\"],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"syncSpaceLeft\":[{\"validateLeftSync\":0}],\"limit\":[{\"validateLimit\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"level\":[{\"validateLevel\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"dateInterval\":[{\"validateDateInterval\":0}],\"chartMode\":[{\"validateChartMode\":0}],\"maxBars\":[{\"validateMaxBars\":0}],\"stack\":[{\"validateStack\":0}],\"scale\":[{\"validateScaling\":0}],\"axisLabelsMode\":[{\"validateAxisLabelsMode\":0}],\"lineFullWidth\":[{\"validateLineFullWidth\":0}],\"showCategories\":[{\"validateShowCategories\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"showOverlayAvg\":[{\"validateShowOverlayAvg\":0}],\"showOverlayMedian\":[{\"validateShowOverlayMedian\":0}]}]]],[\"bn-asset.cjs\",[[1,\"bn-asset\",{\"name\":[1]}]]],[\"bn-component-style.cjs\",[[0,\"bn-component-style\",{\"name\":[1]}]]],[\"bn-dataset.cjs\",[[0,\"bn-dataset\",{\"name\":[1],\"datasources\":[1],\"static\":[4]},null,{\"name\":[{\"nameUpdated\":0}]}]]],[\"bn-grid.cjs\",[[257,\"bn-grid\",{\"chartTitle\":[1,\"chart-title\"],\"rowHeaders\":[1,\"row-headers\"],\"columnHeaders\":[1,\"column-headers\"],\"showRowHeaders\":[1,\"show-row-headers\"],\"showColumnHeaders\":[1,\"show-column-headers\"],\"showBorders\":[1,\"show-borders\"],\"rowHeaderWidth\":[1,\"row-header-width\"],\"cellGap\":[1,\"cell-gap\"],\"gridConfig\":[32]},null,{\"rowHeaders\":[{\"validateRowHeaders\":0}],\"columnHeaders\":[{\"validateColumnHeaders\":0}],\"showRowHeaders\":[{\"validateShowRowHeaders\":0}],\"showColumnHeaders\":[{\"validateShowColumnHeaders\":0}],\"showBorders\":[{\"validateShowBorders\":0}]}]]],[\"bn-image.cjs\",[[1,\"bn-image\",{\"source\":[1]}]]],[\"bn-internationalization.cjs\",[[0,\"bn-internationalization\",{\"code\":[1],\"namespace\":[1]}]]],[\"bn-template.cjs\",[[257,\"bn-template\",{\"templateId\":[1,\"template-id\"]}]]],[\"bn-text.cjs\",[[1,\"bn-text\",{\"value\":[1],\"scale\":[1],\"data\":[32]},null,{\"value\":[{\"validateValue\":0}],\"scale\":[{\"validateScaling\":0}]}]]],[\"bn-tree.cjs\",[[257,\"bn-tree\",{\"edges\":[1],\"direction\":[1],\"levelSpacing\":[2,\"level-spacing\"],\"nodeSpacing\":[2,\"node-spacing\"],\"edgeStyle\":[1,\"edge-style\"],\"showOperators\":[1,\"show-operators\"],\"treeConfig\":[32],\"layout\":[32],\"nodeRects\":[32],\"svgWidth\":[32],\"svgHeight\":[32]},null,{\"edges\":[{\"validateEdgesProp\":0}],\"direction\":[{\"validateDirection\":0}],\"levelSpacing\":[{\"validateLevelSpacing\":0}],\"nodeSpacing\":[{\"validateNodeSpacing\":0}],\"edgeStyle\":[{\"validateEdgeStyle\":0}],\"showOperators\":[{\"validateShowOperators\":0}]}]]],[\"editor-companion.cjs\",[[0,\"editor-companion\",{\"internationalizationKeys\":[64],\"getDistinctFromDataSource\":[64],\"getDistinctFromDataset\":[64]}]]],[\"bn-card.cjs\",[[257,\"bn-card\"]]],[\"bn-message.cjs\",[[1,\"bn-message\",{\"text\":[1025],\"image\":[1]}]]],[\"ibcs-chart-structure.cjs\",[[1,\"ibcs-chart-structure\",{\"data\":[16],\"chartTitle\":[1,\"chart-title\"],\"scenarios\":[16],\"variances\":[16],\"hideCategories\":[4,\"hide-categories\"],\"pixelPerUnit\":[2,\"pixel-per-unit\"],\"pixelPerPercentage\":[2,\"pixel-per-percentage\"],\"limit\":[2],\"styles\":[1040],\"i18n\":[1040],\"order\":[16],\"level\":[1],\"filter\":[1],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"dataFormatDigits\":[16],\"stackConfig\":[16],\"parentDimensions\":[16]}]]],[\"ibcs-chart-time.cjs\",[[1,\"ibcs-chart-time\",{\"data\":[16],\"chartTitle\":[1,\"chart-title\"],\"scenarios\":[16],\"variances\":[16],\"hideAxisLabels\":[4,\"hide-axis-labels\"],\"pixelPerUnit\":[2,\"pixel-per-unit\"],\"pixelPerPercentage\":[2,\"pixel-per-percentage\"],\"limit\":[2],\"leftSideOffsetForHorizontalSync\":[2,\"left-side-offset-for-horizontal-sync\"],\"styles\":[1040],\"i18n\":[1040],\"order\":[16],\"level\":[1],\"dateInterval\":[1,\"date-interval\"],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"axisLabelsMode\":[1,\"axis-labels-mode\"],\"filter\":[1],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"showOverlayMedian\":[4,\"show-overlay-median\"],\"showOverlayAvg\":[4,\"show-overlay-avg\"],\"chartMode\":[1,\"chart-mode\"],\"maxBars\":[2,\"max-bars\"],\"stackConfig\":[16],\"lineFullWidth\":[4,\"line-full-width\"],\"containerWidth\":[2,\"container-width\"],\"dataFormatDigits\":[16],\"parentDimensions\":[16]}]]],[\"bn-context_5.cjs\",[[1,\"bn-table\",{\"scale\":[1],\"tableTitle\":[1,\"table-title\"],\"filter\":[1],\"measureUnit\":[1,\"measure-unit\"],\"scenarios\":[1],\"variances\":[1],\"barColumns\":[1,\"bar-columns\"],\"barColumnWidth\":[1,\"bar-column-width\"],\"unitScaling\":[8,\"unit-scaling\"],\"percentageScaling\":[8,\"percentage-scaling\"],\"dataFormat\":[1,\"data-format\"],\"grouped\":[1],\"showMeasureScale\":[1,\"show-measure-scale\"],\"showGroupTitle\":[1,\"show-group-title\"],\"type\":[1],\"limit\":[2],\"thereof\":[1],\"partof\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"measureType\":[1,\"measure-type\"],\"measureScale\":[1,\"measure-scale\"],\"dataFormatDigitsDecimal\":[2,\"data-format-digits-decimal\"],\"dataFormatDigitsPercent\":[2,\"data-format-digits-percent\"],\"categoryWidth\":[1,\"category-width\"],\"columnthereof\":[1],\"data\":[32],\"datasetMeta\":[32],\"appliedScaleFactor\":[32]},null,{\"scale\":[{\"validateScaling\":0}],\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"barColumns\":[{\"validateBarColumns\":0}],\"barColumnWidth\":[{\"validateBarColumnWidth\":0}],\"unitScaling\":[{\"validateUnitScaling\":0}],\"percentageScaling\":[{\"validatePercentageScaling\":0}],\"dataFormat\":[{\"validateDataFormat\":0}],\"grouped\":[{\"validateGrouped\":0}],\"showMeasureScale\":[{\"validateShowMeasureScale\":0}],\"showGroupTitle\":[{\"validateShowGroupTitle\":0}],\"type\":[{\"validateType\":0}],\"limit\":[{\"validateLimit\":0}],\"thereof\":[{\"validateThereOf\":0}],\"partof\":[{\"validatePartOf\":0}],\"order\":[{\"validateOrderList\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"measureType\":[{\"validateMeasureType\":0}],\"measureScale\":[{\"validateMeasureScale\":0}],\"dataFormatDigitsDecimal\":[{\"validateDataFormatDigitsDecimal\":0}],\"dataFormatDigitsPercent\":[{\"validateDateFormatDigitsPercent\":0}],\"categoryWidth\":[{\"validateCategoryWidth\":0}],\"columnthereof\":[{\"validateColumnThereOf\":0}]}],[257,\"bn-context\",{\"locale\":[1]},null,{\"locale\":[{\"setLocale\":0}]}],[0,\"bn-datasource\",{\"name\":[1]}],[257,\"bn-page\",{\"format\":[1],\"orientation\":[1]},null,{\"format\":[{\"validateFormat\":0}],\"orientation\":[{\"validateOrientation\":0}]}],[1,\"ibcs-table\",{\"data\":[16],\"tableTitle\":[1,\"table-title\"],\"scenarios\":[16],\"scenariosDataFormat\":[1,\"scenarios-data-format\"],\"grouped\":[4],\"limit\":[2],\"showGroupTitle\":[4,\"show-group-title\"],\"thereof\":[16],\"partof\":[16],\"order\":[16],\"categorythereof\":[16],\"type\":[1],\"categoryWidth\":[1,\"category-width\"],\"dataFormatDigits\":[16],\"i18n\":[1040],\"i18nMode\":[1,\"i18n-mode\"],\"measureScale\":[1,\"measure-scale\"],\"measureUnit\":[1,\"measure-unit\"],\"showMeasureScale\":[4,\"show-measure-scale\"],\"measureType\":[1,\"measure-type\"],\"filter\":[1],\"barColumns\":[16],\"barColumnMaxWidth\":[2,\"bar-column-max-width\"],\"unitScaling\":[2,\"unit-scaling\"],\"percentageScaling\":[2,\"percentage-scaling\"],\"scaleFactor\":[2,\"scale-factor\"]}]]],[\"bn-body_4.cjs\",[[1,\"bn-title\",{\"businessUnit\":[1,\"business-unit\"],\"scenarios\":[1],\"variances\":[1],\"order\":[1],\"orderDirection\":[1,\"order-direction\"],\"measures\":[1],\"dateStart\":[1,\"date-start\"],\"dateEnd\":[1,\"date-end\"],\"dateFormat\":[1,\"date-format\"],\"dateLink\":[1,\"date-link\"]},null,{\"scenarios\":[{\"validateScenario\":0}],\"variances\":[{\"validateVariances\":0}],\"order\":[{\"validateOrder\":0}],\"orderDirection\":[{\"validateOrderDirection\":0}],\"measures\":[{\"validateMeasures\":0}],\"dateStart\":[{\"validateDateStart\":0}],\"dateEnd\":[{\"validateDateEnd\":0}],\"dateFormat\":[{\"validateDateFormat\":0}],\"dateLink\":[{\"validateDateLink\":0}]}],[257,\"bn-body\"],[1,\"bn-footer\",{\"pageNumber\":[1026,\"page-number\"],\"text\":[1025],\"code\":[1025],\"displayPageNumber\":[4,\"display-page-number\"]}],[1,\"ibcs-title\",{\"businessUnit\":[1537,\"business-unit\"],\"scenarios\":[16],\"measures\":[16],\"timeperiod\":[16],\"intervalSpanLimit\":[2,\"interval-span-limit\"],\"order\":[16],\"i18n\":[1040],\"i18nMode\":[1,\"i18n-mode\"],\"setBusinessUnit\":[64],\"setProps\":[64]}]]]]"), options);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
exports.setNonce = index.setNonce;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Order = require('./Order-
|
|
4
|
-
var DateStringFactory = require('./DateStringFactory-
|
|
3
|
+
var Order = require('./Order-BKoDS21t.js');
|
|
4
|
+
var DateStringFactory = require('./DateStringFactory-CcluhpGI.js');
|
|
5
5
|
var index = require('./index-Cjw0q6gP.js');
|
|
6
6
|
var withHasError = require('./withHasError-B8gHkfV2.js');
|
|
7
7
|
|
|
@@ -188,6 +188,9 @@ function isValidMeasureScale(value) {
|
|
|
188
188
|
function isTableCategoryWidth(value) {
|
|
189
189
|
return (value === null || value === void 0 ? void 0 : value.toUpperCase().trim()) in Order.TableCategoryWidth;
|
|
190
190
|
}
|
|
191
|
+
function isTableBarColumnWidth(value) {
|
|
192
|
+
return (value === null || value === void 0 ? void 0 : value.toUpperCase().trim()) in Order.TableBarColumnWidth;
|
|
193
|
+
}
|
|
191
194
|
function validateColumnThereOfJsonStr(value) {
|
|
192
195
|
if (isBlankInput(value)) {
|
|
193
196
|
return [];
|
|
@@ -493,6 +496,7 @@ const withStyled = (component) => {
|
|
|
493
496
|
};
|
|
494
497
|
|
|
495
498
|
exports.isBlankInput = isBlankInput;
|
|
499
|
+
exports.isTableBarColumnWidth = isTableBarColumnWidth;
|
|
496
500
|
exports.isTableCategoryWidth = isTableCategoryWidth;
|
|
497
501
|
exports.isValidAxisLabelsMode = isValidAxisLabelsMode;
|
|
498
502
|
exports.isValidBoolean = isValidBoolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
|
-
import { isBlankInput, isTableCategoryWidth, isValidBoolean, isValidDataFormat, isValidDirection, isValidInteger, isValidMeasureScale, isValidMeasureType, isValidNumber, isValidTableType, validateColumnThereOfJsonStr, validateOrderList, validatePartOfJsonStr, validateScenarioList, validateThereOfJsonStr, validateVariancesList, } from "../../utils/validate";
|
|
2
|
+
import { isBlankInput, isTableBarColumnWidth, isTableCategoryWidth, isValidBoolean, isValidDataFormat, isValidDirection, isValidInteger, isValidMeasureScale, isValidMeasureType, isValidNumber, isValidTableType, validateColumnThereOfJsonStr, validateOrderList, validatePartOfJsonStr, validateScenarioList, validateThereOfJsonStr, validateVariancesList, } from "../../utils/validate";
|
|
3
3
|
import withDataset from "../../utils/withDataset";
|
|
4
4
|
import withComponentStatus from "../../utils/withComponentStatus";
|
|
5
5
|
import { globalLabelKeys } from "../../stores/internationalization";
|
|
@@ -9,7 +9,7 @@ import withComponentStyle from "../../utils/withComponentStyle";
|
|
|
9
9
|
import withHasError from "../../utils/withHasError";
|
|
10
10
|
import { getParentDimensions } from "../../utils/parentDimensions";
|
|
11
11
|
import { parseScaling } from "../../utils/scaling";
|
|
12
|
-
import { DataFormat, I18nMode, MeasureType, TableCategoryWidth } from "../../utils/constants";
|
|
12
|
+
import { BAR_COLUMN_WIDTH_EM, DataFormat, I18nMode, MeasureType, TableBarColumnWidth, TableCategoryWidth, } from "../../utils/constants";
|
|
13
13
|
import { TableType } from "./utils/model";
|
|
14
14
|
import { OrderColumn, OrderDirection } from "../../utils/model/Order";
|
|
15
15
|
/**
|
|
@@ -57,14 +57,16 @@ export class Table {
|
|
|
57
57
|
*/
|
|
58
58
|
this.measureUnit = "";
|
|
59
59
|
/**
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
|
|
65
|
-
|
|
60
|
+
* Set width of bar chart columns. Controls the max bar/pin width in pixels.
|
|
61
|
+
* <br /><br />
|
|
62
|
+
* values:<br />
|
|
63
|
+
* ``` w5 // w10 // w15 // w20 // w25 // w30 // w40 // w60 // w80 // w100 ```
|
|
64
|
+
*/
|
|
65
|
+
this.barColumnWidth = "w30";
|
|
66
|
+
/**
|
|
67
|
+
* @deprecated Bars now scale proportionally via column statistics. Kept for backward compatibility.
|
|
66
68
|
* <br /><br />
|
|
67
|
-
*
|
|
69
|
+
* Scaling for absolute variance bar charts (ΔPY).
|
|
68
70
|
* <br /><br />
|
|
69
71
|
* Default: 0.01
|
|
70
72
|
*/
|
|
@@ -312,6 +314,19 @@ export class Table {
|
|
|
312
314
|
this.errors.remove(errId);
|
|
313
315
|
}
|
|
314
316
|
}
|
|
317
|
+
validateBarColumnWidth(newValue) {
|
|
318
|
+
const errId = "ERR_barColumnWidth";
|
|
319
|
+
if (!isTableBarColumnWidth(newValue)) {
|
|
320
|
+
this.errors.addOrReplace({
|
|
321
|
+
id: errId,
|
|
322
|
+
type: "warning",
|
|
323
|
+
message: "barColumnWidth: invalid value '" + newValue + "' is not supported.",
|
|
324
|
+
});
|
|
325
|
+
}
|
|
326
|
+
else {
|
|
327
|
+
this.errors.remove(errId);
|
|
328
|
+
}
|
|
329
|
+
}
|
|
315
330
|
validateUnitScaling(newValue) {
|
|
316
331
|
const errId = "ERR_unitScaling";
|
|
317
332
|
if (!isValidNumber(newValue) && !this.pixelPerUnitGroupMap.has(newValue)) {
|
|
@@ -572,6 +587,7 @@ export class Table {
|
|
|
572
587
|
this.validateColumnThereOf(this.columnthereof);
|
|
573
588
|
this.validateShowMeasureScale(this.showMeasureScale);
|
|
574
589
|
this.validateBarColumns(this.barColumns);
|
|
590
|
+
this.validateBarColumnWidth(this.barColumnWidth);
|
|
575
591
|
this.validateUnitScaling(this.unitScaling);
|
|
576
592
|
this.validatePercentageScaling(this.percentageScaling);
|
|
577
593
|
this.validateScaling(this.scale);
|
|
@@ -799,6 +815,15 @@ export class Table {
|
|
|
799
815
|
}
|
|
800
816
|
return this.filter;
|
|
801
817
|
}
|
|
818
|
+
prepareBarColumnWidth() {
|
|
819
|
+
var _a;
|
|
820
|
+
const key = (_a = this.barColumnWidth) === null || _a === void 0 ? void 0 : _a.toUpperCase();
|
|
821
|
+
const preset = TableBarColumnWidth[key];
|
|
822
|
+
if (preset) {
|
|
823
|
+
return BAR_COLUMN_WIDTH_EM[preset];
|
|
824
|
+
}
|
|
825
|
+
return BAR_COLUMN_WIDTH_EM[TableBarColumnWidth.W30];
|
|
826
|
+
}
|
|
802
827
|
prepareBarColumns() {
|
|
803
828
|
if (isBlankInput(this.barColumns)) {
|
|
804
829
|
return [];
|
|
@@ -878,7 +903,7 @@ export class Table {
|
|
|
878
903
|
render() {
|
|
879
904
|
const fontStyles = this.getFontStyles();
|
|
880
905
|
const effectiveFactor = this.getEffectiveScaleFactor();
|
|
881
|
-
return (h(Host, { key: '
|
|
906
|
+
return (h(Host, { key: 'b379c18d4d92805e91404917ffb096e582b9bec2', style: fontStyles }, h("div", { key: 'a45679a84d85b856f0e01615952c0ccfe05108f9' }, h("ibcs-table", { key: '0b375fca9ab9422bc61a4d0ba75eaf30eedfa77d', data: this.data, "table-title": this.prepareTableTitle(), scenarios: this.prepareScenarios(), "scenarios-data-format": this.prepareDataFormat(), grouped: this.prepareGrouped(), limit: this.prepareLimit(), showGroupTitle: this.prepareShowGroupTitle(), thereof: this.prepareThereOf(), partof: this.preparePartOf(), order: this.prepareOrder(), categorythereof: this.prepareColumnThereOf(), type: this.prepareTableType(), "category-width": this.prepareCategoryWidth(), dataFormatDigits: this.prepareDataFormatDigits(), i18n: this.prepareI18n(), "i18n-mode": this.prepareI18nMode(), "measure-scale": this.prepareMeasureScale(), "measure-type": this.prepareMeasureType(), "measure-unit": this.prepareMeasureUnit(), showMeasureScale: this.prepareShowMeasureScale(), filter: this.prepareFilter(), barColumns: this.prepareBarColumns(), barColumnMaxWidth: this.prepareBarColumnWidth(), unitScaling: this.prepareUnitScaling(), percentageScaling: this.preparePercentageScaling(), scaleFactor: effectiveFactor }))));
|
|
882
907
|
}
|
|
883
908
|
static get is() { return "bn-table"; }
|
|
884
909
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1033,6 +1058,26 @@ export class Table {
|
|
|
1033
1058
|
"reflect": false,
|
|
1034
1059
|
"attribute": "bar-columns"
|
|
1035
1060
|
},
|
|
1061
|
+
"barColumnWidth": {
|
|
1062
|
+
"type": "string",
|
|
1063
|
+
"mutable": false,
|
|
1064
|
+
"complexType": {
|
|
1065
|
+
"original": "string",
|
|
1066
|
+
"resolved": "string",
|
|
1067
|
+
"references": {}
|
|
1068
|
+
},
|
|
1069
|
+
"required": false,
|
|
1070
|
+
"optional": false,
|
|
1071
|
+
"docs": {
|
|
1072
|
+
"tags": [],
|
|
1073
|
+
"text": "Set width of bar chart columns. Controls the max bar/pin width in pixels.\n<br /><br />\nvalues:<br />\n``` w5 // w10 // w15 // w20 // w25 // w30 // w40 // w60 // w80 // w100 ```"
|
|
1074
|
+
},
|
|
1075
|
+
"getter": false,
|
|
1076
|
+
"setter": false,
|
|
1077
|
+
"reflect": false,
|
|
1078
|
+
"attribute": "bar-column-width",
|
|
1079
|
+
"defaultValue": "\"w30\""
|
|
1080
|
+
},
|
|
1036
1081
|
"unitScaling": {
|
|
1037
1082
|
"type": "any",
|
|
1038
1083
|
"mutable": false,
|
|
@@ -1044,8 +1089,11 @@ export class Table {
|
|
|
1044
1089
|
"required": false,
|
|
1045
1090
|
"optional": false,
|
|
1046
1091
|
"docs": {
|
|
1047
|
-
"tags": [
|
|
1048
|
-
|
|
1092
|
+
"tags": [{
|
|
1093
|
+
"name": "deprecated",
|
|
1094
|
+
"text": "Bars now scale proportionally via column statistics. Kept for backward compatibility.\n<br /><br />\nScaling for absolute variance bar charts (\u0394PY).\n<br /><br />\nDefault: 0.01"
|
|
1095
|
+
}],
|
|
1096
|
+
"text": ""
|
|
1049
1097
|
},
|
|
1050
1098
|
"getter": false,
|
|
1051
1099
|
"setter": false,
|
|
@@ -1416,6 +1464,9 @@ export class Table {
|
|
|
1416
1464
|
}, {
|
|
1417
1465
|
"propName": "barColumns",
|
|
1418
1466
|
"methodName": "validateBarColumns"
|
|
1467
|
+
}, {
|
|
1468
|
+
"propName": "barColumnWidth",
|
|
1469
|
+
"methodName": "validateBarColumnWidth"
|
|
1419
1470
|
}, {
|
|
1420
1471
|
"propName": "unitScaling",
|
|
1421
1472
|
"methodName": "validateUnitScaling"
|
|
@@ -47,35 +47,38 @@ td.neg_neutral {
|
|
|
47
47
|
text-align: right;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
.category-inf {
|
|
51
|
-
max-width: 1000em;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
50
|
.category-w100 {
|
|
51
|
+
min-width: 100em;
|
|
55
52
|
max-width: 100em;
|
|
56
53
|
}
|
|
57
54
|
|
|
58
55
|
.category-w50 {
|
|
56
|
+
min-width: 50em;
|
|
59
57
|
max-width: 50em;
|
|
60
58
|
}
|
|
61
59
|
|
|
62
60
|
.category-w25 {
|
|
61
|
+
min-width: 25em;
|
|
63
62
|
max-width: 25em;
|
|
64
63
|
}
|
|
65
64
|
|
|
66
65
|
.category-w20 {
|
|
66
|
+
min-width: 20em;
|
|
67
67
|
max-width: 20em;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
.category-w15 {
|
|
71
|
+
min-width: 15em;
|
|
71
72
|
max-width: 15em;
|
|
72
73
|
}
|
|
73
74
|
|
|
74
75
|
.category-w10 {
|
|
76
|
+
min-width: 10em;
|
|
75
77
|
max-width: 10em;
|
|
76
78
|
}
|
|
77
79
|
|
|
78
80
|
.category-w5 {
|
|
81
|
+
min-width: 5em;
|
|
79
82
|
max-width: 5em;
|
|
80
83
|
}
|
|
81
84
|
|
|
@@ -287,7 +290,6 @@ td {
|
|
|
287
290
|
-webkit-box-sizing: border-box;
|
|
288
291
|
border-top: 0.1em dashed #ddd;
|
|
289
292
|
padding-left: 0.5em;
|
|
290
|
-
max-width: 15em;
|
|
291
293
|
white-space: nowrap;
|
|
292
294
|
overflow: hidden;
|
|
293
295
|
text-overflow: ellipsis;
|
|
@@ -48,6 +48,7 @@ export class IbcsTable {
|
|
|
48
48
|
this.measureType = MeasureType.VOLUME;
|
|
49
49
|
this.filter = "";
|
|
50
50
|
this.barColumns = [];
|
|
51
|
+
this.barColumnMaxWidth = 30;
|
|
51
52
|
this.unitScaling = 0.01;
|
|
52
53
|
this.percentageScaling = 0.5;
|
|
53
54
|
this.scaleFactor = 1;
|
|
@@ -63,7 +64,7 @@ export class IbcsTable {
|
|
|
63
64
|
const errorMsg = this.i18n.get("NO_DATA") || "==No Data==";
|
|
64
65
|
return h("p", { class: "warning" }, errorMsg);
|
|
65
66
|
}
|
|
66
|
-
return (h("table", null, h("thead", null, this.table.getHeader().map((row) => (h("tr", { class: row.cssStyle }, row.getCells().map((cell) => (h("th", { colSpan: cell.colSpan, class: cell.cssStyle }, cell.getAsHeaderList().map((line, i, arr) => (h("span", null, i === arr.length - 1 ? (h("span", { class: line === " " ? "table-footer" : "" }, line, cell.drawPrefix(), " ")) : (h("span", null, line, cell.drawPrefix(), h("br", null))))))))))))), h("tbody", null, this.table.getBody().map((row) => (h("tr", { class: row.cssStyle }, row === null || row === void 0 ? void 0 : row.getCells().map((cell) => (h("td", { colSpan: cell.colSpan, class: cell.
|
|
67
|
+
return (h("table", null, h("thead", null, this.table.getHeader().map((row) => (h("tr", { class: row.cssStyle }, row.getCells().map((cell) => (h("th", { colSpan: cell.colSpan, class: cell.cssStyle }, cell.getAsHeaderList().map((line, i, arr) => (h("span", null, i === arr.length - 1 ? (h("span", { class: line === " " ? "table-footer" : "" }, line, cell.drawPrefix(), " ")) : (h("span", null, line, cell.drawPrefix(), h("br", null))))))))))))), h("tbody", null, this.table.getBody().map((row) => (h("tr", { class: row.cssStyle }, row === null || row === void 0 ? void 0 : row.getCells().map((cell) => (h("td", { colSpan: cell.colSpan, class: cell.type ? `${cell.cssStyle} ${cell.type}` : cell.cssStyle }, cell.prefix != null ? (h("span", { class: cell.cssStyle + " " + cell.prefixStyle }, cell.drawPrefix())) : (""), cell.isBarChart && cell.columnStats ? (h(CellBarChart, { value: cell.value, scenario: cell.key, columnStats: cell.columnStats, height: 18 * this.scaleFactor, isRelative: cell.key.startsWith("dr"), isPositiveGood: cell.key.endsWith("_pos"), measureScale: cell.measureScale, maxBarWidth: this.barColumnMaxWidth, styles: this.barChartStyles })) : (cell.draw(this.componentDataFormatDigits)))))))))));
|
|
67
68
|
};
|
|
68
69
|
return h(Host, null, helper());
|
|
69
70
|
}
|
|
@@ -691,6 +692,26 @@ export class IbcsTable {
|
|
|
691
692
|
"setter": false,
|
|
692
693
|
"defaultValue": "[]"
|
|
693
694
|
},
|
|
695
|
+
"barColumnMaxWidth": {
|
|
696
|
+
"type": "number",
|
|
697
|
+
"mutable": false,
|
|
698
|
+
"complexType": {
|
|
699
|
+
"original": "number",
|
|
700
|
+
"resolved": "number",
|
|
701
|
+
"references": {}
|
|
702
|
+
},
|
|
703
|
+
"required": false,
|
|
704
|
+
"optional": false,
|
|
705
|
+
"docs": {
|
|
706
|
+
"tags": [],
|
|
707
|
+
"text": ""
|
|
708
|
+
},
|
|
709
|
+
"getter": false,
|
|
710
|
+
"setter": false,
|
|
711
|
+
"reflect": false,
|
|
712
|
+
"attribute": "bar-column-max-width",
|
|
713
|
+
"defaultValue": "30"
|
|
714
|
+
},
|
|
694
715
|
"unitScaling": {
|
|
695
716
|
"type": "number",
|
|
696
717
|
"mutable": false,
|
|
@@ -150,28 +150,52 @@ function getBarStroke(varianceStyle) {
|
|
|
150
150
|
// Solid and hatched bars don't need visible stroke
|
|
151
151
|
return { stroke: "none", strokeWidth: 0 };
|
|
152
152
|
}
|
|
153
|
+
/**
|
|
154
|
+
* Computes an effective max for proportional scaling that keeps most bars readable.
|
|
155
|
+
* If a few outliers (extreme values) dominate, the effective max is capped so the
|
|
156
|
+
* majority of bars remain at a useful size. Values exceeding the effective max are
|
|
157
|
+
* flagged as "extreme" and rendered with an arrow indicator.
|
|
158
|
+
*
|
|
159
|
+
* Algorithm: effectiveMax = median * EXTREME_THRESHOLD (default 3×).
|
|
160
|
+
* If this would be less than absMax, some values are extreme.
|
|
161
|
+
* If the median is 0 (e.g. single value), falls back to absMax.
|
|
162
|
+
*/
|
|
163
|
+
const EXTREME_THRESHOLD = 3;
|
|
164
|
+
function computeEffectiveMax(columnStats) {
|
|
165
|
+
if (columnStats.median <= 0) {
|
|
166
|
+
return columnStats.absMax;
|
|
167
|
+
}
|
|
168
|
+
const cap = columnStats.median * EXTREME_THRESHOLD;
|
|
169
|
+
return Math.min(cap, columnStats.absMax);
|
|
170
|
+
}
|
|
153
171
|
/**
|
|
154
172
|
* Renders an absolute variance bar chart (d_ prefix).
|
|
155
173
|
* Horizontal bar with centered axis, green for positive, red for negative.
|
|
156
174
|
* Value label shown next to the bar (black text per IBCS).
|
|
157
175
|
*
|
|
158
176
|
* Layout: [left label area][bar area with axis][right label area]
|
|
159
|
-
* Uses unitScaling to determine bar width (pixels per unit of measure).
|
|
160
177
|
*/
|
|
161
178
|
const AbsoluteVarianceBar = (props) => {
|
|
162
|
-
const { value, scenario, height, isPositiveGood, formattedValue, measureScale, styles = DEFAULT_STYLES } = props;
|
|
179
|
+
const { value, scenario, columnStats, height, isPositiveGood, formattedValue, measureScale, maxBarWidth: maxBarWidthEm = 3, styles = DEFAULT_STYLES, } = props;
|
|
163
180
|
const s = styles.scaleFactor;
|
|
164
|
-
const labelAreaWidth =
|
|
165
|
-
const maxBarWidth =
|
|
166
|
-
|
|
167
|
-
const
|
|
181
|
+
const labelAreaWidth = 38 * s;
|
|
182
|
+
const maxBarWidth = maxBarWidthEm * styles.fontSize * s;
|
|
183
|
+
// Adaptive axis placement based on data range
|
|
184
|
+
const hasNeg = columnStats.min < 0;
|
|
185
|
+
const hasPos = columnStats.max > 0;
|
|
186
|
+
const negBarWidth = hasNeg ? maxBarWidth : 0;
|
|
187
|
+
const posBarWidth = hasPos ? maxBarWidth : 0;
|
|
188
|
+
const barAreaWidth = negBarWidth + posBarWidth;
|
|
189
|
+
const totalWidth = (hasNeg ? labelAreaWidth : 0) + barAreaWidth + (hasPos ? labelAreaWidth : 0);
|
|
168
190
|
const padding = 2 * s;
|
|
169
191
|
const barHeight = height - padding * 2;
|
|
170
|
-
const axisX =
|
|
171
|
-
//
|
|
172
|
-
|
|
173
|
-
const
|
|
174
|
-
const
|
|
192
|
+
const axisX = (hasNeg ? labelAreaWidth : 0) + negBarWidth;
|
|
193
|
+
// Proportional scaling with outlier detection
|
|
194
|
+
const effectiveMax = computeEffectiveMax(columnStats);
|
|
195
|
+
const absValue = Math.abs(value);
|
|
196
|
+
const proportion = effectiveMax > 0 ? absValue / effectiveMax : 0;
|
|
197
|
+
const isExtreme = absValue > effectiveMax;
|
|
198
|
+
const barWidth = Math.min(proportion, 1) * maxBarWidth;
|
|
175
199
|
const isPositive = value >= 0;
|
|
176
200
|
const barX = isPositive ? axisX : axisX - barWidth;
|
|
177
201
|
const barY = padding;
|
|
@@ -195,7 +219,8 @@ const AbsoluteVarianceBar = (props) => {
|
|
|
195
219
|
// Negative values: label in left area, right-aligned
|
|
196
220
|
const labelX = isPositive ? axisX + barWidth + 4 * s : axisX - barWidth - 4 * s;
|
|
197
221
|
const labelAnchor = isPositive ? "start" : "end";
|
|
198
|
-
|
|
222
|
+
const centerY = height / 2;
|
|
223
|
+
return (h("svg", { width: totalWidth, height: height, class: "cell-bar-chart absolute-variance", style: { overflow: "visible" } }, h(PatternDefs, { styles: styles }), h("line", { x1: axisX, y1: 0, x2: axisX, y2: height, stroke: AXIS_COLOR, "stroke-width": 1 * s }), barWidth > 0 && (h("rect", { x: barX, y: barY, width: barWidth, height: barHeight, fill: fillValue, stroke: barStroke, "stroke-width": barStrokeWidth * s })), isExtreme && isPositive && (h("polygon", { points: `${axisX + maxBarWidth},${centerY} ${axisX + maxBarWidth - 6 * s},${centerY - 3 * s} ${axisX + maxBarWidth - 6 * s},${centerY + 3 * s}`, fill: barStyle.fill === "transparent" ? barStyle.stroke : barStyle.fill })), isExtreme && !isPositive && (h("polygon", { points: `${axisX - maxBarWidth},${centerY} ${axisX - maxBarWidth + 6 * s},${centerY - 3 * s} ${axisX - maxBarWidth + 6 * s},${centerY + 3 * s}`, fill: barStyle.fill === "transparent" ? barStyle.stroke : barStyle.fill })), h("text", { x: labelX, y: height / 2, dy: "0.35em", "text-anchor": labelAnchor, fill: styles.fontColor, "font-size": styles.fontSize, "font-family": styles.fontFamily }, displayValue)));
|
|
199
224
|
};
|
|
200
225
|
/**
|
|
201
226
|
* Renders a relative variance pin chart (dr_ prefix).
|
|
@@ -205,30 +230,36 @@ const AbsoluteVarianceBar = (props) => {
|
|
|
205
230
|
* Uses percentageScaling to determine pin length (pixels per percentage point).
|
|
206
231
|
*/
|
|
207
232
|
const RelativeVariancePin = (props) => {
|
|
208
|
-
const { value, scenario, height, isPositiveGood, formattedValue, measureScale, styles = DEFAULT_STYLES } = props;
|
|
233
|
+
const { value, scenario, columnStats, height, isPositiveGood, formattedValue, measureScale, maxBarWidth: maxBarWidthEm = 3, styles = DEFAULT_STYLES, } = props;
|
|
209
234
|
const s = styles.scaleFactor;
|
|
210
|
-
|
|
211
|
-
const
|
|
212
|
-
const
|
|
235
|
+
// Pin length is ~2/3 of bar width for visual balance
|
|
236
|
+
const maxPinLength = Math.round(maxBarWidthEm * 0.67 * styles.fontSize) * s;
|
|
237
|
+
const pinPadding = 5 * s;
|
|
238
|
+
// Adaptive axis placement based on data range
|
|
239
|
+
const hasNeg = columnStats.min < 0;
|
|
240
|
+
const hasPos = columnStats.max > 0;
|
|
241
|
+
const negPinWidth = hasNeg ? maxPinLength + pinPadding : 0;
|
|
242
|
+
const posPinWidth = hasPos ? maxPinLength + pinPadding : 0;
|
|
243
|
+
const pinAreaWidth = negPinWidth + posPinWidth;
|
|
244
|
+
const labelAreaWidth = 45 * s;
|
|
213
245
|
const totalWidth = pinAreaWidth + labelAreaWidth;
|
|
214
|
-
const axisX =
|
|
246
|
+
const axisX = negPinWidth;
|
|
215
247
|
const centerY = height / 2;
|
|
216
|
-
//
|
|
217
|
-
|
|
218
|
-
const
|
|
219
|
-
const
|
|
220
|
-
const
|
|
248
|
+
// Proportional scaling with outlier detection
|
|
249
|
+
const effectiveMax = computeEffectiveMax(columnStats);
|
|
250
|
+
const absValue = Math.abs(value);
|
|
251
|
+
const proportion = effectiveMax > 0 ? absValue / effectiveMax : 0;
|
|
252
|
+
const isExtreme = absValue > effectiveMax;
|
|
253
|
+
const pinLength = Math.min(proportion, 1) * maxPinLength;
|
|
221
254
|
const isPositive = value >= 0;
|
|
222
255
|
const pinEndX = isPositive ? axisX + pinLength : axisX - pinLength;
|
|
223
256
|
// Get style based on column type (scenario vs variance)
|
|
224
257
|
const barStyle = getBarStyle(scenario, value, isPositiveGood, styles);
|
|
225
258
|
const dotRadius = 3 * s;
|
|
226
|
-
// Show arrow for extreme values (when pin would exceed max length)
|
|
227
|
-
const isExtreme = scaledLength > maxPinLength;
|
|
228
259
|
const displayValue = formattedValue || formatValue(value, true, measureScale);
|
|
229
260
|
// Label always on the right side after the pin area
|
|
230
261
|
const labelX = pinAreaWidth + 4 * s;
|
|
231
|
-
return (h("svg", { width: totalWidth, height: height, class: "cell-bar-chart relative-variance", style: { overflow: "visible" } }, h("line", { x1: axisX, y1: 0, x2: axisX, y2: height, stroke: AXIS_COLOR, "stroke-width": 1 * s }), !isExtreme && h("circle", { cx: pinEndX, cy: centerY, r: dotRadius, fill: styles.fontColor }), h("line", { x1: axisX, y1: centerY, x2: pinEndX, y2: centerY, stroke: barStyle.fill, "stroke-width": 2 * s }), isExtreme && isPositive && (h("polygon", { points: `${
|
|
262
|
+
return (h("svg", { width: totalWidth, height: height, class: "cell-bar-chart relative-variance", style: { overflow: "visible" } }, h("line", { x1: axisX, y1: 0, x2: axisX, y2: height, stroke: AXIS_COLOR, "stroke-width": 1 * s }), !isExtreme && h("circle", { cx: pinEndX, cy: centerY, r: dotRadius, fill: styles.fontColor }), h("line", { x1: axisX, y1: centerY, x2: pinEndX, y2: centerY, stroke: barStyle.fill, "stroke-width": 2 * s }), isExtreme && isPositive && (h("polygon", { points: `${axisX + maxPinLength},${centerY} ${axisX + maxPinLength - 6 * s},${centerY - 3 * s} ${axisX + maxPinLength - 6 * s},${centerY + 3 * s}`, fill: barStyle.fill })), isExtreme && !isPositive && (h("polygon", { points: `${axisX - maxPinLength},${centerY} ${axisX - maxPinLength + 6 * s},${centerY - 3 * s} ${axisX - maxPinLength + 6 * s},${centerY + 3 * s}`, fill: barStyle.fill })), h("text", { x: labelX, y: height / 2, dy: "0.35em", "text-anchor": "start", fill: styles.fontColor, "font-size": styles.fontSize, "font-style": "italic", "font-family": styles.fontFamily }, displayValue)));
|
|
232
263
|
};
|
|
233
264
|
/**
|
|
234
265
|
* CellBarChart - Renders IBCS-compliant variance bar charts.
|
|
@@ -79,7 +79,9 @@ export class TableRow {
|
|
|
79
79
|
if (isSecondaryElement) {
|
|
80
80
|
prefixStyle = "prefix-second";
|
|
81
81
|
}
|
|
82
|
-
|
|
82
|
+
if (columnType) {
|
|
83
|
+
cssStyle = `${cssStyle} ${columnType}`;
|
|
84
|
+
}
|
|
83
85
|
const cell = new Cell(scenario, this.elements.length, value, cssStyle, cellType, prefix, prefixStyle, 1, measureScale);
|
|
84
86
|
cell.isBarChart = isBarChart;
|
|
85
87
|
cell.columnStats = columnStats;
|
|
@@ -113,9 +113,11 @@ export class TableDataSetFactory {
|
|
|
113
113
|
if (!barColumns || barColumns.length === 0) {
|
|
114
114
|
return statsMap;
|
|
115
115
|
}
|
|
116
|
-
//
|
|
116
|
+
// Collect all values per column for median calculation
|
|
117
|
+
const valuesMap = new Map();
|
|
117
118
|
for (const column of barColumns) {
|
|
118
|
-
statsMap.set(column, { min: Infinity, max: -Infinity, absMax: 0 });
|
|
119
|
+
statsMap.set(column, { min: Infinity, max: -Infinity, absMax: 0, median: 0 });
|
|
120
|
+
valuesMap.set(column, []);
|
|
119
121
|
}
|
|
120
122
|
// Iterate through all groups and rows
|
|
121
123
|
for (const groupData of queryData) {
|
|
@@ -126,17 +128,24 @@ export class TableDataSetFactory {
|
|
|
126
128
|
const stats = statsMap.get(column);
|
|
127
129
|
stats.min = Math.min(stats.min, value);
|
|
128
130
|
stats.max = Math.max(stats.max, value);
|
|
131
|
+
valuesMap.get(column).push(Math.abs(value));
|
|
129
132
|
}
|
|
130
133
|
}
|
|
131
134
|
}
|
|
132
135
|
}
|
|
133
|
-
// Finalize absMax values
|
|
136
|
+
// Finalize absMax and median values
|
|
134
137
|
for (const [column, stats] of statsMap) {
|
|
135
138
|
if (stats.min === Infinity || stats.max === -Infinity) {
|
|
136
139
|
stats.min = 0;
|
|
137
140
|
stats.max = 0;
|
|
138
141
|
}
|
|
139
142
|
stats.absMax = Math.max(Math.abs(stats.min), Math.abs(stats.max));
|
|
143
|
+
const absValues = valuesMap.get(column);
|
|
144
|
+
if (absValues.length > 0) {
|
|
145
|
+
absValues.sort((a, b) => a - b);
|
|
146
|
+
const mid = Math.floor(absValues.length / 2);
|
|
147
|
+
stats.median = absValues.length % 2 === 0 ? (absValues[mid - 1] + absValues[mid]) / 2 : absValues[mid];
|
|
148
|
+
}
|
|
140
149
|
statsMap.set(column, stats);
|
|
141
150
|
}
|
|
142
151
|
return statsMap;
|
|
@@ -17,12 +17,14 @@ export class ColumnStatistics {
|
|
|
17
17
|
for (const column of columns) {
|
|
18
18
|
let min = Infinity;
|
|
19
19
|
let max = -Infinity;
|
|
20
|
+
const absValues = [];
|
|
20
21
|
for (const group of data) {
|
|
21
22
|
for (const row of group) {
|
|
22
23
|
const value = this.extractValue(row, column);
|
|
23
24
|
if (value !== null && !isNaN(value)) {
|
|
24
25
|
min = Math.min(min, value);
|
|
25
26
|
max = Math.max(max, value);
|
|
27
|
+
absValues.push(Math.abs(value));
|
|
26
28
|
}
|
|
27
29
|
}
|
|
28
30
|
}
|
|
@@ -32,7 +34,13 @@ export class ColumnStatistics {
|
|
|
32
34
|
max = 0;
|
|
33
35
|
}
|
|
34
36
|
const absMax = Math.max(Math.abs(min), Math.abs(max));
|
|
35
|
-
|
|
37
|
+
let median = 0;
|
|
38
|
+
if (absValues.length > 0) {
|
|
39
|
+
absValues.sort((a, b) => a - b);
|
|
40
|
+
const mid = Math.floor(absValues.length / 2);
|
|
41
|
+
median = absValues.length % 2 === 0 ? (absValues[mid - 1] + absValues[mid]) / 2 : absValues[mid];
|
|
42
|
+
}
|
|
43
|
+
statsMap.set(column, { min, max, absMax, median });
|
|
36
44
|
}
|
|
37
45
|
return statsMap;
|
|
38
46
|
}
|
|
@@ -82,6 +82,33 @@ export var TableCategoryWidth;
|
|
|
82
82
|
TableCategoryWidth["W10"] = "w10";
|
|
83
83
|
TableCategoryWidth["W5"] = "w5";
|
|
84
84
|
})(TableCategoryWidth || (TableCategoryWidth = {}));
|
|
85
|
+
/** Width preset for inline bar/pin chart columns. Value = max bar width in em. */
|
|
86
|
+
export var TableBarColumnWidth;
|
|
87
|
+
(function (TableBarColumnWidth) {
|
|
88
|
+
TableBarColumnWidth["W5"] = "w5";
|
|
89
|
+
TableBarColumnWidth["W10"] = "w10";
|
|
90
|
+
TableBarColumnWidth["W15"] = "w15";
|
|
91
|
+
TableBarColumnWidth["W20"] = "w20";
|
|
92
|
+
TableBarColumnWidth["W25"] = "w25";
|
|
93
|
+
TableBarColumnWidth["W30"] = "w30";
|
|
94
|
+
TableBarColumnWidth["W40"] = "w40";
|
|
95
|
+
TableBarColumnWidth["W60"] = "w60";
|
|
96
|
+
TableBarColumnWidth["W80"] = "w80";
|
|
97
|
+
TableBarColumnWidth["W100"] = "w100";
|
|
98
|
+
})(TableBarColumnWidth || (TableBarColumnWidth = {}));
|
|
99
|
+
/** Maps TableBarColumnWidth presets to max bar width in em. */
|
|
100
|
+
export const BAR_COLUMN_WIDTH_EM = {
|
|
101
|
+
[TableBarColumnWidth.W5]: 5,
|
|
102
|
+
[TableBarColumnWidth.W10]: 10,
|
|
103
|
+
[TableBarColumnWidth.W15]: 15,
|
|
104
|
+
[TableBarColumnWidth.W20]: 20,
|
|
105
|
+
[TableBarColumnWidth.W25]: 25,
|
|
106
|
+
[TableBarColumnWidth.W30]: 30,
|
|
107
|
+
[TableBarColumnWidth.W40]: 40,
|
|
108
|
+
[TableBarColumnWidth.W60]: 60,
|
|
109
|
+
[TableBarColumnWidth.W80]: 80,
|
|
110
|
+
[TableBarColumnWidth.W100]: 100,
|
|
111
|
+
};
|
|
85
112
|
/**
|
|
86
113
|
* Three-level row hierarchy for grouping and drill-down: rowGroup > category > subCategory.
|
|
87
114
|
* Index variants (e.g. ROWGROUPINDEX) provide stable numeric sort keys that preserve
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* These are used in component @Watch methods to warn about malformed attribute values
|
|
6
6
|
* without crashing the component.
|
|
7
7
|
*/
|
|
8
|
-
import { AggregationLevel, AxisLabelsMode, DataFormat, I18nMode, MeasureType, Scenarios, Sentiments, TableCategoryWidth, TableType, } from "./constants";
|
|
8
|
+
import { AggregationLevel, AxisLabelsMode, DataFormat, I18nMode, MeasureType, Scenarios, Sentiments, TableBarColumnWidth, TableCategoryWidth, TableType, } from "./constants";
|
|
9
9
|
import { DateDistance, DateLink } from "./DateStringFactory";
|
|
10
10
|
import { OrderColumn, OrderDirection } from "./model/Order";
|
|
11
11
|
/**
|
|
@@ -264,6 +264,9 @@ export function validateStylesString(value) {
|
|
|
264
264
|
export function isTableCategoryWidth(value) {
|
|
265
265
|
return (value === null || value === void 0 ? void 0 : value.toUpperCase().trim()) in TableCategoryWidth;
|
|
266
266
|
}
|
|
267
|
+
export function isTableBarColumnWidth(value) {
|
|
268
|
+
return (value === null || value === void 0 ? void 0 : value.toUpperCase().trim()) in TableBarColumnWidth;
|
|
269
|
+
}
|
|
267
270
|
export function validateColumnThereOfJsonStr(value) {
|
|
268
271
|
if (isBlankInput(value)) {
|
|
269
272
|
return [];
|