@fluentui/react-charting 5.24.5 → 5.24.6

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 (89) hide show
  1. package/CHANGELOG.json +16 -1
  2. package/CHANGELOG.md +11 -2
  3. package/dist/react-charting.js +1 -1
  4. package/dist/react-charting.min.js +1 -1
  5. package/lib/components/AreaChart/AreaChart.styles.js +2 -2
  6. package/lib/components/AreaChart/AreaChart.styles.js.map +1 -1
  7. package/lib/components/CommonComponents/CartesianChart.base.js +16 -10
  8. package/lib/components/CommonComponents/CartesianChart.base.js.map +1 -1
  9. package/lib/components/CommonComponents/CartesianChart.styles.js +35 -62
  10. package/lib/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  11. package/lib/components/DonutChart/DonutChart.styles.js +2 -18
  12. package/lib/components/DonutChart/DonutChart.styles.js.map +1 -1
  13. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +3 -14
  14. package/lib/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
  15. package/lib/components/LineChart/LineChart.styles.js +3 -11
  16. package/lib/components/LineChart/LineChart.styles.js.map +1 -1
  17. package/lib/components/SankeyChart/SankeyChart.styles.js +2 -1
  18. package/lib/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  19. package/lib/components/ScatterChart/ScatterChart.styles.js +3 -14
  20. package/lib/components/ScatterChart/ScatterChart.styles.js.map +1 -1
  21. package/lib/components/VerticalBarChart/VerticalBarChart.styles.js +3 -14
  22. package/lib/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
  23. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +3 -14
  24. package/lib/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
  25. package/lib/utilities/Common.styles.d.ts +6 -0
  26. package/lib/utilities/Common.styles.js +51 -0
  27. package/lib/utilities/Common.styles.js.map +1 -0
  28. package/lib/utilities/SVGTooltipText.d.ts +1 -1
  29. package/lib/utilities/SVGTooltipText.js.map +1 -1
  30. package/lib/utilities/index.d.ts +1 -0
  31. package/lib/utilities/index.js +1 -0
  32. package/lib/utilities/index.js.map +1 -1
  33. package/lib-amd/components/AreaChart/AreaChart.styles.js +2 -2
  34. package/lib-amd/components/AreaChart/AreaChart.styles.js.map +1 -1
  35. package/lib-amd/components/CommonComponents/CartesianChart.base.js +16 -10
  36. package/lib-amd/components/CommonComponents/CartesianChart.base.js.map +1 -1
  37. package/lib-amd/components/CommonComponents/CartesianChart.styles.js +33 -61
  38. package/lib-amd/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  39. package/lib-amd/components/DonutChart/DonutChart.styles.js +2 -17
  40. package/lib-amd/components/DonutChart/DonutChart.styles.js.map +1 -1
  41. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +3 -13
  42. package/lib-amd/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
  43. package/lib-amd/components/LineChart/LineChart.styles.js +3 -10
  44. package/lib-amd/components/LineChart/LineChart.styles.js.map +1 -1
  45. package/lib-amd/components/SankeyChart/SankeyChart.styles.js +2 -2
  46. package/lib-amd/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  47. package/lib-amd/components/ScatterChart/ScatterChart.styles.js +3 -13
  48. package/lib-amd/components/ScatterChart/ScatterChart.styles.js.map +1 -1
  49. package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js +3 -13
  50. package/lib-amd/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
  51. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +3 -13
  52. package/lib-amd/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
  53. package/lib-amd/utilities/Common.styles.d.ts +6 -0
  54. package/lib-amd/utilities/Common.styles.js +57 -0
  55. package/lib-amd/utilities/Common.styles.js.map +1 -0
  56. package/lib-amd/utilities/SVGTooltipText.d.ts +1 -1
  57. package/lib-amd/utilities/SVGTooltipText.js.map +1 -1
  58. package/lib-amd/utilities/index.d.ts +1 -0
  59. package/lib-amd/utilities/index.js +2 -1
  60. package/lib-amd/utilities/index.js.map +1 -1
  61. package/lib-commonjs/components/AreaChart/AreaChart.styles.js +2 -2
  62. package/lib-commonjs/components/AreaChart/AreaChart.styles.js.map +1 -1
  63. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js +16 -10
  64. package/lib-commonjs/components/CommonComponents/CartesianChart.base.js.map +1 -1
  65. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js +33 -60
  66. package/lib-commonjs/components/CommonComponents/CartesianChart.styles.js.map +1 -1
  67. package/lib-commonjs/components/DonutChart/DonutChart.styles.js +2 -18
  68. package/lib-commonjs/components/DonutChart/DonutChart.styles.js.map +1 -1
  69. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js +3 -14
  70. package/lib-commonjs/components/GroupedVerticalBarChart/GroupedVerticalBarChart.styles.js.map +1 -1
  71. package/lib-commonjs/components/LineChart/LineChart.styles.js +3 -11
  72. package/lib-commonjs/components/LineChart/LineChart.styles.js.map +1 -1
  73. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js +2 -1
  74. package/lib-commonjs/components/SankeyChart/SankeyChart.styles.js.map +1 -1
  75. package/lib-commonjs/components/ScatterChart/ScatterChart.styles.js +3 -14
  76. package/lib-commonjs/components/ScatterChart/ScatterChart.styles.js.map +1 -1
  77. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js +3 -14
  78. package/lib-commonjs/components/VerticalBarChart/VerticalBarChart.styles.js.map +1 -1
  79. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js +3 -14
  80. package/lib-commonjs/components/VerticalStackedBarChart/VerticalStackedBarChart.styles.js.map +1 -1
  81. package/lib-commonjs/utilities/Common.styles.d.ts +6 -0
  82. package/lib-commonjs/utilities/Common.styles.js +58 -0
  83. package/lib-commonjs/utilities/Common.styles.js.map +1 -0
  84. package/lib-commonjs/utilities/SVGTooltipText.d.ts +1 -1
  85. package/lib-commonjs/utilities/SVGTooltipText.js.map +1 -1
  86. package/lib-commonjs/utilities/index.d.ts +1 -0
  87. package/lib-commonjs/utilities/index.js +1 -0
  88. package/lib-commonjs/utilities/index.js.map +1 -1
  89. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"SVGTooltipText.js","sourceRoot":"../src/","sources":["utilities/SVGTooltipText.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAA+B,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AACjG,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AA0F7E,IAAM,OAAO,GAAG,CAAC,CAAC;AAElB;;;GAGG;AACH;IACU,kCAA2D;IAkBnE,wBAAY,KAA2B;QACrC,YAAA,MAAK,YAAC,KAAK,CAAC,SAAC;QAVf,6CAA6C;QACrC,kBAAY,GAAG,KAAK,CAAC,SAAS,EAAkB,CAAC;QAKjD,oBAAc,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC;QAoFxC,UAAI,GAAG;YACZ,KAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QAC5B,CAAC,CAAC;QAEK,aAAO,GAAG;YACf,KAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC,CAAC;QAEM,kBAAY,GAAG;YACrB,IAAI,KAAI,CAAC,YAAY,CAAC,OAAO,IAAI,OAAO,KAAI,CAAC,YAAY,CAAC,OAAO,CAAC,OAAO,KAAK,UAAU,EAAE,CAAC;gBACzF,IAAM,IAAI,GAAG,KAAI,CAAC,YAAY,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC;gBACjD,KAAI,CAAC,QAAQ,CAAC;oBACZ,KAAK,EAAE,IAAI,CAAC,CAAC;oBACb,KAAK,EAAE,IAA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ip';\nimport { Async, KeyCodes, getId, portalContainsElement } from '../Utilities';\nimport { ITheme } from '@fluentui/react';\n\ninterface ISVGTooltipTextProps {\n /**\n * Number of milliseconds to delay closing the tooltip, so that the user has time to hover over\n * the tooltip and interact with it. Hovering over the tooltip will count as hovering over the\n * host, so that the tooltip will stay open if the user is actively interacting with it.\n */\n closeDelay?: number;\n\n /**\n * Content to display in the Tooltip.\n */\n content?: string;\n\n /**\n * Length of delay before showing the tooltip on hover.\n * @defaultvalue TooltipDelay.medium\n */\n delay?: TooltipDelay;\n\n /**\n * Additional properties to pass through for Tooltip.\n */\n tooltipProps?: ITooltipProps;\n\n /**\n * Additional properties to pass through for SVG <text>.\n */\n textProps?: React.SVGAttributes<SVGTextElement>;\n\n /**\n * Max width of text\n */\n maxWidth?: number;\n\n /**\n * Max height of text\n */\n maxHeight?: number;\n\n /**\n * Pass false to make prevent the tooptip from receiving focus through keyboard\n * Eg: In Pie Chart, the focus should only land on the arcs and not on the text to\n * avoid repitition of the same datapoint\n * @defaultvalue true\n */\n shouldReceiveFocus?: boolean;\n\n /**\n * Pass true to show tooltip directly\n * Eg: In Pie Chart, the tooltip is shown when the arc is focussed, so the prop is set to true,\n * to directly show the tooltip from this component\n * @defaultvalue false\n */\n isTooltipVisibleProp?: boolean;\n\n /**\n * Function to wrap text within specified width and height\n * and return a boolean value indicating whether the text overflowed\n */\n wrapContent?: (content: string, id: string, maxWidth: number, maxHeight?: number) => boolean;\n\n /**\n * Theme provided by High Order Component\n */\n theme?: ITheme;\n\n /**\n * @default false\n * Prop to selectively display the tooltip background\n */\n showBackground?: boolean;\n\n /**\n * Prop to set classname\n */\n className?: string;\n}\n\ninterface ISVGTooltipTextState {\n isTooltipVisible: boolean;\n isOverflowing: boolean;\n textX?: number;\n textY?: number;\n textWidth?: number;\n textHeight?: number;\n}\n\nconst PADDING = 3;\n\n/**\n * Component to render an SVG text element with an optional tooltip.\n * The tooltip appears on hovering and focusing the element when its content overflows.\n */\nexport class SVGTooltipText\n extends React.Component<ISVGTooltipTextProps, ISVGTooltipTextState>\n implements ITooltipHost\n{\n public static defaultProps = {\n delay: TooltipDelay.medium,\n };\n\n private static _currentVisibleTooltip: ITooltipHost | undefined;\n\n /** The element that gets the hover events */\n private _tooltipHost = React.createRef<SVGTextElement>();\n\n private _async: Async;\n private _dismissTimerId: number;\n private _openTimerId: number;\n private _tooltipHostId = getId('tooltip-host');\n private _ignoreNextFocusEvent: boolean;\n\n constructor(props: ISVGTooltipTextProps) {\n super(props);\n\n this.state = {\n isTooltipVisible: false,\n isOverflowing: false,\n };\n\n this._async = new Async(this);\n }\n\n public render(): React.ReactNode {\n const { content, tooltipProps, textProps, shouldReceiveFocus = true, showBackground = false } = this.props;\n const { isTooltipVisible, textWidth, textHeight } = this.state;\n const tooltipRenderProps: ITooltipProps = {\n content,\n targetElement: this._getTargetElement(),\n calloutProps: {\n onDismiss: this._hideTooltip,\n onMouseEnter: this._onTooltipMouseEnter,\n onMouseLeave: this._onTooltipMouseLeave,\n },\n onMouseEnter: this._onTooltipMouseEnter,\n onMouseLeave: this._onTooltipMouseLeave,\n ...tooltipProps,\n };\n\n const showTooltip =\n (!!this.props.isTooltipVisibleProp && this.state.isOverflowing && !!content) || (isTooltipVisible && !!content);\n const rectX = (typeof textProps?.x === 'number' ? textProps.x : 0) - (textWidth ?? 0) / 2 - PADDING;\n const rectY = (typeof textProps?.y === 'number' ? textProps.y : 0) - (textHeight ?? 0) / 2 - 2 * PADDING;\n return (\n <>\n {showBackground && (\n <rect\n x={rectX}\n y={rectY}\n width={(textWidth ?? 0) + 2 * PADDING}\n height={(textHeight ?? 0) + PADDING}\n transform={textProps?.transform}\n className={this.props.className}\n />\n )}\n <text\n {...textProps}\n id={this._tooltipHostId}\n ref={this._tooltipHost}\n onFocusCapture={this._onTooltipFocus}\n onBlurCapture={this._onTooltipBlur}\n onMouseEnter={this._onTooltipMouseEnter}\n onMouseLeave={this._onTooltipMouseLeave}\n onKeyDown={this._onTooltipKeyDown}\n data-is-focusable={shouldReceiveFocus && this.state.isOverflowing}\n >\n {content}\n </text>\n {showTooltip && <Tooltip {...tooltipRenderProps} />}\n </>\n );\n }\n\n public componentDidMount(): void {\n this._wrapContent();\n this._measureText();\n }\n\n public componentDidUpdate(prevProps: Readonly<ISVGTooltipTextProps>): void {\n if (this.props.maxWidth !== prevProps.maxWidth || this.props.maxHeight !== prevProps.maxHeight) {\n this._wrapContent();\n this._measureText();\n }\n }\n\n public componentWillUnmount(): void {\n if (SVGTooltipText._currentVisibleTooltip && SVGTooltipText._currentVisibleTooltip === this) {\n SVGTooltipText._currentVisibleTooltip = undefined;\n }\n\n this._async.dispose();\n }\n\n public show = (): void => {\n this._toggleTooltip(true);\n };\n\n public dismiss = (): void => {\n this._hideTooltip();\n };\n\n private _measureText = (): void => {\n if (this._tooltipHost.current && typeof this._tooltipHost.current.getBBox === 'function') {\n const bbox = this._tooltipHost.current.getBBox();\n this.setState({\n textX: bbox.x,\n textY: bbox.y,\n textWidth: bbox.width,\n textHeight: bbox.height,\n });\n }\n };\n\n private _getTargetElement = (): HTMLElement | undefined => {\n if (!this._tooltipHost.current) {\n return undefined;\n }\n\n return this._tooltipHost.current as unknown as HTMLElement;\n };\n\n private _onTooltipFocus = (ev: React.FocusEvent<SVGElement>) => {\n if (this._ignoreNextFocusEvent) {\n this._ignoreNextFocusEvent = false;\n return;\n }\n\n this._onTooltipMouseEnter(ev);\n };\n\n private _onTooltipBlur = (ev: React.FocusEvent<SVGElement>) => {\n // The focused element gets a blur event when the document loses focus\n // (e.g. switching tabs in the browser), but we don't want to show the\n // tooltip again when the document gets focus back. Handle this case by\n // checking if the blurred element is still the document's activeElement,\n // and ignoring when it next gets focus back.\n // See https://github.com/microsoft/fluentui/issues/13541\n this._ignoreNextFocusEvent = document?.activeElement === ev.target;\n\n this._dismissTimerId = this._async.setTimeout(() => {\n this._hideTooltip();\n }, 0);\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _onTooltipMouseEnter = (ev: any): void => {\n const { delay } = this.props;\n\n if (SVGTooltipText._currentVisibleTooltip && SVGTooltipText._currentVisibleTooltip !== this) {\n SVGTooltipText._currentVisibleTooltip.dismiss();\n }\n SVGTooltipText._currentVisibleTooltip = this;\n\n if (!this.state.isOverflowing) {\n return;\n }\n\n if (ev.target && portalContainsElement(ev.target as HTMLElement, this._getTargetElement())) {\n // Do not show tooltip when target is inside a portal relative to TooltipHost.\n return;\n }\n\n this._clearDismissTimer();\n this._clearOpenTimer();\n\n if (delay !== TooltipDelay.zero) {\n const delayTime = this._getDelayTime(delay!); // non-null assertion because we set it in `defaultProps`\n\n this._openTimerId = this._async.setTimeout(() => {\n this._toggleTooltip(true);\n }, delayTime);\n } else {\n this._toggleTooltip(true);\n }\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _onTooltipMouseLeave = (ev: any): void => {\n const { closeDelay } = this.props;\n\n this._clearDismissTimer();\n this._clearOpenTimer();\n\n if (closeDelay) {\n this._dismissTimerId = this._async.setTimeout(() => {\n this._toggleTooltip(false);\n }, closeDelay);\n } else {\n this._toggleTooltip(false);\n }\n\n if (SVGTooltipText._currentVisibleTooltip === this) {\n SVGTooltipText._currentVisibleTooltip = undefined;\n }\n };\n\n private _onTooltipKeyDown = (ev: React.KeyboardEvent<SVGElement>): void => {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n if ((ev.which === KeyCodes.escape || ev.ctrlKey) && this.state.isTooltipVisible) {\n this._hideTooltip();\n ev.stopPropagation();\n }\n };\n\n private _clearDismissTimer = (): void => {\n this._async.clearTimeout(this._dismissTimerId);\n };\n\n private _clearOpenTimer = (): void => {\n this._async.clearTimeout(this._openTimerId);\n };\n\n private _hideTooltip = (): void => {\n this._clearOpenTimer();\n this._clearDismissTimer();\n this._toggleTooltip(false);\n };\n\n private _toggleTooltip = (isTooltipVisible: boolean): void => {\n if (this.state.isTooltipVisible !== isTooltipVisible) {\n this.setState({ isTooltipVisible });\n }\n };\n\n private _getDelayTime = (delay: TooltipDelay): number => {\n switch (delay) {\n case TooltipDelay.medium:\n return 300;\n case TooltipDelay.long:\n return 500;\n default:\n return 0;\n }\n };\n\n private _wrapContent = () => {\n const { content, wrapContent, maxWidth = Number.POSITIVE_INFINITY, maxHeight } = this.props;\n\n let isOverflowing = false;\n if (content && wrapContent && wrapContent(content, this._tooltipHostId, maxWidth, maxHeight)) {\n isOverflowing = true;\n }\n\n if (this.state.isOverflowing !== isOverflowing) {\n this.setState({ isOverflowing });\n }\n };\n}\n"]}
