diff --git a/x-pack/platform/packages/private/ml/date_picker/src/components/date_picker_wrapper.tsx b/x-pack/platform/packages/private/ml/date_picker/src/components/date_picker_wrapper.tsx index c8792ab3f9d9e..3925b51b6c38e 100644 --- a/x-pack/platform/packages/private/ml/date_picker/src/components/date_picker_wrapper.tsx +++ b/x-pack/platform/packages/private/ml/date_picker/src/components/date_picker_wrapper.tsx @@ -338,7 +338,7 @@ export const DatePickerWrapper: FC = (props) => { = ({ config, onAddFilter }) = diff --git a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/ip_content.tsx b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/ip_content.tsx index d169220755175..6baaf8e065d1f 100644 --- a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/ip_content.tsx +++ b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/ip_content.tsx @@ -26,7 +26,7 @@ export const IpContent: FC = ({ config, onAddFilter }) => { )} diff --git a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/keyword_content.tsx b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/keyword_content.tsx index 44be869c9af97..ddca9193db2b1 100644 --- a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/keyword_content.tsx +++ b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/keyword_content.tsx @@ -62,14 +62,14 @@ export const KeywordContent: FC = ({ config, onAddFilter }) = {config.stats?.sampledValues && fieldName !== undefined ? ( diff --git a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/number_content.tsx b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/number_content.tsx index a1ff194826215..8b121660e3421 100644 --- a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/number_content.tsx +++ b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/stats_table/components/field_data_expanded_row/number_content.tsx @@ -119,7 +119,7 @@ export const NumberContent: FC = ({ config, onAddFilter }) => diff --git a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/top_values/top_values.tsx b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/top_values/top_values.tsx index 5d263135389eb..35c648e7135bb 100644 --- a/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/top_values/top_values.tsx +++ b/x-pack/platform/plugins/private/data_visualizer/public/application/common/components/top_values/top_values.tsx @@ -11,6 +11,7 @@ import { EuiFlexGroup, EuiFlexItem, EuiProgress, + type EuiProgressProps, EuiText, EuiButtonIcon, EuiSpacer, @@ -36,7 +37,7 @@ import { EMPTY_EXAMPLE } from '../examples_list/examples_list'; interface Props { stats: FieldVisStats | undefined; fieldFormat?: any; - barColor?: 'primary' | 'success' | 'danger' | 'subdued' | 'accent'; + barColor?: EuiProgressProps['color']; compressed?: boolean; onAddFilter?: (field: DataViewField | string, value: string, type: '+' | '-') => void; showSampledValues?: boolean; diff --git a/x-pack/platform/plugins/private/transform/public/app/sections/transform_management/components/refresh_transform_list_button/refresh_transform_list_button.tsx b/x-pack/platform/plugins/private/transform/public/app/sections/transform_management/components/refresh_transform_list_button/refresh_transform_list_button.tsx index efd4fb1d500af..18a3f5c63dafc 100644 --- a/x-pack/platform/plugins/private/transform/public/app/sections/transform_management/components/refresh_transform_list_button/refresh_transform_list_button.tsx +++ b/x-pack/platform/plugins/private/transform/public/app/sections/transform_management/components/refresh_transform_list_button/refresh_transform_list_button.tsx @@ -19,7 +19,7 @@ export const RefreshTransformListButton: FC = ({ isLoading, }) => ( = ({ item }) => { valueText={true} value={s.progress_percent} max={100} - color="success" + color="primary" size="s" /> ), diff --git a/x-pack/platform/plugins/shared/ml/public/application/data_frame_analytics/pages/job_map/components/cytoscape_options.tsx b/x-pack/platform/plugins/shared/ml/public/application/data_frame_analytics/pages/job_map/components/cytoscape_options.tsx index 61cbf816d5a99..6877767907594 100644 --- a/x-pack/platform/plugins/shared/ml/public/application/data_frame_analytics/pages/job_map/components/cytoscape_options.tsx +++ b/x-pack/platform/plugins/shared/ml/public/application/data_frame_analytics/pages/job_map/components/cytoscape_options.tsx @@ -12,8 +12,6 @@ import classificationJobIcon from './icons/ml_classification_job.svg'; import outlierDetectionJobIcon from './icons/ml_outlier_detection_job.svg'; import regressionJobIcon from './icons/ml_regression_job.svg'; -const lineColor = '#C5CCD7'; - const MAP_SHAPES = { ELLIPSE: 'ellipse', RECTANGLE: 'rectangle', @@ -23,7 +21,7 @@ const MAP_SHAPES = { } as const; type MapShapes = (typeof MAP_SHAPES)[keyof typeof MAP_SHAPES]; -function shapeForNode(el: cytoscape.NodeSingular, theme: EuiThemeType): MapShapes { +function shapeForNode(el: cytoscape.NodeSingular): MapShapes { const type = el.data('type'); switch (type) { case JOB_MAP_NODE_TYPES.ANALYTICS: @@ -70,7 +68,7 @@ function borderColorForNode(el: cytoscape.NodeSingular, theme: EuiThemeType) { case JOB_MAP_NODE_TYPES.ANALYTICS_JOB_MISSING: return theme.euiColorFullShade; case JOB_MAP_NODE_TYPES.ANALYTICS: - return theme.euiColorSuccess; + return theme.euiColorVis0; case JOB_MAP_NODE_TYPES.TRANSFORM: return theme.euiColorVis1; case JOB_MAP_NODE_TYPES.INDEX: @@ -85,55 +83,59 @@ function borderColorForNode(el: cytoscape.NodeSingular, theme: EuiThemeType) { } } -export const getCytoscapeOptions = (theme: EuiThemeType): cytoscape.CytoscapeOptions => ({ - autoungrabify: true, - boxSelectionEnabled: false, - maxZoom: 3, - minZoom: 0.2, - style: [ - { - selector: 'node', - style: { - 'background-color': (el: cytoscape.NodeSingular) => - el.data('isRoot') ? theme.euiColorWarning : theme.euiColorGhost, - 'background-height': '60%', - 'background-width': '60%', - 'border-color': (el: cytoscape.NodeSingular) => borderColorForNode(el, theme), - 'border-style': 'solid', - // @ts-ignore - 'background-image': (el: cytoscape.NodeSingular) => iconForNode(el), - 'border-width': (el: cytoscape.NodeSingular) => (el.selected() ? 4 : 3), - color: theme.euiTextColor, - 'font-family': 'Inter UI, Segoe UI, Helvetica, Arial, sans-serif', - 'font-size': theme.euiFontSizeXS, - 'min-zoomed-font-size': parseInt(theme.euiSizeL, 10), - label: 'data(label)', - shape: (el: cytoscape.NodeSingular) => shapeForNode(el, theme), - 'text-background-color': theme.euiColorLightestShade, - 'text-background-opacity': 0, - 'text-background-padding': theme.euiSizeXS, - 'text-background-shape': 'roundrectangle', - 'text-margin-y': parseInt(theme.euiSizeS, 10), - 'text-max-width': '200px', - 'text-valign': 'bottom', - 'text-wrap': 'wrap', +export const getCytoscapeOptions = (theme: EuiThemeType): cytoscape.CytoscapeOptions => { + const lineColor = theme.euiColorLightShade; + + return { + autoungrabify: true, + boxSelectionEnabled: false, + maxZoom: 3, + minZoom: 0.2, + style: [ + { + selector: 'node', + style: { + 'background-color': (el: cytoscape.NodeSingular) => + el.data('isRoot') ? theme.euiColorWarning : theme.euiColorGhost, + 'background-height': '60%', + 'background-width': '60%', + 'border-color': (el: cytoscape.NodeSingular) => borderColorForNode(el, theme), + 'border-style': 'solid', + // @ts-ignore + 'background-image': (el: cytoscape.NodeSingular) => iconForNode(el), + 'border-width': (el: cytoscape.NodeSingular) => (el.selected() ? 4 : 3), + color: theme.euiTextColor, + 'font-family': 'Inter UI, Segoe UI, Helvetica, Arial, sans-serif', + 'font-size': theme.euiFontSizeXS, + 'min-zoomed-font-size': parseInt(theme.euiSizeL, 10), + label: 'data(label)', + shape: (el: cytoscape.NodeSingular) => shapeForNode(el), + 'text-background-color': theme.euiColorLightestShade, + 'text-background-opacity': 0, + 'text-background-padding': theme.euiSizeXS, + 'text-background-shape': 'roundrectangle', + 'text-margin-y': parseInt(theme.euiSizeS, 10), + 'text-max-width': '200px', + 'text-valign': 'bottom', + 'text-wrap': 'wrap', + }, }, - }, - { - selector: 'edge', - style: { - 'curve-style': 'taxi', - // @ts-ignore - 'taxi-direction': 'rightward', - 'line-color': lineColor, - 'overlay-opacity': 0, - 'target-arrow-color': lineColor, - 'target-arrow-shape': 'triangle', - // @ts-ignore - 'target-distance-from-node': theme.euiSizeXS, - width: 1, - 'source-arrow-shape': 'none', + { + selector: 'edge', + style: { + 'curve-style': 'taxi', + // @ts-ignore + 'taxi-direction': 'rightward', + 'line-color': lineColor, + 'overlay-opacity': 0, + 'target-arrow-color': lineColor, + 'target-arrow-shape': 'triangle', + // @ts-ignore + 'target-distance-from-node': theme.euiSizeXS, + width: 1, + 'source-arrow-shape': 'none', + }, }, - }, - ], -}); + ], + }; +}; diff --git a/x-pack/platform/plugins/shared/ml/public/application/jobs/new_job/recognize/components/job_item.tsx b/x-pack/platform/plugins/shared/ml/public/application/jobs/new_job/recognize/components/job_item.tsx index 9d0692d540f13..a60fa07fdee8e 100644 --- a/x-pack/platform/plugins/shared/ml/public/application/jobs/new_job/recognize/components/job_item.tsx +++ b/x-pack/platform/plugins/shared/ml/public/application/jobs/new_job/recognize/components/job_item.tsx @@ -54,7 +54,7 @@ export const JobItem: FC = memo( - + {jobPrefix} {id} diff --git a/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer.js b/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer.js index 57ded98fc8374..9fce79d3d1fab 100644 --- a/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer.js +++ b/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer.js @@ -1130,19 +1130,20 @@ export class TimeSeriesExplorer extends React.Component { )}   - {chartDetails.entityData.count === 1 && ( - - {chartDetails.entityData.entities.length > 0 && '('} - {chartDetails.entityData.entities - .map((entity) => { - return `${entity.fieldName}: ${entity.fieldValue}`; - }) - .join(', ')} - {chartDetails.entityData.entities.length > 0 && ')'} - - )} - {chartDetails.entityData.count !== 1 && ( - + {chartDetails.entityData.count === 1 && + chartDetails.entityData.entities.length > 0 && ( + + ( + {chartDetails.entityData.entities + .map((entity) => { + return `${entity.fieldName}: ${entity.fieldValue}`; + }) + .join(', ')} + ) + + )} + {chartDetails.entityData.count > 1 && ( + {chartDetails.entityData.entities.map((countData, i) => { return ( diff --git a/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer_embeddable_chart/timeseriesexplorer_title.tsx b/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer_embeddable_chart/timeseriesexplorer_title.tsx index 720acfd1704e9..7f874961121a9 100644 --- a/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer_embeddable_chart/timeseriesexplorer_title.tsx +++ b/x-pack/platform/plugins/shared/ml/public/application/timeseriesexplorer/timeseriesexplorer_embeddable_chart/timeseriesexplorer_title.tsx @@ -122,7 +122,7 @@ export const SingleMetricViewerTitle: FC = ({ - + {`${entity.fieldName}: ${entity.fieldValue}`}