@bino-bi/bn-template-engine 1.0.0-next.26 → 1.0.0-next.28

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.
Files changed (420) hide show
  1. package/dist/bn-template-engine/bn-template-engine.esm.js +1 -1
  2. package/dist/bn-template-engine/p-5075771a.entry.js +1 -0
  3. package/dist/bn-template-engine/p-5d516435.entry.js +1 -0
  4. package/dist/bn-template-engine/p-5e90e728.entry.js +1 -0
  5. package/dist/bn-template-engine/p-9ef7e132.entry.js +1 -0
  6. package/dist/bn-template-engine/{p-f06c3703.entry.js → p-9f7a1980.entry.js} +1 -1
  7. package/dist/bn-template-engine/p-BeXgxHkW.js +1 -0
  8. package/dist/bn-template-engine/p-CH0bpt_k.js +1 -0
  9. package/dist/bn-template-engine/p-ClruFZD_.js +1 -0
  10. package/dist/bn-template-engine/{p-CTrNbSXN.js → p-DFmSrSnf.js} +1 -1
  11. package/dist/bn-template-engine/{p-BcLsoDrW.js → p-DI3efDSV.js} +1 -1
  12. package/dist/bn-template-engine/p-DXLTTILG.js +1 -0
  13. package/dist/bn-template-engine/p-DtP4jqG5.js +1 -0
  14. package/dist/bn-template-engine/p-a8281b71.entry.js +1 -0
  15. package/dist/bn-template-engine/p-b31277e7.entry.js +1 -0
  16. package/dist/bn-template-engine/p-b396ac84.entry.js +1 -0
  17. package/dist/cjs/{bn-asset_21.cjs.entry.js → bn-asset_28.cjs.entry.js} +21358 -6528
  18. package/dist/cjs/bn-grid.cjs.entry.js +4 -6
  19. package/dist/cjs/bn-image.cjs.entry.js +3 -5
  20. package/dist/cjs/bn-internationalization.cjs.entry.js +17 -6
  21. package/dist/cjs/bn-ruleset.cjs.entry.js +5 -5
  22. package/dist/cjs/bn-template-engine.cjs.js +1 -1
  23. package/dist/cjs/bn-template.cjs.entry.js +2 -2
  24. package/dist/cjs/bn-text.cjs.entry.js +115 -43
  25. package/dist/cjs/{context-protocol-DcTEh1rq.js → context-protocol-C0rKepqu.js} +108 -22
  26. package/dist/cjs/{diagnostics-CTgbq_Gc.js → diagnostics-Cq-qDtXq.js} +1 -1
  27. package/dist/cjs/editor-companion.cjs.entry.js +2 -2
  28. package/dist/cjs/loader.cjs.js +1 -1
  29. package/dist/cjs/queryError-BZjnIW_w.js +16 -0
  30. package/dist/cjs/{scaling-Dsb5_NXy.js → sanitizeHtml-Yx1xn6i_.js} +467 -287
  31. package/dist/cjs/{withBodyObserver-DJO98AJ-.js → withBodyObserver-CaPUjuC5.js} +1 -1
  32. package/dist/cjs/withHasError-qGW_yqIv.js +426 -0
  33. package/dist/cjs/{withStyled-D0jLwCib.js → withStyled-vSfogp9J.js} +543 -42
  34. package/dist/collection/components/bn-chart-bubble/bn-chart-bubble.css +37 -0
  35. package/dist/collection/components/bn-chart-bubble/bn-chart-bubble.js +53 -28
  36. package/dist/collection/components/bn-chart-bubble/ibcs-chart-bubble.css +37 -5
  37. package/dist/collection/components/bn-chart-bubble/ibcs-chart-bubble.js +16 -7
  38. package/dist/collection/components/bn-chart-bubble/utils/BubbleChart.js +67 -30
  39. package/dist/collection/components/bn-chart-bullet/bn-chart-bullet.css +37 -0
  40. package/dist/collection/components/bn-chart-bullet/bn-chart-bullet.js +49 -29
  41. package/dist/collection/components/bn-chart-bullet/ibcs-chart-bullet.css +37 -5
  42. package/dist/collection/components/bn-chart-bullet/ibcs-chart-bullet.js +17 -7
  43. package/dist/collection/components/bn-chart-bullet/utils/BulletChart.js +34 -18
  44. package/dist/collection/components/bn-chart-bullet/utils/model/BulletChartStyle.js +2 -0
  45. package/dist/collection/components/bn-chart-bullet/utils/model/BulletConfig.js +1 -1
  46. package/dist/collection/components/bn-chart-scatter/bn-chart-scatter.css +37 -0
  47. package/dist/collection/components/bn-chart-scatter/bn-chart-scatter.js +52 -27
  48. package/dist/collection/components/bn-chart-scatter/ibcs-chart-scatter.css +37 -5
  49. package/dist/collection/components/bn-chart-scatter/ibcs-chart-scatter.js +16 -7
  50. package/dist/collection/components/bn-chart-scatter/utils/ScatterChart.js +52 -18
  51. package/dist/collection/components/bn-chart-structure/bn-chart-structure.css +37 -5
  52. package/dist/collection/components/bn-chart-structure/bn-chart-structure.js +74 -44
  53. package/dist/collection/components/bn-chart-structure/ibcs-chart-structure.js +60 -19
  54. package/dist/collection/components/bn-chart-structure/utils/StructureChart.js +218 -262
  55. package/dist/collection/components/bn-chart-structure/utils/elements/Label.js +1 -1
  56. package/dist/collection/components/bn-chart-structure/utils/elements/Needle.js +11 -4
  57. package/dist/collection/components/bn-chart-structure/utils/elements/StackedBar.js +16 -25
  58. package/dist/collection/components/bn-chart-structure/utils/model/StructureChartComponentConfig.js +3 -2
  59. package/dist/collection/components/bn-chart-structure/utils/model/styles/StructureChartStyle.js +2 -0
  60. package/dist/collection/components/bn-chart-time/bn-chart-time.css +37 -0
  61. package/dist/collection/components/bn-chart-time/bn-chart-time.js +122 -52
  62. package/dist/collection/components/bn-chart-time/ibcs-chart-time.css +37 -0
  63. package/dist/collection/components/bn-chart-time/ibcs-chart-time.js +60 -19
  64. package/dist/collection/components/bn-chart-time/utils/TimeChart.js +245 -250
  65. package/dist/collection/components/bn-chart-time/utils/elements/AreaFill.js +1 -1
  66. package/dist/collection/components/bn-chart-time/utils/elements/Label.js +1 -1
  67. package/dist/collection/components/bn-chart-time/utils/elements/LineSeries.js +1 -1
  68. package/dist/collection/components/bn-chart-time/utils/elements/Needle.js +11 -4
  69. package/dist/collection/components/bn-chart-time/utils/elements/StackedColumn.js +22 -34
  70. package/dist/collection/components/bn-chart-time/utils/helper/LabelCollisionManager.js +3 -3
  71. package/dist/collection/components/bn-chart-time/utils/model/TimeChartComponentConfig.js +4 -3
  72. package/dist/collection/components/bn-chart-time/utils/model/TimeChartDataRow.js +2 -2
  73. package/dist/collection/components/bn-chart-time/utils/model/styles/TimeChartStyle.js +2 -0
  74. package/dist/collection/components/bn-component-style/bn-component-style.js +14 -2
  75. package/dist/collection/components/bn-context/bn-context.js +92 -22
  76. package/dist/collection/components/bn-dataset/bn-dataset.js +246 -90
  77. package/dist/collection/components/bn-datasource/bn-datasource.js +169 -77
  78. package/dist/collection/components/bn-footer/bn-footer.js +6 -6
  79. package/dist/collection/components/bn-internationalization/bn-internationalization.js +14 -3
  80. package/dist/collection/components/bn-layout-card/bn-layout-card.js +25 -74
  81. package/dist/collection/components/bn-layout-page/bn-layout-page.js +59 -71
  82. package/dist/collection/components/bn-message/bn-message.js +2 -2
  83. package/dist/collection/components/bn-page/bn-page.css +0 -240
  84. package/dist/collection/components/bn-page/bn-page.js +14 -4
  85. package/dist/collection/components/bn-page/pageFormats.js +69 -0
  86. package/dist/collection/components/bn-ruleset/bn-ruleset.js +2 -2
  87. package/dist/collection/components/bn-scaling-group/bn-scaling-group.js +7 -7
  88. package/dist/collection/components/bn-table/bn-table.css +38 -1
  89. package/dist/collection/components/bn-table/bn-table.js +96 -59
  90. package/dist/collection/components/bn-table/ibcs-table.css +39 -1
  91. package/dist/collection/components/bn-table/ibcs-table.js +89 -30
  92. package/dist/collection/components/bn-table/utils/Table.js +12 -13
  93. package/dist/collection/components/bn-table/utils/elements/Cell.js +9 -3
  94. package/dist/collection/components/bn-table/utils/elements/CellBarChart.js +38 -34
  95. package/dist/collection/components/bn-table/utils/elements/TableRow.js +2 -1
  96. package/dist/collection/components/bn-table/utils/elements/WaterfallBar.js +4 -4
  97. package/dist/collection/components/bn-table/utils/factories/tableDataSetFactory.js +17 -4
  98. package/dist/collection/components/bn-table/utils/helper/DataQuery.js +128 -98
  99. package/dist/collection/components/bn-table/utils/helper/IntervalColumns.js +6 -20
  100. package/dist/collection/components/bn-table/utils/helper/QueryGroup.js +9 -2
  101. package/dist/collection/components/bn-table/utils/helper/barColumnGeometry.js +2 -2
  102. package/dist/collection/components/bn-table/utils/model/TableAttribute.js +2 -2
  103. package/dist/collection/components/bn-table/utils/model/TableComponentConfig.js +3 -2
  104. package/dist/collection/components/bn-template/bn-template.js +1 -1
  105. package/dist/collection/components/bn-text/bn-text.js +36 -39
  106. package/dist/collection/components/bn-text/utils/template.js +79 -0
  107. package/dist/collection/components/bn-title/bn-title.js +10 -4
  108. package/dist/collection/components/bn-title/ibcs-title/ibcs-title.js +3 -1
  109. package/dist/collection/components/bn-tree/bn-tree.js +119 -23
  110. package/dist/collection/components/bn-tree/utils/EdgeRenderer.js +59 -51
  111. package/dist/collection/components/bn-tree/utils/TreeLayout.js +30 -5
  112. package/dist/collection/components/bn-tree/utils/TreeParser.js +35 -0
  113. package/dist/collection/components/editor-companion/editor-companion.js +1 -1
  114. package/dist/collection/context/context-protocol.js +1 -1
  115. package/dist/collection/context/scopedDb.js +47 -4
  116. package/dist/collection/stores/componentStyles.js +39 -0
  117. package/dist/collection/stores/internationalization.js +15 -13
  118. package/dist/collection/utils/DateStringFactory.js +17 -15
  119. package/dist/collection/utils/autoFit.js +2 -2
  120. package/dist/collection/utils/componentRegister.js +60 -16
  121. package/dist/collection/utils/constants.js +2 -2
  122. package/dist/collection/utils/dataAnalyzer.js +9 -12
  123. package/dist/collection/utils/emptyState.js +21 -0
  124. package/dist/collection/utils/formatter.js +29 -20
  125. package/dist/collection/utils/layoutObserver.js +1 -1
  126. package/dist/collection/utils/layoutState/generic.js +1 -1
  127. package/dist/collection/utils/layoutState/svgChartElements.js +2 -2
  128. package/dist/collection/utils/layoutTemplate.js +81 -0
  129. package/dist/collection/utils/measurementHost.js +2 -2
  130. package/dist/collection/utils/model/Order.js +1 -1
  131. package/dist/collection/utils/model/styles/SVGStyle.js +12 -4
  132. package/dist/collection/utils/parentDimensions.js +35 -3
  133. package/dist/collection/utils/queryError.js +11 -0
  134. package/dist/collection/utils/relativeVariance.js +14 -0
  135. package/dist/collection/utils/sanitizeHtml.js +30 -16
  136. package/dist/collection/utils/scaling.js +2 -2
  137. package/dist/collection/utils/stackColors.js +27 -5
  138. package/dist/collection/utils/stackLayout.js +71 -0
  139. package/dist/collection/utils/styled/attributes.js +16 -3
  140. package/dist/collection/utils/styled/style-sheet.js +1 -1
  141. package/dist/collection/utils/styled/withStyled.js +1 -1
  142. package/dist/collection/utils/testing/fakeGroup.js +21 -0
  143. package/dist/collection/utils/testing/mutationObserver.js +44 -0
  144. package/dist/collection/utils/testing/structureChart.js +26 -0
  145. package/dist/collection/utils/testing/timeChart.js +28 -0
  146. package/dist/collection/utils/validate.js +1 -1
  147. package/dist/collection/utils/withComponentStatus.js +137 -12
  148. package/dist/collection/utils/withInheritedProps.js +113 -64
  149. package/dist/collection/utils/withRuleSet.js +10 -7
  150. package/dist/collection/utils/withTranslation.js +3 -3
  151. package/dist/collection/utils/xy/FacetGrid.js +1 -1
  152. package/dist/collection/utils/xy/IsoCurves.js +1 -1
  153. package/dist/collection/utils/xy/NumericScale.js +46 -15
  154. package/dist/collection/utils/xy/PointLabeler.js +2 -2
  155. package/dist/collection/utils/xy/RadiusScale.js +2 -2
  156. package/dist/collection/utils/xy/SeriesPalette.js +3 -3
  157. package/dist/collection/utils/xy/VarianceMeasure.js +22 -4
  158. package/dist/collection/utils/xy/XYFrame.js +4 -4
  159. package/dist/collection/utils/xy/XYLegend.js +5 -7
  160. package/dist/collection/utils/xy/checkXYOverflow.js +32 -0
  161. package/dist/collection/utils/xy/formatXYValue.js +13 -0
  162. package/dist/collection/utils/xy/model/XYChartDataRow.js +0 -0
  163. package/dist/collection/utils/xy/model/XYChartStyle.js +2 -0
  164. package/dist/components/DataFormatDigits.js +1 -1
  165. package/dist/components/DateStringFactory.js +1 -1
  166. package/dist/components/LabelCollisionManager.js +1 -1
  167. package/dist/components/NumericScale.js +1 -1
  168. package/dist/components/Order.js +1 -1
  169. package/dist/components/SVGStyle.js +1 -0
  170. package/dist/components/TableAttribute.js +1 -0
  171. package/dist/components/VarianceMeasure.js +1 -1
  172. package/dist/components/XYChartDataRow.js +1 -1
  173. package/dist/components/bn-asset.js +1 -1
  174. package/dist/components/bn-body2.js +1 -1
  175. package/dist/components/bn-card2.js +1 -1
  176. package/dist/components/bn-chart-bubble.js +1 -1
  177. package/dist/components/bn-chart-bullet.js +1 -1
  178. package/dist/components/bn-chart-scatter.js +1 -1
  179. package/dist/components/bn-chart-structure.js +1 -1
  180. package/dist/components/bn-chart-time.js +1 -1
  181. package/dist/components/bn-component-style.js +1 -1
  182. package/dist/components/bn-context.js +1 -1
  183. package/dist/components/bn-dataset.js +1 -1
  184. package/dist/components/bn-datasource.js +1 -1
  185. package/dist/components/bn-footer2.js +1 -1
  186. package/dist/components/bn-grid.js +1 -1
  187. package/dist/components/bn-image.js +1 -1
  188. package/dist/components/bn-internationalization.js +1 -1
  189. package/dist/components/bn-layout-card.js +1 -1
  190. package/dist/components/bn-layout-page.js +1 -1
  191. package/dist/components/bn-message2.js +1 -1
  192. package/dist/components/bn-page2.js +1 -1
  193. package/dist/components/bn-ruleset.js +1 -1
  194. package/dist/components/bn-scaling-group.js +1 -1
  195. package/dist/components/bn-table.js +1 -1
  196. package/dist/components/bn-template.js +1 -1
  197. package/dist/components/bn-text.js +1 -1
  198. package/dist/components/bn-title2.js +1 -1
  199. package/dist/components/bn-tree.js +1 -1
  200. package/dist/components/checkXYOverflow.js +1 -0
  201. package/dist/components/context-protocol.js +1 -1
  202. package/dist/components/editor-companion.js +1 -1
  203. package/dist/components/emptyState.js +1 -0
  204. package/dist/components/formatter.js +1 -1
  205. package/dist/components/ibcs-chart-bubble2.js +1 -1
  206. package/dist/components/ibcs-chart-bullet2.js +1 -1
  207. package/dist/components/ibcs-chart-scatter2.js +1 -1
  208. package/dist/components/ibcs-chart-structure2.js +1 -1
  209. package/dist/components/ibcs-chart-time2.js +1 -1
  210. package/dist/components/ibcs-table2.js +1 -1
  211. package/dist/components/ibcs-title2.js +1 -1
  212. package/dist/components/layoutTemplate.js +1 -0
  213. package/dist/components/pageFormats.js +1 -0
  214. package/dist/components/parentDimensions.js +1 -0
  215. package/dist/components/queryError.js +1 -0
  216. package/dist/components/relativeVariance.js +1 -0
  217. package/dist/components/sanitizeHtml.js +1 -1
  218. package/dist/components/stackColors.js +1 -1
  219. package/dist/components/stackLayout.js +1 -0
  220. package/dist/components/svg.esm.js +1 -0
  221. package/dist/components/validate.js +1 -1
  222. package/dist/components/withBodyObserver.js +1 -1
  223. package/dist/components/withComponentStatus.js +1 -0
  224. package/dist/components/withComponentStyle.js +1 -1
  225. package/dist/components/withDataset.js +1 -1
  226. package/dist/components/withHasError.js +1 -1
  227. package/dist/components/withRuleSet.js +1 -1
  228. package/dist/components/withScalingGroup.js +1 -1
  229. package/dist/components/withStyled.js +1 -1
  230. package/dist/components/withTranslation.js +1 -1
  231. package/dist/esm/{bn-asset_21.entry.js → bn-asset_28.entry.js} +20948 -6125
  232. package/dist/esm/bn-grid.entry.js +4 -6
  233. package/dist/esm/bn-image.entry.js +3 -5
  234. package/dist/esm/bn-internationalization.entry.js +17 -6
  235. package/dist/esm/bn-ruleset.entry.js +5 -5
  236. package/dist/esm/bn-template-engine.js +1 -1
  237. package/dist/esm/bn-template.entry.js +2 -2
  238. package/dist/esm/bn-text.entry.js +111 -39
  239. package/dist/esm/{context-protocol-B-vdGKeG.js → context-protocol-CdTp19uA.js} +106 -22
  240. package/dist/esm/{diagnostics-CiquIw8B.js → diagnostics-vw6TKMiT.js} +1 -1
  241. package/dist/esm/editor-companion.entry.js +2 -2
  242. package/dist/esm/loader.js +1 -1
  243. package/dist/esm/queryError-ClruFZD_.js +13 -0
  244. package/dist/esm/{scaling-Dggyeqts.js → sanitizeHtml-C5bFtARM.js} +464 -287
  245. package/dist/esm/{withBodyObserver-Cb9ZC5_J.js → withBodyObserver-DD_-r04o.js} +1 -1
  246. package/dist/esm/withHasError-73WV2SP5.js +422 -0
  247. package/dist/esm/{withStyled-DoNsbwS3.js → withStyled-BDEyKd_H.js} +513 -27
  248. package/dist/types/components/bn-chart-bubble/bn-chart-bubble.d.ts +8 -4
  249. package/dist/types/components/bn-chart-bubble/ibcs-chart-bubble.d.ts +2 -1
  250. package/dist/types/components/bn-chart-bubble/utils/BubbleChart.d.ts +14 -2
  251. package/dist/types/components/bn-chart-bullet/bn-chart-bullet.d.ts +12 -11
  252. package/dist/types/components/bn-chart-bullet/ibcs-chart-bullet.d.ts +2 -1
  253. package/dist/types/components/bn-chart-bullet/utils/BulletChart.d.ts +8 -5
  254. package/dist/types/components/bn-chart-bullet/utils/model/BulletChartStyle.d.ts +2 -0
  255. package/dist/types/components/bn-chart-bullet/utils/model/BulletConfig.d.ts +1 -1
  256. package/dist/types/components/bn-chart-scatter/bn-chart-scatter.d.ts +8 -4
  257. package/dist/types/components/bn-chart-scatter/ibcs-chart-scatter.d.ts +2 -1
  258. package/dist/types/components/bn-chart-scatter/utils/ScatterChart.d.ts +11 -1
  259. package/dist/types/components/bn-chart-structure/bn-chart-structure.d.ts +13 -12
  260. package/dist/types/components/bn-chart-structure/ibcs-chart-structure.d.ts +8 -1
  261. package/dist/types/components/bn-chart-structure/utils/StructureChart.d.ts +29 -6
  262. package/dist/types/components/bn-chart-structure/utils/elements/StackedBar.d.ts +4 -3
  263. package/dist/types/components/bn-chart-structure/utils/model/DataPoint.d.ts +3 -2
  264. package/dist/types/components/bn-chart-structure/utils/model/StructureChartComponentConfig.d.ts +2 -1
  265. package/dist/types/components/bn-chart-structure/utils/model/styles/StructureChartStyle.d.ts +2 -0
  266. package/dist/types/components/bn-chart-time/bn-chart-time.d.ts +19 -15
  267. package/dist/types/components/bn-chart-time/ibcs-chart-time.d.ts +8 -1
  268. package/dist/types/components/bn-chart-time/utils/TimeChart.d.ts +63 -5
  269. package/dist/types/components/bn-chart-time/utils/elements/AreaFill.d.ts +1 -1
  270. package/dist/types/components/bn-chart-time/utils/elements/StackedColumn.d.ts +9 -8
  271. package/dist/types/components/bn-chart-time/utils/model/DataPoint.d.ts +3 -2
  272. package/dist/types/components/bn-chart-time/utils/model/TimeChartComponentConfig.d.ts +3 -2
  273. package/dist/types/components/bn-chart-time/utils/model/styles/TimeChartStyle.d.ts +2 -0
  274. package/dist/types/components/bn-context/bn-context.d.ts +15 -3
  275. package/dist/types/components/bn-dataset/bn-dataset.d.ts +41 -20
  276. package/dist/types/components/bn-datasource/bn-datasource.d.ts +34 -18
  277. package/dist/types/components/bn-footer/bn-footer.d.ts +2 -2
  278. package/dist/types/components/bn-layout-card/bn-layout-card.d.ts +3 -10
  279. package/dist/types/components/bn-layout-page/bn-layout-page.d.ts +13 -6
  280. package/dist/types/components/bn-message/bn-message.d.ts +2 -1
  281. package/dist/types/components/bn-page/bn-page.d.ts +2 -1
  282. package/dist/types/components/bn-page/pageFormats.d.ts +40 -0
  283. package/dist/types/components/bn-scaling-group/bn-scaling-group.d.ts +2 -2
  284. package/dist/types/components/bn-table/bn-table.d.ts +11 -10
  285. package/dist/types/components/bn-table/ibcs-table.d.ts +8 -5
  286. package/dist/types/components/bn-table/utils/Table.d.ts +3 -1
  287. package/dist/types/components/bn-table/utils/elements/Cell.d.ts +2 -2
  288. package/dist/types/components/bn-table/utils/elements/CellBarChart.d.ts +6 -4
  289. package/dist/types/components/bn-table/utils/elements/WaterfallBar.d.ts +1 -1
  290. package/dist/types/components/bn-table/utils/factories/tableDataSetFactory.d.ts +2 -0
  291. package/dist/types/components/bn-table/utils/helper/DataQuery.d.ts +14 -5
  292. package/dist/types/components/bn-table/utils/helper/IntervalColumns.d.ts +2 -2
  293. package/dist/types/components/bn-table/utils/helper/QueryGroup.d.ts +6 -1
  294. package/dist/types/components/bn-table/utils/helper/barColumnGeometry.d.ts +2 -2
  295. package/dist/types/components/bn-table/utils/model/TableAttribute.d.ts +2 -0
  296. package/dist/types/components/bn-table/utils/model/TableComponentConfig.d.ts +2 -1
  297. package/dist/types/components/bn-text/bn-text.d.ts +20 -13
  298. package/dist/types/components/bn-text/utils/template.d.ts +10 -0
  299. package/dist/types/components/bn-title/ibcs-title/ibcs-title.d.ts +1 -0
  300. package/dist/types/components/bn-tree/bn-tree.d.ts +8 -1
  301. package/dist/types/components/bn-tree/utils/EdgeRenderer.d.ts +18 -5
  302. package/dist/types/components/bn-tree/utils/TreeLayout.d.ts +5 -0
  303. package/dist/types/components.d.ts +226 -184
  304. package/dist/types/context/scopedDb.d.ts +20 -0
  305. package/dist/types/stores/componentStyles.d.ts +6 -0
  306. package/dist/types/utils/DateStringFactory.d.ts +3 -2
  307. package/dist/types/utils/autoFit.d.ts +2 -2
  308. package/dist/types/utils/componentRegister.d.ts +21 -5
  309. package/dist/types/utils/constants.d.ts +2 -2
  310. package/dist/types/utils/dataAnalyzer.d.ts +1 -1
  311. package/dist/types/utils/emptyState.d.ts +10 -0
  312. package/dist/types/utils/formatter.d.ts +7 -9
  313. package/dist/types/utils/layoutState/generic.d.ts +1 -1
  314. package/dist/types/utils/layoutState/svgChartElements.d.ts +2 -2
  315. package/dist/types/utils/layoutTemplate.d.ts +16 -0
  316. package/dist/types/utils/model/ChartStyles.d.ts +1 -1
  317. package/dist/types/utils/model/DataQueryResultRow.d.ts +2 -2
  318. package/dist/types/utils/model/Order.d.ts +1 -1
  319. package/dist/types/utils/model/styles/SVGStyle.d.ts +5 -1
  320. package/dist/types/utils/parentDimensions.d.ts +9 -0
  321. package/dist/types/utils/queryError.d.ts +5 -0
  322. package/dist/types/utils/relativeVariance.d.ts +9 -0
  323. package/dist/types/utils/sanitizeHtml.d.ts +2 -2
  324. package/dist/types/utils/scaling.d.ts +1 -1
  325. package/dist/types/utils/stackColors.d.ts +3 -2
  326. package/dist/types/utils/stackLayout.d.ts +49 -0
  327. package/dist/types/utils/testing/fakeGroup.d.ts +8 -0
  328. package/dist/types/utils/testing/mutationObserver.d.ts +5 -0
  329. package/dist/types/utils/testing/structureChart.d.ts +5 -0
  330. package/dist/types/utils/testing/timeChart.d.ts +5 -0
  331. package/dist/types/utils/validate.d.ts +1 -1
  332. package/dist/types/utils/withComponentStatus.d.ts +11 -3
  333. package/dist/types/utils/withInheritedProps.d.ts +42 -15
  334. package/dist/types/utils/withRuleSet.d.ts +2 -1
  335. package/dist/types/utils/withTranslation.d.ts +2 -2
  336. package/dist/types/utils/xy/FacetGrid.d.ts +1 -1
  337. package/dist/types/utils/xy/IsoCurves.d.ts +1 -1
  338. package/dist/types/utils/xy/NumericScale.d.ts +9 -4
  339. package/dist/types/utils/xy/PointLabeler.d.ts +2 -2
  340. package/dist/types/utils/xy/RadiusScale.d.ts +2 -2
  341. package/dist/types/utils/xy/SeriesPalette.d.ts +3 -3
  342. package/dist/types/utils/xy/VarianceMeasure.d.ts +10 -2
  343. package/dist/types/utils/xy/XYFrame.d.ts +4 -1
  344. package/dist/types/utils/xy/XYLegend.d.ts +3 -1
  345. package/dist/types/utils/xy/checkXYOverflow.d.ts +8 -0
  346. package/dist/types/utils/xy/formatXYValue.d.ts +7 -0
  347. package/dist/types/utils/xy/model/AxisConfig.d.ts +1 -1
  348. package/dist/types/utils/xy/model/XYChartStyle.d.ts +2 -0
  349. package/package.json +4 -2
  350. package/readme.md +11 -11
  351. package/dist/bn-template-engine/p-03304284.entry.js +0 -1
  352. package/dist/bn-template-engine/p-0fb02c57.entry.js +0 -1
  353. package/dist/bn-template-engine/p-4419db8f.entry.js +0 -1
  354. package/dist/bn-template-engine/p-45508f1b.entry.js +0 -1
  355. package/dist/bn-template-engine/p-461fdffa.entry.js +0 -1
  356. package/dist/bn-template-engine/p-5d7a3a77.entry.js +0 -1
  357. package/dist/bn-template-engine/p-62cc95b7.entry.js +0 -1
  358. package/dist/bn-template-engine/p-686d8e44.entry.js +0 -1
  359. package/dist/bn-template-engine/p-829212c3.entry.js +0 -1
  360. package/dist/bn-template-engine/p-B5Jd_eCX.js +0 -1
  361. package/dist/bn-template-engine/p-BA48JiHe.js +0 -1
  362. package/dist/bn-template-engine/p-BbmobTg0.js +0 -1
  363. package/dist/bn-template-engine/p-BcaI745G.js +0 -1
  364. package/dist/bn-template-engine/p-CG_Bcm6V.js +0 -1
  365. package/dist/bn-template-engine/p-CWWWM-XC.js +0 -1
  366. package/dist/bn-template-engine/p-CsJ84YRk.js +0 -1
  367. package/dist/bn-template-engine/p-D5e8I9Qe.js +0 -1
  368. package/dist/bn-template-engine/p-DVrDYxlh.js +0 -1
  369. package/dist/bn-template-engine/p-DjPXefnq.js +0 -1
  370. package/dist/bn-template-engine/p-DsTzlzxQ.js +0 -1
  371. package/dist/bn-template-engine/p-DtLI_CzV.js +0 -1
  372. package/dist/bn-template-engine/p-EtT29btN.js +0 -1
  373. package/dist/bn-template-engine/p-TuLpbB5O.js +0 -1
  374. package/dist/bn-template-engine/p-a5867a4c.entry.js +0 -1
  375. package/dist/bn-template-engine/p-b27009eb.entry.js +0 -1
  376. package/dist/bn-template-engine/p-bfa87b07.entry.js +0 -1
  377. package/dist/bn-template-engine/p-ceb80db3.entry.js +0 -1
  378. package/dist/bn-template-engine/p-fcfbb329.entry.js +0 -1
  379. package/dist/bn-template-engine/p-qRZrT-U3.js +0 -1
  380. package/dist/cjs/AxisConfig-DwiNUyYG.js +0 -233
  381. package/dist/cjs/LabelCollisionManager-Bv-xkeXw.js +0 -415
  382. package/dist/cjs/NumericScale-BAyYXpKL.js +0 -107
  383. package/dist/cjs/Order-2wRydarc.js +0 -87
  384. package/dist/cjs/SVGStyle-DoxylrEQ.js +0 -8219
  385. package/dist/cjs/SVGVariancesStyleGroup-CiI4GeWe.js +0 -50
  386. package/dist/cjs/VarianceMeasure-CQlSRzlp.js +0 -372
  387. package/dist/cjs/XYChartDataRow-C2FdL58s.js +0 -829
  388. package/dist/cjs/bn-chart-bubble.cjs.entry.js +0 -792
  389. package/dist/cjs/bn-chart-bullet.cjs.entry.js +0 -805
  390. package/dist/cjs/bn-chart-scatter.cjs.entry.js +0 -678
  391. package/dist/cjs/bn-tree.cjs.entry.js +0 -1042
  392. package/dist/cjs/ibcs-chart-bubble.cjs.entry.js +0 -624
  393. package/dist/cjs/ibcs-chart-bullet.cjs.entry.js +0 -673
  394. package/dist/cjs/ibcs-chart-scatter.cjs.entry.js +0 -667
  395. package/dist/cjs/sanitizeHtml-LuZr1IMd.js +0 -85
  396. package/dist/cjs/svgChartElements-tDA43aYj.js +0 -400
  397. package/dist/cjs/withHasError-BdDmiOXM.js +0 -258
  398. package/dist/cjs/withScalingGroup-CFIc5-6s.js +0 -73
  399. package/dist/components/autoFit.js +0 -1
  400. package/dist/components/main.js +0 -1
  401. package/dist/components/utils.js +0 -1
  402. package/dist/esm/AxisConfig-KqzWQbML.js +0 -224
  403. package/dist/esm/LabelCollisionManager-585bQMtP.js +0 -407
  404. package/dist/esm/NumericScale-DsTzlzxQ.js +0 -105
  405. package/dist/esm/Order-DZVWjEL_.js +0 -83
  406. package/dist/esm/SVGStyle-OrPkzjcb.js +0 -8209
  407. package/dist/esm/SVGVariancesStyleGroup-DO5QJfRQ.js +0 -48
  408. package/dist/esm/VarianceMeasure-DDjChp8C.js +0 -364
  409. package/dist/esm/XYChartDataRow-Dn83Tqh9.js +0 -820
  410. package/dist/esm/bn-chart-bubble.entry.js +0 -790
  411. package/dist/esm/bn-chart-bullet.entry.js +0 -803
  412. package/dist/esm/bn-chart-scatter.entry.js +0 -676
  413. package/dist/esm/bn-tree.entry.js +0 -1040
  414. package/dist/esm/ibcs-chart-bubble.entry.js +0 -622
  415. package/dist/esm/ibcs-chart-bullet.entry.js +0 -671
  416. package/dist/esm/ibcs-chart-scatter.entry.js +0 -665
  417. package/dist/esm/sanitizeHtml-BA48JiHe.js +0 -83
  418. package/dist/esm/svgChartElements-B3YClivG.js +0 -395
  419. package/dist/esm/withHasError-Bh1Viz52.js +0 -254
  420. package/dist/esm/withScalingGroup-DNBSqRC0.js +0 -71
