@semcore/d3-chart 18.0.0-prerelease.2 → 18.0.0-prerelease.5

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 (203) hide show
  1. package/CHANGELOG.md +45 -3
  2. package/README.md +0 -1
  3. package/lib/cjs/Area.js +12 -12
  4. package/lib/cjs/Bar.js +16 -16
  5. package/lib/cjs/Bubble.js +14 -14
  6. package/lib/cjs/CompactHorizontalBar.js +17 -17
  7. package/lib/cjs/CompactHorizontalBar.js.map +1 -1
  8. package/lib/cjs/Donut.js +9 -9
  9. package/lib/cjs/Dots.js +12 -12
  10. package/lib/cjs/GroupBar.js +5 -2
  11. package/lib/cjs/GroupBar.js.map +1 -1
  12. package/lib/cjs/HorizontalBar.js +16 -16
  13. package/lib/cjs/Hover.js +2 -13
  14. package/lib/cjs/Hover.js.map +1 -1
  15. package/lib/cjs/Line.js +9 -9
  16. package/lib/cjs/RadialTree.js +12 -12
  17. package/lib/cjs/Reference.js +12 -12
  18. package/lib/cjs/ScatterPlot.js +9 -9
  19. package/lib/cjs/Tooltip.js +12 -12
  20. package/lib/cjs/Venn.js +9 -9
  21. package/lib/cjs/component/Chart/AbstractChart.js +20 -17
  22. package/lib/cjs/component/Chart/AbstractChart.js.map +1 -1
  23. package/lib/cjs/component/Chart/AbstractChart.type.js.map +1 -1
  24. package/lib/cjs/component/Chart/AreaChart.js +1 -1
  25. package/lib/cjs/component/Chart/AreaChart.js.map +1 -1
  26. package/lib/cjs/component/Chart/AreaChart.type.js.map +1 -1
  27. package/lib/cjs/component/Chart/BarChart.js +12 -6
  28. package/lib/cjs/component/Chart/BarChart.js.map +1 -1
  29. package/lib/cjs/component/Chart/BarChart.type.js.map +1 -1
  30. package/lib/cjs/component/Chart/CigaretteChart.js +5 -1
  31. package/lib/cjs/component/Chart/CigaretteChart.js.map +1 -1
  32. package/lib/cjs/component/Chart/HistogramChart.js +1 -1
  33. package/lib/cjs/component/Chart/HistogramChart.js.map +1 -1
  34. package/lib/cjs/component/Chart/HistogramChart.type.js.map +1 -1
  35. package/lib/cjs/component/Chart/LineChart.js +1 -1
  36. package/lib/cjs/component/Chart/LineChart.js.map +1 -1
  37. package/lib/cjs/component/Chart/LineChart.type.js.map +1 -1
  38. package/lib/cjs/component/ChartLegend/BaseLegend.js +0 -4
  39. package/lib/cjs/component/ChartLegend/BaseLegend.js.map +1 -1
  40. package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js +3 -1
  41. package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
  42. package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js +28 -21
  43. package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
  44. package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.type.js.map +1 -1
  45. package/lib/cjs/component/ChartLegend/LegendTable/legend-table.shadow.css +30 -14
  46. package/lib/cjs/component/Cigarette/Cigarette.js +0 -1
  47. package/lib/cjs/component/Cigarette/Cigarette.js.map +1 -1
  48. package/lib/cjs/component/Metric/Metric.js +78 -0
  49. package/lib/cjs/component/Metric/Metric.js.map +1 -0
  50. package/lib/cjs/component/Metric/Metric.type.js +2 -0
  51. package/lib/cjs/component/Metric/Metric.type.js.map +1 -0
  52. package/lib/cjs/index.js +8 -8
  53. package/lib/cjs/index.js.map +1 -1
  54. package/lib/cjs/style/abstract-chart.shadow.css +1 -1
  55. package/lib/cjs/style/area.shadow.css +0 -2
  56. package/lib/cjs/style/bar.shadow.css +1 -3
  57. package/lib/cjs/style/bubble.shadow.css +1 -3
  58. package/lib/cjs/style/donut.shadow.css +1 -3
  59. package/lib/cjs/style/dot.shadow.css +1 -3
  60. package/lib/cjs/style/line.shadow.css +0 -2
  61. package/lib/cjs/style/radial-tree.shadow.css +1 -3
  62. package/lib/cjs/style/reference.shadow.css +1 -1
  63. package/lib/cjs/style/scatterplot.shadow.css +1 -3
  64. package/lib/cjs/style/tooltip.shadow.css +0 -2
  65. package/lib/cjs/style/venn.shadow.css +0 -2
  66. package/lib/cjs/types/index.d.js +20 -0
  67. package/lib/cjs/types/index.d.js.map +1 -1
  68. package/lib/es6/Area.js +12 -12
  69. package/lib/es6/Bar.js +16 -16
  70. package/lib/es6/Bubble.js +14 -14
  71. package/lib/es6/CompactHorizontalBar.js +17 -17
  72. package/lib/es6/CompactHorizontalBar.js.map +1 -1
  73. package/lib/es6/Donut.js +9 -9
  74. package/lib/es6/Dots.js +12 -12
  75. package/lib/es6/GroupBar.js +5 -2
  76. package/lib/es6/GroupBar.js.map +1 -1
  77. package/lib/es6/HorizontalBar.js +16 -16
  78. package/lib/es6/Hover.js +2 -13
  79. package/lib/es6/Hover.js.map +1 -1
  80. package/lib/es6/Line.js +9 -9
  81. package/lib/es6/RadialTree.js +12 -12
  82. package/lib/es6/Reference.js +12 -12
  83. package/lib/es6/ScatterPlot.js +9 -9
  84. package/lib/es6/Tooltip.js +12 -12
  85. package/lib/es6/Venn.js +9 -9
  86. package/lib/es6/component/Chart/AbstractChart.js +20 -17
  87. package/lib/es6/component/Chart/AbstractChart.js.map +1 -1
  88. package/lib/es6/component/Chart/AbstractChart.type.js.map +1 -1
  89. package/lib/es6/component/Chart/AreaChart.js +1 -1
  90. package/lib/es6/component/Chart/AreaChart.js.map +1 -1
  91. package/lib/es6/component/Chart/AreaChart.type.js.map +1 -1
  92. package/lib/es6/component/Chart/BarChart.js +12 -6
  93. package/lib/es6/component/Chart/BarChart.js.map +1 -1
  94. package/lib/es6/component/Chart/BarChart.type.js.map +1 -1
  95. package/lib/es6/component/Chart/CigaretteChart.js +5 -1
  96. package/lib/es6/component/Chart/CigaretteChart.js.map +1 -1
  97. package/lib/es6/component/Chart/HistogramChart.js +1 -1
  98. package/lib/es6/component/Chart/HistogramChart.js.map +1 -1
  99. package/lib/es6/component/Chart/HistogramChart.type.js.map +1 -1
  100. package/lib/es6/component/Chart/LineChart.js +1 -1
  101. package/lib/es6/component/Chart/LineChart.js.map +1 -1
  102. package/lib/es6/component/Chart/LineChart.type.js.map +1 -1
  103. package/lib/es6/component/ChartLegend/BaseLegend.js +0 -4
  104. package/lib/es6/component/ChartLegend/BaseLegend.js.map +1 -1
  105. package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js +3 -1
  106. package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
  107. package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js +28 -21
  108. package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
  109. package/lib/es6/component/ChartLegend/LegendTable/LegendTable.type.js.map +1 -1
  110. package/lib/es6/component/ChartLegend/LegendTable/legend-table.shadow.css +30 -14
  111. package/lib/es6/component/Cigarette/Cigarette.js +0 -1
  112. package/lib/es6/component/Cigarette/Cigarette.js.map +1 -1
  113. package/lib/es6/component/Metric/Metric.js +72 -0
  114. package/lib/es6/component/Metric/Metric.js.map +1 -0
  115. package/lib/es6/component/Metric/Metric.type.js +2 -0
  116. package/lib/es6/component/Metric/Metric.type.js.map +1 -0
  117. package/lib/es6/index.js +1 -1
  118. package/lib/es6/index.js.map +1 -1
  119. package/lib/es6/style/abstract-chart.shadow.css +1 -1
  120. package/lib/es6/style/area.shadow.css +0 -2
  121. package/lib/es6/style/bar.shadow.css +1 -3
  122. package/lib/es6/style/bubble.shadow.css +1 -3
  123. package/lib/es6/style/donut.shadow.css +1 -3
  124. package/lib/es6/style/dot.shadow.css +1 -3
  125. package/lib/es6/style/line.shadow.css +0 -2
  126. package/lib/es6/style/radial-tree.shadow.css +1 -3
  127. package/lib/es6/style/reference.shadow.css +1 -1
  128. package/lib/es6/style/scatterplot.shadow.css +1 -3
  129. package/lib/es6/style/tooltip.shadow.css +0 -2
  130. package/lib/es6/style/venn.shadow.css +0 -2
  131. package/lib/es6/types/index.d.js +5 -7
  132. package/lib/es6/types/index.d.js.map +1 -1
  133. package/lib/esm/Area.mjs +13 -13
  134. package/lib/esm/Bar.mjs +17 -17
  135. package/lib/esm/Bubble.mjs +15 -15
  136. package/lib/esm/CompactHorizontalBar.mjs +18 -18
  137. package/lib/esm/Donut.mjs +10 -10
  138. package/lib/esm/Dots.mjs +13 -13
  139. package/lib/esm/GroupBar.mjs +5 -2
  140. package/lib/esm/HorizontalBar.mjs +17 -17
  141. package/lib/esm/Hover.mjs +2 -13
  142. package/lib/esm/Line.mjs +10 -10
  143. package/lib/esm/RadialTree.mjs +13 -13
  144. package/lib/esm/Reference.mjs +13 -13
  145. package/lib/esm/ScatterPlot.mjs +10 -10
  146. package/lib/esm/Tooltip.mjs +13 -13
  147. package/lib/esm/Venn.mjs +10 -10
  148. package/lib/esm/component/Chart/AbstractChart.mjs +19 -18
  149. package/lib/esm/component/Chart/AreaChart.mjs +1 -1
  150. package/lib/esm/component/Chart/BarChart.mjs +12 -6
  151. package/lib/esm/component/Chart/CigaretteChart.mjs +5 -1
  152. package/lib/esm/component/Chart/HistogramChart.mjs +1 -1
  153. package/lib/esm/component/Chart/LineChart.mjs +1 -1
  154. package/lib/esm/component/ChartLegend/BaseLegend.mjs +0 -4
  155. package/lib/esm/component/ChartLegend/LegendItem/LegendItem.mjs +3 -1
  156. package/lib/esm/component/ChartLegend/LegendTable/LegendTable.mjs +29 -22
  157. package/lib/esm/component/ChartLegend/LegendTable/legend-table.shadow.css +30 -14
  158. package/lib/esm/component/Cigarette/Cigarette.mjs +0 -1
  159. package/lib/esm/component/Metric/Metric.mjs +62 -0
  160. package/lib/esm/index.mjs +34 -34
  161. package/lib/esm/style/abstract-chart.shadow.css +1 -1
  162. package/lib/esm/style/area.shadow.css +0 -2
  163. package/lib/esm/style/bar.shadow.css +1 -3
  164. package/lib/esm/style/bubble.shadow.css +1 -3
  165. package/lib/esm/style/donut.shadow.css +1 -3
  166. package/lib/esm/style/dot.shadow.css +1 -3
  167. package/lib/esm/style/line.shadow.css +0 -2
  168. package/lib/esm/style/radial-tree.shadow.css +1 -3
  169. package/lib/esm/style/reference.shadow.css +1 -1
  170. package/lib/esm/style/scatterplot.shadow.css +1 -3
  171. package/lib/esm/style/tooltip.shadow.css +0 -2
  172. package/lib/esm/style/venn.shadow.css +0 -2
  173. package/lib/types/component/Chart/AbstractChart.d.ts +8 -4
  174. package/lib/types/component/Chart/AbstractChart.d.ts.map +1 -1
  175. package/lib/types/component/Chart/AbstractChart.type.d.ts +9 -7
  176. package/lib/types/component/Chart/AbstractChart.type.d.ts.map +1 -1
  177. package/lib/types/component/Chart/AreaChart.type.d.ts +1 -1
  178. package/lib/types/component/Chart/AreaChart.type.d.ts.map +1 -1
  179. package/lib/types/component/Chart/BarChart.d.ts.map +1 -1
  180. package/lib/types/component/Chart/BarChart.type.d.ts +3 -1
  181. package/lib/types/component/Chart/BarChart.type.d.ts.map +1 -1
  182. package/lib/types/component/Chart/CigaretteChart.d.ts.map +1 -1
  183. package/lib/types/component/Chart/HistogramChart.type.d.ts +1 -1
  184. package/lib/types/component/Chart/HistogramChart.type.d.ts.map +1 -1
  185. package/lib/types/component/Chart/LineChart.type.d.ts +1 -1
  186. package/lib/types/component/Chart/LineChart.type.d.ts.map +1 -1
  187. package/lib/types/component/ChartLegend/BaseLegend.d.ts.map +1 -1
  188. package/lib/types/component/ChartLegend/LegendTable/LegendTable.d.ts.map +1 -1
  189. package/lib/types/component/ChartLegend/LegendTable/LegendTable.type.d.ts +5 -3
  190. package/lib/types/component/ChartLegend/LegendTable/LegendTable.type.d.ts.map +1 -1
  191. package/lib/types/component/Metric/Metric.d.ts +9 -0
  192. package/lib/types/component/Metric/Metric.d.ts.map +1 -0
  193. package/lib/types/component/Metric/Metric.type.d.ts +33 -0
  194. package/lib/types/component/Metric/Metric.type.d.ts.map +1 -0
  195. package/lib/types/index.d.ts +5 -7
  196. package/package.json +16 -15
  197. package/lib/cjs/color.js +0 -132
  198. package/lib/cjs/color.js.map +0 -1
  199. package/lib/cjs/style/var.css +0 -125
  200. package/lib/es6/color.js +0 -127
  201. package/lib/es6/color.js.map +0 -1
  202. package/lib/es6/style/var.css +0 -125
  203. package/lib/esm/color.mjs +0 -127
