Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Adding the option and feature to enable borders with color, opacity and width control on heatmaps along with white borders on emphasis #32358

Merged
merged 21 commits into from
Feb 27, 2025
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
46a4fec
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 24, 2025
a8e28f3
modified: superset-frontend/package-lock.json
Dev10-34 Feb 24, 2025
b404a2e
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 24, 2025
715a15a
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 25, 2025
acb7968
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 25, 2025
bfbfb8e
modified: superset-frontend/package-lock.json
Dev10-34 Feb 25, 2025
4775760
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 25, 2025
aac7a7f
modified: superset-frontend/packages/superset-ui-core/src/color/ut…
Dev10-34 Feb 26, 2025
312cc9b
modified: superset-frontend/packages/superset-ui-core/src/color/ut…
Dev10-34 Feb 26, 2025
14b706d
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 26, 2025
76baf43
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 26, 2025
c588997
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 26, 2025
f84cc69
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/con…
Dev10-34 Feb 27, 2025
fc4f07e
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/con…
Dev10-34 Feb 27, 2025
b76f1f5
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/con…
Dev10-34 Feb 27, 2025
9ebe053
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/con…
Dev10-34 Feb 27, 2025
eb42321
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/tra…
Dev10-34 Feb 27, 2025
2b1f538
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/tra…
Dev10-34 Feb 27, 2025
3bd4223
Update superset-frontend/plugins/plugin-chart-echarts/src/Heatmap/typ…
Dev10-34 Feb 27, 2025
4dac5ba
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 27, 2025
96b128f
modified: superset-frontend/plugins/plugin-chart-echarts/src/Heatm…
Dev10-34 Feb 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion superset-frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,20 @@ const config: ControlPanelConfig = {
},
},
],
[
{
name: 'enable_borders',
config: {
type: 'CheckboxControl',
label: t('Enable Borders'),
renderTrigger: true,
description: t(
'To enable black borders to Heatmap elements',
),
default: false,
},
},
],
],
},
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import {
getSequentialSchemeRegistry,
getTimeFormatter,
getValueFormatter,
supersetTheme,
tooltipHtml,
} from '@superset-ui/core';
import memoizeOne from 'memoize-one';
Expand Down Expand Up @@ -86,6 +87,7 @@ export default function transformProps(
metric = '',
normalizeAcross,
normalized,
enableBorders,
showLegend,
showPercentage,
showValues,
Expand Down Expand Up @@ -161,6 +163,18 @@ export default function transformProps(
return valueFormatter(paramsValue?.[2] as number | null | undefined);
},
},
itemStyle: {
borderColor: enableBorders
? supersetTheme.colors.grayscale.dark2
: undefined,
},
emphasis: {
itemStyle: {
borderColor: supersetTheme.colors.grayscale.light5,
shadowBlur: 10,
shadowColor: supersetTheme.colors.grayscale.dark2,
},
},
},
];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export interface HeatmapFormData extends QueryFormData {
metric: QueryFormMetric;
normalizeAcross: 'heatmap' | 'x' | 'y';
normalized?: boolean;
enableBorders?: boolean;
showLegend?: boolean;
showPercentage?: boolean;
showValues?: boolean;
Expand Down
Loading