@@ -1,8 +1,57 @@
1
1
  import { g as getElement, f as forceUpdate } from './index-C5UYpZUU.js';
2
- import { g as getStores, c as clearStoresCache, D as DateTime } from './context-protocol-B-vdGKeG.js';
3
- import { r as runIfExisits } from './withHasError-Bh1Viz52.js';
4
- import { m as merge, S as Scenarios, b as Sentiments, A as AggregationLevel, c as AxisLabelsMode, T as TableBarColumnWidth, D as DataFormat, d as TableType, M as MeasureType, e as TableCategoryWidth, r as resolveMeasure } from './VarianceMeasure-DDjChp8C.js';
5
- import { b as OrderColumn, O as OrderDirection } from './Order-DZVWjEL_.js';
2
+ import { g as getStores, c as clearStoresCache, D as DateTime } from './context-protocol-CdTp19uA.js';
3
+ import { r as runIfExisits } from './withHasError-73WV2SP5.js';
4
+
5
+ const isObject = (obj) => {
6
+ if (typeof obj === 'object' && obj !== null) {
7
+ if (typeof Object.getPrototypeOf === 'function') {
8
+ const prototype = Object.getPrototypeOf(obj);
9
+ return prototype === Object.prototype || prototype === null;
10
+ }
11
+ return Object.prototype.toString.call(obj) === '[object Object]';
12
+ }
13
+ return false;
14
+ };
15
+ const overwriteMerge = (_, currArr) => currArr;
16
+ const combineMerge = (prevArr, currArr) => {
17
+ return [...new Set([...prevArr, ...currArr])];
18
+ };
19
+ const getMergeFn = (type) => {
20
+ switch (type) {
21
+ case 'overwrite':
22
+ return overwriteMerge;
23
+ case 'combine':
24
+ default:
25
+ return combineMerge;
26
+ }
27
+ };
28
+
29
+ const withDefaultOptions = (options) => {
30
+ return {
31
+ arrayMergeType: 'combine',
32
+ arrayMerge: getMergeFn(options ? options.arrayMergeType : 'combine'),
33
+ ...options,
34
+ };
35
+ };
36
+ const merge = (objects, options) => {
37
+ const opts = withDefaultOptions(options);
38
+ return objects.reduce((prev, curr) => {
39
+ Object.keys(curr).forEach((key) => {
40
+ if (Array.isArray(prev[key]) && Array.isArray(curr[key])) {
41
+ if (opts && opts.arrayMerge) {
42
+ prev[key] = opts.arrayMerge(prev[key], curr[key]);
43
+ }
44
+ }
45
+ else if (isObject(prev[key]) && isObject(curr[key])) {
46
+ prev[key] = merge([prev[key], curr[key]], opts);
47
+ }
48
+ else {
49
+ prev[key] = curr[key];
50
+ }
51
+ });
52
+ return prev;
53
+ }, {});
54
+ };
6
55
 