@@ -1 +1 @@
1
- {"version":3,"file":"Hover.js","names":["Component","sstyled","Root","canUseDOM","getFocusableIn","hasParent","trottle","useEnhancedEffect","React","createElement","style","_sstyled","insert","Tooltip","scaleOfBandwidth","getIndexFromData","eventToPoint","invert","scaleToBand","STROKE_WIDTH","NOTCH_WIDTH","NOTCH_DELTA","formatValue","locale","value","Date","Intl","DateTimeFormat","day","month","format","Hover","constructor","args","_defineProperty","xIndex","yIndex","document","e","currentTarget","isTickUnder","eventEmitter","data","scale","x","y","rootRef","patterns","plotId","asProps","clientX","clientY","xScale","yScale","pX","pY","current","vX","vY","undefined","state","xRect","yRect","height","getBoundingClientRect","yOriginal","heightOriginal","isRootTooltip","target","setState","diff","dimension","heightValue","emit","componentDidMount","unsubscribeMouseMoveRoot","subscribe","_","persist","handlerMouseMoveRoot","unsubscribeMouseLeaveRoot","handlerMouseLeaveRoot","componentWillUnmount","HoverLineRoot","render","_ref3","hideHoverLine","meta","isHide","SHoverLine","Element","styles","dataHints","hideTickHover","xRange","range","yRange","x1","y1","Fragment","cn","HoveredTick","getTicksSize","getTicksPosition","titles","getHorizontalAxesTitle","bind","length","HoverRectRoot","_ref4","SHoverRect","xBand","yBand","xStep","step","xPaddingInner","paddingInner","yStep","yPaddingInner","HOVERED_TICK_MARGIN_Y","HOVERED_TICK_PADDING_Y","HOVERED_TICK_PADDING_X","props","_ref5","tickFormatter","isFirstTick","isLastTick","size","position","contentRef","useRef","interactive","setInteractive","useState","formattedValue","isMightBeInteractive","width","SHoveredTickWrapper","SHoveredTickContent","SHoveredTick","w","tickX","tickY","HoverLineTooltip","_ref","arguments[0]","_ref6","SHoverLineTooltip","_assignProps","HoverLine","HoverRectTooltip","_ref2","_ref7","SHoverRectTooltip","_assignProps2","HoverRect","_______childrenComponents"],"sources":["../../src/Hover.jsx"],"sourcesContent":["import { Component, sstyled, Root } from '@semcore/core';\nimport canUseDOM from '@semcore/core/lib/utils/canUseDOM';\nimport { getFocusableIn } from '@semcore/core/lib/utils/focus-lock/getFocusableIn';\nimport { hasParent } from '@semcore/core/lib/utils/hasParent';\nimport trottle from '@semcore/core/lib/utils/rafTrottle';\nimport useEnhancedEffect from '@semcore/core/lib/utils/use/useEnhancedEffect';\nimport React from 'react';\n\nimport createElement from './createElement';\nimport style from './style/hover.shadow.css';\nimport Tooltip from './Tooltip';\nimport { scaleOfBandwidth, getIndexFromData, eventToPoint, invert, scaleToBand } from './utils';\n\nconst STROKE_WIDTH = 1;\nconst NOTCH_WIDTH = 9;\nconst NOTCH_DELTA = NOTCH_WIDTH / 2 - STROKE_WIDTH / 4;\n\nfunction formatValue(locale, value) {\n if (value instanceof Date) {\n return new Intl.DateTimeFormat(locale ?? 'en', {\n day: 'numeric',\n month: 'short',\n }).format(value);\n }\n return value;\n}\nclass Hover extends Component {\n static style = style;\n\n state = {\n xIndex: null,\n yIndex: null,\n };\n\n virtualElement = canUseDOM() ? document.createElement('div') : {};\n\n handlerMouseMoveRoot = trottle((e, currentTarget, isTickUnder) => {\n const { eventEmitter, data, scale, x, y, rootRef, patterns, plotId } = this.asProps;\n const { clientX, clientY } = e;\n const [xScale, yScale] = scale;\n const [pX, pY] = eventToPoint(e, rootRef.current);\n const vX = invert(xScale, pX);\n const vY = invert(yScale, pY);\n const xIndex = x === undefined || vX === undefined ? null : getIndexFromData(data, xScale, x, vX);\n const yIndex = y === undefined || vY === undefined ? null : getIndexFromData(data, yScale, y, vY);\n const state = { xIndex, yIndex, patterns };\n\n const { x: xRect, y: yRect, height } = rootRef.current.getBoundingClientRect();\n const { y: yOriginal, height: heightOriginal } = currentTarget.getBoundingClientRect();\n const isRootTooltip = hasParent(e.target, rootRef.current);\n\n this.setState(state, () => {\n let x, y;\n\n if (isRootTooltip) {\n x = clientX;\n // preserve static vertical position if it's a move on a tick.\n y = isTickUnder ? yRect + height / 2 : clientY;\n } else {\n const diff = clientY - yOriginal;\n const dimension = (diff / heightOriginal) * 100;\n const heightValue = (height / 100) * dimension;\n\n x = pX + xRect;\n // preserve static vertical position if it's a move on tick.\n y = isTickUnder ? yRect + height / 2 : yRect + heightValue;\n }\n\n eventEmitter.emit(`setTooltipPosition_${plotId}`, x, y);\n eventEmitter.emit(`setTooltipRenderingProps_${plotId}`, {}, state);\n eventEmitter.emit(`setTooltipVisible_${plotId}`, xIndex !== null || yIndex !== null);\n });\n });\n\n handlerMouseLeaveRoot = trottle(() => {\n const state = {\n xIndex: null,\n yIndex: null,\n patterns: this.asProps.patterns,\n };\n this.setState(state, () => {\n this.asProps.eventEmitter.emit(`setTooltipVisible_${this.asProps.plotId}`, false);\n });\n });\n\n componentDidMount() {\n const { eventEmitter } = this.asProps;\n this.unsubscribeMouseMoveRoot = eventEmitter.subscribe('onMouseMoveChart', (e, _, isTickUnder) => {\n e.persist();\n this.handlerMouseMoveRoot(e, e.currentTarget, isTickUnder);\n });\n this.unsubscribeMouseLeaveRoot = eventEmitter.subscribe('onMouseLeaveChart', this.handlerMouseLeaveRoot);\n }\n\n componentWillUnmount() {\n if (this.unsubscribeMouseMoveRoot) {\n this.unsubscribeMouseMoveRoot();\n }\n if (this.unsubscribeMouseLeaveRoot) {\n this.unsubscribeMouseLeaveRoot();\n }\n }\n}\n\nclass HoverLineRoot extends Hover {\n static displayName = 'HoverLine';\n\n render() {\n const { hideHoverLine, meta, locale } = this.asProps;\n const { xIndex, yIndex } = this.state;\n\n const isHide = typeof hideHoverLine === 'function' ? hideHoverLine(xIndex, yIndex) : hideHoverLine;\n\n if (isHide) {\n return null;\n }\n\n const SHoverLine = this.Element;\n const { styles, x, y, data, scale, dataHints, hideTickHover } = this.asProps;\n const [xScale, yScale] = scale;\n\n const xRange = xScale.range();\n const yRange = yScale.range();\n const x1 = xIndex !== null ? scaleOfBandwidth(xScale, data[xIndex][x]) : undefined;\n const y1 = yIndex !== null ? scaleOfBandwidth(yScale, data[yIndex][y]) : undefined;\n\n return sstyled(styles)(\n <>\n {xIndex !== null\n ? (\n <>\n <SHoverLine render='g' index={xIndex} stroke-width={STROKE_WIDTH} aria-hidden>\n <line x1={x1 - NOTCH_DELTA} x2={x1 + NOTCH_DELTA} y1={yRange[0]} y2={yRange[0]} />\n <line x1={x1} y1={yRange[0]} x2={x1} y2={yRange[1]} />\n <line x1={x1 - NOTCH_DELTA} x2={x1 + NOTCH_DELTA} y1={yRange[1]} y2={yRange[1]} />\n </SHoverLine>\n {!hideTickHover && (\n <HoveredTick\n size={meta.getTicksSize('horizontal')}\n position={meta.getTicksPosition('horizontal')}\n tickFormatter={dataHints.titles.getHorizontalAxesTitle ?? formatValue.bind(null, locale)}\n value={data[xIndex]?.[x]}\n isFirstTick={xIndex === 0}\n isLastTick={xIndex === data.length - 1}\n styles={styles}\n x={x1}\n yRange={yRange}\n />\n )}\n </>\n )\n : null}\n {yIndex !== null\n ? (\n <SHoverLine render='g' index={yIndex} stroke-width={STROKE_WIDTH} aria-hidden>\n <line x1={xRange[0]} y1={y1 - NOTCH_DELTA} x2={xRange[0]} y2={y1 + NOTCH_DELTA} />\n <line x1={xRange[0]} y1={y1} x2={xRange[1]} y2={y1} />\n <line x1={xRange[1]} y1={y1 - NOTCH_DELTA} x2={xRange[1]} y2={y1 + NOTCH_DELTA} />\n </SHoverLine>\n )\n : null}\n </>,\n );\n }\n}\n\nclass HoverRectRoot extends Hover {\n static displayName = 'HoverRect';\n\n render() {\n const { hideHoverLine, meta } = this.asProps;\n\n if (hideHoverLine) {\n return null;\n }\n\n const SHoverRect = this.Element;\n const { styles, x, y, data, scale, dataHints, hideTickHover, locale } = this.asProps;\n const { xIndex, yIndex } = this.state;\n const [xScale, yScale] = scale;\n\n const xRange = xScale.range();\n const yRange = yScale.range();\n const xBand = scaleToBand(xScale);\n const yBand = scaleToBand(yScale);\n\n const xStep = xBand.step();\n const xPaddingInner = xBand.paddingInner();\n const yStep = yBand.step();\n const yPaddingInner = yBand.paddingInner();\n\n return sstyled(styles)(\n <>\n {xIndex !== null && (\n <>\n <SHoverRect\n aria-hidden\n render='rect'\n index={xIndex}\n width={xStep - xPaddingInner / 2}\n height={yRange[0] - yRange[1]}\n x={xScale(data[xIndex][x]) - (xStep * xPaddingInner) / 2}\n y={yRange[1]}\n />\n {!hideTickHover && (\n <HoveredTick\n size={meta.getTicksSize('horizontal')}\n position={meta.getTicksPosition('horizontal')}\n tickFormatter={dataHints.titles.getHorizontalAxesTitle ?? formatValue.bind(null, locale)}\n value={data[xIndex]?.[x]}\n styles={styles}\n x={xScale(data[xIndex][x]) + (xStep * (1 - xPaddingInner)) / 2}\n yRange={yRange}\n />\n )}\n </>\n )}\n {yIndex !== null && (\n <SHoverRect\n aria-hidden\n render='rect'\n index={yIndex}\n width={xRange[1] - xRange[0]}\n height={yStep - yPaddingInner / 2}\n x={xRange[0]}\n y={yScale(data[yIndex][y]) - (yStep * yPaddingInner) / 2}\n />\n )}\n </>,\n );\n }\n}\n\nconst HOVERED_TICK_MARGIN_Y = 8;\nconst HOVERED_TICK_PADDING_Y = 3;\nconst HOVERED_TICK_PADDING_X = 12;\n\nfunction HoveredTick(props) {\n const { tickFormatter, value, isFirstTick = false, isLastTick = false, styles, x, yRange, size, position } = props;\n\n const contentRef = React.useRef(null);\n const [interactive, setInteractive] = React.useState(false);\n\n const formattedValue = tickFormatter(value);\n\n const isMightBeInteractive = formattedValue !== null && typeof formattedValue === 'object';\n\n useEnhancedEffect(() => {\n if (!isMightBeInteractive || !contentRef.current) {\n setInteractive(false);\n return;\n }\n\n setInteractive(getFocusableIn(contentRef.current).length > 0);\n });\n\n if (size?.width === undefined || size?.height === undefined || position === null) return null;\n\n const { width, height } = size;\n\n const SHoveredTickWrapper = 'foreignObject';\n const SHoveredTickContent = 'div';\n const SHoveredTick = 'span';\n\n const w = width + HOVERED_TICK_PADDING_X * 2;\n const tickX = isFirstTick\n ? x\n : isLastTick\n ? x - w\n : x - w / 2;\n const tickY = position === 'top'\n ? yRange[1] - height - HOVERED_TICK_MARGIN_Y + HOVERED_TICK_PADDING_Y\n : yRange[0] + HOVERED_TICK_MARGIN_Y - HOVERED_TICK_PADDING_Y;\n\n return sstyled(styles)(\n <SHoveredTickWrapper\n x={tickX}\n y={tickY}\n width={w}\n height={height}\n data-is-first={isFirstTick}\n data-is-last={isLastTick}\n position={position}\n aria-hidden={interactive ? undefined : true}\n >\n <SHoveredTickContent ref={contentRef}>\n <SHoveredTick>{formattedValue}</SHoveredTick>\n </SHoveredTickContent>\n </SHoveredTickWrapper>,\n );\n}\n\nfunction HoverLineTooltip(props) {\n const SHoverLineTooltip = Root;\n return sstyled(props.styles)(<SHoverLineTooltip render={Tooltip} tag={HoverLine} excludeAnchorProps />);\n}\nfunction HoverRectTooltip(props) {\n const SHoverRectTooltip = Root;\n return sstyled(props.styles)(<SHoverRectTooltip render={Tooltip} tag={HoverRect} excludeAnchorProps />);\n}\n\nconst HoverLine = createElement(HoverLineRoot, {\n Tooltip: [HoverLineTooltip, Tooltip._______childrenComponents],\n});\nconst HoverRect = createElement(HoverRectRoot, {\n Tooltip: [HoverRectTooltip, Tooltip._______childrenComponents],\n});\n\nexport { HoverLine, HoverRect };\n"],"mappings":";;;;AAAA,SAASA,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACxD,OAAOC,SAAS,MAAM,mCAAmC;AACzD,SAASC,cAAc,QAAQ,mDAAmD;AAClF,SAASC,SAAS,QAAQ,mCAAmC;AAC7D,OAAOC,OAAO,MAAM,oCAAoC;AACxD,OAAOC,iBAAiB,MAAM,+CAA+C;AAC7E,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,aAAa,MAAM,iBAAiB;AAAC;AAAA,MAAAC,KAAA,8BAAAC,QAAA,CAAAC,MAAA;AAAA;AAAA;EAAA;EAAA;EAAA;EAAA;EAAA;EAAA;AAAA;AAE5C,OAAOC,OAAO,MAAM,WAAW;AAC/B,SAASC,gBAAgB,EAAEC,gBAAgB,EAAEC,YAAY,EAAEC,MAAM,EAAEC,WAAW,QAAQ,SAAS;AAE/F,MAAMC,YAAY,GAAG,CAAC;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BC,SAAS;MAAA;IAAA,GAAAL,IAAA;EAAA,EAAsB,CAAC;AACxG;AACA,SAASM,gBAAgBA,CAAC5B,KAAK,EAAE;EAAA,IAAA6B,KAAA,GAAAN,YAAA;IAAAO,KAAA;EAC/B,MAAMC,iBAAiB,GACiC5I,OAAO;EAA/D,OAAA2I,KAAA,GAAOvJ,OAAO,CAACyH,KAAK,CAAC/B,MAAM,CAAC,eAACnF,KAAA,CAAAC,aAAA,CAACgJ,iBAAiB,EAAAD,KAAA,CAAApD,EAAA;IAAA,GAAAsD,aAAA;MAAA,OAAuBC,SAAS;MAAA;IAAA,GAAAJ,KAAA;EAAA,EAAsB,CAAC;AACxG;AAEA,MAAMF,SAAS,GAAG5I,aAAa,CAAC0E,aAAa,EAAE;EAC7CtE,OAAO,EAAE,CAACkI,gBAAgB,EAAElI,OAAO,CAAC+I,yBAAyB;AAC/D,CAAC,CAAC;AACF,MAAMD,SAAS,GAAGlJ,aAAa,CAACmG,aAAa,EAAE;EAC7C/F,OAAO,EAAE,CAACyI,gBAAgB,EAAEzI,OAAO,CAAC+I,yBAAyB;AAC/D,CAAC,CAAC;AAEF,SAASP,SAAS,EAAEM,SAAS","ignoreList":[]}
1
+ {"version":3,"file":"Hover.js","names":["Component","sstyled","Root","canUseDOM","hasParent","trottle","React","createElement","style","_sstyled","insert","Tooltip","scaleOfBandwidth","getIndexFromData","eventToPoint","invert","scaleToBand","STROKE_WIDTH","NOTCH_WIDTH","NOTCH_DELTA","formatValue","locale","value","Date","Intl","DateTimeFormat","day","month","format","Hover","constructor","args","_defineProperty","xIndex","yIndex","document","e","currentTarget","isTickUnder","eventEmitter","data","scale","x","y","rootRef","patterns","plotId","asProps","clientX","clientY","xScale","yScale","pX","pY","current","vX","vY","undefined","state","xRect","yRect","height","getBoundingClientRect","yOriginal","heightOriginal","isRootTooltip","target","setState","diff","dimension","heightValue","emit","componentDidMount","unsubscribeMouseMoveRoot","subscribe","_","persist","handlerMouseMoveRoot","unsubscribeMouseLeaveRoot","handlerMouseLeaveRoot","componentWillUnmount","HoverLineRoot","render","_ref3","hideHoverLine","meta","isHide","SHoverLine","Element","styles","dataHints","hideTickHover","xRange","range","yRange","x1","y1","Fragment","cn","HoveredTick","getTicksSize","getTicksPosition","titles","getHorizontalAxesTitle","bind","length","HoverRectRoot","_ref4","SHoverRect","xBand","yBand","xStep","step","xPaddingInner","paddingInner","yStep","yPaddingInner","HOVERED_TICK_MARGIN_Y","HOVERED_TICK_PADDING_Y","HOVERED_TICK_PADDING_X","props","_ref5","tickFormatter","isFirstTick","isLastTick","size","position","contentRef","useRef","formattedValue","width","SHoveredTickWrapper","SHoveredTickContent","SHoveredTick","w","tickX","tickY","HoverLineTooltip","_ref","arguments[0]","_ref6","SHoverLineTooltip","_assignProps","HoverLine","HoverRectTooltip","_ref2","_ref7","SHoverRectTooltip","_assignProps2","HoverRect","_______childrenComponents"],"sources":["../../src/Hover.jsx"],"sourcesContent":["import { Component, sstyled, Root } from '@semcore/core';\nimport canUseDOM from '@semcore/core/lib/utils/canUseDOM';\nimport { hasParent } from '@semcore/core/lib/utils/hasParent';\nimport trottle from '@semcore/core/lib/utils/rafTrottle';\nimport React from 'react';\n\nimport createElement from './createElement';\nimport style from './style/hover.shadow.css';\nimport Tooltip from './Tooltip';\nimport { scaleOfBandwidth, getIndexFromData, eventToPoint, invert, scaleToBand } from './utils';\n\nconst STROKE_WIDTH = 1;\nconst NOTCH_WIDTH = 9;\nconst NOTCH_DELTA = NOTCH_WIDTH / 2 - STROKE_WIDTH / 4;\n\nfunction formatValue(locale, value) {\n if (value instanceof Date) {\n return new Intl.DateTimeFormat(locale ?? 'en', {\n day: 'numeric',\n month: 'short',\n }).format(value);\n }\n return value;\n}\nclass Hover extends Component {\n static style = style;\n\n state = {\n xIndex: null,\n yIndex: null,\n };\n\n virtualElement = canUseDOM() ? document.createElement('div') : {};\n\n handlerMouseMoveRoot = trottle((e, currentTarget, isTickUnder) => {\n const { eventEmitter, data, scale, x, y, rootRef, patterns, plotId } = this.asProps;\n const { clientX, clientY } = e;\n const [xScale, yScale] = scale;\n const [pX, pY] = eventToPoint(e, rootRef.current);\n const vX = invert(xScale, pX);\n const vY = invert(yScale, pY);\n const xIndex = x === undefined || vX === undefined ? null : getIndexFromData(data, xScale, x, vX);\n const yIndex = y === undefined || vY === undefined ? null : getIndexFromData(data, yScale, y, vY);\n const state = { xIndex, yIndex, patterns };\n\n const { x: xRect, y: yRect, height } = rootRef.current.getBoundingClientRect();\n const { y: yOriginal, height: heightOriginal } = currentTarget.getBoundingClientRect();\n const isRootTooltip = hasParent(e.target, rootRef.current);\n\n this.setState(state, () => {\n let x, y;\n\n if (isRootTooltip) {\n x = clientX;\n // preserve static vertical position if it's a move on a tick.\n y = isTickUnder ? yRect + height / 2 : clientY;\n } else {\n const diff = clientY - yOriginal;\n const dimension = (diff / heightOriginal) * 100;\n const heightValue = (height / 100) * dimension;\n\n x = pX + xRect;\n // preserve static vertical position if it's a move on tick.\n y = isTickUnder ? yRect + height / 2 : yRect + heightValue;\n }\n\n eventEmitter.emit(`setTooltipPosition_${plotId}`, x, y);\n eventEmitter.emit(`setTooltipRenderingProps_${plotId}`, {}, state);\n eventEmitter.emit(`setTooltipVisible_${plotId}`, xIndex !== null || yIndex !== null);\n });\n });\n\n handlerMouseLeaveRoot = trottle(() => {\n const state = {\n xIndex: null,\n yIndex: null,\n patterns: this.asProps.patterns,\n };\n this.setState(state, () => {\n this.asProps.eventEmitter.emit(`setTooltipVisible_${this.asProps.plotId}`, false);\n });\n });\n\n componentDidMount() {\n const { eventEmitter } = this.asProps;\n this.unsubscribeMouseMoveRoot = eventEmitter.subscribe('onMouseMoveChart', (e, _, isTickUnder) => {\n e.persist();\n this.handlerMouseMoveRoot(e, e.currentTarget, isTickUnder);\n });\n this.unsubscribeMouseLeaveRoot = eventEmitter.subscribe('onMouseLeaveChart', this.handlerMouseLeaveRoot);\n }\n\n componentWillUnmount() {\n if (this.unsubscribeMouseMoveRoot) {\n this.unsubscribeMouseMoveRoot();\n }\n if (this.unsubscribeMouseLeaveRoot) {\n this.unsubscribeMouseLeaveRoot();\n }\n }\n}\n\nclass HoverLineRoot extends Hover {\n static displayName = 'HoverLine';\n\n render() {\n const { hideHoverLine, meta, locale } = this.asProps;\n const { xIndex, yIndex } = this.state;\n\n const isHide = typeof hideHoverLine === 'function' ? hideHoverLine(xIndex, yIndex) : hideHoverLine;\n\n if (isHide) {\n return null;\n }\n\n const SHoverLine = this.Element;\n const { styles, x, y, data, scale, dataHints, hideTickHover } = this.asProps;\n const [xScale, yScale] = scale;\n\n const xRange = xScale.range();\n const yRange = yScale.range();\n const x1 = xIndex !== null ? scaleOfBandwidth(xScale, data[xIndex][x]) : undefined;\n const y1 = yIndex !== null ? scaleOfBandwidth(yScale, data[yIndex][y]) : undefined;\n\n return sstyled(styles)(\n <>\n {xIndex !== null\n ? (\n <>\n <SHoverLine render='g' index={xIndex} stroke-width={STROKE_WIDTH} aria-hidden>\n <line x1={x1 - NOTCH_DELTA} x2={x1 + NOTCH_DELTA} y1={yRange[0]} y2={yRange[0]} />\n <line x1={x1} y1={yRange[0]} x2={x1} y2={yRange[1]} />\n <line x1={x1 - NOTCH_DELTA} x2={x1 + NOTCH_DELTA} y1={yRange[1]} y2={yRange[1]} />\n </SHoverLine>\n {!hideTickHover && (\n <HoveredTick\n size={meta.getTicksSize('horizontal')}\n position={meta.getTicksPosition('horizontal')}\n tickFormatter={dataHints.titles.getHorizontalAxesTitle ?? formatValue.bind(null, locale)}\n value={data[xIndex]?.[x]}\n isFirstTick={xIndex === 0}\n isLastTick={xIndex === data.length - 1}\n styles={styles}\n x={x1}\n yRange={yRange}\n />\n )}\n </>\n )\n : null}\n {yIndex !== null\n ? (\n <SHoverLine render='g' index={yIndex} stroke-width={STROKE_WIDTH} aria-hidden>\n <line x1={xRange[0]} y1={y1 - NOTCH_DELTA} x2={xRange[0]} y2={y1 + NOTCH_DELTA} />\n <line x1={xRange[0]} y1={y1} x2={xRange[1]} y2={y1} />\n <line x1={xRange[1]} y1={y1 - NOTCH_DELTA} x2={xRange[1]} y2={y1 + NOTCH_DELTA} />\n </SHoverLine>\n )\n : null}\n </>,\n );\n }\n}\n\nclass HoverRectRoot extends Hover {\n static displayName = 'HoverRect';\n\n render() {\n const { hideHoverLine, meta } = this.asProps;\n\n if (hideHoverLine) {\n return null;\n }\n\n const SHoverRect = this.Element;\n const { styles, x, y, data, scale, dataHints, hideTickHover, locale } = this.asProps;\n const { xIndex, yIndex } = this.state;\n const [xScale, yScale] = scale;\n\n const xRange = xScale.range();\n const yRange = yScale.range();\n const xBand = scaleToBand(xScale);\n const yBand = scaleToBand(yScale);\n\n const xStep = xBand.step();\n const xPaddingInner = xBand.paddingInner();\n const yStep = yBand.step();\n const yPaddingInner = yBand.paddingInner();\n\n return sstyled(styles)(\n <>\n {xIndex !== null && (\n <>\n <SHoverRect\n aria-hidden\n render='rect'\n index={xIndex}\n width={xStep - xPaddingInner / 2}\n height={yRange[0] - yRange[1]}\n x={xScale(data[xIndex][x]) - (xStep * xPaddingInner) / 2}\n y={yRange[1]}\n />\n {!hideTickHover && (\n <HoveredTick\n size={meta.getTicksSize('horizontal')}\n position={meta.getTicksPosition('horizontal')}\n tickFormatter={dataHints.titles.getHorizontalAxesTitle ?? formatValue.bind(null, locale)}\n value={data[xIndex]?.[x]}\n styles={styles}\n x={xScale(data[xIndex][x]) + (xStep * (1 - xPaddingInner)) / 2}\n yRange={yRange}\n />\n )}\n </>\n )}\n {yIndex !== null && (\n <SHoverRect\n aria-hidden\n render='rect'\n index={yIndex}\n width={xRange[1] - xRange[0]}\n height={yStep - yPaddingInner / 2}\n x={xRange[0]}\n y={yScale(data[yIndex][y]) - (yStep * yPaddingInner) / 2}\n />\n )}\n </>,\n );\n }\n}\n\nconst HOVERED_TICK_MARGIN_Y = 8;\nconst HOVERED_TICK_PADDING_Y = 3;\nconst HOVERED_TICK_PADDING_X = 12;\n\nfunction HoveredTick(props) {\n const { tickFormatter, value, isFirstTick = false, isLastTick = false, styles, x, yRange, size, position } = props;\n\n const contentRef = React.useRef(null);\n\n const formattedValue = tickFormatter(value);\n\n if (size?.width === undefined || size?.height === undefined || position === null) return null;\n\n const { width, height } = size;\n\n const SHoveredTickWrapper = 'foreignObject';\n const SHoveredTickContent = 'div';\n const SHoveredTick = 'span';\n\n const w = width + HOVERED_TICK_PADDING_X * 2;\n const tickX = isFirstTick\n ? x\n : isLastTick\n ? x - w\n : x - w / 2;\n const tickY = position === 'top'\n ? yRange[1] - height - HOVERED_TICK_MARGIN_Y + HOVERED_TICK_PADDING_Y\n : yRange[0] + HOVERED_TICK_MARGIN_Y - HOVERED_TICK_PADDING_Y;\n\n return sstyled(styles)(\n <SHoveredTickWrapper\n x={tickX}\n y={tickY}\n width={w}\n height={height}\n data-is-first={isFirstTick}\n data-is-last={isLastTick}\n position={position}\n >\n <SHoveredTickContent inert='' ref={contentRef}>\n <SHoveredTick>{formattedValue}</SHoveredTick>\n </SHoveredTickContent>\n </SHoveredTickWrapper>,\n );\n}\n\nfunction HoverLineTooltip(props) {\n const SHoverLineTooltip = Root;\n return sstyled(props.styles)(<SHoverLineTooltip render={Tooltip} tag={HoverLine} excludeAnchorProps />);\n}\nfunction HoverRectTooltip(props) {\n const SHoverRectTooltip = Root;\n return sstyled(props.styles)(<SHoverRectTooltip render={Tooltip} tag={HoverRect} excludeAnchorProps />);\n}\n\nconst HoverLine = createElement(HoverLineRoot, {\n Tooltip: [HoverLineTooltip, Tooltip._______childrenComponents],\n});\nconst HoverRect = createElement(HoverRectRoot, {\n Tooltip: [HoverRectTooltip, Tooltip._______childrenComponents],\n});\n\nexport { HoverLine, HoverRect };\n"],"mappings":";;;;AAAA,SAASA,SAAS,EAAEC,OAAO,EAAEC,IAAI,QAAQ,eAAe;AACxD,OAAOC,SAAS,MAAM,mCAAmC;AACzD,SAASC,SAAS,QAAQ,mCAAmC;AAC7D,OAAOC,OAAO,MAAM,oCAAoC;AACxD,OAAOC,KAAK,MAAM,OAAO;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MAAMC,iBAAiB,GACiCxI,OAAO;EAA/D,OAAAuI,KAAA,GAAOjJ,OAAO,CAACuH,KAAK,CAAC/B,MAAM,CAAC,eAACnF,KAAA,CAAAC,aAAA,CAAC4I,iBAAiB,EAAAD,KAAA,CAAAhD,EAAA;IAAA,GAAAkD,aAAA;MAAA,OAAuBC,SAAS;MAAA;IAAA,GAAAJ,KAAA;EAAA,EAAsB,CAAC;AACxG;AAEA,MAAMF,SAAS,GAAGxI,aAAa,CAAC0E,aAAa,EAAE;EAC7CtE,OAAO,EAAE,CAAC8H,gBAAgB,EAAE9H,OAAO,CAAC2I,yBAAyB;AAC/D,CAAC,CAAC;AACF,MAAMD,SAAS,GAAG9I,aAAa,CAACmG,aAAa,EAAE;EAC7C/F,OAAO,EAAE,CAACqI,gBAAgB,EAAErI,OAAO,CAAC2I,yBAAyB;AAC/D,CAAC,CAAC;AAEF,SAASP,SAAS,EAAEM,SAAS","ignoreList":[]}
package/lib/es6/Line.js CHANGED
@@ -12,17 +12,17 @@ import createElement from './createElement';
12
12
  import Dots from './Dots';
