fix(news): show the News panel in the phone Context sheet only

Co-Authored-By: Claude Fable 5.2 <[email protected]>
This commit is contained in:
Mazeyar Moeini FeizabadiandClaude Fable 5.2 committed 2026-11-10 21:26:48 +01:00
1 parent fd9373c09c
commit 369b8e924a
2 files changed
+23 -2

No files matched your search

+17
View File
@@ -977,3 +977,20 @@ test('a slow downward pull is claimed before Android native scroll takes ownersh
assert.equal(shell.getSheet(), null);
shell.destroy();
});
test('on phones the News panel shows in the Context sheet only, like Weather', () => {
const css = readFileSync(
new URL('./styles/mobile-shell.css', import.meta.url),
'utf8',
);
// Hidden by id: the rail's own `#news-panel:not(.collapsed)` rule outranks
// the generic `#right-context-rail > *` hiding rule.
assert.match(
css,
/body\.mobile-shell #right-context-rail > #news-panel,\n[^{}]*\{\s*display: none;/,
);
assert.match(
css,
/body\.mobile-shell\[data-mobile-sheet='context'\]\s+#right-context-rail\s+> #news-panel:not\(\[hidden\]\),/,
);
});