7
56
  /**
8
57
  * Mixin that provides themed styling to a Stencil component using a
@@ -72,8 +121,200 @@ const withComponentStyle = (component) => {
72
121
  return componentStyle;
73
122
  };
74
123
 
124
+ /** Controls which parts of a component are translated: ALL=labels+data, META=labels only. */
125
+ var I18nMode;
126
+ (function (I18nMode) {
127
+ I18nMode["ALL"] = "all";
128
+ I18nMode["META"] = "meta";
129
+ })(I18nMode || (I18nMode = {}));
130
+ /** Unit type of the measured values - affects default formatting and SI prefix behavior. */
131
+ var MeasureType;
132
+ (function (MeasureType) {
133
+ MeasureType["CURRENCY"] = "currency";
134
+ MeasureType["VOLUME"] = "volume";
135
+ })(MeasureType || (MeasureType = {}));
136
+ /**
137
+ * IBCS four-scenario model with up to 4 variants per type.
138
+ * - AC (actual): reported/measured values
139
+ * - PP (previous period): prior year or period for comparison
140
+ * - FC (forecast): projected future values
141
+ * - PL (plan): budgeted/target values
142
+ */
143
+ var Scenarios;
144
+ (function (Scenarios) {
145
+ Scenarios["AC1"] = "ac1";
146
+ Scenarios["AC2"] = "ac2";
147
+ Scenarios["AC3"] = "ac3";
148
+ Scenarios["AC4"] = "ac4";
149
+ Scenarios["PP1"] = "pp1";
150
+ Scenarios["PP2"] = "pp2";
151
+ Scenarios["PP3"] = "pp3";
152
+ Scenarios["PP4"] = "pp4";
153
+ Scenarios["FC1"] = "fc1";
154
+ Scenarios["FC2"] = "fc2";
155
+ Scenarios["FC3"] = "fc3";
156
+ Scenarios["FC4"] = "fc4";
157
+ Scenarios["PL1"] = "pl1";
158
+ Scenarios["PL2"] = "pl2";
159
+ Scenarios["PL3"] = "pl3";
160
+ Scenarios["PL4"] = "pl4";
161
+ })(Scenarios || (Scenarios = {}));
162
+ /**
163
+ * Variance direction for IBCS traffic-light coloring.
164
+ * - POS: favorable variance (green in IBCS)
165
+ * - NEG: unfavorable variance (red in IBCS)
166
+ * - NEU: neutral / no directional meaning
167
+ */
168
+ var Sentiments;
169
+ (function (Sentiments) {
170
+ Sentiments["POS"] = "pos";
171
+ Sentiments["NEG"] = "neg";
172
+ Sentiments["NEU"] = "neu";
173
+ })(Sentiments || (Sentiments = {}));
174
+ /** Number display format: DECIMAL for absolute values, PERCENT for ratio columns. */
175
+ var DataFormat;
176
+ (function (DataFormat) {
177
+ DataFormat["DECIMAL"] = "decimal";
178
+ DataFormat["PERCENT"] = "percent";
179
+ })(DataFormat || (DataFormat = {}));
180
+ /**
181
+ * Table aggregation mode.
182
+ * - LIST: no aggregation, rows displayed as-is
183
+ * - SUM: simple sum per group with a grand total row
184
+ * - SUMNOTOTAL: sum per group without a grand total
185
+ * - OPT: operation-aware aggregation - rows with operation="-" subtract from the group sum
186
+ * - OPTNOTOTAL: operation-aware aggregation without a grand total
187
+ */
188
+ var TableType;
189
+ (function (TableType) {
190
+ TableType["LIST"] = "list";
191
+ TableType["SUM"] = "sum";
192
+ TableType["SUMNOTOTAL"] = "sumnototal";
193
+ TableType["OPT"] = "opt";
194
+ TableType["OPTNOTOTAL"] = "optnototal";
195
+ })(TableType || (TableType = {}));
196
+ /** Width of the category label column, in em of the table font. INF = auto/infinite. */
197
+ var TableCategoryWidth;
198
+ (function (TableCategoryWidth) {
199
+ TableCategoryWidth["INF"] = "inf";
200
+ TableCategoryWidth["W100"] = "w100";
201
+ TableCategoryWidth["W50"] = "w50";
202
+ TableCategoryWidth["W25"] = "w25";
203
+ TableCategoryWidth["W20"] = "w20";
204
+ TableCategoryWidth["W15"] = "w15";
205
+ TableCategoryWidth["W10"] = "w10";
206
+ TableCategoryWidth["W5"] = "w5";
207
+ })(TableCategoryWidth || (TableCategoryWidth = {}));
208
+ /** Width preset for inline bar/pin chart columns. Value = total column width in em. */
209
+ var TableBarColumnWidth;
210
+ (function (TableBarColumnWidth) {
211
+ TableBarColumnWidth["W5"] = "w5";
212
+ TableBarColumnWidth["W10"] = "w10";
213
+ TableBarColumnWidth["W15"] = "w15";
214
+ TableBarColumnWidth["W20"] = "w20";
215
+ TableBarColumnWidth["W25"] = "w25";
216
+ TableBarColumnWidth["W30"] = "w30";
217
+ TableBarColumnWidth["W40"] = "w40";
218
+ TableBarColumnWidth["W60"] = "w60";
219
+ TableBarColumnWidth["W80"] = "w80";
220
+ TableBarColumnWidth["W100"] = "w100";
221
+ })(TableBarColumnWidth || (TableBarColumnWidth = {}));
222
+ /** Maps TableBarColumnWidth presets to total bar column width in em. */
223
+ const BAR_COLUMN_WIDTH_EM = {
224
+ [TableBarColumnWidth.W5]: 5,
225
+ [TableBarColumnWidth.W10]: 10,
226
+ [TableBarColumnWidth.W15]: 15,
227
+ [TableBarColumnWidth.W20]: 20,
228
+ [TableBarColumnWidth.W25]: 25,
229
+ [TableBarColumnWidth.W30]: 30,
230
+ [TableBarColumnWidth.W40]: 40,
231
+ [TableBarColumnWidth.W60]: 60,
232
+ [TableBarColumnWidth.W80]: 80,
233
+ [TableBarColumnWidth.W100]: 100,
234
+ };
235
+ /**
236
+ * Three-level row hierarchy for grouping and drill-down: rowGroup > category > subCategory.
237
+ * Index variants (e.g. ROWGROUPINDEX) provide stable numeric sort keys that preserve
238
+ * the original dataset order when alphabetical sorting is undesirable.
239
+ */
240
+ var AggregationLevel;
241
+ (function (AggregationLevel) {
242
+ AggregationLevel["ROWGROUP"] = "rowGroup";
243
+ AggregationLevel["ROWGROUPINDEX"] = "rowGroupIndex";
244
+ AggregationLevel["CATEGORY"] = "category";
245
+ AggregationLevel["CATEGORYINDEX"] = "categoryIndex";
246
+ AggregationLevel["SUBCATEGORY"] = "subCategory";
247
+ AggregationLevel["SUBCATEGORYINDEX"] = "subCategoryIndex";
248
+ })(AggregationLevel || (AggregationLevel = {}));
249
+ /**
250
+ * Date axis label display strategy.
251
+ * - SMART: abbreviated labels with parent period shown at boundary crossings (e.g. "Jan" normally, "Jan 2024" at year boundary)
252
+ * - LONG: full date format for every label
253
+ * - SHORT: abbreviated format for every label
254
+ */
255
+ var AxisLabelsMode;
256
+ (function (AxisLabelsMode) {
257
+ AxisLabelsMode["SMART"] = "smart";
258
+ AxisLabelsMode["LONG"] = "long";
259
+ AxisLabelsMode["SHORT"] = "short";
260
+ })(AxisLabelsMode || (AxisLabelsMode = {}));
261
+ /**
262
+ * Visual representation type for chart series.
263
+ * - COLUMN: vertical bars (time chart) or horizontal bars (structure chart)
264
+ * - LINE: connected data points
265
+ * - WATERFALL: cumulative flow where each bar starts where the previous one ended
266
+ */
267
+ var ChartType;
268
+ (function (ChartType) {
269
+ ChartType["COLUMN"] = "column";
270
+ ChartType["LINE"] = "line";
271
+ ChartType["WATERFALL"] = "waterfall";
272
+ })(ChartType || (ChartType = {}));
273
+ /** Chart rendering mode. AUTO selects BAR or LINE based on scenario type. */
274
+ var ChartMode;
275
+ (function (ChartMode) {
276
+ ChartMode["BAR"] = "bar";
277
+ ChartMode["LINE"] = "line";
278
+ ChartMode["AUTO"] = "auto";
279
+ })(ChartMode || (ChartMode = {}));
280
+ /**
281
+ * Stacking dimension for multi-segment bar charts.
282
+ * - SCENARIOS: stack the scenarios from the `scenarios` prop end-to-end
283
+ * - DIMENSIONS: stack by the next-lower hierarchy level derived from the `level` prop
284
+ * (rowGroup → category, category → subCategory)
285
+ */
286
+ var StackBy;
287
+ (function (StackBy) {
288
+ StackBy["SCENARIOS"] = "scenarios";
289
+ StackBy["DIMENSIONS"] = "dimensions";
290
+ })(StackBy || (StackBy = {}));
291
+ /**
292
+ * How stacked values are presented.
293
+ * - ABSOLUTE: raw values stacked
294
+ * - RELATIVE: normalized to 100% per data point
295
+ * - ABSOLUTE_RELATIVE: absolute bars with a relative (%) total label
296
+ */
297
+ var StackMode;
298
+ (function (StackMode) {
299
+ StackMode["ABSOLUTE"] = "absolute";
300
+ StackMode["RELATIVE"] = "relative";
301
+ StackMode["ABSOLUTE_RELATIVE"] = "absolute-relative";
302
+ })(StackMode || (StackMode = {}));
303
+ /**
304
+ * Value domain of a RELATIVE (100%) stack: the full stack spans 100 units,
305
+ * so pixelPerUnit is interpreted as pixels per percentage point.
306
+ */
307
+ const RELATIVE_STACK_UNITS = 100;
308
+ /** Sort order of segments within a stacked bar. DATASET preserves the original data order. */
309
+ var StackOrder;
310
+ (function (StackOrder) {
311
+ StackOrder["ASC"] = "asc";
312
+ StackOrder["DESC"] = "desc";
313
+ StackOrder["DATASET"] = "dataset";
314
+ })(StackOrder || (StackOrder = {}));
315
+
75
316
  const EXPRESSION_REGEX = /^\s*(set|first|last|min|max|avg|sum|lit)\(\s*(.*?)\s*\)\s*$/;
