fix: anchor tile preview to bottom so newest terminal content is visible
Previously the <pre> snapshot floated to the top of .tile-body — when content overflowed, the oldest lines showed and newest were clipped. Now .tile-body pre is position:absolute;bottom:0 so overflow clips from the top and the lower-left corner (newest content) is always shown.
This commit is contained in:
@@ -416,6 +416,16 @@ test('buildTileHTML adds tier class on mobile', () => {
|
||||
assert.ok(html.includes('session-tile--tier-'), 'should contain tier class on mobile');
|
||||
});
|
||||
|
||||
test('buildTileHTML wraps snapshot in .tile-body with <pre> as direct child', () => {
|
||||
const session = { name: 'my-session', snapshot: 'line1\nline2' };
|
||||
const html = app.buildTileHTML(session, 0, false);
|
||||
assert.ok(html.includes('class="tile-body"'), 'should contain .tile-body wrapper');
|
||||
assert.ok(
|
||||
/<div class="tile-body"><pre>/.test(html),
|
||||
'<pre> should be a direct child of .tile-body',
|
||||
);
|
||||
});
|
||||
|
||||
// --- renderGrid ---
|
||||
|
||||
test('renderGrid clears grid and shows empty-state when sessions array is empty', () => {
|
||||
|
||||
Reference in New Issue
Block a user