Skip to content

Commit 748b482

Browse files
committed
fix(web): show full descriptions for expanded skills
1 parent 38c1d11 commit 748b482

2 files changed

Lines changed: 43 additions & 0 deletions

File tree

apps/web/src/styles/viewer/templates-plugins.css

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1698,6 +1698,9 @@
16981698
padding: 8px 10px 8px 14px;
16991699
min-width: 0;
17001700
}
1701+
.settings-skills .skills-row-expanded .skills-row-head {
1702+
align-items: flex-start;
1703+
}
17011704
.settings-skills .skills-row-summary-btn {
17021705
flex: 1;
17031706
min-width: 0;
@@ -1713,6 +1716,10 @@
17131716
color: inherit;
17141717
font: inherit;
17151718
}
1719+
.settings-skills .skills-row-expanded .skills-row-summary-btn {
1720+
align-items: flex-start;
1721+
height: auto;
1722+
}
17161723
.settings-skills .skills-row-summary-btn:hover .skills-row-summary-name {
17171724
color: var(--accent);
17181725
}
@@ -1796,6 +1803,12 @@
17961803
color: var(--text-muted);
17971804
line-height: 1.4;
17981805
}
1806+
.settings-skills .skills-row-expanded .skills-row-summary-desc {
1807+
overflow: visible;
1808+
overflow-wrap: anywhere;
1809+
text-overflow: clip;
1810+
white-space: normal;
1811+
}
17991812
.settings-skills .skills-row-chevron {
18001813
display: inline-flex;
18011814
align-items: center;

apps/web/tests/styles/settings-polish.test.ts

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,36 @@ describe('settings polish CSS', () => {
5555
expect(ruleValue(content, 'z-index')).toBe('1');
5656
});
5757

58+
it('shows the full skill description when its row is expanded', () => {
59+
const collapsed = cssBlock(
60+
expandedIndexCss,
61+
'.settings-skills .skills-row-summary-desc',
62+
);
63+
const expandedHead = cssBlock(
64+
expandedIndexCss,
65+
'.settings-skills .skills-row-expanded .skills-row-head',
66+
);
67+
const expandedButton = cssBlock(
68+
expandedIndexCss,
69+
'.settings-skills .skills-row-expanded .skills-row-summary-btn',
70+
);
71+
const expanded = cssBlock(
72+
expandedIndexCss,
73+
'.settings-skills .skills-row-expanded .skills-row-summary-desc',
74+
);
75+
76+
expect(ruleValue(collapsed, 'overflow')).toBe('hidden');
77+
expect(ruleValue(collapsed, 'text-overflow')).toBe('ellipsis');
78+
expect(ruleValue(collapsed, 'white-space')).toBe('nowrap');
79+
expect(ruleValue(expandedHead, 'align-items')).toBe('flex-start');
80+
expect(ruleValue(expandedButton, 'align-items')).toBe('flex-start');
81+
expect(ruleValue(expandedButton, 'height')).toBe('auto');
82+
expect(ruleValue(expanded, 'overflow')).toBe('visible');
83+
expect(ruleValue(expanded, 'text-overflow')).toBe('clip');
84+
expect(ruleValue(expanded, 'white-space')).toBe('normal');
85+
expect(ruleValue(expanded, 'overflow-wrap')).toBe('anywhere');
86+
});
87+
5888
it('keeps the silent-update checkbox native-sized and aligned horizontally', () => {
5989
const row = cssBlock(artifactsCss, '.settings-about-diagnostics > .settings-about-toggle');
6090
const checkbox = cssBlock(artifactsCss, '.settings-about-toggle input');

0 commit comments

Comments
 (0)