76
- /** Field arguments must be plain identifiers — keeps user input out of SQL syntax. */
317
+ /** Field arguments must be plain identifiers - keeps user input out of SQL syntax. */
77
318
  const FIELD_IDENTIFIER_REGEX = /^[A-Za-z_][A-Za-z0-9_]*$/;
78
319
  const NUMERIC_FNS = ["min", "max", "avg", "sum"];
79
320
  /**
@@ -162,7 +403,8 @@ class DateStringFactory {
162
403
  year: "yyyy",
163
404
  quarter: "q'Q' yyyy",
164
405
  month: "LLL yyyy",
165
- week: "'KW'WW yyyy",
406
+ // kkkk is the ISO week year: week 1 of 2025 starts on Monday 2024-12-30
407
+ week: "'KW'WW kkkk",
166
408
  day: "dd.MM.yyyy",
167
409
  hour: "TT",
168
410
  minute: "TT",
@@ -325,24 +567,24 @@ class DateStringFactory {
325
567
  * @param {string|Date} from start date
326
568
  * @param {string|Date} to end date
327
569
  * @param dateInterval
328
- * @param spanLimit
329
570
  */
330
- datesBetween(from, to, dateInterval, spanLimit) {
571
+ datesBetween(from, to, dateInterval) {
331
572
  const unit = this.convertDateDistanceToMomentunitOfTime(dateInterval);
332
573
  const fromDate = from.startOf(unit);
333
574
  const toDate = to.endOf(unit);
334
- let span = toDate.diff(fromDate).as(unit);
335
575
  const days = [];
336
- if (span >= spanLimit) {
337
- span = spanLimit;
338
- }
339
576
  let currentDate = fromDate;
340
577
  do {
341
578
  days.push(currentDate);
342
579
  currentDate = currentDate.plus(this.createDiratonLike(unit, 1));
343
- } while (currentDate <= toDate && days.length < span);
580
+ } while (currentDate <= toDate);
344
581
  return days;
345
582
  }
