Keep shared layout visibility defaults in eager styles

This commit is contained in:
Jonathan Sykes
2026-10-08 03:56:47 +08:00
parent 40b92ebc0d
commit c1a546a5c6
6 changed files with 23 additions and 11 deletions

View File

@@ -79,3 +79,11 @@ test('only core scripts and styles remain eager; native fallback and active layo
assert.deepEqual(JSON.parse(html.match(/id="ytp-assets">([^<]+)<\/script>/)[1]).groups,groups);
for(const name of ['playlist','settings','service-mode','lyrics-editor'])assert.ok(groups['feature:'+name].eager);
});
test('layout-independent visibility and transport defaults stay in eager CSS',()=>{
const {groups}=JSON.parse(readFileSync(join(__dirname,'assets.json'),'utf8'));
assert.ok(groups.core.files.includes('/layout-base.css'));
const shared=readFileSync(join(__dirname,'layout-base.css'),'utf8');
for(const selector of ['.stg-overlay','.deck-chips','.np-btn.done .i-save','.sleep-status .sl-ic','.ab-group','.mc-tune'])assert.ok(shared.includes(selector));
assert.ok(html.includes('href="layout-base.css"'));
});