@bino-bi/bn-template-engine 1.0.0-next.28 → 1.0.0-next.30
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-132ad556.entry.js +1 -0
- package/dist/bn-template-engine/p-17d71782.entry.js +1 -0
- package/dist/bn-template-engine/p-40ba7f43.entry.js +1 -0
- package/dist/bn-template-engine/p-467871f3.entry.js +1 -0
- package/dist/bn-template-engine/p-64803a42.entry.js +1 -0
- package/dist/bn-template-engine/p-B8AjeKja.js +1 -0
- package/dist/bn-template-engine/p-CCZcKl0Q.js +2 -0
- package/dist/bn-template-engine/p-CrT83eO4.js +1 -0
- package/dist/bn-template-engine/p-D_DzKxRV.js +1 -0
- package/dist/bn-template-engine/p-Z2rUaSh_.js +1 -0
- package/dist/bn-template-engine/p-c41c0a1b.entry.js +1 -0
- package/dist/bn-template-engine/p-yc69rwuH.js +1 -0
- package/dist/cjs/{bn-asset_28.cjs.entry.js → bn-annotation-layer_30.cjs.entry.js} +27566 -26774
- package/dist/cjs/bn-grid.cjs.entry.js +11 -63
- package/dist/cjs/bn-image.cjs.entry.js +5 -6
- package/dist/cjs/bn-internationalization.cjs.entry.js +11 -7
- package/dist/cjs/bn-ruleset.cjs.entry.js +7 -8
- package/dist/cjs/bn-template-engine.cjs.js +2 -2
- package/dist/cjs/bn-text.cjs.entry.js +18 -18
- package/dist/cjs/{diagnostics-Cq-qDtXq.js → diagnostics-C4Ggts3w.js} +50 -2
- package/dist/cjs/{index-C1Z9vO7z.js → index-DGis1BzT.js} +0 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{withBodyObserver-CaPUjuC5.js → withBodyObserver-BK4idxqG.js} +2 -2
- package/dist/cjs/{context-protocol-C0rKepqu.js → withHasError-CqvcS23z.js} +462 -14
- package/dist/cjs/{withStyled-vSfogp9J.js → withStyled-70D4Isgt.js} +22 -35
- package/dist/cjs/{sanitizeHtml-Yx1xn6i_.js → withTranslation-C6Pye2CM.js} +148 -129
- package/dist/collection/collection-manifest.json +11 -11
- package/dist/collection/components/bn-annotation-layer/bn-annotation-layer.css +24 -0
- package/dist/collection/components/bn-annotation-layer/bn-annotation-layer.js +430 -0
- package/dist/collection/components/bn-annotation-layer/utils/marks.js +161 -0
- package/dist/collection/components/bn-annotation-layer/utils/matchPoint.js +25 -0
- package/dist/collection/components/bn-annotation-list/bn-annotation-list.css +46 -0
- package/dist/collection/components/bn-annotation-list/bn-annotation-list.js +112 -0
- package/dist/collection/components/bn-asset/bn-asset.js +1 -1
- package/dist/collection/components/bn-body/bn-body.js +24 -1
- package/dist/collection/components/bn-card/bn-card.js +24 -1
- package/dist/collection/components/bn-chart-bubble/{ibcs-chart-bubble.js → bn-chart-bubble-renderer/bn-chart-bubble-renderer.js} +153 -59
- package/dist/collection/components/bn-chart-bubble/bn-chart-bubble.js +70 -13
- package/dist/collection/components/bn-chart-bubble/utils/BubbleChart.js +29 -21
- package/dist/collection/components/bn-chart-bullet/{ibcs-chart-bullet.js → bn-chart-bullet-renderer/bn-chart-bullet-renderer.js} +127 -53
- package/dist/collection/components/bn-chart-bullet/bn-chart-bullet.js +83 -20
- package/dist/collection/components/bn-chart-bullet/utils/BulletChart.js +26 -17
- package/dist/collection/components/bn-chart-bullet/utils/model/BulletChartStyle.js +4 -4
- package/dist/collection/components/bn-chart-scatter/{ibcs-chart-scatter.js → bn-chart-scatter-renderer/bn-chart-scatter-renderer.js} +132 -53
- package/dist/collection/components/bn-chart-scatter/bn-chart-scatter.js +69 -12
- package/dist/collection/components/bn-chart-scatter/utils/ScatterChart.js +26 -14
- package/dist/collection/components/bn-chart-structure/{ibcs-chart-structure.js → bn-chart-structure-renderer/bn-chart-structure-renderer.js} +159 -66
- package/dist/collection/components/bn-chart-structure/bn-chart-structure.js +115 -95
- package/dist/collection/components/bn-chart-structure/utils/StructureChart.js +44 -15
- package/dist/collection/components/bn-chart-structure/utils/elements/Axis.js +1 -1
- package/dist/collection/components/bn-chart-structure/utils/elements/Bar.js +6 -2
- package/dist/collection/components/bn-chart-structure/utils/elements/Label.js +11 -0
- package/dist/collection/components/bn-chart-structure/utils/elements/Marker.js +5 -1
- package/dist/collection/components/bn-chart-structure/utils/elements/Needle.js +4 -1
- package/dist/collection/components/bn-chart-structure/utils/elements/StackedBar.js +6 -2
- package/dist/collection/components/bn-chart-time/{ibcs-chart-time.js → bn-chart-time-renderer/bn-chart-time-renderer.js} +188 -150
- package/dist/collection/components/bn-chart-time/bn-chart-time.js +140 -405
- package/dist/collection/components/bn-chart-time/utils/TimeChart.js +55 -15
- package/dist/collection/components/bn-chart-time/utils/elements/Column.js +5 -1
- package/dist/collection/components/bn-chart-time/utils/elements/Label.js +14 -0
- package/dist/collection/components/bn-chart-time/utils/elements/LineSeries.js +18 -12
- package/dist/collection/components/bn-chart-time/utils/elements/Marker.js +5 -1
- package/dist/collection/components/bn-chart-time/utils/elements/Needle.js +4 -1
- package/dist/collection/components/bn-chart-time/utils/elements/StackedColumn.js +6 -2
- package/dist/collection/components/bn-chart-time/utils/factories/ScenarioFactory.js +2 -2
- package/dist/collection/components/bn-chart-time/utils/model/TimeChartComponentConfig.js +2 -18
- package/dist/collection/components/bn-component-style/bn-component-style.js +3 -3
- package/dist/collection/components/bn-context/bn-context.js +24 -5
- package/dist/collection/components/bn-dataset/bn-dataset.js +8 -8
- package/dist/collection/components/bn-datasource/bn-datasource.js +8 -8
- package/dist/collection/components/bn-footer/bn-footer.css +1 -15
- package/dist/collection/components/bn-footer/bn-footer.js +17 -34
- package/dist/collection/components/bn-grid/bn-grid.js +38 -71
- package/dist/collection/components/bn-image/bn-image.js +21 -2
- package/dist/collection/components/bn-internationalization/bn-internationalization.js +7 -1
- package/dist/collection/components/bn-layout-card/bn-layout-card.js +3 -32
- package/dist/collection/components/bn-layout-page/bn-layout-page.js +3 -32
- package/dist/collection/components/bn-message/bn-message.js +20 -2
- package/dist/collection/components/bn-page/bn-page.js +22 -3
- package/dist/collection/components/bn-ruleset/bn-ruleset.js +3 -3
- package/dist/collection/components/bn-scaling-group/bn-scaling-group.js +9 -9
- package/dist/collection/components/bn-table/{ibcs-table.js → bn-table-renderer/bn-table-renderer.js} +230 -83
- package/dist/collection/components/bn-table/bn-table.js +134 -157
- package/dist/collection/components/bn-table/utils/Table.js +3 -3
- package/dist/collection/components/bn-table/utils/elements/TableRow.js +1 -1
- package/dist/collection/components/bn-table/utils/factories/tableDataSetFactory.js +38 -4
- package/dist/collection/components/bn-table/utils/helper/DataQuery.js +3 -1
- package/dist/collection/components/bn-table/utils/helper/barColumnGeometry.js +2 -2
- package/dist/collection/components/bn-text/bn-text.js +66 -8
- package/dist/collection/components/bn-title/{ibcs-title/ibcs-title.js → bn-title-renderer/bn-title-renderer.js} +59 -83
- package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/Title.js +2 -2
- package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/factories/TitleDataSetFactory.js +1 -1
- package/dist/collection/components/bn-title/bn-title.js +58 -14
- package/dist/collection/components/bn-tree/bn-tree.js +30 -28
- package/dist/collection/index.js +0 -1
- package/dist/collection/schemas.js +1 -0
- package/dist/collection/stores/componentStyles.js +10 -6
- package/dist/collection/stores/createScopedStores.js +3 -1
- package/dist/collection/stores/internationalization.js +10 -6
- package/dist/collection/utils/annotations.js +66 -0
- package/dist/collection/utils/autoFit.js +2 -2
- package/dist/collection/utils/emptyState.js +1 -1
- package/dist/collection/utils/ibcsRuleSet.js +42 -0
- package/dist/collection/utils/layoutState/dataPoint.js +59 -0
- package/dist/collection/utils/layoutState/geometry.js +46 -0
- package/dist/collection/utils/layoutState/index.js +1 -0
- package/dist/collection/utils/layoutState/svgChartElements.js +113 -11
- package/dist/collection/utils/layoutTemplate.js +0 -2
- package/dist/collection/utils/scaling.js +9 -0
- package/dist/collection/utils/validate.js +0 -7
- package/dist/collection/utils/withComponentStyle.js +14 -18
- package/dist/collection/utils/withDataset.js +22 -11
- package/dist/collection/utils/withHasError.js +17 -2
- package/dist/collection/utils/withRuleSet.js +7 -7
- package/dist/collection/utils/withTranslation.js +14 -14
- package/dist/collection/utils/xy/XYFrame.js +13 -3
- package/dist/collection/utils/xy/model/ScaleFactorsXYChart.js +8 -9
- package/dist/collection/utils/xy/pointKey.js +10 -0
- package/dist/components/{ibcs-chart-bullet.d.ts → bn-annotation-layer.d.ts} +4 -4
- package/dist/components/bn-annotation-layer.js +1 -0
- package/dist/components/{ibcs-chart-scatter.d.ts → bn-annotation-list.d.ts} +4 -4
- package/dist/components/bn-annotation-list.js +1 -0
- package/dist/components/bn-asset.js +1 -1
- package/dist/components/bn-body.js +1 -1
- package/dist/components/bn-card.js +1 -1
- package/dist/components/bn-chart-bubble-renderer.d.ts +11 -0
- package/dist/components/bn-chart-bubble-renderer.js +1 -0
- package/dist/components/bn-chart-bubble.js +1 -1
- package/dist/components/bn-chart-bullet-renderer.d.ts +11 -0
- package/dist/components/bn-chart-bullet-renderer.js +1 -0
- package/dist/components/bn-chart-bullet.js +1 -1
- package/dist/components/bn-chart-scatter-renderer.d.ts +11 -0
- package/dist/components/bn-chart-scatter-renderer.js +1 -0
- package/dist/components/bn-chart-scatter.js +1 -1
- package/dist/components/bn-chart-structure-renderer.d.ts +11 -0
- package/dist/components/bn-chart-structure-renderer.js +1 -0
- package/dist/components/bn-chart-structure.js +1 -1
- package/dist/components/{bn-template.d.ts → bn-chart-time-renderer.d.ts} +4 -4
- package/dist/components/bn-chart-time-renderer.js +1 -0
- package/dist/components/bn-chart-time.js +1 -1
- package/dist/components/bn-component-style.js +1 -1
- package/dist/components/bn-context.js +1 -1
- package/dist/components/bn-dataset.js +1 -1
- package/dist/components/bn-datasource.js +1 -1
- package/dist/components/bn-footer.js +1 -1
- package/dist/components/bn-grid.js +1 -1
- package/dist/components/bn-image.js +1 -1
- package/dist/components/bn-internationalization.js +1 -1
- package/dist/components/bn-layout-card.js +1 -1
- package/dist/components/bn-layout-page.js +1 -1
- package/dist/components/bn-message.js +1 -1
- package/dist/components/bn-page.js +1 -1
- package/dist/components/bn-ruleset.js +1 -1
- package/dist/components/bn-scaling-group.js +1 -1
- package/dist/components/{ibcs-chart-bubble.d.ts → bn-table-renderer.d.ts} +4 -4
- package/dist/components/bn-table-renderer.js +1 -0
- package/dist/components/bn-table.js +1 -1
- package/dist/components/bn-text.js +1 -1
- package/dist/components/{editor-companion.d.ts → bn-title-renderer.d.ts} +4 -4
- package/dist/components/bn-title-renderer.js +1 -0
- package/dist/components/bn-title.js +1 -1
- package/dist/components/bn-tree.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/p-B1nL0yOa.js +1 -0
- package/dist/components/p-B7uwck1J.js +1 -0
- package/dist/components/p-BDS_jiow.js +1 -0
- package/dist/components/p-BIIDTtcR.js +1 -0
- package/dist/components/p-BQMKgvEC.js +1 -0
- package/dist/components/p-BSV_vyqs.js +1 -0
- package/dist/components/p-BVKLCz2k.js +1 -0
- package/dist/components/p-BWBHlztH.js +1 -0
- package/dist/components/p-BXrPfAvP.js +1 -0
- package/dist/components/p-Ba9PUiBp.js +1 -0
- package/dist/components/p-BpCL2bfw.js +1 -0
- package/dist/components/p-BpsXOtoW.js +1 -0
- package/dist/components/p-Bs-YxJEt.js +1 -0
- package/dist/components/p-CGI6XIaK.js +1 -0
- package/dist/components/p-CMM8vtHW.js +1 -0
- package/dist/components/p-COqIkH1M.js +1 -0
- package/dist/components/p-CYwd_ZNM.js +1 -0
- package/dist/components/p-CkW23yp2.js +1 -0
- package/dist/components/p-CtBM3KFY.js +1 -0
- package/dist/{bn-template-engine/p-DFmSrSnf.js → components/p-CurWSJkH.js} +1 -1
- package/dist/components/p-CxPSvrcF.js +1 -0
- package/dist/components/p-D2Epww9R.js +1 -0
- package/dist/components/p-D5-dYgK_.js +1 -0
- package/dist/components/p-D6YGOYV1.js +2 -0
- package/dist/components/p-DEHnizot.js +1 -0
- package/dist/components/p-DIyUaSBg.js +1 -0
- package/dist/components/p-DPLcGhVt.js +1 -0
- package/dist/components/p-DUHp_9X-.js +1 -0
- package/dist/components/p-DYG9FH_u.js +1 -0
- package/dist/components/p-DdGnuNtc.js +1 -0
- package/dist/components/p-Dlb4ncGF.js +1 -0
- package/dist/components/p-Dm55bMs2.js +1 -0
- package/dist/components/p-Dq1AzGKX.js +1 -0
- package/dist/components/p-Dq4KMCDU.js +1 -0
- package/dist/components/p-DsOaqeTN.js +1 -0
- package/dist/components/p-Ds_BSK8v.js +1 -0
- package/dist/components/p-LZ9lAY8T.js +1 -0
- package/dist/components/p-U3zkcEJZ.js +1 -0
- package/dist/components/p-WzaayhTX.js +1 -0
- package/dist/components/p-X9hpquOX.js +1 -0
- package/dist/components/p-Xb6Ilq8u.js +1 -0
- package/dist/components/p-ey23VlID.js +1 -0
- package/dist/components/p-jbp6YiHf.js +1 -0
- package/dist/components/p-oJjMz8JF.js +1 -0
- package/dist/components/p-xhiPDAZa.js +1 -0
- package/dist/components/p-xpguaboj.js +1 -0
- package/dist/esm/{bn-asset_28.entry.js → bn-annotation-layer_30.entry.js} +24689 -23899
- package/dist/esm/bn-grid.entry.js +11 -63
- package/dist/esm/bn-image.entry.js +4 -5
- package/dist/esm/bn-internationalization.entry.js +9 -5
- package/dist/esm/bn-ruleset.entry.js +6 -7
- package/dist/esm/bn-template-engine.js +3 -3
- package/dist/esm/bn-text.entry.js +12 -12
- package/dist/esm/{diagnostics-vw6TKMiT.js → diagnostics-Cyqy1zDT.js} +48 -2
- package/dist/esm/{index-C5UYpZUU.js → index-CCZcKl0Q.js} +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{withBodyObserver-DD_-r04o.js → withBodyObserver-JcRB9OPQ.js} +2 -2
- package/dist/esm/{context-protocol-CdTp19uA.js → withHasError-l3cMN-oP.js} +458 -14
- package/dist/esm/{withStyled-BDEyKd_H.js → withStyled-DGOiR00Q.js} +17 -29
- package/dist/esm/{sanitizeHtml-C5bFtARM.js → withTranslation-BpO8BC5B.js} +144 -126
- package/dist/schemas/axis.schema.json +52 -0
- package/dist/schemas/i18n.schema.json +31 -0
- package/dist/schemas/partof.schema.json +33 -0
- package/dist/schemas/ruleset.schema.json +59 -0
- package/dist/schemas/stack.schema.json +51 -0
- package/dist/schemas/theme.schema.json +604 -0
- package/dist/schemas/thereof.schema.json +34 -0
- package/dist/types/components/bn-annotation-layer/bn-annotation-layer.d.ts +81 -0
- package/dist/types/components/bn-annotation-layer/utils/marks.d.ts +69 -0
- package/dist/types/components/bn-annotation-layer/utils/matchPoint.d.ts +17 -0
- package/dist/types/components/bn-annotation-list/bn-annotation-list.d.ts +35 -0
- package/dist/types/components/bn-body/bn-body.d.ts +5 -0
- package/dist/types/components/bn-card/bn-card.d.ts +5 -0
- package/dist/types/components/bn-chart-bubble/bn-chart-bubble-renderer/bn-chart-bubble-renderer.d.ts +97 -0
- package/dist/types/components/bn-chart-bubble/bn-chart-bubble.d.ts +20 -2
- package/dist/types/components/bn-chart-bullet/bn-chart-bullet-renderer/bn-chart-bullet-renderer.d.ts +81 -0
- package/dist/types/components/bn-chart-bullet/bn-chart-bullet.d.ts +21 -3
- package/dist/types/components/bn-chart-bullet/utils/BulletChart.d.ts +2 -0
- package/dist/types/components/bn-chart-bullet/utils/model/BulletChartStyle.d.ts +2 -2
- package/dist/types/components/bn-chart-scatter/bn-chart-scatter-renderer/bn-chart-scatter-renderer.d.ts +85 -0
- package/dist/types/components/bn-chart-scatter/bn-chart-scatter.d.ts +20 -2
- package/dist/types/components/bn-chart-structure/{ibcs-chart-structure.d.ts → bn-chart-structure-renderer/bn-chart-structure-renderer.d.ts} +43 -13
- package/dist/types/components/bn-chart-structure/bn-chart-structure.d.ts +29 -17
- package/dist/types/components/bn-chart-structure/utils/StructureChart.d.ts +7 -0
- package/dist/types/components/bn-chart-structure/utils/elements/Label.d.ts +5 -0
- package/dist/types/components/bn-chart-structure/utils/elements/Marker.d.ts +1 -0
- package/dist/types/components/bn-chart-structure/utils/elements/StackedBar.d.ts +2 -1
- package/dist/types/components/bn-chart-structure/utils/model/DataPoint.d.ts +3 -0
- package/dist/types/components/bn-chart-time/{ibcs-chart-time.d.ts → bn-chart-time-renderer/bn-chart-time-renderer.d.ts} +50 -17
- package/dist/types/components/bn-chart-time/bn-chart-time.d.ts +36 -66
- package/dist/types/components/bn-chart-time/utils/TimeChart.d.ts +7 -0
- package/dist/types/components/bn-chart-time/utils/elements/Label.d.ts +5 -0
- package/dist/types/components/bn-chart-time/utils/elements/LineSeries.d.ts +5 -1
- package/dist/types/components/bn-chart-time/utils/elements/Marker.d.ts +1 -0
- package/dist/types/components/bn-chart-time/utils/elements/StackedColumn.d.ts +2 -1
- package/dist/types/components/bn-chart-time/utils/factories/ScenarioFactory.d.ts +1 -1
- package/dist/types/components/bn-chart-time/utils/model/DataPoint.d.ts +3 -0
- package/dist/types/components/bn-chart-time/utils/model/TimeChartComponentConfig.d.ts +2 -8
- package/dist/types/components/bn-context/bn-context.d.ts +7 -1
- package/dist/types/components/bn-dataset/bn-dataset.d.ts +2 -2
- package/dist/types/components/bn-datasource/bn-datasource.d.ts +2 -2
- package/dist/types/components/bn-footer/bn-footer.d.ts +5 -7
- package/dist/types/components/bn-grid/bn-grid.d.ts +8 -6
- package/dist/types/components/bn-image/bn-image.d.ts +4 -0
- package/dist/types/components/bn-layout-card/bn-layout-card.d.ts +0 -1
- package/dist/types/components/bn-layout-page/bn-layout-page.d.ts +0 -1
- package/dist/types/components/bn-message/bn-message.d.ts +5 -0
- package/dist/types/components/bn-page/bn-page.d.ts +5 -0
- package/dist/types/components/bn-table/{ibcs-table.d.ts → bn-table-renderer/bn-table-renderer.d.ts} +49 -12
- package/dist/types/components/bn-table/bn-table.d.ts +48 -49
- package/dist/types/components/bn-table/utils/elements/Cell.d.ts +2 -0
- package/dist/types/components/bn-table/utils/elements/CellBarChart.d.ts +2 -1
- package/dist/types/components/bn-table/utils/elements/TableRow.d.ts +3 -0
- package/dist/types/components/bn-table/utils/factories/tableDataSetFactory.d.ts +9 -2
- package/dist/types/components/bn-text/bn-text.d.ts +19 -1
- package/dist/types/components/bn-title/{ibcs-title/ibcs-title.d.ts → bn-title-renderer/bn-title-renderer.d.ts} +15 -4
- package/dist/types/components/bn-title/bn-title.d.ts +15 -3
- package/dist/types/components/bn-tree/bn-tree.d.ts +6 -2
- package/dist/types/components.d.ts +2070 -2406
- package/dist/types/context/context-protocol.d.ts +2 -0
- package/dist/types/context/scopedDb.d.ts +9 -12
- package/dist/types/index.d.ts +0 -1
- package/dist/types/schemas.d.ts +50 -0
- package/dist/types/stores/componentStyles.d.ts +8 -0
- package/dist/types/stores/createScopedStores.d.ts +1 -0
- package/dist/types/stores/internationalization.d.ts +3 -2
- package/dist/types/stores/ruleSets.d.ts +15 -3
- package/dist/types/utils/annotations.d.ts +45 -0
- package/dist/types/utils/autoFit.d.ts +2 -2
- package/dist/types/utils/emptyState.d.ts +1 -1
- package/dist/types/utils/ibcsRuleSet.d.ts +16 -0
- package/dist/types/utils/layoutState/dataPoint.d.ts +13 -0
- package/dist/types/utils/layoutState/geometry.d.ts +12 -0
- package/dist/types/utils/layoutState/index.d.ts +1 -0
- package/dist/types/utils/layoutState/svgChartElements.d.ts +9 -6
- package/dist/types/utils/layoutState/types.d.ts +29 -0
- package/dist/types/utils/model/ChartStyles.d.ts +2 -1
- package/dist/types/utils/scaling.d.ts +2 -0
- package/dist/types/utils/validate.d.ts +0 -1
- package/dist/types/utils/withComponentStyle.d.ts +4 -4
- package/dist/types/utils/withDataset.d.ts +3 -3
- package/dist/types/utils/withHasError.d.ts +22 -1
- package/dist/types/utils/withRuleSet.d.ts +3 -2
- package/dist/types/utils/withTranslation.d.ts +1 -2
- package/dist/types/utils/xy/model/ScaleFactorsXYChart.d.ts +6 -7
- package/dist/types/utils/xy/pointKey.d.ts +9 -0
- package/package.json +24 -8
- package/readme.md +14 -8
- package/dist/bn-template-engine/assets/bar.png +0 -0
- package/dist/bn-template-engine/assets/matrix.png +0 -0
- package/dist/bn-template-engine/p-5075771a.entry.js +0 -1
- package/dist/bn-template-engine/p-5d516435.entry.js +0 -1
- package/dist/bn-template-engine/p-5e90e728.entry.js +0 -1
- package/dist/bn-template-engine/p-9ef7e132.entry.js +0 -1
- package/dist/bn-template-engine/p-9f7a1980.entry.js +0 -1
- package/dist/bn-template-engine/p-BeXgxHkW.js +0 -1
- package/dist/bn-template-engine/p-C5UYpZUU.js +0 -2
- package/dist/bn-template-engine/p-CH0bpt_k.js +0 -1
- package/dist/bn-template-engine/p-DI3efDSV.js +0 -1
- package/dist/bn-template-engine/p-DXLTTILG.js +0 -1
- package/dist/bn-template-engine/p-DtP4jqG5.js +0 -1
- package/dist/bn-template-engine/p-a8281b71.entry.js +0 -1
- package/dist/bn-template-engine/p-b31277e7.entry.js +0 -1
- package/dist/bn-template-engine/p-b396ac84.entry.js +0 -1
- package/dist/cjs/bn-template.cjs.entry.js +0 -18
- package/dist/cjs/editor-companion.cjs.entry.js +0 -56
- package/dist/cjs/withHasError-qGW_yqIv.js +0 -426
- package/dist/collection/components/bn-footer/assets/bar.png +0 -0
- package/dist/collection/components/bn-footer/assets/matrix.png +0 -0
- package/dist/collection/components/bn-message/assets/bar.png +0 -0
- package/dist/collection/components/bn-message/assets/matrix.png +0 -0
- package/dist/collection/components/bn-template/bn-template.js +0 -38
- package/dist/collection/components/editor-companion/editor-companion.css +0 -3
- package/dist/collection/components/editor-companion/editor-companion.js +0 -137
- package/dist/collection/utils/templateId.js +0 -12
- package/dist/collection/utils/testing/fakeGroup.js +0 -21
- package/dist/collection/utils/testing/hostFont.js +0 -20
- package/dist/collection/utils/testing/mutationObserver.js +0 -44
- package/dist/collection/utils/testing/structureChart.js +0 -26
- package/dist/collection/utils/testing/timeChart.js +0 -28
- package/dist/components/AxisConfig.js +0 -1
- package/dist/components/CompareUtil.js +0 -1
- package/dist/components/DataFormatDigits.js +0 -1
- package/dist/components/DateStringFactory.js +0 -1
- package/dist/components/LabelCollisionManager.js +0 -1
- package/dist/components/Order.js +0 -1
- package/dist/components/SVGStyle.js +0 -1
- package/dist/components/SVGVariancesStyleGroup.js +0 -1
- package/dist/components/StringAdapter.js +0 -1
- package/dist/components/VarianceMeasure.js +0 -1
- package/dist/components/XYChartDataRow.js +0 -1
- package/dist/components/bn-body2.js +0 -1
- package/dist/components/bn-card2.js +0 -1
- package/dist/components/bn-footer2.js +0 -1
- package/dist/components/bn-message2.js +0 -1
- package/dist/components/bn-page2.js +0 -1
- package/dist/components/bn-template.js +0 -1
- package/dist/components/bn-title2.js +0 -1
- package/dist/components/checkXYOverflow.js +0 -1
- package/dist/components/contentDecoder.js +0 -1
- package/dist/components/context-protocol.js +0 -1
- package/dist/components/editor-companion.js +0 -1
- package/dist/components/formatter.js +0 -1
- package/dist/components/geometry.js +0 -1
- package/dist/components/ibcs-chart-bubble.js +0 -1
- package/dist/components/ibcs-chart-bubble2.js +0 -1
- package/dist/components/ibcs-chart-bullet.js +0 -1
- package/dist/components/ibcs-chart-bullet2.js +0 -1
- package/dist/components/ibcs-chart-scatter.js +0 -1
- package/dist/components/ibcs-chart-scatter2.js +0 -1
- package/dist/components/ibcs-chart-structure.d.ts +0 -11
- package/dist/components/ibcs-chart-structure.js +0 -1
- package/dist/components/ibcs-chart-structure2.js +0 -1
- package/dist/components/ibcs-chart-time.d.ts +0 -11
- package/dist/components/ibcs-chart-time.js +0 -1
- package/dist/components/ibcs-chart-time2.js +0 -1
- package/dist/components/ibcs-table.d.ts +0 -11
- package/dist/components/ibcs-table.js +0 -1
- package/dist/components/ibcs-table2.js +0 -1
- package/dist/components/ibcs-title.d.ts +0 -11
- package/dist/components/ibcs-title.js +0 -1
- package/dist/components/ibcs-title2.js +0 -1
- package/dist/components/layoutTemplate.js +0 -1
- package/dist/components/luxon.js +0 -1
- package/dist/components/scaling.js +0 -1
- package/dist/components/svg.esm.js +0 -1
- package/dist/components/svgChartElements.js +0 -1
- package/dist/components/types.js +0 -1
- package/dist/components/validate.js +0 -1
- package/dist/components/withBodyObserver.js +0 -1
- package/dist/components/withComponentStatus.js +0 -1
- package/dist/components/withComponentStyle.js +0 -1
- package/dist/components/withDataset.js +0 -1
- package/dist/components/withHasError.js +0 -1
- package/dist/components/withRuleSet.js +0 -1
- package/dist/components/withScalingGroup.js +0 -1
- package/dist/components/withStyled.js +0 -1
- package/dist/components/withTranslation.js +0 -1
- package/dist/esm/bn-template.entry.js +0 -16
- package/dist/esm/editor-companion.entry.js +0 -54
- package/dist/esm/withHasError-73WV2SP5.js +0 -422
- package/dist/types/components/bn-chart-bubble/ibcs-chart-bubble.d.ts +0 -59
- package/dist/types/components/bn-chart-bullet/ibcs-chart-bullet.d.ts +0 -53
- package/dist/types/components/bn-chart-scatter/ibcs-chart-scatter.d.ts +0 -54
- package/dist/types/components/bn-template/bn-template.d.ts +0 -10
- package/dist/types/components/editor-companion/editor-companion.d.ts +0 -20
- package/dist/types/utils/templateId.d.ts +0 -9
- package/dist/types/utils/testing/fakeGroup.d.ts +0 -8
- package/dist/types/utils/testing/hostFont.d.ts +0 -16
- package/dist/types/utils/testing/mutationObserver.d.ts +0 -5
- package/dist/types/utils/testing/structureChart.d.ts +0 -5
- package/dist/types/utils/testing/timeChart.d.ts +0 -5
- /package/dist/collection/components/bn-chart-bubble/{ibcs-chart-bubble.css → bn-chart-bubble-renderer/bn-chart-bubble-renderer.css} +0 -0
- /package/dist/collection/components/bn-chart-bullet/{ibcs-chart-bullet.css → bn-chart-bullet-renderer/bn-chart-bullet-renderer.css} +0 -0
- /package/dist/collection/components/bn-chart-scatter/{ibcs-chart-scatter.css → bn-chart-scatter-renderer/bn-chart-scatter-renderer.css} +0 -0
- /package/dist/collection/components/bn-chart-time/{ibcs-chart-time.css → bn-chart-time-renderer/bn-chart-time-renderer.css} +0 -0
- /package/dist/collection/components/bn-table/{ibcs-table.css → bn-table-renderer/bn-table-renderer.css} +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title/ibcs-title.css → bn-title-renderer/bn-title-renderer.css} +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/factories/index.js +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/MeasureEntriy.js +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/TimePeriod.js +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/TitleConfig.js +0 -0
- /package/dist/collection/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/index.js +0 -0
- /package/dist/components/{stackColors.js → p-4q8nRcWC.js} +0 -0
- /package/dist/components/{merge.js → p-B2NXsfMz.js} +0 -0
- /package/dist/components/{layoutObserver.js → p-B6kka9sT.js} +0 -0
- /package/dist/components/{NumericScale.js → p-BJmwHV0a.js} +0 -0
- /package/dist/components/{stackLayout.js → p-BTnRaHPb.js} +0 -0
- /package/dist/components/{emotion-hash.esm.js → p-BYBpC0EO.js} +0 -0
- /package/dist/components/{diagnostics.js → p-CckAR27O.js} +0 -0
- /package/dist/components/{SiPrefix.js → p-CeE4_3wQ.js} +0 -0
- /package/dist/components/{queryError.js → p-ClruFZD_.js} +0 -0
- /package/dist/components/{sanitizeHtml.js → p-CyUmrWfW.js} +0 -0
- /package/dist/components/{TableAttribute.js → p-DCPLGEs_.js} +0 -0
- /package/dist/components/{parentDimensions.js → p-DD1zlev_.js} +0 -0
- /package/dist/components/{pageFormats.js → p-DM7fwmH4.js} +0 -0
- /package/dist/components/{emptyState.js → p-DakXa7Dp.js} +0 -0
- /package/dist/components/{relativeVariance.js → p-fCjsrD7I.js} +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/Title.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/factories/TitleDataSetFactory.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/factories/index.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/MeasureEntriy.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/TimePeriod.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/TitleConfig.d.ts +0 -0
- /package/dist/types/components/bn-title/{ibcs-title → bn-title-renderer}/utils/model/index.d.ts +0 -0
|
@@ -10,13 +10,14 @@ import { DateTime } from "luxon";
|
|
|
10
10
|
import { sourceExpr } from "../../../context/scopedDb";
|
|
11
11
|
import { errorText } from "../../../utils/queryError";
|
|
12
12
|
import { DateDistance, DateStringFactory } from "../../../utils/DateStringFactory";
|
|
13
|
-
import {
|
|
13
|
+
import { pointDate } from "../../../utils/layoutState/dataPoint";
|
|
14
|
+
import { AxisLabelsMode, ChartMode, RELATIVE_STACK_UNITS, StackBy, StackMode } from "../../../utils/constants";
|
|
14
15
|
import { getScenarioPrefix, IBCS_LAYER_ORDER } from "../../../utils/stackColors";
|
|
15
16
|
import { layoutStack, stackExtent, stackLabelSide } from "../../../utils/stackLayout";
|
|
16
17
|
import { computePercentBarExtent, computeUnitBarExtent } from "../../../utils/autoFit";
|
|
17
18
|
import { drawAttached } from "../../../utils/measurementHost";
|
|
18
19
|
import { Formatter } from "../../../utils";
|
|
19
|
-
import { IBCSRuleSet } from "../../../utils/ibcsRuleSet";
|
|
20
|
+
import { IBCSRuleSet, styleSlot, stylesBySlot } from "../../../utils/ibcsRuleSet";
|
|
20
21
|
import { relativeVariance } from "../../../utils/relativeVariance";
|
|
21
22
|
import { VarianceScenario } from "../../../utils/model";
|
|
22
23
|
import { SiPrefix } from "../../../utils/model/SiPrefix";
|
|
@@ -189,7 +190,7 @@ export class TimeChart {
|
|
|
189
190
|
this.axisLabelsMode = config.axisLabelsMode;
|
|
190
191
|
this.intervalSpanLimit = config.intervalSpanLimit;
|
|
191
192
|
this.dateInterval = this.findDateInterval(config.dateInterval);
|
|
192
|
-
this.dataModel = this.populateModel(scenarios, this.dateInterval
|
|
193
|
+
this.dataModel = this.populateModel(scenarios, this.dateInterval);
|
|
193
194
|
this.variancesDataModel = this.populateVarianceModel(config.variances, this.dataModel);
|
|
194
195
|
this.configTitle = config.title;
|
|
195
196
|
this.configVariances = (_a = config === null || config === void 0 ? void 0 : config.variances) !== null && _a !== void 0 ? _a : [];
|
|
@@ -483,7 +484,7 @@ export class TimeChart {
|
|
|
483
484
|
createI18n(i18n) {
|
|
484
485
|
this.state = FactoryState.DIRTY;
|
|
485
486
|
const defaultI18n = new Map([
|
|
486
|
-
["
|
|
487
|
+
["SEPARATOR_WS", ", "],
|
|
487
488
|
["in", "in"],
|
|
488
489
|
["ORDER_asc", "↑"],
|
|
489
490
|
["ORDER_desc", "↓"],
|
|
@@ -505,7 +506,7 @@ export class TimeChart {
|
|
|
505
506
|
["pl4", "PL4"],
|
|
506
507
|
["category", " "],
|
|
507
508
|
["operation", " "],
|
|
508
|
-
["
|
|
509
|
+
["thereof", "davon"],
|
|
509
510
|
["part_of", "in % von"],
|
|
510
511
|
["ibcssymbol_delta_ac", "Δ{%}"],
|
|
511
512
|
["ibcssymbol_delta_generic", "Δ({%})"],
|
|
@@ -603,12 +604,24 @@ export class TimeChart {
|
|
|
603
604
|
}
|
|
604
605
|
return width;
|
|
605
606
|
}
|
|
607
|
+
/**
|
|
608
|
+
* The styles with each scenario on the bar style slot its colorIndex selects.
|
|
609
|
+
* `this.styles` stays the theme: the hatch pattern is built from its `fc` slot.
|
|
610
|
+
*/
|
|
611
|
+
scenarioStyles() {
|
|
612
|
+
const barStyles = stylesBySlot(this.styles.barStyles, this.ruleSet);
|
|
613
|
+
if (barStyles === this.styles.barStyles) {
|
|
614
|
+
return this.styles;
|
|
615
|
+
}
|
|
616
|
+
return Object.assign(Object.create(Object.getPrototypeOf(this.styles)), this.styles, { barStyles });
|
|
617
|
+
}
|
|
606
618
|
setAxisScenario(scenarios) {
|
|
607
619
|
let result = Scenario.AC1;
|
|
608
620
|
if (scenarios != null && scenarios.length > 0) {
|
|
609
621
|
const axis = new VarianceScenario(scenarios.toString());
|
|
610
622
|
if (axis.isValid) {
|
|
611
|
-
|
|
623
|
+
// the axis is drawn in the look of the slot the reference scenario has
|
|
624
|
+
result = (styleSlot(this.ruleSet.getScenarioColorIndex(axis.delta)) + axis.delta.slice(2));
|
|
612
625
|
}
|
|
613
626
|
}
|
|
614
627
|
if (result === null) {
|
|
@@ -617,7 +630,7 @@ export class TimeChart {
|
|
|
617
630
|
}
|
|
618
631
|
return result;
|
|
619
632
|
}
|
|
620
|
-
populateModel(selectedScenarios, dateInterval
|
|
633
|
+
populateModel(selectedScenarios, dateInterval) {
|
|
621
634
|
if (this.rowCount === 0 || !this.fromExpr) {
|
|
622
635
|
return [];
|
|
623
636
|
}
|
|
@@ -757,6 +770,7 @@ export class TimeChart {
|
|
|
757
770
|
return result;
|
|
758
771
|
}
|
|
759
772
|
createDataRows(result, selectedScenarios) {
|
|
773
|
+
var _a;
|
|
760
774
|
const dataModel = [];
|
|
761
775
|
result.forEach((element, index) => {
|
|
762
776
|
dataModel.push({
|
|
@@ -771,8 +785,21 @@ export class TimeChart {
|
|
|
771
785
|
});
|
|
772
786
|
//}
|
|
773
787
|
});
|
|
788
|
+
for (const entry of dataModel) {
|
|
789
|
+
for (const dataPoint of [entry.scenario1, entry.scenario2, entry.scenario3, entry.scenario4]) {
|
|
790
|
+
// a bucket without a value has a bar of height 0: nothing an annotation can point at
|
|
791
|
+
if (dataPoint.value != null && !Number.isNaN(dataPoint.value)) {
|
|
792
|
+
dataPoint.key = { date: TimeChart.pointDate(entry.date), scenario: (_a = dataPoint.scenario) !== null && _a !== void 0 ? _a : undefined };
|
|
793
|
+
}
|
|
794
|
+
}
|
|
795
|
+
}
|
|
774
796
|
return dataModel;
|
|
775
797
|
}
|
|
798
|
+
/** The bucket a point belongs to. */
|
|
799
|
+
static pointDate(date) {
|
|
800
|
+
var _a;
|
|
801
|
+
return pointDate((_a = date === null || date === void 0 ? void 0 : date.toISO) === null || _a === void 0 ? void 0 : _a.call(date));
|
|
802
|
+
}
|
|
776
803
|
findSmallestDataPointValue(dataModel) {
|
|
777
804
|
const pixel = this.isVarianceChart() ? this.pixelPerPercentage : this.pixelPerUnit;
|
|
778
805
|
let smallestDataPoint = new DataPoint(0, "default", pixel, Scenario.NEU);
|
|
@@ -817,12 +844,19 @@ export class TimeChart {
|
|
|
817
844
|
const directon = scenarios.direction;
|
|
818
845
|
const pixelPerUnit = scenarios.type === "dr" ? this.pixelPerPercentage : this.pixelPerUnit;
|
|
819
846
|
for (const index in dataModel) {
|
|
847
|
+
const point = new DataPoint(this.calculateVariance(scenarios, dataModel[index], scenariomap), scenarios.delta, pixelPerUnit, directon);
|
|
848
|
+
if (point.value !== null && !Number.isNaN(point.value)) {
|
|
849
|
+
point.key = {
|
|
850
|
+
date: TimeChart.pointDate(dataModel[index].date),
|
|
851
|
+
scenario: variancesConfig[varianceScenario],
|
|
852
|
+
};
|
|
853
|
+
}
|
|
820
854
|
varianceModel.push({
|
|
821
855
|
id: Number(index),
|
|
822
856
|
category: dataModel[index].category,
|
|
823
857
|
type: scenarios.type === "dr" ? VarianceType.RELATIVE : VarianceType.ABSOLUTE,
|
|
824
858
|
date: dataModel[index].date,
|
|
825
|
-
scenario1:
|
|
859
|
+
scenario1: point,
|
|
826
860
|
scenario2: new DataPoint(null, null, null, null),
|
|
827
861
|
scenario3: new DataPoint(null, null, null, null),
|
|
828
862
|
scenario4: new DataPoint(null, null, null, null),
|
|
@@ -952,7 +986,7 @@ export class TimeChart {
|
|
|
952
986
|
}
|
|
953
987
|
drawScenarios(dataModel, svgContainer) {
|
|
954
988
|
const columnGroup = svgContainer.group().id("Scenarios");
|
|
955
|
-
const scenarioFactory = new ScenarioFactory(this.position, columnGroup, this.
|
|
989
|
+
const scenarioFactory = new ScenarioFactory(this.position, columnGroup, this.scenarioStyles(), dataModel.length, this.i18n);
|
|
956
990
|
scenarioFactory.setOverflowConfig(this.overflowConfig);
|
|
957
991
|
let hasValidPrim = false;
|
|
958
992
|
dataModel.forEach((elements, index) => {
|
|
@@ -984,7 +1018,7 @@ export class TimeChart {
|
|
|
984
1018
|
const lineGroup = svgContainer.group().id("LineScenarios");
|
|
985
1019
|
// Create collision manager for label overlap detection across all line series
|
|
986
1020
|
const collisionManager = new LabelCollisionManager();
|
|
987
|
-
const scenarioFactory = new ScenarioFactory(this.position, lineGroup, this.
|
|
1021
|
+
const scenarioFactory = new ScenarioFactory(this.position, lineGroup, this.scenarioStyles(), dataModel.length, this.i18n);
|
|
988
1022
|
scenarioFactory.setCollisionManager(collisionManager);
|
|
989
1023
|
// Collect data points for each scenario
|
|
990
1024
|
const slotDefaults = ["ac1", "pp1", "fc1", "pl1"];
|
|
@@ -1017,7 +1051,7 @@ export class TimeChart {
|
|
|
1017
1051
|
// Create LineSeries in z-order (SVG group creation order = render order)
|
|
1018
1052
|
const seriesList = [];
|
|
1019
1053
|
for (const scenario of scenarios) {
|
|
1020
|
-
const series = scenarioFactory.createLineSeries(scenario.points, scenario.scenarioName);
|
|
1054
|
+
const series = scenarioFactory.createLineSeries(scenario.points, scenario.scenarioName, styleSlot(this.ruleSet.getScenarioColorIndex(scenario.scenarioName)));
|
|
1021
1055
|
seriesList.push({ series, scenarioType: scenario.scenarioType });
|
|
1022
1056
|
}
|
|
1023
1057
|
// Phase 1: Draw geometry (groups already in correct z-order from creation)
|
|
@@ -1147,7 +1181,7 @@ export class TimeChart {
|
|
|
1147
1181
|
}
|
|
1148
1182
|
drawVarianceScenario(dataModel, svgContainer) {
|
|
1149
1183
|
const columnGroup = svgContainer.group().id("Scenarios");
|
|
1150
|
-
const scenarioFactory = new ScenarioFactory(this.position, columnGroup, this.
|
|
1184
|
+
const scenarioFactory = new ScenarioFactory(this.position, columnGroup, this.scenarioStyles(), dataModel.length, this.i18n);
|
|
1151
1185
|
scenarioFactory.setOverflowConfig(this.overflowConfig);
|
|
1152
1186
|
dataModel.forEach((elements, index) => {
|
|
1153
1187
|
if (elements["type"] === VarianceType.RELATIVE) {
|
|
@@ -1266,7 +1300,11 @@ export class TimeChart {
|
|
|
1266
1300
|
lastColumn = column;
|
|
1267
1301
|
});
|
|
1268
1302
|
if (lastColumn && group.hasValue) {
|
|
1269
|
-
|
|
1303
|
+
// an overlay has one total per scenario family: the family tells them apart
|
|
1304
|
+
lastColumn.drawTotalLabel(this.dataFormatDigits, this.measureScale, {
|
|
1305
|
+
date: TimeChart.pointDate(elements.date),
|
|
1306
|
+
scenario: groups.length > 1 ? group.prefix : undefined,
|
|
1307
|
+
});
|
|
1270
1308
|
}
|
|
1271
1309
|
});
|
|
1272
1310
|
});
|
|
@@ -1383,7 +1421,9 @@ export class TimeChart {
|
|
|
1383
1421
|
for (let layerIdx = 0; layerIdx < activeLayers.length; layerIdx++) {
|
|
1384
1422
|
const upperPoints = toAreaPoints(layerIdx, "end");
|
|
1385
1423
|
const lowerPoints = toAreaPoints(layerIdx, "start");
|
|
1386
|
-
const scenarioType = isScenarioStack
|
|
1424
|
+
const scenarioType = isScenarioStack
|
|
1425
|
+
? styleSlot(this.ruleSet.getScenarioColorIndex(layerScenarios[layerIdx]))
|
|
1426
|
+
: null;
|
|
1387
1427
|
const areaFill = new AreaFill(areaGroup, upperPoints, lowerPoints, scenarioType, layerIdx, isScenarioStack);
|
|
1388
1428
|
areaFill.draw();
|
|
1389
1429
|
areaFill.drawBoundaryLine();
|
|
@@ -1400,7 +1440,7 @@ export class TimeChart {
|
|
|
1400
1440
|
return;
|
|
1401
1441
|
}
|
|
1402
1442
|
const overlayGroup = svgContainer.group().id("Overlay");
|
|
1403
|
-
const scenarioFactory = new ScenarioFactory(this.position, overlayGroup, this.
|
|
1443
|
+
const scenarioFactory = new ScenarioFactory(this.position, overlayGroup, this.scenarioStyles(), dataModel.length, this.i18n);
|
|
1404
1444
|
if (this.showOverlayAvg === true) {
|
|
1405
1445
|
let previousDataPoint = null;
|
|
1406
1446
|
const avgDataModel = tranformToAvgDataModel(dataModel);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { HookLocation, Label } from "./Label";
|
|
2
2
|
import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
3
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
3
4
|
// import { DataFormatDigits } from "../../../../utils/model/DataFormatDigits";
|
|
4
5
|
// import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
5
6
|
/**
|
|
@@ -69,6 +70,7 @@ export class Column {
|
|
|
69
70
|
return this;
|
|
70
71
|
}
|
|
71
72
|
draw(dataFormatDigits = { percent: 2, decimal: 1 }, measureScale = new SiPrefix()) {
|
|
73
|
+
var _a;
|
|
72
74
|
// TODE: JHE: Remove DataFOrmatDigits Type Duplicates
|
|
73
75
|
if (this.isEmpty()) {
|
|
74
76
|
return this;
|
|
@@ -76,6 +78,8 @@ export class Column {
|
|
|
76
78
|
const scenarioStyle = this.getScenarioStyle();
|
|
77
79
|
const strokeStyle = this.convertToSVGStyle(scenarioStyle, "stroke");
|
|
78
80
|
const fillStyle = this.getFillStyle(scenarioStyle);
|
|
81
|
+
this.scenarioGroup.attr(dataPointAttributes(this.dataPoint.key));
|
|
82
|
+
(_a = this.columnGroup) === null || _a === void 0 ? void 0 : _a.attr(dataPointAttributes(this.dataPoint.key, "element"));
|
|
79
83
|
if (this.columnGroup != null) {
|
|
80
84
|
if (this.isOverflowing && this.overflowConfig) {
|
|
81
85
|
this.drawOverdriveBar(fillStyle, strokeStyle);
|
|
@@ -219,7 +223,7 @@ export class Column {
|
|
|
219
223
|
const labelY = this.isOverflowing
|
|
220
224
|
? this.dimensions.labelYPos
|
|
221
225
|
: this.position.getColumnDataLabelPositionY(this.dataPoint.getScaledUnit());
|
|
222
|
-
return new Label(this.scenarioGroup, this.position.getColumnCenterPositionX(this.index), labelY, this.ID_DATA_PREFIX, dataPoint.value, this.styles, labelHook, HookLocation.Center);
|
|
226
|
+
return new Label(this.scenarioGroup, this.position.getColumnCenterPositionX(this.index), labelY, this.ID_DATA_PREFIX, dataPoint.value, this.styles, labelHook, HookLocation.Center).setPoint(dataPoint.key);
|
|
223
227
|
}
|
|
224
228
|
getScenarioLabel(columnLabel) {
|
|
225
229
|
if (this.isPrimaryColumn) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
2
2
|
import { Formatter } from "../../../../utils";
|
|
3
3
|
import { getContrastTextColor } from "../../../../utils/stackColors";
|
|
4
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
4
5
|
// import { DataFormatDigits } from "../../../../utils/model/DataFormatDigits";
|
|
5
6
|
// import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
6
7
|
/**
|
|
@@ -36,6 +37,7 @@ export class Label {
|
|
|
36
37
|
this.CSS_CATEGORIES = "categories";
|
|
37
38
|
this.isRelativeLabel = false;
|
|
38
39
|
this.segmentFillColor = null;
|
|
40
|
+
this.pointPart = "label";
|
|
39
41
|
this.x = xPosition;
|
|
40
42
|
this.y = yPosition;
|
|
41
43
|
this.value = value;
|
|
@@ -58,6 +60,12 @@ export class Label {
|
|
|
58
60
|
this.segmentFillColor = color;
|
|
59
61
|
return this;
|
|
60
62
|
}
|
|
63
|
+
/** The data row this label belongs to. Written on the label group when the label is visible. */
|
|
64
|
+
setPoint(key, part = "label") {
|
|
65
|
+
this.pointKey = key;
|
|
66
|
+
this.pointPart = part;
|
|
67
|
+
return this;
|
|
68
|
+
}
|
|
61
69
|
updateGroup(newGroup) {
|
|
62
70
|
this.group = newGroup;
|
|
63
71
|
return this;
|
|
@@ -96,6 +104,9 @@ export class Label {
|
|
|
96
104
|
text.addClass("hide");
|
|
97
105
|
label.addClass("hide");
|
|
98
106
|
}
|
|
107
|
+
else if (this.pointKey) {
|
|
108
|
+
label.attr(dataPointAttributes(this.pointKey, this.pointPart));
|
|
109
|
+
}
|
|
99
110
|
return this;
|
|
100
111
|
}
|
|
101
112
|
isEmpty() {
|
|
@@ -110,6 +121,9 @@ export class Label {
|
|
|
110
121
|
const label = this.group;
|
|
111
122
|
const labelStr = "" + this.value;
|
|
112
123
|
this.drawLabel(label, labelStr);
|
|
124
|
+
if (this.pointKey) {
|
|
125
|
+
label.attr(dataPointAttributes(this.pointKey, this.pointPart));
|
|
126
|
+
}
|
|
113
127
|
return this;
|
|
114
128
|
}
|
|
115
129
|
drawLabel(label, labelStr) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { HookLocation, Label } from "./Label";
|
|
2
2
|
import { LabelDirection } from "../helper/LabelCollisionManager";
|
|
3
3
|
import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
4
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
4
5
|
const IBCS_LINE_STYLES = {
|
|
5
6
|
ac: { markerFill: "#000000", markerStroke: "#000000", lineColor: "#000000" },
|
|
6
7
|
pp: { markerFill: "#999999", markerStroke: "#999999", lineColor: "#999999" },
|
|
@@ -8,7 +9,10 @@ const IBCS_LINE_STYLES = {
|
|
|
8
9
|
pl: { markerFill: "#ffffff", markerStroke: "#000000", lineColor: "#000000" },
|
|
9
10
|
};
|
|
10
11
|
export class LineSeries {
|
|
11
|
-
constructor(position, styles, dataPoints, scenarioGroup, labelGroup, scenarioName, scenarioLabel, _i18n, collisionManager = null
|
|
12
|
+
constructor(position, styles, dataPoints, scenarioGroup, labelGroup, scenarioName, scenarioLabel, _i18n, collisionManager = null,
|
|
13
|
+
/** Style slot (ac, pp, fc, pl) of the line. Without it the scenario name decides. */
|
|
14
|
+
lineSlot) {
|
|
15
|
+
this.lineSlot = lineSlot;
|
|
12
16
|
this.MARKER_SIZE = 8;
|
|
13
17
|
this.LINE_WIDTH = 2;
|
|
14
18
|
this.ID_LINE_PREFIX = "LINE";
|
|
@@ -59,8 +63,8 @@ export class LineSeries {
|
|
|
59
63
|
return this;
|
|
60
64
|
}
|
|
61
65
|
getLineStyle() {
|
|
62
|
-
var _a, _b;
|
|
63
|
-
const scenarioType = ((
|
|
66
|
+
var _a, _b, _c;
|
|
67
|
+
const scenarioType = (_a = this.lineSlot) !== null && _a !== void 0 ? _a : (((_c = (_b = this.scenarioName) === null || _b === void 0 ? void 0 : _b.slice(0, 2)) === null || _c === void 0 ? void 0 : _c.toLowerCase()) || "ac");
|
|
64
68
|
return IBCS_LINE_STYLES[scenarioType] || IBCS_LINE_STYLES.ac;
|
|
65
69
|
}
|
|
66
70
|
/**
|
|
@@ -77,7 +81,7 @@ export class LineSeries {
|
|
|
77
81
|
*/
|
|
78
82
|
drawSquareMarker(group, cx, cy, style) {
|
|
79
83
|
const halfSize = this.MARKER_SIZE / 2;
|
|
80
|
-
group
|
|
84
|
+
return group
|
|
81
85
|
.rect(this.MARKER_SIZE, this.MARKER_SIZE)
|
|
82
86
|
.fill(style.markerFill)
|
|
83
87
|
.stroke({ color: style.markerStroke, width: 1 })
|
|
@@ -87,7 +91,7 @@ export class LineSeries {
|
|
|
87
91
|
* Draws a circle marker (variant 2: ac2, pp2, fc2, pl2)
|
|
88
92
|
*/
|
|
89
93
|
drawCircleMarker(group, cx, cy, style) {
|
|
90
|
-
group
|
|
94
|
+
return group
|
|
91
95
|
.circle(this.MARKER_SIZE)
|
|
92
96
|
.fill(style.markerFill)
|
|
93
97
|
.stroke({ color: style.markerStroke, width: 1 })
|
|
@@ -98,7 +102,7 @@ export class LineSeries {
|
|
|
98
102
|
*/
|
|
99
103
|
drawTriangleMarker(group, cx, cy, style) {
|
|
100
104
|
const s = this.MARKER_SIZE / 2;
|
|
101
|
-
group
|
|
105
|
+
return group
|
|
102
106
|
.polygon(`${cx},${cy - s} ${cx - s},${cy + s} ${cx + s},${cy + s}`)
|
|
103
107
|
.fill(style.markerFill)
|
|
104
108
|
.stroke({ color: style.markerStroke, width: 1 });
|
|
@@ -108,7 +112,7 @@ export class LineSeries {
|
|
|
108
112
|
*/
|
|
109
113
|
drawDiamondMarker(group, cx, cy, style) {
|
|
110
114
|
const s = this.MARKER_SIZE / 2;
|
|
111
|
-
group
|
|
115
|
+
return group
|
|
112
116
|
.polygon(`${cx},${cy - s} ${cx + s},${cy} ${cx},${cy + s} ${cx - s},${cy}`)
|
|
113
117
|
.fill(style.markerFill)
|
|
114
118
|
.stroke({ color: style.markerStroke, width: 1 });
|
|
@@ -152,20 +156,22 @@ export class LineSeries {
|
|
|
152
156
|
const centerX = this.position.getColumnCenterPositionX(point.index);
|
|
153
157
|
const centerY = this.position.getColumnPositionY() - point.dataPoint.getScaledUnit();
|
|
154
158
|
// Draw marker shape based on scenario variant
|
|
159
|
+
let marker;
|
|
155
160
|
switch (variant) {
|
|
156
161
|
case 2:
|
|
157
|
-
this.drawCircleMarker(markerGroup, centerX, centerY, lineStyle);
|
|
162
|
+
marker = this.drawCircleMarker(markerGroup, centerX, centerY, lineStyle);
|
|
158
163
|
break;
|
|
159
164
|
case 3:
|
|
160
|
-
this.drawTriangleMarker(markerGroup, centerX, centerY, lineStyle);
|
|
165
|
+
marker = this.drawTriangleMarker(markerGroup, centerX, centerY, lineStyle);
|
|
161
166
|
break;
|
|
162
167
|
case 4:
|
|
163
|
-
this.drawDiamondMarker(markerGroup, centerX, centerY, lineStyle);
|
|
168
|
+
marker = this.drawDiamondMarker(markerGroup, centerX, centerY, lineStyle);
|
|
164
169
|
break;
|
|
165
170
|
default: // variant 1 or unknown
|
|
166
|
-
this.drawSquareMarker(markerGroup, centerX, centerY, lineStyle);
|
|
171
|
+
marker = this.drawSquareMarker(markerGroup, centerX, centerY, lineStyle);
|
|
167
172
|
break;
|
|
168
173
|
}
|
|
174
|
+
marker.attr(dataPointAttributes(point.dataPoint.key, "element")).attr("data-bn-index", String(point.index));
|
|
169
175
|
}
|
|
170
176
|
}
|
|
171
177
|
/**
|
|
@@ -233,7 +239,7 @@ export class LineSeries {
|
|
|
233
239
|
this.collisionManager.register(bounds);
|
|
234
240
|
}
|
|
235
241
|
const label = new Label(this.labelGroup, labelX, labelY, this.ID_LABEL_PREFIX, point.dataPoint.value, this.styles, verticalHook, horizontalHook);
|
|
236
|
-
label.draw(true, dataFormatDigits, measureScale);
|
|
242
|
+
label.setPoint(point.dataPoint.key).draw(true, dataFormatDigits, measureScale);
|
|
237
243
|
}
|
|
238
244
|
}
|
|
239
245
|
drawScenarioLabel() {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { HookLocation, Label } from "./Label";
|
|
2
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
2
3
|
/**
|
|
3
4
|
* Renders a diamond/triangle marker indicator for PP or PL reference values in a time chart.
|
|
4
5
|
*
|
|
@@ -34,6 +35,7 @@ export class Marker {
|
|
|
34
35
|
this.scenario = scenario;
|
|
35
36
|
if ((dataPoint === null || dataPoint === void 0 ? void 0 : dataPoint.isEmpty()) !== true) {
|
|
36
37
|
this.hasData = true;
|
|
38
|
+
this.pointKey = dataPoint.key;
|
|
37
39
|
this.dimensions = this.createMarkerDimensions(dataPoint, index, isPrimaryMarker);
|
|
38
40
|
this.scenarioLabel = this.getScenarioLabel(labelText, styles, isPrimaryMarker);
|
|
39
41
|
}
|
|
@@ -52,6 +54,7 @@ export class Marker {
|
|
|
52
54
|
fillStyle = polygonPattern.pattern;
|
|
53
55
|
}
|
|
54
56
|
}
|
|
57
|
+
this.markerGroup.attr(dataPointAttributes(this.pointKey));
|
|
55
58
|
this.markerGroup
|
|
56
59
|
.polygon(this.markerPattern.background)
|
|
57
60
|
.fill(whiteBorder)
|
|
@@ -62,7 +65,8 @@ export class Marker {
|
|
|
62
65
|
.fill(fillStyle)
|
|
63
66
|
.stroke(strokeStyle)
|
|
64
67
|
.cy(this.dimensions.yPos - this.dimensions.columnLength)
|
|
65
|
-
.cx(this.dimensions.xPos)
|
|
68
|
+
.cx(this.dimensions.xPos)
|
|
69
|
+
.attr(dataPointAttributes(this.pointKey, "element"));
|
|
66
70
|
if (this.scenarioLabel != null && !this.scenarioLabel.isEmpty()) {
|
|
67
71
|
this.scenarioLabel.setPos(this.dimensions.scenarioLabelXPos, this.dimensions.scenarioLabelYPos).draw();
|
|
68
72
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { HookLocation, Label } from "./Label";
|
|
2
2
|
import { NOT_AVAILABLE } from "../../../../utils/relativeVariance";
|
|
3
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
3
4
|
// import {SVGVariancesStyleGroup} from "../../../../utils/model/styles/SVGVariancesStyleGroup";
|
|
4
5
|
/**
|
|
5
6
|
* Renders a relative variance pin (needle) in an IBCS time chart.
|
|
@@ -42,7 +43,7 @@ export class Needle {
|
|
|
42
43
|
this.hasData = true;
|
|
43
44
|
this.dimensions = this.createDimensions(position, dataPoint, index);
|
|
44
45
|
this.dataLabel = new Label(this.scenarioGroup, this.position.getColumnCenterPositionX(this.index), this.position.getNeedleDataLabelPositionY(this.dataPoint.getScaledPercentUnit()), this.ID_DATA_PREFIX, notAvailable ? NOT_AVAILABLE : dataPoint.value, this.styles, HookLocation.Center, HookLocation.Center);
|
|
45
|
-
this.dataLabel.setToRelativeVarianceLabel();
|
|
46
|
+
this.dataLabel.setToRelativeVarianceLabel().setPoint(dataPoint.key);
|
|
46
47
|
}
|
|
47
48
|
}
|
|
48
49
|
updateLabelGroup(newGroup) {
|
|
@@ -63,6 +64,8 @@ export class Needle {
|
|
|
63
64
|
if (this.isEmpty()) {
|
|
64
65
|
return this;
|
|
65
66
|
}
|
|
67
|
+
this.scenarioGroup.attr(dataPointAttributes(this.dataPoint.key));
|
|
68
|
+
this.barGroup.attr(dataPointAttributes(this.dataPoint.key, "element"));
|
|
66
69
|
const scenarioStyle = this.styles.varianceStyles[this.dataPoint.getVarianceStyle()];
|
|
67
70
|
const strokeStyle = this.convertToSVGStyle(scenarioStyle, "stroke");
|
|
68
71
|
let fillStyle = this.convertToSVGStyle(scenarioStyle, "fill");
|
|
@@ -2,6 +2,7 @@ import { HookLocation, Label } from "./Label";
|
|
|
2
2
|
import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
3
3
|
import { StackMode } from "../../../../utils/constants";
|
|
4
4
|
import { Formatter } from "../../../../utils/formatter";
|
|
5
|
+
import { dataPointAttributes } from "../../../../utils/layoutState/dataPoint";
|
|
5
6
|
/**
|
|
6
7
|
* Renders a single segment within a stacked bar column in a time chart.
|
|
7
8
|
*
|
|
@@ -50,6 +51,7 @@ export class StackedColumn {
|
|
|
50
51
|
const fillColor = colors[this.segmentIndex % colors.length];
|
|
51
52
|
const fillStyle = { color: fillColor };
|
|
52
53
|
const strokeStyle = { color: fillColor, width: 0.5 };
|
|
54
|
+
this.columnGroup.attr(dataPointAttributes(this.dataPoint.key, "element"));
|
|
53
55
|
// Draw rectangle
|
|
54
56
|
this.columnGroup
|
|
55
57
|
.rect(columnWidth, Math.max(segmentHeight, 0.5))
|
|
@@ -65,12 +67,14 @@ export class StackedColumn {
|
|
|
65
67
|
const labelValue = Formatter.number(this.segment.share, "percent", dataFormatDigits.percent, dataFormatDigits.percent, 1, this.styles.locale);
|
|
66
68
|
new Label(this.group, xPos, labelY, "STACK_SEG", labelValue, this.styles, HookLocation.Center, HookLocation.Center)
|
|
67
69
|
.setSegmentFill(fillColor)
|
|
70
|
+
.setPoint(this.dataPoint.key)
|
|
68
71
|
.forceStringTypeDraw();
|
|
69
72
|
}
|
|
70
73
|
else {
|
|
71
74
|
// Pass raw numeric value - Label.draw() formats with measureScale
|
|
72
75
|
new Label(this.group, xPos, labelY, "STACK_SEG", value, this.styles, HookLocation.Center, HookLocation.Center)
|
|
73
76
|
.setSegmentFill(fillColor)
|
|
77
|
+
.setPoint(this.dataPoint.key)
|
|
74
78
|
.draw(true, dataFormatDigits, measureScale);
|
|
75
79
|
}
|
|
76
80
|
}
|
|
@@ -78,7 +82,7 @@ export class StackedColumn {
|
|
|
78
82
|
/**
|
|
79
83
|
* Draw the signed total of the stack: above the positive side, or below the negative side for a negative total.
|
|
80
84
|
*/
|
|
81
|
-
drawTotalLabel(dataFormatDigits = { percent: 2, decimal: 1 }, measureScale = new SiPrefix()) {
|
|
85
|
+
drawTotalLabel(dataFormatDigits = { percent: 2, decimal: 1 }, measureScale = new SiPrefix(), key) {
|
|
82
86
|
if (this.stackMode === StackMode.RELATIVE) {
|
|
83
87
|
// Don't show total for 100% stacked (always 100%)
|
|
84
88
|
return;
|
|
@@ -89,6 +93,6 @@ export class StackedColumn {
|
|
|
89
93
|
const xPos = this.position.getColumnCenterPositionX(this.index);
|
|
90
94
|
const labelY = this.position.getColumnDataLabelPositionY(end * this.dataPoint.pixelPerUnit);
|
|
91
95
|
const label = new Label(this.group, xPos, labelY, "STACK_TOTAL", this.stack.total, this.styles, isNegative ? HookLocation.Top : HookLocation.Bottom, HookLocation.Center);
|
|
92
|
-
label.draw(true, dataFormatDigits, measureScale);
|
|
96
|
+
label.setPoint(key, "total").draw(true, dataFormatDigits, measureScale);
|
|
93
97
|
}
|
|
94
98
|
}
|
|
@@ -136,11 +136,11 @@ export class ScenarioFactory {
|
|
|
136
136
|
moveLabelsToFront() {
|
|
137
137
|
this.svgGroups.scenario1Label.front();
|
|
138
138
|
}
|
|
139
|
-
createLineSeries(dataPoints, scenarioName) {
|
|
139
|
+
createLineSeries(dataPoints, scenarioName, lineSlot) {
|
|
140
140
|
const lineSeriesGroup = this.svgGroups.parent.group().id("LineSeries_" + scenarioName);
|
|
141
141
|
const labelGroup = this.svgGroups.scenario1Label.group().id("LineSeries_Label_" + scenarioName);
|
|
142
142
|
// Scenario label for the line (to be shown at the right of the last data point)
|
|
143
143
|
const scenarioLabel = `${this.i18n.get(scenarioName) || scenarioName}`;
|
|
144
|
-
return new LineSeries(this.position, this.styles, dataPoints, lineSeriesGroup, labelGroup, scenarioName, scenarioLabel, this.i18n, this.collisionManager);
|
|
144
|
+
return new LineSeries(this.position, this.styles, dataPoints, lineSeriesGroup, labelGroup, scenarioName, scenarioLabel, this.i18n, this.collisionManager, lineSlot);
|
|
145
145
|
}
|
|
146
146
|
}
|
|
@@ -3,13 +3,11 @@
|
|
|
3
3
|
// import { StringAdapter } from "../../../../utils/helper/StringAdapter";
|
|
4
4
|
// import { Order, OrderAdapter } from "../../../../utils/model/Order";
|
|
5
5
|
// import { AdapterUtils } from "../../../../utils/helper/AdapterUtils";
|
|
6
|
-
import {
|
|
6
|
+
import { AxisLabelsMode, ChartMode } from "../../../../utils/constants";
|
|
7
7
|
import { DataAnalyzer } from "../../../../utils/dataAnalyzer";
|
|
8
8
|
import { DateDistance } from "../../../../utils/DateStringFactory";
|
|
9
9
|
import { AdapterUtils } from "../../../../utils/helper/AdapterUtils";
|
|
10
10
|
import { CompareUtil } from "../../../../utils/helper/CompareUtil";
|
|
11
|
-
import { StringAdapter } from "../../../../utils/helper/StringAdapter";
|
|
12
|
-
import { OrderAdapter } from "../../../../utils/model/Order";
|
|
13
11
|
import { SiPrefix } from "../../../../utils/model/SiPrefix";
|
|
14
12
|
/**
|
|
15
13
|
* Configuration for an IBCS time-series chart component.
|
|
@@ -29,10 +27,6 @@ export class TimeChartComponentConfig {
|
|
|
29
27
|
this.pixelPerUnit = 10;
|
|
30
28
|
/** Vertical scale factor for percentage variances: pixels per 1.0 (=100%). */
|
|
31
29
|
this.pixelPerPercentage = 50;
|
|
32
|
-
/** Maximum data points to display; 0 means unlimited. */
|
|
33
|
-
this.limit = 0;
|
|
34
|
-
this.sortOrder = new OrderAdapter(new StringAdapter()).default();
|
|
35
|
-
this.level = AggregationLevel.CATEGORY;
|
|
36
30
|
/** Pixel offset from left edge for horizontal alignment across multiple charts. -1 disables sync. */
|
|
37
31
|
this.leftSideOffsetForHorizontalSync = -1;
|
|
38
32
|
/** Date granularity (year, quarter, month, etc.). AUTO auto-detects from data. */
|
|
@@ -64,9 +58,8 @@ export class TimeChartComponentConfig {
|
|
|
64
58
|
* Reads from the shared alasql database for measure-scale auto-calculation.
|
|
65
59
|
*/
|
|
66
60
|
export class TimeChartComponentConfigAdapter {
|
|
67
|
-
constructor(dataRowAdapter,
|
|
61
|
+
constructor(dataRowAdapter, stringAdapter, dataFormatDigitsAdapter, db, fromExpr, onQueryError) {
|
|
68
62
|
this.dataRowAdapter = dataRowAdapter;
|
|
69
|
-
this.orderAdapter = orderAdapter;
|
|
70
63
|
this.stringAdapter = stringAdapter;
|
|
71
64
|
this.dataFormatDigitsAdapter = dataFormatDigitsAdapter;
|
|
72
65
|
this.db = db;
|
|
@@ -92,15 +85,6 @@ export class TimeChartComponentConfigAdapter {
|
|
|
92
85
|
if (CompareUtil.isNumber(data.pixelPerPercentage)) {
|
|
93
86
|
config.pixelPerPercentage = data.pixelPerPercentage;
|
|
94
87
|
}
|
|
95
|
-
if (CompareUtil.isNumber(data.limit)) {
|
|
96
|
-
config.limit = data.limit;
|
|
97
|
-
}
|
|
98
|
-
if (CompareUtil.isExisting(data.sortOrder)) {
|
|
99
|
-
config.sortOrder = this.orderAdapter.adapt(data.sortOrder);
|
|
100
|
-
}
|
|
101
|
-
if (CompareUtil.isExisting(data.level)) {
|
|
102
|
-
config.level = data.level;
|
|
103
|
-
}
|
|
104
88
|
if (CompareUtil.isExisting(data.dateInterval)) {
|
|
105
89
|
config.dateInterval = data.dateInterval;
|
|
106
90
|
}
|
|
@@ -16,7 +16,7 @@ export class ComponentStyle {
|
|
|
16
16
|
const parsedData = JSON.parse(data);
|
|
17
17
|
// @ts-ignore
|
|
18
18
|
this.stores.componentStyles.set(this.name, parsedData);
|
|
19
|
-
this.errors.remove("
|
|
19
|
+
this.errors.remove("ERR_body");
|
|
20
20
|
const unknown = unknownStyleKeys(parsedData);
|
|
21
21
|
if (unknown.length > 0) {
|
|
22
22
|
this.errors.addOrReplace({
|
|
@@ -31,7 +31,7 @@ export class ComponentStyle {
|
|
|
31
31
|
}
|
|
32
32
|
catch (e) {
|
|
33
33
|
this.errors.addOrReplace({
|
|
34
|
-
id: "
|
|
34
|
+
id: "ERR_body",
|
|
35
35
|
type: "error",
|
|
36
36
|
message: `bn-component-style: Failed to parse JSON body - ${e.message}`,
|
|
37
37
|
});
|
|
@@ -40,7 +40,7 @@ export class ComponentStyle {
|
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
42
|
render() {
|
|
43
|
-
return h(Host, { key: '
|
|
43
|
+
return h(Host, { key: '443fd52bc75e267b8699e29f754a15130f444315' });
|
|
44
44
|
}
|
|
45
45
|
static get is() { return "bn-component-style"; }
|
|
46
46
|
static get originalStyleUrls() {
|
|
@@ -27,10 +27,10 @@ const read = (element, property, attribute) => {
|
|
|
27
27
|
return property in element ? null : element.getAttribute(attribute);
|
|
28
28
|
};
|
|
29
29
|
/** Every visual bn-* component; non-visual producers (bn-dataset, ...) are excluded. */
|
|
30
|
-
const VISUAL_SELECTOR = "bn-body, bn-card, bn-chart-bubble, bn-chart-bullet, bn-chart-scatter, " +
|
|
30
|
+
const VISUAL_SELECTOR = "bn-annotation-layer, bn-annotation-list, bn-body, bn-card, bn-chart-bubble, bn-chart-bullet, bn-chart-scatter, " +
|
|
31
31
|
"bn-chart-structure, bn-chart-time, bn-footer, bn-grid, bn-image, " +
|
|
32
32
|
"bn-layout-card, bn-layout-page, bn-message, bn-page, bn-table, " +
|
|
33
|
-
"bn-
|
|
33
|
+
"bn-text, bn-title, bn-tree";
|
|
34
34
|
export class Context {
|
|
35
35
|
constructor() {
|
|
36
36
|
/** The page numbers this context wrote. A number that is not in here was set by the author and is left alone. */
|
|
@@ -82,11 +82,11 @@ export class Context {
|
|
|
82
82
|
target.setAttribute("page-number", number);
|
|
83
83
|
});
|
|
84
84
|
const renderOrientation = this.element.getAttribute("render-orientation");
|
|
85
|
-
if (this.
|
|
85
|
+
if (this.lastRenderOrientation !== undefined && this.lastRenderOrientation !== renderOrientation) {
|
|
86
86
|
// a layout page reads the attribute while it renders
|
|
87
87
|
pages.filter((page) => page.localName === "bn-layout-page").forEach((page) => forceUpdate(page));
|
|
88
88
|
}
|
|
89
|
-
this.
|
|
89
|
+
this.lastRenderOrientation = renderOrientation;
|
|
90
90
|
this.writePageSize(pages[0], renderOrientation);
|
|
91
91
|
}
|
|
92
92
|
/**
|
|
@@ -191,7 +191,7 @@ export class Context {
|
|
|
191
191
|
componentWillUpdate() { }
|
|
192
192
|
componentDidUpdate() { }
|
|
193
193
|
render() {
|
|
194
|
-
return (h(Host, { key: '
|
|
194
|
+
return (h(Host, { key: 'a50946d9cb100a1644a2c758af7854900826c5ce' }, h("slot", { key: 'c02525871433af7bb15f39c62c1417365a28d931' })));
|
|
195
195
|
}
|
|
196
196
|
static get is() { return "bn-context"; }
|
|
197
197
|
static get encapsulation() { return "shadow"; }
|
|
@@ -244,6 +244,25 @@ export class Context {
|
|
|
244
244
|
"setter": false,
|
|
245
245
|
"reflect": true,
|
|
246
246
|
"attribute": "i18n-namespace"
|
|
247
|
+
},
|
|
248
|
+
"renderOrientation": {
|
|
249
|
+
"type": "string",
|
|
250
|
+
"mutable": false,
|
|
251
|
+
"complexType": {
|
|
252
|
+
"original": "\"landscape\" | \"portrait\"",
|
|
253
|
+
"resolved": "\"landscape\" | \"portrait\"",
|
|
254
|
+
"references": {}
|
|
255
|
+
},
|
|
256
|
+
"required": false,
|
|
257
|
+
"optional": true,
|
|
258
|
+
"docs": {
|
|
259
|
+
"tags": [],
|
|
260
|
+
"text": "Orientation of the sheets the document is printed on: `landscape` or\n`portrait`. A `<bn-layout-page>` with the other orientation is turned\nonto the sheet. Without it no page is turned."
|
|
261
|
+
},
|
|
262
|
+
"getter": false,
|
|
263
|
+
"setter": false,
|
|
264
|
+
"reflect": true,
|
|
265
|
+
"attribute": "render-orientation"
|
|
247
266
|
}
|
|
248
267
|
};
|
|
249
268
|
}
|