583
+ /** Number of `dateInterval` periods from `from` to `to`, both included. */
584
+ countBetween(from, to, dateInterval) {
585
+ const unit = this.convertDateDistanceToMomentunitOfTime(dateInterval);
586
+ return Math.floor(to.startOf(unit).diff(from.startOf(unit), unit).as(unit)) + 1;
587
+ }
346
588
  /**
347
589
  * Produces an IBCS date-link string combining date formatting with link notation.
348
590
  *
@@ -400,7 +642,7 @@ class DateStringFactory {
400
642
  dateString1 = dateString2;
401
643
  }
402
644
  // clean up dateString1 if same year
403
- if (mode === DateLink.INTERVAL || mode === DateLink.CUM || DateLink.AVG) {
645
+ if (mode === DateLink.INTERVAL || mode === DateLink.CUM || mode === DateLink.AVG) {
404
646
  if (type === DateDistance.QUARTER) {
405
647
  if (date1.quarter === date2.quarter && date1.year === date2.year) {
406
648
  dateString2 = dateString2.replace(" " + date2.year, "");
@@ -418,11 +660,11 @@ class DateStringFactory {
418
660
  }
419
661
  }
420
662
  else if (type === DateDistance.WEEK) {
421
- if (date1.weekNumber === date2.weekNumber && date1.year === date2.year) {
422
- dateString2 = dateString2.replace(" " + date2.year, "");
663
+ if (date1.weekNumber === date2.weekNumber && date1.weekYear === date2.weekYear) {
664
+ dateString2 = dateString2.replace(" " + date2.weekYear, "");
423
665
  }
424
- else if (date1.year === date2.year) {
425
- dateString1 = dateString1.replace(" " + date1.year, "");
666
+ else if (date1.weekYear === date2.weekYear) {
667
+ dateString1 = dateString1.replace(" " + date1.weekYear, "");
426
668
  }
427
669
  }
428
670
  }
@@ -465,7 +707,8 @@ class DateStringFactory {
465
707
  getFormatedWeekDate(date) {
466
708
  let format = this.dateFormatShort["week"];
467
709
  if (this.isFirstWeek(date)) {
468
- format += " " + this.dateFormatShort["year"];
710
+ // the short ISO week year, see the week format
711
+ format += " kk";
469
712
  }
470
713
  return date.setLocale(this.locale).toFormat(format);
471
714
  }
@@ -591,12 +834,242 @@ class DateStringFactory {
591
834
  * locale-aware through `setLocale`, so they need no override.
592
835
  */