1
+ {"version":3,"file":"SVGTooltipText.js","sourceRoot":"../src/","sources":["utilities/SVGTooltipText.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAA+B,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AACjG,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AA0F7E,IAAM,OAAO,GAAG,CAAC,CAAC;AAElB;;;GAGG;AACH;IACU,kCAA2D;IAkBnE,wBAAY,KAA2B;QACrC,YAAA,MAAK,YAAC,KAAK,CAAC,SAAC;QAVf,6CAA6C;QACrC,kBAAY,GAAG,KAAK,CAAC,SAAS,EAAkB,CAAC;QAKjD,oBAAc,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC;QAoFxC,UAAI,GAAG;YACZ,KAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QAC5B,CAAC,CAAC;QAEK,aAAO,GAAG;YACf,KAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC,CAAC;QAEM,kBAAY,GAAG;YACrB,IAAI,KAAI,CAAC,YAAY,CAAC,OAAO,IAAI,OAAO,KAAI,CAAC,YAAY,CAAC,OAAO,CAAC,OAAO,KAAK,UAAU,EAAE,CAAC;gBACzF,IAAM,IAAI,GAAG,KAAI,CAAC,YAAY,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC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PY,cAAc","sourcesContent":["import * as React from 'react';\nimport { ITooltipHost, ITooltipProps, Tooltip, TooltipDelay } from '@fluentui/react/lib/Tooltip';\nimport { Async, KeyCodes, getId, portalContainsElement } from '../Utilities';\nimport { ITheme } from '@fluentui/react';\n\nexport interface ISVGTooltipTextProps {\n /**\n * Number of milliseconds to delay closing the tooltip, so that the user has time to hover over\n * the tooltip and interact with it. Hovering over the tooltip will count as hovering over the\n * host, so that the tooltip will stay open if the user is actively interacting with it.\n */\n closeDelay?: number;\n\n /**\n * Content to display in the Tooltip.\n */\n content?: string;\n\n /**\n * Length of delay before showing the tooltip on hover.\n * @defaultvalue TooltipDelay.medium\n */\n delay?: TooltipDelay;\n\n /**\n * Additional properties to pass through for Tooltip.\n */\n tooltipProps?: ITooltipProps;\n\n /**\n * Additional properties to pass through for SVG <text>.\n */\n textProps?: React.SVGAttributes<SVGTextElement>;\n\n /**\n * Max width of text\n */\n maxWidth?: number;\n\n /**\n * Max height of text\n */\n maxHeight?: number;\n\n /**\n * Pass false to make prevent the tooptip from receiving focus through keyboard\n * Eg: In Pie Chart, the focus should only land on the arcs and not on the text to\n * avoid repitition of the same datapoint\n * @defaultvalue true\n */\n shouldReceiveFocus?: boolean;\n\n /**\n * Pass true to show tooltip directly\n * Eg: In Pie Chart, the tooltip is shown when the arc is focussed, so the prop is set to true,\n * to directly show the tooltip from this component\n * @defaultvalue false\n */\n isTooltipVisibleProp?: boolean;\n\n /**\n * Function to wrap text within specified width and height\n * and return a boolean value indicating whether the text overflowed\n */\n wrapContent?: (content: string, id: string, maxWidth: number, maxHeight?: number) => boolean;\n\n /**\n * Theme provided by High Order Component\n */\n theme?: ITheme;\n\n /**\n * @default false\n * Prop to selectively display the tooltip background\n */\n showBackground?: boolean;\n\n /**\n * Prop to set classname\n */\n className?: string;\n}\n\ninterface ISVGTooltipTextState {\n isTooltipVisible: boolean;\n isOverflowing: boolean;\n textX?: number;\n textY?: number;\n textWidth?: number;\n textHeight?: number;\n}\n\nconst PADDING = 3;\n\n/**\n * Component to render an SVG text element with an optional tooltip.\n * The tooltip appears on hovering and focusing the element when its content overflows.\n */\nexport class SVGTooltipText\n extends React.Component<ISVGTooltipTextProps, ISVGTooltipTextState>\n implements ITooltipHost\n{\n public static defaultProps = {\n delay: TooltipDelay.medium,\n };\n\n private static _currentVisibleTooltip: ITooltipHost | undefined;\n\n /** The element that gets the hover events */\n private _tooltipHost = React.createRef<SVGTextElement>();\n\n private _async: Async;\n private _dismissTimerId: number;\n private _openTimerId: number;\n private _tooltipHostId = getId('tooltip-host');\n private _ignoreNextFocusEvent: boolean;\n\n constructor(props: ISVGTooltipTextProps) {\n super(props);\n\n this.state = {\n isTooltipVisible: false,\n isOverflowing: false,\n };\n\n this._async = new Async(this);\n }\n\n public render(): React.ReactNode {\n const { content, tooltipProps, textProps, shouldReceiveFocus = true, showBackground = false } = this.props;\n const { isTooltipVisible, textWidth, textHeight } = this.state;\n const tooltipRenderProps: ITooltipProps = {\n content,\n targetElement: this._getTargetElement(),\n calloutProps: {\n onDismiss: this._hideTooltip,\n onMouseEnter: this._onTooltipMouseEnter,\n onMouseLeave: this._onTooltipMouseLeave,\n },\n onMouseEnter: this._onTooltipMouseEnter,\n onMouseLeave: this._onTooltipMouseLeave,\n ...tooltipProps,\n };\n\n const showTooltip =\n (!!this.props.isTooltipVisibleProp && this.state.isOverflowing && !!content) || (isTooltipVisible && !!content);\n const rectX = (typeof textProps?.x === 'number' ? textProps.x : 0) - (textWidth ?? 0) / 2 - PADDING;\n const rectY = (typeof textProps?.y === 'number' ? textProps.y : 0) - (textHeight ?? 0) / 2 - 2 * PADDING;\n return (\n <>\n {showBackground && (\n <rect\n x={rectX}\n y={rectY}\n width={(textWidth ?? 0) + 2 * PADDING}\n height={(textHeight ?? 0) + PADDING}\n transform={textProps?.transform}\n className={this.props.className}\n />\n )}\n <text\n {...textProps}\n id={this._tooltipHostId}\n ref={this._tooltipHost}\n onFocusCapture={this._onTooltipFocus}\n onBlurCapture={this._onTooltipBlur}\n onMouseEnter={this._onTooltipMouseEnter}\n onMouseLeave={this._onTooltipMouseLeave}\n onKeyDown={this._onTooltipKeyDown}\n data-is-focusable={shouldReceiveFocus && this.state.isOverflowing}\n >\n {content}\n </text>\n {showTooltip && <Tooltip {...tooltipRenderProps} />}\n </>\n );\n }\n\n public componentDidMount(): void {\n this._wrapContent();\n this._measureText();\n }\n\n public componentDidUpdate(prevProps: Readonly<ISVGTooltipTextProps>): void {\n if (this.props.maxWidth !== prevProps.maxWidth || this.props.maxHeight !== prevProps.maxHeight) {\n this._wrapContent();\n this._measureText();\n }\n }\n\n public componentWillUnmount(): void {\n if (SVGTooltipText._currentVisibleTooltip && SVGTooltipText._currentVisibleTooltip === this) {\n SVGTooltipText._currentVisibleTooltip = undefined;\n }\n\n this._async.dispose();\n }\n\n public show = (): void => {\n this._toggleTooltip(true);\n };\n\n public dismiss = (): void => {\n this._hideTooltip();\n };\n\n private _measureText = (): void => {\n if (this._tooltipHost.current && typeof this._tooltipHost.current.getBBox === 'function') {\n const bbox = this._tooltipHost.current.getBBox();\n this.setState({\n textX: bbox.x,\n textY: bbox.y,\n textWidth: bbox.width,\n textHeight: bbox.height,\n });\n }\n };\n\n private _getTargetElement = (): HTMLElement | undefined => {\n if (!this._tooltipHost.current) {\n return undefined;\n }\n\n return this._tooltipHost.current as unknown as HTMLElement;\n };\n\n private _onTooltipFocus = (ev: React.FocusEvent<SVGElement>) => {\n if (this._ignoreNextFocusEvent) {\n this._ignoreNextFocusEvent = false;\n return;\n }\n\n this._onTooltipMouseEnter(ev);\n };\n\n private _onTooltipBlur = (ev: React.FocusEvent<SVGElement>) => {\n // The focused element gets a blur event when the document loses focus\n // (e.g. switching tabs in the browser), but we don't want to show the\n // tooltip again when the document gets focus back. Handle this case by\n // checking if the blurred element is still the document's activeElement,\n // and ignoring when it next gets focus back.\n // See https://github.com/microsoft/fluentui/issues/13541\n this._ignoreNextFocusEvent = document?.activeElement === ev.target;\n\n this._dismissTimerId = this._async.setTimeout(() => {\n this._hideTooltip();\n }, 0);\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _onTooltipMouseEnter = (ev: any): void => {\n const { delay } = this.props;\n\n if (SVGTooltipText._currentVisibleTooltip && SVGTooltipText._currentVisibleTooltip !== this) {\n SVGTooltipText._currentVisibleTooltip.dismiss();\n }\n SVGTooltipText._currentVisibleTooltip = this;\n\n if (!this.state.isOverflowing) {\n return;\n }\n\n if (ev.target && portalContainsElement(ev.target as HTMLElement, this._getTargetElement())) {\n // Do not show tooltip when target is inside a portal relative to TooltipHost.\n return;\n }\n\n this._clearDismissTimer();\n this._clearOpenTimer();\n\n if (delay !== TooltipDelay.zero) {\n const delayTime = this._getDelayTime(delay!); // non-null assertion because we set it in `defaultProps`\n\n this._openTimerId = this._async.setTimeout(() => {\n this._toggleTooltip(true);\n }, delayTime);\n } else {\n this._toggleTooltip(true);\n }\n };\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _onTooltipMouseLeave = (ev: any): void => {\n const { closeDelay } = this.props;\n\n this._clearDismissTimer();\n this._clearOpenTimer();\n\n if (closeDelay) {\n this._dismissTimerId = this._async.setTimeout(() => {\n this._toggleTooltip(false);\n }, closeDelay);\n } else {\n this._toggleTooltip(false);\n }\n\n if (SVGTooltipText._currentVisibleTooltip === this) {\n SVGTooltipText._currentVisibleTooltip = undefined;\n }\n };\n\n private _onTooltipKeyDown = (ev: React.KeyboardEvent<SVGElement>): void => {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n if ((ev.which === KeyCodes.escape || ev.ctrlKey) && this.state.isTooltipVisible) {\n this._hideTooltip();\n ev.stopPropagation();\n }\n };\n\n private _clearDismissTimer = (): void => {\n this._async.clearTimeout(this._dismissTimerId);\n };\n\n private _clearOpenTimer = (): void => {\n this._async.clearTimeout(this._openTimerId);\n };\n\n private _hideTooltip = (): void => {\n this._clearOpenTimer();\n this._clearDismissTimer();\n this._toggleTooltip(false);\n };\n\n private _toggleTooltip = (isTooltipVisible: boolean): void => {\n if (this.state.isTooltipVisible !== isTooltipVisible) {\n this.setState({ isTooltipVisible });\n }\n };\n\n private _getDelayTime = (delay: TooltipDelay): number => {\n switch (delay) {\n case TooltipDelay.medium:\n return 300;\n case TooltipDelay.long:\n return 500;\n default:\n return 0;\n }\n };\n\n private _wrapContent = () => {\n const { content, wrapContent, maxWidth = Number.POSITIVE_INFINITY, maxHeight } = this.props;\n\n let isOverflowing = false;\n if (content && wrapContent && wrapContent(content, this._tooltipHostId, maxWidth, maxHeight)) {\n isOverflowing = true;\n }\n\n if (this.state.isOverflowing !== isOverflowing) {\n this.setState({ isOverflowing });\n }\n };\n}\n"]}
@@ -1,4 +1,5 @@
1
1
  export * from './ChartHoverCard/index';
2
+ export * from './Common.styles';
2
3
  export * from './utilities';
3
4
  export * from './colors';
4
5
  export * from './gradients';
@@ -1,4 +1,5 @@
1
1
  export * from './ChartHoverCard/index';
2
+ export * from './Common.styles';
2
3
  export * from './utilities';
3
4
  export * from './colors';
4
5
  export * from './gradients';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["utilities/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC","sourcesContent":["export * from './ChartHoverCard/index';\nexport * from './utilities';\nexport * from './colors';\nexport * from './gradients';\nexport * from './vbc-utils';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["utilities/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC","sourcesContent":["export * from './ChartHoverCard/index';\nexport * from './Common.styles';\nexport * from './utilities';\nexport * from './colors';\nexport * from './gradients';\nexport * from './vbc-utils';\n"]}
@@ -1,10 +1,10 @@
1
- define(["require", "exports", "tslib"], function (require, exports, tslib_1) {
1
+ define(["require", "exports", "../../utilities/index"], function (require, exports, index_1) {
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.getStyles = void 0;
5
5
  var getStyles = function (props) {
6
6
  return {
7
- tooltip: tslib_1.__assign(tslib_1.__assign({}, props.theme.fonts.medium), { display: 'flex', flexDirection: 'column', padding: '8px', position: 'absolute', textAlign: 'center', top: '0px', background: props.theme.semanticColors.bodyBackground, borderRadius: '2px', pointerEvents: 'none', color: props.theme.semanticColors.bodyText }),
7
+ tooltip: (0, index_1.getTooltipStyle)(props.theme),
8
8
  };
9
9
  };
10
10
  exports.getStyles = getStyles;
@@ -1 +1 @@
1
- {"version":3,"file":"AreaChart.styles.js","sourceRoot":"../src/","sources":["components/AreaChart/AreaChart.styles.ts"],"names":[],"mappings":";;;;IAEO,IAAM,SAAS,GAAG,UAAC,KAA2B;QACnD,OAAO;YACL,OAAO,wCACF,KAAK,CAAC,KAAM,CAAC,KAAK,CAAC,MAAM,KAC5B,OAAO,EAAE,MAAM,EACf,aAAa,EAAE,QAAQ,EACvB,OAAO,EAAE,KAAK,EACd,QAAQ,EAAE,UAAU,EACpB,SAAS,EAAE,QAAQ,EACnB,GAAG,EAAE,KAAK,EACV,UAAU,EAAE,KAAK,CAAC,KAAM,CAAC,cAAc,CAAC,cAAc,EACtD,YAAY,EAAE,KAAK,EACnB,aAAa,EAAE,MAAM,EACrB,KAAK,EAAE,KAAK,CAAC,KAAM,CAAC,cAAc,CAAC,QAAQ,GAC5C;SACF,CAAC;IACJ,CAAC,CAAC;IAhBW,QAAA,SAAS,aAgBpB","sourcesContent":["import { IAreaChartStyleProps, IAreaChartStyles } from './AreaChart.types';\n\nexport const getStyles = (props: IAreaChartStyleProps): IAreaChartStyles => {\n return {\n tooltip: {\n ...props.theme!.fonts.medium,\n display: 'flex',\n flexDirection: 'column',\n padding: '8px',\n position: 'absolute',\n textAlign: 'center',\n top: '0px',\n background: props.theme!.semanticColors.bodyBackground,\n borderRadius: '2px',\n pointerEvents: 'none',\n color: props.theme!.semanticColors.bodyText,\n },\n };\n};\n"]}
1
+ {"version":3,"file":"AreaChart.styles.js","sourceRoot":"../src/","sources":["components/AreaChart/AreaChart.styles.ts"],"names":[],"mappings":";;;;IAGO,IAAM,SAAS,GAAG,UAAC,KAA2B;QACnD,OAAO;YACL,OAAO,EAAE,IAAA,uBAAe,EAAC,KAAK,CAAC,KAAM,CAAC;SACvC,CAAC;IACJ,CAAC,CAAC;IAJW,QAAA,SAAS,aAIpB","sourcesContent":["import { IAreaChartStyleProps, IAreaChartStyles } from './AreaChart.types';\nimport { getTooltipStyle } from '../../utilities/index';\n\nexport const getStyles = (props: IAreaChartStyleProps): IAreaChartStyles => {\n return {\n tooltip: getTooltipStyle(props.theme!),\n };\n};\n"]}
@@ -469,6 +469,12 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
469
469
  this.margins.top -
470
470
  this.state._removalValueForTextTuncate -
471
471
  this.titleMargin;
472
+ var commonSvgToolTipProps = {
473
+ wrapContent: index_1.wrapContent,
474
+ theme: this.props.theme,
475
+ showBackground: true,
476
+ className: this._classNames.svgTooltip,
477
+ };
472
478
  /**
473
479
  * We have use the {@link defaultTabbableElement } to fix
474
480
  * the Focus not landing on chart while tabbing, instead goes to legend.
@@ -498,20 +504,20 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
498
504
  }, id: "xAxisGElement".concat(this.idForGraph),
499
505
  // To add wrap of x axis lables feature, need to remove word height from svg height.
500
506
  transform: "translate(0, ".concat(svgDimensions.height - this.margins.bottom - this.state._removalValueForTextTuncate, ")"), className: this._classNames.xAxis }),
501
- this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, { content: this.props.xAxisTitle, textProps: {
507
+ this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, tslib_1.__assign({ content: this.props.xAxisTitle, textProps: {
502
508
  x: this.margins.left + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,
503
509
  y: svgDimensions.height - this.titleMargin,
504
510
  className: this._classNames.axisTitle,
505
511
  textAnchor: 'middle',
506
512
  'aria-hidden': true,
507
- }, maxWidth: xAxisTitleMaximumAllowedWidth, wrapContent: index_1.wrapContent, theme: this.props.theme, showBackground: true, className: this._classNames.svgTooltip })),
508
- this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, { content: this.props.xAxisAnnotation, textProps: {
513
+ }, maxWidth: xAxisTitleMaximumAllowedWidth }, commonSvgToolTipProps))),
514
+ this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, tslib_1.__assign({ content: this.props.xAxisAnnotation, textProps: {
509
515
  x: this.margins.left + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,
510
516
  y: this.titleMargin + 3,
511
517
  className: this._classNames.axisAnnotation,
512
518
  textAnchor: 'middle',
513
519
  'aria-hidden': true,
514
- }, maxWidth: xAxisTitleMaximumAllowedWidth, wrapContent: index_1.wrapContent, theme: this.props.theme, showBackground: true, className: this._classNames.svgTooltip })),
520
+ }, maxWidth: xAxisTitleMaximumAllowedWidth }, commonSvgToolTipProps))),
515
521
  React.createElement("g", { ref: function (e) {
516
522
  _this.yAxisElement = e;
517
523
  }, id: "yAxisGElement".concat(this.idForGraph), transform: "translate(".concat(this._isRtl
@@ -523,7 +529,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
523
529
  }, id: "yAxisGElementSecondary".concat(this.idForGraph), transform: "translate(".concat(this._isRtl
524
530
  ? this.margins.left + this.state.startFromX
525
531
  : svgDimensions.width - this.margins.right - this.state.startFromX, ", 0)"), className: this._classNames.yAxis }),
526
- this.props.secondaryYAxistitle !== undefined && this.props.secondaryYAxistitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, { content: this.props.secondaryYAxistitle, textProps: {
532
+ this.props.secondaryYAxistitle !== undefined && this.props.secondaryYAxistitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, tslib_1.__assign({ content: this.props.secondaryYAxistitle, textProps: {
527
533
  x: (yAxisTitleMaximumAllowedHeight - this.margins.bottom) / 2 +
528
534
  this.state._removalValueForTextTuncate,
529
535
  y: this._isRtl
@@ -535,9 +541,9 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
535
541
  : this.margins.right / 2 + this.titleMargin, ",\n ").concat(svgDimensions.height - this.margins.bottom - this.margins.top - this.titleMargin, ")rotate(-90)"),
536
542
  className: this._classNames.axisTitle,
537
543
  'aria-hidden': true,
538
- }, maxWidth: yAxisTitleMaximumAllowedHeight, wrapContent: index_1.wrapContent, theme: this.props.theme, showBackground: true, className: this._classNames.svgTooltip })))),
544
+ }, maxWidth: yAxisTitleMaximumAllowedHeight }, commonSvgToolTipProps))))),
539
545
  children,
540
- this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, { content: this.props.yAxisTitle, textProps: {
546
+ this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '' && (React.createElement(SVGTooltipText_1.SVGTooltipText, tslib_1.__assign({ content: this.props.yAxisTitle, textProps: {
541
547
  x: (yAxisTitleMaximumAllowedHeight - this.margins.bottom) / 2 +
542
548
  this.state._removalValueForTextTuncate,
543
549
  y: this._isRtl
@@ -547,10 +553,10 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
547
553
  transform: "translate(0,\n ".concat(svgDimensions.height - this.margins.bottom - this.margins.top - this.titleMargin, ")rotate(-90)"),
548
554
  className: this._classNames.axisTitle,
549
555
  'aria-hidden': true,
550
- }, maxWidth: yAxisTitleMaximumAllowedHeight, wrapContent: index_1.wrapContent, theme: this.props.theme, showBackground: true, className: this._classNames.svgTooltip })),
556
+ }, maxWidth: yAxisTitleMaximumAllowedHeight }, commonSvgToolTipProps))),
551
557
  this.props.yAxisAnnotation !== undefined &&
552
558
  this.props.yAxisAnnotation !== '' &&
553
- (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '') && (React.createElement(SVGTooltipText_1.SVGTooltipText, { content: this.props.yAxisAnnotation, textProps: {
559
+ (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '') && (React.createElement(SVGTooltipText_1.SVGTooltipText, tslib_1.__assign({ content: this.props.yAxisAnnotation, textProps: {
554
560
  x: (yAxisTitleMaximumAllowedHeight - this.margins.bottom) / 2 +
555
561
  this.state._removalValueForTextTuncate,
556
562
  y: this._isRtl
@@ -562,7 +568,7 @@ define(["require", "exports", "tslib", "react", "@fluentui/react/lib/Utilities",
562
568
  : this.margins.right / 2 + this.titleMargin, ",\n ").concat(svgDimensions.height - this.margins.bottom - this.margins.top - this.titleMargin, ")rotate(-90)"),
563
569
  className: this._classNames.axisAnnotation,
564
570
  'aria-hidden': true,
565
- }, maxWidth: yAxisTitleMaximumAllowedHeight, wrapContent: index_1.wrapContent, theme: this.props.theme, showBackground: true, className: this._classNames.svgTooltip })))),
571
+ }, maxWidth: yAxisTitleMaximumAllowedHeight }, commonSvgToolTipProps))))),
566
572
  !this.props.hideLegend && (React.createElement("div", { ref: function (e) { return (_this.legendContainer = e); }, className: this._classNames.legendContainer }, this.props.legendBars)),
567
573
  callout && React.createElement(React.Suspense, { fallback: React.createElement("div", null, "Loading...") }, callout)));
568
574
  };
@@ -1 +1 @@
1
- {"version":3,"file":"CartesianChart.base.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.base.tsx"],"names":[],"mappings":";;;;IAsCA,IAAM,aAAa,GAAG,IAAA,8BAAkB,GAAoD,CAAC;IAC7F,IAAM,cAAc,GAAG,KAAK,CAAC,IAAI,CAAC;Q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,CAAC,GAAG,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,KAAK,EAAE,KAAI,CAAC,uBAAuB,EAAE,CAAC;wBACnF,CAAC,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,KAAK,CAAC;oBAC9C,IAAM,sBAAsB,GAC1B,SAAS,CAAC,qBAAqB,EAAE,CAAC,MAAM,GAAG,qBAAqB;wBAC9D,CAAC,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,MAAM;wBAC1C,CAAC,CAAC,GAAG,CAAC;oBACV,IAAM,YAAY,GAChB,cAAc,KAAK,qBAAqB;wBACxC,eAAe,KAAK,sBAAsB,GAAG,qBAAqB,CAAC;oBACrE,IAAI,YAAY,EAAE,CAAC;wBACjB,KAAI,CAAC,QAAQ,CAAC;4BACZ,cAAc,EAAE,qBAAqB;4BACrC,eAAe,EAAE,sBAAsB,GAAG,qBAAqB;yBAChE,CAAC,CAAC;oBACL,CAAC;gBACH,CAAC;YACH,CAAC,CAAC,CAAC;QACL,CAAC;QAoGH,yBAAC;IAAD,CAAC,AAz/BD,CACU,KAAK,CAAC,SAAS,GAw/BxB;IAz/BY,gDAAkB","sourcesContent":["import * as React from 'react';\nimport { IProcessedStyleSet } from '@fluentui/react/lib/Styling';\nimport { classNamesFunction, getId, getRTL } from '@fluentui/react/lib/Utilities';\nimport { Callout } from '@fluentui/react/lib/Callout';\nimport { FocusZone, FocusZoneDirection } from '@fluentui/react-focus';\nimport { select as d3Select } from 'd3-selection';\nimport {\n ICartesianChartStyles,\n ICartesianChartStyleProps,\n IModifiedCartesianChartProps,\n IYValueHover,\n} from '../../index';\nimport { formatToLocaleString } from '@fluentui/chart-utilities';\nimport {\n createNumericXAxis,\n createStringXAxis,\n IAxisData,\n getAccessibleDataObject,\n createDateXAxis,\n IMargins,\n XAxisTypes,\n YAxisType,\n createWrapOfXLabels,\n rotateXAxisLabels,\n Points,\n pointTypes,\n calculateLongestLabelWidth,\n createYAxisLabels,\n ChartTypes,\n wrapContent,\n getSecureProps,\n truncateString,\n tooltipOfAxislabels,\n} from '../../utilities/index';\nimport { LegendShape, Shape } from '../Legends/index';\nimport { SVGTooltipText } from '../../utilities/SVGTooltipText';\nimport { IChart } from '../../types/index';\n\nconst getClassNames = classNamesFunction<ICartesianChartStyleProps, ICartesianChartStyles>();\nconst ChartHoverCard = React.lazy(() =>\n import('../../utilities/ChartHoverCard/ChartHoverCard').then(module => ({ default: module.ChartHoverCard })),\n);\nconst chartTypesWithStringYAxis = [\n ChartTypes.HorizontalBarChartWithAxis,\n ChartTypes.HeatMapChart,\n ChartTypes.VerticalStackedBarChart,\n];\n\nexport interface ICartesianChartState {\n containerWidth: number;\n containerHeight: number;\n _width: number;\n _height: number;\n /* To update this values using setState in render method.\n * To avoid multiple re renders, Only first time setting the value.\n */\n isRemoveValCalculated?: boolean;\n /* Used for when WrapXAxisLabels props appeared.\n * To display the total word (space separated words), Need to have more space than usual.\n * This height will get total height need to disaply total word.\n * These value need to be removed from actual svg height/graph height.\n * Defalut value is 0. And this values calculted when 'wrapXAxisLables' or 'showXAxisLablesTooltip' is true.\n */\n _removalValueForTextTuncate?: number;\n startFromX: number;\n}\n\n/**\n * Cartesian chart used for\n * 1.draw X and Y axis of the chart\n * 2.Callout\n * 3.Fit parent Continer\n */\nexport class CartesianChartBase\n extends React.Component<IModifiedCartesianChartProps, ICartesianChartState>\n implements IChart\n{\n public chartContainer: HTMLDivElement;\n private _classNames: IProcessedStyleSet<ICartesianChartStyles>;\n private legendContainer: HTMLDivElement;\n private minLegendContainerHeight: number = 32;\n private xAxisElement: SVGSVGElement | null;\n private yAxisElement: SVGSVGElement | null;\n private yAxisElementSecondary: SVGSVGElement | null;\n private margins: IMargins;\n private idForGraph: string;\n private idForDefaultTabbableElement: string;\n private _reqID: number;\n private _isRtl: boolean = getRTL();\n private _tickValues: (string | number)[];\n private titleMargin: number;\n private _isFirstRender: boolean = true;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _xScale: any;\n private isIntegralDataset: boolean = true;\n private _tooltipId: string;\n\n constructor(props: IModifiedCartesianChartProps) {\n super(props);\n this.state = {\n containerHeight: 0,\n containerWidth: 0,\n _width: this.props.width || 600,\n _height: this.props.height || 350,\n _removalValueForTextTuncate: 0,\n isRemoveValCalculated: true,\n startFromX: 0,\n };\n this.idForGraph = getId('chart_');\n this.titleMargin = 8;\n this.idForDefaultTabbableElement = getId('defaultTabbableElement_');\n this._tooltipId = getId('tooltip_');\n /**\n * In RTL mode, Only graph will be rendered left/right. We need to provide left and right margins manually.\n * So that, in RTL, left margins becomes right margins and viceversa.\n * As graph needs to be drawn perfecty, these values consider as default values.\n * Same margins using for all other cartesian charts. Can be accessible through 'getMargins' call back method.\n */\n this.margins = {\n top: this.props.margins?.top ?? 20,\n bottom: this.props.margins?.bottom ?? 35,\n right: this._isRtl\n ? this.props.margins?.left ?? 40\n : this.props.margins?.right ?? this.props?.secondaryYScaleOptions\n ? 40\n : 20,\n left: this._isRtl\n ? this.props.margins?.right ?? this.props?.secondaryYScaleOptions\n ? 40\n : 20\n : this.props.margins?.left ?? 40,\n };\n const TITLE_MARGIN_HORIZONTAL = 24;\n const TITLE_MARGIN_VERTICAL = 20;\n if (this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '') {\n this.margins.bottom! = this.props.margins?.bottom ?? this.margins.bottom! + TITLE_MARGIN_VERTICAL;\n }\n if (this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '') {\n this.margins.left! = this._isRtl\n ? this.props.margins?.right ?? this.props?.secondaryYAxistitle\n ? this.margins.right! + 2 * TITLE_MARGIN_HORIZONTAL\n : this.margins.right! + TITLE_MARGIN_HORIZONTAL\n : this.props.margins?.left ?? this.margins.left! + TITLE_MARGIN_HORIZONTAL;\n this.margins.right! = this._isRtl\n ? this.props.margins?.left ?? this.margins.left! + TITLE_MARGIN_HORIZONTAL\n : this.props.margins?.right ?? this.props?.secondaryYAxistitle\n ? this.margins.right! + 2 * TITLE_MARGIN_HORIZONTAL\n : this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n }\n if (this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '') {\n this.margins.top! = this.props.margins?.top ?? this.margins.top! + TITLE_MARGIN_VERTICAL;\n }\n if (\n this.props.yAxisAnnotation !== undefined &&\n this.props.yAxisAnnotation !== '' &&\n (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '')\n ) {\n if (this._isRtl) {\n this.margins.left! = this.props.margins?.right ?? this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n } else {\n this.margins.right! = this.props.margins?.right ?? this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n }\n }\n }\n\n public componentDidMount(): void {\n this._fitParentContainer();\n if (\n chartTypesWithStringYAxis.includes(this.props.chartType) &&\n this.props.showYAxisLables &&\n this.yAxisElement &&\n this.props.yAxisType === YAxisType.StringAxis\n ) {\n const maxYAxisLabelLength = this.calculateMaxYAxisLabelLength(this._classNames.yAxis!);\n if (this.state.startFromX !== maxYAxisLabelLength) {\n this.setState({\n startFromX: maxYAxisLabelLength,\n });\n }\n } else if (this.state.startFromX !== 0) {\n this.setState({\n startFromX: 0,\n });\n }\n this.isIntegralDataset = !this.props.points.some((point: { y: number }) => {\n return point.y % 1 !== 0;\n });\n }\n\n public componentWillUnmount(): void {\n cancelAnimationFrame(this._reqID);\n }\n\n public componentDidUpdate(prevProps: IModifiedCartesianChartProps): void {\n if (prevProps.height !== this.props.height || prevProps.width !== this.props.width) {\n this._fitParentContainer();\n }\n if (\n !this.props.wrapXAxisLables &&\n this.props.rotateXAxisLables &&\n this.props.xAxisType! === XAxisTypes.StringAxis\n ) {\n const rotateLabelProps = {\n node: this.xAxisElement,\n xAxis: this._xScale,\n };\n const rotatedHeight = rotateXAxisLabels(rotateLabelProps);\n if (\n this.state.isRemoveValCalculated &&\n this.state._removalValueForTextTuncate !== rotatedHeight! + this.margins.bottom! &&\n rotatedHeight! > 0\n ) {\n this.setState({\n _removalValueForTextTuncate: rotatedHeight! + this.margins.bottom!,\n isRemoveValCalculated: false,\n });\n }\n }\n if (\n chartTypesWithStringYAxis.includes(this.props.chartType) &&\n this.props.showYAxisLables &&\n this.yAxisElement &&\n this.props.yAxisType === YAxisType.StringAxis\n ) {\n const maxYAxisLabelLength = this.calculateMaxYAxisLabelLength(this._classNames.yAxis!);\n if (this.state.startFromX !== maxYAxisLabelLength) {\n this.setState({\n startFromX: maxYAxisLabelLength,\n });\n }\n } else if (this.state.startFromX !== 0) {\n this.setState({\n startFromX: 0,\n });\n }\n if (prevProps.points !== this.props.points) {\n this.isIntegralDataset = !this.props.points.some((point: { y: number }) => {\n return point.y % 1 !== 0;\n });\n }\n }\n\n public calculateMaxYAxisLabelLength = (className: string): number => {\n const formatTickLabel = (str: string) => {\n if (this.props.showYAxisLablesTooltip) {\n return truncateString(str, this.props.noOfCharsToTruncate || 4);\n }\n\n return str;\n };\n\n return calculateLongestLabelWidth(\n this.props.stringDatasetForYAxisDomain!.map(label => formatTickLabel(label)),\n `.${className} text`,\n );\n };\n\n public render(): JSX.Element {\n const {\n calloutProps,\n points,\n chartType,\n chartHoverProps,\n svgFocusZoneProps,\n svgProps,\n culture,\n dateLocalizeOptions,\n timeFormatLocale,\n customDateTimeFormatter,\n } = this.props;\n if (this.props.parentRef) {\n this._fitParentContainer();\n }\n\n const margin = { ...this.margins };\n // Note: This check is unnecessary since startFromX is only set for charts with string y-axis.\n if (chartTypesWithStringYAxis.includes(this.props.chartType)) {\n if (!this._isRtl) {\n margin.left! += this.state.startFromX;\n } else {\n margin.right! += this.state.startFromX;\n }\n }\n // Callback for margins to the chart\n this.props.getmargins && this.props.getmargins(margin);\n\n this._classNames = getClassNames(this.props.styles!, {\n theme: this.props.theme!,\n width: this.state._width,\n height: this.state._height,\n className: this.props.className,\n isRtl: this._isRtl,\n enableReflow: this.props.enableReflow,\n });\n\n let callout: JSX.Element | null = null;\n\n let children = null;\n if (\n (this.props.enableFirstRenderOptimization && this.chartContainer) ||\n !this.props.enableFirstRenderOptimization\n ) {\n this._isFirstRender = false;\n const XAxisParams = {\n domainNRangeValues: this.props.getDomainNRangeValues(\n points,\n this.props.getDomainMargins ? this.props.getDomainMargins(this.state.containerWidth) : this.margins,\n this.state.containerWidth,\n chartType,\n this._isRtl,\n this.props.xAxisType,\n this.props.barwidth!,\n this.props.tickValues!,\n // This is only used for Horizontal Bar Chart with Axis for y as string axis\n this.state.startFromX,\n ),\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n margins: this.margins,\n xAxisElement: this.xAxisElement!,\n showRoundOffXTickValues: this.props.showRoundOffXTickValues ?? true,\n xAxisCount: this.props.xAxisTickCount,\n xAxistickSize: this.props.xAxistickSize,\n tickPadding: this.props.tickPadding || this.props.showXAxisLablesTooltip ? 5 : 10,\n xAxisPadding: this.props.xAxisPadding,\n xAxisInnerPadding: this.props.xAxisInnerPadding,\n xAxisOuterPadding: this.props.xAxisOuterPadding,\n containerWidth: this.state.containerWidth,\n hideTickOverlap:\n this.props.hideTickOverlap &&\n !this.props.rotateXAxisLables &&\n !this.props.showXAxisLablesTooltip &&\n !this.props.wrapXAxisLables,\n };\n\n const YAxisParams = {\n margins: this.props.getYDomainMargins ? this.props.getYDomainMargins(this.state.containerHeight) : this.margins,\n containerWidth: this.state.containerWidth,\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n yAxisElement: this.yAxisElement,\n yAxisTickFormat: this.props.yAxisTickFormat!,\n yAxisTickCount: this.props.yAxisTickCount!,\n yMinValue: this.props.yMinValue || 0,\n yMaxValue: this.props.yMaxValue || 0,\n tickPadding: 10,\n maxOfYVal: this.props.maxOfYVal,\n yMinMaxValues: this.props.getMinMaxOfYAxis(points, this.props.yAxisType),\n // please note these padding default values must be consistent in here\n // and the parent chart(HBWA/Vertical etc..) for more details refer example\n // http://using-d3js.com/04_07_ordinal_scales.html\n yAxisPadding: this.props.yAxisPadding || 0,\n };\n /**\n * These scales used for 2 purposes.\n * 1. To create x and y axis\n * 2. To draw the graph.\n * For area/line chart using same scales. For other charts, creating their own scales to draw the graph.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let xScale: any;\n let tickValues: (string | number)[];\n switch (this.props.xAxisType!) {\n case XAxisTypes.NumericAxis:\n ({ xScale, tickValues } = createNumericXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.chartType,\n culture,\n ));\n break;\n case XAxisTypes.DateAxis:\n ({ xScale, tickValues } = createDateXAxis(\n XAxisParams,\n this.props.tickParams!,\n culture,\n dateLocalizeOptions,\n timeFormatLocale,\n customDateTimeFormatter,\n this.props.useUTC,\n ));\n break;\n case XAxisTypes.StringAxis:\n ({ xScale, tickValues } = createStringXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.datasetForXAxisDomain!,\n culture,\n ));\n break;\n default:\n ({ xScale, tickValues } = createNumericXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.chartType,\n culture,\n ));\n }\n this._xScale = xScale;\n this._tickValues = tickValues;\n\n /*\n * To enable wrapping of x axis tick values or to display complete x axis tick values,\n * we need to calculate how much space it needed to render the text.\n * No need to re-calculate every time the chart renders and same time need to get an update. So using setState.\n * Required space will be calculated first time chart rendering and if any width/height of chart updated.\n * */\n if (this.props.wrapXAxisLables || this.props.showXAxisLablesTooltip) {\n const wrapLabelProps = {\n node: this.xAxisElement,\n xAxis: xScale,\n showXAxisLablesTooltip: this.props.showXAxisLablesTooltip || false,\n noOfCharsToTruncate: this.props.noOfCharsToTruncate || 4,\n };\n const temp = xScale && (createWrapOfXLabels(wrapLabelProps) as number);\n // this value need to be updated for draw graph updated. So instead of using private value, using set state.\n if (this.state.isRemoveValCalculated && this.state._removalValueForTextTuncate !== temp) {\n this.setState({ _removalValueForTextTuncate: temp, isRemoveValCalculated: false });\n }\n }\n\n /**\n * These scales used for 2 purposes.\n * 1. To create x and y axis\n * 2. To draw the graph.\n * For area/line chart using same scales. For other charts, creating their own scales to draw the graph.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let yScalePrimary: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let yScaleSecondary: any;\n const axisData: IAxisData = { yAxisDomainValues: [] };\n if (this.props.yAxisType && this.props.yAxisType === YAxisType.StringAxis) {\n yScalePrimary = this.props.createStringYAxis(\n YAxisParams,\n this.props.stringDatasetForYAxisDomain!,\n this._isRtl,\n this.props.barwidth,\n this.props.chartType,\n );\n } else {\n // TODO: Since the scale domain values are now computed independently for both the primary and\n // secondary y-axes, the yMinValue and yMaxValue props are no longer necessary for accurately\n // rendering the secondary y-axis. Therefore, rather than checking the secondaryYScaleOptions\n // prop to determine whether to create a secondary y-axis, it's more appropriate to check if any\n // data points are assigned to use the secondary y-scale.\n if (this.props?.secondaryYScaleOptions) {\n const YAxisParamsSecondary = {\n margins: this.margins,\n containerWidth: this.state.containerWidth,\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n yAxisElement: this.yAxisElementSecondary,\n yAxisTickFormat: this.props.yAxisTickFormat!,\n yAxisTickCount: this.props.yAxisTickCount!,\n yMinValue: this.props.secondaryYScaleOptions?.yMinValue || 0,\n yMaxValue: this.props.secondaryYScaleOptions?.yMaxValue ?? 100,\n tickPadding: 10,\n yMinMaxValues: this.props.getMinMaxOfYAxis(points, this.props.yAxisType, true),\n yAxisPadding: this.props.yAxisPadding,\n };\n\n yScaleSecondary = this.props.createYAxis(\n YAxisParamsSecondary,\n this._isRtl,\n axisData,\n this.isIntegralDataset,\n true,\n this.props.supportNegativeData!,\n this.props.roundedTicks!,\n );\n }\n yScalePrimary = this.props.createYAxis(\n YAxisParams,\n this._isRtl,\n axisData,\n this.isIntegralDataset,\n false,\n this.props.supportNegativeData!,\n this.props.roundedTicks!,\n );\n }\n\n if (chartTypesWithStringYAxis.includes(this.props.chartType) && this.props.yAxisType === YAxisType.StringAxis) {\n // To create y axis tick values by if specified truncating the rest of the text\n // and showing elipsis or showing the whole string,\n yScalePrimary &&\n // Note: This function should be invoked within the showYAxisLablesTooltip check,\n // as its sole purpose is to truncate labels that exceed the noOfCharsToTruncate limit.\n createYAxisLabels(\n this.yAxisElement,\n yScalePrimary,\n this.props.noOfCharsToTruncate || 4,\n this.props.showYAxisLablesTooltip || false,\n this._isRtl,\n );\n\n // Removing un wanted tooltip div from DOM, when prop not provided, for proper cleanup\n // of unwanted DOM elements, to prevent flacky behaviour in tooltips , that might occur\n // in creating tooltips when tooltips are enabled( as we try to recreate a tspan with this._tooltipId)\n if (!this.props.showYAxisLablesTooltip) {\n try {\n document.getElementById(this._tooltipId) && document.getElementById(this._tooltipId)!.remove();\n //eslint-disable-next-line no-empty\n } catch (e) {}\n }\n // Used to display tooltip at y axis labels.\n if (this.props.showYAxisLablesTooltip) {\n const yAxisElement = d3Select(this.yAxisElement).call(yScalePrimary);\n try {\n document.getElementById(this._tooltipId) && document.getElementById(this._tooltipId)!.remove();\n //eslint-disable-next-line no-empty\n } catch (e) {}\n const ytooltipProps = {\n tooltipCls: this._classNames.tooltip!,\n id: this._tooltipId,\n axis: yAxisElement,\n };\n yAxisElement && tooltipOfAxislabels(ytooltipProps);\n }\n }\n\n this.props.getAxisData && this.props.getAxisData(axisData);\n // Callback function for chart, returns axis\n this._getData(xScale, yScalePrimary, yScaleSecondary);\n\n children = this.props.children({\n ...this.state,\n xScale,\n yScalePrimary,\n yScaleSecondary,\n });\n\n if (!this.props.hideTooltip && calloutProps!.isCalloutVisible) {\n callout = this._generateCallout(calloutProps, chartHoverProps);\n }\n }\n\n const svgDimensions = {\n width: this.state.containerWidth,\n height: this.state.containerHeight,\n };\n\n let focusDirection;\n if (this.props.focusZoneDirection === FocusZoneDirection.vertical) {\n focusDirection = this.props.focusZoneDirection;\n } else if (this.props.focusZoneDirection) {\n focusDirection = this.props.focusZoneDirection;\n } else {\n focusDirection = FocusZoneDirection.horizontal;\n }\n\n const xAxisTitleMaximumAllowedWidth =\n svgDimensions.width - this.margins.left! - this.margins.right! - this.state.startFromX!;\n const yAxisTitleMaximumAllowedHeight =\n svgDimensions.height -\n this.margins.bottom! -\n this.margins.top! -\n this.state._removalValueForTextTuncate! -\n this.titleMargin;\n /**\n * We have use the {@link defaultTabbableElement } to fix\n * the Focus not landing on chart while tabbing, instead goes to legend.\n * This issue is observed in Area, line chart after performance optimization done in the PR {@link https://github.com/microsoft/fluentui/pull/27721 }\n * This issue is observed in Bar charts after the changes done by FocusZone team in the PR: {@link https://github.com/microsoft/fluentui/pull/24175 }\n * The issue in Bar Charts(VB and VSB) is due to a {@link FocusZone } update where previously an event listener was\n * attached on keydown to the window, so that whenever the tab key is pressed all outer FocusZone's\n * tab-indexes are updated (an outer FocusZone is a FocusZone that is not within another one).\n * But now after the above PR : they are attaching the\n * listeners to the FocusZone elements instead of the window. So in the first render cycle in Bar charts\n * bars are not created as in the first render cycle the size of the chart container is not known( or is 0)\n * which creates bars of height 0 so instead we do not create any bars and instead return empty fragments.\n *\n * We have tried 2 Approaches to fix the issue:\n * 1. Using the {@link elementRef} property of FocusZone where we dispatch event for tab keydown\n * after the second render cycle which triggers an update of the tab index in FocusZone.\n * But this is a hacky solution and not a proper fix and also elementRef is deprecated.\n * 2. Using the default tabbable element to fix the issue.\n */\n\n return (\n <div\n id={this.idForGraph}\n className={this._classNames.root}\n ref={(rootElem: HTMLDivElement) => (this.chartContainer = rootElem)}\n onMouseLeave={this._onChartLeave}\n >\n {!this._isFirstRender && <div id={this.idForDefaultTabbableElement} />}\n <FocusZone\n direction={focusDirection}\n className={this._classNames.chartWrapper}\n defaultTabbableElement={`#${this.idForDefaultTabbableElement}`}\n {...svgFocusZoneProps}\n >\n {this._isFirstRender && <div id={this.idForDefaultTabbableElement} />}\n <svg\n width={svgDimensions.width}\n height={svgDimensions.height}\n role=\"region\"\n aria-label={this._getChartDescription()}\n style={{ display: 'block' }}\n {...getSecureProps(svgProps)}\n >\n <g\n ref={(e: SVGSVGElement | null) => {\n this.xAxisElement = e;\n }}\n id={`xAxisGElement${this.idForGraph}`}\n // To add wrap of x axis lables feature, need to remove word height from svg height.\n transform={`translate(0, ${\n svgDimensions.height - this.margins.bottom! - this.state._removalValueForTextTuncate!\n })`}\n className={this._classNames.xAxis}\n />\n {this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '' && (\n <SVGTooltipText\n content={this.props.xAxisTitle}\n textProps={{\n x: this.margins.left! + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,\n y: svgDimensions.height - this.titleMargin,\n className: this._classNames.axisTitle!,\n textAnchor: 'middle',\n 'aria-hidden': true,\n }}\n maxWidth={xAxisTitleMaximumAllowedWidth}\n wrapContent={wrapContent}\n theme={this.props.theme}\n showBackground={true}\n className={this._classNames.svgTooltip}\n />\n )}\n {this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '' && (\n <SVGTooltipText\n content={this.props.xAxisAnnotation}\n textProps={{\n x: this.margins.left! + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,\n y: this.titleMargin + 3,\n className: this._classNames.axisAnnotation!,\n textAnchor: 'middle',\n 'aria-hidden': true,\n }}\n maxWidth={xAxisTitleMaximumAllowedWidth}\n wrapContent={wrapContent}\n theme={this.props.theme}\n showBackground={true}\n className={this._classNames.svgTooltip}\n />\n )}\n <g\n ref={(e: SVGSVGElement | null) => {\n this.yAxisElement = e;\n }}\n id={`yAxisGElement${this.idForGraph}`}\n transform={`translate(${\n this._isRtl\n ? svgDimensions.width - this.margins.right! - this.state.startFromX\n : this.margins.left! + this.state.startFromX\n }, 0)`}\n className={this._classNames.yAxis}\n />\n {this.props.secondaryYScaleOptions && (\n <g>\n <g\n ref={(e: SVGSVGElement | null) => {\n this.yAxisElementSecondary = e;\n }}\n id={`yAxisGElementSecondary${this.idForGraph}`}\n transform={`translate(${\n this._isRtl\n ? this.margins.left! + this.state.startFromX\n : svgDimensions.width - this.margins.right! - this.state.startFromX\n }, 0)`}\n className={this._classNames.yAxis}\n />\n {this.props.secondaryYAxistitle !== undefined && this.props.secondaryYAxistitle !== '' && (\n <SVGTooltipText\n content={this.props.secondaryYAxistitle}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? this.state.startFromX - this.titleMargin\n : svgDimensions.width - this.margins.right!,\n textAnchor: 'middle',\n transform: `translate(${\n this._isRtl\n ? this.margins.right! / 2 - this.titleMargin\n : this.margins.right! / 2 + this.titleMargin\n },\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisTitle!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n wrapContent={wrapContent}\n theme={this.props.theme}\n showBackground={true}\n className={this._classNames.svgTooltip}\n />\n )}\n </g>\n )}\n {children}\n {this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '' && (\n <SVGTooltipText\n content={this.props.yAxisTitle}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? svgDimensions.width - this.margins.right! / 2 + this.titleMargin\n : this.margins.left! / 2 - this.titleMargin,\n textAnchor: 'middle',\n transform: `translate(0,\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisTitle!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n wrapContent={wrapContent}\n theme={this.props.theme}\n showBackground={true}\n className={this._classNames.svgTooltip}\n />\n )}\n {this.props.yAxisAnnotation !== undefined &&\n this.props.yAxisAnnotation !== '' &&\n (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '') && (\n <SVGTooltipText\n content={this.props.yAxisAnnotation}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? this.state.startFromX - this.titleMargin\n : svgDimensions.width - this.margins.right!,\n textAnchor: 'middle',\n transform: `translate(${\n this._isRtl\n ? this.margins.right! / 2 - this.titleMargin\n : this.margins.right! / 2 + this.titleMargin\n },\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisAnnotation!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n wrapContent={wrapContent}\n theme={this.props.theme}\n showBackground={true}\n className={this._classNames.svgTooltip}\n />\n )}\n </svg>\n </FocusZone>\n\n {!this.props.hideLegend && (\n <div ref={(e: HTMLDivElement) => (this.legendContainer = e)} className={this._classNames.legendContainer}>\n {this.props.legendBars}\n </div>\n )}\n {/** The callout is used for narration, so keep it mounted on the DOM */}\n {callout && <React.Suspense fallback={<div>Loading...</div>}>{callout}</React.Suspense>}\n </div>\n );\n }\n\n /**\n * Dedicated function to return the Callout JSX Element , which can further be used to only call this when\n * only the calloutprops and charthover props changes.\n * @param calloutProps\n * @param chartHoverProps\n * @returns\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _generateCallout(calloutProps: any, chartHoverProps: any): JSX.Element {\n return (\n <Callout\n hidden={!(!this.props.hideTooltip && calloutProps!.isCalloutVisible)}\n /** Keep the callout updated with details of focused/hovered chart element */\n shouldUpdateWhenHidden={true}\n {...calloutProps}\n >\n {/** Given custom callout, then it will render */}\n {this.props.customizedCallout && this.props.customizedCallout}\n {/** single x point its corresponding y points of all the bars/lines in chart will render in callout */}\n {!this.props.customizedCallout && this.props.isCalloutForStack && this._multiValueCallout(calloutProps)}\n {/** single x point its corresponding y point of single line/bar in the chart will render in callout */}\n {!this.props.customizedCallout && !this.props.isCalloutForStack && (\n <ChartHoverCard\n XValue={calloutProps.XValue}\n Legend={calloutProps.legend!}\n YValue={calloutProps.YValue!}\n color={calloutProps.color!}\n culture={this.props.culture}\n {...chartHoverProps}\n />\n )}\n </Callout>\n );\n }\n\n // TO DO: Write a common functional component for Multi value callout and divide sub count method\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _multiValueCallout = (calloutProps: any) => {\n const yValueHoverSubCountsExists: boolean = this._yValueHoverSubCountsExists(calloutProps.YValueHover);\n return (\n <div className={this._classNames.calloutContentRoot}>\n <div\n className={this._classNames.calloutDateTimeContainer}\n style={yValueHoverSubCountsExists ? { marginBottom: '11px' } : {}}\n >\n <div\n className={this._classNames.calloutContentX}\n {...getAccessibleDataObject(calloutProps!.xAxisCalloutAccessibilityData, 'text', false)}\n >\n {formatToLocaleString(calloutProps!.hoverXValue, this.props.culture, this.props.useUTC)}\n </div>\n </div>\n <div\n className={this._classNames.calloutInfoContainer}\n style={yValueHoverSubCountsExists ? { display: 'flex' } : {}}\n >\n {calloutProps!.YValueHover &&\n calloutProps!.YValueHover.map((yValue: IYValueHover, index: number, yValues: IYValueHover[]) => {\n const isLast: boolean = index + 1 === yValues.length;\n const { shouldDrawBorderBottom = false } = yValue;\n return (\n <div\n {...getAccessibleDataObject(yValue.callOutAccessibilityData, 'text', false)}\n key={`callout-content-${index}`}\n style={\n yValueHoverSubCountsExists\n ? {\n display: 'inline-block',\n ...(shouldDrawBorderBottom && {\n borderBottom: `1px solid ${this.props.theme!.semanticColors.menuDivider}`,\n paddingBottom: '10px',\n }),\n }\n : {\n ...(shouldDrawBorderBottom && {\n borderBottom: `1px solid ${this.props.theme!.semanticColors.menuDivider}`,\n paddingBottom: '10px',\n }),\n }\n }\n >\n {this._getCalloutContent(yValue, index, yValueHoverSubCountsExists, isLast)}\n </div>\n );\n })}\n {!!calloutProps.descriptionMessage && (\n <div className={this._classNames.descriptionMessage}>{calloutProps.descriptionMessage}</div>\n )}\n </div>\n </div>\n );\n };\n\n private _yValueHoverSubCountsExists(yValueHover?: IYValueHover[]) {\n if (yValueHover) {\n return yValueHover.some(\n (yValue: {\n legend?: string;\n y?: number;\n color?: string;\n yAxisCalloutData?: string | { [id: string]: number };\n }) => yValue.yAxisCalloutData && typeof yValue.yAxisCalloutData !== 'string',\n );\n }\n return false;\n }\n\n private _getCalloutContent(\n xValue: IYValueHover,\n index: number,\n yValueHoverSubCountsExists: boolean,\n isLast: boolean,\n ): React.ReactNode {\n const marginStyle: React.CSSProperties = isLast ? {} : { marginRight: '16px' };\n const toDrawShape = xValue.index !== undefined && xValue.index !== -1;\n const _classNames = getClassNames(this.props.styles!, {\n theme: this.props.theme!,\n width: this.state._width,\n height: this.state._height,\n className: this.props.className,\n isRtl: this._isRtl,\n lineColor: xValue.color,\n toDrawShape,\n });\n\n const { culture, useUTC } = this.props;\n const yValue = formatToLocaleString(xValue.y, culture, useUTC);\n if (!xValue.yAxisCalloutData || typeof xValue.yAxisCalloutData === 'string') {\n return (\n <div style={yValueHoverSubCountsExists ? marginStyle : {}}>\n {yValueHoverSubCountsExists && (\n <div className=\"ms-fontWeight-semibold\" style={{ fontSize: '12pt' }}>\n {xValue.legend!} ({yValue})\n </div>\n )}\n <div id={`${index}_${xValue.y}`} className={_classNames.calloutBlockContainer}>\n {toDrawShape && (\n <Shape\n svgProps={{\n className: _classNames.shapeStyles,\n }}\n pathProps={{ fill: xValue.color }}\n shape={Points[xValue.index! % Object.keys(pointTypes).length] as LegendShape}\n />\n )}\n <div>\n <div className={_classNames.calloutlegendText}> {xValue.legend}</div>\n <div className={_classNames.calloutContentY}>\n {formatToLocaleString(\n xValue.yAxisCalloutData ? xValue.yAxisCalloutData : xValue.y ?? xValue.data,\n culture,\n useUTC,\n )}\n </div>\n </div>\n </div>\n </div>\n );\n } else {\n const subcounts: { [id: string]: number } = xValue.yAxisCalloutData as { [id: string]: number };\n return (\n <div style={marginStyle}>\n <div className=\"ms-fontWeight-semibold\" style={{ fontSize: '12pt' }}>\n {xValue.legend!} ({yValue})\n </div>\n {Object.keys(subcounts).map((subcountName: string) => {\n return (\n <div key={subcountName} className={_classNames.calloutBlockContainer}>\n <div className={_classNames.calloutlegendText}>\n {formatToLocaleString(subcountName, culture, useUTC)}\n </div>\n <div className={_classNames.calloutContentY}>\n {formatToLocaleString(subcounts[subcountName], culture, useUTC)}\n </div>\n </div>\n );\n })}\n </div>\n );\n }\n }\n\n /**\n * When screen resizes, along with screen, chart also auto adjusted.\n * This method used to adjust height and width of the charts.\n */\n private _fitParentContainer(): void {\n const { containerWidth, containerHeight } = this.state;\n this._reqID = requestAnimationFrame(() => {\n let legendContainerHeight;\n if (this.props.hideLegend) {\n // If there is no legend, need not to allocate some space from total chart space.\n legendContainerHeight = 0;\n } else {\n const legendContainerComputedStyles = this.legendContainer && getComputedStyle(this.legendContainer);\n legendContainerHeight =\n ((this.legendContainer && this.legendContainer.getBoundingClientRect().height) ||\n this.minLegendContainerHeight) +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginTop) || '0') +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginBottom) || '0');\n }\n if (this.props.parentRef || this.chartContainer) {\n const container = this.props.parentRef ? this.props.parentRef : this.chartContainer;\n const currentContainerWidth =\n this.props.enableReflow && !this._isFirstRender\n ? Math.max(container.getBoundingClientRect().width, this._calculateChartMinWidth())\n : container.getBoundingClientRect().width;\n const currentContainerHeight =\n container.getBoundingClientRect().height > legendContainerHeight\n ? container.getBoundingClientRect().height\n : 350;\n const shouldResize =\n containerWidth !== currentContainerWidth ||\n containerHeight !== currentContainerHeight - legendContainerHeight;\n if (shouldResize) {\n this.setState({\n containerWidth: currentContainerWidth,\n containerHeight: currentContainerHeight - legendContainerHeight,\n });\n }\n }\n });\n }\n\n // Call back to the chart.\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _getData = (xScale: any, yScalePrimary: any, yScaleSecondary: any) => {\n this.props.getGraphData &&\n this.props.getGraphData(\n xScale,\n yScalePrimary,\n this.state.containerHeight - this.state._removalValueForTextTuncate!,\n this.state.containerWidth,\n this.xAxisElement,\n this.yAxisElement,\n yScaleSecondary,\n );\n };\n\n private _onChartLeave = (): void => {\n this.props.onChartMouseLeave && this.props.onChartMouseLeave();\n };\n\n private _calculateChartMinWidth = (): number => {\n let labelWidth = 10; // Total padding on the left and right sides of the label\n\n // Case: rotated labels\n if (\n !this.props.wrapXAxisLables &&\n this.props.rotateXAxisLables &&\n this.props.xAxisType! === XAxisTypes.StringAxis\n ) {\n const longestLabelWidth = calculateLongestLabelWidth(this._tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth * Math.cos(Math.PI / 4));\n }\n // Case: truncated labels\n else if (this.props.showXAxisLablesTooltip) {\n const tickValues = this._tickValues.map(val => {\n const numChars = this.props.noOfCharsToTruncate || 4;\n return val.toString().length > numChars ? `${val.toString().slice(0, numChars)}...` : val;\n });\n\n const longestLabelWidth = calculateLongestLabelWidth(tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth);\n }\n // Case: wrapped labels\n else if (this.props.wrapXAxisLables) {\n const words: string[] = [];\n this._tickValues.forEach((val: string) => {\n words.push(...val.toString().split(/\\s+/));\n });\n\n const longestLabelWidth = calculateLongestLabelWidth(words, `.${this._classNames.xAxis} text`);\n labelWidth += Math.max(Math.ceil(longestLabelWidth), 10);\n }\n // Default case\n else {\n const longestLabelWidth = calculateLongestLabelWidth(this._tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth);\n }\n\n let minChartWidth = this.margins.left! + this.margins.right! + labelWidth * (this._tickValues.length - 1);\n\n if (\n [ChartTypes.GroupedVerticalBarChart, ChartTypes.VerticalBarChart, ChartTypes.VerticalStackedBarChart].includes(\n this.props.chartType,\n )\n ) {\n const minDomainMargin = 8;\n minChartWidth += minDomainMargin * 2;\n }\n\n return minChartWidth;\n };\n\n private _getChartDescription = (): string => {\n return (\n (this.props.chartTitle || 'Chart. ') +\n this._getAxisTitle('X', this.props.xAxisTitle, this.props.xAxisType) +\n this._getAxisTitle('Y', this.props.yAxisTitle, this.props.yAxisType || YAxisType.NumericAxis) +\n (this.props.secondaryYScaleOptions\n ? this._getAxisTitle('secondary Y', this.props.secondaryYAxistitle, YAxisType.NumericAxis)\n : '')\n );\n };\n\n private _getAxisTitle = (\n axisLabel: string,\n axisTitle: string | undefined,\n axisType: XAxisTypes | YAxisType,\n ): string => {\n return (\n `The ${axisLabel} axis displays ` +\n (axisTitle ||\n (axisType === XAxisTypes.StringAxis || axisType === YAxisType.StringAxis\n ? 'categories'\n : axisType === XAxisTypes.DateAxis || axisType === YAxisType.DateAxis\n ? 'time'\n : 'values')) +\n '. '\n );\n };\n}\n"]}
1
+ {"version":3,"file":"CartesianChart.base.js","sourceRoot":"../src/","sources":["components/CommonComponents/CartesianChart.base.tsx"],"names":[],"mappings":";;;;IAsCA,IAAM,aAAa,GAAG,IAAA,8BAAkB,GAAoD,CAAC;IAC7F,IAAM,cAAc,GAAG,KAAK,CAAC,IAAI,CAAC;QAChC,OAAA,sDAAO,+CAA+C,4BAAE,IAAI,CAAC,UAAA,MAAM,IAAI,OAAA,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,cAAc,EAAE,CAAC,EAApC,CAAoC,CAAC;IAA5G,CAA4G,CAC7G,CAAC;IACF,IAAM,yBAAyB,GAAG;QAChC,kBAAU,CAAC,0BAA0B;QACrC,kBAAU,CAAC,YAAY;QACvB,kBAAU,CAAC,uBAAuB;KACnC,CAAC;IAqBF;;;;;OAKG;IACH;QACU,8CAAmE;QAwB3E,4BAAY,KAAmC;;YAC7C,YAAA,MAAK,YAAC,KAAK,CAAC,SAAC;YAnBP,8BAAwB,GAAW,EAAE,CAAC;YAQtC,YAAM,GAAY,IAAA,kBAAM,GAAE,CAAC;YAG3B,oBAAc,GAAY,IAAI,CAAC;YAI/B,uBAAiB,GAAY,IAAI,CAAC;YAoJnC,kCAA4B,GAAG,UAAC,SAAiB;gBACtD,IAAM,eAAe,GAAG,UAAC,GAAW;oBAClC,IAAI,KAAI,CAAC,KAAK,CAAC,sBAAsB,EAAE,CAAC;wBACtC,OAAO,IAAA,sBAAc,EAAC,GAAG,EAAE,KAAI,CAAC,KAAK,CAAC,mBAAmB,IAAI,CAAC,C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C,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,KAAK,EAAE,KAAI,CAAC,uBAAuB,EAAE,CAAC;wBACnF,CAAC,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,KAAK,CAAC;oBAC9C,IAAM,sBAAsB,GAC1B,SAAS,CAAC,qBAAqB,EAAE,CAAC,MAAM,GAAG,qBAAqB;wBAC9D,CAAC,CAAC,SAAS,CAAC,qBAAqB,EAAE,CAAC,MAAM;wBAC1C,CAAC,CAAC,GAAG,CAAC;oBACV,IAAM,YAAY,GAChB,cAAc,KAAK,qBAAqB;wBACxC,eAAe,KAAK,sBAAsB,GAAG,qBAAqB,CAAC;oBACrE,IAAI,YAAY,EAAE,CAAC;wBACjB,KAAI,CAAC,QAAQ,CAAC;4BACZ,cAAc,EAAE,qBAAqB;4BACrC,eAAe,EAAE,sBAAsB,GAAG,qBAAqB;yBAChE,CAAC,CAAC;oBACL,CAAC;gBACH,CAAC;YACH,CAAC,CAAC,CAAC;QACL,CAAC;QAoGH,yBAAC;IAAD,CAAC,AAj/BD,CACU,KAAK,CAAC,SAAS,GAg/BxB;IAj/BY,gDAAkB","sourcesContent":["import * as React from 'react';\nimport { IProcessedStyleSet } from '@fluentui/react/lib/Styling';\nimport { classNamesFunction, getId, getRTL } from '@fluentui/react/lib/Utilities';\nimport { Callout } from '@fluentui/react/lib/Callout';\nimport { FocusZone, FocusZoneDirection } from '@fluentui/react-focus';\nimport { select as d3Select } from 'd3-selection';\nimport {\n ICartesianChartStyles,\n ICartesianChartStyleProps,\n IModifiedCartesianChartProps,\n IYValueHover,\n} from '../../index';\nimport { formatToLocaleString } from '@fluentui/chart-utilities';\nimport {\n createNumericXAxis,\n createStringXAxis,\n IAxisData,\n getAccessibleDataObject,\n createDateXAxis,\n IMargins,\n XAxisTypes,\n YAxisType,\n createWrapOfXLabels,\n rotateXAxisLabels,\n Points,\n pointTypes,\n calculateLongestLabelWidth,\n createYAxisLabels,\n ChartTypes,\n wrapContent,\n getSecureProps,\n truncateString,\n tooltipOfAxislabels,\n} from '../../utilities/index';\nimport { LegendShape, Shape } from '../Legends/index';\nimport { SVGTooltipText, ISVGTooltipTextProps } from '../../utilities/SVGTooltipText';\nimport { IChart } from '../../types/index';\n\nconst getClassNames = classNamesFunction<ICartesianChartStyleProps, ICartesianChartStyles>();\nconst ChartHoverCard = React.lazy(() =>\n import('../../utilities/ChartHoverCard/ChartHoverCard').then(module => ({ default: module.ChartHoverCard })),\n);\nconst chartTypesWithStringYAxis = [\n ChartTypes.HorizontalBarChartWithAxis,\n ChartTypes.HeatMapChart,\n ChartTypes.VerticalStackedBarChart,\n];\n\nexport interface ICartesianChartState {\n containerWidth: number;\n containerHeight: number;\n _width: number;\n _height: number;\n /* To update this values using setState in render method.\n * To avoid multiple re renders, Only first time setting the value.\n */\n isRemoveValCalculated?: boolean;\n /* Used for when WrapXAxisLabels props appeared.\n * To display the total word (space separated words), Need to have more space than usual.\n * This height will get total height need to disaply total word.\n * These value need to be removed from actual svg height/graph height.\n * Defalut value is 0. And this values calculted when 'wrapXAxisLables' or 'showXAxisLablesTooltip' is true.\n */\n _removalValueForTextTuncate?: number;\n startFromX: number;\n}\n\n/**\n * Cartesian chart used for\n * 1.draw X and Y axis of the chart\n * 2.Callout\n * 3.Fit parent Continer\n */\nexport class CartesianChartBase\n extends React.Component<IModifiedCartesianChartProps, ICartesianChartState>\n implements IChart\n{\n public chartContainer: HTMLDivElement;\n private _classNames: IProcessedStyleSet<ICartesianChartStyles>;\n private legendContainer: HTMLDivElement;\n private minLegendContainerHeight: number = 32;\n private xAxisElement: SVGSVGElement | null;\n private yAxisElement: SVGSVGElement | null;\n private yAxisElementSecondary: SVGSVGElement | null;\n private margins: IMargins;\n private idForGraph: string;\n private idForDefaultTabbableElement: string;\n private _reqID: number;\n private _isRtl: boolean = getRTL();\n private _tickValues: (string | number)[];\n private titleMargin: number;\n private _isFirstRender: boolean = true;\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _xScale: any;\n private isIntegralDataset: boolean = true;\n private _tooltipId: string;\n\n constructor(props: IModifiedCartesianChartProps) {\n super(props);\n this.state = {\n containerHeight: 0,\n containerWidth: 0,\n _width: this.props.width || 600,\n _height: this.props.height || 350,\n _removalValueForTextTuncate: 0,\n isRemoveValCalculated: true,\n startFromX: 0,\n };\n this.idForGraph = getId('chart_');\n this.titleMargin = 8;\n this.idForDefaultTabbableElement = getId('defaultTabbableElement_');\n this._tooltipId = getId('tooltip_');\n /**\n * In RTL mode, Only graph will be rendered left/right. We need to provide left and right margins manually.\n * So that, in RTL, left margins becomes right margins and viceversa.\n * As graph needs to be drawn perfecty, these values consider as default values.\n * Same margins using for all other cartesian charts. Can be accessible through 'getMargins' call back method.\n */\n this.margins = {\n top: this.props.margins?.top ?? 20,\n bottom: this.props.margins?.bottom ?? 35,\n right: this._isRtl\n ? this.props.margins?.left ?? 40\n : this.props.margins?.right ?? this.props?.secondaryYScaleOptions\n ? 40\n : 20,\n left: this._isRtl\n ? this.props.margins?.right ?? this.props?.secondaryYScaleOptions\n ? 40\n : 20\n : this.props.margins?.left ?? 40,\n };\n const TITLE_MARGIN_HORIZONTAL = 24;\n const TITLE_MARGIN_VERTICAL = 20;\n if (this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '') {\n this.margins.bottom! = this.props.margins?.bottom ?? this.margins.bottom! + TITLE_MARGIN_VERTICAL;\n }\n if (this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '') {\n this.margins.left! = this._isRtl\n ? this.props.margins?.right ?? this.props?.secondaryYAxistitle\n ? this.margins.right! + 2 * TITLE_MARGIN_HORIZONTAL\n : this.margins.right! + TITLE_MARGIN_HORIZONTAL\n : this.props.margins?.left ?? this.margins.left! + TITLE_MARGIN_HORIZONTAL;\n this.margins.right! = this._isRtl\n ? this.props.margins?.left ?? this.margins.left! + TITLE_MARGIN_HORIZONTAL\n : this.props.margins?.right ?? this.props?.secondaryYAxistitle\n ? this.margins.right! + 2 * TITLE_MARGIN_HORIZONTAL\n : this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n }\n if (this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '') {\n this.margins.top! = this.props.margins?.top ?? this.margins.top! + TITLE_MARGIN_VERTICAL;\n }\n if (\n this.props.yAxisAnnotation !== undefined &&\n this.props.yAxisAnnotation !== '' &&\n (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '')\n ) {\n if (this._isRtl) {\n this.margins.left! = this.props.margins?.right ?? this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n } else {\n this.margins.right! = this.props.margins?.right ?? this.margins.right! + TITLE_MARGIN_HORIZONTAL;\n }\n }\n }\n\n public componentDidMount(): void {\n this._fitParentContainer();\n if (\n chartTypesWithStringYAxis.includes(this.props.chartType) &&\n this.props.showYAxisLables &&\n this.yAxisElement &&\n this.props.yAxisType === YAxisType.StringAxis\n ) {\n const maxYAxisLabelLength = this.calculateMaxYAxisLabelLength(this._classNames.yAxis!);\n if (this.state.startFromX !== maxYAxisLabelLength) {\n this.setState({\n startFromX: maxYAxisLabelLength,\n });\n }\n } else if (this.state.startFromX !== 0) {\n this.setState({\n startFromX: 0,\n });\n }\n this.isIntegralDataset = !this.props.points.some((point: { y: number }) => {\n return point.y % 1 !== 0;\n });\n }\n\n public componentWillUnmount(): void {\n cancelAnimationFrame(this._reqID);\n }\n\n public componentDidUpdate(prevProps: IModifiedCartesianChartProps): void {\n if (prevProps.height !== this.props.height || prevProps.width !== this.props.width) {\n this._fitParentContainer();\n }\n if (\n !this.props.wrapXAxisLables &&\n this.props.rotateXAxisLables &&\n this.props.xAxisType! === XAxisTypes.StringAxis\n ) {\n const rotateLabelProps = {\n node: this.xAxisElement,\n xAxis: this._xScale,\n };\n const rotatedHeight = rotateXAxisLabels(rotateLabelProps);\n if (\n this.state.isRemoveValCalculated &&\n this.state._removalValueForTextTuncate !== rotatedHeight! + this.margins.bottom! &&\n rotatedHeight! > 0\n ) {\n this.setState({\n _removalValueForTextTuncate: rotatedHeight! + this.margins.bottom!,\n isRemoveValCalculated: false,\n });\n }\n }\n if (\n chartTypesWithStringYAxis.includes(this.props.chartType) &&\n this.props.showYAxisLables &&\n this.yAxisElement &&\n this.props.yAxisType === YAxisType.StringAxis\n ) {\n const maxYAxisLabelLength = this.calculateMaxYAxisLabelLength(this._classNames.yAxis!);\n if (this.state.startFromX !== maxYAxisLabelLength) {\n this.setState({\n startFromX: maxYAxisLabelLength,\n });\n }\n } else if (this.state.startFromX !== 0) {\n this.setState({\n startFromX: 0,\n });\n }\n if (prevProps.points !== this.props.points) {\n this.isIntegralDataset = !this.props.points.some((point: { y: number }) => {\n return point.y % 1 !== 0;\n });\n }\n }\n\n public calculateMaxYAxisLabelLength = (className: string): number => {\n const formatTickLabel = (str: string) => {\n if (this.props.showYAxisLablesTooltip) {\n return truncateString(str, this.props.noOfCharsToTruncate || 4);\n }\n\n return str;\n };\n\n return calculateLongestLabelWidth(\n this.props.stringDatasetForYAxisDomain!.map(label => formatTickLabel(label)),\n `.${className} text`,\n );\n };\n\n public render(): JSX.Element {\n const {\n calloutProps,\n points,\n chartType,\n chartHoverProps,\n svgFocusZoneProps,\n svgProps,\n culture,\n dateLocalizeOptions,\n timeFormatLocale,\n customDateTimeFormatter,\n } = this.props;\n if (this.props.parentRef) {\n this._fitParentContainer();\n }\n\n const margin = { ...this.margins };\n // Note: This check is unnecessary since startFromX is only set for charts with string y-axis.\n if (chartTypesWithStringYAxis.includes(this.props.chartType)) {\n if (!this._isRtl) {\n margin.left! += this.state.startFromX;\n } else {\n margin.right! += this.state.startFromX;\n }\n }\n // Callback for margins to the chart\n this.props.getmargins && this.props.getmargins(margin);\n\n this._classNames = getClassNames(this.props.styles!, {\n theme: this.props.theme!,\n width: this.state._width,\n height: this.state._height,\n className: this.props.className,\n isRtl: this._isRtl,\n enableReflow: this.props.enableReflow,\n });\n\n let callout: JSX.Element | null = null;\n\n let children = null;\n if (\n (this.props.enableFirstRenderOptimization && this.chartContainer) ||\n !this.props.enableFirstRenderOptimization\n ) {\n this._isFirstRender = false;\n const XAxisParams = {\n domainNRangeValues: this.props.getDomainNRangeValues(\n points,\n this.props.getDomainMargins ? this.props.getDomainMargins(this.state.containerWidth) : this.margins,\n this.state.containerWidth,\n chartType,\n this._isRtl,\n this.props.xAxisType,\n this.props.barwidth!,\n this.props.tickValues!,\n // This is only used for Horizontal Bar Chart with Axis for y as string axis\n this.state.startFromX,\n ),\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n margins: this.margins,\n xAxisElement: this.xAxisElement!,\n showRoundOffXTickValues: this.props.showRoundOffXTickValues ?? true,\n xAxisCount: this.props.xAxisTickCount,\n xAxistickSize: this.props.xAxistickSize,\n tickPadding: this.props.tickPadding || this.props.showXAxisLablesTooltip ? 5 : 10,\n xAxisPadding: this.props.xAxisPadding,\n xAxisInnerPadding: this.props.xAxisInnerPadding,\n xAxisOuterPadding: this.props.xAxisOuterPadding,\n containerWidth: this.state.containerWidth,\n hideTickOverlap:\n this.props.hideTickOverlap &&\n !this.props.rotateXAxisLables &&\n !this.props.showXAxisLablesTooltip &&\n !this.props.wrapXAxisLables,\n };\n\n const YAxisParams = {\n margins: this.props.getYDomainMargins ? this.props.getYDomainMargins(this.state.containerHeight) : this.margins,\n containerWidth: this.state.containerWidth,\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n yAxisElement: this.yAxisElement,\n yAxisTickFormat: this.props.yAxisTickFormat!,\n yAxisTickCount: this.props.yAxisTickCount!,\n yMinValue: this.props.yMinValue || 0,\n yMaxValue: this.props.yMaxValue || 0,\n tickPadding: 10,\n maxOfYVal: this.props.maxOfYVal,\n yMinMaxValues: this.props.getMinMaxOfYAxis(points, this.props.yAxisType),\n // please note these padding default values must be consistent in here\n // and the parent chart(HBWA/Vertical etc..) for more details refer example\n // http://using-d3js.com/04_07_ordinal_scales.html\n yAxisPadding: this.props.yAxisPadding || 0,\n };\n /**\n * These scales used for 2 purposes.\n * 1. To create x and y axis\n * 2. To draw the graph.\n * For area/line chart using same scales. For other charts, creating their own scales to draw the graph.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let xScale: any;\n let tickValues: (string | number)[];\n switch (this.props.xAxisType!) {\n case XAxisTypes.NumericAxis:\n ({ xScale, tickValues } = createNumericXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.chartType,\n culture,\n ));\n break;\n case XAxisTypes.DateAxis:\n ({ xScale, tickValues } = createDateXAxis(\n XAxisParams,\n this.props.tickParams!,\n culture,\n dateLocalizeOptions,\n timeFormatLocale,\n customDateTimeFormatter,\n this.props.useUTC,\n ));\n break;\n case XAxisTypes.StringAxis:\n ({ xScale, tickValues } = createStringXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.datasetForXAxisDomain!,\n culture,\n ));\n break;\n default:\n ({ xScale, tickValues } = createNumericXAxis(\n XAxisParams,\n this.props.tickParams!,\n this.props.chartType,\n culture,\n ));\n }\n this._xScale = xScale;\n this._tickValues = tickValues;\n\n /*\n * To enable wrapping of x axis tick values or to display complete x axis tick values,\n * we need to calculate how much space it needed to render the text.\n * No need to re-calculate every time the chart renders and same time need to get an update. So using setState.\n * Required space will be calculated first time chart rendering and if any width/height of chart updated.\n * */\n if (this.props.wrapXAxisLables || this.props.showXAxisLablesTooltip) {\n const wrapLabelProps = {\n node: this.xAxisElement,\n xAxis: xScale,\n showXAxisLablesTooltip: this.props.showXAxisLablesTooltip || false,\n noOfCharsToTruncate: this.props.noOfCharsToTruncate || 4,\n };\n const temp = xScale && (createWrapOfXLabels(wrapLabelProps) as number);\n // this value need to be updated for draw graph updated. So instead of using private value, using set state.\n if (this.state.isRemoveValCalculated && this.state._removalValueForTextTuncate !== temp) {\n this.setState({ _removalValueForTextTuncate: temp, isRemoveValCalculated: false });\n }\n }\n\n /**\n * These scales used for 2 purposes.\n * 1. To create x and y axis\n * 2. To draw the graph.\n * For area/line chart using same scales. For other charts, creating their own scales to draw the graph.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let yScalePrimary: any;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let yScaleSecondary: any;\n const axisData: IAxisData = { yAxisDomainValues: [] };\n if (this.props.yAxisType && this.props.yAxisType === YAxisType.StringAxis) {\n yScalePrimary = this.props.createStringYAxis(\n YAxisParams,\n this.props.stringDatasetForYAxisDomain!,\n this._isRtl,\n this.props.barwidth,\n this.props.chartType,\n );\n } else {\n // TODO: Since the scale domain values are now computed independently for both the primary and\n // secondary y-axes, the yMinValue and yMaxValue props are no longer necessary for accurately\n // rendering the secondary y-axis. Therefore, rather than checking the secondaryYScaleOptions\n // prop to determine whether to create a secondary y-axis, it's more appropriate to check if any\n // data points are assigned to use the secondary y-scale.\n if (this.props?.secondaryYScaleOptions) {\n const YAxisParamsSecondary = {\n margins: this.margins,\n containerWidth: this.state.containerWidth,\n containerHeight: this.state.containerHeight - this.state._removalValueForTextTuncate!,\n yAxisElement: this.yAxisElementSecondary,\n yAxisTickFormat: this.props.yAxisTickFormat!,\n yAxisTickCount: this.props.yAxisTickCount!,\n yMinValue: this.props.secondaryYScaleOptions?.yMinValue || 0,\n yMaxValue: this.props.secondaryYScaleOptions?.yMaxValue ?? 100,\n tickPadding: 10,\n yMinMaxValues: this.props.getMinMaxOfYAxis(points, this.props.yAxisType, true),\n yAxisPadding: this.props.yAxisPadding,\n };\n\n yScaleSecondary = this.props.createYAxis(\n YAxisParamsSecondary,\n this._isRtl,\n axisData,\n this.isIntegralDataset,\n true,\n this.props.supportNegativeData!,\n this.props.roundedTicks!,\n );\n }\n yScalePrimary = this.props.createYAxis(\n YAxisParams,\n this._isRtl,\n axisData,\n this.isIntegralDataset,\n false,\n this.props.supportNegativeData!,\n this.props.roundedTicks!,\n );\n }\n\n if (chartTypesWithStringYAxis.includes(this.props.chartType) && this.props.yAxisType === YAxisType.StringAxis) {\n // To create y axis tick values by if specified truncating the rest of the text\n // and showing elipsis or showing the whole string,\n yScalePrimary &&\n // Note: This function should be invoked within the showYAxisLablesTooltip check,\n // as its sole purpose is to truncate labels that exceed the noOfCharsToTruncate limit.\n createYAxisLabels(\n this.yAxisElement,\n yScalePrimary,\n this.props.noOfCharsToTruncate || 4,\n this.props.showYAxisLablesTooltip || false,\n this._isRtl,\n );\n\n // Removing un wanted tooltip div from DOM, when prop not provided, for proper cleanup\n // of unwanted DOM elements, to prevent flacky behaviour in tooltips , that might occur\n // in creating tooltips when tooltips are enabled( as we try to recreate a tspan with this._tooltipId)\n if (!this.props.showYAxisLablesTooltip) {\n try {\n document.getElementById(this._tooltipId) && document.getElementById(this._tooltipId)!.remove();\n //eslint-disable-next-line no-empty\n } catch (e) {}\n }\n // Used to display tooltip at y axis labels.\n if (this.props.showYAxisLablesTooltip) {\n const yAxisElement = d3Select(this.yAxisElement).call(yScalePrimary);\n try {\n document.getElementById(this._tooltipId) && document.getElementById(this._tooltipId)!.remove();\n //eslint-disable-next-line no-empty\n } catch (e) {}\n const ytooltipProps = {\n tooltipCls: this._classNames.tooltip!,\n id: this._tooltipId,\n axis: yAxisElement,\n };\n yAxisElement && tooltipOfAxislabels(ytooltipProps);\n }\n }\n\n this.props.getAxisData && this.props.getAxisData(axisData);\n // Callback function for chart, returns axis\n this._getData(xScale, yScalePrimary, yScaleSecondary);\n\n children = this.props.children({\n ...this.state,\n xScale,\n yScalePrimary,\n yScaleSecondary,\n });\n\n if (!this.props.hideTooltip && calloutProps!.isCalloutVisible) {\n callout = this._generateCallout(calloutProps, chartHoverProps);\n }\n }\n\n const svgDimensions = {\n width: this.state.containerWidth,\n height: this.state.containerHeight,\n };\n\n let focusDirection;\n if (this.props.focusZoneDirection === FocusZoneDirection.vertical) {\n focusDirection = this.props.focusZoneDirection;\n } else if (this.props.focusZoneDirection) {\n focusDirection = this.props.focusZoneDirection;\n } else {\n focusDirection = FocusZoneDirection.horizontal;\n }\n\n const xAxisTitleMaximumAllowedWidth =\n svgDimensions.width - this.margins.left! - this.margins.right! - this.state.startFromX!;\n const yAxisTitleMaximumAllowedHeight =\n svgDimensions.height -\n this.margins.bottom! -\n this.margins.top! -\n this.state._removalValueForTextTuncate! -\n this.titleMargin;\n\n const commonSvgToolTipProps: ISVGTooltipTextProps = {\n wrapContent,\n theme: this.props.theme,\n showBackground: true,\n className: this._classNames.svgTooltip,\n };\n /**\n * We have use the {@link defaultTabbableElement } to fix\n * the Focus not landing on chart while tabbing, instead goes to legend.\n * This issue is observed in Area, line chart after performance optimization done in the PR {@link https://github.com/microsoft/fluentui/pull/27721 }\n * This issue is observed in Bar charts after the changes done by FocusZone team in the PR: {@link https://github.com/microsoft/fluentui/pull/24175 }\n * The issue in Bar Charts(VB and VSB) is due to a {@link FocusZone } update where previously an event listener was\n * attached on keydown to the window, so that whenever the tab key is pressed all outer FocusZone's\n * tab-indexes are updated (an outer FocusZone is a FocusZone that is not within another one).\n * But now after the above PR : they are attaching the\n * listeners to the FocusZone elements instead of the window. So in the first render cycle in Bar charts\n * bars are not created as in the first render cycle the size of the chart container is not known( or is 0)\n * which creates bars of height 0 so instead we do not create any bars and instead return empty fragments.\n *\n * We have tried 2 Approaches to fix the issue:\n * 1. Using the {@link elementRef} property of FocusZone where we dispatch event for tab keydown\n * after the second render cycle which triggers an update of the tab index in FocusZone.\n * But this is a hacky solution and not a proper fix and also elementRef is deprecated.\n * 2. Using the default tabbable element to fix the issue.\n */\n\n return (\n <div\n id={this.idForGraph}\n className={this._classNames.root}\n ref={(rootElem: HTMLDivElement) => (this.chartContainer = rootElem)}\n onMouseLeave={this._onChartLeave}\n >\n {!this._isFirstRender && <div id={this.idForDefaultTabbableElement} />}\n <FocusZone\n direction={focusDirection}\n className={this._classNames.chartWrapper}\n defaultTabbableElement={`#${this.idForDefaultTabbableElement}`}\n {...svgFocusZoneProps}\n >\n {this._isFirstRender && <div id={this.idForDefaultTabbableElement} />}\n <svg\n width={svgDimensions.width}\n height={svgDimensions.height}\n role=\"region\"\n aria-label={this._getChartDescription()}\n style={{ display: 'block' }}\n {...getSecureProps(svgProps)}\n >\n <g\n ref={(e: SVGSVGElement | null) => {\n this.xAxisElement = e;\n }}\n id={`xAxisGElement${this.idForGraph}`}\n // To add wrap of x axis lables feature, need to remove word height from svg height.\n transform={`translate(0, ${\n svgDimensions.height - this.margins.bottom! - this.state._removalValueForTextTuncate!\n })`}\n className={this._classNames.xAxis}\n />\n {this.props.xAxisTitle !== undefined && this.props.xAxisTitle !== '' && (\n <SVGTooltipText\n content={this.props.xAxisTitle}\n textProps={{\n x: this.margins.left! + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,\n y: svgDimensions.height - this.titleMargin,\n className: this._classNames.axisTitle!,\n textAnchor: 'middle',\n 'aria-hidden': true,\n }}\n maxWidth={xAxisTitleMaximumAllowedWidth}\n {...commonSvgToolTipProps}\n />\n )}\n {this.props.xAxisAnnotation !== undefined && this.props.xAxisAnnotation !== '' && (\n <SVGTooltipText\n content={this.props.xAxisAnnotation}\n textProps={{\n x: this.margins.left! + this.state.startFromX + xAxisTitleMaximumAllowedWidth / 2,\n y: this.titleMargin + 3,\n className: this._classNames.axisAnnotation!,\n textAnchor: 'middle',\n 'aria-hidden': true,\n }}\n maxWidth={xAxisTitleMaximumAllowedWidth}\n {...commonSvgToolTipProps}\n />\n )}\n <g\n ref={(e: SVGSVGElement | null) => {\n this.yAxisElement = e;\n }}\n id={`yAxisGElement${this.idForGraph}`}\n transform={`translate(${\n this._isRtl\n ? svgDimensions.width - this.margins.right! - this.state.startFromX\n : this.margins.left! + this.state.startFromX\n }, 0)`}\n className={this._classNames.yAxis}\n />\n {this.props.secondaryYScaleOptions && (\n <g>\n <g\n ref={(e: SVGSVGElement | null) => {\n this.yAxisElementSecondary = e;\n }}\n id={`yAxisGElementSecondary${this.idForGraph}`}\n transform={`translate(${\n this._isRtl\n ? this.margins.left! + this.state.startFromX\n : svgDimensions.width - this.margins.right! - this.state.startFromX\n }, 0)`}\n className={this._classNames.yAxis}\n />\n {this.props.secondaryYAxistitle !== undefined && this.props.secondaryYAxistitle !== '' && (\n <SVGTooltipText\n content={this.props.secondaryYAxistitle}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? this.state.startFromX - this.titleMargin\n : svgDimensions.width - this.margins.right!,\n textAnchor: 'middle',\n transform: `translate(${\n this._isRtl\n ? this.margins.right! / 2 - this.titleMargin\n : this.margins.right! / 2 + this.titleMargin\n },\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisTitle!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n {...commonSvgToolTipProps}\n />\n )}\n </g>\n )}\n {children}\n {this.props.yAxisTitle !== undefined && this.props.yAxisTitle !== '' && (\n <SVGTooltipText\n content={this.props.yAxisTitle}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? svgDimensions.width - this.margins.right! / 2 + this.titleMargin\n : this.margins.left! / 2 - this.titleMargin,\n textAnchor: 'middle',\n transform: `translate(0,\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisTitle!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n {...commonSvgToolTipProps}\n />\n )}\n {this.props.yAxisAnnotation !== undefined &&\n this.props.yAxisAnnotation !== '' &&\n (this.props.secondaryYAxistitle === undefined || this.props.secondaryYAxistitle === '') && (\n <SVGTooltipText\n content={this.props.yAxisAnnotation}\n textProps={{\n x:\n (yAxisTitleMaximumAllowedHeight - this.margins.bottom!) / 2 +\n this.state._removalValueForTextTuncate!,\n y: this._isRtl\n ? this.state.startFromX - this.titleMargin\n : svgDimensions.width - this.margins.right!,\n textAnchor: 'middle',\n transform: `translate(${\n this._isRtl\n ? this.margins.right! / 2 - this.titleMargin\n : this.margins.right! / 2 + this.titleMargin\n },\n ${svgDimensions.height - this.margins.bottom! - this.margins.top! - this.titleMargin})rotate(-90)`,\n className: this._classNames.axisAnnotation!,\n 'aria-hidden': true,\n }}\n maxWidth={yAxisTitleMaximumAllowedHeight}\n {...commonSvgToolTipProps}\n />\n )}\n </svg>\n </FocusZone>\n\n {!this.props.hideLegend && (\n <div ref={(e: HTMLDivElement) => (this.legendContainer = e)} className={this._classNames.legendContainer}>\n {this.props.legendBars}\n </div>\n )}\n {/** The callout is used for narration, so keep it mounted on the DOM */}\n {callout && <React.Suspense fallback={<div>Loading...</div>}>{callout}</React.Suspense>}\n </div>\n );\n }\n\n /**\n * Dedicated function to return the Callout JSX Element , which can further be used to only call this when\n * only the calloutprops and charthover props changes.\n * @param calloutProps\n * @param chartHoverProps\n * @returns\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _generateCallout(calloutProps: any, chartHoverProps: any): JSX.Element {\n return (\n <Callout\n hidden={!(!this.props.hideTooltip && calloutProps!.isCalloutVisible)}\n /** Keep the callout updated with details of focused/hovered chart element */\n shouldUpdateWhenHidden={true}\n {...calloutProps}\n >\n {/** Given custom callout, then it will render */}\n {this.props.customizedCallout && this.props.customizedCallout}\n {/** single x point its corresponding y points of all the bars/lines in chart will render in callout */}\n {!this.props.customizedCallout && this.props.isCalloutForStack && this._multiValueCallout(calloutProps)}\n {/** single x point its corresponding y point of single line/bar in the chart will render in callout */}\n {!this.props.customizedCallout && !this.props.isCalloutForStack && (\n <ChartHoverCard\n XValue={calloutProps.XValue}\n Legend={calloutProps.legend!}\n YValue={calloutProps.YValue!}\n color={calloutProps.color!}\n culture={this.props.culture}\n {...chartHoverProps}\n />\n )}\n </Callout>\n );\n }\n\n // TO DO: Write a common functional component for Multi value callout and divide sub count method\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _multiValueCallout = (calloutProps: any) => {\n const yValueHoverSubCountsExists: boolean = this._yValueHoverSubCountsExists(calloutProps.YValueHover);\n return (\n <div className={this._classNames.calloutContentRoot}>\n <div\n className={this._classNames.calloutDateTimeContainer}\n style={yValueHoverSubCountsExists ? { marginBottom: '11px' } : {}}\n >\n <div\n className={this._classNames.calloutContentX}\n {...getAccessibleDataObject(calloutProps!.xAxisCalloutAccessibilityData, 'text', false)}\n >\n {formatToLocaleString(calloutProps!.hoverXValue, this.props.culture, this.props.useUTC)}\n </div>\n </div>\n <div\n className={this._classNames.calloutInfoContainer}\n style={yValueHoverSubCountsExists ? { display: 'flex' } : {}}\n >\n {calloutProps!.YValueHover &&\n calloutProps!.YValueHover.map((yValue: IYValueHover, index: number, yValues: IYValueHover[]) => {\n const isLast: boolean = index + 1 === yValues.length;\n const { shouldDrawBorderBottom = false } = yValue;\n return (\n <div\n {...getAccessibleDataObject(yValue.callOutAccessibilityData, 'text', false)}\n key={`callout-content-${index}`}\n style={\n yValueHoverSubCountsExists\n ? {\n display: 'inline-block',\n ...(shouldDrawBorderBottom && {\n borderBottom: `1px solid ${this.props.theme!.semanticColors.menuDivider}`,\n paddingBottom: '10px',\n }),\n }\n : {\n ...(shouldDrawBorderBottom && {\n borderBottom: `1px solid ${this.props.theme!.semanticColors.menuDivider}`,\n paddingBottom: '10px',\n }),\n }\n }\n >\n {this._getCalloutContent(yValue, index, yValueHoverSubCountsExists, isLast)}\n </div>\n );\n })}\n {!!calloutProps.descriptionMessage && (\n <div className={this._classNames.descriptionMessage}>{calloutProps.descriptionMessage}</div>\n )}\n </div>\n </div>\n );\n };\n\n private _yValueHoverSubCountsExists(yValueHover?: IYValueHover[]) {\n if (yValueHover) {\n return yValueHover.some(\n (yValue: {\n legend?: string;\n y?: number;\n color?: string;\n yAxisCalloutData?: string | { [id: string]: number };\n }) => yValue.yAxisCalloutData && typeof yValue.yAxisCalloutData !== 'string',\n );\n }\n return false;\n }\n\n private _getCalloutContent(\n xValue: IYValueHover,\n index: number,\n yValueHoverSubCountsExists: boolean,\n isLast: boolean,\n ): React.ReactNode {\n const marginStyle: React.CSSProperties = isLast ? {} : { marginRight: '16px' };\n const toDrawShape = xValue.index !== undefined && xValue.index !== -1;\n const _classNames = getClassNames(this.props.styles!, {\n theme: this.props.theme!,\n width: this.state._width,\n height: this.state._height,\n className: this.props.className,\n isRtl: this._isRtl,\n lineColor: xValue.color,\n toDrawShape,\n });\n\n const { culture, useUTC } = this.props;\n const yValue = formatToLocaleString(xValue.y, culture, useUTC);\n if (!xValue.yAxisCalloutData || typeof xValue.yAxisCalloutData === 'string') {\n return (\n <div style={yValueHoverSubCountsExists ? marginStyle : {}}>\n {yValueHoverSubCountsExists && (\n <div className=\"ms-fontWeight-semibold\" style={{ fontSize: '12pt' }}>\n {xValue.legend!} ({yValue})\n </div>\n )}\n <div id={`${index}_${xValue.y}`} className={_classNames.calloutBlockContainer}>\n {toDrawShape && (\n <Shape\n svgProps={{\n className: _classNames.shapeStyles,\n }}\n pathProps={{ fill: xValue.color }}\n shape={Points[xValue.index! % Object.keys(pointTypes).length] as LegendShape}\n />\n )}\n <div>\n <div className={_classNames.calloutlegendText}> {xValue.legend}</div>\n <div className={_classNames.calloutContentY}>\n {formatToLocaleString(\n xValue.yAxisCalloutData ? xValue.yAxisCalloutData : xValue.y ?? xValue.data,\n culture,\n useUTC,\n )}\n </div>\n </div>\n </div>\n </div>\n );\n } else {\n const subcounts: { [id: string]: number } = xValue.yAxisCalloutData as { [id: string]: number };\n return (\n <div style={marginStyle}>\n <div className=\"ms-fontWeight-semibold\" style={{ fontSize: '12pt' }}>\n {xValue.legend!} ({yValue})\n </div>\n {Object.keys(subcounts).map((subcountName: string) => {\n return (\n <div key={subcountName} className={_classNames.calloutBlockContainer}>\n <div className={_classNames.calloutlegendText}>\n {formatToLocaleString(subcountName, culture, useUTC)}\n </div>\n <div className={_classNames.calloutContentY}>\n {formatToLocaleString(subcounts[subcountName], culture, useUTC)}\n </div>\n </div>\n );\n })}\n </div>\n );\n }\n }\n\n /**\n * When screen resizes, along with screen, chart also auto adjusted.\n * This method used to adjust height and width of the charts.\n */\n private _fitParentContainer(): void {\n const { containerWidth, containerHeight } = this.state;\n this._reqID = requestAnimationFrame(() => {\n let legendContainerHeight;\n if (this.props.hideLegend) {\n // If there is no legend, need not to allocate some space from total chart space.\n legendContainerHeight = 0;\n } else {\n const legendContainerComputedStyles = this.legendContainer && getComputedStyle(this.legendContainer);\n legendContainerHeight =\n ((this.legendContainer && this.legendContainer.getBoundingClientRect().height) ||\n this.minLegendContainerHeight) +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginTop) || '0') +\n parseFloat((legendContainerComputedStyles && legendContainerComputedStyles.marginBottom) || '0');\n }\n if (this.props.parentRef || this.chartContainer) {\n const container = this.props.parentRef ? this.props.parentRef : this.chartContainer;\n const currentContainerWidth =\n this.props.enableReflow && !this._isFirstRender\n ? Math.max(container.getBoundingClientRect().width, this._calculateChartMinWidth())\n : container.getBoundingClientRect().width;\n const currentContainerHeight =\n container.getBoundingClientRect().height > legendContainerHeight\n ? container.getBoundingClientRect().height\n : 350;\n const shouldResize =\n containerWidth !== currentContainerWidth ||\n containerHeight !== currentContainerHeight - legendContainerHeight;\n if (shouldResize) {\n this.setState({\n containerWidth: currentContainerWidth,\n containerHeight: currentContainerHeight - legendContainerHeight,\n });\n }\n }\n });\n }\n\n // Call back to the chart.\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n private _getData = (xScale: any, yScalePrimary: any, yScaleSecondary: any) => {\n this.props.getGraphData &&\n this.props.getGraphData(\n xScale,\n yScalePrimary,\n this.state.containerHeight - this.state._removalValueForTextTuncate!,\n this.state.containerWidth,\n this.xAxisElement,\n this.yAxisElement,\n yScaleSecondary,\n );\n };\n\n private _onChartLeave = (): void => {\n this.props.onChartMouseLeave && this.props.onChartMouseLeave();\n };\n\n private _calculateChartMinWidth = (): number => {\n let labelWidth = 10; // Total padding on the left and right sides of the label\n\n // Case: rotated labels\n if (\n !this.props.wrapXAxisLables &&\n this.props.rotateXAxisLables &&\n this.props.xAxisType! === XAxisTypes.StringAxis\n ) {\n const longestLabelWidth = calculateLongestLabelWidth(this._tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth * Math.cos(Math.PI / 4));\n }\n // Case: truncated labels\n else if (this.props.showXAxisLablesTooltip) {\n const tickValues = this._tickValues.map(val => {\n const numChars = this.props.noOfCharsToTruncate || 4;\n return val.toString().length > numChars ? `${val.toString().slice(0, numChars)}...` : val;\n });\n\n const longestLabelWidth = calculateLongestLabelWidth(tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth);\n }\n // Case: wrapped labels\n else if (this.props.wrapXAxisLables) {\n const words: string[] = [];\n this._tickValues.forEach((val: string) => {\n words.push(...val.toString().split(/\\s+/));\n });\n\n const longestLabelWidth = calculateLongestLabelWidth(words, `.${this._classNames.xAxis} text`);\n labelWidth += Math.max(Math.ceil(longestLabelWidth), 10);\n }\n // Default case\n else {\n const longestLabelWidth = calculateLongestLabelWidth(this._tickValues, `.${this._classNames.xAxis} text`);\n labelWidth += Math.ceil(longestLabelWidth);\n }\n\n let minChartWidth = this.margins.left! + this.margins.right! + labelWidth * (this._tickValues.length - 1);\n\n if (\n [ChartTypes.GroupedVerticalBarChart, ChartTypes.VerticalBarChart, ChartTypes.VerticalStackedBarChart].includes(\n this.props.chartType,\n )\n ) {\n const minDomainMargin = 8;\n minChartWidth += minDomainMargin * 2;\n }\n\n return minChartWidth;\n };\n\n private _getChartDescription = (): string => {\n return (\n (this.props.chartTitle || 'Chart. ') +\n this._getAxisTitle('X', this.props.xAxisTitle, this.props.xAxisType) +\n this._getAxisTitle('Y', this.props.yAxisTitle, this.props.yAxisType || YAxisType.NumericAxis) +\n (this.props.secondaryYScaleOptions\n ? this._getAxisTitle('secondary Y', this.props.secondaryYAxistitle, YAxisType.NumericAxis)\n : '')\n );\n };\n\n private _getAxisTitle = (\n axisLabel: string,\n axisTitle: string | undefined,\n axisType: XAxisTypes | YAxisType,\n ): string => {\n return (\n `The ${axisLabel} axis displays ` +\n (axisTitle ||\n (axisType === XAxisTypes.StringAxis || axisType === YAxisType.StringAxis\n ? 'categories'\n : axisType === XAxisTypes.DateAxis || axisType === YAxisType.DateAxis\n ? 'time'\n : 'values')) +\n '. '\n );\n };\n}\n"]}