Update dependency @elastic/charts to v33 (master) (#105633)

This commit is contained in:
renovate[bot] 2021-07-20 03:33:22 -04:00 committed by GitHub
parent 41289fadc3
commit 1e30148f59
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 34 additions and 16 deletions

View file

@ -97,7 +97,7 @@
"dependencies": { "dependencies": {
"@elastic/apm-rum": "^5.8.0", "@elastic/apm-rum": "^5.8.0",
"@elastic/apm-rum-react": "^1.2.11", "@elastic/apm-rum-react": "^1.2.11",
"@elastic/charts": "32.0.0", "@elastic/charts": "33.0.0",
"@elastic/datemath": "link:bazel-bin/packages/elastic-datemath", "@elastic/datemath": "link:bazel-bin/packages/elastic-datemath",
"@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@^8.0.0-canary.13", "@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@^8.0.0-canary.13",
"@elastic/ems-client": "7.14.0", "@elastic/ems-client": "7.14.0",

View file

@ -18,6 +18,7 @@ import {
Accessor, Accessor,
AccessorFn, AccessorFn,
ColorVariant, ColorVariant,
LabelOverflowConstraint,
} from '@elastic/charts'; } from '@elastic/charts';
import { DatatableRow } from '../../../expressions/public'; import { DatatableRow } from '../../../expressions/public';
@ -130,7 +131,7 @@ export const renderAllSeries = (
minBarHeight={2} minBarHeight={2}
displayValueSettings={{ displayValueSettings={{
showValueLabel, showValueLabel,
hideClippedValue: true, overflowConstraints: [LabelOverflowConstraint.ChartEdges],
}} }}
/> />
); );
@ -161,7 +162,7 @@ export const renderAllSeries = (
stackAccessors={isStacked ? ['__any_value__'] : undefined} stackAccessors={isStacked ? ['__any_value__'] : undefined}
displayValueSettings={{ displayValueSettings={{
showValueLabel, showValueLabel,
hideClippedValue: true, overflowConstraints: [LabelOverflowConstraint.ChartEdges],
}} }}
timeZone={timeZone} timeZone={timeZone}
stackMode={stackMode} stackMode={stackMode}

View file

@ -335,9 +335,11 @@ exports[`xy_expression XYChart component it renders bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -399,9 +401,11 @@ exports[`xy_expression XYChart component it renders bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -558,9 +562,11 @@ exports[`xy_expression XYChart component it renders horizontal bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -622,9 +628,11 @@ exports[`xy_expression XYChart component it renders horizontal bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -1219,9 +1227,11 @@ exports[`xy_expression XYChart component it renders stacked bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -1287,9 +1297,11 @@ exports[`xy_expression XYChart component it renders stacked bar 1`] = `
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -1450,9 +1462,11 @@ exports[`xy_expression XYChart component it renders stacked horizontal bar 1`] =
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }
@ -1518,9 +1532,11 @@ exports[`xy_expression XYChart component it renders stacked horizontal bar 1`] =
} }
displayValueSettings={ displayValueSettings={
Object { Object {
"hideClippedValue": true,
"isAlternatingValueLabel": false, "isAlternatingValueLabel": false,
"isValueContainedInElement": true, "isValueContainedInElement": true,
"overflowConstraints": Array [
"chartEdges",
],
"showValueLabel": false, "showValueLabel": false,
"valueFormatter": [Function], "valueFormatter": [Function],
} }

View file

@ -25,6 +25,7 @@ import {
ElementClickListener, ElementClickListener,
BrushEndListener, BrushEndListener,
CurveType, CurveType,
LabelOverflowConstraint,
} from '@elastic/charts'; } from '@elastic/charts';
import { I18nProvider } from '@kbn/i18n/react'; import { I18nProvider } from '@kbn/i18n/react';
import { import {
@ -909,7 +910,7 @@ export function XYChart({
showValueLabel: shouldShowValueLabels && valueLabels !== 'hide', showValueLabel: shouldShowValueLabels && valueLabels !== 'hide',
isAlternatingValueLabel: false, isAlternatingValueLabel: false,
isValueContainedInElement: true, isValueContainedInElement: true,
hideClippedValue: true, overflowConstraints: [LabelOverflowConstraint.ChartEdges],
}, },
}; };
return <BarSeries key={index} {...seriesProps} {...valueLabelsSettings} />; return <BarSeries key={index} {...seriesProps} {...valueLabelsSettings} />;

View file

@ -1389,10 +1389,10 @@
dependencies: dependencies:
object-hash "^1.3.0" object-hash "^1.3.0"
"@elastic/charts@32.0.0": "@elastic/charts@33.0.0":
version "32.0.0" version "33.0.0"
resolved "https://registry.yarnpkg.com/@elastic/charts/-/charts-32.0.0.tgz#f747b8fa931027ba7476a6284be03383cd6a6dab" resolved "https://registry.yarnpkg.com/@elastic/charts/-/charts-33.0.0.tgz#45428b792300e363ecd3454465be49d42788a1fd"
integrity sha512-3cvX0Clezocd6/T2R5h3+nilPdIgWrO+it043giyW5U0pAtFC5P+5VyNEjn22LlD3zzbndxAbXHSj0QDvHXOBw== integrity sha512-HUt0oBaO/PSRZcYHmdLL1lzFWMBtP/9umGIAQgW785qv+y/Hv2cjjfYNckGfnr5RUDtx0KCc3v2UBkRq6n93EA==
dependencies: dependencies:
"@popperjs/core" "^2.4.0" "@popperjs/core" "^2.4.0"
chroma-js "^2.1.0" chroma-js "^2.1.0"