13
13
  import { ForecastGradient, PotentialGradient, resolvePatternDasharray, StrokeMask } from './Pattern';
14
14
  /*!__reshadow-styles__:"./style/line.shadow.css"*/
15
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SLine_1g38p_gg_{fill:#0000;stroke-width:2;stroke:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245));transition-property:d;transition-duration:var(--duration_1g38p);transition-timing-function:ease-in-out}.___SLine_1g38p_gg_.__color_1g38p_gg_{stroke:var(--color_1g38p)}.___SLine_1g38p_gg_.__hide_1g38p_gg_{display:none}.___SLine_1g38p_gg_.__transparent_1g38p_gg_{opacity:.3}.___SNull_1g38p_gg_{fill:#0000;stroke:var(--intergalactic-chart-palette-order-null,oklch(.9 .009 234));stroke-dasharray:4}.___SNull_1g38p_gg_.__hide_1g38p_gg_{display:none}.___SLineArea_1g38p_gg_{transition-property:d;transition-duration:var(--duration_1g38p);transition-timing-function:ease-in-out;opacity:.3;fill:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245))}.___SLineArea_1g38p_gg_.__color_1g38p_gg_{fill:var(--color_1g38p)}", /*__inner_css_end__*/"1g38p_gg_"),
15
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SLine_foqqi_gg_{fill:#0000;stroke-width:2;stroke:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245));transition-property:d;transition-duration:var(--duration_foqqi);transition-timing-function:ease-in-out}.___SLine_foqqi_gg_.__color_foqqi_gg_{stroke:var(--color_foqqi)}.___SLine_foqqi_gg_.__hide_foqqi_gg_{display:none}.___SLine_foqqi_gg_.__transparent_foqqi_gg_{opacity:.3}.___SNull_foqqi_gg_{fill:#0000;stroke:var(--intergalactic-chart-palette-order-null,oklch(.9 .009 234));stroke-dasharray:4}.___SNull_foqqi_gg_.__hide_foqqi_gg_{display:none}.___SLineArea_foqqi_gg_{transition-property:d;transition-duration:var(--duration_foqqi);transition-timing-function:ease-in-out;opacity:.3;fill:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245))}.___SLineArea_foqqi_gg_.__color_foqqi_gg_{fill:var(--color_foqqi)}", /*__inner_css_end__*/"foqqi_gg_"),
16
16
  /*__reshadow_css_end__*/
17
17
  {
18
- "__SLine": "___SLine_1g38p_gg_",
19
- "--duration": "--duration_1g38p",
20
- "_color": "__color_1g38p_gg_",
21
- "--color": "--color_1g38p",
22
- "_hide": "__hide_1g38p_gg_",
23
- "_transparent": "__transparent_1g38p_gg_",
24
- "__SNull": "___SNull_1g38p_gg_",
25
- "__SLineArea": "___SLineArea_1g38p_gg_"
18
+ "__SLine": "___SLine_foqqi_gg_",
19
+ "--duration": "--duration_foqqi",
20
+ "_color": "__color_foqqi_gg_",
21
+ "--color": "--color_foqqi",
22
+ "_hide": "__hide_foqqi_gg_",
23
+ "_transparent": "__transparent_foqqi_gg_",
24
+ "__SNull": "___SNull_foqqi_gg_",
25
+ "__SLineArea": "___SLineArea_foqqi_gg_"
26
26
  });
27
27
  import { definedData, definedNullData, scaleOfBandwidth, getNullData, interpolateValue, getChartDefaultColorName, eventToPoint, invert, getDataOfType } from './utils';
28
28
  class LineRoot extends Component {
@@ -10,20 +10,20 @@ import React from 'react';
10
10
  import createElement from './createElement';
11
11
  import { PatternSymbol, getPatternSymbolSize } from './Pattern';
12
12
  /*!__reshadow-styles__:"./style/radial-tree.shadow.css"*/
13
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SRadian_tu12w_gg_{cursor:pointer;fill:var(--intergalactic-text-large-info,oklch(.23 .009 245))}.___SLine_tu12w_gg_{stroke:var(--intergalactic-text-large-info,oklch(.23 .009 245))}.___SLine_tu12w_gg_.__stroke_tu12w_gg_{stroke:var(--stroke_tu12w)}.___SLine_tu12w_gg_.__transparent_tu12w_gg_{opacity:.3}.___SCap_tu12w_gg_{transition:r .1s}.___SCap_tu12w_gg_.__pattern_tu12w_gg_{stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:1px}.___SCap_tu12w_gg_.__transparent_tu12w_gg_,.___SIcon_tu12w_gg_.__transparent_tu12w_gg_{opacity:.3}.___SLabel_tu12w_gg_{fill:var(--color_tu12w)}.___SLabel_tu12w_gg_.__transparent_tu12w_gg_{opacity:.3}@media (hover:hover){.___SRadian_tu12w_gg_:hover .___SLabel_tu12w_gg_{cursor:pointer;filter:brightness(.6)}}@media (prefers-reduced-motion){.___SLineCap_tu12w_gg_{transition:none}}", /*__inner_css_end__*/"tu12w_gg_"),
13
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SRadian_1u9s6_gg_{cursor:pointer;fill:var(--intergalactic-text-large-info,oklch(.23 .009 245))}.___SLine_1u9s6_gg_{stroke:var(--intergalactic-text-large-info,oklch(.23 .009 245))}.___SLine_1u9s6_gg_.__stroke_1u9s6_gg_{stroke:var(--stroke_1u9s6)}.___SLine_1u9s6_gg_.__transparent_1u9s6_gg_{opacity:.3}.___SCap_1u9s6_gg_{transition:r .1s}.___SCap_1u9s6_gg_.__pattern_1u9s6_gg_{stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:1px}.___SCap_1u9s6_gg_.__transparent_1u9s6_gg_,.___SIcon_1u9s6_gg_.__transparent_1u9s6_gg_{opacity:.3}.___SLabel_1u9s6_gg_{fill:var(--color_1u9s6)}.___SLabel_1u9s6_gg_.__transparent_1u9s6_gg_{opacity:.3}@media (hover:hover){.___SRadian_1u9s6_gg_:hover .___SLabel_1u9s6_gg_{cursor:pointer;filter:brightness(.6)}}@media (prefers-reduced-motion){.___SLineCap_1u9s6_gg_{transition:none}}", /*__inner_css_end__*/"1u9s6_gg_"),
14
14
  /*__reshadow_css_end__*/
15
15
  {
16
- "__SRadian": "___SRadian_tu12w_gg_",
17
- "__SLine": "___SLine_tu12w_gg_",
18
- "_stroke": "__stroke_tu12w_gg_",
19
- "--stroke": "--stroke_tu12w",
20
- "_transparent": "__transparent_tu12w_gg_",
21
- "__SCap": "___SCap_tu12w_gg_",
22
- "_pattern": "__pattern_tu12w_gg_",
23
- "__SIcon": "___SIcon_tu12w_gg_",
24
- "__SLabel": "___SLabel_tu12w_gg_",
25
- "--color": "--color_tu12w",
26
- "__SLineCap": "___SLineCap_tu12w_gg_"
16
+ "__SRadian": "___SRadian_1u9s6_gg_",
17
+ "__SLine": "___SLine_1u9s6_gg_",
18
+ "_stroke": "__stroke_1u9s6_gg_",
19
+ "--stroke": "--stroke_1u9s6",
20
+ "_transparent": "__transparent_1u9s6_gg_",
21
+ "__SCap": "___SCap_1u9s6_gg_",
22
+ "_pattern": "__pattern_1u9s6_gg_",
23
+ "__SIcon": "___SIcon_1u9s6_gg_",
24
+ "__SLabel": "___SLabel_1u9s6_gg_",
25
+ "--color": "--color_1u9s6",
26
+ "__SLineCap": "___SLineCap_1u9s6_gg_"
27
27
  });
28
28
  import { getChartDefaultColorName, measureText } from './utils';
29
29
  const baseAngle = -Math.PI / 2; // The top vertical line
@@ -5,20 +5,20 @@ import uniqueIDEnhancement from '@semcore/core/lib/utils/uniqueID';
5
5
  import React from 'react';
6
6
  import createElement from './createElement';
7
7
  /*!__reshadow-styles__:"./style/reference.shadow.css"*/
8
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SReferenceLine_w3kqr_gg_{fill:none;stroke:var(--intergalactic-chart-grid-y-accent-hover-line,oklch(.88 .011 234.9))}.___STitle_w3kqr_gg_{font-size:var(--intergalactic-fs-100,12px);fill:var(--intergalactic-chart-grid-text-label,#00132466);transform-origin:var(--transform-origin_w3kqr)}.___STitle_w3kqr_gg_._position_top_w3kqr_gg_{text-anchor:middle}.___STitle_w3kqr_gg_._position_bottom_w3kqr_gg_{text-anchor:middle;dominant-baseline:hanging}.___STitle_w3kqr_gg_._position_left_w3kqr_gg_,.___STitle_w3kqr_gg_._position_right_w3kqr_gg_{transform:rotate(-90deg);dominant-baseline:middle;text-anchor:middle}.___SBackground_w3kqr_gg_{fill:var(--intergalactic-chart-grid-period-bg,oklch(.96 .005 232.5))}.___SStripes_w3kqr_gg_{fill:var(--fill_w3kqr)}.___SStripesPatternPath_w3kqr_gg_{stroke:var(--intergalactic-chart-grid-period-pattern,oklch(.95 .006 232.7));stroke-width:1px}", /*__inner_css_end__*/"w3kqr_gg_"),
8
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SReferenceLine_103dp_gg_{fill:none;stroke:var(--intergalactic-chart-grid-y-accent-hover-line,oklch(.88 .011 234.9))}.___STitle_103dp_gg_{font-size:var(--intergalactic-fs-100,12px);fill:var(--intergalactic-chart-grid-text-label,#00132466);transform-origin:var(--transform-origin_103dp)}.___STitle_103dp_gg_._position_top_103dp_gg_{text-anchor:middle}.___STitle_103dp_gg_._position_bottom_103dp_gg_{text-anchor:middle;dominant-baseline:hanging}.___STitle_103dp_gg_._position_left_103dp_gg_,.___STitle_103dp_gg_._position_right_103dp_gg_{transform:rotate(-90deg);dominant-baseline:middle;text-anchor:middle}.___SBackground_103dp_gg_{fill:var(--intergalactic-chart-grid-period-bg,oklch(.96 .005 232.5))}.___SStripes_103dp_gg_{fill:var(--fill_103dp)}.___SStripesPatternPath_103dp_gg_{stroke:var(--intergalactic-chart-grid-period-pattern,oklch(.95 .006 232.7));stroke-width:1px}", /*__inner_css_end__*/"103dp_gg_"),
9
9
  /*__reshadow_css_end__*/
10
10
  {
11
- "__SReferenceLine": "___SReferenceLine_w3kqr_gg_",
12
- "__STitle": "___STitle_w3kqr_gg_",
13
- "--transform-origin": "--transform-origin_w3kqr",
14
- "_position_top": "_position_top_w3kqr_gg_",
15
- "_position_bottom": "_position_bottom_w3kqr_gg_",
16
- "_position_right": "_position_right_w3kqr_gg_",
17
- "_position_left": "_position_left_w3kqr_gg_",
18
- "__SBackground": "___SBackground_w3kqr_gg_",
19
- "__SStripes": "___SStripes_w3kqr_gg_",
20
- "--fill": "--fill_w3kqr",
21
- "__SStripesPatternPath": "___SStripesPatternPath_w3kqr_gg_"
11
+ "__SReferenceLine": "___SReferenceLine_103dp_gg_",
12
+ "__STitle": "___STitle_103dp_gg_",
13
+ "--transform-origin": "--transform-origin_103dp",
14
+ "_position_top": "_position_top_103dp_gg_",
15
+ "_position_bottom": "_position_bottom_103dp_gg_",
16
+ "_position_right": "_position_right_103dp_gg_",
17
+ "_position_left": "_position_left_103dp_gg_",
18
+ "__SBackground": "___SBackground_103dp_gg_",
19
+ "__SStripes": "___SStripes_103dp_gg_",
20
+ "--fill": "--fill_103dp",
21
+ "__SStripesPatternPath": "___SStripesPatternPath_103dp_gg_"
22
22
  });
23
23
  import { scaleOfBandwidth } from './utils';
24
24
  const STROKE_WIDTH = 1;
@@ -9,17 +9,17 @@ import React from 'react';
9
9
  import createElement from './createElement';
10
10
  import { PatternFill } from './Pattern';
11
11
  /*!__reshadow-styles__:"./style/scatterplot.shadow.css"*/
12
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SScatterPlot_srw2j_gg_{fill:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245));transition-property:cx,cy;transition-duration:var(--duration_srw2j);transition-timing-function:ease-in-out;opacity:.5}@media (hover:hover){.___SScatterPlot_srw2j_gg_:hover{opacity:.8}}.___SScatterPlot_srw2j_gg_.__color_srw2j_gg_{fill:var(--color_srw2j)}.___SScatterPlot_srw2j_gg_.__pattern_srw2j_gg_.__color_srw2j_gg_{fill:var(--pattern_srw2j);stroke:var(--color_srw2j);stroke-width:1px}.___SScatterPlot_srw2j_gg_.__transparent_srw2j_gg_{opacity:.3}.___SValue_srw2j_gg_{text-anchor:middle;font-size:var(--intergalactic-fs-50,10px);stroke:var(--intergalactic-chart-palette-order-9,oklch(.53 .157 279.2))}.___SValue_srw2j_gg_.__color_srw2j_gg_{stroke:var(--color_srw2j)}.___SValue_srw2j_gg_.__transparent_srw2j_gg_{opacity:.3}", /*__inner_css_end__*/"srw2j_gg_"),
12
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SScatterPlot_v4rqi_gg_{fill:var(--intergalactic-chart-palette-order-1,oklch(.23 .009 245));transition-property:cx,cy;transition-duration:var(--duration_v4rqi);transition-timing-function:ease-in-out;opacity:.5}@media (hover:hover){.___SScatterPlot_v4rqi_gg_:hover{opacity:.8}}.___SScatterPlot_v4rqi_gg_.__color_v4rqi_gg_{fill:var(--color_v4rqi)}.___SScatterPlot_v4rqi_gg_.__pattern_v4rqi_gg_.__color_v4rqi_gg_{fill:var(--pattern_v4rqi);stroke:var(--color_v4rqi);stroke-width:1px}.___SScatterPlot_v4rqi_gg_.__transparent_v4rqi_gg_{opacity:.3}.___SValue_v4rqi_gg_{text-anchor:middle;font-size:var(--intergalactic-fs-50,10px);stroke:var(--intergalactic-chart-palette-order-9,oklch(.53 .157 279.2))}.___SValue_v4rqi_gg_.__color_v4rqi_gg_{stroke:var(--color_v4rqi)}.___SValue_v4rqi_gg_.__transparent_v4rqi_gg_{opacity:.3}", /*__inner_css_end__*/"v4rqi_gg_"),
13
13
  /*__reshadow_css_end__*/
14
14
  {
15
- "__SScatterPlot": "___SScatterPlot_srw2j_gg_",
16
- "_color": "__color_srw2j_gg_",
17
- "--color": "--color_srw2j",
18
- "_pattern": "__pattern_srw2j_gg_",
19
- "--pattern": "--pattern_srw2j",
20
- "_transparent": "__transparent_srw2j_gg_",
21
- "__SValue": "___SValue_srw2j_gg_",
22
- "--duration": "--duration_srw2j"
15
+ "__SScatterPlot": "___SScatterPlot_v4rqi_gg_",
16
+ "_color": "__color_v4rqi_gg_",
17
+ "--color": "--color_v4rqi",
18
+ "_pattern": "__pattern_v4rqi_gg_",
19
+ "--pattern": "--pattern_v4rqi",
20
+ "_transparent": "__transparent_v4rqi_gg_",
21
+ "__SValue": "___SValue_v4rqi_gg_",
22
+ "--duration": "--duration_v4rqi"
23
23
  });
24
24
  import Tooltip from './Tooltip';
25
25
  import { getScatterPlotRadius } from './utils';
@@ -13,20 +13,20 @@ import React from 'react';
13
13
  import createElement from './createElement';
14
14
  import { PatternSymbol } from './Pattern';
15
15
  /*!__reshadow-styles__:"./style/tooltip.shadow.css"*/
16
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___STooltip_5s0wq_gg_{font-size:var(--intergalactic-fs-100,12px);line-height:var(--intergalactic-lh-100,1.3334);font-feature-settings:\"tnum\";font-variant-numeric:tabular-nums;position:relative;color:var(--intergalactic-text-primary-invert,oklch(.991 .005 232.5/.959));background-color:var(--intergalactic-tooltip-bg-invert,oklch(.23 .009 245));border-radius:var(--intergalactic-popper-rounded,6px);border:1px solid var(--intergalactic-tooltip-border-invert,oklch(.4 .015 245));box-sizing:border-box;box-shadow:var(--intergalactic-box-shadow-popper,1px 1px 10px 0 oklch(.324 .077 242.1/.079));padding:var(--intergalactic-spacing-3x,12px)}.___STitle_5s0wq_gg_{color:var(--intergalactic-text-secondary-invert,#e1f2ffb9);margin-bottom:var(--intergalactic-spacing-2x,8px)}@media (color-gamut:p3){.___STitle_5s0wq_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___SDotGroup_5s0wq_gg_{display:flex;align-items:center}.___SDot_5s0wq_gg_{margin-right:var(--intergalactic-spacing-2x,8px)}.___SDotCircle_5s0wq_gg_.__color_5s0wq_gg_.__lightness_5s0wq_gg_{background-color:var(--color_5s0wq);width:10px;height:10px;border-radius:50%;box-shadow:0 0 0 1px oklch(from var(--color_5s0wq) calc(l + var(--lightness_5s0wq)) c h)}.___SFooter_5s0wq_gg_{background:var(--intergalactic-bg-secondary-invert,oklch(.907 .048 245.2/.129));color:var(--intergalactic-text-secondary-invert,#e1f2ffb9);padding:var(--intergalactic-spacing-1x,4px) var(--intergalactic-spacing-3x,12px);border-radius:0 0 var(--intergalactic-rounded-medium,6px) var(--intergalactic-rounded-medium,6px);margin:var(--intergalactic-spacing-3x,12px) calc(var(--intergalactic-spacing-3x, 12px)*-1) calc(var(--intergalactic-spacing-3x, 12px)*-1)}@media (color-gamut:p3){.___SFooter_5s0wq_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___SDotPattern_5s0wq_gg_{stroke-width:1px;stroke:oklch(from var(--intergalactic-chart-grid-border,#fff) l c h/.5)}", /*__inner_css_end__*/"5s0wq_gg_"),
16
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___STooltip_1bv2y_gg_{font-size:var(--intergalactic-fs-100,12px);line-height:var(--intergalactic-lh-100,1.3334);font-feature-settings:\"tnum\";font-variant-numeric:tabular-nums;position:relative;color:var(--intergalactic-text-primary-invert,oklch(.991 .005 232.5/.959));background-color:var(--intergalactic-tooltip-bg-invert,oklch(.23 .009 245));border-radius:var(--intergalactic-popper-rounded,6px);border:1px solid var(--intergalactic-tooltip-border-invert,oklch(.4 .015 245));box-sizing:border-box;box-shadow:var(--intergalactic-box-shadow-popper,1px 1px 10px 0 oklch(.324 .077 242.1/.079));padding:var(--intergalactic-spacing-3x,12px)}.___STitle_1bv2y_gg_{color:var(--intergalactic-text-secondary-invert,#e1f2ffb9);margin-bottom:var(--intergalactic-spacing-2x,8px)}@media (color-gamut:p3){.___STitle_1bv2y_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___SDotGroup_1bv2y_gg_{display:flex;align-items:center}.___SDot_1bv2y_gg_{margin-right:var(--intergalactic-spacing-2x,8px)}.___SDotCircle_1bv2y_gg_.__color_1bv2y_gg_.__lightness_1bv2y_gg_{background-color:var(--color_1bv2y);width:10px;height:10px;border-radius:50%;box-shadow:0 0 0 1px oklch(from var(--color_1bv2y) calc(l + var(--lightness_1bv2y)) c h)}.___SFooter_1bv2y_gg_{background:var(--intergalactic-bg-secondary-invert,oklch(.907 .048 245.2/.129));color:var(--intergalactic-text-secondary-invert,#e1f2ffb9);padding:var(--intergalactic-spacing-1x,4px) var(--intergalactic-spacing-3x,12px);border-radius:0 0 var(--intergalactic-rounded-medium,6px) var(--intergalactic-rounded-medium,6px);margin:var(--intergalactic-spacing-3x,12px) calc(var(--intergalactic-spacing-3x, 12px)*-1) calc(var(--intergalactic-spacing-3x, 12px)*-1)}@media (color-gamut:p3){.___SFooter_1bv2y_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___SDotPattern_1bv2y_gg_{stroke-width:1px;stroke:oklch(from var(--intergalactic-chart-grid-border,#fff) l c h/.5)}", /*__inner_css_end__*/"1bv2y_gg_"),
17
17
  /*__reshadow_css_end__*/
18
18
  {
19
- "__STooltip": "___STooltip_5s0wq_gg_",
20
- "__STitle": "___STitle_5s0wq_gg_",
21
- "__SDotGroup": "___SDotGroup_5s0wq_gg_",
22
- "__SDot": "___SDot_5s0wq_gg_",
23
- "__SDotCircle": "___SDotCircle_5s0wq_gg_",
24
- "_color": "__color_5s0wq_gg_",
25
- "_lightness": "__lightness_5s0wq_gg_",
26
- "--color": "--color_5s0wq",
27
- "--lightness": "--lightness_5s0wq",
28
- "__SFooter": "___SFooter_5s0wq_gg_",
29
- "__SDotPattern": "___SDotPattern_5s0wq_gg_"
19
+ "__STooltip": "___STooltip_1bv2y_gg_",
20
+ "__STitle": "___STitle_1bv2y_gg_",
21
+ "__SDotGroup": "___SDotGroup_1bv2y_gg_",
22
+ "__SDot": "___SDot_1bv2y_gg_",
23
+ "__SDotCircle": "___SDotCircle_1bv2y_gg_",
24
+ "_color": "__color_1bv2y_gg_",
25
+ "_lightness": "__lightness_1bv2y_gg_",
26
+ "--color": "--color_1bv2y",
27
+ "--lightness": "--lightness_1bv2y",
28
+ "__SFooter": "___SFooter_1bv2y_gg_",
29
+ "__SDotPattern": "___SDotPattern_1bv2y_gg_"
30
30
  });
