diff --git a/.buildkite/utils/github.ts b/.buildkite/utils/github.ts index 7ee9938d50..e23d5f268f 100644 --- a/.buildkite/utils/github.ts +++ b/.buildkite/utils/github.ts @@ -32,7 +32,7 @@ const auth = JSON.parse(process.env.GITHUB_AUTH); const MyOctokit = Octokit.plugin(retry); export const octokit = new MyOctokit({ authStrategy: createAppAuth, - auth: auth, + auth, }); export const defaultGHOptions = { @@ -237,7 +237,7 @@ export const updateCheckStatus = async ( const output = title && typeof title === 'string' ? { - title: title, + title, summary: title, ...options.output, } diff --git a/.eslintrc.js b/.eslintrc.js index f3bbc7fe2a..f72498b1e8 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -94,9 +94,11 @@ module.exports = { 'react/require-default-props': 0, 'react/display-name': 0, 'react/require-render-return': 0, // rule is broken for certain types of function syntax + 'react/prefer-stateless-function': 0, // annoying rule that could be used in the future 'jsx-a11y/no-static-element-interactions': 1, 'jsx-a11y/mouse-events-have-key-events': 1, 'jsx-a11y/click-events-have-key-events': 1, + 'jsx-a11y/no-static-element-interactions': 0, '@typescript-eslint/member-ordering': 0, eqeqeq: 2, @@ -112,6 +114,7 @@ module.exports = { 'consistent-return': 0, 'no-plusplus': 0, 'no-bitwise': 0, + 'object-shorthand': ['error', 'properties'], 'no-void': [2, { allowAsStatement: true }], yoda: 0, 'no-restricted-globals': 0, diff --git a/e2e/page_objects/common.ts b/e2e/page_objects/common.ts index f773fa5425..a649c9e28d 100644 --- a/e2e/page_objects/common.ts +++ b/e2e/page_objects/common.ts @@ -282,11 +282,12 @@ export class CommonPage { * @param mousePosition * @param selector */ - clickMouseRelativeToDOMElement = (page: Page) => async (mousePosition: MousePosition, selector: string) => { - const element = await this.getBoundingClientRect(page)(selector); - const { x, y } = getCursorPosition(mousePosition, element); - await page.mouse.click(x, y); - }; + clickMouseRelativeToDOMElement = + (page: Page) => async (mousePosition: MousePosition, selector: string, button?: 'left' | 'right' | 'middle') => { + const element = await this.getBoundingClientRect(page)(selector); + const { x, y } = getCursorPosition(mousePosition, element); + await page.mouse.click(x, y, { button }); + }; /** * Drag mouse relative to element @@ -435,6 +436,33 @@ export class CommonPage { }); }; + /** + * Expect a chart given a url from storybook with mouse click + * + * TODO - Find why this always creates a 2px diff + * + * @param url Storybook url from knobs section + * @param mousePosition - position of mouse relative to chart + * @param options + */ + expectChartWithClickAtUrlToMatchScreenshot = + (page: Page) => + async ( + url: string, + mousePosition: MousePosition, + button?: 'left' | 'right' | 'middle', + options?: ScreenshotElementAtUrlOptions, + ) => { + const action = async () => { + await options?.action?.(); + await this.clickMouseRelativeToDOMElement(page)(mousePosition, this.chartSelector, button); + }; + await this.expectChartAtUrlToMatchScreenshot(page)(url, { + ...options, + action, + }); + }; + /** * Expect a chart given a url from storybook with keyboard events * @param url diff --git a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/hover-state/should-fade-all-other-annotations-when-line-marker-is-hovered-chrome-linux.png b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/hover-state/should-fade-all-other-annotations-when-line-marker-is-hovered-chrome-linux.png index 234e300313..7884357ba6 100644 Binary files a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/hover-state/should-fade-all-other-annotations-when-line-marker-is-hovered-chrome-linux.png and b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/hover-state/should-fade-all-other-annotations-when-line-marker-is-hovered-chrome-linux.png differ diff --git a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-x-domain-chrome-linux.png b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-x-domain-chrome-linux.png index fde5c0262d..972c6962db 100644 Binary files a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-x-domain-chrome-linux.png and b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-x-domain-chrome-linux.png differ diff --git a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-y-domain-chrome-linux.png b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-y-domain-chrome-linux.png index 686599096a..9cd08f63a8 100644 Binary files a/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-y-domain-chrome-linux.png and b/e2e/screenshots/annotations_stories.test.ts-snapshots/annotations-stories/outside-annotations/should-show-tooltip-on-hover-y-domain-chrome-linux.png differ diff --git a/e2e/screenshots/bar_stories.test.ts-snapshots/bar-series-stories/functional-accessors/functional-accessors-with-field-name-with-tooltip-chrome-linux.png b/e2e/screenshots/bar_stories.test.ts-snapshots/bar-series-stories/functional-accessors/functional-accessors-with-field-name-with-tooltip-chrome-linux.png index 2b194132ea..295b4ca84c 100644 Binary files a/e2e/screenshots/bar_stories.test.ts-snapshots/bar-series-stories/functional-accessors/functional-accessors-with-field-name-with-tooltip-chrome-linux.png and b/e2e/screenshots/bar_stories.test.ts-snapshots/bar-series-stories/functional-accessors/functional-accessors-with-field-name-with-tooltip-chrome-linux.png differ diff --git a/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/sagitta-offset/should-show-custom-value-formatter-in-tooltip-chrome-linux.png b/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/sagitta-offset/should-show-custom-value-formatter-in-tooltip-chrome-linux.png index e603710493..ea63ae73b0 100644 Binary files a/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/sagitta-offset/should-show-custom-value-formatter-in-tooltip-chrome-linux.png and b/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/sagitta-offset/should-show-custom-value-formatter-in-tooltip-chrome-linux.png differ diff --git a/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/should-render-actual-tooltip-color-on-hover-chrome-linux.png b/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/should-render-actual-tooltip-color-on-hover-chrome-linux.png index 9c53c20ad6..d29b54796e 100644 Binary files a/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/should-render-actual-tooltip-color-on-hover-chrome-linux.png and b/e2e/screenshots/goal_stories.test.ts-snapshots/goal-stories/should-render-actual-tooltip-color-on-hover-chrome-linux.png differ diff --git a/e2e/screenshots/grid_stories.test.ts-snapshots/grid-stories/should-render-crosshair-lines-above-grid-lines-chrome-linux.png b/e2e/screenshots/grid_stories.test.ts-snapshots/grid-stories/should-render-crosshair-lines-above-grid-lines-chrome-linux.png index 18b7b79e4d..e3f5e620f6 100644 Binary files a/e2e/screenshots/grid_stories.test.ts-snapshots/grid-stories/should-render-crosshair-lines-above-grid-lines-chrome-linux.png and b/e2e/screenshots/grid_stories.test.ts-snapshots/grid-stories/should-render-crosshair-lines-above-grid-lines-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-90-degree-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-90-degree-chrome-linux.png index 45b625da3d..3d19d01f77 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-90-degree-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-90-degree-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-chrome-linux.png index 1e9eaa2ead..6cd6dff8ca 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-rectangular-brush-selection-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-90-degree-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-90-degree-chrome-linux.png index 2263ab29e4..6ddfb8d36f 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-90-degree-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-90-degree-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-chrome-linux.png index 8d578cedaa..cf4a936bfb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-x-brush-selection-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-90-degree-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-90-degree-chrome-linux.png index a9b9c9c807..b9871fb300 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-90-degree-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-90-degree-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-chrome-linux.png index e632e3ecde..b2d7f19eca 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/brushing/show-y-brush-selection-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/hide-null-bars-in-tooltip-in-percentage-mode-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/hide-null-bars-in-tooltip-in-percentage-mode-chrome-linux.png index 64ac4726cf..aed49a89f8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/hide-null-bars-in-tooltip-in-percentage-mode-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/hide-null-bars-in-tooltip-in-percentage-mode-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-dark-theme-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-dark-theme-chrome-linux.png index 2733e473c1..f1186140d4 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-dark-theme-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-dark-theme-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-light-theme-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-light-theme-chrome-linux.png index 56ff9b0c18..dabb63db7d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-light-theme-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-band-when-background-is-set-with-eui-light-theme-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-dark-theme-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-dark-theme-chrome-linux.png index 7dbe71336f..b154e97172 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-dark-theme-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-dark-theme-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-light-theme-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-light-theme-chrome-linux.png index fa6d3a6a96..2aab3ba6ed 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-light-theme-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/mouse-cursor/should-show-cursor-when-background-is-set-with-eui-light-theme-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/hide-tooltip-if-configured-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/hide-tooltip-if-configured-chrome-linux.png index 3d9191e148..2e1be9d1ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/hide-tooltip-if-configured-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/hide-tooltip-if-configured-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-areas-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-areas-chrome-linux.png index de99da9fab..18c981c55a 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-areas-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-areas-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-bars-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-bars-chrome-linux.png index 9c7ea32c23..4abc560e11 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-bars-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-show-null-values-in-tooltip-if-configured/show-n-a-tooltip-for-bars-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-size-legends-with-ordinal-x-axis-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-size-legends-with-ordinal-x-axis-chrome-linux.png index d490416528..998441b89d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-size-legends-with-ordinal-x-axis-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/should-size-legends-with-ordinal-x-axis-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-all-custom-tick-formatters-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-all-custom-tick-formatters-chrome-linux.png index 358395cba3..ca7d331bf3 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-all-custom-tick-formatters-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-all-custom-tick-formatters-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-axis-tick-formatter-with-no-header-formatter-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-axis-tick-formatter-with-no-header-formatter-chrome-linux.png index 4bda95bca7..625b9a26b8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-axis-tick-formatter-with-no-header-formatter-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-axis-tick-formatter-with-no-header-formatter-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-custom-mark-formatters-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-custom-mark-formatters-chrome-linux.png index 4300cd249a..ff2f1f64cb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-custom-mark-formatters-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-custom-mark-formatters-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-header-formatter-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-header-formatter-chrome-linux.png index e1a6c1b13f..793e77529f 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-header-formatter-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-header-formatter-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-series-tick-formatter-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-series-tick-formatter-chrome-linux.png index e2d2adf383..31112c9d71 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-series-tick-formatter-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-default-tick-formatter-with-no-axis-tick-formatter-nor-series-tick-formatter-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-header-formatter-for-x-axis-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-header-formatter-for-x-axis-chrome-linux.png index 358395cba3..ca7d331bf3 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-header-formatter-for-x-axis-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-header-formatter-for-x-axis-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-chrome-linux.png index d801870053..657b6aa074 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-missing-series-tick-formatter-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-missing-series-tick-formatter-chrome-linux.png index 38d76010d3..69265f85c4 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-missing-series-tick-formatter-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-formatting/should-use-series-tick-formatter-with-no-axis-tick-formatter-missing-series-tick-formatter-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-crosshairs-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-crosshairs-chrome-linux.png index 34f0f11a7b..b6a4ef50d3 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-crosshairs-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-crosshairs-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-extra-values-in-legend-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-extra-values-in-legend-chrome-linux.png index 91c5698dec..e7c45c4e44 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-extra-values-in-legend-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-extra-values-in-legend-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-tooltips-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-tooltips-chrome-linux.png index 78dfc72a80..7dcc090176 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-tooltips-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltip-sync/show-synced-tooltips-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-bottom-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-bottom-chrome-linux.png index a439b7bfb8..4e4ecb143f 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-bottom-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-bottom-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-top-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-top-chrome-linux.png index 6fb49c63ca..cca1920a99 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-top-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/boundary-chart/should-contain-tooltip-inside-boundary-near-top-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png index 129f14dc5d..458ec41c44 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-top-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-top-chrome-linux.png index 7c45ccaa4d..286af38f22 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-top-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-first-bar-group-top-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png index 129f14dc5d..458ec41c44 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-top-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-top-chrome-linux.png index f7b846d8f0..ce0191f84f 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-top-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-0/shows-tooltip-on-last-bar-group-top-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png index 62b5c9b59b..09ed1e0033 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-bottom-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-top-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-top-chrome-linux.png index 910d8f3304..f325a614c5 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-top-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-first-bar-group-top-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png index af74df72f5..9e86314f48 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-bottom-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-top-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-top-chrome-linux.png index 910d8f3304..f325a614c5 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-top-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/hover-over-specific-bars/rotation-90/shows-tooltip-on-last-bar-group-top-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 12a62b6d96..2f27170462 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 5fc4a734ee..30423235d7 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 7f64352a77..fe89f2d5dd 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 52babf141e..3103bf9687 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-chart/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 139b620e92..74d1338c2e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b6675fc8d3..4073b8f656 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 4114dc6743..724543f1a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index f9f4a6d5b9..05694e3f4a 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index a670765c72..1318eab80e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 336d4db037..815ac57e1d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 91d496d2e5..3edfe7053b 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 4fe40394d9..7f643b8222 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-0/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 139b620e92..74d1338c2e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b6675fc8d3..4073b8f656 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 4114dc6743..724543f1a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index f9f4a6d5b9..05694e3f4a 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index a670765c72..1318eab80e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 336d4db037..815ac57e1d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 91d496d2e5..3edfe7053b 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 4fe40394d9..7f643b8222 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-180/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 139b620e92..74d1338c2e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b6675fc8d3..4073b8f656 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 4114dc6743..724543f1a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index f9f4a6d5b9..05694e3f4a 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index a670765c72..1318eab80e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 336d4db037..815ac57e1d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 91d496d2e5..3edfe7053b 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 4fe40394d9..7f643b8222 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png index dff6758d89..c355001061 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png index ba702514cf..fc55c0999e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-bottom/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 139b620e92..74d1338c2e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b6675fc8d3..4073b8f656 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png index 4114dc6743..724543f1a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png index f9f4a6d5b9..05694e3f4a 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-left/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png index f3454dab1d..6bc55461a8 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png index b79e0c66af..dff29a66ea 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png index a670765c72..1318eab80e 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png index 336d4db037..815ac57e1d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-right/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png index 2927e0e641..f32e8ab9fb 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png index 86535f7469..c6bb8b45ad 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-bottom-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png index 91d496d2e5..3edfe7053b 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-left-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png index 4fe40394d9..7f643b8222 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/positioning/boundary-el-default/rotation-negative-90/placement-top/shows-tooltip-in-top-right-corner-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-for-split-and-y-accessors-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-for-split-and-y-accessors-chrome-linux.png index b40e817b2e..cfa1c6a370 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-for-split-and-y-accessors-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-for-split-and-y-accessors-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-in-dark-theme-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-in-dark-theme-chrome-linux.png index b99e470de8..737dc56d63 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-in-dark-theme-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-current-tooltip-in-dark-theme-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-custom-tooltip-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-custom-tooltip-chrome-linux.png index 5ea857bde9..676480945d 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-custom-tooltip-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-render-custom-tooltip-chrome-linux.png differ diff --git a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-show-tooltip-on-sunburst-chrome-linux.png b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-show-tooltip-on-sunburst-chrome-linux.png index eb570a6752..355e6a50b1 100644 Binary files a/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-show-tooltip-on-sunburst-chrome-linux.png and b/e2e/screenshots/interactions.test.ts-snapshots/interactions/tooltips/should-show-tooltip-on-sunburst-chrome-linux.png differ diff --git a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/should-break-multiline-legends-with-long-url-characters-chrome-linux.png b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/should-break-multiline-legends-with-long-url-characters-chrome-linux.png index b23aae7182..27e3c66ae0 100644 Binary files a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/should-break-multiline-legends-with-long-url-characters-chrome-linux.png and b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/should-break-multiline-legends-with-long-url-characters-chrome-linux.png differ diff --git a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-bottom-legend-chrome-linux.png b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-bottom-legend-chrome-linux.png index 6e2f40b266..f8e1bd42cb 100644 Binary files a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-bottom-legend-chrome-linux.png and b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-bottom-legend-chrome-linux.png differ diff --git a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-left-legend-chrome-linux.png b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-left-legend-chrome-linux.png index 71c74d2dff..d45563244d 100644 Binary files a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-left-legend-chrome-linux.png and b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-left-legend-chrome-linux.png differ diff --git a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-right-legend-chrome-linux.png b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-right-legend-chrome-linux.png index cfede315f1..e689cb1282 100644 Binary files a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-right-legend-chrome-linux.png and b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-right-legend-chrome-linux.png differ diff --git a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-top-legend-chrome-linux.png b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-top-legend-chrome-linux.png index 958b0abff7..e1be31d77a 100644 Binary files a/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-top-legend-chrome-linux.png and b/e2e/screenshots/legend_stories.test.ts-snapshots/legend-stories/tooltip-placement-with-legend/should-render-tooltip-with-top-legend-chrome-linux.png differ diff --git a/e2e/screenshots/line_stories.test.ts-snapshots/line-series-stories/line-with-mark-accessor/with-hidden-points-default-point-highlighter-size-chrome-linux.png b/e2e/screenshots/line_stories.test.ts-snapshots/line-series-stories/line-with-mark-accessor/with-hidden-points-default-point-highlighter-size-chrome-linux.png index ed937ce462..059a584578 100644 Binary files a/e2e/screenshots/line_stories.test.ts-snapshots/line-series-stories/line-with-mark-accessor/with-hidden-points-default-point-highlighter-size-chrome-linux.png and b/e2e/screenshots/line_stories.test.ts-snapshots/line-series-stories/line-with-mark-accessor/with-hidden-points-default-point-highlighter-size-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index a6e566c8b2..e4e8cf5825 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 40d8ff0eb1..843161e103 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 1773c3ba6a..5a073a1a06 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 5be49e696b..b08ec21a90 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 1773c3ba6a..5a073a1a06 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 5be49e696b..b08ec21a90 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-percentage/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 5347095f23..0cc3b8ad05 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index a32e57c95f..db01227ce9 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 34e4a63171..5a11f59412 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 5ea49ad429..bbfcf2e968 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index d8a463162c..bb9ece5b1d 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index a130da6905..8ed309bb0d 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-silhouette/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 979cc31ff6..73c28f5c75 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 677c0e1c85..29541694ac 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-mixed/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 6653cca207..eaae53e480 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index c80efb9191..6da21e68f0 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-negative/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index e8e4d3f947..ca50eb76c1 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/area-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png index 0c007efb6b..d52b941ed9 100644 Binary files a/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png and b/e2e/screenshots/mixed_stories.test.ts-snapshots/mixed-series-stories/stack-mode-wiggle/polarity-positive/bar-series/should-show-area-chart-with-toggled-series-and-mouse-over-chrome-linux.png differ diff --git a/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-america-new-york/use-default-local-timezone-america-new-york-chrome-linux.png b/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-america-new-york/use-default-local-timezone-america-new-york-chrome-linux.png index b8c4df6ebd..8ced380582 100644 Binary files a/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-america-new-york/use-default-local-timezone-america-new-york-chrome-linux.png and b/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-america-new-york/use-default-local-timezone-america-new-york-chrome-linux.png differ diff --git a/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-europe-rome/use-default-local-timezone-europe-rome-chrome-linux.png b/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-europe-rome/use-default-local-timezone-europe-rome-chrome-linux.png index d7340caeaa..fe72ea4ee8 100644 Binary files a/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-europe-rome/use-default-local-timezone-europe-rome-chrome-linux.png and b/e2e/screenshots/timezone.test.ts-snapshots/time-zone/timezone-europe-rome/use-default-local-timezone-europe-rome-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-over-selection-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-over-selection-chrome-linux.png new file mode 100644 index 0000000000..a1e88072c2 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-over-selection-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-without-selection-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-without-selection-chrome-linux.png new file mode 100644 index 0000000000..d6411daea9 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/pinning-without-selection-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-async-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-async-chrome-linux.png new file mode 100644 index 0000000000..334d8cd622 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-async-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-chrome-linux.png new file mode 100644 index 0000000000..1cbcc990b2 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/selecting-series-on-pinned-tooltip-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/show-loading-prompt-for-async-actions-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/show-loading-prompt-for-async-actions-chrome-linux.png new file mode 100644 index 0000000000..ad7a2a5251 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/cartesian/show-loading-prompt-for-async-actions-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/flamegraph/pinning-with-selection-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/flamegraph/pinning-with-selection-chrome-linux.png new file mode 100644 index 0000000000..4702a6de58 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/flamegraph/pinning-with-selection-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/heatmap/pinning-with-selection-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/heatmap/pinning-with-selection-chrome-linux.png new file mode 100644 index 0000000000..bfce55deba Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/heatmap/pinning-with-selection-chrome-linux.png differ diff --git a/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/partition/pinning-with-selection-chrome-linux.png b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/partition/pinning-with-selection-chrome-linux.png new file mode 100644 index 0000000000..0d17fe9376 Binary files /dev/null and b/e2e/screenshots/tooltip.test.ts-snapshots/tooltip/chart-types/partition/pinning-with-selection-chrome-linux.png differ diff --git a/e2e/tests/tooltip.test.ts b/e2e/tests/tooltip.test.ts new file mode 100644 index 0000000000..75f34dbf5b --- /dev/null +++ b/e2e/tests/tooltip.test.ts @@ -0,0 +1,105 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { test } from '@playwright/test'; + +import { common } from '../page_objects/common'; + +process.env.ENV_URL = 'http://localhost:9002/'; + +test.describe('Tooltip', () => { + test.describe('Chart Types', () => { + test.describe('Cartesian', () => { + test('pinning without selection', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--cartesian-charts&globals=theme:light&knob-Chart%20type=treemap&knob-SeriesType=bar&knob-async%20delay%20(ms)=1500&knob-character%20set=rtl&knob-data%20polarity=Mixed&knob-pinned=true&knob-rtl%20language=AR&knob-show%20legend=true&knob-stacked=true&knob-visible=true', + { left: 240, bottom: 260 }, + 'right', + ); + }); + + test('pinning over selection', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--cartesian-charts&globals=theme:light&knob-Chart type=treemap&knob-SeriesType=bar&knob-async delay=1000&knob-async delay (ms)=1500&knob-character set=rtl&knob-chart type=line&knob-data polarity=Mixed&knob-pinned=true&knob-rtl language=AR&knob-show legend=true&knob-stacked=true&knob-visible=true&knob-reduce data=true&knob-async actions delay=0', + { left: 220, bottom: 285 }, + 'right', + ); + }); + + test('show loading prompt for async actions', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--cartesian-charts&globals=theme:light&knob-Chart type=treemap&knob-SeriesType=bar&knob-async delay=1000&knob-async delay (ms)=1500&knob-character set=rtl&knob-chart type=line&knob-data polarity=Mixed&knob-pinned=true&knob-rtl language=AR&knob-show legend=true&knob-stacked=true&knob-visible=true&knob-reduce data=true&knob-async actions delay=1000', + { left: 220, bottom: 285 }, + 'right', + ); + }); + + test('selecting series on pinned tooltip', async ({ page }) => { + await common.expectChartAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--cartesian-charts&globals=theme:light&knob-Chart type=treemap&knob-SeriesType=bar&knob-async delay=1000&knob-async delay (ms)=1500&knob-character set=rtl&knob-chart type=bar&knob-data polarity=Mixed&knob-pinned=true&knob-rtl language=AR&knob-show legend=true&knob-stacked=true&knob-visible=true&knob-reduce data=true&knob-async actions delay=0', + { + action: async () => { + await common.clickMouseRelativeToDOMElement(page)({ left: 260, top: 180 }, common.chartSelector, 'right'); + // table row not visible thus not clickable by playwright + const items = page.locator('.echTooltip__tableRow .echTooltip__tableCell:first-of-type'); + await items.nth(5).click(); + await items.nth(0).click(); + await items.nth(2).click(); + }, + }, + ); + }); + + test('selecting series on pinned tooltip async', async ({ page }) => { + const delay = 100; + await common.expectChartAtUrlToMatchScreenshot(page)( + `http://localhost:9001/?path=/story/components-tooltip--cartesian-charts&globals=theme:light&knob-Chart type=treemap&knob-SeriesType=bar&knob-async delay=1000&knob-async delay (ms)=1500&knob-character set=rtl&knob-chart type=bar&knob-data polarity=Mixed&knob-pinned=true&knob-rtl language=AR&knob-show legend=true&knob-stacked=true&knob-visible=true&knob-reduce data=true&knob-async actions delay=${delay}`, + { + action: async () => { + await common.clickMouseRelativeToDOMElement(page)({ left: 260, top: 180 }, common.chartSelector, 'right'); + // table row not visible thus not clickable by playwright + const items = page.locator('.echTooltip__tableRow .echTooltip__tableCell:first-of-type'); + await items.nth(2).click(); + }, + delay, + }, + ); + }); + }); + + test.describe('Partition', () => { + test('pinning with selection', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--partition-charts&globals=background:white;theme:light&knob-Chart%20type=treemap&knob-SeriesType=bar&knob-async%20delay%20(ms)=1500&knob-character%20set=rtl&knob-data%20polarity=Mixed&knob-pinned=true&knob-rtl%20language=AR&knob-show%20legend=true&knob-stacked=true&knob-visible=true', + { left: 245, bottom: 185 }, + 'right', + ); + }); + }); + + test.describe('Heatmap', () => { + test('pinning with selection', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--heatmap-chart&globals=theme:light&knob-Chart%20type=treemap&knob-SeriesType=bar&knob-async%20delay%20(ms)=1500&knob-character%20set=rtl&knob-data%20polarity=Mixed&knob-pinned=true&knob-rtl%20language=AR&knob-show%20legend=true&knob-stacked=true&knob-visible=true', + { left: 300, bottom: 180 }, + 'right', + ); + }); + }); + + test.describe('Flamegraph', () => { + test('pinning with selection', async ({ page }) => { + await common.expectChartWithClickAtUrlToMatchScreenshot(page)( + 'http://localhost:9001/?path=/story/components-tooltip--flamegraph&globals=theme:light&knob-Chart%20type=treemap&knob-SeriesType=bar&knob-async%20delay%20(ms)=1500&knob-character%20set=rtl&knob-data%20polarity=Mixed&knob-pinned=true&knob-rtl%20language=AR&knob-show%20legend=true&knob-stacked=true&knob-visible=true', + { left: 220, bottom: 220 }, + 'right', + ); + }); + }); + }); +}); diff --git a/packages/charts/api/charts.api.md b/packages/charts/api/charts.api.md index 4d76c387a7..616bda5937 100644 --- a/packages/charts/api/charts.api.md +++ b/packages/charts/api/charts.api.md @@ -229,7 +229,7 @@ export interface ArrayNode extends NodeDescriptor { } // @public -export const Axis: FC>; +export const Axis: FC>; // @public (undocumented) export type AxisId = string; @@ -560,8 +560,9 @@ export interface ColorConfig { } // @public (undocumented) -export type ColorStripCellProps = Omit & { +export type ColorStripCellProps = Omit & { color?: string; + displayOnly?: boolean; }; // @public @@ -648,12 +649,15 @@ export type CustomTooltip extends TooltipInfo { - // (undocumented) backgroundColor: string; // (undocumented) dir: 'ltr' | 'rtl'; // (undocumented) headerFormatter?: TooltipValueFormatter; + pinned: boolean; + selected: TooltipValue[]; + setSelection: (items: TooltipValue[]) => void; + toggleSelected: (item: TooltipValue) => void; } // @public (undocumented) @@ -1262,7 +1266,7 @@ export type GroupId = string; export type GroupKeysOrKeyFn = Array | GroupByKeyFn; // @alpha -export const Heatmap: (props: SFProps, "chartType" | "specType", "data" | "timeZone" | "valueAccessor" | "valueFormatter" | "xAccessor" | "yAccessor" | "xSortPredicate" | "ySortPredicate" | "xScale" | "xAxisTitle" | "yAxisTitle" | "xAxisLabelFormatter" | "yAxisLabelFormatter" | "xAxisLabelName" | "yAxisLabelName", "name" | "onBrushEnd" | "highlightedData", "id" | "colorScale">) => null; +export const Heatmap: (props: SFProps, "chartType" | "specType", "data" | "timeZone" | "valueAccessor" | "xAccessor" | "yAccessor" | "valueFormatter" | "xScale" | "xSortPredicate" | "ySortPredicate" | "xAxisTitle" | "yAxisTitle" | "xAxisLabelFormatter" | "yAxisLabelFormatter" | "xAxisLabelName" | "yAxisLabelName", "name" | "onBrushEnd" | "highlightedData", "id" | "colorScale">) => null; // @alpha (undocumented) export interface HeatmapBandsColorScale { @@ -1896,7 +1900,7 @@ export type PartialTheme = RecursivePartial; // Warning: (ae-forgotten-export) The symbol "PartitionSpec" needs to be exported by the entry point index.d.ts // // @public -export const Partition: (props: SFProps, "chartType" | "specType", "animation" | "layout" | "valueAccessor" | "valueFormatter" | "valueGetter" | "clockwiseSectors" | "specialFirstInnermostSector" | "drilldown" | "maxRowCount" | "fillOutside" | "radiusOutside" | "fillRectangleWidth" | "fillRectangleHeight" | "percentFormatter" | "topGroove" | "smallMultiples" | "layers", never, "data" | "id">) => null; +export const Partition: (props: SFProps, "chartType" | "specType", "animation" | "layout" | "valueAccessor" | "smallMultiples" | "valueFormatter" | "valueGetter" | "clockwiseSectors" | "specialFirstInnermostSector" | "drilldown" | "maxRowCount" | "fillOutside" | "radiusOutside" | "fillRectangleWidth" | "fillRectangleHeight" | "percentFormatter" | "topGroove" | "layers", never, "data" | "id">) => null; // Warning: (ae-forgotten-export) The symbol "StaticConfig" needs to be exported by the entry point index.d.ts // @@ -2011,6 +2015,9 @@ export interface PerSideDistance { top: number; } +// @public (undocumented) +export type PinTooltipCallback = (pinned: boolean, resetPointer?: boolean) => any; + // @public (undocumented) export type Pixels = number; @@ -2417,13 +2424,16 @@ export const SeriesType: Readonly<{ // @public export type SeriesType = $Values; +// @public (undocumented) +export type SetSelectedTooltipItemsCallback = (items: TooltipValue[]) => any; + // @public export const Settings: (props: SFProps) => null; // Warning: (ae-forgotten-export) The symbol "BuildProps" needs to be exported by the entry point index.d.ts // // @public (undocumented) -export const settingsBuildProps: BuildProps; +export const settingsBuildProps: BuildProps; // @public (undocumented) export type SettingsProps = ComponentProps; @@ -2712,13 +2722,13 @@ export interface Theme { legend: LegendStyle; lineSeriesStyle: LineSeriesStyle; markSizeRatio?: number; - // (undocumented) metric: MetricStyle; partition: PartitionStyle; // (undocumented) scales: ScalesConfig; // (undocumented) sharedStyle: SharedGeometryStateStyle; + tooltip: TooltipStyle; } // @public (undocumented) @@ -2777,11 +2787,22 @@ export interface TimeslipSpec extends Spec { // @public export function toEntries, S>(array: T[], accessor: keyof T, staticValue: S): Record; +// @public (undocumented) +export type ToggleSelectedTooltipItemCallback = (item: TooltipValue) => any; + // @public -export const Tooltip: (props: SFProps, "id" | "chartType" | "specType", "type" | "snap" | "showNullValues", "footer" | "header" | "offset" | "fallbackPlacements" | "placement" | "boundary" | "boundaryPadding" | "headerFormatter" | "unit" | "customTooltip" | "stickTo", never>) => null; +export const Tooltip: (props: SFProps, "id" | "chartType" | "specType", "type" | "actions" | "selectionPrompt" | "actionsLoading" | "noActionsLoaded" | "snap" | "showNullValues" | "actionPrompt" | "pinningPrompt" | "maxTooltipItems" | "maxVisibleTooltipItems", "footer" | "header" | "offset" | "fallbackPlacements" | "placement" | "boundary" | "boundaryPadding" | "headerFormatter" | "unit" | "customTooltip" | "stickTo", never>) => null; // @public -export const tooltipBuildProps: BuildProps, "id" | "chartType" | "specType", "type" | "snap" | "showNullValues", "footer" | "header" | "offset" | "fallbackPlacements" | "placement" | "boundary" | "boundaryPadding" | "headerFormatter" | "unit" | "customTooltip" | "stickTo", never>; +export type TooltipAction = { + label: string | ((selected: TooltipValue[], allItems: TooltipValue[]) => ReactNode); + hide?: (selected: TooltipValue[], allItems: TooltipValue[]) => boolean; + disabled?: (selected: TooltipValue[], allItems: TooltipValue[]) => boolean | string; + onSelect: (selected: TooltipValue[], allItems: TooltipValue[]) => void; +}; + +// @public +export const tooltipBuildProps: BuildProps, "id" | "chartType" | "specType", "type" | "actions" | "selectionPrompt" | "actionsLoading" | "noActionsLoaded" | "snap" | "showNullValues" | "actionPrompt" | "pinningPrompt" | "maxTooltipItems" | "maxVisibleTooltipItems", "footer" | "header" | "offset" | "fallbackPlacements" | "placement" | "boundary" | "boundaryPadding" | "headerFormatter" | "unit" | "customTooltip" | "stickTo", never>; // @public export type TooltipCellStyle = Pick; @@ -2829,10 +2850,22 @@ export type TooltipSettings = TooltipType | TooltipProps; // @public export interface TooltipSpec extends Spec, TooltipPortalSettings<'chart'> { + actionPrompt: string; + actions: TooltipAction[] | ((selected: TooltipValue[]) => Promise[]> | TooltipAction[]); + actionsLoading: string | ComponentType<{ + selected: TooltipValue[]; + }>; customTooltip?: CustomTooltip; footer?: string | ((items: TooltipValue[]) => ReactNode); header?: string | ((items: TooltipValue[]) => ReactNode); headerFormatter?: TooltipValueFormatter; + maxTooltipItems: number; + maxVisibleTooltipItems: number; + noActionsLoaded: string | ComponentType<{ + selected: TooltipValue[]; + }>; + pinningPrompt: string; + selectionPrompt: string; showNullValues: boolean; snap: boolean; stickTo?: TooltipStickTo; @@ -2855,10 +2888,17 @@ export const TooltipStickTo: Readonly<{ // @public (undocumented) export type TooltipStickTo = $Values; +// @public +export interface TooltipStyle { + defaultDotColor: Color; + maxTableHeight: CSSProperties['maxHeight']; + maxWidth: NonNullable; +} + // Warning: (ae-forgotten-export) The symbol "TooltipTableProps" needs to be exported by the entry point index.d.ts // // @public (undocumented) -export const TooltipTable: ({ maxHeight, className, ...props }: TooltipTableProps) => JSX.Element; +export const TooltipTable: ({ className, ...props }: TooltipTableProps) => JSX.Element; // Warning: (ae-forgotten-export) The symbol "TooltipTableBodyProps" needs to be exported by the entry point index.d.ts // @@ -2866,17 +2906,19 @@ export const TooltipTable: ({ className, ...props }: TooltipTableBodyProps) => JSX.Element; // @public (undocumented) -export const TooltipTableCell: ({ style, tagName, className, children }: TooltipTableCellProps) => JSX.Element; +export const TooltipTableCell: ({ style, truncate, tagName, className, children, title: manualTitle, }: TooltipTableCellProps) => JSX.Element; // @public (undocumented) export type TooltipTableCellProps = PropsWithChildren_2<{ tagName?: 'td' | 'th'; + truncate?: boolean; className?: string; + title?: string; style?: TooltipCellStyle; }>; // @public -export function TooltipTableColorCell({ color, className, ...cellProps }: ColorStripCellProps): JSX.Element | null; +export function TooltipTableColorCell({ color, className, displayOnly, ...cellProps }: ColorStripCellProps): JSX.Element | null; // @alpha export type TooltipTableColumn = TooltipTableColumnCustom | TooltipTableColumnColor | TooltipTableColumnNumber | TooltipTableColumnText; @@ -2889,6 +2931,8 @@ export type TooltipTableColumnBase[]) => string); hidden?: boolean | ((items: TooltipValue[]) => boolean); style?: TooltipCellStyle; + truncate?: boolean; + width?: CSSProperties['gridTemplateColumns']; }; // @alpha @@ -2925,17 +2969,17 @@ export interface TooltipTableColumnText({ maxHeight, className, ...props }: TooltipTableFooterProps) => JSX.Element | null; +export const TooltipTableFooter: ({ className, ...props }: TooltipTableFooterProps) => JSX.Element | null; // Warning: (ae-forgotten-export) The symbol "TooltipTableHeaderProps" needs to be exported by the entry point index.d.ts // // @public (undocumented) -export const TooltipTableHeader: ({ maxHeight, className, ...props }: TooltipTableHeaderProps) => JSX.Element | null; +export const TooltipTableHeader: ({ className, ...props }: TooltipTableHeaderProps) => JSX.Element | null; // Warning: (ae-forgotten-export) The symbol "TooltipTableRowProps" needs to be exported by the entry point index.d.ts // // @public (undocumented) -export const TooltipTableRow: ({ maxHeight, isHighlighted, children, className }: TooltipTableRowProps) => JSX.Element; +export const TooltipTableRow: ({ id, isHighlighted, isSelected, children, onSelect, className, }: TooltipTableRowProps) => JSX.Element; // @public export const TooltipType: Readonly<{ diff --git a/packages/charts/src/chart_types/flame_chart/flame_chart.tsx b/packages/charts/src/chart_types/flame_chart/flame_chart.tsx index 9328a6d655..c4b7d965ed 100644 --- a/packages/charts/src/chart_types/flame_chart/flame_chart.tsx +++ b/packages/charts/src/chart_types/flame_chart/flame_chart.tsx @@ -6,16 +6,16 @@ * Side Public License, v 1. */ -import React, { createRef, CSSProperties, KeyboardEvent, MouseEvent, RefObject, WheelEventHandler } from 'react'; +import React, { createRef, CSSProperties, RefObject, WheelEventHandler } from 'react'; import { connect } from 'react-redux'; import { bindActionCreators, Dispatch } from 'redux'; import { ChartType } from '..'; -import { DEFAULT_CSS_CURSOR } from '../../common/constants'; +import { DEFAULT_CSS_CURSOR, SECONDARY_BUTTON } from '../../common/constants'; import { bindFramebuffer, createTexture, NullTexture, readPixel, Texture } from '../../common/kingly'; import { GL } from '../../common/webgl_constants'; import { BasicTooltip } from '../../components/tooltip/tooltip'; -import { SettingsSpec, SpecType, TooltipType } from '../../specs'; +import { SettingsSpec, SpecType, TooltipType, TooltipValue } from '../../specs'; import { onChartRendered } from '../../state/actions/chart'; import { ON_POINTER_MOVE } from '../../state/actions/mouse'; import { BackwardRef, GlobalChartState } from '../../state/chart_state'; @@ -145,6 +145,7 @@ interface StateProps { chartDimensions: Size; a11ySettings: ReturnType; tooltipRequired: boolean; + pinnableTooltip: boolean; onElementOver: NonNullable; onElementClick: NonNullable; onElementOut: NonNullable; @@ -183,8 +184,17 @@ class FlameComponent extends React.Component { private pointerX: number = NaN; private pointerY: number = NaN; + // mouse coordinates for pinned tooltip + private pinnedPointerX: number = NaN; + private pinnedPointerY: number = NaN; + + // pinned tooltip state + private tooltipPinned: boolean = false; + private tooltipSelectedSeries: TooltipValue[] = []; + // currently hovered over datum private hoverIndex: number = NaN; + private tooltipValues: TooltipValue[] = []; // drilldown animation private animationRafId: number = NaN; @@ -255,6 +265,29 @@ class FlameComponent extends React.Component { columns.position0 === columns.position1 && columns.size0 === columns.size1 ? -Infinity : Infinity; // if nothing to tween, then skip it } + private pinTooltip = (pinned: boolean): void => { + if (!pinned) { + this.unpinTooltip(true); + return; + } + + this.tooltipPinned = true; + this.tooltipSelectedSeries = this.tooltipValues; + // this.setState({}); + }; + + private toggleSelectedTooltipItem = (tooltipValue: TooltipValue): void => { + // selection is arbitrary for flame elements - just toggle single selection + if (!this.tooltipPinned) return; + this.tooltipSelectedSeries = this.tooltipSelectedSeries.length === 0 ? [tooltipValue] : []; + this.setState({}); + }; + + private setSelectedTooltipItems = (tooltipValues: TooltipValue[]): void => { + this.tooltipSelectedSeries = tooltipValues; + this.setState({}); + }; + private focusOnNavElement(element?: NavRect) { if (!element) { return; @@ -357,8 +390,15 @@ class FlameComponent extends React.Component { this.drawCanvas(); }; - componentDidUpdate = () => { + private chartDimensionsChanged({ height, width }: Size): boolean { + return this.props.chartDimensions.height !== height || this.props.chartDimensions.width !== width; + } + + componentDidUpdate = ({ chartDimensions }: FlameProps) => { if (!this.ctx) this.tryCanvasContext(); + if (this.tooltipPinned && this.chartDimensionsChanged(chartDimensions)) { + this.unpinTooltip(); + } this.bindControls(); this.ensureTextureAndDraw(); @@ -378,48 +418,83 @@ class FlameComponent extends React.Component { const box = this.props.forwardStageRef.current.getBoundingClientRect(); this.pointerX = e.clientX - box.left; this.pointerY = e.clientY - box.top; + + if (!this.tooltipPinned) { + this.pinnedPointerX = this.pointerX; + this.pinnedPointerY = this.pointerY; + } + } + + private unpinTooltip(redraw = false) { + this.pinnedPointerX = NaN; + this.pinnedPointerY = NaN; + this.tooltipPinned = false; + this.tooltipSelectedSeries = []; + this.updateHoverIndex(); + if (redraw) { + this.smartDraw(); + } } private getHoveredDatumIndex = () => { const pr = window.devicePixelRatio * this.pinchZoomScale; - return { - datumIndex: this.datumAtXY(pr * this.pointerX, pr * (this.props.chartDimensions.height - this.pointerY)), - }; + const x = this.tooltipPinned ? this.pinnedPointerX : this.pointerX; + const y = this.tooltipPinned ? this.pinnedPointerY : this.pointerY; + return this.datumAtXY(pr * x, pr * (this.props.chartDimensions.height - y)); }; private getDragDistanceX = () => this.pointerX - this.startOfDragX; private getDragDistanceY = () => -(this.pointerY - this.startOfDragY); private isDragging = ({ buttons }: { buttons: number }) => buttons & LEFT_MOUSE_BUTTON; - private handleMouseHoverMove = (e: React.MouseEvent) => { + private handleMouseHoverMove = (e: React.MouseEvent) => { if (!this.isDragging(e)) { e.stopPropagation(); this.updatePointerLocation(e); - const hovered = this.getHoveredDatumIndex(); - const prevHoverIndex = this.hoverIndex >= 0 ? this.hoverIndex : NaN; - if (hovered) { - this.hoverIndex = hovered.datumIndex; - if (!Object.is(this.hoverIndex, prevHoverIndex)) { - if (Number.isFinite(hovered.datumIndex)) { - this.props.onElementOver([{ vmIndex: hovered.datumIndex }]); // userland callback - } else { - this.hoverIndex = NaN; - this.props.onElementOut(); // userland callback - } - } - this.setState({}); // exact tooltip location needs an update + if (!this.tooltipPinned) { + this.updateHoverIndex(); } } }; - private handleMouseDragMove = (e: { - stopPropagation: () => void; - buttons: number; - clientX: number; - clientY: number; - }) => { + private updateHoverIndex() { + const hoveredDatumIndex = this.getHoveredDatumIndex(); + const prevHoverIndex = this.hoverIndex >= 0 ? this.hoverIndex : NaN; + this.hoverIndex = hoveredDatumIndex; + if (!Object.is(this.hoverIndex, prevHoverIndex)) { + if (Number.isFinite(hoveredDatumIndex)) { + this.props.onElementOver([{ vmIndex: hoveredDatumIndex }]); // userland callback + } else { + this.hoverIndex = NaN; + this.props.onElementOut(); // userland callback + } + } + + if (prevHoverIndex !== this.hoverIndex) { + const columns = this.props.columnarViewModel; + this.tooltipValues = + this.hoverIndex >= 0 + ? [ + { + label: columns.label[this.hoverIndex], + color: getColor(columns.color, this.hoverIndex), + isHighlighted: false, + isVisible: true, + seriesIdentifier: { specId: '', key: '' }, + value: columns.value[this.hoverIndex], + formattedValue: `${specValueFormatter(columns.value[this.hoverIndex])}`, + valueAccessor: this.hoverIndex, + }, + ] + : []; + } + this.setState({}); // exact tooltip location needs an update + } + + private handleMouseDragMove = (e: MouseEvent) => { e.stopPropagation(); this.updatePointerLocation(e); + if (this.isDragging(e)) { const dragInMinimap = this.pointerInMinimap(this.startOfDragX, this.startOfDragY); const focusMoveDirection = dragInMinimap ? 1 : -1; // focus box moves in direction of drag: positive; opposite: negative @@ -471,47 +546,91 @@ class FlameComponent extends React.Component { this.startOfDragY = this.pointerY; }; - private handleMouseDown = (e: MouseEvent) => { + private handleMouseDown = (e: React.MouseEvent) => { e.stopPropagation(); + if (e.button === SECONDARY_BUTTON || e.ctrlKey) return; // context menu click if (Number.isNaN(this.pointerX + this.pointerY)) return; // don't reset from minimap + if (this.tooltipPinned) return; // prevent dragging while tooltip is pinned + this.resetDrag(); + window.addEventListener('mousemove', this.handleMouseDragMove, { passive: true }); window.addEventListener('mouseup', this.handleMouseUp, { passive: true }); }; - private handleMouseUp = (e: { - stopPropagation: () => void; - buttons: number; - clientX: number; - clientY: number; - detail: number; - }) => { + private handleContextMenu = (e: React.MouseEvent) => { e.stopPropagation(); + e.preventDefault(); // prevent browser context menu + + if (this.tooltipPinned) { + this.handleUnpinningTooltip(); + return; + } + if (!Number.isFinite(this.getHoveredDatumIndex())) { + // NOP if not hover a node + return; + } + window.addEventListener('keyup', this.handleKeyUp); + window.addEventListener('click', this.handleUnpinningTooltip); + window.addEventListener('visibilitychange', this.handleUnpinningTooltip); + this.pinTooltip(true); + this.setState({}); // updates cursor + }; + + private handleMouseUp = (e: MouseEvent) => { + e.stopPropagation(); + window.removeEventListener('mousemove', this.handleMouseDragMove); window.removeEventListener('mouseup', this.handleMouseUp); + + if (this.tooltipPinned) { + this.unpinTooltip(); + this.clearDrag(); + return; + } + this.updatePointerLocation(e); // just in case: eg. the user tabbed away, moved mouse elsewhere, and came back const dragDistanceX = this.getDragDistanceX(); // zero or NaN means that a non-zero drag didn't happen const dragDistanceY = this.getDragDistanceY(); // zero or NaN means that a non-zero drag didn't happen if (!dragDistanceX && !dragDistanceY) { - const hovered = this.getHoveredDatumIndex(); + const hoveredDatumIndex = this.getHoveredDatumIndex(); const isDoubleClick = e.detail > 1; - const hasClickedOnRectangle = Number.isFinite(hovered?.datumIndex); + const hasClickedOnRectangle = Number.isFinite(hoveredDatumIndex); const mustFocus = SINGLE_CLICK_EMPTY_FOCUS || isDoubleClick !== hasClickedOnRectangle; // xor: either double-click on empty space, or single-click on a node - if (mustFocus && !this.pointerInMinimap(this.pointerX, this.pointerY)) { - const { datumIndex } = hovered; - const rect = focusRect(this.props.columnarViewModel, this.props.chartDimensions.height, datumIndex); - this.navigator.add({ ...rect, index: datumIndex }); - this.focusOnNode(datumIndex); - this.props.onElementClick([{ vmIndex: datumIndex }]); // userland callback + const isContextClick = e.button === SECONDARY_BUTTON || e.ctrlKey; + + if (mustFocus && !isContextClick && !this.pointerInMinimap(this.pointerX, this.pointerY)) { + const rect = focusRect(this.props.columnarViewModel, this.props.chartDimensions.height, hoveredDatumIndex); + this.navigator.add({ ...rect, index: hoveredDatumIndex }); + this.focusOnNode(hoveredDatumIndex); + this.props.onElementClick([{ vmIndex: hoveredDatumIndex }]); // userland callback } } this.clearDrag(); this.setState({}); }; - private handleMouseLeave = (e: MouseEvent) => { + private handleUnpinningTooltip = () => { + window.removeEventListener('keyup', this.handleKeyUp); + window.removeEventListener('click', this.handleUnpinningTooltip); + window.removeEventListener('visibilitychange', this.handleUnpinningTooltip); + this.pinTooltip(false); + }; + + static watchedKeys: KeyboardEvent['key'][] = ['Escape']; + private handleKeyUp = ({ key }: KeyboardEvent) => { + if (!FlameComponent.watchedKeys.includes(key)) return; + + window.removeEventListener('keyup', this.handleKeyUp); + + this.unpinTooltip(); + }; + + private handleMouseLeave = (e: React.MouseEvent) => { e.stopPropagation(); - this.smartDraw(); + if (!this.tooltipPinned) { + this.smartDraw(); + } }; private preventScroll = (e: WheelEvent) => e.metaKey === IS_META_REQUIRED_FOR_ZOOM && e.preventDefault(); @@ -519,7 +638,9 @@ class FlameComponent extends React.Component { private handleWheel: WheelEventHandler = (e) => { if (e.metaKey !== IS_META_REQUIRED_FOR_ZOOM) return; // one way: zoom; other way: let scroll happen + this.unpinTooltip(); this.updatePointerLocation(e); + const { x0, x1, y0, y1 } = this.currentFocus; const wheelDelta = -e.deltaY; // mapbox convention: scroll down increases magnification const delta = wheelDelta * ZOOM_SPEED; @@ -628,7 +749,7 @@ class FlameComponent extends React.Component { this.setState({}); }; - private handleEnterKey = (e: KeyboardEvent) => { + private handleEnterKey = (e: React.KeyboardEvent) => { e.stopPropagation(); if (e.key === 'Enter') { if (e.shiftKey) { @@ -647,14 +768,13 @@ class FlameComponent extends React.Component { this.searchForText(false); }; - private handleEscapeKey = (e: KeyboardEvent) => { - e.stopPropagation(); + private handleEscapeKey = (e: React.KeyboardEvent) => { if (e.key === 'Escape') { this.clearSearchText(); } }; - private handleSearchFieldKeyPress = (e: KeyboardEvent) => { + private handleSearchFieldKeyPress = (e: React.KeyboardEvent) => { e.stopPropagation(); if (!this.handleEnterKey(e)) { this.searchForText(false); @@ -717,6 +837,13 @@ class FlameComponent extends React.Component { this.setState({}); }; + private getActiveCursor(): CSSProperties['cursor'] { + if (this.tooltipPinned) return DEFAULT_CSS_CURSOR; + if (this.startOfDragX) return 'grabbing'; + if (this.hoverIndex >= 0) return 'pointer'; + return 'grab'; + } + render = () => { const { forwardStageRef, @@ -736,12 +863,12 @@ class FlameComponent extends React.Component { margin: 0, border: 0, position: 'absolute', - cursor: this.startOfDragX ? 'grab' : this.hoverIndex >= 0 ? 'pointer' : DEFAULT_CSS_CURSOR, + cursor: this.getActiveCursor(), }; + const dpr = window.devicePixelRatio * this.pinchZoomScale; const canvasWidth = width * dpr; const canvasHeight = height * dpr; - const columns = this.props.columnarViewModel; const hitCount = this.currentSearchHitCount; const { @@ -772,6 +899,7 @@ class FlameComponent extends React.Component { height={canvasHeight} onMouseMove={this.handleMouseHoverMove} onMouseDown={this.handleMouseDown} + onContextMenu={this.props.pinnableTooltip ? this.handleContextMenu : undefined} onMouseLeave={this.handleMouseLeave} onKeyPress={this.handleEnterKey} onKeyUp={this.handleEscapeKey} @@ -989,26 +1117,24 @@ class FlameComponent extends React.Component {

({ type: ON_POINTER_MOVE, position: { x: NaN, y: NaN }, time: NaN })} - position={{ x: this.pointerX, y: this.pointerY, width: 0, height: 0 }} - visible={this.props.tooltipRequired && this.hoverIndex >= 0 && !(this.wobbleTimeLeft > 0)} + position={ + this.tooltipPinned + ? { x: this.pinnedPointerX, y: this.pinnedPointerY, width: 0, height: 0 } + : { x: this.pointerX, y: this.pointerY, width: 0, height: 0 } + } + pinned={this.tooltipPinned} + selected={this.tooltipSelectedSeries} + pinTooltip={this.pinTooltip} + toggleSelectedTooltipItem={this.toggleSelectedTooltipItem} + setSelectedTooltipItems={this.setSelectedTooltipItems} + visible={ + this.tooltipPinned || (this.props.tooltipRequired && this.hoverIndex >= 0 && !(this.wobbleTimeLeft > 0)) + } info={{ header: null, - values: - this.hoverIndex >= 0 - ? [ - { - label: columns.label[this.hoverIndex], - color: getColor(columns.color, this.hoverIndex), - isHighlighted: false, - isVisible: true, - seriesIdentifier: { specId: '', key: '' }, - value: columns.value[this.hoverIndex], - formattedValue: `${specValueFormatter(columns.value[this.hoverIndex])}`, - valueAccessor: this.hoverIndex, - }, - ] - : [], + values: this.tooltipValues, }} getChartContainerRef={this.props.containerRef} /> @@ -1211,6 +1337,7 @@ class FlameComponent extends React.Component { const mapStateToProps = (state: GlobalChartState): StateProps => { const flameSpec = getSpecsFromStore(state.specs, ChartType.Flame, SpecType.Series)[0]; const settingsSpec = getSettingsSpecSelector(state); + const tooltipSpec = getTooltipSpecSelector(state); return { theme: getChartThemeSelector(state).flamegraph, debugHistory: settingsSpec.debug, @@ -1219,7 +1346,8 @@ const mapStateToProps = (state: GlobalChartState): StateProps => { animationDuration: flameSpec?.animation.duration ?? 0, chartDimensions: state.parentDimensions, a11ySettings: getA11ySettingsSelector(state), - tooltipRequired: getTooltipSpecSelector(state).type !== TooltipType.None, + tooltipRequired: tooltipSpec.type !== TooltipType.None, + pinnableTooltip: tooltipSpec.actions.length > 0, // mandatory charts API protocol; todo extract these mappings once there are other charts like Flame onElementOver: settingsSpec.onElementOver ?? (() => {}), diff --git a/packages/charts/src/chart_types/flame_chart/internal_chart_state.ts b/packages/charts/src/chart_types/flame_chart/internal_chart_state.ts index a7aedd2161..d6708ff7f9 100644 --- a/packages/charts/src/chart_types/flame_chart/internal_chart_state.ts +++ b/packages/charts/src/chart_types/flame_chart/internal_chart_state.ts @@ -31,7 +31,7 @@ export class FlameState implements InternalChartState { getLegendExtraValues = () => new Map(); getPointerCursor = () => DEFAULT_CSS_CURSOR; getTooltipAnchor = () => ({ x: 0, y: 0, width: 0, height: 0 }); - isTooltipVisible = () => ({ visible: false, isExternal: false }); + isTooltipVisible = () => ({ visible: false, isExternal: false, displayOnly: false, isPinnable: false }); getTooltipInfo = () => ({ header: null, values: [] }); getProjectionContainerArea = () => ({ width: 0, height: 0, top: 0, left: 0 }); getMainProjectionArea = () => ({ width: 0, height: 0, top: 0, left: 0 }); diff --git a/packages/charts/src/chart_types/goal_chart/state/chart_state.tsx b/packages/charts/src/chart_types/goal_chart/state/chart_state.tsx index 9a3dc94623..7b95ed91df 100644 --- a/packages/charts/src/chart_types/goal_chart/state/chart_state.tsx +++ b/packages/charts/src/chart_types/goal_chart/state/chart_state.tsx @@ -12,7 +12,8 @@ import { ChartType } from '../..'; import { DEFAULT_CSS_CURSOR } from '../../../common/constants'; import { LegendItem } from '../../../common/legend'; import { Tooltip } from '../../../components/tooltip/tooltip'; -import { InternalChartState, GlobalChartState, BackwardRef } from '../../../state/chart_state'; +import { InternalChartState, GlobalChartState, BackwardRef, TooltipVisibility } from '../../../state/chart_state'; +import { getActivePointerPosition } from '../../../state/selectors/get_active_pointer_position'; import { InitStatus } from '../../../state/selectors/get_internal_is_intialized'; import { LegendItemLabel } from '../../../state/selectors/get_legend_items_labels'; import { DebugState } from '../../../state/types'; @@ -87,8 +88,13 @@ export class GoalState implements InternalChartState { return DEFAULT_CSS_CURSOR; } - isTooltipVisible(globalState: GlobalChartState) { - return { visible: isTooltipVisibleSelector(globalState), isExternal: false }; + isTooltipVisible(globalState: GlobalChartState): TooltipVisibility { + return { + visible: isTooltipVisibleSelector(globalState), + isExternal: false, + displayOnly: false, + isPinnable: false, + }; } getTooltipInfo(globalState: GlobalChartState) { @@ -96,7 +102,7 @@ export class GoalState implements InternalChartState { } getTooltipAnchor(state: GlobalChartState) { - const { position } = state.interactions.pointer.current; + const position = getActivePointerPosition(state); return { isRotated: false, x: position.x, diff --git a/packages/charts/src/chart_types/goal_chart/state/selectors/picked_shapes.ts b/packages/charts/src/chart_types/goal_chart/state/selectors/picked_shapes.ts index 2b4e52e01e..9dda9a7c18 100644 --- a/packages/charts/src/chart_types/goal_chart/state/selectors/picked_shapes.ts +++ b/packages/charts/src/chart_types/goal_chart/state/selectors/picked_shapes.ts @@ -8,16 +8,12 @@ import { Rectangle } from '../../../../common/geometry'; import { LayerValue } from '../../../../specs'; -import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; import { BulletViewModel } from '../../layout/types/viewmodel_types'; import { initialBoundingBox, Mark } from '../../layout/viewmodel/geoms'; +import { getActivePointerPosition } from './../../../../state/selectors/get_active_pointer_position'; import { geometries, getPrimitiveGeoms } from './geometries'; -function getCurrentPointerPosition(state: GlobalChartState) { - return state.interactions.pointer.current.position; -} - function fullBoundingBox(ctx: CanvasRenderingContext2D | null, geoms: Mark[]) { const box = initialBoundingBox(); if (ctx) { @@ -42,7 +38,7 @@ export const getCaptureBoundingBox = createCustomCachedSelector([getPrimitiveGeo /** @internal */ export const getPickedShapes = createCustomCachedSelector( - [geometries, getCurrentPointerPosition, getCaptureBoundingBox], + [geometries, getActivePointerPosition, getCaptureBoundingBox], (geoms, pointerPosition, capture): BulletViewModel[] => { const picker = geoms.pickQuads; const { chartCenter } = geoms; diff --git a/packages/charts/src/chart_types/heatmap/state/chart_state.tsx b/packages/charts/src/chart_types/heatmap/state/chart_state.tsx index 4056c80412..3fb300900e 100644 --- a/packages/charts/src/chart_types/heatmap/state/chart_state.tsx +++ b/packages/charts/src/chart_types/heatmap/state/chart_state.tsx @@ -98,7 +98,7 @@ export class HeatmapState implements InternalChartState { } isTooltipVisible(globalState: GlobalChartState) { - return { visible: isTooltipVisibleSelector(globalState), isExternal: false }; + return isTooltipVisibleSelector(globalState); } getTooltipInfo(globalState: GlobalChartState) { diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/get_brush_area.ts b/packages/charts/src/chart_types/heatmap/state/selectors/get_brush_area.ts index 2e484f18c0..e30c5cbf84 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/get_brush_area.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/get_brush_area.ts @@ -9,6 +9,7 @@ import { BrushAxis } from '../../../../specs'; import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; import { clamp } from '../../../../utils/common'; import { Dimensions } from '../../../../utils/dimensions'; @@ -17,14 +18,13 @@ import { getBrushedHighlightedShapesSelector } from './get_brushed_highlighted_s const getMouseDownPosition = (state: GlobalChartState) => state.interactions.pointer.down; const getIsDragging = (state: GlobalChartState) => state.interactions.pointer.dragging; -const getCurrentPointerPosition = (state: GlobalChartState) => state.interactions.pointer.current.position; /** @internal */ export const getBrushAreaSelector = createCustomCachedSelector( [ getIsDragging, getMouseDownPosition, - getCurrentPointerPosition, + getActivePointerPosition, getSettingsSpecSelector, computeChartElementSizesSelector, getBrushedHighlightedShapesSelector, diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/get_brushed_highlighted_shapes.ts b/packages/charts/src/chart_types/heatmap/state/selectors/get_brushed_highlighted_shapes.ts index 8b58e01aa4..66e9a11950 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/get_brushed_highlighted_shapes.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/get_brushed_highlighted_shapes.ts @@ -9,6 +9,7 @@ import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; import { DragShape } from '../../layout/types/viewmodel_types'; +import { getActivePointerPosition } from './../../../../state/selectors/get_active_pointer_position'; import { getHeatmapGeometries } from './geometries'; function getCurrentPointerStates(state: GlobalChartState) { @@ -17,12 +18,12 @@ function getCurrentPointerStates(state: GlobalChartState) { /** @internal */ export const getBrushedHighlightedShapesSelector = createCustomCachedSelector( - [getHeatmapGeometries, getCurrentPointerStates], - (geoms, pointerStates): DragShape => { + [getHeatmapGeometries, getCurrentPointerStates, getActivePointerPosition], + (geoms, pointerStates, activePosition): DragShape => { if (!pointerStates.dragging || !pointerStates.down) { return null; } - return geoms.pickDragShape([pointerStates.down.position, pointerStates.current.position]); + return geoms.pickDragShape([pointerStates.down.position, activePosition]); }, ); diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_band.ts b/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_band.ts index 7b8ce11a66..959d0e85a5 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_band.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_band.ts @@ -8,27 +8,26 @@ import { Rect } from '../../../../geoms/types'; import { isPointerOverEvent, PointerEvent } from '../../../../specs'; -import { GlobalChartState, PointerState } from '../../../../state/chart_state'; +import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; -import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { isNil } from '../../../../utils/common'; +import { Point } from '../../../../utils/point'; import { ShapeViewModel } from '../../layout/types/viewmodel_types'; import { getHeatmapGeometries } from './geometries'; const getExternalPointerEventStateSelector = (state: GlobalChartState) => state.externalEvents.pointer; -const getPointerEventStateSelector = (state: GlobalChartState) => state.interactions.pointer.current; - /** @internal */ export const getCursorBandPositionSelector = createCustomCachedSelector( - [getHeatmapGeometries, getExternalPointerEventStateSelector, getPointerEventStateSelector, getSettingsSpecSelector], + [getHeatmapGeometries, getExternalPointerEventStateSelector, getActivePointerPosition], getCursorBand, ); function getCursorBand( geoms: ShapeViewModel, externalPointerEvent: PointerEvent | null, - currentPointer: PointerState, + currentPointerPosition: Point, ): (Rect & { fromExternalEvent: boolean }) | undefined { // external pointer events takes precedence over the current mouse pointer if (isPointerOverEvent(externalPointerEvent)) { @@ -44,8 +43,8 @@ function getCursorBand( } } // display the current hovered cell - if (currentPointer.position.x > -1) { - const point = currentPointer.position; + if (currentPointerPosition.x > -1) { + const point = currentPointerPosition; const end = { x: point.x + Number.EPSILON, y: point.y + Number.EPSILON }; const band = geoms.pickDragShape([point, end]); if (band) { diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_pointer.ts b/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_pointer.ts index 7ae0b1920a..b9c1dcba6d 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_pointer.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/get_cursor_pointer.ts @@ -6,15 +6,21 @@ * Side Public License, v 1. */ +import { CSSProperties } from 'react'; + import { DEFAULT_CSS_CURSOR } from '../../../../common/constants'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { isBrushingSelector } from './is_brushing'; import { getPickedShapes } from './picked_shapes'; /** @internal */ export const getPointerCursorSelector = createCustomCachedSelector( - [getPickedShapes, isBrushingSelector], - (pickedShapes, isBrushing) => { - return isBrushing || (Array.isArray(pickedShapes) && pickedShapes.length > 0) ? 'pointer' : DEFAULT_CSS_CURSOR; + [getPickedShapes, isBrushingSelector, getTooltipInteractionState], + (pickedShapes, isBrushing, tooltipState): CSSProperties['cursor'] => { + if (tooltipState.pinned) return; + return isBrushing || (Array.isArray(pickedShapes) && pickedShapes.some(({ visible }) => visible)) + ? 'pointer' + : DEFAULT_CSS_CURSOR; }, ); diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/get_tooltip_anchor.ts b/packages/charts/src/chart_types/heatmap/state/selectors/get_tooltip_anchor.ts index 122b989894..99b399e703 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/get_tooltip_anchor.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/get_tooltip_anchor.ts @@ -7,18 +7,14 @@ */ import { AnchorPosition } from '../../../../components/portal/types'; -import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { computeChartElementSizesSelector } from './compute_chart_dimensions'; import { getPickedShapes } from './picked_shapes'; -function getCurrentPointerPosition(state: GlobalChartState) { - return state.interactions.pointer.current.position; -} - /** @internal */ export const getTooltipAnchorSelector = createCustomCachedSelector( - [getPickedShapes, computeChartElementSizesSelector, getCurrentPointerPosition], + [getPickedShapes, computeChartElementSizesSelector, getActivePointerPosition], (shapes, { grid }, position): AnchorPosition => { if (Array.isArray(shapes) && shapes.length > 0) { const firstShape = shapes[0]; diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/is_tooltip_visible.ts b/packages/charts/src/chart_types/heatmap/state/selectors/is_tooltip_visible.ts index ba48181922..87f9e0d214 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/is_tooltip_visible.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/is_tooltip_visible.ts @@ -7,15 +7,30 @@ */ import { TooltipType } from '../../../../specs/constants'; +import { TooltipVisibility } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { getTooltipSpecSelector } from '../../../../state/selectors/get_tooltip_spec'; import { getTooltipInfoSelector } from './tooltip'; /** @internal */ export const isTooltipVisibleSelector = createCustomCachedSelector( - [getTooltipSpecSelector, getTooltipInfoSelector], - ({ type }, tooltipInfo): boolean => { - if (type === TooltipType.None) return false; - return tooltipInfo.values.length > 0; + [getTooltipSpecSelector, getTooltipInfoSelector, getTooltipInteractionState], + ({ type }, tooltipInfo, { pinned }): TooltipVisibility => { + if (type === TooltipType.None) { + return { + visible: false, + isExternal: false, + displayOnly: false, + isPinnable: false, + }; + } + + return { + visible: tooltipInfo.values.length > 0 || pinned, + displayOnly: tooltipInfo.values.every(({ displayOnly }) => displayOnly), + isExternal: false, + isPinnable: tooltipInfo.values.length > 0, + }; }, ); diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/on_pointer_update_caller.ts b/packages/charts/src/chart_types/heatmap/state/selectors/on_pointer_update_caller.ts index 070c313df3..c8938cab38 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/on_pointer_update_caller.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/on_pointer_update_caller.ts @@ -18,11 +18,12 @@ import { } from '../../../../specs'; import { GlobalChartState, PointerState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { getChartIdSelector } from '../../../../state/selectors/get_chart_id'; import { getLastClickSelector } from '../../../../state/selectors/get_last_click'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; import { getSpecOrNull } from './heatmap_spec'; -import { getCurrentPointerPosition, getPickedGridCell } from './picked_shapes'; +import { getPickedGridCell } from './picked_shapes'; function isSameEventValue(a: PointerOverEvent, b: PointerOverEvent, changeTrigger: PointerUpdateTrigger) { const checkX = changeTrigger === PointerUpdateTrigger.X || changeTrigger === PointerUpdateTrigger.Both; @@ -57,7 +58,7 @@ export function createOnPointerUpdateCaller(): (state: GlobalChartState) => void getSpecOrNull, getLastClickSelector, getSettingsSpecSelector, - getCurrentPointerPosition, + getActivePointerPosition, getPickedGridCell, getChartIdSelector, ], diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/picked_shapes.ts b/packages/charts/src/chart_types/heatmap/state/selectors/picked_shapes.ts index 1947387f55..91ae3da11e 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/picked_shapes.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/picked_shapes.ts @@ -6,20 +6,15 @@ * Side Public License, v 1. */ -import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { Cell, GridCell, TextBox } from '../../layout/types/viewmodel_types'; import { computeChartElementSizesSelector } from './compute_chart_dimensions'; import { getHeatmapGeometries } from './geometries'; -/** @internal */ -export function getCurrentPointerPosition(state: GlobalChartState) { - return state.interactions.pointer.current.position; -} - /** @internal */ export const getPickedShapes = createCustomCachedSelector( - [getHeatmapGeometries, getCurrentPointerPosition, computeChartElementSizesSelector], + [getHeatmapGeometries, getActivePointerPosition, computeChartElementSizesSelector], (geoms, pointerPosition, dims): Cell[] | TextBox => { const picker = geoms.pickQuads; const { x, y } = pointerPosition; @@ -32,7 +27,7 @@ export const getPickedShapes = createCustomCachedSelector( /** @internal */ export const getPickedGridCell = createCustomCachedSelector( - [getHeatmapGeometries, getCurrentPointerPosition, computeChartElementSizesSelector], + [getHeatmapGeometries, getActivePointerPosition, computeChartElementSizesSelector], (geoms, pointerPosition): GridCell | undefined => { return geoms.pickGridCell(pointerPosition.x, pointerPosition.y); }, diff --git a/packages/charts/src/chart_types/heatmap/state/selectors/tooltip.ts b/packages/charts/src/chart_types/heatmap/state/selectors/tooltip.ts index 3c33f70030..601b7c776f 100644 --- a/packages/charts/src/chart_types/heatmap/state/selectors/tooltip.ts +++ b/packages/charts/src/chart_types/heatmap/state/selectors/tooltip.ts @@ -16,6 +16,7 @@ import { getPickedShapes } from './picked_shapes'; const EMPTY_TOOLTIP = Object.freeze({ header: null, values: [], + disableActions: false, }); /** @internal */ @@ -29,6 +30,7 @@ export const getTooltipInfoSelector = createCustomCachedSelector( const tooltipInfo: TooltipInfo = { header: null, values: [], + disableActions: false, }; if (Array.isArray(pickedShapes)) { @@ -78,6 +80,7 @@ export const getTooltipInfoSelector = createCustomCachedSelector( value: `${shape.value}`, formattedValue: `${shape.formatted}`, datum: shape.datum, + displayOnly: true, }); }); } else { @@ -93,7 +96,9 @@ export const getTooltipInfoSelector = createCustomCachedSelector( value: `${pickedShapes.value}`, formattedValue: `${pickedShapes.value}`, datum: pickedShapes.value, + displayOnly: true, }); + tooltipInfo.disableActions = true; } return tooltipInfo; diff --git a/packages/charts/src/chart_types/metric/state/chart_state.tsx b/packages/charts/src/chart_types/metric/state/chart_state.tsx index ca9db3ca33..ee23c7a63c 100644 --- a/packages/charts/src/chart_types/metric/state/chart_state.tsx +++ b/packages/charts/src/chart_types/metric/state/chart_state.tsx @@ -33,7 +33,13 @@ export class MetricState implements InternalChartState { getLegendItemsLabels = () => EMPTY_LEGEND_ITEM_LIST; getLegendExtraValues = () => EMPTY_MAP; getPointerCursor = () => DEFAULT_CSS_CURSOR; - isTooltipVisible = () => ({ visible: false, isExternal: false }); + isTooltipVisible = () => ({ + visible: false, + isExternal: false, + displayOnly: false, + isPinnable: false, + }); + getTooltipInfo = () => undefined; getTooltipAnchor = () => null; eventCallbacks = () => {}; diff --git a/packages/charts/src/chart_types/partition_chart/state/chart_state.tsx b/packages/charts/src/chart_types/partition_chart/state/chart_state.tsx index 665b57f193..9ec6b4f072 100644 --- a/packages/charts/src/chart_types/partition_chart/state/chart_state.tsx +++ b/packages/charts/src/chart_types/partition_chart/state/chart_state.tsx @@ -10,6 +10,7 @@ import { RefObject } from 'react'; import { ChartType } from '../..'; import { BackwardRef, GlobalChartState, InternalChartState } from '../../../state/chart_state'; +import { getActivePointerPosition } from '../../../state/selectors/get_active_pointer_position'; import { InitStatus } from '../../../state/selectors/get_internal_is_intialized'; import { DebugState } from '../../../state/types'; import { Dimensions } from '../../../utils/dimensions'; @@ -86,6 +87,8 @@ export class PartitionState implements InternalChartState { return { visible: isTooltipVisibleSelector(globalState), isExternal: false, + displayOnly: false, + isPinnable: true, }; } @@ -94,7 +97,7 @@ export class PartitionState implements InternalChartState { } getTooltipAnchor(state: GlobalChartState) { - const { position } = state.interactions.pointer.current; + const position = getActivePointerPosition(state); return { isRotated: false, x: position.x, diff --git a/packages/charts/src/chart_types/partition_chart/state/selectors/get_cursor_pointer.ts b/packages/charts/src/chart_types/partition_chart/state/selectors/get_cursor_pointer.ts index dfb99a3bbe..51fa0f9c2e 100644 --- a/packages/charts/src/chart_types/partition_chart/state/selectors/get_cursor_pointer.ts +++ b/packages/charts/src/chart_types/partition_chart/state/selectors/get_cursor_pointer.ts @@ -9,12 +9,14 @@ import { DEFAULT_CSS_CURSOR } from '../../../../common/constants'; import { createCustomCachedSelector } from '../../../../state/create_selector'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { getPickedShapes } from './picked_shapes'; /** @internal */ export const getPointerCursorSelector = createCustomCachedSelector( - [getPickedShapes, getSettingsSpecSelector], - (pickedShapes, { onElementClick, onElementOver }) => { + [getPickedShapes, getSettingsSpecSelector, getTooltipInteractionState], + (pickedShapes, { onElementClick, onElementOver }, tooltipState) => { + if (tooltipState.pinned) return; return Array.isArray(pickedShapes) && pickedShapes.length > 0 && (onElementClick || onElementOver) ? 'pointer' : DEFAULT_CSS_CURSOR; diff --git a/packages/charts/src/chart_types/partition_chart/state/selectors/picked_shapes.ts b/packages/charts/src/chart_types/partition_chart/state/selectors/picked_shapes.ts index bb087420c6..f0a372fd40 100644 --- a/packages/charts/src/chart_types/partition_chart/state/selectors/picked_shapes.ts +++ b/packages/charts/src/chart_types/partition_chart/state/selectors/picked_shapes.ts @@ -6,18 +6,14 @@ * Side Public License, v 1. */ -import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; import { pickedShapes, pickShapesLayerValues } from '../../layout/viewmodel/picked_shapes'; +import { getActivePointerPosition } from './../../../../state/selectors/get_active_pointer_position'; import { partitionDrilldownFocus, partitionMultiGeometries } from './geometries'; -function getCurrentPointerPosition(state: GlobalChartState) { - return state.interactions.pointer.current.position; -} - /** @internal */ export const getPickedShapes = createCustomCachedSelector( - [partitionMultiGeometries, getCurrentPointerPosition, partitionDrilldownFocus], + [partitionMultiGeometries, getActivePointerPosition, partitionDrilldownFocus], pickedShapes, ); diff --git a/packages/charts/src/chart_types/timeslip/internal_chart_state.ts b/packages/charts/src/chart_types/timeslip/internal_chart_state.ts index 92d70cbd8b..05d9c94548 100644 --- a/packages/charts/src/chart_types/timeslip/internal_chart_state.ts +++ b/packages/charts/src/chart_types/timeslip/internal_chart_state.ts @@ -31,7 +31,13 @@ export class TimeslipState implements InternalChartState { getLegendExtraValues = () => new Map(); getPointerCursor = () => DEFAULT_CSS_CURSOR; getTooltipAnchor = () => ({ x: 0, y: 0, width: 0, height: 0 }); - isTooltipVisible = () => ({ visible: false, isExternal: false }); + isTooltipVisible = () => ({ + visible: false, + isExternal: false, + displayOnly: false, + isPinnable: false, + }); + getTooltipInfo = () => ({ header: null, values: [] }); getProjectionContainerArea = () => ({ width: 0, height: 0, top: 0, left: 0 }); getMainProjectionArea = () => ({ width: 0, height: 0, top: 0, left: 0 }); diff --git a/packages/charts/src/chart_types/timeslip/timeslip/data.ts b/packages/charts/src/chart_types/timeslip/timeslip/data.ts index 367428e4b0..7000e52917 100644 --- a/packages/charts/src/chart_types/timeslip/timeslip/data.ts +++ b/packages/charts/src/chart_types/timeslip/timeslip/data.ts @@ -24,6 +24,5 @@ export const getEnrichedData = (rows: { epochMs: number; value?: number }[]) => maxValue: -Infinity, }, ); - // console.log({ from: new Date(stats.minEpochMs), to: new Date(stats.maxEpochMs), count: rows.length }) return { rows, stats }; }; diff --git a/packages/charts/src/chart_types/wordcloud/state/chart_state.tsx b/packages/charts/src/chart_types/wordcloud/state/chart_state.tsx index cebd755eb6..e2789157ef 100644 --- a/packages/charts/src/chart_types/wordcloud/state/chart_state.tsx +++ b/packages/charts/src/chart_types/wordcloud/state/chart_state.tsx @@ -65,7 +65,12 @@ export class WordcloudState implements InternalChartState { } isTooltipVisible() { - return { visible: false, isExternal: false }; + return { + visible: false, + isExternal: false, + displayOnly: false, + isPinnable: false, + }; } getTooltipInfo() { diff --git a/packages/charts/src/chart_types/xy_chart/annotations/line/tooltip.test.tsx b/packages/charts/src/chart_types/xy_chart/annotations/line/tooltip.test.tsx index 0579209c26..5506e6c07f 100644 --- a/packages/charts/src/chart_types/xy_chart/annotations/line/tooltip.test.tsx +++ b/packages/charts/src/chart_types/xy_chart/annotations/line/tooltip.test.tsx @@ -59,12 +59,12 @@ describe('Annotation tooltips', () => { expect(annotation).toHaveLength(1); expect(wrapper.find('.echAnnotation')).toHaveLength(0); annotation.simulate('mouseenter'); - const header = wrapper.find('.echTooltip__header'); + const header = wrapper.find('.echTooltipHeader'); expect(header).toHaveLength(1); expect(header.text()).toEqual('2'); expect(wrapper.find('.echAnnotation__details').text()).toEqual('foo'); annotation.simulate('mouseleave'); - expect(annotation.find('.echTooltip__header')).toHaveLength(0); + expect(annotation.find('.echTooltipHeader')).toHaveLength(0); }); test('should now show tooltip if hidden', () => { diff --git a/packages/charts/src/chart_types/xy_chart/renderer/canvas/animations/animation.ts b/packages/charts/src/chart_types/xy_chart/renderer/canvas/animations/animation.ts index 3a8b7f3f3e..cab615f09c 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/canvas/animations/animation.ts +++ b/packages/charts/src/chart_types/xy_chart/renderer/canvas/animations/animation.ts @@ -77,7 +77,6 @@ export class Animation { if (!isFiniteNumber(this.initial) || !isFiniteNumber(this.target) || this.initial === this.target) { return false; } - // if (this.debug && count++ % 30 === 0) console.log(t, this.delay, this.duration, this.timeOffset); return t - this.delay + this.timeOffset < this.duration; } diff --git a/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/_annotations.scss b/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/_annotations.scss index 9707849b77..c47f1b4f48 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/_annotations.scss +++ b/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/_annotations.scss @@ -3,7 +3,7 @@ transition: opacity $euiAnimSpeedNormal; pointer-events: none; user-select: none; - max-width: 256px; + max-width: 260px; &__marker { position: absolute; diff --git a/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/annotation_tooltip.tsx b/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/annotation_tooltip.tsx index d471e19d7b..d5d8f0ee7f 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/annotation_tooltip.tsx +++ b/packages/charts/src/chart_types/xy_chart/renderer/dom/annotations/annotation_tooltip.tsx @@ -29,7 +29,16 @@ export const AnnotationTooltip = ({ state, chartRef, chartId, onScroll, zIndex } } return ( - + ); diff --git a/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_band.tsx b/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_band.tsx index a24b27a06e..216d5a1719 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_band.tsx +++ b/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_band.tsx @@ -12,12 +12,14 @@ import { connect } from 'react-redux'; import { Rect } from '../../../../geoms/types'; import { getTooltipType } from '../../../../specs'; import { TooltipType } from '../../../../specs/constants'; -import { GlobalChartState } from '../../../../state/chart_state'; +import { GlobalChartState, TooltipInteractionState } from '../../../../state/chart_state'; import { getChartRotationSelector } from '../../../../state/selectors/get_chart_rotation'; import { getChartThemeSelector } from '../../../../state/selectors/get_chart_theme'; import { getInternalIsInitializedSelector, InitStatus } from '../../../../state/selectors/get_internal_is_intialized'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { getTooltipSpecSelector } from '../../../../state/selectors/get_tooltip_spec'; +import { getInitialTooltipState } from '../../../../state/utils'; import { Rotation } from '../../../../utils/common'; import { LIGHT_THEME } from '../../../../utils/themes/light_theme'; import { Theme } from '../../../../utils/themes/theme'; @@ -25,14 +27,18 @@ import { getCursorBandPositionSelector } from '../../state/selectors/get_cursor_ interface CursorBandProps { theme: Theme; + isBrushing: boolean; chartRotation: Rotation; cursorPosition?: Rect; tooltipType: TooltipType; fromExternalEvent?: boolean; + tooltipState: TooltipInteractionState; } -function canRenderBand(type: TooltipType, visible: boolean, fromExternalEvent?: boolean) { - return visible && (type === TooltipType.Crosshairs || type === TooltipType.VerticalCursor || fromExternalEvent); +function canRenderBand(type: TooltipType, pinned: boolean, visible: boolean, fromExternalEvent?: boolean) { + return ( + pinned || (visible && (type === TooltipType.Crosshairs || type === TooltipType.VerticalCursor || fromExternalEvent)) + ); } class CursorBandComponent extends React.Component { @@ -43,12 +49,19 @@ class CursorBandComponent extends React.Component { theme: { crosshair: { band }, }, + isBrushing, cursorPosition, tooltipType, fromExternalEvent, + tooltipState: { pinned }, } = this.props; const isBand = (cursorPosition?.width ?? 0) > 0 && (cursorPosition?.height ?? 0) > 0; - if (!isBand || !cursorPosition || !canRenderBand(tooltipType, band.visible, fromExternalEvent)) { + if ( + isBrushing || + !isBand || + !cursorPosition || + !canRenderBand(tooltipType, pinned, band.visible, fromExternalEvent) + ) { return null; } const { x, y, width, height } = cursorPosition; @@ -64,9 +77,11 @@ class CursorBandComponent extends React.Component { const mapStateToProps = (state: GlobalChartState): CursorBandProps => { if (getInternalIsInitializedSelector(state) !== InitStatus.Initialized) { return { + isBrushing: false, theme: LIGHT_THEME, chartRotation: 0, tooltipType: TooltipType.None, + tooltipState: getInitialTooltipState(), }; } const settings = getSettingsSpecSelector(state); @@ -76,11 +91,13 @@ const mapStateToProps = (state: GlobalChartState): CursorBandProps => { const tooltipType = getTooltipType(tooltip, settings, fromExternalEvent); return { + isBrushing: state.interactions.pointer.dragging, theme: getChartThemeSelector(state), chartRotation: getChartRotationSelector(state), cursorPosition: cursorBandPosition, tooltipType, fromExternalEvent, + tooltipState: getTooltipInteractionState(state), }; }; diff --git a/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_line.tsx b/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_line.tsx index 862f7987dd..a193ba4ec0 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_line.tsx +++ b/packages/charts/src/chart_types/xy_chart/renderer/dom/cursor_line.tsx @@ -12,12 +12,14 @@ import { connect } from 'react-redux'; import { Rect } from '../../../../geoms/types'; import { getTooltipType } from '../../../../specs'; import { TooltipType } from '../../../../specs/constants'; -import { GlobalChartState } from '../../../../state/chart_state'; +import { GlobalChartState, TooltipInteractionState } from '../../../../state/chart_state'; import { getChartRotationSelector } from '../../../../state/selectors/get_chart_rotation'; import { getChartThemeSelector } from '../../../../state/selectors/get_chart_theme'; import { getInternalIsInitializedSelector, InitStatus } from '../../../../state/selectors/get_internal_is_intialized'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { getTooltipSpecSelector } from '../../../../state/selectors/get_tooltip_spec'; +import { getInitialTooltipState } from '../../../../state/utils'; import { Rotation } from '../../../../utils/common'; import { LIGHT_THEME } from '../../../../utils/themes/light_theme'; import { Theme } from '../../../../utils/themes/theme'; @@ -25,15 +27,19 @@ import { getCursorBandPositionSelector } from '../../state/selectors/get_cursor_ interface CursorLineProps { theme: Theme; + isBrushing: boolean; chartRotation: Rotation; cursorPosition?: Rect; tooltipType: TooltipType; fromExternalEvent?: boolean; isLine: boolean; + tooltipState: TooltipInteractionState; } -function canRenderBand(type: TooltipType, visible: boolean, fromExternalEvent?: boolean) { - return visible && (type === TooltipType.Crosshairs || type === TooltipType.VerticalCursor || fromExternalEvent); +function canRenderBand(type: TooltipType, pinned: boolean, visible: boolean, fromExternalEvent?: boolean) { + return ( + pinned || (visible && (type === TooltipType.Crosshairs || type === TooltipType.VerticalCursor || fromExternalEvent)) + ); } class CursorLineComponent extends React.Component { @@ -44,13 +50,20 @@ class CursorLineComponent extends React.Component { theme: { crosshair: { band, line }, }, + isBrushing, cursorPosition, tooltipType, fromExternalEvent, isLine, + tooltipState: { pinned }, } = this.props; - if (!cursorPosition || !canRenderBand(tooltipType, band.visible, fromExternalEvent) || !isLine) { + if ( + isBrushing || + !cursorPosition || + !canRenderBand(tooltipType, pinned, band.visible, fromExternalEvent) || + !isLine + ) { return null; } const { x, y, width, height } = cursorPosition; @@ -67,10 +80,12 @@ class CursorLineComponent extends React.Component { const mapStateToProps = (state: GlobalChartState): CursorLineProps => { if (getInternalIsInitializedSelector(state) !== InitStatus.Initialized) { return { + isBrushing: false, theme: LIGHT_THEME, chartRotation: 0, tooltipType: TooltipType.None, isLine: false, + tooltipState: getInitialTooltipState(), }; } const settings = getSettingsSpecSelector(state); @@ -81,12 +96,14 @@ const mapStateToProps = (state: GlobalChartState): CursorLineProps => { const isLine = cursorBandPosition?.width === 0 || cursorBandPosition?.height === 0; return { + isBrushing: state.interactions.pointer.dragging, theme: getChartThemeSelector(state), chartRotation: getChartRotationSelector(state), cursorPosition: cursorBandPosition, tooltipType, fromExternalEvent, isLine, + tooltipState: getTooltipInteractionState(state), }; }; diff --git a/packages/charts/src/chart_types/xy_chart/renderer/dom/highlighter.tsx b/packages/charts/src/chart_types/xy_chart/renderer/dom/highlighter.tsx index 7d10482c99..abb2c0e3b0 100644 --- a/packages/charts/src/chart_types/xy_chart/renderer/dom/highlighter.tsx +++ b/packages/charts/src/chart_types/xy_chart/renderer/dom/highlighter.tsx @@ -28,6 +28,7 @@ interface HighlighterProps { initialized: boolean; chartId: string; zIndex: number; + isBrushing: boolean; highlightedGeometries: IndexedGeometry[]; chartTransform: Transform; chartDimensions: Dimensions; @@ -54,7 +55,8 @@ class HighlighterComponent extends React.Component { static displayName = 'Highlighter'; render() { - const { highlightedGeometries, chartDimensions, chartRotation, chartId, zIndex } = this.props; + const { highlightedGeometries, chartDimensions, chartRotation, chartId, zIndex, isBrushing } = this.props; + if (isBrushing) return null; const clipWidth = [90, -90].includes(chartRotation) ? chartDimensions.height : chartDimensions.width; const clipHeight = [90, -90].includes(chartRotation) ? chartDimensions.width : chartDimensions.height; const clipPathId = `echHighlighterClipPath__${chartId}`; @@ -116,6 +118,7 @@ const mapStateToProps = (state: GlobalChartState): HighlighterProps => { initialized: false, chartId, zIndex, + isBrushing: false, highlightedGeometries: [], chartTransform: { x: 0, @@ -131,6 +134,7 @@ const mapStateToProps = (state: GlobalChartState): HighlighterProps => { initialized: true, chartId, zIndex, + isBrushing: state.interactions.pointer.dragging, highlightedGeometries: getHighlightedGeomsSelector(state), chartTransform: computeChartTransformSelector(state), chartDimensions: computeChartDimensionsSelector(state).chartDimensions, diff --git a/packages/charts/src/chart_types/xy_chart/state/chart_state.interactions.test.tsx b/packages/charts/src/chart_types/xy_chart/state/chart_state.interactions.test.tsx index 7771fa0be5..a6895654dd 100644 --- a/packages/charts/src/chart_types/xy_chart/state/chart_state.interactions.test.tsx +++ b/packages/charts/src/chart_types/xy_chart/state/chart_state.interactions.test.tsx @@ -31,7 +31,7 @@ import { getCursorBandPositionSelector } from './selectors/get_cursor_band'; import { getProjectedPointerPositionSelector } from './selectors/get_projected_pointer_position'; import { getHighlightedGeomsSelector, - getTooltipInfoAndGeometriesSelector, + getHighlightedTooltipTooltipValuesSelector, } from './selectors/get_tooltip_values_highlighted_geoms'; import { isTooltipVisibleSelector } from './selectors/is_tooltip_visible'; import { createOnBrushEndCaller } from './selectors/on_brush_end_caller'; @@ -171,7 +171,7 @@ describe('Chart state pointer interactions', () => { }; MockStore.addSpecs([ordinalBarSeries, updatedSettings], store); store.dispatch(onPointerMove({ x: 10, y: 10 + 70 }, 0)); - const tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); // no tooltip values exist if we have a TooltipType === None expect(tooltipInfo.tooltip.values.length).toBe(0); let isTooltipVisible = isTooltipVisibleSelector(store.getState()); @@ -222,7 +222,7 @@ describe('Chart state pointer interactions', () => { onElementOverCaller(state); onPointerMoveCaller(state); }); - const tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values).toEqual([]); }); @@ -238,14 +238,14 @@ describe('Chart state pointer interactions', () => { MockStore.flush(store); expect(onPointerUpdateListener).toHaveBeenCalledTimes(1); - const tooltipInfo1 = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo1 = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo1.tooltip.values.length).toBe(1); // avoid calls store.dispatch(onPointerMove({ x: chartLeft + 12, y: chartTop + 12 }, 1)); MockStore.flush(store); expect(onPointerUpdateListener).toHaveBeenCalledTimes(1); - const tooltipInfo2 = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo2 = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo2.tooltip.values.length).toBe(1); expect(tooltipInfo1).toEqual(tooltipInfo2); }); @@ -256,14 +256,14 @@ describe('Chart state pointer interactions', () => { MockStore.flush(store); expect(onPointerUpdateListener).toHaveBeenCalledTimes(1); - const tooltipInfo1 = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo1 = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo1.tooltip.values.length).toBe(1); // avoid calls store.dispatch(onPointerMove({ x: chartLeft + 12, y: chartTop + 10 }, 1)); MockStore.flush(store); expect(onPointerUpdateListener).toHaveBeenCalledTimes(1); - const tooltipInfo2 = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo2 = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo2.tooltip.values.length).toBe(1); expect(tooltipInfo1).toEqual(tooltipInfo2); }); @@ -396,7 +396,7 @@ describe('Chart state pointer interactions', () => { }); test('can hover top-left corner of the first bar', () => { - let tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + let tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values).toEqual([]); store.dispatch(onPointerMove({ x: chartLeft + 0, y: chartTop + 0 }, 0)); let projectedPointerPosition = getProjectedPointerPositionSelector(store.getState()); @@ -407,7 +407,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); let isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(tooltipInfo.highlightedGeometries.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -437,7 +437,7 @@ describe('Chart state pointer interactions', () => { expect(projectedPointerPosition).toMatchObject({ x: -1, y: -1 }); isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(false); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values.length).toBe(0); expect(tooltipInfo.highlightedGeometries.length).toBe(0); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -454,7 +454,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); let isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - let tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + let tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(1); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -483,7 +483,7 @@ describe('Chart state pointer interactions', () => { expect(projectedPointerPosition).toMatchObject({ x: -1, y: 89 }); isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(false); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values.length).toBe(0); expect(tooltipInfo.highlightedGeometries.length).toBe(0); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -504,7 +504,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); let isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - let tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + let tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(1); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -538,7 +538,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(tooltipInfo.highlightedGeometries.length).toBe(0); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -559,7 +559,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); let isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - let tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + let tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(1); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -593,7 +593,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.values.length).toBe(1); // we are over the second bar here expect(tooltipInfo.highlightedGeometries.length).toBe(1); @@ -626,7 +626,7 @@ describe('Chart state pointer interactions', () => { test('can hover top-right corner of the chart', () => { expect(onOverListener).toHaveBeenCalledTimes(0); expect(onOutListener).toHaveBeenCalledTimes(0); - let tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + let tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(0); expect(tooltipInfo.tooltip.values.length).toBe(0); @@ -640,7 +640,7 @@ describe('Chart state pointer interactions', () => { const isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(0); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(0); @@ -692,7 +692,7 @@ describe('Chart state pointer interactions', () => { expect((cursorBandPosition as Rect).width).toBe(45); const isTooltipVisible = isTooltipVisibleSelector(store.getState()); expect(isTooltipVisible.visible).toBe(true); - const tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.highlightedGeometries.length).toBe(1); expect(tooltipInfo.tooltip.values.length).toBe(1); expect(onOverListener).toHaveBeenCalledTimes(1); @@ -782,7 +782,7 @@ describe('Chart state pointer interactions', () => { test('chart 0 rotation', () => { MockStore.addSpecs([spec, leftAxis, bottomAxis, currentSettingSpec], store); store.dispatch(onPointerMove({ x: chartLeft + 0, y: chartTop + 89 }, 0)); - const tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.header?.value).toBe(0); expect(tooltipInfo.tooltip.header?.formattedValue).toBe('bottom 0'); expect(tooltipInfo.tooltip.values[0].value).toBe(10); @@ -797,7 +797,7 @@ describe('Chart state pointer interactions', () => { MockStore.addSpecs([spec, leftAxis, bottomAxis, updatedSettings], store); store.dispatch(onPointerMove({ x: chartLeft + 0, y: chartTop + 89 }, 0)); - const tooltipInfo = getTooltipInfoAndGeometriesSelector(store.getState()); + const tooltipInfo = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(tooltipInfo.tooltip.header?.value).toBe(1); expect(tooltipInfo.tooltip.header?.formattedValue).toBe('left 1'); expect(tooltipInfo.tooltip.values[0].value).toBe(5); @@ -1380,7 +1380,7 @@ describe('Clickable annotations', () => { }); const tooltipValues = (s: Store) => - getTooltipInfoAndGeometriesSelector(s.getState()).tooltip.values.map((d) => [d.label, d.value]); + getHighlightedTooltipTooltipValuesSelector(s.getState()).tooltip.values.map((d) => [d.label, d.value]); it.each` type | stackMode | first | second | third diff --git a/packages/charts/src/chart_types/xy_chart/state/chart_state.tooltip.test.ts b/packages/charts/src/chart_types/xy_chart/state/chart_state.tooltip.test.ts index 20f830426b..20a5ed9ac3 100644 --- a/packages/charts/src/chart_types/xy_chart/state/chart_state.tooltip.test.ts +++ b/packages/charts/src/chart_types/xy_chart/state/chart_state.tooltip.test.ts @@ -14,7 +14,7 @@ import { updateParentDimensions } from '../../../state/actions/chart_settings'; import { onPointerMove } from '../../../state/actions/mouse'; import { upsertSpec, specParsed } from '../../../state/actions/specs'; import { GlobalChartState, chartStoreReducer } from '../../../state/chart_state'; -import { getTooltipInfoAndGeometriesSelector } from './selectors/get_tooltip_values_highlighted_geoms'; +import { getHighlightedTooltipTooltipValuesSelector } from './selectors/get_tooltip_values_highlighted_geoms'; describe('XYChart - State tooltips', () => { let store: Store; @@ -65,7 +65,7 @@ describe('XYChart - State tooltips', () => { ); store.dispatch(specParsed()); const state = store.getState(); - const tooltipValues = getTooltipInfoAndGeometriesSelector(state); + const tooltipValues = getHighlightedTooltipTooltipValuesSelector(state); expect(tooltipValues.tooltip.values).toHaveLength(expectedTooltipValuesLength); expect(tooltipValues.tooltip.header === null).toBe(expectHeader); expect(tooltipValues.highlightedGeometries).toHaveLength(expectedHgeomsLength); diff --git a/packages/charts/src/chart_types/xy_chart/state/chart_state.tsx b/packages/charts/src/chart_types/xy_chart/state/chart_state.tsx index bbd1dfd218..30d3405f57 100644 --- a/packages/charts/src/chart_types/xy_chart/state/chart_state.tsx +++ b/packages/charts/src/chart_types/xy_chart/state/chart_state.tsx @@ -29,7 +29,7 @@ import { getBrushAreaSelector } from './selectors/get_brush_area'; import { getChartTypeDescriptionSelector } from './selectors/get_chart_type_description'; import { getPointerCursorSelector } from './selectors/get_cursor_pointer'; import { getDebugStateSelector } from './selectors/get_debug_state'; -import { getHighlightedValuesSelector } from './selectors/get_highlighted_values'; +import { getLegendItemExtraValuesSelector } from './selectors/get_legend_item_extra_values'; import { getLegendItemsLabelsSelector } from './selectors/get_legend_items_labels'; import { getSeriesSpecsSelector } from './selectors/get_specs'; import { getTooltipAnchorPositionSelector } from './selectors/get_tooltip_anchor_position'; @@ -111,7 +111,7 @@ export class XYAxisChartState implements InternalChartState { } getLegendExtraValues(globalState: GlobalChartState): Map { - return getHighlightedValuesSelector(globalState); + return getLegendItemExtraValuesSelector(globalState); } chartRenderer(containerRef: BackwardRef, forwardCanvasRef: RefObject) { diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/get_cursor_pointer.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/get_cursor_pointer.ts index 7f176a59e1..4cefe0b385 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/get_cursor_pointer.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/get_cursor_pointer.ts @@ -6,6 +6,8 @@ * Side Public License, v 1. */ +import { CSSProperties } from 'react'; + import { DEFAULT_CSS_CURSOR } from '../../../../common/constants'; import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; @@ -17,6 +19,8 @@ import { getHighlightedGeomsSelector } from './get_tooltip_values_highlighted_ge import { isBrushAvailableSelector } from './is_brush_available'; const getCurrentPointerPositionSelector = (state: GlobalChartState) => state.interactions.pointer.current.position; +const getTooltipInteractionStateSelector = (state: GlobalChartState) => state.interactions.tooltip; +const getIsDragging = (state: GlobalChartState) => state.interactions.pointer.dragging; /** @internal */ export const getPointerCursorSelector = createCustomCachedSelector( @@ -28,6 +32,8 @@ export const getPointerCursorSelector = createCustomCachedSelector( computeChartDimensionsSelector, isBrushAvailableSelector, getAnnotationTooltipStateSelector, + getTooltipInteractionStateSelector, + getIsDragging, ], ( highlightedGeometries, @@ -37,12 +43,17 @@ export const getPointerCursorSelector = createCustomCachedSelector( { chartDimensions }, isBrushAvailable, annotationTooltipState, - ): string => { + tooltipState, + isDragging, + ): CSSProperties['cursor'] => { + if (tooltipState.pinned) return; const { x, y } = currentPointerPosition; // get positions relative to chart const xPos = x - chartDimensions.left; const yPos = y - chartDimensions.top; + if (isDragging) return 'crosshair'; + // limit cursorPosition to chartDimensions if (xPos < 0 || xPos >= chartDimensions.width || yPos < 0 || yPos >= chartDimensions.height) { return DEFAULT_CSS_CURSOR; diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/get_highlighted_values.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/get_legend_item_extra_values.ts similarity index 61% rename from packages/charts/src/chart_types/xy_chart/state/selectors/get_highlighted_values.ts rename to packages/charts/src/chart_types/xy_chart/state/selectors/get_legend_item_extra_values.ts index d6c53168e3..3ed29c0dce 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/get_highlighted_values.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/get_legend_item_extra_values.ts @@ -9,11 +9,11 @@ import { LegendItemExtraValues } from '../../../../common/legend'; import { SeriesKey } from '../../../../common/series_id'; import { createCustomCachedSelector } from '../../../../state/create_selector'; -import { getHighlightedValues } from '../../tooltip/tooltip'; -import { getTooltipInfoSelector } from './get_tooltip_values_highlighted_geoms'; +import { getLegendItemExtraValues } from '../../tooltip/tooltip'; +import { getTooltipInfoAndGeomsSelector } from './get_tooltip_values_highlighted_geoms'; /** @internal */ -export const getHighlightedValuesSelector = createCustomCachedSelector( - [getTooltipInfoSelector], - ({ values }): Map => getHighlightedValues(values), +export const getLegendItemExtraValuesSelector = createCustomCachedSelector( + [getTooltipInfoAndGeomsSelector], + ({ tooltip: { values } }): Map => getLegendItemExtraValues(values), ); diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/get_projected_pointer_position.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/get_projected_pointer_position.ts index eed6513da3..58654c880d 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/get_projected_pointer_position.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/get_projected_pointer_position.ts @@ -7,24 +7,23 @@ */ import { ScaleBand } from '../../../../scales/scale_band'; -import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getActivePointerPosition } from '../../../../state/selectors/get_active_pointer_position'; import { Dimensions } from '../../../../utils/dimensions'; import { Point } from '../../../../utils/point'; import { PrimitiveValue } from '../../../partition_chart/layout/utils/group_by_rollup'; import { computeChartDimensionsSelector } from './compute_chart_dimensions'; import { computeSmallMultipleScalesSelector, SmallMultipleScales } from './compute_small_multiple_scales'; -const getCurrentPointerPosition = (state: GlobalChartState) => state.interactions.pointer.current.position; - /** @internal */ export type PointerPosition = Point & { horizontalPanelValue: PrimitiveValue; verticalPanelValue: PrimitiveValue }; + /** * Get the x and y pointer position relative to the chart projection area * @internal */ export const getProjectedPointerPositionSelector = createCustomCachedSelector( - [getCurrentPointerPosition, computeChartDimensionsSelector, computeSmallMultipleScalesSelector], + [getActivePointerPosition, computeChartDimensionsSelector, computeSmallMultipleScalesSelector], (currentPointerPosition, { chartDimensions }, smallMultipleScales): PointerPosition => getProjectedPointerPosition(currentPointerPosition, chartDimensions, smallMultipleScales), ); diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.test.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.test.ts index 9d0403452e..2cc0e49545 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.test.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.test.ts @@ -13,7 +13,7 @@ import { MockStore } from '../../../../mocks/store/store'; import { ScaleType } from '../../../../scales/constants'; import { onPointerMove } from '../../../../state/actions/mouse'; import { GlobalChartState } from '../../../../state/chart_state'; -import { getTooltipInfoAndGeometriesSelector } from './get_tooltip_values_highlighted_geoms'; +import { getHighlightedTooltipTooltipValuesSelector } from './get_tooltip_values_highlighted_geoms'; describe('Highlight points', () => { describe('On Ordinal area chart', () => { @@ -37,12 +37,12 @@ describe('Highlight points', () => { }); it('On ordinal area chart, it should correctly highlight points', () => { store.dispatch(onPointerMove({ x: 50, y: 100 }, 0)); - const { highlightedGeometries } = getTooltipInfoAndGeometriesSelector(store.getState()); + const { highlightedGeometries } = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(highlightedGeometries).toHaveLength(1); }); it('On ordinal area chart, it should not highlight points if not within the buffer', () => { store.dispatch(onPointerMove({ x: 5, y: 100 }, 0)); - const { highlightedGeometries } = getTooltipInfoAndGeometriesSelector(store.getState()); + const { highlightedGeometries } = getHighlightedTooltipTooltipValuesSelector(store.getState()); expect(highlightedGeometries).toHaveLength(0); }); }); diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.ts index f008dd4cc8..26608305e5 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/get_tooltip_values_highlighted_geoms.ts @@ -21,6 +21,7 @@ import { GlobalChartState } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; import { getChartRotationSelector } from '../../../../state/selectors/get_chart_rotation'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { getTooltipSpecSelector } from '../../../../state/selectors/get_tooltip_spec'; import { isNil, Rotation } from '../../../../utils/common'; import { isValidPointerOverEvent } from '../../../../utils/events'; @@ -59,7 +60,7 @@ export interface TooltipAndHighlightedGeoms { const getExternalPointerEventStateSelector = (state: GlobalChartState) => state.externalEvents.pointer; /** @internal */ -export const getTooltipInfoAndGeometriesSelector = createCustomCachedSelector( +export const getTooltipInfoAndGeomsSelector = createCustomCachedSelector( [ getSeriesSpecsSelector, getAxisSpecsSelector, @@ -158,12 +159,6 @@ function getTooltipAndHighlightFromValue( highlightedGeometries.push(indexedGeometry); } - // if it's a follow tooltip, and no element is highlighted - // do _not_ add element into tooltip list - if (!isHighlighted && isFollowTooltipType(tooltipType)) { - return acc; - } - // format the tooltip values const formattedTooltip = formatTooltip(indexedGeometry, spec, false, isHighlighted, hasSingleSeries, yAxis); @@ -203,14 +198,35 @@ function getTooltipAndHighlightFromValue( }; } +/** @internal */ +export const getHighlightedTooltipTooltipValuesSelector = createCustomCachedSelector( + [getTooltipInteractionState, getTooltipInfoAndGeomsSelector, getTooltipSpecSelector, getSettingsSpecSelector], + ({ pinned }, values, tooltip, settings): TooltipAndHighlightedGeoms => { + const tooltipType = getTooltipType(tooltip, settings); + const highlightedValues = values.tooltip.values.filter((v) => v.isHighlighted); + const hasTooltipContent = values.tooltip.values.length > tooltip.maxTooltipItems && highlightedValues.length > 0; + + if (!pinned && (isFollowTooltipType(tooltipType) || hasTooltipContent)) { + return { + ...values, + tooltip: { + ...values.tooltip, + values: highlightedValues, + }, + }; + } + return values; + }, +); + /** @internal */ export const getTooltipInfoSelector = createCustomCachedSelector( - [getTooltipInfoAndGeometriesSelector], + [getHighlightedTooltipTooltipValuesSelector], ({ tooltip }): TooltipInfo => tooltip, ); /** @internal */ export const getHighlightedGeomsSelector = createCustomCachedSelector( - [getTooltipInfoAndGeometriesSelector], + [getHighlightedTooltipTooltipValuesSelector], ({ highlightedGeometries }): IndexedGeometry[] => highlightedGeometries, ); diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/is_tooltip_visible.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/is_tooltip_visible.ts index 28e6d6c59b..e149276493 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/is_tooltip_visible.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/is_tooltip_visible.ts @@ -6,27 +6,25 @@ * Side Public License, v 1. */ -import { TooltipInfo } from '../../../../components/tooltip/types'; import { TooltipType } from '../../../../specs/constants'; -import { GlobalChartState, PointerStates } from '../../../../state/chart_state'; +import { InteractionsState, TooltipVisibility } from '../../../../state/chart_state'; import { createCustomCachedSelector } from '../../../../state/create_selector'; +import { getTooltipInteractionState } from '../../../../state/selectors/get_tooltip_interaction_state'; import { isExternalTooltipVisibleSelector } from '../../../../state/selectors/is_external_tooltip_visible'; import { Point } from '../../../../utils/point'; -import { TooltipSpec } from './../../../../specs/tooltip'; +import { isFollowTooltipType, TooltipSpec } from './../../../../specs/tooltip'; import { getTooltipSpecSelector } from './../../../../state/selectors/get_tooltip_spec'; import { getProjectedPointerPositionSelector } from './get_projected_pointer_position'; -import { getTooltipInfoSelector } from './get_tooltip_values_highlighted_geoms'; +import { getTooltipInfoAndGeomsSelector, TooltipAndHighlightedGeoms } from './get_tooltip_values_highlighted_geoms'; import { isAnnotationTooltipVisibleSelector } from './is_annotation_tooltip_visible'; -const getPointerSelector = (state: GlobalChartState) => state.interactions.pointer; - /** @internal */ export const isTooltipVisibleSelector = createCustomCachedSelector( [ getTooltipSpecSelector, - getPointerSelector, + getTooltipInteractionState, getProjectedPointerPositionSelector, - getTooltipInfoSelector, + getTooltipInfoAndGeomsSelector, isAnnotationTooltipVisibleSelector, isExternalTooltipVisibleSelector, ], @@ -34,23 +32,30 @@ export const isTooltipVisibleSelector = createCustomCachedSelector( ); function isTooltipVisible( - { type: tooltipType }: TooltipSpec, - pointer: PointerStates, + { type: tooltipType, maxTooltipItems }: TooltipSpec, + { pinned }: InteractionsState['tooltip'], projectedPointerPosition: Point, - tooltip: TooltipInfo, + { tooltip, highlightedGeometries }: TooltipAndHighlightedGeoms, isAnnotationTooltipVisible: boolean, externalTooltipVisible: boolean, -) { +): TooltipVisibility { + const visibleTooltip = isFollowTooltipType(tooltipType) + ? highlightedGeometries + : tooltip.values.length > maxTooltipItems && highlightedGeometries.length > 0 + ? highlightedGeometries + : tooltip.values; const isLocalTooltip = tooltipType !== TooltipType.None && - pointer.down === null && projectedPointerPosition.x > -1 && projectedPointerPosition.y > -1 && - tooltip.values.length > 0 && + visibleTooltip.length > 0 && !isAnnotationTooltipVisible; - const isExternalTooltip = externalTooltipVisible && tooltip.values.length > 0; + const isExternalTooltip = externalTooltipVisible && visibleTooltip.length > 0; + return { - visible: isLocalTooltip || isExternalTooltip, + visible: isLocalTooltip || isExternalTooltip || pinned, isExternal: externalTooltipVisible, + displayOnly: false, + isPinnable: tooltip.values.length > 0, }; } diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_out_caller.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_out_caller.ts index 683c83846c..155b4f2530 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_out_caller.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_out_caller.ts @@ -15,7 +15,7 @@ import { createCustomCachedSelector } from '../../../../state/create_selector'; import { getSettingsSpecSelector } from '../../../../state/selectors/get_settings_spec'; import { IndexedGeometry } from '../../../../utils/geometry'; import { - getTooltipInfoAndGeometriesSelector, + getHighlightedTooltipTooltipValuesSelector, TooltipAndHighlightedGeoms, } from './get_tooltip_values_highlighted_geoms'; @@ -44,7 +44,7 @@ export function createOnElementOutCaller(): (state: GlobalChartState) => void { return (state: GlobalChartState) => { if (selector === null && state.chartType === ChartType.XYAxis) { selector = createCustomCachedSelector( - [getTooltipInfoAndGeometriesSelector, getSettingsSpecSelector], + [getHighlightedTooltipTooltipValuesSelector, getSettingsSpecSelector], ({ highlightedGeometries }: TooltipAndHighlightedGeoms, settings: SettingsSpec): void => { const nextProps = { settings, diff --git a/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_over_caller.ts b/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_over_caller.ts index 0117707be2..10fadb997d 100644 --- a/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_over_caller.ts +++ b/packages/charts/src/chart_types/xy_chart/state/selectors/on_element_over_caller.ts @@ -16,7 +16,7 @@ import { getSettingsSpecSelector } from '../../../../state/selectors/get_setting import { IndexedGeometry, GeometryValue } from '../../../../utils/geometry'; import { XYChartSeriesIdentifier } from '../../utils/series'; import { - getTooltipInfoAndGeometriesSelector, + getHighlightedTooltipTooltipValuesSelector, TooltipAndHighlightedGeoms, } from './get_tooltip_values_highlighted_geoms'; @@ -53,7 +53,7 @@ export function createOnElementOverCaller(): (state: GlobalChartState) => void { return (state: GlobalChartState) => { if (selector === null && state.chartType === ChartType.XYAxis) { selector = createCustomCachedSelector( - [getTooltipInfoAndGeometriesSelector, getSettingsSpecSelector], + [getHighlightedTooltipTooltipValuesSelector, getSettingsSpecSelector], ({ highlightedGeometries }: TooltipAndHighlightedGeoms, settings: SettingsSpec): void => { const nextProps = { settings, diff --git a/packages/charts/src/chart_types/xy_chart/tooltip/tooltip.ts b/packages/charts/src/chart_types/xy_chart/tooltip/tooltip.ts index 336a0aabad..df5b9f4606 100644 --- a/packages/charts/src/chart_types/xy_chart/tooltip/tooltip.ts +++ b/packages/charts/src/chart_types/xy_chart/tooltip/tooltip.ts @@ -22,7 +22,7 @@ export const Y0_ACCESSOR_POSTFIX = ' - lower'; export const Y1_ACCESSOR_POSTFIX = ' - upper'; /** @internal */ -export function getHighlightedValues( +export function getLegendItemExtraValues( tooltipValues: TooltipValue[], defaultValue?: string, ): Map { diff --git a/packages/charts/src/common/constants.ts b/packages/charts/src/common/constants.ts index 7528b1613e..29627784fb 100644 --- a/packages/charts/src/common/constants.ts +++ b/packages/charts/src/common/constants.ts @@ -7,7 +7,7 @@ */ /** @internal */ -export const DEFAULT_CSS_CURSOR = 'default'; +export const DEFAULT_CSS_CURSOR = undefined; /** @internal */ export const TAU = 2 * Math.PI; /** @internal */ @@ -27,3 +27,8 @@ export const RIGHT = 'right' as const; export const MIDDLE = 'middle' as const; /** @public */ export const CENTER = 'center' as const; + +/** @internal + * Value used to describe the secondary button (usually the right button) on a `MouseEvent.button` + */ +export const SECONDARY_BUTTON = 2; diff --git a/packages/charts/src/common/hooks/use_render_skip.ts b/packages/charts/src/common/hooks/use_render_skip.ts new file mode 100644 index 0000000000..d24c4e0010 --- /dev/null +++ b/packages/charts/src/common/hooks/use_render_skip.ts @@ -0,0 +1,26 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { useEffect, useState } from 'react'; + +/** + * Helper hook to skips n renders + * @internal + */ +export function useRenderSkip(rendersToSkip: number = 1) { + const [renderCount, setRenderCount] = useState(0); + useEffect( + () => { + if (renderCount >= rendersToSkip) return; + setRenderCount((n) => n + 1); + }, + // eslint-disable-next-line react-hooks/exhaustive-deps + rendersToSkip === 1 ? [] : undefined, + ); + return renderCount >= rendersToSkip; +} diff --git a/packages/charts/src/components/__snapshots__/chart.test.tsx.snap b/packages/charts/src/components/__snapshots__/chart.test.tsx.snap index f683a80d9a..d7246242a6 100644 --- a/packages/charts/src/components/__snapshots__/chart.test.tsx.snap +++ b/packages/charts/src/components/__snapshots__/chart.test.tsx.snap @@ -20,7 +20,7 @@ exports[`Chart should render the legend name test 1`] = ` - +
    @@ -61,10 +61,10 @@ exports[`Chart should render the legend name test 1`] = `
    - -
    + +
    - + @@ -92,13 +92,13 @@ exports[`Chart should render the legend name test 1`] = ` - + - + @@ -106,7 +106,7 @@ exports[`Chart should render the legend name test 1`] = ` - + diff --git a/packages/charts/src/components/_index.scss b/packages/charts/src/components/_index.scss index 96aa10c069..ce2091babf 100644 --- a/packages/charts/src/components/_index.scss +++ b/packages/charts/src/components/_index.scss @@ -1,7 +1,7 @@ @import 'global'; @import 'container'; @import 'brush/index'; -@import 'tooltip/index'; +@import 'tooltip/components/index'; @import 'portal/index'; @import 'icons/index'; @import 'legend/index'; diff --git a/packages/charts/src/components/chart_container.tsx b/packages/charts/src/components/chart_container.tsx index 5a0799405d..060ea4aeb3 100644 --- a/packages/charts/src/components/chart_container.tsx +++ b/packages/charts/src/components/chart_container.tsx @@ -6,25 +6,29 @@ * Side Public License, v 1. */ -import React from 'react'; +import React, { CSSProperties } from 'react'; import { connect } from 'react-redux'; import { bindActionCreators, Dispatch } from 'redux'; -import { DEFAULT_CSS_CURSOR } from '../common/constants'; -import { SettingsSpec } from '../specs'; +import { ChartType } from '../chart_types'; +import { DEFAULT_CSS_CURSOR, SECONDARY_BUTTON } from '../common/constants'; +import { SettingsSpec, TooltipSpec } from '../specs'; import { onKeyPress as onKeyPressAction } from '../state/actions/key'; import { onMouseUp as onMouseUpAction, onMouseDown as onMouseDownAction, onPointerMove as onPointerMoveAction, } from '../state/actions/mouse'; -import { GlobalChartState, BackwardRef } from '../state/chart_state'; +import { pinTooltip as pinTooltipAction } from '../state/actions/tooltip'; +import { GlobalChartState, BackwardRef, TooltipInteractionState } from '../state/chart_state'; +import { isPinnableTooltip } from '../state/selectors/can_pin_tooltip'; import { getInternalChartRendererSelector } from '../state/selectors/get_chart_type_components'; import { getInternalPointerCursor } from '../state/selectors/get_internal_cursor_pointer'; import { getInternalIsBrushingSelector } from '../state/selectors/get_internal_is_brushing'; import { getInternalIsBrushingAvailableSelector } from '../state/selectors/get_internal_is_brushing_available'; import { getInternalIsInitializedSelector, InitStatus } from '../state/selectors/get_internal_is_intialized'; import { getSettingsSpecSelector } from '../state/selectors/get_settings_spec'; +import { getTooltipSpecSelector } from '../state/selectors/get_tooltip_spec'; import { isInternalChartEmptySelector } from '../state/selectors/is_chart_empty'; import { deepEqual } from '../utils/fast_deep_equal'; import { NoResults } from './no_results'; @@ -32,11 +36,15 @@ import { NoResults } from './no_results'; interface ChartContainerComponentStateProps { status: InitStatus; isChartEmpty?: boolean; - pointerCursor: string; + pointerCursor: CSSProperties['cursor']; isBrushing: boolean; + tooltipState: TooltipInteractionState; initialized?: boolean; + canPinTooltip: boolean; isBrushingAvailable: boolean; settings?: SettingsSpec; + tooltip: TooltipSpec; + disableInteractions: boolean; internalChartRenderer: ( containerRef: BackwardRef, forwardStageRef: React.RefObject, @@ -47,6 +55,7 @@ interface ChartContainerComponentDispatchProps { onMouseUp: typeof onMouseUpAction; onMouseDown: typeof onMouseDownAction; onKeyPress: typeof onKeyPressAction; + pinTooltip: typeof pinTooltipAction; } interface ChartContainerComponentOwnProps { @@ -60,6 +69,7 @@ type ReactiveChartProps = ChartContainerComponentStateProps & class ChartContainerComponent extends React.Component { static displayName = 'ChartContainer'; + static watchedKeys: KeyboardEvent['key'][] = ['Escape']; shouldComponentUpdate(nextProps: ReactiveChartProps) { return !deepEqual(this.props, nextProps); @@ -68,8 +78,8 @@ class ChartContainerComponent extends React.Component { handleMouseMove = ({ nativeEvent: { offsetX, offsetY, timeStamp }, }: React.MouseEvent) => { - const { isChartEmpty, onPointerMove, internalChartRenderer } = this.props; - if (isChartEmpty || internalChartRenderer.name === 'FlameWithTooltip') { + const { isChartEmpty, disableInteractions, onPointerMove, internalChartRenderer } = this.props; + if (isChartEmpty || disableInteractions || internalChartRenderer.name === 'FlameWithTooltip') { // Flame chart does its own event handling, and panning temporarily attaches // an event handler onto `window`. So this `chart_container.handleMouseMove` // can not be avoided with `e.stopPropagation()`. So we should avoid emission @@ -86,23 +96,20 @@ class ChartContainerComponent extends React.Component { }; handleMouseLeave = ({ nativeEvent: { timeStamp } }: React.MouseEvent) => { - const { isChartEmpty, onPointerMove, isBrushing } = this.props; - if (isChartEmpty) { - return; - } - if (isBrushing) { + const { isChartEmpty, disableInteractions, onPointerMove, isBrushing } = this.props; + if (isChartEmpty || disableInteractions || isBrushing) { return; } onPointerMove({ x: -1, y: -1 }, timeStamp); }; handleMouseDown = ({ - nativeEvent: { offsetX, offsetY, timeStamp }, + nativeEvent: { offsetX, offsetY, timeStamp, button, ctrlKey }, }: React.MouseEvent) => { - const { isChartEmpty, onMouseDown, isBrushingAvailable } = this.props; - if (isChartEmpty) { - return; - } + const { isChartEmpty, disableInteractions, onMouseDown, isBrushingAvailable, tooltipState } = this.props; + + // button 2 to block brushing on right click + if (tooltipState.pinned || button === SECONDARY_BUTTON || ctrlKey || isChartEmpty || disableInteractions) return; if (isBrushingAvailable) { window.addEventListener('mouseup', this.handleBrushEnd); @@ -119,9 +126,38 @@ class ChartContainerComponent extends React.Component { ); }; + handleUnpinningTooltip = () => { + window.removeEventListener('keyup', this.handleKeyUp); + window.removeEventListener('click', this.handleUnpinningTooltip); + window.removeEventListener('scroll', this.handleUnpinningTooltip); + window.removeEventListener('visibilitychange', this.handleUnpinningTooltip); + this.props.pinTooltip(false, true); + }; + + handleContextMenu = (e: React.MouseEvent) => { + const { isChartEmpty, disableInteractions, tooltipState } = this.props; + if (isChartEmpty || disableInteractions) { + return; + } + + e.preventDefault(); // prevent browser context menu + + if (tooltipState.pinned) { + this.handleUnpinningTooltip(); + return; + } + + window.addEventListener('keyup', this.handleKeyUp); + window.addEventListener('click', this.handleUnpinningTooltip); + window.addEventListener('scroll', this.handleUnpinningTooltip); + window.addEventListener('visibilitychange', this.handleUnpinningTooltip); + + this.props.pinTooltip(true); + }; + handleMouseUp = ({ nativeEvent: { offsetX, offsetY, timeStamp } }: React.MouseEvent) => { - const { isChartEmpty, onMouseUp } = this.props; - if (isChartEmpty) { + const { isChartEmpty, disableInteractions, onMouseUp, tooltipState } = this.props; + if (tooltipState.pinned || isChartEmpty || disableInteractions) { return; } @@ -137,10 +173,12 @@ class ChartContainerComponent extends React.Component { }; handleKeyUp = ({ key }: KeyboardEvent) => { + if (!ChartContainerComponent.watchedKeys.includes(key)) return; + window.removeEventListener('keyup', this.handleKeyUp); - const { isChartEmpty, onKeyPress } = this.props; - if (isChartEmpty) { + const { isChartEmpty, disableInteractions, onKeyPress } = this.props; + if (isChartEmpty || disableInteractions) { return; } @@ -172,6 +210,7 @@ class ChartContainerComponent extends React.Component { } const { pointerCursor, internalChartRenderer, getChartContainerRef, forwardStageRef } = this.props; + return (
    { onMouseLeave={this.handleMouseLeave} onMouseDown={this.handleMouseDown} onMouseUp={this.handleMouseUp} + onContextMenu={this.props.canPinTooltip ? this.handleContextMenu : undefined} > {internalChartRenderer(getChartContainerRef, forwardStageRef)}
    @@ -196,35 +236,46 @@ const mapDispatchToProps = (dispatch: Dispatch): ChartContainerComponentDispatch onMouseUp: onMouseUpAction, onMouseDown: onMouseDownAction, onKeyPress: onKeyPressAction, + pinTooltip: pinTooltipAction, }, dispatch, ); const mapStateToProps = (state: GlobalChartState): ChartContainerComponentStateProps => { const status = getInternalIsInitializedSelector(state); const settings = getSettingsSpecSelector(state); + const tooltip = getTooltipSpecSelector(state); const initialized = !state.specParsing && state.specsInitialized; + const tooltipState = state.interactions.tooltip; if (status !== InitStatus.Initialized) { return { status, initialized, + tooltipState, + canPinTooltip: false, pointerCursor: DEFAULT_CSS_CURSOR, isBrushingAvailable: false, isBrushing: false, internalChartRenderer: () => null, settings, + tooltip, + disableInteractions: false, }; } return { status, initialized, + tooltipState, isChartEmpty: isInternalChartEmptySelector(state), + canPinTooltip: isPinnableTooltip(state), pointerCursor: getInternalPointerCursor(state), isBrushingAvailable: getInternalIsBrushingAvailableSelector(state), isBrushing: getInternalIsBrushingSelector(state), internalChartRenderer: getInternalChartRendererSelector(state), settings, + tooltip, + disableInteractions: state.chartType === ChartType.Flame, }; }; diff --git a/packages/charts/src/components/legend/_legend.scss b/packages/charts/src/components/legend/_legend.scss index 9ab2247e30..353b8fa418 100644 --- a/packages/charts/src/components/legend/_legend.scss +++ b/packages/charts/src/components/legend/_legend.scss @@ -31,6 +31,10 @@ position: relative; } + &--inert { + pointer-events: none; + } + .echLegendListContainer { @include euiYScrollWithShadows; width: 100%; diff --git a/packages/charts/src/components/legend/label.tsx b/packages/charts/src/components/legend/label.tsx index f97668e71b..dd61c54e94 100644 --- a/packages/charts/src/components/legend/label.tsx +++ b/packages/charts/src/components/legend/label.tsx @@ -19,6 +19,7 @@ interface LabelProps { onToggle?: (negate: boolean) => void; options: LegendLabelOptions; } + /** * Label component used to display text in legend item * @internal diff --git a/packages/charts/src/components/legend/legend.tsx b/packages/charts/src/components/legend/legend.tsx index 65dc0b31be..204de752d1 100644 --- a/packages/charts/src/components/legend/legend.tsx +++ b/packages/charts/src/components/legend/legend.tsx @@ -39,6 +39,7 @@ import { getLegendStyle, getLegendListStyle } from './style_utils'; interface LegendStateProps { debug: boolean; + isBrushing: boolean; chartDimensions: Dimensions; containerDimensions: Dimensions; chartTheme: Theme; @@ -62,6 +63,7 @@ function LegendComponent(props: LegendStateProps & LegendDispatchProps) { items, size, debug, + isBrushing, chartTheme: { chartMargins, legend }, chartDimensions, containerDimensions, @@ -79,6 +81,7 @@ function LegendComponent(props: LegendStateProps & LegendDispatchProps) { const legendClasses = classNames('echLegend', { 'echLegend--debug': debug, + 'echLegend--inert': isBrushing, 'echLegend--horizontal': positionConfig.direction === LayoutDirection.Horizontal, 'echLegend--vertical': positionConfig.direction === LayoutDirection.Vertical, 'echLegend--left': positionConfig.hAlign === HorizontalAlignment.Left, @@ -137,6 +140,7 @@ const EMPTY_DEFAULT_STATE: LegendStateProps = { items: [], extraValues: new Map(), debug: false, + isBrushing: false, chartTheme: LIGHT_THEME, size: { width: 0, height: 0 }, config: DEFAULT_LEGEND_CONFIG, @@ -153,6 +157,7 @@ const mapStateToProps = (state: GlobalChartState): LegendStateProps => { const { debug } = getSettingsSpecSelector(state); return { debug, + isBrushing: state.interactions.pointer.dragging, chartDimensions: getInternalMainProjectionAreaSelector(state), containerDimensions: getInternalProjectionContainerAreaSelector(state), chartTheme: getChartThemeSelector(state), diff --git a/packages/charts/src/components/portal/tooltip_portal.tsx b/packages/charts/src/components/portal/tooltip_portal.tsx index 852031cc8d..858a9ad88f 100644 --- a/packages/charts/src/components/portal/tooltip_portal.tsx +++ b/packages/charts/src/components/portal/tooltip_portal.tsx @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import { createPopper, Instance } from '@popperjs/core'; +import { createPopper, Instance, Placement as PopperPlacement } from '@popperjs/core'; import { ReactNode, useCallback, useEffect, useMemo, useRef } from 'react'; import { createPortal } from 'react-dom'; @@ -44,6 +44,11 @@ type PortalTooltipProps = { * Chart Id to add new anchor for each chart on the page */ chartId: string; + + /** + * Called when computed placement changes + */ + onPlacementChange?: (placement: PopperPlacement) => void; }; function addToPadding(padding: Partial | number = 0, extra: number = 0): Padding | number | undefined { @@ -67,7 +72,9 @@ const TooltipPortalComponent = ({ visible, chartId, zIndex, + onPlacementChange, }: PortalTooltipProps) => { + const finalPlacement = useRef('auto'); const skipPositioning = isHTMLElement((anchor as PortalAnchorRef).current); const { position } = anchor as PositionedPortalAnchorRef; @@ -147,6 +154,17 @@ const TooltipPortalComponent = ({ padding: addToPadding(boundaryPadding, offset), }, }, + { + name: 'reportPlacement', + phase: 'afterWrite', + enabled: Boolean(onPlacementChange), + fn: ({ state }) => { + if (finalPlacement.current !== state.placement) { + finalPlacement.current = state.placement; + onPlacementChange?.(state.placement); + } + }, + }, ], }); // eslint-disable-next-line react-hooks/exhaustive-deps diff --git a/packages/charts/src/components/tooltip/_index.scss b/packages/charts/src/components/tooltip/_index.scss deleted file mode 100644 index 0a06e6f1bb..0000000000 --- a/packages/charts/src/components/tooltip/_index.scss +++ /dev/null @@ -1 +0,0 @@ -@import 'tooltip'; diff --git a/packages/charts/src/components/tooltip/_tooltip.scss b/packages/charts/src/components/tooltip/_tooltip.scss deleted file mode 100644 index 8bac8b91de..0000000000 --- a/packages/charts/src/components/tooltip/_tooltip.scss +++ /dev/null @@ -1,160 +0,0 @@ -@import '../mixins'; - -$tooltipBorderColor: $euiColorLightShade; -$tooltipBorderWidth: 1px; -$rowColorStripWidth: 5px; -$maxRowColorStripWidth: 8px; -$rowColorStripAnimatedWidthDelta: 3px; - -.echTooltip { - @include euiToolTipStyle; - @include euiFontSizeXS; - padding: 0; - transition: opacity $euiAnimSpeedNormal; - pointer-events: none; - user-select: none; - max-width: 256px; - background-color: $euiColorEmptyShade; - color: $euiTextColor; - overflow: hidden; - - & > :not(:last-child) { - border-bottom: solid $tooltipBorderWidth $tooltipBorderColor; - } - - .euiTable { - background-color: transparent; - } - - .euiTableFooterCell, - .euiTableHeaderCell, - .euiTableRowCell { - color: white; - } - - &__list { - &--scrollable { - overflow-y: auto; - pointer-events: auto; - } - } - - &__divider { - border-bottom: solid $tooltipBorderWidth $tooltipBorderColor; - } - - &__metricRow { - padding: $euiSizeXS ($euiSizeXS * 2); - display: flex; - justify-content: space-between; - } - - &__header { - font-weight: $euiFontWeightBold; - margin-bottom: 0; - padding: $euiSizeXS ($euiSizeXS * 2); - } - - &__footer { - font-weight: $euiFontWeightBold; - border-top: solid $tooltipBorderWidth $tooltipBorderColor; - margin-top: 0; - padding: $euiSizeXS ($euiSizeXS * 2); - } - - &__stickyAction { - color: #69707d; - padding: $euiSizeS; - margin-left: $rowColorStripWidth; - } - - &__table { - width: 100%; - - &--scrollable { - overflow-y: auto; - pointer-events: auto; - } - } - - &__tableHeader { - font-weight: $euiFontWeightBold; - margin-bottom: 0; - border-bottom: solid $tooltipBorderWidth $tooltipBorderColor; - } - - &__tableCell:not(.echTooltip__colorCell) { - padding: 4px; - } - - &__tableBody { - td:not(.echTooltip__colorCell) { - padding: 2px 4px; - } - } - - &__tableFooter { - border-top: solid $tooltipBorderWidth $tooltipBorderColor; - font-weight: $euiFontWeightBold; - margin-top: 0; - } - - &__tableRow { - position: relative; - - &--highlighted { - background-color: transparentize($euiColorLightShade, 0.5); - - // TODO save this for future sticky interactions - // .echTooltip__colorStrip { - // width: $rowColorStripWidth + $rowColorStripAnimatedWidthDelta; - // } - } - } - - &__colorCell { - padding: 0; - height: 100%; - position: relative; - - &--empty { - width: 0; - } - } - - &__colorStrip { - position: absolute; - top: 0; - left: 0; - bottom: 0; - width: $rowColorStripWidth; - min-width: $rowColorStripWidth; - max-width: $maxRowColorStripWidth; - transition: width 200ms; - } - - &__colorStripSpacer { - width: $maxRowColorStripWidth; - } - - &__label { - @include wrapText; - min-width: 1px; - flex: 1 1 auto; - text-align: left; - } - - &__value { - text-align: right; - font-feature-settings: 'tnum'; - } - - &[dir='rtl'] { - .echTooltip { - &__colorStrip { - left: auto; - right: 0; - } - } - } -} diff --git a/packages/charts/src/components/tooltip/components/_index.scss b/packages/charts/src/components/tooltip/components/_index.scss new file mode 100644 index 0000000000..de114c19ef --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_index.scss @@ -0,0 +1,6 @@ +@import 'tooltip'; +@import 'tooltip_header'; +@import 'tooltip_footer'; +@import 'tooltip_divider'; +@import 'tooltip_prompt'; +@import 'tooltip_actions'; diff --git a/packages/charts/src/components/tooltip/components/_tooltip.scss b/packages/charts/src/components/tooltip/components/_tooltip.scss new file mode 100644 index 0000000000..4641424616 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip.scss @@ -0,0 +1,236 @@ +@import '../../mixins'; + +$tooltipBorderColor: $euiColorLightShade; +$tooltipBorderWidth: 1px; +$rowColorStripWidth: 5px; +/** + * Manually synced with `MAX_ROW_COLOR_STRIP_WIDTH` const in [`tooltip_table.tsx`](packages/charts/src/components/tooltip/components/tooltip_table.tsx) + */ +$maxRowColorStripWidth: 11px; + +$tableBorder: solid $tooltipBorderWidth $tooltipBorderColor; + +$tableRowHoverColor: transparentize($euiColorPrimary, 0.95); +$tableRowSelectedColor: tintOrShade($euiFocusBackgroundColor, 0, 10%); +$tableRowHoverSelectedColor: tintOrShade($euiFocusBackgroundColor, 0, 10%); + +.echTooltip { + @include euiToolTipStyle; + @include euiFontSizeXS; + padding: 0; + max-width: 100%; + pointer-events: none; + user-select: none; + background-color: $euiColorEmptyShade; + color: $euiTextColor; + overflow: hidden; + cursor: default; + transition: box-shadow 400ms, opacity $euiAnimSpeedNormal; + border: 1px solid $euiColorEmptyShade; + + &__outerWrapper { + display: flex; + } + + &--pinned { + @include euiBottomShadowSmall; + pointer-events: auto; + user-select: auto; + + .echTooltip__tableRow--selectable { + cursor: pointer; + } + + .echTooltipActions { + pointer-events: auto; + } + .echTooltip__tableWrapper { + pointer-events: auto; + } + } + + .echTooltip__tableCell--truncate { + @include euiTextTruncate; + } + + &__metricRow { + padding: $euiSizeXS ($euiSizeXS * 2); + display: flex; + justify-content: space-between; + } + + &__tableWrapper { + overflow: auto; + @include euiScrollBar; + background-color: $euiColorEmptyShade; + } + + &__table { + display: grid; + width: 100%; + + &--noGrid { + display: table; + } + } + + &__tableHeader, + &__tableFooter { + .echTooltip__tableCell { + cursor: default; + font-weight: $euiFontWeightBold; + background-color: $euiColorEmptyShade; + position: sticky; + z-index: 1; + } + } + + &__tableHeader, + &__tableBody, + &__tableFooter, + &__tableRow { + // This ignores all above elements for positioning + // effectively spreading all children in its place + display: contents; + } + + &__tableHeader { + margin-bottom: 0; + top: 0; + + .echTooltip__tableCell { + border-bottom: $tableBorder; + top: 0; + } + } + + &__tableFooter { + margin-top: 0; + bottom: 0; + + .echTooltip__tableCell { + border-top: $tableBorder; + bottom: 0; + } + } + + &__tableCell:not(.echTooltip__colorCell) { + padding: 4px; + } + + &__tableBody { + .echTooltip__tableCell:not(.echTooltip__colorCell) { + padding: 2px 4px; + } + + .echTooltip__tableRow--selected { + .echTooltip__tableCell:not(.echTooltip__colorCell), + .echTooltip__colorCell .echTooltip__colorStrip--spacer { + background-color: $tableRowSelectedColor; + } + } + + .echTooltip__tableRow--selected:hover { + .echTooltip__tableCell:not(.echTooltip__colorCell), + .echTooltip__colorCell .echTooltip__colorStrip--spacer { + background-color: $tableRowHoverSelectedColor; + } + } + .echTooltip__tableRow--selectable:hover { + .echTooltip__tableCell:not(.echTooltip__colorCell), + .echTooltip__colorCell .echTooltip__colorStrip--spacer { + background-color: $tableRowHoverColor; + } + } + } + + &__tableRow { + position: relative; + + &--highlighted { + .echTooltip__tableCell:not(.echTooltip__colorCell), + .echTooltip__colorCell .echTooltip__colorStrip--spacer { + background-color: transparentize($euiColorLightShade, 0.5); + } + } + + &--selected { + :not(.echTooltip__colorCell--static) .echTooltip__colorStrip { + width: $maxRowColorStripWidth; + + &--spacer { + width: 0; + min-width: 0; + } + + &:not(&--bg)::before { + opacity: 1; + } + } + } + } + + &__colorCell { + padding: 0; + height: 100%; + position: relative; + overflow: hidden; // to avoid extra height from color strip styles + width: $maxRowColorStripWidth; + + &--static { + width: $rowColorStripWidth; + } + } + + &__colorStrip, + &__colorStrip--bg, + &__colorStrip--spacer { + position: absolute; + top: 0; + left: 0; + bottom: 0; + width: $rowColorStripWidth; + transition: width 200ms; + } + + &__colorStrip { + &::before { + opacity: 0; + content: '✓'; + display: flex; + justify-content: center; + align-items: center; + height: 95%; // to center dot better + font-size: 90%; + font-weight: bold; + transition: opacity 200ms; + } + + &--spacer { + left: auto; + right: 0; + width: $maxRowColorStripWidth - $rowColorStripWidth; + min-width: $maxRowColorStripWidth - $rowColorStripWidth; + } + } + + &__label { + min-width: 1px; + flex: 1 1 auto; + text-align: left; + } + + &__value { + text-align: right; + font-feature-settings: 'tnum'; + } + + &[dir='rtl'] { + .echTooltip { + &__colorStrip { + left: auto; + right: 0; + } + } + } +} diff --git a/packages/charts/src/components/tooltip/components/_tooltip_actions.scss b/packages/charts/src/components/tooltip/components/_tooltip_actions.scss new file mode 100644 index 0000000000..43236f623b --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip_actions.scss @@ -0,0 +1,53 @@ +.echTooltipActions { + position: relative; + display: flex; + align-items: flex-start; + flex-direction: column; + width: 100%; + font-style: normal; + font-size: 12px; + line-height: 21px; + + &__prompt { + position: relative; + height: 26px; + padding: 0 $euiSizeS; + line-height: 26px; + width: 100%; + color: $euiTextSubduedColor; + font-style: normal; + font-size: 12px; + } + + &__action { + &:nth-child(2) { + padding-top: 4px; + } + &:last-child { + padding-bottom: 2px; + } + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + display: block; + text-align: left; + width: 100%; + padding: 0 $euiSizeS; + line-height: 21px; + cursor: pointer; + color: $euiTextColor; + &:hover, + &:focus { + text-decoration: underline; + } + + &[disabled] { + cursor: default; + color: $euiButtonColorDisabledText; + &:hover, + &:focus { + text-decoration: none; + } + } + } +} diff --git a/packages/charts/src/components/tooltip/components/_tooltip_divider.scss b/packages/charts/src/components/tooltip/components/_tooltip_divider.scss new file mode 100644 index 0000000000..ec01d553a5 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip_divider.scss @@ -0,0 +1,4 @@ +.echTooltipDivider { + width: 100%; + border-bottom: $tableBorder; +} diff --git a/packages/charts/src/components/tooltip/components/_tooltip_footer.scss b/packages/charts/src/components/tooltip/components/_tooltip_footer.scss new file mode 100644 index 0000000000..65aa161ea7 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip_footer.scss @@ -0,0 +1,5 @@ +.echTooltipFooter { + font-weight: $euiFontWeightBold; + margin-top: 0; + padding: $euiSizeXS ($euiSizeXS * 2); +} diff --git a/packages/charts/src/components/tooltip/components/_tooltip_header.scss b/packages/charts/src/components/tooltip/components/_tooltip_header.scss new file mode 100644 index 0000000000..42a940d2c5 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip_header.scss @@ -0,0 +1,5 @@ +.echTooltipHeader { + font-weight: $euiFontWeightSemiBold; + margin-bottom: 0; + padding: $euiSizeXS ($euiSizeXS * 2); +} diff --git a/packages/charts/src/components/tooltip/components/_tooltip_prompt.scss b/packages/charts/src/components/tooltip/components/_tooltip_prompt.scss new file mode 100644 index 0000000000..bf6a782b28 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/_tooltip_prompt.scss @@ -0,0 +1,28 @@ +$tooltipPromptAnimDelay: 0.5s; + +@keyframes promptFadeInDown { + 100% { + opacity: 1; + top: 0; + height: 26px; + } +} + +.echTooltipPrompt { + position: relative; + width: 100%; + //opacity: 0; + //top: -26px; + //height: 0; + //animation: promptFadeInDown 0.5s forwards; + //animation-delay: $tooltipPromptAnimDelay; + z-index: -1; + + &__content { + color: $euiTextSubduedColor; + font-style: normal; + font-size: 12px; + line-height: 26px; + padding: 0 $euiSizeS; + } +} diff --git a/packages/charts/src/components/tooltip/components/tooltip_actions.tsx b/packages/charts/src/components/tooltip/components/tooltip_actions.tsx new file mode 100644 index 0000000000..3e134e3661 --- /dev/null +++ b/packages/charts/src/components/tooltip/components/tooltip_actions.tsx @@ -0,0 +1,99 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { ComponentType, useEffect, useState } from 'react'; + +import { SeriesIdentifier } from '../../../common/series_id'; +import { BaseDatum, TooltipAction, TooltipSpec, TooltipValue } from '../../../specs'; +import { Datum, renderWithProps } from '../../../utils/common'; +import { TooltipDivider } from './tooltip_divider'; +import { useTooltipContext } from './tooltip_provider'; + +/** @internal */ +export const TooltipActions = ({ + actions, + selectionPrompt, + actionsLoading, + noActionsLoaded, +}: Pick, 'actions' | 'selectionPrompt' | 'actionsLoading' | 'noActionsLoaded'>) => { + const { pinned, selected, values, pinTooltip } = useTooltipContext(); + const syncActions = Array.isArray(actions); + const [loading, setLoading] = useState(true); + const [loadedActions, setLoadedActions] = useState[]>(syncActions ? actions : []); + + useEffect(() => { + if (pinned && !syncActions) { + const fetchActions = async ( + asyncActions: (s: TooltipValue[]) => Promise[]> | TooltipAction[], + ) => { + setLoading(true); + setLoadedActions(await asyncActions(selected)); + setLoading(false); + }; + void fetchActions(actions); + return () => { + setLoading(true); + setLoadedActions([]); + }; + } + }, [syncActions, actions, selected, pinned]); + + if (!syncActions) { + if (loading) return renderPromptContent(actionsLoading, selected); + if (loadedActions.length === 0) return renderPromptContent(noActionsLoaded, selected); + } + + if (pinned && syncActions && loadedActions.length === 0) { + return null; + } + + const visibleActions = loadedActions.filter(({ hide }) => !hide || hide(selected, values)); + + if (visibleActions.length === 0) { + return renderPromptContent(selectionPrompt, selected); + } + + return ( +
    + + {...visibleActions.map(({ onSelect, label, disabled }, i) => { + const reason = disabled && disabled(selected, values); + + return ( + + ); + })} +
    + ); +}; + +function renderPromptContent( + content: string | ComponentType<{ selected: TooltipValue[] }>, + selected: Array>, +) { + return ( +
    + +
    {renderWithProps(content, { selected })}
    +
    + ); +} diff --git a/packages/charts/src/components/tooltip/components/tooltip_body.tsx b/packages/charts/src/components/tooltip/components/tooltip_body.tsx index 6f4af436ac..e988fef5b3 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_body.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_body.tsx @@ -6,12 +6,14 @@ * Side Public License, v 1. */ -import React from 'react'; +import { Placement as PopperPlacement } from '@popperjs/core'; +import React, { CSSProperties } from 'react'; import { SeriesIdentifier } from '../../../common/series_id'; import { TooltipValueFormatter, BaseDatum, TooltipSpec, TooltipProps } from '../../../specs'; import { Datum } from '../../../utils/common'; -import { TooltipInfo } from '../types'; +import { TooltipStyle } from '../../../utils/themes/theme'; +import { SetSelectedTooltipItemsCallback, ToggleSelectedTooltipItemCallback, TooltipInfo } from '../types'; import { TooltipFooter } from './tooltip_footer'; import { TooltipHeader } from './tooltip_header'; import { useTooltipContext } from './tooltip_provider'; @@ -20,12 +22,19 @@ import { TooltipWrapper } from './tooltip_wrapper'; import { TooltipTableColumn } from './types'; interface TooltipBodyProps - extends Pick, 'headerFormatter' | 'header' | 'footer'> { + extends Pick< + TooltipSpec, + 'actions' | 'actionPrompt' | 'pinningPrompt' | 'selectionPrompt' | 'actionsLoading' | 'noActionsLoaded' + >, + Pick, 'headerFormatter' | 'header' | 'footer' | 'actionPrompt' | 'selectionPrompt'> { visible: boolean; info?: TooltipInfo; + placement?: PopperPlacement; columns: TooltipTableColumn[]; headerFormatter?: TooltipValueFormatter; settings?: TooltipProps; + toggleSelected: ToggleSelectedTooltipItemCallback; + setSelection: SetSelectedTooltipItemsCallback; } /** @internal */ @@ -37,30 +46,115 @@ export const TooltipBody = ) => { - const { backgroundColor, dir } = useTooltipContext(); + const { backgroundColor, dir, pinned, selected, theme, actionable } = useTooltipContext(); if (!info || !visible) { return null; } + const wrapperStyles = getStylesFromPlacement(actionable, theme, placement); + if (typeof settings !== 'string' && settings?.customTooltip) { const CustomTooltip = settings.customTooltip; return ( - - - +
    + + + +
    ); } return ( - - {header ? ( - {typeof header === 'string' ? header : header(info.values)} - ) : ( - - )} - - {footer && {typeof footer === 'string' ? footer : footer(info.values)}} - +
    + + {header ? ( + {typeof header === 'string' ? header : header(info.values)} + ) : ( + + )} + + {footer && {typeof footer === 'string' ? footer : footer(info.values)}} + +
    ); }; + +function getStylesFromPlacement( + actionable: boolean, + { maxWidth }: TooltipStyle, + placement?: PopperPlacement, +): CSSProperties | undefined { + if (!actionable) return { maxWidth }; + switch (placement) { + case 'left': + case 'left-start': + case 'left-end': + case 'top-end': + case 'bottom-end': + return { + width: maxWidth, + justifyContent: 'flex-end', + }; + case 'right': + case 'right-start': + case 'right-end': + case 'top-start': + case 'bottom-start': + return { + width: maxWidth, + justifyContent: 'flex-start', + }; + case 'top': + case 'bottom': + return { + width: maxWidth, + justifyContent: 'center', + }; + case 'auto': + case 'auto-start': + case 'auto-end': + default: + return { + width: maxWidth, + }; + } +} diff --git a/packages/charts/src/components/tooltip/components/tooltip_divider.tsx b/packages/charts/src/components/tooltip/components/tooltip_divider.tsx index f08531254c..2724e3ce65 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_divider.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_divider.tsx @@ -14,5 +14,5 @@ interface TooltipDividerProps { /** @public */ export const TooltipDivider = ({ margin }: TooltipDividerProps) => { - return
    ; + return
    ; }; diff --git a/packages/charts/src/components/tooltip/components/tooltip_footer.tsx b/packages/charts/src/components/tooltip/components/tooltip_footer.tsx index 6cfb635a87..eccd4dae5b 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_footer.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_footer.tsx @@ -14,5 +14,5 @@ type TooltipFooterProps = PropsWithChildren<{}>; /** @public */ export const TooltipFooter = ({ children }: TooltipFooterProps) => { - return
    {renderComplexChildren(children)}
    ; + return
    {renderComplexChildren(children)}
    ; }; diff --git a/packages/charts/src/components/tooltip/components/tooltip_header.tsx b/packages/charts/src/components/tooltip/components/tooltip_header.tsx index 3f4521985c..5c51ae5079 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_header.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_header.tsx @@ -12,6 +12,7 @@ import { SeriesIdentifier } from '../../../common/series_id'; import { BaseDatum, TooltipValue, TooltipValueFormatter } from '../../../specs'; import { Datum, renderComplexChildren } from '../../../utils/common'; import { PropsOrChildrenWithProps } from '../types'; +import { TooltipDivider } from './tooltip_divider'; type TooltipHeaderProps< D extends BaseDatum = Datum, @@ -25,14 +26,24 @@ const TooltipHeaderInner = , ) => { if ('children' in props) { - return
    {renderComplexChildren(props.children)}
    ; + return ( + <> +
    {renderComplexChildren(props.children)}
    + + + ); } const { header, formatter } = props; if (!header || !header.isVisible) return null; const formattedValue = formatter ? formatter(header) : header.formattedValue; if (!formattedValue) return null; - return
    {formattedValue}
    ; + return ( + <> +
    {formattedValue}
    + + + ); }; /** @public */ diff --git a/packages/charts/src/components/tooltip/components/tooltip_prompt.tsx b/packages/charts/src/components/tooltip/components/tooltip_prompt.tsx new file mode 100644 index 0000000000..407b50339a --- /dev/null +++ b/packages/charts/src/components/tooltip/components/tooltip_prompt.tsx @@ -0,0 +1,21 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { PropsWithChildren } from 'react'; + +import { TooltipDivider } from './tooltip_divider'; + +/** @internal */ +export function TooltipPrompt({ children }: PropsWithChildren<{}>) { + return ( +
    + +
    {children}
    +
    + ); +} diff --git a/packages/charts/src/components/tooltip/components/tooltip_provider.tsx b/packages/charts/src/components/tooltip/components/tooltip_provider.tsx index 6ccc8eab10..fc75279090 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_provider.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_provider.tsx @@ -6,30 +6,78 @@ * Side Public License, v 1. */ -import React, { PropsWithChildren, useContext } from 'react'; +import React, { PropsWithChildren, Context, useContext } from 'react'; -interface TooltipContext { +import { SeriesIdentifier } from '../../../common/series_id'; +import { BaseDatum, TooltipValue } from '../../../specs'; +import { pinTooltip as pinTooltipAction } from '../../../state/actions/tooltip'; +import { Datum } from '../../../utils/common'; +import { LIGHT_THEME } from '../../../utils/themes/light_theme'; +import { TooltipStyle } from '../../../utils/themes/theme'; +import { PinTooltipCallback } from '../types'; + +interface TooltipContext { backgroundColor: string; dir: 'rtl' | 'ltr'; + maxItems: number; + pinned: boolean; + actionable: boolean; + canPinTooltip: boolean; + selected: Array>; + values: TooltipValue[]; + pinTooltip: PinTooltipCallback; + theme: TooltipStyle; } const TooltipContext = React.createContext({ backgroundColor: '#fff', dir: 'ltr', + maxItems: 5, + pinned: false, + actionable: false, + canPinTooltip: false, + selected: [], + values: [], + pinTooltip: pinTooltipAction, + theme: LIGHT_THEME.tooltip, }); /** @internal */ -export const useTooltipContext = () => useContext(TooltipContext); +export const useTooltipContext = () => + useContext>(TooltipContext as unknown as Context>); -type TooltipProviderProps = PropsWithChildren; +type TooltipProviderProps< + D extends BaseDatum = Datum, + SI extends SeriesIdentifier = SeriesIdentifier, +> = PropsWithChildren>; /** @internal */ -export const TooltipProvider = ({ backgroundColor, dir, children }: TooltipProviderProps) => { +export const TooltipProvider = ({ + backgroundColor, + dir, + maxItems, + pinned, + actionable, + canPinTooltip, + selected, + values, + pinTooltip, + children, + theme, +}: TooltipProviderProps) => { return ( {children} diff --git a/packages/charts/src/components/tooltip/components/tooltip_table.tsx b/packages/charts/src/components/tooltip/components/tooltip_table.tsx index 958c3c417b..27d3127c16 100644 --- a/packages/charts/src/components/tooltip/components/tooltip_table.tsx +++ b/packages/charts/src/components/tooltip/components/tooltip_table.tsx @@ -12,12 +12,21 @@ import React, { CSSProperties } from 'react'; import { SeriesIdentifier } from '../../../common/series_id'; import { BaseDatum, TooltipValue } from '../../../specs'; import { Datum, isNil } from '../../../utils/common'; -import { PropsOrChildrenWithProps } from '../types'; +import { PropsOrChildrenWithProps, ToggleSelectedTooltipItemCallback } from '../types'; +import { useTooltipContext } from './tooltip_provider'; import { TooltipTableBody } from './tooltip_table_body'; import { TooltipTableFooter } from './tooltip_table_footer'; import { TooltipTableHeader } from './tooltip_table_header'; import { TooltipTableColumn } from './types'; +const TOOLTIP_ITEM_HEIGHT = 20; +const TOOLTIP_HEADER_HEIGHT = 25; +const TOOLTIP_FOOTER_HEIGHT = 25; +/** + * Manually synced with `$maxRowColorStripWidth` scss var in [`_tooltip.scss`](packages/charts/src/components/tooltip/_tooltip.scss) + */ +const MAX_ROW_COLOR_STRIP_WIDTH = 11; + type TooltipTableProps< D extends BaseDatum = Datum, SI extends SeriesIdentifier = SeriesIdentifier, @@ -25,8 +34,16 @@ type TooltipTableProps< { columns: TooltipTableColumn[]; items: TooltipValue[]; + pinned?: boolean; + onSelect?: ToggleSelectedTooltipItemCallback; + selected?: TooltipValue[]; + }, + { + /** + * Used to defined the column widths, otherwise auto-generated + */ + gridTemplateColumns: CSSProperties['gridTemplateColumns']; }, - {}, { className?: string; maxHeight?: CSSProperties['maxHeight']; @@ -35,19 +52,23 @@ type TooltipTableProps< /** @public */ export const TooltipTable = ({ - maxHeight, className, ...props }: TooltipTableProps) => { - const classes = classNames('echTooltip__table', className, { - 'echTooltip__table--scrollable': !isNil(maxHeight), - }); + const { theme, maxItems, ...rest } = useTooltipContext(); if ('children' in props) { + const { gridTemplateColumns } = props; + const classes = classNames('echTooltip__table', className, { + 'echTooltip__table--noGrid': !gridTemplateColumns, + }); + const maxHeight = props.maxHeight ?? theme.maxTableHeight; return ( - - {props.children} -
    +
    +
    + {props.children} +
    +
    ); } @@ -55,11 +76,36 @@ export const TooltipTable =