Skip to content

Commit 9ccb261

Browse files
authored
fix: Wrap long key names in chart detail popovers (#3577)
1 parent 1ac1315 commit 9ccb261

File tree

3 files changed

+34
-4
lines changed

3 files changed

+34
-4
lines changed

pages/common/popover-drilldown-sample-data.ts

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,35 @@ export default [
3030
},
3131
],
3232
},
33+
{
34+
title: 'AWS-MiscellaneousOverflowingStringNameService',
35+
data: [
36+
{
37+
x: '2023-04-01',
38+
y: 0,
39+
},
40+
{
41+
x: '2023-05-01',
42+
y: 12,
43+
},
44+
{
45+
x: '2023-06-01',
46+
y: 31,
47+
},
48+
{
49+
x: '2023-07-01',
50+
y: 52,
51+
},
52+
{
53+
x: '2023-08-01',
54+
y: 24,
55+
},
56+
{
57+
x: '2023-09-01',
58+
y: 4,
59+
},
60+
],
61+
},
3362
{
3463
title: 'Amazon Relational Database Service',
3564
data: [

src/internal/components/chart-series-details/styles.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ $font-weight-bold: awsui.$font-weight-heading-s;
3636
justify-content: space-between;
3737
inline-size: 100%;
3838
> .key {
39+
@include styles.text-wrapping;
3940
display: inline-flex;
4041
color: awsui.$color-text-group-label;
4142
}

src/mixed-line-bar-chart/__integ__/announcements.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ describe('Popover content is announced as plain text on hover', () => {
88
const alwaysVisibleTexts = [
99
'Jun 2023',
1010
'Amazon Simple Storage Service $69.80',
11-
'Amazon Relational Database Service $35.96',
12-
'Group 1 $83.31',
13-
'Group 2 $114.17',
11+
'AWS-MiscellaneousOverflowingStringNameService $31.00',
12+
'Group 1 $76.02',
13+
'Group 2 $157.42',
1414
];
15-
const group1SubItemsTexts = ['AWS Config $40.06', 'AWS Key Management Service $43.25'];
15+
const group1SubItemsTexts = ['Amazon Relational Database Service $35.96', 'AWS Config $40.06'];
1616

1717
test(
1818
'without expandable sub-items',

0 commit comments

Comments
 (0)