-
Notifications
You must be signed in to change notification settings - Fork 383
feat(react-charts): add high contrast #12419
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
Changes from 2 commits
ba7dfc5
4289820
50b202a
d6a2939
224a198
cfa1408
dd0c787
8d02694
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -57,6 +57,8 @@ | |
| import chart_legend_orientation from '@patternfly/react-tokens/dist/esm/chart_legend_orientation'; | ||
| import chart_legend_title_orientation from '@patternfly/react-tokens/dist/esm/chart_legend_title_orientation'; | ||
| import chart_legend_data_type from '@patternfly/react-tokens/dist/esm/chart_legend_data_type'; | ||
| import chart_legend_data_stroke_Color from '@patternfly/react-tokens/dist/esm/chart_legend_data_stroke_Color'; | ||
|
Check failure on line 60 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_legend_data_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_legend_data_stroke_Width'; | ||
|
Check failure on line 61 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_legend_title_Padding from '@patternfly/react-tokens/dist/esm/chart_legend_title_Padding'; | ||
| import chart_line_data_Fill from '@patternfly/react-tokens/dist/esm/chart_line_data_Fill'; | ||
| import chart_line_data_Opacity from '@patternfly/react-tokens/dist/esm/chart_line_data_Opacity'; | ||
|
|
@@ -99,6 +101,8 @@ | |
| import chart_donut_pie_angle_Padding from '@patternfly/react-tokens/dist/esm/chart_donut_pie_angle_Padding'; | ||
| import chart_donut_pie_Padding from '@patternfly/react-tokens/dist/esm/chart_donut_pie_Padding'; | ||
| import chart_donut_pie_Width from '@patternfly/react-tokens/dist/esm/chart_donut_pie_Width'; | ||
| import chart_donut_pie_data_stroke_Color from '@patternfly/react-tokens/dist/esm/chart_donut_pie_data_stroke_Color'; | ||
|
Check failure on line 104 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_donut_pie_data_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_donut_pie_data_stroke_Width'; | ||
|
Check failure on line 105 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_donut_threshold_dynamic_pie_Height from '@patternfly/react-tokens/dist/esm/chart_donut_threshold_dynamic_pie_Height'; | ||
| import chart_donut_threshold_dynamic_pie_Padding from '@patternfly/react-tokens/dist/esm/chart_donut_threshold_dynamic_pie_Padding'; | ||
| import chart_donut_threshold_dynamic_pie_Width from '@patternfly/react-tokens/dist/esm/chart_donut_threshold_dynamic_pie_Width'; | ||
|
|
@@ -113,6 +117,8 @@ | |
| import chart_threshold_stroke_dash_array from '@patternfly/react-tokens/dist/esm/chart_threshold_stroke_dash_array'; | ||
| import chart_threshold_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_threshold_stroke_Width'; | ||
| import chart_bullet_Height from '@patternfly/react-tokens/dist/esm/chart_bullet_Height'; | ||
| import chart_bullet_bar_stroke_Color from '@patternfly/react-tokens/dist/esm/chart_bullet_bar_stroke_Color'; | ||
|
Check failure on line 120 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_bullet_bar_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_bullet_bar_stroke_Width'; | ||
|
Check failure on line 121 in packages/react-charts/src/victory/components/ChartTheme/themes/base-theme.ts
|
||
| import chart_bullet_comparative_measure_error_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_bullet_comparative_measure_error_stroke_Width'; | ||
| import chart_bullet_comparative_measure_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_bullet_comparative_measure_stroke_Width'; | ||
| import chart_bullet_comparative_measure_warning_stroke_Width from '@patternfly/react-tokens/dist/esm/chart_bullet_comparative_measure_warning_stroke_Width'; | ||
|
|
@@ -166,9 +172,9 @@ | |
| style: { | ||
| data: { | ||
| fill: chart_area_data_Fill.var, | ||
| fillOpacity: chart_area_Opacity.value, | ||
| fillOpacity: chart_area_Opacity.var, | ||
| // Omit stroke to add a line border from color scale | ||
| // stroke: chart_global_label_stroke.value, | ||
| // stroke: chart_global_label_stroke_color.value, | ||
| strokeWidth: chart_area_stroke_Width.value | ||
| }, | ||
| labels: LABEL_CENTERED_PROPS | ||
|
|
@@ -218,7 +224,7 @@ | |
| fill: chart_bar_data_Fill.var, | ||
| padding: chart_bar_data_Padding.value, | ||
| stroke: chart_bar_data_stroke.var, | ||
| strokeWidth: chart_bar_data_stroke_Width.value | ||
| strokeWidth: chart_bar_data_stroke_Width.var | ||
| }, | ||
| labels: LABEL_PROPS | ||
| } | ||
|
|
@@ -296,7 +302,9 @@ | |
| titleOrientation: chart_legend_title_orientation.value, | ||
| style: { | ||
| data: { | ||
| type: chart_legend_data_type.value | ||
| type: chart_legend_data_type.value, | ||
| stroke: chart_legend_data_stroke_Color.var, | ||
| strokeWidth: chart_legend_data_stroke_Width.var | ||
| }, | ||
| labels: LABEL_PROPS, | ||
| title: { | ||
|
|
@@ -324,7 +332,7 @@ | |
| data: { | ||
| padding: chart_pie_data_Padding.value, | ||
| stroke: chart_pie_data_stroke_Color.var, | ||
| strokeWidth: chart_pie_data_stroke_Width.value | ||
| strokeWidth: chart_pie_data_stroke_Width.var | ||
| }, | ||
| labels: { | ||
| ...LABEL_PROPS, | ||
|
|
@@ -460,6 +468,14 @@ | |
| bulletPrimaryDotMeasure: { | ||
| group: { | ||
| height: chart_bullet_Height.value | ||
| }, | ||
| scatter: { | ||
| style: { | ||
| data: { | ||
| stroke: chart_bullet_bar_stroke_Color.var, | ||
| strokeWidth: chart_bullet_bar_stroke_Width.var | ||
| } | ||
| } | ||
|
Comment on lines
+471
to
+478
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure about the
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @dlabrecq as far as I can tell, the coderabbit comment about imports was just out of date. The build and everything was passing and all of the visual regression tests passed. I requested a re-review and it resoled that comment and didn't flag it again.
You can see that one here - https://pf-react-pr-12419.surge.sh/components/charts/bullet-chart#primary-measure-dot
|
||
| } | ||
| }, | ||
| bulletPrimaryNegativeMeasure: { | ||
|
|
@@ -470,6 +486,14 @@ | |
| bulletPrimarySegmentedMeasure: { | ||
| group: { | ||
| height: chart_bullet_Height.value | ||
| }, | ||
| bar: { | ||
| style: { | ||
| data: { | ||
| stroke: chart_bullet_bar_stroke_Color.var, | ||
| strokeWidth: chart_bullet_bar_stroke_Width.var | ||
| } | ||
| } | ||
| } | ||
| }, | ||
| bulletQualitativeRange: { | ||
|
|
@@ -482,30 +506,54 @@ | |
| height: chart_donut_pie_Height.value, | ||
| padding: chart_donut_pie_Padding.value, | ||
| padAngle: chart_donut_pie_angle_Padding.value, | ||
| width: chart_donut_pie_Width.value | ||
| width: chart_donut_pie_Width.value, | ||
| style: { | ||
| data: { | ||
| stroke: chart_donut_pie_data_stroke_Color.var, | ||
| strokeWidth: chart_donut_pie_data_stroke_Width.var | ||
| } | ||
| } | ||
| } as any // Victory is missing padAngle | ||
| }, | ||
| donutThresholdDynamic: { | ||
| pie: { | ||
| height: chart_donut_threshold_dynamic_pie_Height.value, | ||
| padding: chart_donut_threshold_dynamic_pie_Padding.value, | ||
| width: chart_donut_threshold_dynamic_pie_Width.value | ||
| width: chart_donut_threshold_dynamic_pie_Width.value, | ||
| style: { | ||
| data: { | ||
| stroke: chart_donut_pie_data_stroke_Color.var, | ||
| strokeWidth: chart_donut_pie_data_stroke_Width.var | ||
| } | ||
| } | ||
| } | ||
| }, | ||
| donutThresholdStatic: { | ||
| pie: { | ||
| height: chart_donut_threshold_static_pie_Height.value, | ||
| padAngle: chart_donut_threshold_static_pie_angle_Padding.value, | ||
| padding: chart_donut_threshold_static_pie_Padding.value, | ||
| width: chart_donut_threshold_static_pie_Width.value | ||
| width: chart_donut_threshold_static_pie_Width.value, | ||
| style: { | ||
| data: { | ||
| stroke: chart_donut_pie_data_stroke_Color.var, | ||
| strokeWidth: chart_donut_pie_data_stroke_Width.var | ||
| } | ||
| } | ||
| } as any // Victory is missing padAngle | ||
| }, | ||
| donutUtilization: { | ||
| pie: { | ||
| height: chart_donut_utilization_dynamic_pie_Height.value, | ||
| padding: chart_donut_utilization_dynamic_pie_Padding.value, | ||
| padAngle: chart_donut_utilization_dynamic_pie_angle_Padding.value, | ||
| width: chart_donut_utilization_dynamic_pie_Width.value | ||
| width: chart_donut_utilization_dynamic_pie_Width.value, | ||
| style: { | ||
| data: { | ||
| stroke: chart_donut_pie_data_stroke_Color.var, | ||
| strokeWidth: chart_donut_pie_data_stroke_Width.var | ||
| } | ||
| } | ||
| } as any // Victory is missing padAngle | ||
| }, | ||
| threshold: { | ||
|
|
||

Uh oh!
There was an error while loading. Please reload this page.