593
836
  DateStringFactory.LOCALE_DATE_FORMAT = {
594
- en: { week: "'W'WW yyyy", day: "MM/dd/yyyy", fallback: "MM/dd/yyyy" },
837
+ en: { week: "'W'WW kkkk", day: "MM/dd/yyyy", fallback: "MM/dd/yyyy" },
595
838
  };
596
839
  DateStringFactory.LOCALE_DATE_FORMAT_SHORT = {
597
840
  en: { week: "'W'WW", fallback: "MM/dd/yyyy" },
598
841
  };
599
842
 
843
+ /**
844
+ * Type-checking utility used throughout the adapter layer for safe JSON-to-domain conversion.
845
+ *
846
+ * All methods are static guards that validate a single `unknown` value before it is
847
+ * assigned to a typed domain property. Methods that serve as TypeScript type guards
848
+ * use `data is T` return types to enable downstream type narrowing.
849
+ */
850
+ class CompareUtil {
851
+ static isExisting(data) {
852
+ return data !== null && data !== undefined;
853
+ }
854
+ static isString(data) {
855
+ return typeof data === "string";
856
+ }
857
+ static isNumber(data) {
858
+ return typeof data === "number" && !Number.isNaN(data);
859
+ }
860
+ static isBoolean(data) {
861
+ return typeof data === "boolean";
862
+ }
863
+ static isArray(data) {
864
+ return Array.isArray(data);
865
+ }
866
+ static isObject(data) {
867
+ return typeof data === "object" && data !== null;
868
+ }
869
+ /**
870
+ * Checks if the value is a valid IBCS aggregation operator.
871
+ * Only `"+"` and `"-"` are valid; any other value is rejected.
872
+ */
873
+ static isOperator(data) {
874
+ return data === "+" || data === "-";
875
+ }
876
+ /**
877
+ * Checks if the value is a valid Luxon DateTime instance.
878
+ * Returns false for invalid DateTime objects (e.g. parsed from malformed strings).
879
+ */
880
+ static isDate(data) {
881
+ return data instanceof DateTime && data.isValid;
882
+ }
883
+ }
884
+
885
+ /** Shared utilities for the adapter layer, used by all component config adapters. */
886
+ class AdapterUtils {
887
+ /** Returns the trimmed string value, or an empty string if the input is not a string. */
888
+ static adaptDefaultString(data) {
889
+ if (CompareUtil.isString(data)) {
890
+ return data.trim();
891
+ }
892
+ return "";
893
+ }
894
+ /**
895
+ * Safely adapts an array of untyped records through a typed adapter.
896
+ * If `data` is not an array, returns an empty array instead of throwing.
897
+ */
898
+ static adaptArray(data, adapter) {
899
+ const targetArray = [];
900
+ if (CompareUtil.isArray(data)) {
901
+ data.forEach((b) => {
902
+ targetArray.push(adapter.adapt(b));
903
+ });
904
+ }
905
+ return targetArray;
906
+ }
907
+ }
908
+
909
+ var OrderDirection;
910
+ (function (OrderDirection) {
911
+ OrderDirection["ASC"] = "asc";
912
+ OrderDirection["DESC"] = "desc";
913
+ })(OrderDirection || (OrderDirection = {}));
914
+ /** Valid columns for ORDER BY in AlaSQL queries - includes hierarchy dimensions and all 16 scenario slots. */
915
+ var OrderColumn;
916
+ (function (OrderColumn) {
917
+ OrderColumn["ROWGROUP"] = "rowGroup";
918
+ OrderColumn["ROWGROUPINDEX"] = "rowGroupIndex";
919
+ OrderColumn["CATEGORY"] = "category";
920
+ OrderColumn["CATEGORYINDEX"] = "categoryIndex";
921
+ OrderColumn["SUBCATEGORY"] = "subCategory";
922
+ OrderColumn["SUBCATEGORYINDEX"] = "subCategoryIndex";
923
+ OrderColumn["AC1"] = "ac1";
924
+ OrderColumn["AC2"] = "ac2";
925
+ OrderColumn["AC3"] = "ac3";
926
+ OrderColumn["AC4"] = "ac4";
927
+ OrderColumn["PP1"] = "pp1";
928
+ OrderColumn["PP2"] = "pp2";
929
+ OrderColumn["PP3"] = "pp3";
930
+ OrderColumn["PP4"] = "pp4";
931
+ OrderColumn["FC1"] = "fc1";
932
+ OrderColumn["FC2"] = "fc2";
933
+ OrderColumn["FC3"] = "fc3";
934
+ OrderColumn["FC4"] = "fc4";
935
+ OrderColumn["PL1"] = "pl1";
936
+ OrderColumn["PL2"] = "pl2";
937
+ OrderColumn["PL3"] = "pl3";
938
+ OrderColumn["PL4"] = "pl4";
939
+ })(OrderColumn || (OrderColumn = {}));
940
+ class Order {
941
+ /**
942
+ * @param hierarchy Columns for multi-level sorting, applied left-to-right (e.g. `["rowGroup", "category"]`).
943
+ * @param direction Sort direction applied to all hierarchy levels.
944
+ */
945
+ constructor(hierarchy = ["category"], direction = OrderDirection.ASC) {
946
+ this.hierarchy = hierarchy;
947
+ this.direction = direction;
948
+ }
949
+ }
950
+ class OrderAdapter {
951
+ constructor(stringAdapter) {
952
+ this.stringAdapter = stringAdapter;
953
+ }
954
+ adapt(data) {
955
+ var _a;
956
+ const hierarchy = AdapterUtils.adaptArray(data.hierarchy, this.stringAdapter);
957
+ const order = OrderDirection[(_a = data.direction) === null || _a === void 0 ? void 0 : _a.toUpperCase()] || OrderDirection.ASC;
958
+ return new Order(hierarchy.map((str) => OrderColumn[str.toUpperCase()] || OrderColumn.CATEGORY), order);
959
+ }
960
+ default() {
961
+ return new Order(["category"], OrderDirection.ASC);
962
+ }
963
+ }
964
+
965
+ /** Text shown for a relative variance whose reference is 0. */
966
+ const NOT_AVAILABLE = "n/a";
967
+ /**
968
+ * Relative variance (a - b) / |b|, from the difference a - b and the reference b.
969
+ * undefined: the reference is 0, callers show NOT_AVAILABLE and no bar.
970
+ * The reference counts as 0 also when it is 0 up to float rounding: a ratio above 1e9.
971
+ * NaN: an input is NaN, missing data stays missing.
972
+ */
973
+ function relativeVariance(difference, reference) {
974
+ // a reference of 0, or 0 up to the float rounding of its sum, has no meaningful ratio
975
+ if (Math.abs(reference) <= Math.abs(difference) * 1e-9)
976
+ return undefined;
977
+ return difference / Math.abs(reference);
978
+ }
979
+
980
+ /**
981
+ * Variance-token parser for XY chart axis measures.
982
+ *
983
+ * Reuses the engine's variance grammar (`d{base}_{delta}_{sentiment}` /
984
+ * `dr{base}_{delta}_{sentiment}`) with one deviation from
985
+ * {@link VarianceScenario}: on axes the trailing sentiment segment is
986
+ * **optional and ignored** - position encodes the value, there is no
987
+ * pos/neg coloring. The regex is anchored, so partial matches inside a
988
+ * longer token are rejected.
989
+ */
990
+ const VARIANCE_MEASURE_REGEX = /^(dr|d)((?:ac|pp|fc|pl)[1-4])_((?:ac|pp|fc|pl)[1-4])(?:_(pos|neg|neu))?$/;
991
+ class VarianceMeasure {
992
+ constructor(
993
+ /** `"d"` = absolute, `"dr"` = relative (fraction of delta). */
994
+ type,
995
+ /** Minuend scenario slot, e.g. `"ac1"`. */
996
+ base,
997
+ /** Subtrahend scenario slot, e.g. `"pp1"`. */
998
+ delta) {
999
+ this.type = type;
1000
+ this.base = base;
1001
+ this.delta = delta;
1002
+ }
1003
+ /** Parses a variance token; returns `null` when the token doesn't match the grammar. */
1004
+ static parse(token) {
1005
+ const match = VARIANCE_MEASURE_REGEX.exec(token);
1006
+ if (match === null) {
1007
+ return null;
1008
+ }
1009
+ return new VarianceMeasure(match[1], match[2], match[3]);
1010
+ }
1011
+ /**
1012
+ * Computes the variance value, mirroring the null-safe math of the
1013
+ * existing charts: absolute = `base - delta`, relative =
1014
+ * `(base - delta) / |delta|`. Returns `null` when either operand is
1015
+ * missing or a relative variance would divide by zero.
1016
+ */
1017
+ compute(base, delta) {
1018
+ var _a;
1019
+ if (base == null || delta == null) {
1020
+ return null;
1021
+ }
1022
+ if (this.type === "dr") {
1023
+ if (delta === 0) {
1024
+ return null;
1025
+ }
1026
+ return (_a = relativeVariance(base - delta, delta)) !== null && _a !== void 0 ? _a : null;
1027
+ }
1028
+ return base - delta;
1029
+ }
1030
+ }
1031
+ /**
1032
+ * Resolves a measure token to a scenario slot or a variance measure.
1033
+ * Returns `null` for tokens matching neither vocabulary.
1034
+ */
1035
+ function resolveMeasure(token) {
1036
+ const trimmed = token.trim();
1037
+ if (Object.values(Scenarios).includes(trimmed)) {
1038
+ return { kind: "scenario", slot: trimmed };
1039
+ }
1040
+ const variance = VarianceMeasure.parse(trimmed);
1041
+ if (variance !== null) {
1042
+ return { kind: "variance", measure: variance };
1043
+ }
1044
+ return null;
1045
+ }
1046
+ /**
1047
+ * Scenario family (`ac` | `pp` | `fc` | `pl`) of a plain scenario slot.
1048
+ */
1049
+ function scenarioFamily(slot) {
1050
+ return slot.replace(/\d+$/, "");
1051
+ }
1052
+ /** Slot number (`1`-`4`) of a plain scenario slot. */
1053
+ function scenarioSlotNumber(slot) {
1054
+ return slot.replace(/^[a-z]+/, "");
1055
+ }
1056
+ /** True for a relative variance token (`dr…`): its values are fractions and are shown in percent. */
1057
+ function isRelativeMeasure(token) {
1058
+ var _a;
1059
+ return ((_a = VarianceMeasure.parse(token.trim())) === null || _a === void 0 ? void 0 : _a.type) === "dr";
1060
+ }
1061
+ /**
1062
+ * The axis config in the unit of the axis values. A relative variance axis is written
1063
+ * in percent (`min: -40`, `refLine: 20`), while its values are fractions (0.2 for 20 %).
1064
+ */
1065
+ function axisInValueUnits(axis) {
1066
+ if (!isRelativeMeasure(axis.measure)) {
1067
+ return axis;
1068
+ }
1069
+ const fraction = (percent) => percent === undefined ? undefined : percent / 100;
1070
+ return Object.assign(Object.assign({}, axis), { min: fraction(axis.min), max: fraction(axis.max), refLine: fraction(axis.refLine), highlight: axis.highlight && { from: fraction(axis.highlight.from), to: fraction(axis.highlight.to) } });
1071
+ }
1072
+
600
1073
  /**
601
1074
  * Prop validators for Stencil @Watch handlers.
602
1075
  *
@@ -870,7 +1343,7 @@ function validateStackConfig(value) {
870
1343
  /**
871
1344
  * Checks whether a value is a valid XY chart measure token: a scenario
872
1345
  * column (`ac1`…`pl4`) or a variance token (`d…`/`dr…`, sentiment suffix
873
- * optional — spec §4.4 of the scatter/bubble charts).
1346
+ * optional - spec §4.4 of the scatter/bubble charts).
874
1347
  */
