Skip to content

Commit

Permalink
Merge pull request #15 from NHS-digital-website/DW-3003-fix-text-cont…
Browse files Browse the repository at this point in the history
…rast-warnings

[DW-3003] Fixed text contrast warnings
  • Loading branch information
LEJA3 authored Jun 21, 2022
2 parents 46bd263 + 65442ba commit b3712b6
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
4 changes: 3 additions & 1 deletion dist/nhsd-dataviz.js
Original file line number Diff line number Diff line change
Expand Up @@ -8700,6 +8700,7 @@ var nhsdviz = (function (exports) {
'@global': {
[`#nhsd-viz-${options.visualisationId}`]: {
position: 'relative',
color: palette.text,
background: palette.background,
textAlign: 'center',
display: 'flex',
Expand Down Expand Up @@ -9331,7 +9332,8 @@ var nhsdviz = (function (exports) {
.call(d => {
d.append('td').text((d) => d.values[0]);
});
table.classed('nhsd-viz-sr-only', true);
table.classed('nhsd-viz-sr-only', true)
.classed('nhsd-viz-body', true);
}

function column (vizChart, options) {
Expand Down
2 changes: 1 addition & 1 deletion dist/nhsd-dataviz.min.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/helpers/chart-styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export default function(target: d3.Selection<d3.BaseType, unknown, HTMLElement,
'@global': {
[`#nhsd-viz-${options.visualisationId}`]: {
position: 'relative',
color: palette.text,
background: palette.background,
textAlign: 'center',
display: 'flex',
Expand Down
3 changes: 2 additions & 1 deletion src/visualisations/sr-table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,6 @@ export default function(vizChart: d3.Selection<HTMLElement, unknown, HTMLElement
d.append('td').text((d: SeriesData['series'][0]) => d.values[0])
});

table.classed('nhsd-viz-sr-only', true);
table.classed('nhsd-viz-sr-only', true)
.classed('nhsd-viz-body', true);
}

0 comments on commit b3712b6

Please sign in to comment.