fix(FN-4061): prevent mobile chat session switcher title clipping
- Add explicit normal line-height on mobile session trigger and option rows - Render session option titles as block elements with normal line-height for wrapped text - Extend ChatView mobile CSS regression assertions to cover new line-height and display rules Fusion-Task-Id: FN-4061
This commit is contained in:
@@ -397,6 +397,7 @@
|
||||
color: var(--text);
|
||||
padding: var(--space-xs) var(--space-sm);
|
||||
min-height: calc(var(--space-lg) * 2);
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.chat-mobile-session-trigger .chat-thread-header-title {
|
||||
@@ -465,6 +466,7 @@
|
||||
cursor: pointer;
|
||||
text-align: left;
|
||||
padding: var(--space-sm) var(--space-md);
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.chat-mobile-session-option:hover {
|
||||
@@ -482,6 +484,8 @@
|
||||
|
||||
.chat-mobile-session-option-title {
|
||||
width: 100%;
|
||||
display: block;
|
||||
line-height: normal;
|
||||
white-space: normal;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
@@ -2498,10 +2498,14 @@ describe("ChatView CSS — mobile thread switcher", () => {
|
||||
expect(optionTitleMatch).toBeTruthy();
|
||||
expect(triggerMatch?.[1]).toContain("min-height: calc(var(--space-lg) * 2)");
|
||||
expect(triggerMatch?.[1]).toContain("min-width: 0");
|
||||
expect(triggerMatch?.[1]).toContain("line-height: normal");
|
||||
expect(dropdownMatch?.[1]).toContain("background: var(--surface)");
|
||||
expect(dropdownMatch?.[1]).toContain("border: 1px solid var(--border)");
|
||||
expect(optionMatch?.[1]).toContain("min-height: calc(var(--space-lg) * 2.25)");
|
||||
expect(optionMatch?.[1]).toContain("align-items: flex-start");
|
||||
expect(optionMatch?.[1]).toContain("line-height: normal");
|
||||
expect(optionTitleMatch?.[1]).toContain("display: block");
|
||||
expect(optionTitleMatch?.[1]).toContain("line-height: normal");
|
||||
expect(optionTitleMatch?.[1]).toContain("white-space: normal");
|
||||
expect(optionTitleMatch?.[1]).toContain("overflow-wrap: anywhere");
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user