31
31
  import { getChartDefaultColorName } from './utils';
32
32
 
package/lib/es6/Venn.js CHANGED
@@ -12,17 +12,17 @@ import React from 'react';
12
12
  import createElement from './createElement';
13
13
  import { PatternFill } from './Pattern';
14
14
  /*!__reshadow-styles__:"./style/venn.shadow.css"*/
15
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SCircle_1gi52_gg_{fill:var(--intergalactic-chart-palette-order-2,oklch(.58 .168 278.2));stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:2px;fill-opacity:.5;transition-property:cx,cy;transition-duration:var(--duration_1gi52);transition-timing-function:ease-in-out}@media (hover:hover){.___SCircle_1gi52_gg_:hover{fill-opacity:.7}}.___SCircle_1gi52_gg_.__color_1gi52_gg_{fill:var(--color_1gi52)}.___SCircle_1gi52_gg_.__pattern_1gi52_gg_.__color_1gi52_gg_{fill:var(--pattern_1gi52);fill-opacity:.7;stroke:var(--color_1gi52);stroke-width:1px}@media (hover:hover){.___SCircle_1gi52_gg_.__pattern_1gi52_gg_.__color_1gi52_gg_:hover{fill-opacity:.85}}.___SCircle_1gi52_gg_.__transparent_1gi52_gg_{opacity:.3}.___SIntersection_1gi52_gg_{stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:2px;fill-opacity:0}@media (hover:hover){.___SIntersection_1gi52_gg_:hover{fill-opacity:.1}}.___SIntersection_1gi52_gg_.__transparent_1gi52_gg_{opacity:.3}", /*__inner_css_end__*/"1gi52_gg_"),
15
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SCircle_gifii_gg_{fill:var(--intergalactic-chart-palette-order-2,oklch(.58 .168 278.2));stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:2px;fill-opacity:.5;transition-property:cx,cy;transition-duration:var(--duration_gifii);transition-timing-function:ease-in-out}@media (hover:hover){.___SCircle_gifii_gg_:hover{fill-opacity:.7}}.___SCircle_gifii_gg_.__color_gifii_gg_{fill:var(--color_gifii)}.___SCircle_gifii_gg_.__pattern_gifii_gg_.__color_gifii_gg_{fill:var(--pattern_gifii);fill-opacity:.7;stroke:var(--color_gifii);stroke-width:1px}@media (hover:hover){.___SCircle_gifii_gg_.__pattern_gifii_gg_.__color_gifii_gg_:hover{fill-opacity:.85}}.___SCircle_gifii_gg_.__transparent_gifii_gg_{opacity:.3}.___SIntersection_gifii_gg_{stroke:var(--intergalactic-chart-grid-border,#fff);stroke-width:2px;fill-opacity:0}@media (hover:hover){.___SIntersection_gifii_gg_:hover{fill-opacity:.1}}.___SIntersection_gifii_gg_.__transparent_gifii_gg_{opacity:.3}", /*__inner_css_end__*/"gifii_gg_"),
16
16
  /*__reshadow_css_end__*/
17
17
  {
18
- "__SCircle": "___SCircle_1gi52_gg_",
19
- "_color": "__color_1gi52_gg_",
20
- "--color": "--color_1gi52",
21
- "_transparent": "__transparent_1gi52_gg_",
22
- "__SIntersection": "___SIntersection_1gi52_gg_",
23
- "--duration": "--duration_1gi52",
24
- "_pattern": "__pattern_1gi52_gg_",
25
- "--pattern": "--pattern_1gi52"
18
+ "__SCircle": "___SCircle_gifii_gg_",
19
+ "_color": "__color_gifii_gg_",
20
+ "--color": "--color_gifii",
21
+ "_transparent": "__transparent_gifii_gg_",
22
+ "__SIntersection": "___SIntersection_gifii_gg_",
23
+ "--duration": "--duration_gifii",
24
+ "_pattern": "__pattern_gifii_gg_",
25
+ "--pattern": "--pattern_gifii"
26
26
  });
27
27
  import Tooltip from './Tooltip';
28
28
  import { getChartDefaultColorName } from './utils';
@@ -21,20 +21,20 @@ import React, { Fragment } from 'react';
21
21
  import { Plot, XAxis, YAxis } from '../..';
22
22
  import { makeDataHintsContainer } from '../../a11y/hints';
23
23
  /*!__reshadow-styles__:"../../style/abstract-chart.shadow.css"*/
24
- const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SChart_1e5sk_gg_{width:100%;height:100%;min-width:0;min-height:0}.___STooltipChildrenWrapper_1e5sk_gg_{display:grid;grid-gap:var(--intergalactic-spacing-2x,8px);gap:var(--intergalactic-spacing-2x,8px);align-items:center}.___STooltipChildrenWrapper_1e5sk_gg_._columnsCount_2_1e5sk_gg_{grid-template-columns:auto minmax(28px,max-content)}.___STooltipChildrenWrapper_1e5sk_gg_._columnsCount_2_1e5sk_gg_ .___STooltipDivider_1e5sk_gg_{grid-column:span 2}.___STooltipChildrenWrapper_1e5sk_gg_._columnsCount_3_1e5sk_gg_{grid-template-columns:auto minmax(28px,max-content) minmax(28px,max-content)}.___STooltipChildrenWrapper_1e5sk_gg_._columnsCount_3_1e5sk_gg_ .___STooltipDivider_1e5sk_gg_{grid-column:span 3}.___STooltipDeltaWrapper_1e5sk_gg_{gap:var(--intergalactic-spacing-05x,2px);justify-content:flex-end}.___STooltipDeltaWrapper_1e5sk_gg_._trend_upward_1e5sk_gg_{color:var(--intergalactic-chart-data-success,oklch(.82 .19 143))}.___STooltipDeltaWrapper_1e5sk_gg_._trend_downward_1e5sk_gg_{color:var(--intergalactic-chart-data-critical,#ff7d7d)}@media (color-gamut:p3){.___STooltipDeltaWrapper_1e5sk_gg_._trend_downward_1e5sk_gg_{color:var(--intergalactic-chart-data-critical,oklch(.74 .19 22))}}.___STooltipDeltaWrapper_1e5sk_gg_._trend_stable_1e5sk_gg_{color:var(--intergalactic-text-secondary-invert,#e1f2ffb9)}@media (color-gamut:p3){.___STooltipDeltaWrapper_1e5sk_gg_._trend_stable_1e5sk_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___STooltipDeltaWrapper_1e5sk_gg_._deltaPercentGrowthColor_critical_1e5sk_gg_._trend_upward_1e5sk_gg_{color:var(--intergalactic-chart-data-critical,#ff7d7d)}@media (color-gamut:p3){.___STooltipDeltaWrapper_1e5sk_gg_._deltaPercentGrowthColor_critical_1e5sk_gg_._trend_upward_1e5sk_gg_{color:var(--intergalactic-chart-data-critical,oklch(.74 .19 22))}}.___STooltipDeltaWrapper_1e5sk_gg_._deltaPercentGrowthColor_critical_1e5sk_gg_._trend_downward_1e5sk_gg_{color:var(--intergalactic-chart-data-success,oklch(.82 .19 143))}.___STooltipDeltaWrapper_1e5sk_gg_ .___STooltipDeltaIcon_1e5sk_gg_{align-self:center}", /*__inner_css_end__*/"1e5sk_gg_"),
24
+ const style = (/*__reshadow_css_start__*/_sstyled.insert(/*__inner_css_start__*/".___SChart_s53or_gg_{width:100%;height:100%;min-width:0;min-height:0}.___STooltipChildrenWrapper_s53or_gg_{display:grid;grid-gap:var(--intergalactic-spacing-2x,8px);gap:var(--intergalactic-spacing-2x,8px);align-items:center}.___STooltipChildrenWrapper_s53or_gg_._columnsCount_2_s53or_gg_{grid-template-columns:auto minmax(28px,max-content)}.___STooltipChildrenWrapper_s53or_gg_._columnsCount_2_s53or_gg_ .___STooltipDivider_s53or_gg_{grid-column:span 2}.___STooltipChildrenWrapper_s53or_gg_._columnsCount_3_s53or_gg_{grid-template-columns:auto minmax(28px,max-content) minmax(28px,max-content)}.___STooltipChildrenWrapper_s53or_gg_._columnsCount_3_s53or_gg_ .___STooltipDivider_s53or_gg_{grid-column:span 3}.___STooltipDeltaWrapper_s53or_gg_{gap:var(--intergalactic-spacing-05x,2px);justify-content:flex-end}.___STooltipDeltaWrapper_s53or_gg_._trend_upward_s53or_gg_{color:var(--intergalactic-chart-data-success,oklch(.82 .19 143))}.___STooltipDeltaWrapper_s53or_gg_._trend_downward_s53or_gg_{color:var(--intergalactic-chart-data-critical,#ff7d7d)}@media (color-gamut:p3){.___STooltipDeltaWrapper_s53or_gg_._trend_downward_s53or_gg_{color:var(--intergalactic-chart-data-critical,oklch(.74 .19 22))}}.___STooltipDeltaWrapper_s53or_gg_._trend_stable_s53or_gg_{color:var(--intergalactic-text-secondary-invert,#e1f2ffb9)}@media (color-gamut:p3){.___STooltipDeltaWrapper_s53or_gg_._trend_stable_s53or_gg_{color:var(--intergalactic-text-secondary-invert,oklch(.953 .025 240.1/.726))}}.___STooltipDeltaWrapper_s53or_gg_._deltaPercentGrowthColor_bad_s53or_gg_._trend_upward_s53or_gg_{color:var(--intergalactic-chart-data-critical,#ff7d7d)}@media (color-gamut:p3){.___STooltipDeltaWrapper_s53or_gg_._deltaPercentGrowthColor_bad_s53or_gg_._trend_upward_s53or_gg_{color:var(--intergalactic-chart-data-critical,oklch(.74 .19 22))}}.___STooltipDeltaWrapper_s53or_gg_._deltaPercentGrowthColor_bad_s53or_gg_._trend_downward_s53or_gg_{color:var(--intergalactic-chart-data-success,oklch(.82 .19 143))}.___STooltipDeltaWrapper_s53or_gg_ .___STooltipDeltaIcon_s53or_gg_{align-self:center}", /*__inner_css_end__*/"s53or_gg_"),
25
25
  /*__reshadow_css_end__*/
26
26
  {
27
- "__SChart": "___SChart_1e5sk_gg_",
28
- "__STooltipChildrenWrapper": "___STooltipChildrenWrapper_1e5sk_gg_",
29
- "_columnsCount_2": "_columnsCount_2_1e5sk_gg_",
30
- "__STooltipDivider": "___STooltipDivider_1e5sk_gg_",
31
- "_columnsCount_3": "_columnsCount_3_1e5sk_gg_",
32
- "__STooltipDeltaWrapper": "___STooltipDeltaWrapper_1e5sk_gg_",
33
- "_trend_upward": "_trend_upward_1e5sk_gg_",
34
- "_trend_downward": "_trend_downward_1e5sk_gg_",
35
- "_trend_stable": "_trend_stable_1e5sk_gg_",
36
- "_deltaPercentGrowthColor_critical": "_deltaPercentGrowthColor_critical_1e5sk_gg_",
37
- "__STooltipDeltaIcon": "___STooltipDeltaIcon_1e5sk_gg_"
27
+ "__SChart": "___SChart_s53or_gg_",
28
+ "__STooltipChildrenWrapper": "___STooltipChildrenWrapper_s53or_gg_",
29
+ "_columnsCount_2": "_columnsCount_2_s53or_gg_",
30
+ "__STooltipDivider": "___STooltipDivider_s53or_gg_",
31
+ "_columnsCount_3": "_columnsCount_3_s53or_gg_",
32
+ "__STooltipDeltaWrapper": "___STooltipDeltaWrapper_s53or_gg_",
33
+ "_trend_upward": "_trend_upward_s53or_gg_",
34
+ "_trend_downward": "_trend_downward_s53or_gg_",
35
+ "_trend_stable": "_trend_stable_s53or_gg_",
36
+ "_deltaPercentGrowthColor_bad": "_deltaPercentGrowthColor_bad_s53or_gg_",
37
+ "__STooltipDeltaIcon": "___STooltipDeltaIcon_s53or_gg_"
38
38
  });
39
39
  import { interpolateValue } from '../../utils';
40
40
  import ChartLegend, { ChartLegendTable } from '../ChartLegend';
@@ -95,13 +95,14 @@ export class AbstractChart extends Component {
95
95
  } = this.props;
96
96
  return this.dataKeys.map((key, index) => {
97
97
  const legendData = legendProps?.legendMap?.[key];
98
+
99
+ // @ts-expect-error will fill columns or rows later
98
100
  const dataDefinition = {
99
101
  id: key,
100
102
  label: legendData?.label ?? key,
101
103
  icon: legendData?.icon ?? undefined,
102
104
  checked: legendData?.defaultChecked ?? true,
103
- color: this.resolveColor(key, index),
104
- columns: []
105
+ color: this.resolveColor(key, index)
105
106
  };
106
107
  if (legendData?.additionalInfo || legendData?.count) {
107
108
  dataDefinition.additionalInfo = legendData.additionalInfo ? {
@@ -110,9 +111,11 @@ export class AbstractChart extends Component {
110
111
  count: legendData.count
111
112
  } : undefined;
112
113
  }
113
- if (legendData && 'columns' in legendData) {
114
+ if (legendData && 'rows' in legendData && !('columns' in dataDefinition)) {
115
+ dataDefinition.rows = legendData.rows || [];
116
+ } else if (legendData && 'columns' in legendData && !('rows' in dataDefinition)) {
114
117
  dataDefinition.columns = legendData.columns || [];
115
- } else if (!Array.isArray(data)) {
118
+ } else if (!Array.isArray(data) && !('rows' in dataDefinition)) {
116
119
  let value = undefined;
117
120
  let dataValue = data[key];
118
121
  if (data instanceof Map) {
@@ -600,7 +603,7 @@ export class AbstractChart extends Component {
600
603
  "eventEmitter": eventEmitter,
601
604
  "locale": locale,
602
605
  ...extractedAriaProps
603
- }), this.renderAxis(), !showTooltip ? null : this.renderTooltip(), this.renderChart()));
606
+ }), !showTooltip ? null : this.renderTooltip(), this.renderAxis(), this.renderChart()));
604
607
  }
605
608
  handleResize(entities) {
606
609
  const {