875
1348
  function isValidMeasureToken(value) {
876
1349
  if (isBlankInput(value)) {
@@ -894,7 +1367,7 @@ class StyleSheet {
894
1367
  }
895
1368
  apply(data) {
896
1369
  data.forEach((value) => this.cache.set(value.className, value.style));
897
- this.tag.innerHTML = Array.from(this.cache.values())
1370
+ this.tag.textContent = Array.from(this.cache.values())
898
1371
  .map((value) => value)
899
1372
  .join("\n");
900
1373
  }
@@ -1041,9 +1514,19 @@ function getStyle(attr, className, value) {
1041
1514
  return `.${className} {${attr.cssName}: ${value};}`;
1042
1515
  }
1043
1516
  function getCSS(attr, value) {
1517
+ // The rule is written as stylesheet text. Only what the browser parsed and serialized as one value
1518
+ // of this property goes in: the attribute text itself could close the rule and add its own.
1519
+ const probe = document.createElement("div").style;
1520
+ probe.setProperty(attr.cssName, value);
1521
+ const parsed = probe.getPropertyValue(attr.cssName);
1522
+ // A var() value is kept as written and may end inside an open string or bracket, which would swallow
1523
+ // the rules after it. A declaration placed behind the value only arrives if the value is closed.
1524
+ probe.cssText = `${attr.cssName}:${parsed};--bn-end:1`;
1525
+ if (!parsed || parsed.includes("<") || probe.getPropertyValue("--bn-end") !== "1") {
1526
+ return undefined;
1527
+ }
1044
1528
  const className = getClassName(attr, value);
1045
- const style = getStyle(attr, className, value);
1046
- return { className, style };
1529
+ return { className, style: getStyle(attr, className, parsed) };
1047
1530
  }
1048
1531
  const apply = (el) => {
1049
1532
  const map = new Map();
@@ -1058,7 +1541,10 @@ const apply = (el) => {
1058
1541
  function (v) {
1059
1542
  return v;
1060
1543
  };
1061
- map.set(name, getCSS(attributes[name], transform(value)));
1544
+ const css = getCSS(attributes[name], transform(value));
1545
+ if (css) {
1546
+ map.set(name, css);
1547
+ }
1062
1548
  }
1063
1549
  });
1064
1550
  return map;
@@ -1126,10 +1612,10 @@ const withStyled = (component) => {
1126
1612
  runIfExisits(cstrConnectedCallback, component);
1127
1613
  };
1128
1614
  component["disconnectedCallback"] = () => {
1129
- // MutationObserver has no per-element unobserve — the shared observer
1615
+ // MutationObserver has no per-element unobserve - the shared observer
1130
1616
  // automatically stops firing for elements removed from the DOM.
1131
1617
  runIfExisits(cstrDisconnectedCallback, component);
1132
1618
  };
1133
1619
  };
1134
1620
 
1135
- export { validateColumnThereOfJsonStr as A, validateAttributesJsonStr as B, parseTableAttributeExpression as C, DateDistance as D, validateMeasureList as E, isValidDate as F, isValidDateLink as G, DateLink as H, isValidInteger as a, withComponentStyle as b, isValidMeasureToken as c, isValidDirection as d, isValidBoolean as e, isValidNumber as f, validateScenarioList as g, validateVariancesList as h, isBlankInput as i, isValidLevel as j, isValidMeasureScale as k, validateStackConfig as l, isValidDateFormat as m, isValidAxisLabelsMode as n, murmur2 as o, DateStringFactory as p, validateBarColumnsList as q, isTableBarColumnWidth as r, isValidDataFormat as s, isValidTableType as t, validateThereOfJsonStr as u, validateOrderList as v, withStyled as w, validatePartOfJsonStr as x, isValidMeasureType as y, isTableCategoryWidth as z };
1621
+ export { scenarioSlotNumber as $, AggregationLevel as A, DateStringFactory as B, CompareUtil as C, DateDistance as D, validateBarColumnsList as E, isTableBarColumnWidth as F, isValidDataFormat as G, isValidTableType as H, validateThereOfJsonStr as I, validatePartOfJsonStr as J, isValidMeasureType as K, isTableCategoryWidth as L, validateColumnThereOfJsonStr as M, validateAttributesJsonStr as N, OrderDirection as O, DataFormat as P, I18nMode as Q, MeasureType as R, StackBy as S, TableCategoryWidth as T, parseTableAttributeExpression as U, BAR_COLUMN_WIDTH_EM as V, TableBarColumnWidth as W, validateMeasureList as X, isValidDate as Y, isValidDateLink as Z, DateLink as _, withComponentStyle as a, axisInValueUnits as a0, isRelativeMeasure as a1, AdapterUtils as a2, OrderAdapter as a3, NOT_AVAILABLE as a4, relativeVariance as a5, RELATIVE_STACK_UNITS as a6, FIELD_IDENTIFIER_REGEX as a7, Scenarios as a8, isBlankInput as b, isValidInteger as c, isValidMeasureToken as d, isValidDirection as e, Order as f, OrderColumn as g, validateScenarioList as h, isValidBoolean as i, validateVariancesList as j, isValidLevel as k, isValidMeasureScale as l, merge as m, validateStackConfig as n, StackOrder as o, StackMode as p, isValidNumber as q, resolveMeasure as r, scenarioFamily as s, isValidDateFormat as t, isValidAxisLabelsMode as u, validateOrderList as v, withStyled as w, AxisLabelsMode as x, ChartMode as y, murmur2 as z };